*** Welcome to piglix ***

Formatted text


Formatted text, styled text, or rich text, as opposed to plain text, has styling information beyond the minimum of semantic elements: colours, styles (boldface, italic), sizes, and special features (such as hyperlinks).

Formatted text cannot rightly be identified with binary files or be distinct from ASCII text. This is because formatted text is not necessarily binary, it may be text-only, such as HTML, RTF or enriched text files, and it may be ASCII-only. Conversely, a plain text file may be non-ASCII (in an encoding such as Unicode UTF-8). Text-only formatted text is achieved by markup which too is textual, while some editors of formatted text like Microsoft Word save in a binary format.

Formatted text has its genesis in the pre-computer use of underscoring to embolden passages in typewritten manuscripts. In the first interactive systems of early computer technology, underscoring was not possible, and users made up for this lack (and the lack of formatting in ASCII) by using certain symbols as substitutes. Emphasis, for example, could be achieved in ASCII in a number of ways:

Surrounding by underscores was also used for book titles: Look it up in _The_C_Programming_Language_.

Formatting can be marked by tags distinguished from the body text by special characters, such as angle brackets in HTML. For example, this text:

is marked up in HTML thus:

The italicised text is enclosed by an opening and a closing italics tag. In LaTeX, the text would be marked up like this:

Markup languages can be implemented with any text editor, needing no special software.

Since the invention of MacWrite, the first WYSIWYG word processor, in which the typist codes the formatting visually rather than by inserting textual markup, word processors have tended to save to binary files. Opening such files with a text editor reveals the text embellished with various binary characters, either around the formatted areas (e.g. in WordPerfect) or separately, at the beginning or end of the file (e.g. in Microsoft Word).


...
Wikipedia

...