11573Srgrimes/*- 21573Srgrimes * Copyright (c) 1992, 1993 31573Srgrimes * The Regents of the University of California. All rights reserved. 41573Srgrimes * 51573Srgrimes * This code is derived from software contributed to Berkeley by 61573Srgrimes * Christos Zoulas of Cornell University. 71573Srgrimes * 81573Srgrimes * Redistribution and use in source and binary forms, with or without 91573Srgrimes * modification, are permitted provided that the following conditions 101573Srgrimes * are met: 111573Srgrimes * 1. Redistributions of source code must retain the above copyright 121573Srgrimes * notice, this list of conditions and the following disclaimer. 131573Srgrimes * 2. Redistributions in binary form must reproduce the above copyright 141573Srgrimes * notice, this list of conditions and the following disclaimer in the 151573Srgrimes * documentation and/or other materials provided with the distribution. 16148834Sstefanf * 3. Neither the name of the University nor the names of its contributors 171573Srgrimes * may be used to endorse or promote products derived from this software 181573Srgrimes * without specific prior written permission. 191573Srgrimes * 201573Srgrimes * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 211573Srgrimes * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 221573Srgrimes * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 231573Srgrimes * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 241573Srgrimes * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 251573Srgrimes * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 261573Srgrimes * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 271573Srgrimes * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 281573Srgrimes * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 291573Srgrimes * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 301573Srgrimes * SUCH DAMAGE. 311573Srgrimes * 321573Srgrimes * @(#)tty.h 8.1 (Berkeley) 6/4/93 33148834Sstefanf * $NetBSD: tty.h,v 1.11 2005/06/01 11:37:52 lukem Exp $ 3484260Sobrien * $FreeBSD$ 351573Srgrimes */ 361573Srgrimes 371573Srgrimes/* 381573Srgrimes * el.tty.h: Local terminal header 391573Srgrimes */ 401573Srgrimes#ifndef _h_el_tty 4184260Sobrien#define _h_el_tty 421573Srgrimes 431573Srgrimes#include "histedit.h" 441573Srgrimes#include <termios.h> 4584260Sobrien#include <unistd.h> 461573Srgrimes 471573Srgrimes/* Define our own since everyone gets it wrong! */ 4884260Sobrien#define CONTROL(A) ((A) & 037) 491573Srgrimes 501573Srgrimes/* 511573Srgrimes * Aix compatible names 521573Srgrimes */ 531573Srgrimes# if defined(VWERSE) && !defined(VWERASE) 541573Srgrimes# define VWERASE VWERSE 551573Srgrimes# endif /* VWERSE && !VWERASE */ 561573Srgrimes 571573Srgrimes# if defined(VDISCRD) && !defined(VDISCARD) 581573Srgrimes# define VDISCARD VDISCRD 591573Srgrimes# endif /* VDISCRD && !VDISCARD */ 601573Srgrimes 611573Srgrimes# if defined(VFLUSHO) && !defined(VDISCARD) 621573Srgrimes# define VDISCARD VFLUSHO 631573Srgrimes# endif /* VFLUSHO && VDISCARD */ 641573Srgrimes 651573Srgrimes# if defined(VSTRT) && !defined(VSTART) 661573Srgrimes# define VSTART VSTRT 671573Srgrimes# endif /* VSTRT && ! VSTART */ 681573Srgrimes 691573Srgrimes# if defined(VSTAT) && !defined(VSTATUS) 701573Srgrimes# define VSTATUS VSTAT 711573Srgrimes# endif /* VSTAT && ! VSTATUS */ 721573Srgrimes 731573Srgrimes# ifndef ONLRET 741573Srgrimes# define ONLRET 0 751573Srgrimes# endif /* ONLRET */ 761573Srgrimes 771573Srgrimes# ifndef TAB3 781573Srgrimes# ifdef OXTABS 791573Srgrimes# define TAB3 OXTABS 801573Srgrimes# else 811573Srgrimes# define TAB3 0 821573Srgrimes# endif /* OXTABS */ 831573Srgrimes# endif /* !TAB3 */ 841573Srgrimes 851573Srgrimes# if defined(OXTABS) && !defined(XTABS) 861573Srgrimes# define XTABS OXTABS 871573Srgrimes# endif /* OXTABS && !XTABS */ 881573Srgrimes 891573Srgrimes# ifndef ONLCR 901573Srgrimes# define ONLCR 0 911573Srgrimes# endif /* ONLCR */ 921573Srgrimes 931573Srgrimes# ifndef IEXTEN 941573Srgrimes# define IEXTEN 0 951573Srgrimes# endif /* IEXTEN */ 961573Srgrimes 971573Srgrimes# ifndef ECHOCTL 981573Srgrimes# define ECHOCTL 0 991573Srgrimes# endif /* ECHOCTL */ 1001573Srgrimes 1011573Srgrimes# ifndef PARENB 1021573Srgrimes# define PARENB 0 1031573Srgrimes# endif /* PARENB */ 1041573Srgrimes 1051573Srgrimes# ifndef EXTPROC 1061573Srgrimes# define EXTPROC 0 1071573Srgrimes# endif /* EXTPROC */ 1081573Srgrimes 1091573Srgrimes# ifndef FLUSHO 1101573Srgrimes# define FLUSHO 0 1111573Srgrimes# endif /* FLUSHO */ 1121573Srgrimes 1131573Srgrimes 1141573Srgrimes# if defined(VDISABLE) && !defined(_POSIX_VDISABLE) 1151573Srgrimes# define _POSIX_VDISABLE VDISABLE 1161573Srgrimes# endif /* VDISABLE && ! _POSIX_VDISABLE */ 1171573Srgrimes 1181573Srgrimes/* 1191573Srgrimes * Work around ISC's definition of IEXTEN which is 1201573Srgrimes * XCASE! 1211573Srgrimes */ 1221573Srgrimes# ifdef ISC 1231573Srgrimes# if defined(IEXTEN) && defined(XCASE) 1241573Srgrimes# if IEXTEN == XCASE 1251573Srgrimes# undef IEXTEN 1261573Srgrimes# define IEXTEN 0 1271573Srgrimes# endif /* IEXTEN == XCASE */ 1281573Srgrimes# endif /* IEXTEN && XCASE */ 1291573Srgrimes# if defined(IEXTEN) && !defined(XCASE) 1301573Srgrimes# define XCASE IEXTEN 1311573Srgrimes# undef IEXTEN 1321573Srgrimes# define IEXTEN 0 1331573Srgrimes# endif /* IEXTEN && !XCASE */ 1341573Srgrimes# endif /* ISC */ 1351573Srgrimes 1361573Srgrimes/* 1371573Srgrimes * Work around convex weirdness where turning off IEXTEN makes us 1381573Srgrimes * lose all postprocessing! 1391573Srgrimes */ 1401573Srgrimes#if defined(convex) || defined(__convex__) 1411573Srgrimes# if defined(IEXTEN) && IEXTEN != 0 1421573Srgrimes# undef IEXTEN 1431573Srgrimes# define IEXTEN 0 1441573Srgrimes# endif /* IEXTEN != 0 */ 1451573Srgrimes#endif /* convex || __convex__ */ 1461573Srgrimes 14726926Smsmith/* 14826926Smsmith * So that we don't lose job control. 14926926Smsmith */ 15026926Smsmith#ifdef __SVR4 15126926Smsmith# undef CSWTCH 15226926Smsmith#endif 1531573Srgrimes 1541573Srgrimes#ifndef _POSIX_VDISABLE 1551573Srgrimes# define _POSIX_VDISABLE ((unsigned char) -1) 1561573Srgrimes#endif /* _POSIX_VDISABLE */ 1571573Srgrimes 1581573Srgrimes#if !defined(CREPRINT) && defined(CRPRNT) 1591573Srgrimes# define CREPRINT CRPRNT 1601573Srgrimes#endif /* !CREPRINT && CRPRNT */ 1611573Srgrimes#if !defined(CDISCARD) && defined(CFLUSH) 1621573Srgrimes# define CDISCARD CFLUSH 1631573Srgrimes#endif /* !CDISCARD && CFLUSH */ 1641573Srgrimes 1651573Srgrimes#ifndef CINTR 1661573Srgrimes# define CINTR CONTROL('c') 1671573Srgrimes#endif /* CINTR */ 1681573Srgrimes#ifndef CQUIT 1691573Srgrimes# define CQUIT 034 /* ^\ */ 1701573Srgrimes#endif /* CQUIT */ 1711573Srgrimes#ifndef CERASE 1721573Srgrimes# define CERASE 0177 /* ^? */ 1731573Srgrimes#endif /* CERASE */ 1741573Srgrimes#ifndef CKILL 1751573Srgrimes# define CKILL CONTROL('u') 1761573Srgrimes#endif /* CKILL */ 1771573Srgrimes#ifndef CEOF 1781573Srgrimes# define CEOF CONTROL('d') 1791573Srgrimes#endif /* CEOF */ 1801573Srgrimes#ifndef CEOL 1811573Srgrimes# define CEOL _POSIX_VDISABLE 1821573Srgrimes#endif /* CEOL */ 1831573Srgrimes#ifndef CEOL2 1841573Srgrimes# define CEOL2 _POSIX_VDISABLE 1851573Srgrimes#endif /* CEOL2 */ 1861573Srgrimes#ifndef CSWTCH 1871573Srgrimes# define CSWTCH _POSIX_VDISABLE 1881573Srgrimes#endif /* CSWTCH */ 1891573Srgrimes#ifndef CDSWTCH 1901573Srgrimes# define CDSWTCH _POSIX_VDISABLE 1911573Srgrimes#endif /* CDSWTCH */ 1921573Srgrimes#ifndef CERASE2 1931573Srgrimes# define CERASE2 _POSIX_VDISABLE 1941573Srgrimes#endif /* CERASE2 */ 1951573Srgrimes#ifndef CSTART 1961573Srgrimes# define CSTART CONTROL('q') 1971573Srgrimes#endif /* CSTART */ 1981573Srgrimes#ifndef CSTOP 1991573Srgrimes# define CSTOP CONTROL('s') 2001573Srgrimes#endif /* CSTOP */ 2011573Srgrimes#ifndef CSUSP 2021573Srgrimes# define CSUSP CONTROL('z') 2031573Srgrimes#endif /* CSUSP */ 2041573Srgrimes#ifndef CDSUSP 2051573Srgrimes# define CDSUSP CONTROL('y') 2061573Srgrimes#endif /* CDSUSP */ 2071573Srgrimes 2081573Srgrimes#ifdef hpux 2091573Srgrimes 2101573Srgrimes# ifndef CREPRINT 2111573Srgrimes# define CREPRINT _POSIX_VDISABLE 2121573Srgrimes# endif /* CREPRINT */ 2131573Srgrimes# ifndef CDISCARD 2141573Srgrimes# define CDISCARD _POSIX_VDISABLE 2151573Srgrimes# endif /* CDISCARD */ 2161573Srgrimes# ifndef CLNEXT 2171573Srgrimes# define CLNEXT _POSIX_VDISABLE 2181573Srgrimes# endif /* CLNEXT */ 2191573Srgrimes# ifndef CWERASE 2201573Srgrimes# define CWERASE _POSIX_VDISABLE 2211573Srgrimes# endif /* CWERASE */ 2221573Srgrimes 2231573Srgrimes#else /* !hpux */ 2241573Srgrimes 2251573Srgrimes# ifndef CREPRINT 2261573Srgrimes# define CREPRINT CONTROL('r') 2271573Srgrimes# endif /* CREPRINT */ 2281573Srgrimes# ifndef CDISCARD 2291573Srgrimes# define CDISCARD CONTROL('o') 2301573Srgrimes# endif /* CDISCARD */ 2311573Srgrimes# ifndef CLNEXT 2321573Srgrimes# define CLNEXT CONTROL('v') 2331573Srgrimes# endif /* CLNEXT */ 2341573Srgrimes# ifndef CWERASE 2351573Srgrimes# define CWERASE CONTROL('w') 2361573Srgrimes# endif /* CWERASE */ 2371573Srgrimes 2381573Srgrimes#endif /* hpux */ 2391573Srgrimes 2401573Srgrimes#ifndef CSTATUS 2411573Srgrimes# define CSTATUS CONTROL('t') 2421573Srgrimes#endif /* CSTATUS */ 2431573Srgrimes#ifndef CPAGE 2441573Srgrimes# define CPAGE ' ' 2451573Srgrimes#endif /* CPAGE */ 2461573Srgrimes#ifndef CPGOFF 2471573Srgrimes# define CPGOFF CONTROL('m') 2481573Srgrimes#endif /* CPGOFF */ 2491573Srgrimes#ifndef CKILL2 2501573Srgrimes# define CKILL2 _POSIX_VDISABLE 2511573Srgrimes#endif /* CKILL2 */ 2521573Srgrimes#ifndef CBRK 2531573Srgrimes# ifndef masscomp 2541573Srgrimes# define CBRK 0377 2551573Srgrimes# else 2561573Srgrimes# define CBRK '\0' 2571573Srgrimes# endif /* masscomp */ 2581573Srgrimes#endif /* CBRK */ 2591573Srgrimes#ifndef CMIN 2601573Srgrimes# define CMIN CEOF 2611573Srgrimes#endif /* CMIN */ 2621573Srgrimes#ifndef CTIME 2631573Srgrimes# define CTIME CEOL 2641573Srgrimes#endif /* CTIME */ 2651573Srgrimes 2661573Srgrimes/* 2671573Srgrimes * Fix for sun inconsistency. On termio VSUSP and the rest of the 2681573Srgrimes * ttychars > NCC are defined. So we undefine them. 2691573Srgrimes */ 2701573Srgrimes#if defined(TERMIO) || defined(POSIX) 2711573Srgrimes# if defined(POSIX) && defined(NCCS) 2721573Srgrimes# define NUMCC NCCS 2731573Srgrimes# else 2741573Srgrimes# ifdef NCC 2751573Srgrimes# define NUMCC NCC 2761573Srgrimes# endif /* NCC */ 2771573Srgrimes# endif /* POSIX && NCCS */ 2781573Srgrimes# ifdef NUMCC 2791573Srgrimes# ifdef VINTR 2801573Srgrimes# if NUMCC <= VINTR 2811573Srgrimes# undef VINTR 2821573Srgrimes# endif /* NUMCC <= VINTR */ 2831573Srgrimes# endif /* VINTR */ 2841573Srgrimes# ifdef VQUIT 2851573Srgrimes# if NUMCC <= VQUIT 2861573Srgrimes# undef VQUIT 2871573Srgrimes# endif /* NUMCC <= VQUIT */ 2881573Srgrimes# endif /* VQUIT */ 2891573Srgrimes# ifdef VERASE 2901573Srgrimes# if NUMCC <= VERASE 2911573Srgrimes# undef VERASE 2921573Srgrimes# endif /* NUMCC <= VERASE */ 2931573Srgrimes# endif /* VERASE */ 2941573Srgrimes# ifdef VKILL 2951573Srgrimes# if NUMCC <= VKILL 2961573Srgrimes# undef VKILL 2971573Srgrimes# endif /* NUMCC <= VKILL */ 2981573Srgrimes# endif /* VKILL */ 2991573Srgrimes# ifdef VEOF 3001573Srgrimes# if NUMCC <= VEOF 3011573Srgrimes# undef VEOF 3021573Srgrimes# endif /* NUMCC <= VEOF */ 3031573Srgrimes# endif /* VEOF */ 3041573Srgrimes# ifdef VEOL 3051573Srgrimes# if NUMCC <= VEOL 3061573Srgrimes# undef VEOL 3071573Srgrimes# endif /* NUMCC <= VEOL */ 3081573Srgrimes# endif /* VEOL */ 3091573Srgrimes# ifdef VEOL2 3101573Srgrimes# if NUMCC <= VEOL2 3111573Srgrimes# undef VEOL2 3121573Srgrimes# endif /* NUMCC <= VEOL2 */ 3131573Srgrimes# endif /* VEOL2 */ 3141573Srgrimes# ifdef VSWTCH 3151573Srgrimes# if NUMCC <= VSWTCH 3161573Srgrimes# undef VSWTCH 3171573Srgrimes# endif /* NUMCC <= VSWTCH */ 3181573Srgrimes# endif /* VSWTCH */ 3191573Srgrimes# ifdef VDSWTCH 3201573Srgrimes# if NUMCC <= VDSWTCH 3211573Srgrimes# undef VDSWTCH 3221573Srgrimes# endif /* NUMCC <= VDSWTCH */ 3231573Srgrimes# endif /* VDSWTCH */ 3241573Srgrimes# ifdef VERASE2 3251573Srgrimes# if NUMCC <= VERASE2 3261573Srgrimes# undef VERASE2 3271573Srgrimes# endif /* NUMCC <= VERASE2 */ 3281573Srgrimes# endif /* VERASE2 */ 3291573Srgrimes# ifdef VSTART 3301573Srgrimes# if NUMCC <= VSTART 3311573Srgrimes# undef VSTART 3321573Srgrimes# endif /* NUMCC <= VSTART */ 3331573Srgrimes# endif /* VSTART */ 3341573Srgrimes# ifdef VSTOP 3351573Srgrimes# if NUMCC <= VSTOP 3361573Srgrimes# undef VSTOP 3371573Srgrimes# endif /* NUMCC <= VSTOP */ 3381573Srgrimes# endif /* VSTOP */ 3391573Srgrimes# ifdef VWERASE 3401573Srgrimes# if NUMCC <= VWERASE 3411573Srgrimes# undef VWERASE 3421573Srgrimes# endif /* NUMCC <= VWERASE */ 3431573Srgrimes# endif /* VWERASE */ 3441573Srgrimes# ifdef VSUSP 3451573Srgrimes# if NUMCC <= VSUSP 3461573Srgrimes# undef VSUSP 3471573Srgrimes# endif /* NUMCC <= VSUSP */ 3481573Srgrimes# endif /* VSUSP */ 3491573Srgrimes# ifdef VDSUSP 3501573Srgrimes# if NUMCC <= VDSUSP 3511573Srgrimes# undef VDSUSP 3521573Srgrimes# endif /* NUMCC <= VDSUSP */ 3531573Srgrimes# endif /* VDSUSP */ 3541573Srgrimes# ifdef VREPRINT 3551573Srgrimes# if NUMCC <= VREPRINT 3561573Srgrimes# undef VREPRINT 3571573Srgrimes# endif /* NUMCC <= VREPRINT */ 3581573Srgrimes# endif /* VREPRINT */ 3591573Srgrimes# ifdef VDISCARD 3601573Srgrimes# if NUMCC <= VDISCARD 3611573Srgrimes# undef VDISCARD 3621573Srgrimes# endif /* NUMCC <= VDISCARD */ 3631573Srgrimes# endif /* VDISCARD */ 3641573Srgrimes# ifdef VLNEXT 3651573Srgrimes# if NUMCC <= VLNEXT 3661573Srgrimes# undef VLNEXT 3671573Srgrimes# endif /* NUMCC <= VLNEXT */ 3681573Srgrimes# endif /* VLNEXT */ 3691573Srgrimes# ifdef VSTATUS 3701573Srgrimes# if NUMCC <= VSTATUS 3711573Srgrimes# undef VSTATUS 3721573Srgrimes# endif /* NUMCC <= VSTATUS */ 3731573Srgrimes# endif /* VSTATUS */ 3741573Srgrimes# ifdef VPAGE 3751573Srgrimes# if NUMCC <= VPAGE 3761573Srgrimes# undef VPAGE 3771573Srgrimes# endif /* NUMCC <= VPAGE */ 3781573Srgrimes# endif /* VPAGE */ 3791573Srgrimes# ifdef VPGOFF 3801573Srgrimes# if NUMCC <= VPGOFF 3811573Srgrimes# undef VPGOFF 3821573Srgrimes# endif /* NUMCC <= VPGOFF */ 3831573Srgrimes# endif /* VPGOFF */ 3841573Srgrimes# ifdef VKILL2 3851573Srgrimes# if NUMCC <= VKILL2 3861573Srgrimes# undef VKILL2 3871573Srgrimes# endif /* NUMCC <= VKILL2 */ 3881573Srgrimes# endif /* VKILL2 */ 3891573Srgrimes# ifdef VBRK 3901573Srgrimes# if NUMCC <= VBRK 3911573Srgrimes# undef VBRK 3921573Srgrimes# endif /* NUMCC <= VBRK */ 3931573Srgrimes# endif /* VBRK */ 3941573Srgrimes# ifdef VMIN 3951573Srgrimes# if NUMCC <= VMIN 3961573Srgrimes# undef VMIN 3971573Srgrimes# endif /* NUMCC <= VMIN */ 3981573Srgrimes# endif /* VMIN */ 3991573Srgrimes# ifdef VTIME 4001573Srgrimes# if NUMCC <= VTIME 4011573Srgrimes# undef VTIME 4021573Srgrimes# endif /* NUMCC <= VTIME */ 4031573Srgrimes# endif /* VTIME */ 4041573Srgrimes# endif /* NUMCC */ 4051573Srgrimes#endif /* !POSIX */ 4061573Srgrimes 40784260Sobrien#define C_INTR 0 40884260Sobrien#define C_QUIT 1 40984260Sobrien#define C_ERASE 2 41084260Sobrien#define C_KILL 3 41184260Sobrien#define C_EOF 4 41284260Sobrien#define C_EOL 5 41384260Sobrien#define C_EOL2 6 41484260Sobrien#define C_SWTCH 7 41584260Sobrien#define C_DSWTCH 8 41684260Sobrien#define C_ERASE2 9 41784260Sobrien#define C_START 10 41884260Sobrien#define C_STOP 11 41984260Sobrien#define C_WERASE 12 42084260Sobrien#define C_SUSP 13 42184260Sobrien#define C_DSUSP 14 42284260Sobrien#define C_REPRINT 15 42384260Sobrien#define C_DISCARD 16 42484260Sobrien#define C_LNEXT 17 42584260Sobrien#define C_STATUS 18 42684260Sobrien#define C_PAGE 19 42784260Sobrien#define C_PGOFF 20 42884260Sobrien#define C_KILL2 21 42984260Sobrien#define C_BRK 22 43084260Sobrien#define C_MIN 23 43184260Sobrien#define C_TIME 24 43284260Sobrien#define C_NCC 25 43384260Sobrien#define C_SH(A) (1 << (A)) 4341573Srgrimes 4351573Srgrimes/* 4361573Srgrimes * Terminal dependend data structures 4371573Srgrimes */ 43884260Sobrien#define EX_IO 0 /* while we are executing */ 43984260Sobrien#define ED_IO 1 /* while we are editing */ 44084260Sobrien#define TS_IO 2 /* new mode from terminal */ 44184260Sobrien#define QU_IO 2 /* used only for quoted chars */ 44284260Sobrien#define NN_IO 3 /* The number of entries */ 4431573Srgrimes 44484260Sobrien#define MD_INP 0 44584260Sobrien#define MD_OUT 1 44684260Sobrien#define MD_CTL 2 44784260Sobrien#define MD_LIN 3 44884260Sobrien#define MD_CHAR 4 44984260Sobrien#define MD_NN 5 4501573Srgrimes 4518870Srgrimestypedef struct { 452148834Sstefanf const char *t_name; 453148834Sstefanf unsigned int t_setmask; 454148834Sstefanf unsigned int t_clrmask; 45584260Sobrien} ttyperm_t[NN_IO][MD_NN]; 4561573Srgrimes 4571573Srgrimestypedef unsigned char ttychar_t[NN_IO][C_NCC]; 4581573Srgrimes 45984260Sobrienprotected int tty_init(EditLine *); 46084260Sobrienprotected void tty_end(EditLine *); 461148834Sstefanfprotected int tty_stty(EditLine *, int, const char **); 46284260Sobrienprotected int tty_rawmode(EditLine *); 46384260Sobrienprotected int tty_cookedmode(EditLine *); 46484260Sobrienprotected int tty_quotemode(EditLine *); 46584260Sobrienprotected int tty_noquotemode(EditLine *); 46684260Sobrienprotected void tty_bind_char(EditLine *, int); 4671573Srgrimes 4681573Srgrimestypedef struct { 4691573Srgrimes ttyperm_t t_t; 4701573Srgrimes ttychar_t t_c; 4711573Srgrimes struct termios t_ex, t_ed, t_ts; 4721573Srgrimes int t_tabs; 4731573Srgrimes int t_eight; 4741573Srgrimes speed_t t_speed; 4751573Srgrimes int t_mode; 4761573Srgrimes unsigned char t_vdisable; 4771573Srgrimes} el_tty_t; 4781573Srgrimes 4791573Srgrimes 4801573Srgrimes#endif /* _h_el_tty */ 481