Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Computer terminal
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
====Text terminals{{anchor|Text terminal}}==== [[File:Stdstreams-notitle.svg|thumb|A typical text terminal produces input and displays output and errors]] [[File:Nano 1.2.5.png|thumb|200px|right|[[Nano (text editor)|Nano]] text editor running in the [[xterm]] terminal emulator]] A '''text terminal''', or often just ''terminal'' (sometimes ''text console'') is a serial computer interface for text entry and display. Information is presented as [[text mode|an array of pre-selected formed characters]]. When such devices use a video display such as a [[cathode-ray tube]], they are called a "[[video display unit]]" or "visual display unit" (VDU) or "video display terminal" (VDT). The [[system console]] is often<ref>Some computers have consoles containing only buttons, dials, lights and switches.</ref> a text terminal used to operate a computer. Modern computers have a built-in keyboard and display for the console. Some Unix-like operating systems such as Linux and [[FreeBSD]] have virtual consoles to provide several text terminals on a single computer. The fundamental type of application running on a text terminal is a [[command-line interpreter]] or ''[[shell (computing)|shell]]'', which [[Command-line interface#Command prompt|prompts]] for commands from the user and executes each command after a press of {{keypress|Return}}.<ref>As opposed to the {{keypress|Enter}} key used on buffered text terminals and PCs.</ref> This includes [[Unix shell]]s and some [[interactive programming]] environments. In a shell, most of the commands are small applications themselves. Another important application type is that of the [[text editor]]. A text editor typically occupies the full area of display, displays one or more text documents, and allows the user to edit the documents. The text editor has, for many uses, been replaced by the [[word processor]], which usually provides rich formatting features that the text editor lacks. The first word processors used text to communicate the structure of the document, but later word processors operate in a graphical environment and provide a [[WYSIWYG]] simulation of the formatted output. However, text editors are still used for documents containing [[Markup language|markup]] such as [[DocBook]] or [[LaTeX]]. Programs such as [[Telix]] and [[Minicom]] control a [[modem]] and the local terminal to let the user interact with remote servers. On the [[Internet]], [[telnet]] and [[Secure Shell|ssh]] work similarly. In the simplest form, a text terminal is like a file. Writing to the file displays the text and reading from the file produces what the user enters. In Unix-like operating systems, there are several [[character special file]]s that correspond to available text terminals. For other operations, there are special [[escape sequence]]s, [[control character]]s and <code>termios</code> [[system call|functions]] that a program can use, most easily via a library such as ''[[ncurses]]''. For more complex operations, the programs can use terminal specific ''[[ioctl]]'' system calls. For an application, the simplest way to use a terminal is to simply write and read text strings to and from it sequentially. The output text is scrolled, so that only the last several lines (typically 24) are visible. [[Unix]] systems typically [[Data buffer|buffer]] the input text until the Enter key is pressed, so the application receives a ready string of text. In this mode, the application need not know much about the terminal. For many interactive applications this is not sufficient. One of the common enhancements is ''command-line editing'' (assisted with such libraries as [[GNU Readline|readline]]); it also may give access to command history. This is very helpful for various interactive command-line interpreters. Even more advanced interactivity is provided with ''full-screen'' applications. Those applications completely control the screen layout; also they respond to key-pressing immediately. This mode is very useful for text editors, [[file manager]]s and [[web browser]]s. In addition, such programs control the color and brightness of text on the screen, and decorate it with underline, blinking and special characters (e.g. [[box-drawing character]]s). To achieve all this, the application must deal not only with plain text strings, but also with control characters and escape sequences, which allow moving the [[cursor (user interface)|cursor]] to an arbitrary position, clearing portions of the screen, changing colors and displaying special characters, and also responding to function keys. The great problem here is that there are many different terminals and terminal emulators, each with its own set of escape sequences. In order to overcome this, special [[library (computing)|libraries]] (such as [[curses (programming library)|curses]]) have been created, together with terminal description databases, such as Termcap and Terminfo.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)