summaryrefslogtreecommitdiff
path: root/macros/optex/base/optex.ini
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-04-20 03:00:55 +0000
committerNorbert Preining <norbert@preining.info>2021-04-20 03:00:55 +0000
commitd65c208b161ffee9ce5343fdfdb17d00523cecae (patch)
tree6829c46d8881891365b9be3fb660dba3ca79e6f5 /macros/optex/base/optex.ini
parent272d21375e83d59014b6591075291d172bbfa007 (diff)
CTAN sync 202104200300
Diffstat (limited to 'macros/optex/base/optex.ini')
-rw-r--r--macros/optex/base/optex.ini107
1 files changed, 107 insertions, 0 deletions
diff --git a/macros/optex/base/optex.ini b/macros/optex/base/optex.ini
new file mode 100644
index 0000000000..c695b7d809
--- /dev/null
+++ b/macros/optex/base/optex.ini
@@ -0,0 +1,107 @@
+%% This is part of the OpTeX project, see http://petr.olsak.net/optex
+
+%% OpTeX ini file
+%% Petr Olsak <project started from: Jan. 2020>
+
+% Catcodes:
+
+\catcode `\{=1 % left brace is begin-group character
+\catcode `\}=2 % right brace is end-group character
+\catcode `\$=3 % dollar sign is math shift
+\catcode `\&=4 % ampersand is alignment tab
+\catcode `\#=6 % hash mark is macro parameter character
+\catcode `\^=7 %
+\catcode `\^^K=7 % circumflex and uparrow are for superscripts
+\catcode `\^^A=8 % downarrow is for subscripts
+\catcode `\^^I=10 % ascii tab is a blank space
+\catcode `\_=11 % underline can be used in control sequences
+\catcode `\~=13 % tilde is active
+\catcode `\^^a0=13 % non breaking space in Unicode
+\catcode 127=12 % normal character
+
+% OpTeX version
+
+\def\optexversion{1.01 Mar.2021}
+\def\fmtname{OpTeX}
+\let\fmtversion=\optexversion
+
+% Engine testing:
+
+\newlinechar=`\^^J
+\ifx\directlua\undefined
+ \message{This format is based only on LuaTeX, use luatex -ini optex.ini^^J}
+ \endinput \fi
+
+\ifx\bgroup\undefined \else
+ \message{This file can be used only for format initialisation, use luatex -ini^^J}
+ \endinput \fi
+
+% Basic .opm syntax:
+
+\let\_endcode =\endinput
+\def \_codedecl #1#2{\message{#2^^J}}% information about .opm file
+\long\def\_doc#1\_cod#2 {} % skip documentation
+
+% Initialization:
+
+\message{OpTeX (Olsak's Plain TeX) initialization <\optexversion>^^J}
+
+\input prefixed.opm % prefixed primitives and code syntax
+\input luatex-ini.opm % luaTeX initialization
+\input basic-macros.opm % basic macros
+\input alloc.opm % allocators for registers
+\input if-macros.opm % special \if-macros, \is-macros and loops
+\input parameters.opm % parameters setting
+\input more-macros.opm % OpTeX useful macros (todo: doc)
+\input keyval.opm % key=value dictionaries
+\input plain-macros.opm % plainTeX macros
+\input fonts-preload.opm % preloaded Latin Modern fonts
+\input fonts-resize.opm % font resizing (low-level macros)
+\input fonts-select.opm % font selection system
+\input math-preload.opm % math fams CM + AMS preloaded
+\input math-macros.opm % basic macros for math plus mathchardefs
+\input math-unicode.opm % macros for loading UnicodeMath fonts
+\input fonts-opmac.opm % font managing macros from OPmac
+\input output.opm % output routine
+\input margins.opm % macros for margins setting
+\input colors.opm % colors
+\input ref-file.opm % ref file
+\input references.opm % references
+\input hyperlinks.opm % hyperlinks
+\input maketoc.opm % maketoc
+\input outlines.opm % PDF outlines
+\input pdfuni-string.opm % PDFunicode strings for outlines
+\input sections.opm % titles, chapters, sections
+\input lists.opm % lists, \begitems, \enditems
+\input verbatim.opm % verbatim
+\input hi-syntax.opm % syntax highlighting of verbatim listimgs
+\input graphics.opm % graphics
+\input table.opm % table macro
+\input multicolumns.opm % more columns by \begmulti ...\endmulti
+\input cite-bib.opm % Bibliography, \cite
+\input makeindex.opm % Make index and sorting
+\input fnotes.opm % \fnotes, \mnotes
+\input styles.opm % styles \report, \letter
+\input logos.opm % standard logos
+\input uni-lcuc.opm % Setting lccodes and uccodes for Unicode characters
+\input hyphen-lan.opm % initialization of hyphenation patterns
+\input languages.opm % languages
+\input others.opm % miscenaleous
+
+\_directlua{
+ % preload OpTeX's lua code into format as bytecode
+ lua.bytecode[1] = assert(loadfile(kpse.find_file("optex", "lua")))
+}
+
+\_everyjob = {%
+ \_message{This is OpTeX (Olsak's Plain TeX), version <\optexversion>^^J}%
+ \_mathchardef\_fnotestack=\_pdfcolorstackinit page {0 g 0 G}%
+ \_directlua{lua.bytecode[1]()}% load OpTeX's Lua code
+ \_mathsbon % replaces \int_a^b to \int _a^b
+ \_inputref % inputs \jobname.ref if exists
+}
+
+\_dump
+
+\_endcode % ------------------------------
+