🚧 This page is currently being revised and reconstructed.
Its structure, examples, and explanations are being updated for current ConTeXt and LuaMetaTeX. Please feel free to edit, correct, or improve this page while the revision is in progress.
Input and compilation · Overview · Project and file management · Sample documents
Contents
-
1
Sample documents
- 1.1 1. Finding an example
- 1.2 2. Chronological index
- 1.3 3. Technical status
- 1.4 4. PRAGMA documents and official sources
- 1.5 5. Simple documents
- 1.6 6. Theses and academic projects
- 1.7 7. Labels, cards, and imposed material
- 1.8 8. Presentations and screen documents
- 1.9 9. Books and periodicals
- 1.10 10. MetaPost and MetaFun documents
- 1.11 11. Reports
- 1.12 12. Reviewing an old sample
- 1.13 13. Suggested metadata for sample pages
- 1.14 14. Contributing or modernizing a sample
- 1.15 15. Related pages
This page collects examples of complete or substantial ConTeXt documents: letters, theses, presentations, books, reports, graphical documents, and other real-world layouts.
The collection spans more than twenty years of ConTeXt development. Some examples are suitable starting points for current work; others are valuable mainly for studying document design or earlier ConTeXt techniques.
A sample document should therefore be read along two independent axes:
document type technical status
| |
+-- thesis +-- LMTX-tested
+-- presentation +-- current, untested
+-- book +-- legacy, untested
+-- report +-- known deprecated code
+-- graphics
A sample is not necessarily a template.
Sample documents are useful for studying how several ConTeXt mechanisms work together: page design, typography, document structure, project organization, graphics, notes, bibliographies, and reusable definitions.
Before reusing old source code in a new project, check the relevant commands, modules, fonts, and file organization with current ConTeXt.
For the complete category listing, see all sample documents in this wiki.
1. Finding an example
There are three useful ways to navigate this collection:
| If you want to... | Use |
|---|---|
| find a particular kind of document | the thematic sections below |
| see when an example was created | the chronological index |
| judge whether old code is safe to reuse | the technical status |
If you are primarily interested in organizing a substantial multifile document, see first Project and file management.
For page design and document structure, see also:
- Document layout tutorials ;
- Document structure and headlines ;
- Graphical programming with MetaPost and MetaFun .
2. Chronological index
Where a creation or publication date is known, it is recorded here.
The date tells you when an example belongs in the history of ConTeXt; it does not by itself tell you whether the source still works.
| Date | Example | Type | Technical note |
|---|---|---|---|
| 2023 | ConTeXt for pres(id)ent(ation) | Presentation | Recent example |
| 2023 | Step-by-step book layout | Book | Recent tutorial |
| 2014 | Invoice 2 | Invoice | Not yet classified for current LMTX |
| 2011 | Fairy style | Book | Older example |
| 2008 | Proceedings style | Book / proceedings | Older example |
| 2005 | Conference presentation by Brooks | Presentation | Older external example |
| 2004 | Uno style | Book | Older example |
| 2004 | ConTeXt info style | Presentation | Older example |
| 2004 | Skdk style | Presentation | Older example |
| 2001 | Ubuch style | Book | Contains deprecated code |
Examples for which no reliable creation or publication date is currently known remain in the thematic sections below.
Creation date and test date are different facts.
A page may eventually record, for example:
Created / published: 2004 Last tested with LMTX: 2026
An old example may work perfectly with current ConTeXt, while a newer example may still depend on particular fonts, modules, or assumptions.
3. Technical status
As pages are reviewed, their technical status should ideally be described independently of their age.
| Status | Meaning |
|---|---|
| LMTX-tested | The example has recently been compiled and its relevant behaviour checked with current LuaMetaTeX/LMTX. |
| Current, not yet tested | The example is relatively recent, but this wiki revision has not independently verified it. |
| Legacy, untested | The example comes from an earlier ConTeXt generation and has not yet been checked with current LMTX. |
| Known deprecated code | At least one part of the implementation is known to require modernization. |
Unknown is better than guessed.
If an example has not been tested, mark it as untested rather than inferring compatibility from its date.
4. PRAGMA documents and official sources
The ConTeXt distribution itself contains manuals, demonstrations, and substantial source documents.
Useful starting points include:
- This Way and My Way magazines , whose source code is included in the documents;
- the official manuals ;
- the ConTeXt source mirror .
These are particularly useful for studying how several ConTeXt mechanisms are combined in real documents.
4.1 Historical pdfTeX documentation
The following documents belong to an earlier stage of the ConTeXt/pdfTeX ecosystem and are retained primarily for historical and typographical interest:
5. Simple documents
These examples concentrate on relatively self-contained document types.
- Letter —
German DIN Letter style by Holger Schöner.
- Building application —
French Bauplan style.
- Research paper —
MLA style.
- Academic work —
Law Faculty University of Ljubljana style and citations for diploma theses and related work.
- Calendar —
Calendar script.
- Curriculum vitæ —
Curriculum vitæ.
- Invoice —
Invoice using Wolfgang's letter module.
- Invoice, alternative example —
Invoice 2 (2014).
- DIN long folder —
DIN lang folder.
6. Theses and academic projects
Theses are particularly useful sample documents because they commonly combine document structure, frontmatter and backmatter, bibliographies, figures, cross-references, environments, and multiple source files.
6.1 Aditya Mahajan's thesis
This is a complete thesis rather than a minimal template and is useful for studying how a large real document is assembled.
6.2 UTM thesis template
The repository includes separate document parts and project-level setup.
6.3 General thesis template
Another example of a substantial multifile thesis.
6.4 Older thesis example
- PhD thesis style file using a KOMA-script-inspired layout.
Treat this as legacy source unless its current behaviour has been retested.
7. Labels, cards, and imposed material
These examples deal with several independent objects placed on one physical page.
- Business card — many identical cards on one page;
- File card — many different cards on one page;
- Creating self-adhesive labels — labels for jars and similar objects.
8. Presentations and screen documents
See also Presentations.
8.1 Step-by-step presentation construction
Aditya Mahajan's Creating a clean presentation style in 40 commits develops a presentation environment incrementally.
Its pedagogical value lies in showing individual design decisions rather than presenting one large unexplained style file.
8.2 More recent presentation styles
- ConTeXt for pres(id)ent(ation) — three presentation styles by Hraban , 2023.
8.3 Earlier presentation examples
- ConTeXt info style by Hraban , with help from Hans Hagen, 2004;
- Skdk style by Hraban , 2004;
These are useful for studying presentation design, but their implementation should be checked before being used as the basis of a current LMTX style.
8.4 Interactive screen document
- Midgard character sheet — interactive form for the German RPG Midgard , by Hraban .
9. Books and periodicals
Books are useful for studying the interaction between page layout, headings, notes, illustrations, and project organization.
9.1 Step-by-step book layout
- Step-by-step book layout tutorial by Mikael Sundqvist, 2023.
9.2 Book examples in the Garden
- Ubuch style by Hraban , 2001 — contains deprecated code;
- Theory book style by Thomas ;
- Proceedings style by Hraban , 2008;
- Fairy style by Hraban , 2011;
- Sidenotes style by Andy ;
- Catalogue raisonné by Peter .
Separate design from implementation.
An older book may still provide excellent ideas for chapter openings, running heads, margins, sidenotes, title pages, or page proportions even when some of its code needs modernization.
10. MetaPost and MetaFun documents
See Graphical programming with MetaPost and MetaFun.
Examples include:
- Cover pages by Hans Hagen and others;
- Colorful CD inlay by Hans Hagen;
- A full CD booklet for the Dresden choir Wild Roses Crew .
These illustrate how MetaFun can form part of the architecture and visual language of a complete document.
11. Reports
The report example combines several mechanisms in one substantial design:
- page-aware headings;
- structural numbering;
- MetaFun graphics;
- highlighted text blocks;
- local notes;
- frontmatter, bodymatter, appendices, and backmatter;
- custom font setup.
It is useful for studying how separate ConTeXt mechanisms can be combined into a coherent document rather than treated as isolated commands.
12. Reviewing an old sample
When updating an old example for current LMTX, use a conservative workflow:
compile the original sample
|
+-- works
| |
| +--> record current behaviour
|
+-- fails
|
v
locate the failing mechanism
|
v
minimal test
|
v
update only what is needed
|
v
compile the complete sample again
This preserves working techniques and makes each modernization traceable.
13. Suggested metadata for sample pages
As individual pages are reviewed, they should ideally record:
Document type: Created / published: ConTeXt generation: Last tested with LMTX: Special requirements: Source available:
For example:
Document type: presentation Created / published: 2004 ConTeXt generation: MkII / early MkIV Last tested with LMTX: not yet tested Special requirements: unknown Source available: yes
Unknown information should remain explicitly unknown rather than being guessed.
14. Contributing or modernizing a sample
A useful sample page should explain:
- what kind of document it demonstrates;
- when it was created or published, if known;
- whether it has been tested with current LMTX;
- what techniques are worth studying;
- whether special fonts, modules, or external files are required;
- how the example should be compiled.
If an example no longer compiles, identify the obsolete mechanism when possible instead of simply declaring the whole document unusable.
15. Related pages
- Input and compilation
- Project and file management
- Document structure and headlines
- Document layout tutorials
- Presentations
- Graphical programming with MetaPost and MetaFun
- All sample documents
Input and compilation · Overview · Project and file management · Sample documents