xref: /titanic_52/usr/src/cmd/vi/port/ex_vis.h (revision bbfd0aa6b6f4ad933985f9b64f0fe3686be1f8b7)
17c478bd9Sstevel@tonic-gate /*
27c478bd9Sstevel@tonic-gate  * CDDL HEADER START
37c478bd9Sstevel@tonic-gate  *
47c478bd9Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
5*bbfd0aa6Scf46844  * Common Development and Distribution License (the "License").
6*bbfd0aa6Scf46844  * You may not use this file except in compliance with the License.
77c478bd9Sstevel@tonic-gate  *
87c478bd9Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97c478bd9Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
107c478bd9Sstevel@tonic-gate  * See the License for the specific language governing permissions
117c478bd9Sstevel@tonic-gate  * and limitations under the License.
127c478bd9Sstevel@tonic-gate  *
137c478bd9Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
147c478bd9Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
157c478bd9Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
167c478bd9Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
177c478bd9Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
187c478bd9Sstevel@tonic-gate  *
197c478bd9Sstevel@tonic-gate  * CDDL HEADER END
207c478bd9Sstevel@tonic-gate  */
21f6db9f27Scf46844 /*
22*bbfd0aa6Scf46844  * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
23f6db9f27Scf46844  * Use is subject to license terms.
24f6db9f27Scf46844  */
25f6db9f27Scf46844 
267c478bd9Sstevel@tonic-gate /*	Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T	*/
277c478bd9Sstevel@tonic-gate /*	  All Rights Reserved  	*/
287c478bd9Sstevel@tonic-gate 
297c478bd9Sstevel@tonic-gate 
307c478bd9Sstevel@tonic-gate /* Copyright (c) 1981 Regents of the University of California */
31f6db9f27Scf46844 
32f6db9f27Scf46844 #ifndef _EX_VIS_H
33f6db9f27Scf46844 #define	_EX_VIS_H
34f6db9f27Scf46844 
35f6db9f27Scf46844 #pragma ident	"%Z%%M%	%I%	%E% SMI"
36f6db9f27Scf46844 
37f6db9f27Scf46844 #ifdef __cplusplus
38f6db9f27Scf46844 extern "C" {
39f6db9f27Scf46844 #endif
40f6db9f27Scf46844 
417c478bd9Sstevel@tonic-gate /*
427c478bd9Sstevel@tonic-gate  * Ex version 3
437c478bd9Sstevel@tonic-gate  *
447c478bd9Sstevel@tonic-gate  * Open and visual mode definitions.
457c478bd9Sstevel@tonic-gate  *
467c478bd9Sstevel@tonic-gate  * There are actually 4 major states in open/visual modes.  These
477c478bd9Sstevel@tonic-gate  * are visual, crt open (where the cursor can move about the screen and
487c478bd9Sstevel@tonic-gate  * the screen can scroll and be erased), one line open (on dumb glass-crt's
497c478bd9Sstevel@tonic-gate  * like the adm3), and hardcopy open (for everything else).
507c478bd9Sstevel@tonic-gate  *
517c478bd9Sstevel@tonic-gate  * The basic state is given by bastate, and the current state by state,
527c478bd9Sstevel@tonic-gate  * since we can be in pseudo-hardcopy mode if we are on an adm3 and the
537c478bd9Sstevel@tonic-gate  * line is longer than 80.
547c478bd9Sstevel@tonic-gate  */
557c478bd9Sstevel@tonic-gate 
567c478bd9Sstevel@tonic-gate var	short	bastate;
577c478bd9Sstevel@tonic-gate var	short	state;
587c478bd9Sstevel@tonic-gate 
597c478bd9Sstevel@tonic-gate #define	VISUAL		0
607c478bd9Sstevel@tonic-gate #define	CRTOPEN		1
617c478bd9Sstevel@tonic-gate #define	ONEOPEN		2
627c478bd9Sstevel@tonic-gate #define	HARDOPEN	3
637c478bd9Sstevel@tonic-gate 
647c478bd9Sstevel@tonic-gate /*
657c478bd9Sstevel@tonic-gate  * The screen in visual and crtopen is of varying size; the basic
667c478bd9Sstevel@tonic-gate  * window has top basWTOP and basWLINES lines are thereby implied.
677c478bd9Sstevel@tonic-gate  * The current window (which may have grown from the basic size)
687c478bd9Sstevel@tonic-gate  * has top WTOP and WLINES lines.  The top line of the window is WTOP,
697c478bd9Sstevel@tonic-gate  * and the bottom line WBOT.  The line WECHO is used for messages,
707c478bd9Sstevel@tonic-gate  * search strings and the like.  If WBOT==WECHO then we are in ONEOPEN
717c478bd9Sstevel@tonic-gate  * or HARDOPEN and there is no way back to the line we were on if we
727c478bd9Sstevel@tonic-gate  * go to WECHO (i.e. we will have to scroll before we go there, and
737c478bd9Sstevel@tonic-gate  * we can't get back).  There are WCOLS columns per line.
747c478bd9Sstevel@tonic-gate  * If WBOT!=WECHO then WECHO will be the last line on the screen
757c478bd9Sstevel@tonic-gate  * and WBOT is the line before it.
767c478bd9Sstevel@tonic-gate  */
777c478bd9Sstevel@tonic-gate var	short	basWTOP;
787c478bd9Sstevel@tonic-gate var	short	basWLINES;
797c478bd9Sstevel@tonic-gate var	short	WTOP;
807c478bd9Sstevel@tonic-gate var	short	WBOT;
817c478bd9Sstevel@tonic-gate var	short	WLINES;
827c478bd9Sstevel@tonic-gate var	short	WCOLS;
837c478bd9Sstevel@tonic-gate var	short	WECHO;
847c478bd9Sstevel@tonic-gate 
857c478bd9Sstevel@tonic-gate /*
867c478bd9Sstevel@tonic-gate  * When we are dealing with the echo area we consider the window
877c478bd9Sstevel@tonic-gate  * to be "split" and set the variable splitw.  Otherwise, moving
887c478bd9Sstevel@tonic-gate  * off the bottom of the screen into WECHO causes a screen rollup.
897c478bd9Sstevel@tonic-gate  */
907c478bd9Sstevel@tonic-gate var	bool	splitw;
917c478bd9Sstevel@tonic-gate 
927c478bd9Sstevel@tonic-gate /*
937c478bd9Sstevel@tonic-gate  * Information about each line currently on the screen includes
947c478bd9Sstevel@tonic-gate  * the y coordinate associated with the line, the printing depth
957c478bd9Sstevel@tonic-gate  * of the line (0 indicates unknown), and a mask which indicates
967c478bd9Sstevel@tonic-gate  * whether the line is "unclean", i.e. whether we should check
977c478bd9Sstevel@tonic-gate  * to make sure the line is displayed correctly at the next
987c478bd9Sstevel@tonic-gate  * appropriate juncture.
997c478bd9Sstevel@tonic-gate  */
1007c478bd9Sstevel@tonic-gate struct vlinfo {
1017c478bd9Sstevel@tonic-gate 	short	vliny;		/* Y coordinate */	/* was char */
1027c478bd9Sstevel@tonic-gate 	short	vdepth;		/* Depth of displayed line */ /* was char */
1037c478bd9Sstevel@tonic-gate 	short	vflags;		/* Is line potentially dirty ? */
1047c478bd9Sstevel@tonic-gate };
1057c478bd9Sstevel@tonic-gate var	struct vlinfo  vlinfo[TUBELINES + 2];
1067c478bd9Sstevel@tonic-gate 
1077c478bd9Sstevel@tonic-gate #define	DEPTH(c)	(vlinfo[c].vdepth)
1087c478bd9Sstevel@tonic-gate #define	LINE(c)		(vlinfo[c].vliny)
1097c478bd9Sstevel@tonic-gate #define	FLAGS(c)	(vlinfo[c].vflags)
1107c478bd9Sstevel@tonic-gate 
1117c478bd9Sstevel@tonic-gate #define	VDIRT	1
1127c478bd9Sstevel@tonic-gate 
1137c478bd9Sstevel@tonic-gate /*
1147c478bd9Sstevel@tonic-gate  * Hacks to copy vlinfo structures around
1157c478bd9Sstevel@tonic-gate  */
1167c478bd9Sstevel@tonic-gate #ifdef	V6
1177c478bd9Sstevel@tonic-gate 	/* Kludge to make up for no structure assignment */
1187c478bd9Sstevel@tonic-gate 	struct {
1197c478bd9Sstevel@tonic-gate 		long	longi;
1207c478bd9Sstevel@tonic-gate 	};
1217c478bd9Sstevel@tonic-gate #define	vlcopy(i, j)	i.longi = j.longi
1227c478bd9Sstevel@tonic-gate #else
1237c478bd9Sstevel@tonic-gate #define	vlcopy(i, j)	i = j;
1247c478bd9Sstevel@tonic-gate #endif
1257c478bd9Sstevel@tonic-gate 
1267c478bd9Sstevel@tonic-gate /*
1277c478bd9Sstevel@tonic-gate  * The current line on the screen is represented by vcline.
1287c478bd9Sstevel@tonic-gate  * There are vcnt lines on the screen, the last being "vcnt - 1".
1297c478bd9Sstevel@tonic-gate  * Vcline is intimately tied to the current value of dot,
1307c478bd9Sstevel@tonic-gate  * and when command mode is used as a subroutine fancy footwork occurs.
1317c478bd9Sstevel@tonic-gate  */
1327c478bd9Sstevel@tonic-gate var	short	vcline;
1337c478bd9Sstevel@tonic-gate var	short	vcnt;
1347c478bd9Sstevel@tonic-gate 
1357c478bd9Sstevel@tonic-gate /*
1367c478bd9Sstevel@tonic-gate  * To allow many optimizations on output, an exact image of the terminal
1377c478bd9Sstevel@tonic-gate  * screen is maintained in the space addressed by vtube0.  The vtube
1387c478bd9Sstevel@tonic-gate  * array indexes this space as lines, and is shuffled on scrolls, insert+delete
1397c478bd9Sstevel@tonic-gate  * lines and the like rather than (more expensively) shuffling the screen
1407c478bd9Sstevel@tonic-gate  * data itself.  It is also rearranged during insert mode across line
1417c478bd9Sstevel@tonic-gate  * boundaries to make incore work easier.
1427c478bd9Sstevel@tonic-gate  */
1437c478bd9Sstevel@tonic-gate var	wchar_t	*vtube[TUBELINES];
1447c478bd9Sstevel@tonic-gate var	wchar_t	*vtube0;
1457c478bd9Sstevel@tonic-gate 
1467c478bd9Sstevel@tonic-gate /*
1477c478bd9Sstevel@tonic-gate  * The current cursor position within the current line is kept in
1487c478bd9Sstevel@tonic-gate  * cursor.  The current line is kept in linebuf.  During insertions
1497c478bd9Sstevel@tonic-gate  * we use the auxiliary array genbuf as scratch area.
1507c478bd9Sstevel@tonic-gate  * The cursor wcursor and wdot are used in operations within/spanning
1517c478bd9Sstevel@tonic-gate  * lines to mark the other end of the affected area, or the target
1527c478bd9Sstevel@tonic-gate  * for a motion.
1537c478bd9Sstevel@tonic-gate  */
1547c478bd9Sstevel@tonic-gate var	unsigned char	*cursor;
1557c478bd9Sstevel@tonic-gate var	unsigned char	*wcursor;
1567c478bd9Sstevel@tonic-gate var	line	*wdot;
1577c478bd9Sstevel@tonic-gate 
1587c478bd9Sstevel@tonic-gate /*
1597c478bd9Sstevel@tonic-gate  * Undo information is saved in a LBSIZE buffer at "vutmp" for changes
1607c478bd9Sstevel@tonic-gate  * within the current line, or as for command mode for multi-line changes
1617c478bd9Sstevel@tonic-gate  * or changes on lines no longer the current line.
1627c478bd9Sstevel@tonic-gate  * The change kind "VCAPU" is used immediately after a U undo to prevent
1637c478bd9Sstevel@tonic-gate  * two successive U undo's from destroying the previous state.
1647c478bd9Sstevel@tonic-gate  */
1657c478bd9Sstevel@tonic-gate #define	VNONE	0
1667c478bd9Sstevel@tonic-gate #define	VCHNG	1
1677c478bd9Sstevel@tonic-gate #define	VMANY	2
1687c478bd9Sstevel@tonic-gate #define	VCAPU	3
1697c478bd9Sstevel@tonic-gate #define	VMCHNG	4
1707c478bd9Sstevel@tonic-gate #define	VMANYINS 5
1717c478bd9Sstevel@tonic-gate 
1727c478bd9Sstevel@tonic-gate var	short	vundkind;	/* Which kind of undo - from above */
1737c478bd9Sstevel@tonic-gate var	unsigned char	*vutmp;		/* Prev line image when "VCHNG" */
1747c478bd9Sstevel@tonic-gate 
1757c478bd9Sstevel@tonic-gate /*
1767c478bd9Sstevel@tonic-gate  * State information for undoing of macros.  The basic idea is that
1777c478bd9Sstevel@tonic-gate  * if the macro does only 1 change or even none, we don't treat it
1787c478bd9Sstevel@tonic-gate  * specially.  If it does 2 or more changes we want to be able to
1797c478bd9Sstevel@tonic-gate  * undo it as a unit.  We remember how many changes have been made
1807c478bd9Sstevel@tonic-gate  * within the current macro.  (Remember macros can be nested.)
1817c478bd9Sstevel@tonic-gate  */
1827c478bd9Sstevel@tonic-gate #define VC_NOTINMAC	0	/* Not in a macro */
1837c478bd9Sstevel@tonic-gate #define VC_NOCHANGE	1	/* In a macro, no changes so far */
1847c478bd9Sstevel@tonic-gate #define VC_ONECHANGE	2	/* In a macro, one change so far */
1857c478bd9Sstevel@tonic-gate #define VC_MANYCHANGE	3	/* In a macro, at least 2 changes so far */
1867c478bd9Sstevel@tonic-gate 
1877c478bd9Sstevel@tonic-gate var	short	vch_mac;	/* Change state - one of the above */
1887c478bd9Sstevel@tonic-gate 
1897c478bd9Sstevel@tonic-gate /*
1907c478bd9Sstevel@tonic-gate  * For U undo's the line is grabbed by "vmove" after it first appears
1917c478bd9Sstevel@tonic-gate  * on that line.  The "vUNDdot" which specifies which line has been
1927c478bd9Sstevel@tonic-gate  * saved is selectively cleared when changes involving other lines
1937c478bd9Sstevel@tonic-gate  * are made, i.e. after a 'J' join.  This is because a 'JU' would
1947c478bd9Sstevel@tonic-gate  * lose completely the text of the line just joined on.
1957c478bd9Sstevel@tonic-gate  */
1967c478bd9Sstevel@tonic-gate var	unsigned char	*vUNDcurs;	/* Cursor just before 'U' */
1977c478bd9Sstevel@tonic-gate var	line	*vUNDdot;	/* The line address of line saved in vUNDsav */
1987c478bd9Sstevel@tonic-gate var	line	vUNDsav;	/* Grabbed initial "*dot" */
1997c478bd9Sstevel@tonic-gate 
2007c478bd9Sstevel@tonic-gate #define	killU()		vUNDdot = NOLINE
2017c478bd9Sstevel@tonic-gate 
2027c478bd9Sstevel@tonic-gate /*
2037c478bd9Sstevel@tonic-gate  * There are a number of cases where special behaviour is needed
2047c478bd9Sstevel@tonic-gate  * from deeply nested routines.  This is accomplished by setting
2057c478bd9Sstevel@tonic-gate  * the bits of hold, which acts to change the state of the general
2067c478bd9Sstevel@tonic-gate  * visual editing behaviour in specific ways.
2077c478bd9Sstevel@tonic-gate  *
2087c478bd9Sstevel@tonic-gate  * HOLDAT prevents the clreol (clear to end of line) routines from
2097c478bd9Sstevel@tonic-gate  * putting out @'s or ~'s on empty lines.
2107c478bd9Sstevel@tonic-gate  *
2117c478bd9Sstevel@tonic-gate  * HOLDDOL prevents the reopen routine from putting a '$' at the
2127c478bd9Sstevel@tonic-gate  * end of a reopened line in list mode (for hardcopy mode, e.g.).
2137c478bd9Sstevel@tonic-gate  *
2147c478bd9Sstevel@tonic-gate  * HOLDROL prevents spurious blank lines when scrolling in hardcopy
2157c478bd9Sstevel@tonic-gate  * open mode.
2167c478bd9Sstevel@tonic-gate  *
2177c478bd9Sstevel@tonic-gate  * HOLDQIK prevents the fake insert mode during repeated commands.
2187c478bd9Sstevel@tonic-gate  *
2197c478bd9Sstevel@tonic-gate  * HOLDPUPD prevents updating of the physical screen image when
2207c478bd9Sstevel@tonic-gate  * mucking around while in insert mode.
2217c478bd9Sstevel@tonic-gate  *
2227c478bd9Sstevel@tonic-gate  * HOLDECH prevents clearing of the echo area while rolling the screen
2237c478bd9Sstevel@tonic-gate  * backwards (e.g.) in deference to the clearing of the area at the
2247c478bd9Sstevel@tonic-gate  * end of the scroll (1 time instead of n times).  The fact that this
2257c478bd9Sstevel@tonic-gate  * is actually needed is recorded in heldech, which says that a clear
2267c478bd9Sstevel@tonic-gate  * of the echo area was actually held off.
2277c478bd9Sstevel@tonic-gate  */
2287c478bd9Sstevel@tonic-gate var	short	hold;
2297c478bd9Sstevel@tonic-gate var	short	holdupd;	/* Hold off update when echo line is too long */
2307c478bd9Sstevel@tonic-gate 
2317c478bd9Sstevel@tonic-gate #define	HOLDAT		1
2327c478bd9Sstevel@tonic-gate #define	HOLDDOL		2
2337c478bd9Sstevel@tonic-gate #define	HOLDROL		4
2347c478bd9Sstevel@tonic-gate #define	HOLDQIK		8
2357c478bd9Sstevel@tonic-gate #define	HOLDPUPD	16
2367c478bd9Sstevel@tonic-gate #define	HOLDECH		32
2377c478bd9Sstevel@tonic-gate #define HOLDWIG		64
2387c478bd9Sstevel@tonic-gate 
2397c478bd9Sstevel@tonic-gate /*
2407c478bd9Sstevel@tonic-gate  * Miscellaneous variables
2417c478bd9Sstevel@tonic-gate  */
2427c478bd9Sstevel@tonic-gate var	short	CDCNT;		/* Count of ^D's in insert on this line */
2437c478bd9Sstevel@tonic-gate var	unsigned char	DEL[VBSIZE+1];	/* Last deleted text */
2447c478bd9Sstevel@tonic-gate var	bool	HADUP;		/* This insert line started with ^ then ^D */
2457c478bd9Sstevel@tonic-gate var	bool	HADZERO;	/* This insert line started with 0 then ^D */
2467c478bd9Sstevel@tonic-gate var	unsigned char	INS[VBSIZE+1];	/* Last inserted text */
2477c478bd9Sstevel@tonic-gate var	int	Vlines;		/* Number of file lines "before" vi command */
2487c478bd9Sstevel@tonic-gate var	int	Xcnt;		/* External variable holding last cmd's count */
2497c478bd9Sstevel@tonic-gate var	bool	Xhadcnt;	/* Last command had explicit count? */
2507c478bd9Sstevel@tonic-gate var	short	ZERO;
2517c478bd9Sstevel@tonic-gate var	short	dir;		/* Direction for search (+1 or -1) */
2527c478bd9Sstevel@tonic-gate var	short	doomed;		/* Disply chars right of cursor to be killed */
2537c478bd9Sstevel@tonic-gate var	bool	gobblebl;	/* Wrapmargin space generated nl, eat a space */
2547c478bd9Sstevel@tonic-gate var	bool	hadcnt;		/* (Almost) internal to vmain() */
2557c478bd9Sstevel@tonic-gate var	bool	heldech;	/* We owe a clear of echo area */
2567c478bd9Sstevel@tonic-gate var	bool	insmode;	/* Are in character insert mode */
2577c478bd9Sstevel@tonic-gate var	unsigned char	lastcmd[5];	/* Chars in last command */
2587c478bd9Sstevel@tonic-gate var	int	lastcnt;	/* Count for last command */
2597c478bd9Sstevel@tonic-gate var	unsigned char	*lastcp;	/* Save current command here to repeat */
2607c478bd9Sstevel@tonic-gate var	bool	lasthad;	/* Last command had a count? */
2617c478bd9Sstevel@tonic-gate var	short	lastvgk;	/* Previous input key, if not from keyboard */
2627c478bd9Sstevel@tonic-gate var	short	lastreg;	/* Register with last command */
2637c478bd9Sstevel@tonic-gate var	unsigned char	*ncols['z'-'a'+2];	/* Cursor positions of marks */
2647c478bd9Sstevel@tonic-gate var	unsigned char	*notenam;	/* Name to be noted with change count */
2657c478bd9Sstevel@tonic-gate var	unsigned char	*notesgn;	/* Change count from last command */
2667c478bd9Sstevel@tonic-gate var	unsigned char	op;		/* Operation of current command */
2677c478bd9Sstevel@tonic-gate var	int	Peekkey;	/* Peek ahead key */
2687c478bd9Sstevel@tonic-gate var	bool	rubble;		/* Line is filthy (in hardcopy open), redraw! */
2697c478bd9Sstevel@tonic-gate var	int	vSCROLL;	/* Number lines to scroll on ^D/^U */
2707c478bd9Sstevel@tonic-gate var	unsigned char	*vglobp;	/* Untyped input (e.g. repeat insert text) */
2717c478bd9Sstevel@tonic-gate var	unsigned char	vmacbuf[VBSIZE];   /* Text of visual macro, hence nonnestable */
2727c478bd9Sstevel@tonic-gate var	unsigned char	*vmacp;		/* Like vglobp but for visual macros */
2737c478bd9Sstevel@tonic-gate var	unsigned char	*vmcurs;	/* Cursor for restore after undo d), e.g. */
2747c478bd9Sstevel@tonic-gate var	short	vmovcol;	/* Column to try to keep on arrow keys */
2757c478bd9Sstevel@tonic-gate var	bool	vmoving;	/* Are trying to keep vmovcol */
2767c478bd9Sstevel@tonic-gate var	short	vreg;		/* Reg for this command */   /* mjm: was char */
2777c478bd9Sstevel@tonic-gate var	short	wdkind;		/* Liberal/conservative words? */
2787c478bd9Sstevel@tonic-gate var	unsigned char	workcmd[5];	/* Temporary for lastcmd */
2797c478bd9Sstevel@tonic-gate var	bool rewrite;
2807c478bd9Sstevel@tonic-gate #ifdef XPG4
2817c478bd9Sstevel@tonic-gate var	int	P_cursor_offset;	/* cursor adjust for Put */
2827c478bd9Sstevel@tonic-gate #endif
2837c478bd9Sstevel@tonic-gate #ifndef PRESUNEUC
2847c478bd9Sstevel@tonic-gate var	unsigned char	wcharfiller;	/* Right margin filler for wide char */
2857c478bd9Sstevel@tonic-gate #endif /* PRESUNEUC */
2867c478bd9Sstevel@tonic-gate 
2877c478bd9Sstevel@tonic-gate 
2887c478bd9Sstevel@tonic-gate /*
2897c478bd9Sstevel@tonic-gate  * Macros
2907c478bd9Sstevel@tonic-gate  */
2917c478bd9Sstevel@tonic-gate #define	INF		30000
2927c478bd9Sstevel@tonic-gate #define	LASTLINE	LINE(vcnt)
2937c478bd9Sstevel@tonic-gate #define	beep		obeep
2947c478bd9Sstevel@tonic-gate #define	cindent()	((outline - vlinfo[vcline].vliny) * WCOLS + outcol)
2957c478bd9Sstevel@tonic-gate #define	vputp(cp, cnt)	tputs(cp, cnt, vputch)
2967c478bd9Sstevel@tonic-gate #define	vputc(c)	putch(c)
2977c478bd9Sstevel@tonic-gate #define	_ON	1
2987c478bd9Sstevel@tonic-gate #define	_OFF	0
2997c478bd9Sstevel@tonic-gate /*
3007c478bd9Sstevel@tonic-gate  * Function types
3017c478bd9Sstevel@tonic-gate  */
302*bbfd0aa6Scf46844 int	any();
3037c478bd9Sstevel@tonic-gate int	beep();
304*bbfd0aa6Scf46844 void	fixundo(void);
3057c478bd9Sstevel@tonic-gate int	qcount();
306f6db9f27Scf46844 int	vchange(unsigned char);
307f6db9f27Scf46844 int	vdelete(unsigned char);
3087c478bd9Sstevel@tonic-gate int	vgrabit();
3097c478bd9Sstevel@tonic-gate int	vinschar();
3107c478bd9Sstevel@tonic-gate int	vmove();
3117c478bd9Sstevel@tonic-gate int	vputchar();
3127c478bd9Sstevel@tonic-gate int	vshift();
3137c478bd9Sstevel@tonic-gate int	vyankit();
3147c478bd9Sstevel@tonic-gate 
3157c478bd9Sstevel@tonic-gate #define FILLER 0177 /* fill positions for multibyte characters */
316f6db9f27Scf46844 
317f6db9f27Scf46844 #ifdef __cplusplus
318f6db9f27Scf46844 }
319f6db9f27Scf46844 #endif
320f6db9f27Scf46844 
321f6db9f27Scf46844 #endif /* _EX_VIS_H */
322