Setext
{{Short description|Lightweight markup language for text documents}}
{{Infobox file format
| name = Setext
| logo =
| icon =
| iconcaption =
| screenshot =
| caption =
| extension = .etx{{efn| ("enhanced/ e-mailable text") {{Cite web |date=1992-01-06 |title=TidBITS in new format |url=https://tidbits.com/1992/01/06/tidbits-in-new-format/ |access-date=2022-07-01 |website=TidBITS |language=en}}}}
| mime =
| type code =
| uniform type =
| conforms to =
| magic =
| owner = Ian Feldman
| released = {{Start date and age|1992|01|06}}
| latest release version =
| latest release date =
| genre = Lightweight markup language
| container for =
| contained by =
| extended from =
| extended to =
| standard =
| free =
| url =
}}
Setext (Structure Enhanced Text){{Cite web|last1=Engst|first1=Adam C.|title=comp.sys.mac.announce / TidBITS file server available|url=https://groups.google.com/forum/#!search/before$3A1992$2F01$2F01$20setext$20structure$20enhanced/comp.sys.mac.announce/huItllyV_p4/-X8pBRvRSPcJ|publisher=UseNet|accessdate=21 December 2015}} is a lightweight markup language used to format plain text documents such as e-newsletters, Usenet postings, and e-mails. In contrast to some other markup languages (such as HTML), the markup is easily readable without any parsing or special software.
Setext was first introduced in 1991 by Ian Feldman for use in the TidBITS electronic newsletter.
Purpose
Setext allows viewing of marked-up documents without special viewing software. When appropriate software is used, however, a rich text-style experience is available to the user.
Smaller documents are trivial to create in any text editor.
To prevent errors, most large setext publications are created using a markup language such as HTML or SGML and then converted. The setext document can then be distributed without the need for the recipient to use a HTML email or web viewer.
= Multiple ''setext'' documents in the same file =
Multiple setext documents can be stored in the same file, similarly to how the mbox format can store multiple e-mail messages together.
It was initially announced that multiple documents could be included in a single stream, separated by a special
tag serving as a document delimiter{{efn|This was to function much in the same way as the original purpose of the ASCII "File Separator" (FS; 0x1C; typed as Ctrl-\
) C0 control character but it proved too visually distracting and so was removed before setext was finalized. }}. After several months, it was clarified{{Cite web |date=1992-03-09 |title=Administrivia |url=https://tidbits.com/1992/03/09/administrivia-13/ |access-date=2022-07-01 |website=TidBITS |language=en}} that this tag was not an official part of setext, and that multiple documents should instead be delimited by $$
appearing at the end of a line of text.
Regardless of the number of documents stored in the same file, basic metadata can be stored about any or all of them by using the subject-tt tag syntax.
Setext tags
The following are the ten most common of the 16 different setext tags.{{Cite web |last=Oliver |first=Erik |title=Setext command reference |url=http://valdemar.net/~erik/site-features/setext/ |access-date=2022-07-01 |website=Erik Oliver's Home Page |url-status=live |archive-url=https://web.archive.org/web/20220816203127/http://valdemar.net/~erik/site-features/setext/ |archive-date=2022-08-16 }}{{Cite web |last=Feldman |first=Ian |date=1992-08-16 |title=What is setext |url=http://www.bsdi.com/setext/setext_concepts_Aug92.etx |archive-url=https://web.archive.org/web/20010430053834/http://www.bsdi.com/setext/setext_concepts_Aug92.etx |archive-date=2001-04-30 |access-date= |website=bsdi.org}}{{efn|(Not currently shown in table: note-tt, quote-tt, subject-tt, suppress-tt, twobuck-tt, and twodot-tt)}}
class="wikitable" summary="Syntax and examples of various {{No selflink|Setext|setext}} markup tags"
|+ style="text-align: center;" | setext tag usage and examples{{efn | name="table_notes" |(For a document to be valid setext, the only required tag is either 'subhead-tt' or 'title-tt' - all others are optional.)}}{{efn |name=formal_def | "(A) formal definition of what makes a setext: a text that contains at least one verified setext subhead or setext title" {{Cite web |last=Feldman |first=Ian |date=1992-03-15 |title=setext sermon – Part 1 |url=http://www.bsdi.com/setext/sermon_1+920315.etx |archive-url=https://web.archive.org/web/20010309083208/http://www.bsdi.com/setext/sermon_1+920315.etx |archive-date=2001-03-09 |access-date= |website=bsdi.com}}{{Cite web |last= Feldman |first=Ian |date=1992-03-29 |title=setext sermon – Part 2 |url=http://www.bsdi.com/setext/sermon_2+920329.etx |archive-url=https://web.archive.org/web/20010430054853/http://www.bsdi.com/setext/sermon_2+920329.etx |archive-date=2001-04-30 |access-date= |website=bsdi.org}}}} ! scope="col" |Name{{efn |name=typotag | ('-tt' stands for 'typotag', the Feldman's shorthand for 'typographic tags'; contrast with the 'tags' used in modern systems for categorizing data or photos into groups) }} ! style="text-align: left; min-width= 30em;" | setext pattern ! style="text-align: left;" | Example {{efn |(i.e. the actual text as stored / transmitted, except in the case of bullet-tt. Visual appearance would be defined/controlled by the program displaying the document.)}} ! style="text-align: left; width= 25%;" | Comments |
id="b" scope="row" | title-tt
| class="nowrap" | | ==================== | A distinct title identified by the text, maximum one per setext. Must start at the beginning of the line. |
---|
id="c" scope="row" |subhead-tt
| class="nowrap" | | -------------- | A distinct subheading identified by the text, zero or more per text. Must start at beginning of line. See note in title-tt about handling. |
indent-tt
| 66-char lines indented by 2 spaces | class="nowrap" | First paragraph... ...more of paragraph. [blank line] Next paragraph... | Lines undented and unfolded (longer lines are generally tolerated by most parsers). This is primary body text, generally plain undented in emails, etc. currently. |
bold-tt
| class="nowrap" | | | One or more bold words, generally |
italic-tt
| class="nowrap" | | | A single, italicized word; multi-word form was not officially specified due to "visual-clarity reasons" |
class="nowrap" |underline-tt
| class="nowrap" |
| | Display in a (user) selected style, preferably with underlining--except in browsers where underlining corresponds to hot links. One or more underlined words |
hot-tt
| class="nowrap" | | | Used to mark notes and URLs{{efn|"synonymous with the 'grouped' style of HyperCard"}}{{efn | name=hotlinks_note | A href-tt or note-tt 'hot word' prefixed with an underscore (i.e., |
include-tt
| class="nowrap" | | > This is quoted text... > ...more... | Displayed in a user selected style, preferably monospaced with the leading ">" |
bullet-tt
| class="nowrap" | | * Item 1 that is... ...really long * Item 2 | Displayed in bullet or list format. |
href-tt
| class="nowrap" | | | (Linked in the text with a hot-tt as |
Standalone Setext files
See also
References
= Notes =
{{Notelist}}
= References =
{{Reflist}}
External links
- [http://docutils.sourceforge.net/mirror/setext/setext_concepts_Aug92.etx.txt Setext format]
- [https://web.archive.org/web/20010424104701/http://www.bsdi.com/setext/ Setext historical documents] at Archive.org
- [http://tidbits.com/article/3282 TidBITS introduction of setext]
- [https://www.w3.org/MarkUp/html-test/setext/ setext+sgml at W3.org], including the same document in both [https://www.w3.org/MarkUp/html-test/setext/setext+sgml_01.etx setext-like plain text] and [https://www.w3.org/MarkUp/html-test/setext/setext+sgml_01.html html] formats to allow a side-by-side comparison.
= Implementations =
- [http://www.valdemar.net/~erik/setext/setext2html.txt setext2html.pl] — A Perl setext -> HTML converter
- [http://setextbrowser.zomdir.com/ setextbrowser.zomdir.com] ({{webarchive |url=https://web.archive.org/web/20181129222020/https://setext-browser.zomdir.com/ |date=29 November 2018}}) – A web application which let you browse the internet in a semi-setext format
{{Document markup languages}}
{{DEFAULTSORT:Setext}}