Text user interface

From Wikipedia, the free encyclopedia

Jump to: navigation, search

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.

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 and Microsoft Windows

The FreeDOS Edit user interface.

On IBM PCs and compatibles, 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.

Most often those programs used blue background for the main screen, with white or yellow characters, although commonly they had also user color customization. Later, the interface became deeply influenced by GUIs, adding pull-down menus and dialog boxes. Soon mouse input was added (even at graphical resolution in some cases thanks to the ability of the EGA and VGA display adapters to redefine the text character shapes by software), providing additional functionality.

Some notable programs of this kind were Microsoft Word, MS-DOS Shell, WordPerfect, Norton Commander, Borland Turbo C (which included the conio library), Lotus 1-2-3 and many others. Some of these interfaces survive even during the Microsoft Windows 3.x age in the first 1990's; for example, the Microsoft C 6.0 compiler, employed to write true GUI programs under 16-bit MS Windows, still features its own TUI.

Since the beginning, Microsoft Windows includes a console for displaying MS-DOS software. Later versions added the Win32 console as a native interface for command line and TUI programs. The console usually opens in window mode, but it can be switched to full true text mode screen and vice versa by pressing the Alt and Enter keys together.


[edit] TUI under Unix-like systems

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

In Unix-like operating systems, 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. Some applications, such as w3m, as well as older versions of pine and vi use the less-capable termcap library, performing many of the functions associated with curses within the application.

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.

The proprietary Mac OS X text editor BBEdit includes a 'shell worksheet' function that works as a full-screen shell window.

[edit] TUI in embedded systems

Embedded system displaying menu on a LCD screen

Modern embedded systems are capable of displaying TUI on a monitor like personal computers. This functionality is usually implemented using specialized integrated circuits, modules, or using FPGA.

Video circuits or modules are usually controlled using VT100-compatible command set over UART,[citation needed] FPGA designs usually allow direct video memory access.[citation needed]

Optimized TUI written in C language on a low-cost 8 or 16-bit microcontroller requires at least 2kB of code and minimum 10 MIPS of computing power.[citation needed] Almost all modern microcontrollers such as ARM7, Microchip PIC18, Micochip PIC24, MIPS, etc. meet all requirements for TUI implementation.

[edit] Other TUIs

  • The full screen editor of the Commodore 8-bit computers was advanced in its market segment for its time. Users could move the cursor over the entire screen area, entering and editing BASIC program lines, as well as direct mode commands.
  • Apple's Macintosh Programmer's Workshop programming environment included Commando, a TUI shell. It was the inspiration for BBEdit's shell worksheet.

[edit] See also

[edit] Examples of programming libraries

Personal tools