add insch(), mvinsch(), and mvwinsch()
[unix-history] / usr / src / lib / libcurses / curses.h
index 099b851..a07abe7 100644 (file)
@@ -1,4 +1,4 @@
-/* %G% (Berkeley) @(#)curses.h 1.4 */
+/* %G% (Berkeley) @(#)curses.h 1.6 */
 # ifndef WINDOW
 
 # include      <stdio.h>
 # ifndef WINDOW
 
 # include      <stdio.h>
@@ -29,18 +29,18 @@ typedef     struct sgttyb   SGTTY;
  * Capabilities from termcap
  */
 
  * Capabilities from termcap
  */
 
-bool   AM, BS, CA, DA, DB, EO, GT, HZ, IN, MI, MS, NC, OS, UL, XN;
-char    *AL, *BC, *BT, *CD, *CE, *CL, *CM, *DC, *DL, *DM, *DO, *ED,
-       *EI, *HO, *IC, *IM, *IP, *LL, *MA, *ND, *SE, *SF, *SO, *SR,
-       *TA, *TE, *TI, *UC, *UE, *UP, *US, *VB, *VE, *VS, PC;
+extern bool     AM, BS, CA, DA, DB, EO, GT, HZ, IN, MI, MS, NC, OS, UL,
+               XN;
+extern char     *AL, *BC, *BT, *CD, *CE, *CL, *CM, *DC, *DL, *DM, *DO,
+               *ED, *EI, *HO, *IC, *IM, *IP, *LL, *MA, *ND, *SE, *SF,
+               *SO, *SR, *TA, *TE, *TI, *UC, *UE, *UP, *US, *VB, *VE,
+               *VS, PC;
 
 /*
  * From the tty modes...
  */
 
 
 /*
  * From the tty modes...
  */
 
-bool   NONL, UPPERCASE;
-
-bool   normtty, _pfast;
+extern bool    NONL, UPPERCASE, normtty, _pfast;
 
 struct _win_st {
        short   _cury, _curx;
 
 struct _win_st {
        short   _cury, _curx;
@@ -63,9 +63,9 @@ extern char   *Def_term, ttytype[];
 
 extern int     LINES, COLS, _tty_ch, _res_flg;
 
 
 extern int     LINES, COLS, _tty_ch, _res_flg;
 
-SGTTY          _tty;
+extern SGTTY   _tty;
 
 
-WINDOW         *stdscr, *curscr;
+extern WINDOW  *stdscr, *curscr;
 
 /*
  *     Define VOID to stop lint from generating "null effect"
 
 /*
  *     Define VOID to stop lint from generating "null effect"
@@ -94,6 +94,7 @@ int   __void__;
 # define       deleteln()      VOID(wdeleteln(stdscr))
 # define       refresh()       VOID(wrefresh(stdscr))
 # define       inch()          VOID(winch(stdscr))
 # define       deleteln()      VOID(wdeleteln(stdscr))
 # define       refresh()       VOID(wrefresh(stdscr))
 # define       inch()          VOID(winch(stdscr))
+# define       insch(c)        VOID(winsch(stdscr,c))
 # define       standout()      VOID(wstandout(stdscr))
 # define       standend()      VOID(wstandend(stdscr))
 
 # define       standout()      VOID(wstandout(stdscr))
 # define       standend()      VOID(wstandend(stdscr))
 
@@ -105,11 +106,13 @@ int       __void__;
 #define        mvwaddstr(win,y,x,str)  VOID(wmove(win,y,x)==ERR?ERR:waddstr(win,str))
 #define        mvwgetstr(win,y,x)      VOID(wmove(win,y,x)==ERR?ERR:wgetstr(win))
 #define        mvwinch(win,y,x)        VOID(wmove(win,y,x) == ERR ? ERR : winch(win))
 #define        mvwaddstr(win,y,x,str)  VOID(wmove(win,y,x)==ERR?ERR:waddstr(win,str))
 #define        mvwgetstr(win,y,x)      VOID(wmove(win,y,x)==ERR?ERR:wgetstr(win))
 #define        mvwinch(win,y,x)        VOID(wmove(win,y,x) == ERR ? ERR : winch(win))
+#define        mvwinsch(win,y,x,c)     VOID(wmove(win,y,x) == ERR ? ERR:winsch(win,c))
 #define        mvaddch(y,x,ch)         mvwaddch(stdscr,y,x,ch)
 #define        mvgetch(y,x)            mvwgetch(stdscr,y,x)
 #define        mvaddstr(y,x,str)       mvwaddstr(stdscr,y,x,str)
 #define        mvgetstr(y,x)           mvwgetstr(stdscr,y,x)
 #define        mvaddch(y,x,ch)         mvwaddch(stdscr,y,x,ch)
 #define        mvgetch(y,x)            mvwgetch(stdscr,y,x)
 #define        mvaddstr(y,x,str)       mvwaddstr(stdscr,y,x,str)
 #define        mvgetstr(y,x)           mvwgetstr(stdscr,y,x)
-#define        mvinch(y,x)             mvwinch(win,y,x)
+#define        mvinch(y,x)             mvwinch(stdscr,y,x)
+#define        mvinsch(y,x,c)          mvwinsch(stdscr,y,x,c)
 
 /*
  * psuedo functions
 
 /*
  * psuedo functions