1 /* -*-C-*-
2 
3 Copyright (C) 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
4     1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
5     2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Massachusetts
6     Institute of Technology
7 
8 This file is part of MIT/GNU Scheme.
9 
10 MIT/GNU Scheme is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2 of the License, or (at
13 your option) any later version.
14 
15 MIT/GNU Scheme is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18 General Public License for more details.
19 
20 You should have received a copy of the GNU General Public License
21 along with MIT/GNU Scheme; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301,
23 USA.
24 
25 */
26 
27 #ifndef SCM_OSTERM_H
28 #define SCM_OSTERM_H
29 
30 #include "os.h"
31 
32 extern Tchannel arg_terminal (int);
33 
34 extern unsigned int OS_terminal_get_ispeed (Tchannel channel);
35 extern unsigned int OS_terminal_get_ospeed (Tchannel channel);
36 extern void OS_terminal_set_ispeed
37   (Tchannel channel, unsigned int baud);
38 extern void OS_terminal_set_ospeed
39   (Tchannel channel, unsigned int baud);
40 extern unsigned int arg_baud_index (unsigned int argument);
41 extern unsigned int OS_baud_index_to_rate (unsigned int index);
42 extern int OS_baud_rate_to_index (unsigned int rate);
43 extern unsigned int OS_terminal_state_size (void);
44 extern void OS_terminal_get_state (Tchannel channel, void * statep);
45 extern void OS_terminal_set_state (Tchannel channel, void * statep);
46 extern int OS_terminal_cooked_output_p (Tchannel channel);
47 extern void OS_terminal_raw_output (Tchannel channel);
48 extern void OS_terminal_cooked_output (Tchannel channel);
49 extern int OS_terminal_buffered_p (Tchannel channel);
50 extern void OS_terminal_buffered (Tchannel channel);
51 extern void OS_terminal_nonbuffered (Tchannel channel);
52 extern void OS_terminal_flush_input (Tchannel channel);
53 extern void OS_terminal_flush_output (Tchannel channel);
54 extern void OS_terminal_drain_output (Tchannel channel);
55 extern int OS_job_control_p (void);
56 extern int OS_have_ptys_p (void);
57 
58 #endif /* SCM_OSTERM_H */
59