ConTeXt: Difference between revisions
imported>Wikideas1 →See also: Comparison of TeX editors |
imported>Ron Waffle m →Example of code: copy edit |
||
| Line 1: | Line 1: | ||
{{Short description|General-purpose document processor, derived from TeX}} | {{Short description|General-purpose document processor, derived from TeX}}{{Primary sources|date=July 2025}}{{Infobox software | ||
{{Infobox software | |||
| name = ConTeXt | | name = ConTeXt | ||
| logo = [[Image:ConTeXt Unofficial Logo.svg|The Unofficial ConTeXt logo (contextgarden.net logo)|200px]] | | logo = [[Image:ConTeXt Unofficial Logo.svg|The Unofficial ConTeXt logo (contextgarden.net logo)|200px]] | ||
| author = Mainly Hans Hagen and [http://www.pragma-ade.com/ Pragma ADE] | | author = Mainly Hans Hagen and [http://www.pragma-ade.com/ Pragma ADE] | ||
| developer = Mainly Hans Hagen, | | developer = Mainly Hans Hagen, Taco Hoekwater,<ref>[http://www.tug.org/interviews/hoekwater.html Dave Walden interview with Taco Hoekwater. TeX User Group 2006.]</ref> Aditya Mahajan, Mojca Miklavec, Wolfgang Schuster | ||
| latest_release_version = Mark IV 0.61 | | latest_release_version = Mark IV 0.61 | ||
| latest_release_date = {{start date|2015|05|24}}<ref>{{Cite web |url=http://wiki.contextgarden.net/Release_Notes |title=Release notes of ConTeXt at contextgarden |access-date=2009-03-09 |archive-date=2005-12-26 |archive-url=https://web.archive.org/web/20051226203050/http://wiki.contextgarden.net/Release_Notes |url-status=dead }}</ref><ref>{{Cite web |url=http://foundry.supelec.fr/frs/?group_id=14 |title=List of releases of ConTeXt |access-date=2009-03-18 |archive-url=https://web.archive.org/web/20061124101941/https://foundry.supelec.fr/frs/?group_id=14 |archive-date=2006-11-24 |url-status=dead }}</ref><ref>{{Cite web |url=http://foundry.supelec.fr/gf/project/contextrev/frs/ |title=ConTeXt files in Supelec |access-date=2009-10-05 |archive-url=https://web.archive.org/web/20101106003346/http://foundry.supelec.fr/gf/project/contextrev/frs/ |archive-date=2010-11-06 |url-status=dead }}</ref> | | latest_release_date = {{start date|2015|05|24}}<ref>{{Cite web |url=http://wiki.contextgarden.net/Release_Notes |title=Release notes of ConTeXt at contextgarden |access-date=2009-03-09 |archive-date=2005-12-26 |archive-url=https://web.archive.org/web/20051226203050/http://wiki.contextgarden.net/Release_Notes |url-status=dead }}</ref><ref>{{Cite web |url=http://foundry.supelec.fr/frs/?group_id=14 |title=List of releases of ConTeXt |access-date=2009-03-18 |archive-url=https://web.archive.org/web/20061124101941/https://foundry.supelec.fr/frs/?group_id=14 |archive-date=2006-11-24 |url-status=dead }}</ref><ref>{{Cite web |url=http://foundry.supelec.fr/gf/project/contextrev/frs/ |title=ConTeXt files in Supelec |access-date=2009-10-05 |archive-url=https://web.archive.org/web/20101106003346/http://foundry.supelec.fr/gf/project/contextrev/frs/ |archive-date=2010-11-06 |url-status=dead }}</ref> | ||
| operating_system = Multiplatform ([[TeX]]) | | operating_system = Multiplatform ([[TeX]]) | ||
| genre = Document processor, | | genre = Document processor, document markup language | ||
| license = Program code under [https://www.gnu.org/licenses/gpl-2.0.html GPLv2] and Documentation under [https://creativecommons.org/licenses/by-nc-sa/3.0/ CC BY-NC-SA 3.0]<ref>[http://wiki.contextgarden.net/Read_Me Read Me] (license of ConTeXt code and documentation)</ref> | | license = Program code under [https://www.gnu.org/licenses/gpl-2.0.html GPLv2] and Documentation under [https://creativecommons.org/licenses/by-nc-sa/3.0/ CC BY-NC-SA 3.0]<ref>[http://wiki.contextgarden.net/Read_Me Read Me] (license of ConTeXt code and documentation)</ref> | ||
| website = [http://wiki.contextgarden.net contextgarden] | | website = [http://wiki.contextgarden.net contextgarden] | ||
}} | }} | ||
'''ConTeXt''' is a general-purpose [[document processor]]. Like [[LaTeX]], it is derived from [[TeX]]. | '''ConTeXt''', stylised as '''{{Stylized LaTeX|context}}''', is a general-purpose [[document processor]]. Like [[LaTeX]], it is derived from the [[TeX]] [[typesetting]] system. ConTeXt is especially suited for structured documents, automated document production, very fine typography, and multilingual typesetting. It is based in part on TeX, and uses a [[document markup language]] for manuscript preparation. The typographical and automated capabilities of ConTeXt are extensive, including interfaces for handling [[microtypography]], multiple footnotes and footnote classes, and manipulating [[OpenType]] fonts and features. Moreover, ConTeXt offers extensive support for colors, backgrounds, hyperlinks, presentations, figure-text integration, and conditional compilation. It gives the user extensive control over formatting, while making it easy to create new layouts and styles without learning the low-level TeX [[Macro (computer science)|macro]] language. | ||
While comparisons can be made between ConTeXt and [[LaTeX]], the primary objectives of the two systems are distinct. From the | While comparisons can be made between ConTeXt and [[LaTeX]], the primary objectives of the two systems are distinct. From the outset, ConTeXt has been a typography and typesetting system designed to give users straightforward and consistent access to advanced typographical control, which is crucial for general-purpose typesetting. LaTeX's original vision, on the other hand, was to insulate the user from typographical decisions—an approach particularly useful for tasks such as submitting articles to a scientific journal. Although LaTeX has evolved from this original vision, ConTeXt's unified design prevents the package clashes which are often experienced with LaTeX.<ref>{{Cite web |url=http://www.tex.ac.uk/cgi-bin/texfaq2html?label=context |title=FAQ of the UK TeX Archive |access-date=2009-03-16 |archive-url=https://web.archive.org/web/20100518111729/http://www.tex.ac.uk/cgi-bin/texfaq2html?label=context |archive-date=2010-05-18 |url-status=dead }}</ref><ref name="whatiscontextwiki">[http://wiki.contextgarden.net/What_is_ConTeXt "What is ConTeXt" page at contextgarden]</ref> | ||
ConTeXt provides a multilingual user interface with support for markup in English, Dutch, German, French, and Italian and support for output in many scripts including western European, eastern European, Arabic, Chinese, Japanese, and Korean. It also allows the user to use different TeX engines like [[LuaTeX]] (MkIV) and [[LuaMetaTeX]] (LMTX). Older versions (MkII) worked with [[pdfTeX]] or [[XeTeX]].<ref name="whatiscontextwiki"/> | ConTeXt provides a multilingual user interface with support for markup in English, Dutch, German, French, and Italian, and support for output in many scripts including western European, eastern European, Arabic, Chinese, Japanese, and Korean. It also allows the user to use different TeX engines, like [[LuaTeX]] (MkIV) and [[LuaMetaTeX]] (LMTX). Older versions (MkII) worked with [[pdfTeX]] or [[XeTeX]].<ref name="whatiscontextwiki"/> | ||
As its native drawing engine, ConTeXt integrates a superset of [[MetaPost]] called [[MetaFun]],<ref name="whatiscontextwiki"/> which allows users to draw page backgrounds and ornaments with MetaPost. MetaFun can also be used directly with MetaPost. ConTeXt also supports the use of other external drawing engines, like [[PGF/TikZ]]<ref>[http://www.ctan.org/tex-archive/graphics/pgf/base/doc/generic/pgf/pgfmanual.pdf PGF/TikZ official manual. Version 2.0] {{webarchive |url=https://web.archive.org/web/20110109090729/http://www.ctan.org/tex-archive/graphics/pgf/base/doc/generic/pgf/pgfmanual.pdf |date=January 9, 2011 }}. Section 9.1.3 "Using the ConTeXt Format". p. 88</ref> and PSTricks.<ref name="list-modules">[http://wiki.contextgarden.net/Modules List of ConTeXt modules at contextgarden]</ref> | As its native drawing engine, ConTeXt integrates a superset of [[MetaPost]] called [[MetaFun]],<ref name="whatiscontextwiki"/> which allows users to draw page backgrounds and ornaments with MetaPost. MetaFun can also be used directly with MetaPost. ConTeXt also supports the use of other external drawing engines, like [[PGF/TikZ]]<ref>[http://www.ctan.org/tex-archive/graphics/pgf/base/doc/generic/pgf/pgfmanual.pdf PGF/TikZ official manual. Version 2.0] {{webarchive |url=https://web.archive.org/web/20110109090729/http://www.ctan.org/tex-archive/graphics/pgf/base/doc/generic/pgf/pgfmanual.pdf |date=January 9, 2011 }}. Section 9.1.3 "Using the ConTeXt Format". p. 88</ref> and PSTricks.<ref name="list-modules">[http://wiki.contextgarden.net/Modules List of ConTeXt modules at contextgarden]</ref> | ||
ConTeXt also provides a | ConTeXt also provides a macro package for typesetting [[chemical structure]] diagrams with TeX, called [https://www.ctan.org/pkg/ppchtex PPCHTeX],<ref>[http://wiki.contextgarden.net/Chemistry PPCHTeX Module for ConTeXt reference page at contextgarden]</ref> as well as many other modules.<ref name="list-modules"/><ref>[http://modules.contextgarden.net/ List of ConTeXt modules (static page)]</ref><ref>[http://dl.contextgarden.net/modules/ List of ConTeXt modules in web server for downloading]</ref> This package can also be used with plain TeX and LaTeX. | ||
Originally | Originally titled ''pragmatex'', ConTeXt was given its name around 1996<ref>[https://tug.org/interviews/hagen.html Hans Hagen Interview, 2006]</ref> by Hans Hagen from [http://www.pragma-ade.com/ PRAGMA Advanced Document Engineering] (Pragma ADE), a Netherlands-based company. | ||
== License == | == License == | ||
ConTeXt is [[free software]] | ConTeXt is [[free software]]; the program code (i.e. anything not under the <code>{{nowrap|/doc}}</code> subtree) is distributed under the [[GNU GPL]], and the documentation is provided under [[Creative Commons]] Attribution NonCommercial ShareAlike license.<ref>{{cite web |url=http://wiki.contextgarden.net/Read_Me |title=Read Me | access-date = 2010-07-13 |last=Hagen |first=Hans | date = 2005-11-24}}</ref> | ||
The ConTeXt [http://www.pragma-ade.com/general/manuals/cont-eni.pdf official manual](2001) and ConTeXt [http://www.pragma-ade.com/general/manuals/ms-cb-en.pdf official mini tutorial] (1999) are documents copyrighted by Pragma, but there is a repository | The ConTeXt [http://www.pragma-ade.com/general/manuals/cont-eni.pdf official manual](2001) and ConTeXt [http://www.pragma-ade.com/general/manuals/ms-cb-en.pdf official mini tutorial] (1999) are documents copyrighted by Pragma, but there is a repository for the future manual<ref>[http://foundry.supelec.fr/gf/project/contextman/scmsvn/?action=browse&path=%2Fcontext-reference%2F Repository of new reference manual] {{webarchive |url=https://web.archive.org/web/20120222103946/http://foundry.supelec.fr/gf/project/contextman/scmsvn/?action=browse&path=%2Fcontext-reference%2F |date=February 22, 2012 }}</ref> released under the [[GFDL|GNU Free Documentation License]].<ref>[http://foundry.supelec.fr/gf/project/contextman/scmsvn/?action=browse&path=%2Fcontext-reference%2FCOPYING&view=log License notice of new official manual] {{webarchive |url=https://web.archive.org/web/20120222104006/http://foundry.supelec.fr/gf/project/contextman/scmsvn/?action=browse&path=%2Fcontext-reference%2FCOPYING&view=log |date=February 22, 2012 }}</ref><ref>Part of thread about context manual where Taco Hoekwater [http://www.ntg.nl/pipermail/ntg-context/2009/039070.html recognises that new manual is licensed under the GFDL] and [http://www.ntg.nl/pipermail/ntg-context/2009/039072.html he should put license note on the current directory of manual]</ref> As of April 2009, there is an up-to-date version of the fonts and typography chapters.<ref>Up-to-date chapters of manual: [http://context.aanhet.net/svn/contextman/context-reference/en/co-fonts.pdf Fonts] and [http://context.aanhet.net/svn/contextman/context-reference/en/co-typography.pdf Typography]. April 2009.</ref> | ||
== Versions == | == Versions == | ||
The current version of ConTeXt is LMTX, introduced in April 2019 as the successor to Mark IV (MkIV).<ref>{{Cite web|title=LMTX - Wiki|url=https://wiki.contextgarden.net/LMTX|access-date=2020-08-30|website=wiki.contextgarden.net}}</ref> Previous versions | The current version of ConTeXt is LMTX, introduced in April 2019 as the successor to Mark IV (MkIV).<ref>{{Cite web|title=LMTX - Wiki|url=https://wiki.contextgarden.net/LMTX|access-date=2020-08-30|website=wiki.contextgarden.net}}</ref> Previous versions{{mdash}}Mark II (MkII) and Mark I{{mdash}}are no longer maintained. | ||
According to the developers, the principal difference between LMTX and its predecessors is that the newest version "uses a compilation and scripting engine that is specifically developed with ConTeXt in mind: LuaMetaTeX ... [which] has been optimised heavily for ConTeXt use." Previously, MkIV used [[LuaTeX]] and MkII used [[pdfTeX]]. | According to the developers, the principal difference between LMTX and its predecessors is that the newest version "uses a compilation and scripting engine that is specifically developed with ConTeXt in mind: LuaMetaTeX ... [which] has been optimised heavily for ConTeXt use." Previously, MkIV used [[LuaTeX]] and MkII used [[pdfTeX]]. | ||
== History == | == History == | ||
ConTeXt was created by Hans Hagen<ref name="walden-hans">[http://www.tug.org/interviews/interview-files/hans-hagen.html Dave Walden interview Hans Hagen. TeX User Group 2006.]</ref> and Ton Otten of Pragma ADE in the Netherlands<ref>[http://www.tug.org/pracjourn/2005-1/asknelly/ "Ask Nelly ..." PracTeX Journal. TeX User Group. 2005]. Includes an example of ConTeXt document with source code.</ref> around 1991<ref name="taco-history">[http://meeting.contextgarden.net/2007/share/taco/history.pdf Taco Hoekwater "A short History of $2^4$ parts". ConTeXt User Meeting 2007 (march 24)]</ref><ref name="CUM-programme-2007">[http://meeting.contextgarden.net/2007/programme.shtml Programme of the ConTeXt User Meeting 2007]</ref> due to the need for educational typesetting material. | ConTeXt was created by Hans Hagen<ref name="walden-hans">[http://www.tug.org/interviews/interview-files/hans-hagen.html Dave Walden interview Hans Hagen. TeX User Group 2006.]</ref> and Ton Otten of Pragma ADE in the Netherlands,<ref>[http://www.tug.org/pracjourn/2005-1/asknelly/ "Ask Nelly ..." PracTeX Journal. TeX User Group. 2005]. Includes an example of ConTeXt document with source code.</ref> around 1991,<ref name="taco-history">[http://meeting.contextgarden.net/2007/share/taco/history.pdf Taco Hoekwater "A short History of $2^4$ parts". ConTeXt User Meeting 2007 (march 24)]</ref><ref name="CUM-programme-2007">[http://meeting.contextgarden.net/2007/programme.shtml Programme of the ConTeXt User Meeting 2007]</ref> due to the need for educational typesetting material. | ||
Around 1996, Hans Hagen coined the name ConTeXt meaning "text with tex" (con-tex-t; "con" is a Latin preposition meaning "together with").<ref name="walden-hans"/> Before 1996 ConTeXt was used only within Pragma ADE, but in 1996 it began to be adopted by a wider audience. | Around 1996, Hans Hagen coined the name ConTeXt, meaning "text with tex" (con-tex-t; "con" is a Latin preposition meaning "together with").<ref name="walden-hans"/> Before 1996, ConTeXt was used only within Pragma ADE, but in 1996 it began to be adopted by a wider audience. | ||
In July 2004, contextgarden.net wiki page was created.<ref name="taco-history"/><ref>{{Cite web |url=http://contextgarden.wordpress.com/2009/07/17/happy-birthday-contextgarden/ |title=contextgarden 5th birthday on 24 July 2009 |access-date=22 July 2009 |archive-date=18 July 2011 |archive-url=https://web.archive.org/web/20110718092025/http://contextgarden.wordpress.com/2009/07/17/happy-birthday-contextgarden/ |url-status=dead }}</ref> | In July 2004, the contextgarden.net wiki page was created.<ref name="taco-history"/><ref>{{Cite web |url=http://contextgarden.wordpress.com/2009/07/17/happy-birthday-contextgarden/ |title=contextgarden 5th birthday on 24 July 2009 |access-date=22 July 2009 |archive-date=18 July 2011 |archive-url=https://web.archive.org/web/20110718092025/http://contextgarden.wordpress.com/2009/07/17/happy-birthday-contextgarden/ |url-status=dead }}</ref> | ||
ConTeXt low-level code was originally written in Dutch. Around 2005, the ConTeXt developers began translating this to English, resulting in the version known as MKII, which is now stable and frozen{{Citation needed|date=November 2009}} | ConTeXt low-level code was originally written in Dutch. Around 2005, the ConTeXt developers began translating this to English, resulting in the version known as MKII, which is now stable and frozen.{{Citation needed|date=November 2009}} | ||
In August 2007, Hans Hagen presented the MKIV version | In August 2007, Hans Hagen presented the MKIV version;<ref name="CUM-programme-2007"/><ref>[http://meeting.contextgarden.net/2007/share/hans/mkiv-epen-2007.pdf Hans Hagen The Road to MKIV. ConTeXt User Meeting 2007.]</ref> the first public beta was released later that year.<ref>[http://wiki.contextgarden.net/Mark_IV MKIV at contextgarden]</ref> | ||
During the ConTeXt User Meeting 2008, Mojca Miklavec presented<ref>[http://meeting.contextgarden.net/2008/programme.shtml ConTeXt User Meeting 2008 web page]</ref> [http://minimals.contextgarden.net/ ConTeXt Minimals], a distribution of ConTeXt containing the latest binaries and intended to have a small memory footprint, thus demanding less bandwidth for updates.<ref>{{Cite web |url=http://wiki.contextgarden.net/ConTeXt_Minimals |title=ConTeXt Minimals web page |access-date=2009-01-22 |archive-date=2018-11-16 |archive-url=https://web.archive.org/web/20181116060213/https://wiki.contextgarden.net/ConTeXt_Minimals |url-status=dead }}</ref> In August 2008, this distribution was registered as a project | During the ConTeXt User Meeting 2008, Mojca Miklavec presented<ref>[http://meeting.contextgarden.net/2008/programme.shtml ConTeXt User Meeting 2008 web page]</ref> [http://minimals.contextgarden.net/ ConTeXt Minimals], a distribution of ConTeXt containing the latest binaries and intended to have a small memory footprint, thus demanding less bandwidth for updates.<ref>{{Cite web |url=http://wiki.contextgarden.net/ConTeXt_Minimals |title=ConTeXt Minimals web page |access-date=2009-01-22 |archive-date=2018-11-16 |archive-url=https://web.archive.org/web/20181116060213/https://wiki.contextgarden.net/ConTeXt_Minimals |url-status=dead }}</ref> In August 2008, this distribution was registered as a project on the Canonical Launchpad website.<ref>[https://launchpad.net/context ConTeXt at Launchpad.net]</ref> | ||
In June 2008, Patrick Gundlach wrote the first post<ref>[http://contextgarden.wordpress.com/2008/06/23/garden-admins-at-the-context-meeting/ First ConTeXt blog post]</ref> in [http://contextgarden.wordpress.com ConTeXt blog]. | In June 2008, Patrick Gundlach wrote the first post<ref>[http://contextgarden.wordpress.com/2008/06/23/garden-admins-at-the-context-meeting/ First ConTeXt blog post]</ref> in [http://contextgarden.wordpress.com ConTeXt blog]. | ||
In July 2009, ConTeXt started [http://dl.contextgarden.net/distribution/git/ git repository].<ref>{{Cite web |url=http://contextgarden.wordpress.com/2009/07/17/new-git-repository/ |title=Post of announce of git repository |access-date=2009-07-22 |archive-date=2010-03-24 |archive-url=https://web.archive.org/web/20100324105956/http://contextgarden.wordpress.com/2009/07/17/new-git-repository/ |url-status=dead }}</ref> | In July 2009, ConTeXt started a [http://dl.contextgarden.net/distribution/git/ git repository].<ref>{{Cite web |url=http://contextgarden.wordpress.com/2009/07/17/new-git-repository/ |title=Post of announce of git repository |access-date=2009-07-22 |archive-date=2010-03-24 |archive-url=https://web.archive.org/web/20100324105956/http://contextgarden.wordpress.com/2009/07/17/new-git-repository/ |url-status=dead }}</ref> | ||
In November 2010, the [http://group.contextgarden.net/ ConTeXt Group] was created.<ref>[http://www.journal-officiel.gouv.fr/association/index.php?ACTION=Rechercher&JTY_WALDEC=W353009428 Official announcement of ConTeXt Group registration]</ref> | In November 2010, the [http://group.contextgarden.net/ ConTeXt Group] was created.<ref>[http://www.journal-officiel.gouv.fr/association/index.php?ACTION=Rechercher&JTY_WALDEC=W353009428 Official announcement of ConTeXt Group registration]</ref> | ||
| Line 59: | Line 58: | ||
==Example of code== | ==Example of code== | ||
Making ConTeXt documents is simple: | Making ConTeXt documents is simple: make a plain text file, and compile it with the <code>context</code> script.<ref>[http://www.pragma-ade.com/general/manuals/mtexexec.pdf "TeXEXEC explained" manual. Pragma ADE.]</ref> The result of this process is a [[Portable Document Format|PDF]] file (ConTeXt also can generate a [[DVI (file format)|DVI]] file). An example is shown below. | ||
ConTeXt documents come with the file extension .tex or an extension demarking the version required: <code>.mkii</code>, <code>.mkiv</code>, or <code>.mkxl</code> for regular TeX, <code>.mkvi</code> or <code>.mklx</code> for a dialect that supports named macro parameters in addition to TeX’s numeric ones.<ref>{{Cite web|url=https://mailman.ntg.nl/pipermail/ntg-context/2020/096906.html|title=[NTG-context] Official file ending?|last=Hagen|first=Hans|date=2020-02-04|website=mailman.ntg.nl|access-date=2020-02-12|archive-date=2021-06-28|archive-url=https://web.archive.org/web/20210628083507/https://mailman.ntg.nl/pipermail/ntg-context/2020/096906.html|url-status=dead}}</ref> | ConTeXt documents come with the file extension <code>.tex</code>, or an extension demarking the version required: <code>.mkii</code>, <code>.mkiv</code>, or <code>.mkxl</code> for regular TeX, <code>.mkvi</code> or <code>.mklx</code> for a dialect that supports named macro parameters in addition to TeX’s numeric ones.<ref>{{Cite web|url=https://mailman.ntg.nl/pipermail/ntg-context/2020/096906.html|title=[NTG-context] Official file ending?|last=Hagen|first=Hans|date=2020-02-04|website=mailman.ntg.nl|access-date=2020-02-12|archive-date=2021-06-28|archive-url=https://web.archive.org/web/20210628083507/https://mailman.ntg.nl/pipermail/ntg-context/2020/096906.html|url-status=dead}}</ref> | ||
{| style="width:100%;" border="0" cellpadding="0" cellspacing="0" | {| style="width:100%;" border="0" cellpadding="0" cellspacing="0" | ||
|- | |- | ||
| Line 122: | Line 121: | ||
{{Reflist|2}} | {{Reflist|2}} | ||
{{TeX navbox}} | {{TeX navbox}} | ||
Latest revision as of 19:56, 2 October 2025
Template:Short descriptionScript error: No such module "Unsubst".Script error: No such module "Infobox".Template:Template other Script error: No such module "Check for unknown parameters".Script error: No such module "Check for conflicting parameters".
ConTeXt, stylised as Template:Stylized LaTeX, is a general-purpose document processor. Like LaTeX, it is derived from the TeX typesetting system. ConTeXt is especially suited for structured documents, automated document production, very fine typography, and multilingual typesetting. It is based in part on TeX, and uses a document markup language for manuscript preparation. The typographical and automated capabilities of ConTeXt are extensive, including interfaces for handling microtypography, multiple footnotes and footnote classes, and manipulating OpenType fonts and features. Moreover, ConTeXt offers extensive support for colors, backgrounds, hyperlinks, presentations, figure-text integration, and conditional compilation. It gives the user extensive control over formatting, while making it easy to create new layouts and styles without learning the low-level TeX macro language.
While comparisons can be made between ConTeXt and LaTeX, the primary objectives of the two systems are distinct. From the outset, ConTeXt has been a typography and typesetting system designed to give users straightforward and consistent access to advanced typographical control, which is crucial for general-purpose typesetting. LaTeX's original vision, on the other hand, was to insulate the user from typographical decisions—an approach particularly useful for tasks such as submitting articles to a scientific journal. Although LaTeX has evolved from this original vision, ConTeXt's unified design prevents the package clashes which are often experienced with LaTeX.[1][2]
ConTeXt provides a multilingual user interface with support for markup in English, Dutch, German, French, and Italian, and support for output in many scripts including western European, eastern European, Arabic, Chinese, Japanese, and Korean. It also allows the user to use different TeX engines, like LuaTeX (MkIV) and LuaMetaTeX (LMTX). Older versions (MkII) worked with pdfTeX or XeTeX.[2]
As its native drawing engine, ConTeXt integrates a superset of MetaPost called MetaFun,[2] which allows users to draw page backgrounds and ornaments with MetaPost. MetaFun can also be used directly with MetaPost. ConTeXt also supports the use of other external drawing engines, like PGF/TikZ[3] and PSTricks.[4]
ConTeXt also provides a macro package for typesetting chemical structure diagrams with TeX, called PPCHTeX,[5] as well as many other modules.[4][6][7] This package can also be used with plain TeX and LaTeX.
Originally titled pragmatex, ConTeXt was given its name around 1996[8] by Hans Hagen from PRAGMA Advanced Document Engineering (Pragma ADE), a Netherlands-based company.
License
ConTeXt is free software; the program code (i.e. anything not under the /doc subtree) is distributed under the GNU GPL, and the documentation is provided under Creative Commons Attribution NonCommercial ShareAlike license.[9]
The ConTeXt official manual(2001) and ConTeXt official mini tutorial (1999) are documents copyrighted by Pragma, but there is a repository for the future manual[10] released under the GNU Free Documentation License.[11][12] As of April 2009, there is an up-to-date version of the fonts and typography chapters.[13]
Versions
The current version of ConTeXt is LMTX, introduced in April 2019 as the successor to Mark IV (MkIV).[14] Previous versionsTemplate:MdashMark II (MkII) and Mark ITemplate:Mdashare no longer maintained.
According to the developers, the principal difference between LMTX and its predecessors is that the newest version "uses a compilation and scripting engine that is specifically developed with ConTeXt in mind: LuaMetaTeX ... [which] has been optimised heavily for ConTeXt use." Previously, MkIV used LuaTeX and MkII used pdfTeX.
History
ConTeXt was created by Hans Hagen[15] and Ton Otten of Pragma ADE in the Netherlands,[16] around 1991,[17][18] due to the need for educational typesetting material.
Around 1996, Hans Hagen coined the name ConTeXt, meaning "text with tex" (con-tex-t; "con" is a Latin preposition meaning "together with").[15] Before 1996, ConTeXt was used only within Pragma ADE, but in 1996 it began to be adopted by a wider audience.
In July 2004, the contextgarden.net wiki page was created.[17][19]
ConTeXt low-level code was originally written in Dutch. Around 2005, the ConTeXt developers began translating this to English, resulting in the version known as MKII, which is now stable and frozen.Script error: No such module "Unsubst".
In August 2007, Hans Hagen presented the MKIV version;[18][20] the first public beta was released later that year.[21]
During the ConTeXt User Meeting 2008, Mojca Miklavec presented[22] ConTeXt Minimals, a distribution of ConTeXt containing the latest binaries and intended to have a small memory footprint, thus demanding less bandwidth for updates.[23] In August 2008, this distribution was registered as a project on the Canonical Launchpad website.[24]
In June 2008, Patrick Gundlach wrote the first post[25] in ConTeXt blog.
In July 2009, ConTeXt started a git repository.[26]
In November 2010, the ConTeXt Group was created.[27]
In April 2019, LMTX (ConTeXt LuaMetaTeX) was announced.[28]
Example of code
Making ConTeXt documents is simple: make a plain text file, and compile it with the context script.[29] The result of this process is a PDF file (ConTeXt also can generate a DVI file). An example is shown below.
ConTeXt documents come with the file extension .tex, or an extension demarking the version required: .mkii, .mkiv, or .mkxl for regular TeX, .mkvi or .mklx for a dialect that supports named macro parameters in addition to TeX’s numeric ones.[30]
% This line is a comment because % precedes it.
% It specifies the format of head named 'title'
% Specifically the style of the font: sans serif
% + bold + big font.
\setuphead[title][style={\ss\bfd},
before={\begingroup},
after={John Doe, the author\smallskip%
\currentdate\bigskip\endgroup}]
\starttext
\title{\CONTEXT}
\section{Text}
\CONTEXT\ is a document preparation system for the
\TEX\ typesetting program. It offers programmable
desktop publishing features and extensive
facilities for automating most aspects of
typesetting and desktop publishing, including
numbering and cross-referencing (for example to
equation \in[eqn:famous-emc]), tables and figures,
page layout, bibliographies, and much more.
It was originally written around 1990 by Hans
Hagen. It could be an alternative or complement
to \LATEX.
\section{Maths}
With \CONTEXT\ we could write maths. Equations
can be automatically numbered.
\placeformula[eqn:famous-emc]
\startformula
E = mc^2
\stopformula
with
\placeformula[eqn:def-m]
\startformula
m = \frac{m_0}{\sqrt{1-\frac{v^2}{c^2}}}
\stopformula
\stoptext
|
See also
Script error: No such module "Portal".
References
<templatestyles src="Reflist/styles.css" />
- ↑ Script error: No such module "citation/CS1".
- ↑ a b c "What is ConTeXt" page at contextgarden
- ↑ PGF/TikZ official manual. Version 2.0 Template:Webarchive. Section 9.1.3 "Using the ConTeXt Format". p. 88
- ↑ a b List of ConTeXt modules at contextgarden
- ↑ PPCHTeX Module for ConTeXt reference page at contextgarden
- ↑ List of ConTeXt modules (static page)
- ↑ List of ConTeXt modules in web server for downloading
- ↑ Hans Hagen Interview, 2006
- ↑ Script error: No such module "citation/CS1".
- ↑ Repository of new reference manual Template:Webarchive
- ↑ License notice of new official manual Template:Webarchive
- ↑ Part of thread about context manual where Taco Hoekwater recognises that new manual is licensed under the GFDL and he should put license note on the current directory of manual
- ↑ Up-to-date chapters of manual: Fonts and Typography. April 2009.
- ↑ Script error: No such module "citation/CS1".
- ↑ a b Dave Walden interview Hans Hagen. TeX User Group 2006.
- ↑ "Ask Nelly ..." PracTeX Journal. TeX User Group. 2005. Includes an example of ConTeXt document with source code.
- ↑ a b Taco Hoekwater "A short History of $2^4$ parts". ConTeXt User Meeting 2007 (march 24)
- ↑ a b Programme of the ConTeXt User Meeting 2007
- ↑ Script error: No such module "citation/CS1".
- ↑ Hans Hagen The Road to MKIV. ConTeXt User Meeting 2007.
- ↑ MKIV at contextgarden
- ↑ ConTeXt User Meeting 2008 web page
- ↑ Script error: No such module "citation/CS1".
- ↑ ConTeXt at Launchpad.net
- ↑ First ConTeXt blog post
- ↑ Script error: No such module "citation/CS1".
- ↑ Official announcement of ConTeXt Group registration
- ↑ Announcement of lmtx
- ↑ "TeXEXEC explained" manual. Pragma ADE.
- ↑ Script error: No such module "citation/CS1".
Script error: No such module "Check for unknown parameters".