Text user interface

From Wikipedia, the free encyclopedia

TUI short for: Text User Interface or Textual User Interface (and sometimes Terminal User Interface), is a retronym that was coined sometime after the invention of graphical user interfaces, to distinguish them from text based user interfaces. TUIs are different from command-line interfaces in that, like GUIs, they use the entire screen area and do not necessarily provide line-by-line output. However, TUIs only use text and symbols available on a typical text terminal, while GUIs typically use high resolution graphics modes.

Contents

[edit] TUI on ANSI-compatible terminals

Snapshot of a TUI used in a BBS system called Synchronet.
Snapshot of a TUI used in a BBS system called Synchronet.

ANSI standard ANSI X3.64 defines a standard set of escape sequences that can be used to drive terminals to create TUIs (see ANSI escape code.) However, not all terminals follow this standard, and many non-compatible but functionally equivalent sequences exist.

[edit] TUI under MS-DOS

On IBM PCs, the BIOS and MS-DOS system calls provide a way of writing text on the screen, and the ANSI.SYS driver could process standard ANSI escape sequences. However, programmers soon learned that writing data directly to the screen buffer was much faster, as well as being much simpler to program and less error-prone. This change in programming technique resulted in a large number of MS-DOS TUI programs. Some notable programs of this kind were Microsoft Word, MS-DOS Shell, WordPerfect, Norton Commander, Borland Turbo C (which included the conio library), and many others. Most often those programs used blue background for the main screen, with white or yellow characters. Soon mouse input was added, providing additional functionality. Later, the interface became deeply influenced by GUIs, adding pull-down menus and dialog boxes.

[edit] TUI under Win32

Today Microsoft Windows includes Win32 console as a convenient interface for TUI programs, even though a public domain version of conio exists too. However, most console applications under Win32 are command-line tools. One notable full-screen TUI program for Win32 is the file manager FAR Manager (a clone of Norton Commander).

[edit] TUI under Unix-like systems

Snapshot of 'XFdrake', a TUI used in Mandriva Linux to configure the graphical system.
Snapshot of 'XFdrake', a TUI used in Mandriva Linux to configure the graphical system.

In the Unix world, TUIs are often constructed using the terminal control library curses, or ncurses, a mostly compatible library.

The advent of the curses library with Berkeley Unix created a portable and stable API for which to write TUIs. The ability to talk to various text terminal types using the same interfaces led to more widespread use of "visual" Unix programs, which occupied the entire terminal screen instead of using a simple line interface. This can be seen in text editors such as vi, mail clients such as pine or mutt, system management tools such as SMIT or SAM, and web browsers such as lynx or w3m.

In addition, the rise in popularity of Linux brought many former MS-DOS users to a Unix-like platform, which has fostered an MS-DOS influence in many TUIs. The program minicom, for example, is modeled after the popular MS-DOS program Telix. Some other TUI programs, such as the Twin desktop, were ported over.

[edit] See also