PageRenderTime 21ms CodeModel.GetById 13ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 1ms

/Doc/library/tty.rst

http://unladen-swallow.googlecode.com/
ReStructuredText | 38 lines | 22 code | 16 blank | 0 comment | 0 complexity | ad1b12de51efa082e40642b5981a6602 MD5 | raw file
 1
 2:mod:`tty` --- Terminal control functions
 3=========================================
 4
 5.. module:: tty
 6   :platform: Unix
 7   :synopsis: Utility functions that perform common terminal control operations.
 8.. moduleauthor:: Steen Lumholt
 9.. sectionauthor:: Moshe Zadka <moshez@zadka.site.co.il>
10
11
12The :mod:`tty` module defines functions for putting the tty into cbreak and raw
13modes.
14
15Because it requires the :mod:`termios` module, it will work only on Unix.
16
17The :mod:`tty` module defines the following functions:
18
19
20.. function:: setraw(fd[, when])
21
22   Change the mode of the file descriptor *fd* to raw. If *when* is omitted, it
23   defaults to :const:`termios.TCSAFLUSH`, and is passed to
24   :func:`termios.tcsetattr`.
25
26
27.. function:: setcbreak(fd[, when])
28
29   Change the mode of file descriptor *fd* to cbreak. If *when* is omitted, it
30   defaults to :const:`termios.TCSAFLUSH`, and is passed to
31   :func:`termios.tcsetattr`.
32
33
34.. seealso::
35
36   Module :mod:`termios`
37      Low-level terminal control interface.
38