LuaTeX format with extended plainTeX macros

Petr Olsak, 2020, 2021, 2022, 2023

cz Cesky


Tugboat articles [1] [2] [3]

Discussion forum for users

Packages documentation:
math, mte, minim-mp, pdfextra

OpTeX at github (current)
optex-114.zip (14 Feb 2024)
optex-113.zip (16 Nov 2023)
optex-112.zip (24 May 2023)
optex-111.zip (9 Mar 2023)
optex-110.zip (9 Feb 2023)
optex-109.zip (3 Dec 2022)
optex-108.zip (4 Aug 2022)
optex-107.zip (17 May 2022)
optex-106.zip (11 Mar 2022)
optex-105.zip (28 Jan 2022)
optex-104.zip (26 Aug 2021)
optex-103.zip (03 Jun 2021)
optex-102.zip (25 Apr 2021)
optex-101.zip (18 Mar 2021)
optex-100.zip (09 Feb 2021)
optex-19.zip (14 Jan 2021)
optex-18.zip (21 Dec 2020)

Tips, triks, howto
OpTeX at github
FTP site, history
CTUstyle for OpTeX

OpTeX is a LuaTeX format based on Plain TeX macros (by Donald Knuth) and on OPmac macros. The main features are:

OpTeX should be a modern plain TeX with power from OPmac (fonts selection system, colors, external graphics, references, hyperlinks...) with Unicode fonts.

  • OpTeX keeps the simplicity (like in plain TeX and OPmac macros).
  • There are no old obscurities concerning various 8-bit encodings and various engines. We are using only Unicode and only LuaTeX.
  • OpTeX provides a powerful font selection system (for Unicode font families, of course).
  • OpTeX supports hyphenations of all languages installed in your TeX system.
  • All features from OPmac macros are copied (for example, you can see opmac-prospectus.pdf)
  • Macros are documented in the same place where code is.
  • Documentation of all features is at single place.
  • The user namespace of control sequences is separated from internal namespace of OpTeX and primitives (\foo versus \_foo).

TeXlive includes OpTeX in its last version released at CTAN. You can process your document by optex document. Try optex op-demo for example. If the optex command is not present, try to run luatex -fmt optex op-demo.

You can run OpTeX on-line at Overleaf: you can start from this project.

If you have a TeX distribution without OpTeX, you need LuaTeX in version 1.10.0 (2019) or later, luaotfload package 3.12 or later, and you can install OpTeX manually:

   unzip optex-(version).zip
   cd optex/base
   luatex -ini optex.ini

The format file is generated. Copy the optex.fmt file somewhere to your TeX system where format files can be read by LuaTeX. Copy *.opm files to a directory where LuaTeX can read them. You can process your document by luatex -fmt optex document.tex or you can create an alias with name optex (to luatex -fmt optex) in your system.


Announcement of version 1.00

February 2021

I published OpTeX for the first time a year ago. Intensive developmnet took place during that time. I collected many reports from users and implemented new features. Thanks for all that reports.

Now, OpTeX has reached a stable state, in my opinion. I wish to offer users the certainty of the immutability of basic principles of OpTeX so that they can create their macros. This is time to release version 1.00 of OpTeX and to remove the word "beta" from the name of the version.

I plan to continue fixing bugs but I will be very careful not to violate basic features on which users can build their macros. Before I add eventually a new feature, I will think about the change in detail with regard to this principle.



Public domain. More precisely, it is the same as for OPmac macros.

Other relevant software by various authors