A text editor is a type of
computer program
A computer program is a sequence or set of instructions in a programming language for a computer to execute. Computer programs are one component of software, which also includes documentation and other intangible components.
A computer program ...
that edits
plain text
In computing, plain text is a loose term for data (e.g. file contents) that represent only characters of readable material but not its graphical representation nor other objects (floating-point numbers, images, etc.). It may also include a limit ...
. Such programs are sometimes known as "notepad" software (e.g.
Windows Notepad
Windows Notepad is a simple text editor for Windows; it creates and edits plain text documents. First released in 1983 to commercialize the computer mouse in MS-DOS, Notepad has been part of every version of Windows ever since.
History
In May ...
). Text editors are provided with
operating system
An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs.
Time-sharing operating systems schedule tasks for efficient use of the system and may also in ...
s and software development packages, and can be used to change files such as
configuration file
In computing, configuration files (commonly known simply as config files) are files used to configure the parameters and initial settings for some computer programs. They are used for user applications, server processes and operating system ...
s, documentation files and
programming language
A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language.
The description of a programming ...
source code
In computing, source code, or simply code, is any collection of code, with or without comments, written using a human-readable programming language, usually as plain text. The source code of a program is specially designed to facilitate the wo ...
.
Plain text and rich text
There are important differences between plain text (created and edited by text editors) and
rich text
Rich may refer to:
Common uses
* Rich, an entity possessing wealth
* Rich, an intense flavor, color, sound, texture, or feeling
** Rich (wine), a descriptor in wine tasting
Places United States
* Rich, Mississippi, an unincorporated comm ...
(such as that created by
word processor
A word processor (WP) is a device or computer program that provides for input, editing, formatting, and output of text, often with some additional features.
Early word processors were stand-alone devices dedicated to the function, but current ...
s or
desktop publishing software
Desktop publishing (DTP) is the creation of documents using page layout software on a personal ("desktop") computer. It was first used almost exclusively for print publications, but now it also assists in the creation of various forms of onlin ...
).
Plain text exclusively consists of character representation. Each character is represented by a fixed-length sequence of one, two, or four bytes, or as a variable-length sequence of one to four bytes, in accordance to specific
character encoding
Character encoding is the process of assigning numbers to Graphics, graphical character (computing), characters, especially the written characters of Language, human language, allowing them to be Data storage, stored, Data communication, transmi ...
conventions, such as
ASCII
ASCII ( ), abbreviated from American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. Because of ...
,
ISO/IEC 2022,
Shift JIS
Shift JIS (Shift Japanese Industrial Standards, also SJIS, MIME name Shift_JIS, known as PCK in Solaris contexts) is a character encoding for the Japanese language, originally developed by a Japanese company called ASCII Corporation in conjuncti ...
,
UTF-8
UTF-8 is a variable-length character encoding used for electronic communication. Defined by the Unicode Standard, the name is derived from ''Unicode'' (or ''Universal Coded Character Set'') ''Transformation Format 8-bit''.
UTF-8 is capable of ...
, or
UTF-16
UTF-16 (16-bit Unicode Transformation Format) is a character encoding capable of encoding all 1,112,064 valid code points of Unicode (in fact this number of code points is dictated by the design of UTF-16). The encoding is variable-length, as cod ...
. These conventions define many printable characters, but also
non-printing characters that control the flow of the text, such as
space
Space is the boundless three-dimensional extent in which objects and events have relative position and direction. In classical physics, physical space is often conceived in three linear dimensions, although modern physicists usually cons ...
,
line break, and
page break
A page break is a marker in an electronic document that tells the document interpreter that the content which follows is part of a new page. A page break causes a form feed to be sent to the printer during spooling of the document to the printer. ...
. Plain text contains no other information about the text itself, not even the character encoding convention employed. Plain text is stored in
text file
A text file (sometimes spelled textfile; an old alternative name is flatfile) is a kind of computer file that is structured as a sequence of lines of electronic text. A text file exists stored as data within a computer file system. In operat ...
s, although text files do not exclusively store plain text. Since the early days of computers, plain text was (once by necessity and now by convention) generally displayed using a
monospace font
A monospaced font, also called a fixed-pitch, fixed-width, or non-proportional font, is a font whose letters and characters each occupy the same amount of horizontal space. This contrasts with variable-width fonts, where the letters and spaci ...
, such that horizontal alignment and columnar formatting were sometimes done using whitespace characters.
Rich text, on the other hand, may contain metadata, character formatting data (e.g.
typeface, size, weight and style), paragraph formatting data (e.g. indentation, alignment, letter and word distribution, and space between lines or other paragraphs), and page specification data (e.g. size, margin and reading direction). Rich text can be very complex. Rich text can be saved in
binary format
A binary file is a computer file that is not a text file. The term "binary file" is often used as a term meaning "non-text file". Many binary file formats contain parts that can be interpreted as text; for example, some computer document file ...
(e.g.
DOC
DOC, Doc, doc or DoC may refer to:
In film and television
* ''Doc'' (2001 TV series), a 2001–2004 PAX series
* ''Doc'' (1975 TV series), a 1975–1976 CBS sitcom
* "D.O.C." (''Lost''), a television episode
* ''Doc'' (film), a 1971 Wester ...
), text files adhering to a
markup language (e.g.
RTF or
HTML
The HyperText Markup Language or HTML is the standard markup language for documents designed to be displayed in a web browser. It can be assisted by technologies such as Cascading Style Sheets (CSS) and scripting languages such as JavaSc ...
), or in a hybrid form of both (e.g.
Office Open XML).
Text editors are intended to open and save text files containing either plain text or anything that can be interpreted as plain text, including the markup for rich text or the markup for something else (e.g.
SVG).
History
Before text editors existed, computer text was punched into
cards with
keypunch
A keypunch is a device for precisely punching holes into stiff paper cards at specific locations as determined by keys struck by a human operator. Other devices included here for that same function include the gang punch, the pantograph punch, ...
machines. Physical boxes of these thin cardboard cards were then inserted into a
card reader
A card reader is a data input device that reads data from a card-shaped storage medium. The first were punched card readers, which read the paper or cardboard punched cards that were used during the first several decades of the computer industry ...
.
Magnetic tape
Magnetic tape is a medium for magnetic storage made of a thin, magnetizable coating on a long, narrow strip of plastic film. It was developed in Germany in 1928, based on the earlier magnetic wire recording from Denmark. Devices that use magne ...
,
drum
The drum is a member of the percussion group of musical instruments. In the Hornbostel-Sachs classification system, it is a membranophone. Drums consist of at least one membrane, called a drumhead or drum skin, that is stretched over a she ...
and
disk
Disk or disc may refer to:
* Disk (mathematics), a geometric shape
* Disk storage
Music
* Disc (band), an American experimental music band
* ''Disk'' (album), a 1995 EP by Moby
Other uses
* Disk (functional analysis), a subset of a vector sp ...
card image Card image is a traditional term for a character string, usually 80 characters in length, that was, or could be, contained on a single punched card. IBM cards were 80 characters in length. UNIVAC cards were 90 characters in length. Card image files ...
files created from such card decks often had no line-separation characters at all, and assumed fixed-length 80- or 90-character records. An alternative to cards was
Punched tape
Five- and eight-hole punched paper tape
Paper tape reader on the Harwell computer with a small piece of five-hole tape connected in a circle – creating a physical program loop
Punched tape or perforated paper tape is a form of data storage ...
. It could be created by some
teleprinter
A teleprinter (teletypewriter, teletype or TTY) is an electromechanical device that can be used to send and receive typed messages through various communications channels, in both point-to-point and point-to-multipoint configurations. Init ...
s (such as the Teletype), which used special characters to indicate ends of records. Some early operating systems included batch text editors, either integrated with language processors or as separate utility programs; one early example was the ability to edit
SQUOZE
SQUOZE (abbreviated as SQZ) is a memory-efficient representation of a combined source and relocatable object program file with a symbol table on punched cards which was introduced in 1958 with the SCAT assembler on the SHARE Operating Syste ...
source files for SCAT in
SHARE Operating System
The SHARE Operating System (SOS) is an operating system introduced in 1959 by the SHARE user group. It is an improvement on the General Motors GM-NAA I/O operating system, the first operating system for the IBM 704. The main objective was to im ...
.
The first interactive text editors were
"line editors" oriented to teleprinter- or
typewriter
A typewriter is a mechanical or electromechanical machine for typing characters. Typically, a typewriter has an array of keys, and each one causes a different single character to be produced on paper by striking an inked ribbon selectivel ...
-style terminals without displays. Commands (often a single keystroke) effected edits to a file at an imaginary insertion point called the "cursor". Edits were verified by typing a command to print a small section of the file, and periodically by printing the entire file. In some line editors, the cursor could be moved by commands that specified the line number in the file, text
strings
String or strings may refer to:
*String (structure), a long flexible structure made from threads twisted together, which is used to tie, bind, or hang other objects
Arts, entertainment, and media Films
* ''Strings'' (1991 film), a Canadian anim ...
(context) for which to search, and eventually
regular expression
A regular expression (shortened as regex or regexp; sometimes referred to as rational expression) is a sequence of characters that specifies a search pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
s. Line editors were major improvements over keypunching. Some line editors could be used by keypunch; editing commands could be taken from a deck of cards and applied to a specified file. Some common line editors supported a "verify" mode in which change commands displayed the altered lines.
When
computer terminal
A computer terminal is an electronic or electromechanical hardware device that can be used for entering data into, and transcribing data from, a computer or a computing system. The teletype was an example of an early-day hard-copy terminal and ...
s with video screens became available, screen-based text editors (sometimes called just "screen editors") became common. One of the earliest full-screen editors was
O26, which was written for the operator console of the
CDC 6000 series The CDC 6000 series is a discontinued family of mainframe computers manufactured by Control Data Corporation in the 1960s. It consisted of the CDC 6200, CDC 6300, CDC 6400, CDC 6500, CDC 6600 and CDC 6700 computers, which were all extremely rapid ...
computers in 1967. Another early full-screen editor was
vi. Written in the 1970s, it is still a standard editor on
Unix
Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and ot ...
and
Linux
Linux ( or ) is a family of open-source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically packaged as a Linux distribution, which ...
operating systems. Also written in the 1970s was the
UCSD Pascal
UCSD Pascal is a Pascal programming language system that runs on the UCSD p-System, a portable, highly machine-independent operating system. UCSD Pascal was first released in 1977. It was developed at the University of California, San Diego (U ...
Screen Oriented Editor, which was optimized both for indented source code and general text.
Emacs, one of the first
free and open-source software projects, is another early full-screen or real-time editor, one that was
ported
In software engineering, porting is the process of adapting software for the purpose of achieving some form of execution in a computing environment that is different from the one that a given program (meant for such execution) was originally desi ...
to many systems. A full-screen editor's ease-of-use and speed (compared to the line-based editors) motivated many early purchases of video terminals.
The core data structure in a text editor is the one that manages the string (sequence of characters) or list of
records that represents the current state of the file being edited.
While the former could be stored in a single long consecutive
array
An array is a systematic arrangement of similar objects, usually in rows and columns.
Things called an array include:
{{TOC right
Music
* In twelve-tone and serial composition, the presentation of simultaneous twelve-tone sets such that the ...
of characters,
the desire for text editors that could more quickly insert text, delete text, and undo/redo previous edits led to the development of more complicated sequence data structures.
A typical text editor uses a
gap buffer
A gap buffer in computer science is a dynamic array that allows efficient insertion and deletion operations clustered near the same location. Gap buffers are especially common in text editors, where most changes to the text occur at or near the cur ...
, a
linked list of lines (as in
PaperClip
A paper clip (or paperclip) is a tool used to hold sheets of paper together, usually made of steel wire bent to a looped shape (though some are covered in plastic). Most paper clips are variations of the ''Gem'' type introduced in the 1890s or e ...
), a
piece table In computing, a piece table is a data structure typically used to represent a text document while it is edited in a text editor. Initially a reference (or 'span') to the whole of the original file is created, which represents the as yet unchanged ...
, or a
rope
A rope is a group of yarns, plies, fibres, or strands that are twisted or braided together into a larger and stronger form. Ropes have tensile strength and so can be used for dragging and lifting. Rope is thicker and stronger than similar ...
, as its sequence data structure.
Types of text editors
Some text editors are small and simple, while others offer broad and complex functions. For example,
Unix
Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and ot ...
and Unix-like operating systems have the
pico
Pico may refer to:
Places The Moon
* Mons Pico, a lunar mountain in the northern part of the Mare Imbrium basin
Portugal
* Pico, a civil parish in the municipality of Vila Verde
* Pico da Pedra, a civil parish in the municipality of Ribeir ...
editor (or a variant), but many also include the
vi and Emacs editors.
Microsoft Windows
Windows is a group of several proprietary graphical operating system families developed and marketed by Microsoft. Each family caters to a certain sector of the computing industry. For example, Windows NT for consumers, Windows Server for serv ...
systems come with the simple
Notepad
A notebook (also known as a notepad, writing pad, drawing pad, or legal pad) is a book or stack of paper pages that are often ruled and used for purposes such as note-taking, journaling or other writing, drawing, or scrapbooking.
History
...
, though many people—especially programmers—prefer other
editors
Editing is the process of selecting and preparing written, photographic, visual, audible, or cinematic material used by a person or an entity to convey a message or information. The editing process can involve correction, condensation, or ...
with more features. Under
Apple Macintosh
The Mac (known as Macintosh until 1999) is a family of personal computers designed and marketed by Apple Inc., Apple Inc. Macs are known for their ease of use and minimalist designs, and are popular among students, creative professionals, and ...
's
classic Mac OS there was the native
TeachText
The TeachText application is a simple text editor made by Apple Computer and included with System 7.1 and earlier. It was created by Apple programmer Bryan Stearns with later versions created by Stearns and Francis Stanbach. TeachText was one ...
later replaced by
SimpleText
SimpleText is the native text editor for the Apple classic Mac OS. SimpleText allows text editing and text formatting (underline, italic, bold, etc.), fonts, and sizes. It was developed to integrate the features included in the different version ...
in 1994, which was replaced in
Mac OS X
macOS (; previously OS X and originally Mac OS X) is a Unix operating system developed and marketed by Apple Inc. since 2001. It is the primary operating system for Apple's Mac computers. Within the market of desktop and la ...
by
TextEdit
TextEdit is an open-source word processor and text editor, first featured in NeXT's NeXTSTEP and OPENSTEP. It is now distributed with macOS since Apple Inc.'s acquisition of NeXT, and available as a GNUstep application for other Unix-like ope ...
, which combines features of a text editor with those typical of a word processor such as rulers, margins and multiple font selection. These features are not available simultaneously, but must be switched by user command, or through the program automatically determining the
file type
A file format is a standard way that information is encoded for storage in a computer file. It specifies how bits are used to encode information in a digital storage medium. File formats may be either proprietary or free.
Some file format ...
.
Most word processors can read and write files in plain text format, allowing them to open files saved from text editors. Saving these files from a word processor, however, requires ensuring the file is written in
plain text
In computing, plain text is a loose term for data (e.g. file contents) that represent only characters of readable material but not its graphical representation nor other objects (floating-point numbers, images, etc.). It may also include a limit ...
format, and that any
text encoding
Character encoding is the process of assigning numbers to graphical characters, especially the written characters of human language, allowing them to be stored, transmitted, and transformed using digital computers. The numerical values that ...
or
BOM settings won't obscure the file for its intended use. Non-
WYSIWYG
In computing, WYSIWYG ( ), an acronym for What You See Is What You Get, is a system in which editing software allows content to be edited in a form that resembles its appearance when printed or displayed as a finished product, such as a printed d ...
word processors, such as
WordStar
WordStar is a word processor application for microcomputers. It was published by MicroPro International and originally written for the CP/M-80 operating system, and later written also for MS-DOS and other 16-bit PC OSes. Rob Barnaby was the so ...
, are more easily pressed into service as text editors, and in fact were commonly used as such during the 1980s. The default
file format
A file format is a standard way that information is encoded for storage in a computer file. It specifies how bits are used to encode information in a digital storage medium. File formats may be either proprietary or free.
Some file formats ...
of these word processors often resembles a markup language, with the basic format being plain text and visual formatting achieved using non-printing
control characters or
escape sequence
In computer science, an escape sequence is a combination of characters that has a meaning other than the literal characters contained therein; it is marked by one or more preceding (and possibly terminating) characters.
Examples
* In C and ma ...
s. Later word processors like
Microsoft Word
Microsoft Word is a word processing software developed by Microsoft. It was first released on October 25, 1983, under the name ''Multi-Tool Word'' for Xenix systems. Subsequent versions were later written for several other platforms includin ...
store their files in a
binary format
A binary file is a computer file that is not a text file. The term "binary file" is often used as a term meaning "non-text file". Many binary file formats contain parts that can be interpreted as text; for example, some computer document file ...
and are almost never used to edit plain text files.
Some text editors can
edit unusually large files such as
log files
In computing, logging is the act of keeping a log of events that occur in a computer system, such as problems, errors or just information on current operations. These events may occur in the operating system or in other software. A message or l ...
or an entire
database
In computing, a database is an organized collection of data stored and accessed electronically. Small databases can be stored on a file system, while large databases are hosted on computer clusters or cloud storage. The design of databases sp ...
placed in a single file. Simpler text editors may just read files into the computer's main
memory
Memory is the faculty of the mind by which data or information is encoded, stored, and retrieved when needed. It is the retention of information over time for the purpose of influencing future action. If past events could not be remembered, ...
. With larger files, this may be a slow process, and the entire file may not fit. Some text editors do not let the user start editing until this read-in is complete. Editing performance also often suffers in nonspecialized editors, with the editor taking seconds or even minutes to respond to keystrokes or navigation commands. Specialized editors have optimizations such as only storing the visible portion of large files in memory, improving editing performance.
Some editors are programmable, meaning, e.g., they can be customized for specific uses. With a programmable editor it is easy to automate repetitive tasks or, add new functionality or even implement a new application within the framework of the editor. One common motive for customizing is to make a text editor use the commands of another text editor with which the user is more familiar, or to duplicate missing functionality the user has come to depend on. Software developers often use editor customizations tailored to the programming language or development environment they are working in. The programmability of some text editors is limited to enhancing the core editing functionality of the program, but
Emacs can be extended far beyond editing text files—for web browsing, reading email, online chat, managing files or playing games and is often thought of as a Lisp execution environment with a
Text User Interface
In computing, text-based user interfaces (TUI) (alternately terminal user interfaces, to reflect a dependence upon the properties of computer terminals and not just text), is a retronym describing a type of user interface (UI) common as an ear ...
. Emacs can even be programmed to emulate
Vi, its rival in the traditional
editor wars of
Unix culture.
An important group of programmable editors uses
REXX as a scripting language. These "orthodox editors" contain a "command line" into which commands and macros can be typed and text lines into which line commands and macros can be typed. Most such editors are derivatives of
ISPF/PDF EDIT
Edit may refer to:
Concepts
* an action that is part of an editing process (including of images, video, and film)
* a particular version that is the result of editing, especially of film (for example, fan edit), or music (for example, radi ...
or of
XEDIT
XEDIT is a visual editor for VM/CMS using block mode IBM 3270 terminals. (Line-mode terminals are also supported.)
XEDIT is much more line-oriented than modern PC and Unix editors. For example, XEDIT supports automatic line numbers, and ma ...
, IBM's flagship editor for
VM/SP
VM (often: VM/CMS) is a family of IBM virtual machine operating systems used on IBM mainframes System/370, System/390, zSeries, System z and compatible systems, including the Hercules emulator for personal computers.
The following version ...
through
z/VM
z/VM is the current version in IBM's VM family of virtual machine operating systems. z/VM was first released in October 2000 and remains in active use and development . It is directly based on technology and concepts dating back to the 1960s, wi ...
. Among them are
THE
''The'' () is a grammatical article in English, denoting persons or things already mentioned, under discussion, implied or otherwise presumed familiar to listeners, readers, or speakers. It is the definite article in English. ''The'' is the ...
,
KEDIT
XEDIT is a visual editor for VM/CMS using block mode IBM 3270 terminals. (Line-mode terminals are also supported.)
XEDIT is much more line-oriented than modern PC and Unix editors. For example, XEDIT supports automatic line numbers, and ma ...
, X2, Uni-edit, and
SEDIT.
A text editor written or customized for a specific use can determine what the user is editing and assist the user, often by
completing programming terms and showing
tooltip
The tooltip, also known as infotip or hint, is a common graphical user interface (GUI) element in which, when hovering over a screen element or component, a text box displays information about that element, such as a description of a button's f ...
s with relevant documentation. Many text editors for software developers include source code
syntax highlighting
Syntax highlighting is a feature of text editors that are used for programming, scripting, or markup languages, such as HTML. The feature displays text, especially source code, in different colours and fonts according to the category of terms ...
and automatic
indentation
__FORCETOC__
In the written form of many languages, an indentation or indent is an empty space at the beginning of a line to signal the start of a new paragraph. Many computer languages have adopted this technique to designate "paragraphs" or o ...
to make programs easier to read and write. Programming editors often let the user select the name of an
include file,
function
Function or functionality may refer to:
Computing
* Function key, a type of key on computer keyboards
* Function model, a structured representation of processes in a system
* Function object or functor or functionoid, a concept of object-oriente ...
or
variable
Variable may refer to:
* Variable (computer science), a symbolic name associated with a value and whose associated value may be changed
* Variable (mathematics), a symbol that represents a quantity in a mathematical expression, as used in many ...
, then jump to its definition. Some also allow for easy navigation back to the original section of code by storing the initial cursor location or by displaying the requested definition in a
popup window Popup, Pop up or pop-up may refer to:
Arts, entertainment, and media
* ''Pop Up'' (album), a 2007 album by Yelle
* ''Pop Up'' (video game), a video game also known as ''Bumpy''
* Pop-up book, a book with three-dimensional pages
Computing
* Po ...
or temporary buffer. Some editors implement this ability themselves, but often an auxiliary utility like
ctags
Ctags is a programming tool that generates an index (or tag) file of names found in source and header files of various programming languages to aid code comprehension. Depending on the language, functions, variables, class members, macros a ...
is used to locate the definitions.
Typical features
* Find and replace – Text editors provide extensive facilities for searching and replacing strings of text, either individually, or groups of files in opened tabs or a selected folder. Advanced editors can use
regular expression
A regular expression (shortened as regex or regexp; sometimes referred to as rational expression) is a sequence of characters that specifies a search pattern in text. Usually such patterns are used by string-searching algorithms for "find" ...
s to search and edit text or code. Additional features may include optional
case sensitivity In computers, case sensitivity defines whether uppercase and lowercase letters are treated as distinct (case-sensitive) or equivalent (case-insensitive). For instance, when users interested in learning about dogs search an e-book, "dog" and "Dog" a ...
, a history of search terms for quick recall and
autocompletion
Autocomplete, or word completion, is a feature in which an application predicts the rest of a word a user is typing. In Android and iOS smartphones, this is called predictive text. In graphical user interfaces, users can typically press the tab ...
, and listing multiple results in one place.
*
Cut, copy, and paste
In human–computer interaction and user interface design, cut, copy, and paste are related commands that offer an interprocess communication technique for transferring data through a computer's user interface. The ''cut'' command removes t ...
– most text editors provide methods to duplicate and move text within the file, or between files.
* Ability to handle
UTF-8
UTF-8 is a variable-length character encoding used for electronic communication. Defined by the Unicode Standard, the name is derived from ''Unicode'' (or ''Universal Coded Character Set'') ''Transformation Format 8-bit''.
UTF-8 is capable of ...
encoded text.
*
Text formatting
Typesetting is the composition of text by means of arranging physical ''type'' (or ''sort'') in mechanical systems or ''glyphs'' in digital systems representing '' characters'' (letters and other symbols).Dictionary.com Unabridged. Random H ...
– Text editors often provide basic visual formatting features like
line wrap
Line breaking, also known as word wrapping, is breaking a section of text into lines so that it will fit into the available width of a page, window or other display area. In text display, line wrap is continuing on a new line when a line is ful ...
,
auto-indentation,
bullet list formatting using
ASCII
ASCII ( ), abbreviated from American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. Because of ...
characters,
comment formatting,
syntax highlighting
Syntax highlighting is a feature of text editors that are used for programming, scripting, or markup languages, such as HTML. The feature displays text, especially source code, in different colours and fonts according to the category of terms ...
and so on. These are typically only for display and do not insert formatting codes into the file itself.
*
Undo and redo – As with word processors, text editors provide a way to undo and redo the last edit, or more. Often—especially with older text editors—there is only one level of edit history remembered and successively issuing the undo command will only "toggle" the last change. Modern or more complex editors usually provide a multiple-level history such that issuing the undo command repeatedly will revert the document to successively older edits. A separate redo command will cycle the edits "forward" toward the most recent changes. The number of changes remembered depends upon the editor and is often configurable by the user.
* Ability to jump to a specified line number.
Advanced features
* Macro or procedure definition: to define new commands or features as combinations of prior commands or other macros, perhaps with passed parameters, or with nesting of macros.
* Profiles to retain options set by the user between editing session.
* Profile macros with names specified in, e.g., environment, profile, executed automatically at the beginning of an edit session or when opening a new file.
* Multi-file editing: the ability to edit multiple files during an edit-session, perhaps remembering the current-line cursor of each file, to insert repeated text into each file, copy or move text among files,
compare files side-by-side (perhaps with a tiled
multiple-document interface
A multiple-document interface (MDI) is a graphical user interface in which multiple windows reside under a single parent window. Such systems often allow child windows to embed other windows inside them as well, creating complex nested hierarchies ...
), etc.
* Multi-view editors: the ability to display multiple views of the same file, with independent cursor tracking, synchronizing changes among the windows but providing the same facilities as are available for independent files.
* Collapse/expand, also called
folding
Fold, folding or foldable may refer to:
Arts, entertainment, and media
* ''Fold'' (album), the debut release by Australian rock band Epicure
* Fold (poker), in the game of poker, to discard one's hand and forfeit interest in the current pot
*Abov ...
: the ability to temporarily exclude sections of the text from view. This may either be based on a range of line numbers or on some syntactic element, e.g., excluding everything between a BEGIN; and the matching END;.
* Column-based editing; the ability to alter or insert data at a particular column, or to shift data to specific columns.
*
Data transformation
In computing, data transformation is the process of converting data from one format or structure into another format or structure. It is a fundamental aspect of most data integrationCIO.com. Agile Comes to Data Integration. Retrieved from: htt ...
– Reading or merging the contents of another text file into the file currently being edited. Some text editors provide a way to insert the output of a command issued to the operating system's
shell
Shell may refer to:
Architecture and design
* Shell (structure), a thin structure
** Concrete shell, a thin shell of concrete, usually with no interior columns or exterior buttresses
** Thin-shell structure
Science Biology
* Seashell, a hard o ...
. Also, a case-shifting feature could translate to lowercase or uppercase.
*
Filtering – Some advanced text editors allow the editor to send all or sections of the file being edited to another utility and read the result back into the file in place of the lines being "filtered". This, for example, is useful for sorting a series of lines alphabetically or numerically, doing mathematical computations, indenting
source code
In computing, source code, or simply code, is any collection of code, with or without comments, written using a human-readable programming language, usually as plain text. The source code of a program is specially designed to facilitate the wo ...
, and so on.
*
Syntax highlighting
Syntax highlighting is a feature of text editors that are used for programming, scripting, or markup languages, such as HTML. The feature displays text, especially source code, in different colours and fonts according to the category of terms ...
– contextually highlights
source code
In computing, source code, or simply code, is any collection of code, with or without comments, written using a human-readable programming language, usually as plain text. The source code of a program is specially designed to facilitate the wo ...
,
markup languages,
config file
In computing, configuration files (commonly known simply as config files) are files used to configure the parameters and initial settings for some computer programs. They are used for user applications, server processes and operating system se ...
s and other text that appears in an organized or predictable format. Editors generally allow users to customize the colors or styles used for each language element. Some text editors also allow users to install and use
theme
Theme or themes may refer to:
* Theme (arts), the unifying subject or idea of the type of visual work
* Theme (Byzantine district), an administrative district in the Byzantine Empire governed by a Strategos
* Theme (computing), a custom graphical ...
s to change the
look and feel
In software design, the look and feel of a graphical user interface comprises aspects of its design, including elements such as colors, shapes, layout, and typefaces (the "look"), as well as the behavior of dynamic elements such as buttons, boxe ...
of the editor's entire
user interface
In the industrial design field of human–computer interaction, a user interface (UI) is the space where interactions between humans and machines occur. The goal of this interaction is to allow effective operation and control of the machine f ...
.
* Syntax-oriented editors - some editors have support for the syntax of one or more languages, and allow operations in terms of syntactical unit, e.g., insert a new WHEN clause in a SELECT statement.
*
Extensibility - a text editor intended for use by programmers must provide some
plugin mechanism, or be
scriptable, so a programmer can customize the editor with features needed to manage individual software projects, customize functionality or
key bindings
computing, a keyboard shortcut also known as hotkey is a series of one or several keys to quickly invoke a software program or perform a preprogrammed action. This action may be part of the standard functionality of the operating system or ...
for specific
programming language
A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language.
The description of a programming ...
s or
version control
In software engineering, version control (also known as revision control, source control, or source code management) is a class of systems responsible for managing changes to computer programs, documents, large web sites, or other collections o ...
systems, or conform to specific
coding styles.
*
Cursor
Cursor may refer to:
* Cursor (user interface), an indicator used to show the current position for user interaction on a computer monitor or other display device
* Cursor (databases), a control structure that enables traversal over the records in ...
navigation may vary across text editors. For example, pressing
End twice may navigate to the end of a
wrapped line after one press navigated to the end of an on-screen row of text.
Block-oriented terminal
A computer terminal is an electronic or electromechanical hardware device that can be used for entering data into, and transcribing data from, a computer or a computing system. The teletype was an example of an early-day hard-copy terminal and ...
s typically have dedicated cursor movement keys, as do keyboards on personal computers.
*
Command line
A command-line interpreter or command-line processor uses a command-line interface (CLI) to receive commands from a user in the form of lines of text. This provides a means of setting parameters for the environment, invoking executables and pro ...
- some editors, e.g.,
ISPF
In computing, Interactive System Productivity Facility (ISPF) is a software product for many historic IBM mainframe operating systems and currently the z/OS and z/VM operating systems that run on IBM mainframes. It includes a screen editor, the us ...
,
XEDIT
XEDIT is a visual editor for VM/CMS using block mode IBM 3270 terminals. (Line-mode terminals are also supported.)
XEDIT is much more line-oriented than modern PC and Unix editors. For example, XEDIT supports automatic line numbers, and ma ...
, have a dedicated field on the screen for entering commands as opposed to text. Depending on the editor, the user may have to use cursor keys to switch between the command and text fields or the editor may interpret, e.g., specific function keys , as requests to switch.
* Line commands, also known as prefix commands or sequence commands - Some editors treat a file as an array of text lines with associated line numbers or sequence numbers, and have a distinct line number field for each text field. A line command is a string that the user types into a line number field and that the editor recognizes as a command operating on that specific line or block of lines, e.g., LC to translate a line to lower case, ))3 to shift a block right three columns. Some editors also support line macros, also known as prefix macros or sequence macros. Despite the name ''prefix command'', some editors allow the sequence field to appear after the text field.
Specialised editors
Some editors include special features and extra functions, for instance,
*
Source code editor
A source-code editor is a text editor program designed specifically for editing source code of computer programs. It may be a standalone application or it may be built into an integrated development environment (IDE) or web browser. Source-code ed ...
s are text editors with additional functionality to facilitate the production of source code. These often feature user-programmable syntax highlighting and code navigation functions as well as coding tools or keyboard
macros similar to an HTML editor.
*
Folding editor
Code or text folding, or less commonly holophrasting, is a feature of some graphical user interfaces that allows the user to selectively hide ("fold") or display ("unfold") parts of a document. This allows the user to manage large amounts of text ...
s. This subclass includes so-called "orthodox editors" that are derivatives of Xedit. Editors that implement folding without programing-specific features are usually called outliners (see below).
*
IDEs (integrated development environments) are designed to manage and streamline large programming projects. They are usually only used for programming as they contain many features unnecessary for simple text editing.
*
World Wide Web
The World Wide Web (WWW), commonly known as the Web, is an information system enabling documents and other web resources to be accessed over the Internet.
Documents and downloadable media are made available to the network through web se ...
authors are offered a variety of
HTML editor
An HTML editor is a program for editing HTML, the markup of a web page. Although the HTML markup in a web page can be controlled with any text editor, specialized HTML editors can offer convenience and added functionality. For example, many HT ...
s dedicated to the task of creating
web pages. These include:
Dreamweaver
Adobe Dreamweaver is a proprietary web development tool from Adobe Inc. It was created by Macromedia in 1997 and developed by them until Macromedia was acquired by Adobe Systems in 2005.
Adobe Dreamweaver is available for the macOS and Windows ...
,
KompoZer
Mozilla Composer is the free and open-source HTML editor and web authoring module of the Mozilla Application Suite (the predecessor to SeaMonkey). It is used to create and to edit web pages, e-mail, and text documents easily. It is compatible w ...
and
E Text Editor
E, or e, is the fifth letter and the second vowel letter in the Latin alphabet, used in the modern English alphabet, the alphabets of other western European languages and others worldwide. Its name in English is ''e'' (pronounced ); plura ...
. Many offer the option of viewing a work in progress on a built-in
HTML rendering engine or standard
web browser
A web browser is application software for accessing websites. When a user requests a web page from a particular website, the browser retrieves its files from a web server and then displays the page on the user's screen. Browsers are used o ...
.
* Most
web development is done in a
dynamic programming language
In computer science, a dynamic programming language is a class of high-level programming languages, which at runtime execute many common programming behaviours that static programming languages perform during compilation. These behaviors co ...
such as
Ruby
A ruby is a pinkish red to blood-red colored gemstone, a variety of the mineral corundum ( aluminium oxide). Ruby is one of the most popular traditional jewelry gems and is very durable. Other varieties of gem-quality corundum are called ...
or
PHP
PHP is a general-purpose scripting language geared toward web development. It was originally created by Danish-Canadian programmer Rasmus Lerdorf in 1993 and released in 1995. The PHP reference implementation is now produced by The PHP Group. ...
using a source code editor or IDE. The HTML delivered by all but the simplest static web sites is stored as individual
template file
A template processor (also known as a template engine or template parser) is software designed to combine templates with a data model to produce result documents.
The language that the templates are written in is known as a template language ...
s that are assembled by the software controlling the site and do not compose a complete HTML document.
* Mathematicians, physicists, and computer scientists often produce articles and books using
TeX
Tex may refer to:
People and fictional characters
* Tex (nickname), a list of people and fictional characters with the nickname
* Joe Tex (1933–1982), stage name of American soul singer Joseph Arrington Jr.
Entertainment
* ''Tex'', the Italian ...
or
LaTeX
Latex is an emulsion (stable dispersion) of polymer microparticles in water. Latexes are found in nature, but synthetic latexes are common as well.
In nature, latex is found as a milky fluid found in 10% of all flowering plants (angiosperms ...
in plain text files. Such documents are often produced by a standard text editor, but some people use specialized
TeX editors
Tex may refer to:
People and fictional characters
* Tex (nickname), a list of people and fictional characters with the nickname
* Joe Tex (1933–1982), stage name of American soul singer Joseph Arrington Jr.
Entertainment
* ''Tex'', the Italian ...
.
*
Outliner
An outliner (or outline processor) is a specialized type of text editor (word processor) used to create and edit outlines, which are text files which have a tree structure, for organization. Textual information is contained in discrete sections c ...
s. Also called tree-based editors, because they combine a hierarchical outline tree with a text editor. Folding (see above) can be considered a specialized form of outlining.
*
Collaborative editors allow multiple users to work on the same document simultaneously from remote locations over a network. The changes made by individual users are tracked and merged into the document automatically to eliminate the possibility of conflicting edits. These editors also typically include an
online chat
Online chat may refer to any kind of communication over the Internet that offers a real-time transmission of text messages from sender to receiver. Chat messages are generally short in order to enable other participants to respond quickly. Ther ...
component for discussion among editors.
*
Distraction-free editors provide a
minimalistic interface with the purpose of isolating the writer from the rest of the applications and operating system, thus being able to focus on the writing without distractions from interface elements like a
toolbar
The toolbar, also called a bar or standard toolbar (originally known as ribbon) is a graphical control element on which on-screen icons can be used. A toolbar often allows for quick access to functions that are commonly used in the program. Some ...
or
notification area
A taskbar is an element of a graphical user interface which has various purposes. It typically shows which programs are currently running.
The specific design and layout of the taskbar varies between individual operating systems, but generally as ...
.
Programmable editors can usually be enhanced to perform any or all of these functions, but simpler editors focus on just one, or, like
gPHPedit
gPHPedit is a discontinued UTF-8-compatible IDE for web development in PHP using the GNOME desktop environment. gPHPedit is built using Scintilla. It was originally written by Andy Jeffries, and was maintained by Anoop John. It is similar to ...
, are targeted at a single programming language.
See also
*
List of text editors
The following is a list of notable text editors.
Graphical and text user interface
The following editors can either be used with a graphical user interface or a text user interface.
Graphical user interface
Text user interface
Sys ...
*
Comparison of text editors
This article provides basic comparisons for notable text editors. More feature details for text editors are available from the '' Category of text editor features'' and from the individual products' articles. This article may not be up-to-date or n ...
*
Editor war
The editor war is the rivalry between users of the Emacs and vi (now usually Vim, or more recently Neovim) text editors. The rivalry has become an enduring part of hacker culture and the free software community.
The Emacs versus vi debate was o ...
*
File viewer
A file viewer is a Software application that represents the data stored in a computer file in a human-readable form. The file contents are formatted in a meaningful way and then displayed on the screen or printed out. Also, they may be read alo ...
– does not change file, faster for very large files and can be more secure
*
Hex editor
A hex editor (or ''binary file editor'' or ''byte editor'') is a computer program that allows for manipulation of the fundamental binary data that constitutes a computer file. The name 'hex' comes from 'hexadecimal', a standard numerical format f ...
– used for editing binary files
*
Stream editor – used for non-interactive editing
Notes
References
External links
Orthodox Editors as a Special Class of Advanced Editors discusses Xedit and its clones with an emphasis of folding capabilities and programmability
{{Authority control
Technical communication tools