sync
[bitrig.git] / bin / ksh / tty.h
bloba7b3aaa8c5745d83f97f9f78c5d7cbe2685b46b0
1 /* $OpenBSD: tty.h,v 1.5 2004/12/20 11:34:26 otto Exp $ */
3 /*
4 tty.h -- centralized definitions for a variety of terminal interfaces
6 created by DPK, Oct. 1986
8 Rearranged to work with autoconf, added TTY_state, get_tty/set_tty
9 Michael Rendell, May '94
11 last edit: 30-Jul-1987 D A Gwyn
14 /* some useful #defines */
15 #ifdef EXTERN
16 # define I__(i) = i
17 #else
18 # define I__(i)
19 # define EXTERN extern
20 # define EXTERN_DEFINED
21 #endif
23 #include <termios.h>
25 EXTERN int tty_fd I__(-1); /* dup'd tty file descriptor */
26 EXTERN int tty_devtty; /* true if tty_fd is from /dev/tty */
27 EXTERN struct termios tty_state; /* saved tty state */
29 extern void tty_init(int);
30 extern void tty_close(void);
32 /* be sure not to interfere with anyone else's idea about EXTERN */
33 #ifdef EXTERN_DEFINED
34 # undef EXTERN_DEFINED
35 # undef EXTERN
36 #endif
37 #undef I__