summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2022-12-21 18:00:37 +0100
committerContext Git Mirror Bot <phg@phi-gamma.net>2022-12-21 18:00:37 +0100
commit36355f3d0c23357fccf2c76b3e9605a41cae519d (patch)
tree7b2bfa701a21ed8b075deba24112583461706770
parent8f472c629a996f1c08281198210354a253d7f56b (diff)
downloadcontext-36355f3d0c23357fccf2c76b3e9605a41cae519d.tar.gz
2022-12-21 17:12:00
-rw-r--r--context/data/scite/context/lexers/data/scite-context-data-context.lua4
-rw-r--r--context/data/scite/context/lexers/data/scite-context-data-tex.lua4
-rw-r--r--context/data/scite/context/scite-context-data-context.properties643
-rw-r--r--context/data/scite/context/scite-context-data-tex.properties267
-rw-r--r--doc/context/sources/general/manuals/lowlevel/lowlevel-boxes.tex32
-rw-r--r--doc/context/sources/general/manuals/lowlevel/lowlevel-registers.tex35
-rw-r--r--doc/context/sources/general/manuals/luametatex/luametatex.tex4
-rw-r--r--metapost/context/base/mpxl/mp-apos.mpxl3
-rw-r--r--source/luametatex/source/lua/lmtinterface.c2
-rw-r--r--source/luametatex/source/lua/lmtinterface.h1
-rw-r--r--source/luametatex/source/lua/lmtnodelib.c1
-rw-r--r--source/luametatex/source/lua/lmttexlib.c153
-rw-r--r--source/luametatex/source/lua/lmttokenlib.c6
-rw-r--r--source/luametatex/source/luametatex.h2
-rw-r--r--source/luametatex/source/tex/texcommands.c11
-rw-r--r--source/luametatex/source/tex/texcommands.h9
-rw-r--r--source/luametatex/source/tex/texdumpdata.h2
-rw-r--r--source/luametatex/source/tex/texequivalents.c34
-rw-r--r--source/luametatex/source/tex/texequivalents.h8
-rw-r--r--source/luametatex/source/tex/texmaincontrol.c256
-rw-r--r--source/luametatex/source/tex/texmath.c3
-rw-r--r--source/luametatex/source/tex/texnodes.c2
-rw-r--r--source/luametatex/source/tex/texnodes.h7
-rw-r--r--source/luametatex/source/tex/texpackaging.c104
-rw-r--r--source/luametatex/source/tex/texpackaging.h2
-rw-r--r--source/luametatex/source/tex/texscanning.c37
-rw-r--r--source/luametatex/source/tex/textoken.c2
-rw-r--r--source/luametatex/source/tex/textypes.h25
-rw-r--r--tex/context/base/mkii/cont-new.mkii2
-rw-r--r--tex/context/base/mkii/context.mkii2
-rw-r--r--tex/context/base/mkii/mult-ro.mkii1
-rw-r--r--tex/context/base/mkiv/char-def.lua1
-rw-r--r--tex/context/base/mkiv/colo-ini.lua18
-rw-r--r--tex/context/base/mkiv/cont-new.mkiv2
-rw-r--r--tex/context/base/mkiv/context.mkiv2
-rw-r--r--tex/context/base/mkiv/font-dsp.lua4
-rw-r--r--tex/context/base/mkiv/meta-imp-dum.mkiv6
-rw-r--r--tex/context/base/mkiv/mult-def.lua3
-rw-r--r--tex/context/base/mkiv/mult-low.lua9
-rw-r--r--tex/context/base/mkiv/mult-prm.lua5
-rw-r--r--tex/context/base/mkiv/status-files.pdfbin24575 -> 24587 bytes
-rw-r--r--tex/context/base/mkiv/status-lua.pdfbin264780 -> 264782 bytes
-rw-r--r--tex/context/base/mkiv/syst-ini.mkiv4
-rw-r--r--tex/context/base/mkxl/anch-bar.mkxl18
-rw-r--r--tex/context/base/mkxl/anch-bck.mklx28
-rw-r--r--tex/context/base/mkxl/anch-box.mkxl63
-rw-r--r--tex/context/base/mkxl/anch-pgr.mkxl4
-rw-r--r--tex/context/base/mkxl/anch-pos.mkxl33
-rw-r--r--tex/context/base/mkxl/anch-snc.mkxl4
-rw-r--r--tex/context/base/mkxl/anch-tab.mkxl10
-rw-r--r--tex/context/base/mkxl/attr-ini.mkxl6
-rw-r--r--tex/context/base/mkxl/back-exp.mkxl6
-rw-r--r--tex/context/base/mkxl/bibl-bib.mkxl10
-rw-r--r--tex/context/base/mkxl/bibl-tra.mkxl30
-rw-r--r--tex/context/base/mkxl/buff-ini.mkxl8
-rw-r--r--tex/context/base/mkxl/buff-ver.mkxl12
-rw-r--r--tex/context/base/mkxl/catc-ini.mkxl16
-rw-r--r--tex/context/base/mkxl/chem-str.mkxl6
-rw-r--r--tex/context/base/mkxl/cldf-ini.mkxl2
-rw-r--r--tex/context/base/mkxl/colo-ext.mkxl2
-rw-r--r--tex/context/base/mkxl/colo-grp.mkxl4
-rw-r--r--tex/context/base/mkxl/colo-ini.mkxl33
-rw-r--r--tex/context/base/mkxl/cont-new.mkxl2
-rw-r--r--tex/context/base/mkxl/context.mkxl2
-rw-r--r--tex/context/base/mkxl/core-dat.mkxl4
-rw-r--r--tex/context/base/mkxl/core-ini.mkxl4
-rw-r--r--tex/context/base/mkxl/core-sys.mkxl6
-rw-r--r--tex/context/base/mkxl/file-ini.mklx16
-rw-r--r--tex/context/base/mkxl/file-job.lmt16
-rw-r--r--tex/context/base/mkxl/file-job.mklx9
-rw-r--r--tex/context/base/mkxl/file-mod.mklx8
-rw-r--r--tex/context/base/mkxl/font-dsp.lmt4
-rw-r--r--tex/context/base/mkxl/font-ini.mklx24
-rw-r--r--tex/context/base/mkxl/font-lib.mklx18
-rw-r--r--tex/context/base/mkxl/font-mat.mklx2
-rw-r--r--tex/context/base/mkxl/grph-fig.mkxl22
-rw-r--r--tex/context/base/mkxl/grph-inc.mkxl16
-rw-r--r--tex/context/base/mkxl/grph-trf.mkxl56
-rw-r--r--tex/context/base/mkxl/lang-frq.mkxl2
-rw-r--r--tex/context/base/mkxl/lang-hup.mkxl2
-rw-r--r--tex/context/base/mkxl/lang-hyp.mkxl2
-rw-r--r--tex/context/base/mkxl/lang-ini.mkxl10
-rw-r--r--tex/context/base/mkxl/layo-ini.mkxl4
-rw-r--r--tex/context/base/mkxl/lpdf-rul.lmt31
-rw-r--r--tex/context/base/mkxl/math-act.lmt26
-rw-r--r--tex/context/base/mkxl/math-ali.mkxl95
-rw-r--r--tex/context/base/mkxl/math-del.mkxl6
-rw-r--r--tex/context/base/mkxl/math-fen.mkxl21
-rw-r--r--tex/context/base/mkxl/math-frc.mkxl2
-rw-r--r--tex/context/base/mkxl/math-ini.mkxl38
-rw-r--r--tex/context/base/mkxl/math-stc.mklx26
-rw-r--r--tex/context/base/mkxl/meta-ini.mkxl8
-rw-r--r--tex/context/base/mkxl/meta-nod.mkxl4
-rw-r--r--tex/context/base/mkxl/meta-pdh.mkxl4
-rw-r--r--tex/context/base/mkxl/mlib-pdf.mkxl14
-rw-r--r--tex/context/base/mkxl/mult-aux.mkxl22
-rw-r--r--tex/context/base/mkxl/node-bck.lmt3
-rw-r--r--tex/context/base/mkxl/node-fin.mkxl4
-rw-r--r--tex/context/base/mkxl/node-ini.mkxl4
-rw-r--r--tex/context/base/mkxl/node-rul.mkxl32
-rw-r--r--tex/context/base/mkxl/pack-bck.mklx2
-rw-r--r--tex/context/base/mkxl/pack-box.mkxl54
-rw-r--r--tex/context/base/mkxl/pack-com.mkxl59
-rw-r--r--tex/context/base/mkxl/pack-cut.mkxl12
-rw-r--r--tex/context/base/mkxl/pack-lyr.mkxl36
-rw-r--r--tex/context/base/mkxl/pack-mat.mkxl8
-rw-r--r--tex/context/base/mkxl/pack-mrl.mkxl2
-rw-r--r--tex/context/base/mkxl/pack-obj.mkxl13
-rw-r--r--tex/context/base/mkxl/pack-pos.mkxl22
-rw-r--r--tex/context/base/mkxl/pack-rul.mkxl133
-rw-r--r--tex/context/base/mkxl/page-app.mkxl6
-rw-r--r--tex/context/base/mkxl/page-bck.mkxl20
-rw-r--r--tex/context/base/mkxl/page-blk.mkxl2
-rw-r--r--tex/context/base/mkxl/page-box.mklx10
-rw-r--r--tex/context/base/mkxl/page-brk.mkxl6
-rw-r--r--tex/context/base/mkxl/page-col.mkxl18
-rw-r--r--tex/context/base/mkxl/page-com.mkxl12
-rw-r--r--tex/context/base/mkxl/page-cst.mkxl36
-rw-r--r--tex/context/base/mkxl/page-ffl.mkxl41
-rw-r--r--tex/context/base/mkxl/page-flt.mkxl37
-rw-r--r--tex/context/base/mkxl/page-flw.mkxl2
-rw-r--r--tex/context/base/mkxl/page-imp.mkxl41
-rw-r--r--tex/context/base/mkxl/page-ini.mkxl6
-rw-r--r--tex/context/base/mkxl/page-ins.mkxl6
-rw-r--r--tex/context/base/mkxl/page-lay.mkxl160
-rw-r--r--tex/context/base/mkxl/page-lin.mklx20
-rw-r--r--tex/context/base/mkxl/page-mbk.mklx2
-rw-r--r--tex/context/base/mkxl/page-mcl.mkxl40
-rw-r--r--tex/context/base/mkxl/page-mix.mkxl38
-rw-r--r--tex/context/base/mkxl/page-mrk.mkxl8
-rw-r--r--tex/context/base/mkxl/page-not.mkxl2
-rw-r--r--tex/context/base/mkxl/page-one.mkxl26
-rw-r--r--tex/context/base/mkxl/page-otr.mklx6
-rw-r--r--tex/context/base/mkxl/page-pcl.mkxl44
-rw-r--r--tex/context/base/mkxl/page-pst.mkxl2
-rw-r--r--tex/context/base/mkxl/page-sel.mklx12
-rw-r--r--tex/context/base/mkxl/page-sid.mkxl130
-rw-r--r--tex/context/base/mkxl/page-txt.mklx2
-rw-r--r--tex/context/base/mkxl/publ-ini.mkxl20
-rw-r--r--tex/context/base/mkxl/scrn-bar.mklx36
-rw-r--r--tex/context/base/mkxl/scrn-but.mklx30
-rw-r--r--tex/context/base/mkxl/scrn-fld.mklx32
-rw-r--r--tex/context/base/mkxl/scrn-hlp.mklx8
-rw-r--r--tex/context/base/mkxl/scrn-pag.mklx36
-rw-r--r--tex/context/base/mkxl/scrn-wid.mklx4
-rw-r--r--tex/context/base/mkxl/spac-ali.mkxl4
-rw-r--r--tex/context/base/mkxl/spac-grd.mkxl10
-rw-r--r--tex/context/base/mkxl/spac-hor.mkxl66
-rw-r--r--tex/context/base/mkxl/spac-lin.mkxl8
-rw-r--r--tex/context/base/mkxl/spac-pag.mkxl6
-rw-r--r--tex/context/base/mkxl/spac-par.mkxl14
-rw-r--r--tex/context/base/mkxl/spac-ver.lmt5
-rw-r--r--tex/context/base/mkxl/spac-ver.mkxl168
-rw-r--r--tex/context/base/mkxl/strc-con.mklx22
-rw-r--r--tex/context/base/mkxl/strc-flt.mklx61
-rw-r--r--tex/context/base/mkxl/strc-ind.mkxl10
-rw-r--r--tex/context/base/mkxl/strc-itm.mklx50
-rw-r--r--tex/context/base/mkxl/strc-lnt.mklx8
-rw-r--r--tex/context/base/mkxl/strc-lst.mklx4
-rw-r--r--tex/context/base/mkxl/strc-mat.mkxl41
-rw-r--r--tex/context/base/mkxl/strc-not.mklx15
-rw-r--r--tex/context/base/mkxl/strc-pag.mkxl2
-rw-r--r--tex/context/base/mkxl/strc-ref.mklx42
-rw-r--r--tex/context/base/mkxl/strc-reg.mkxl14
-rw-r--r--tex/context/base/mkxl/strc-ren.mkxl32
-rw-r--r--tex/context/base/mkxl/strc-sec.mkxl8
-rw-r--r--tex/context/base/mkxl/supp-box.mkxl182
-rw-r--r--tex/context/base/mkxl/syst-aux.mkxl100
-rw-r--r--tex/context/base/mkxl/syst-ini.mkxl174
-rw-r--r--tex/context/base/mkxl/tabl-frm.mkxl18
-rw-r--r--tex/context/base/mkxl/tabl-ltb.mkxl64
-rw-r--r--tex/context/base/mkxl/tabl-mis.mkxl22
-rw-r--r--tex/context/base/mkxl/tabl-ntb.mkxl227
-rw-r--r--tex/context/base/mkxl/tabl-tab.mkxl116
-rw-r--r--tex/context/base/mkxl/tabl-tbl.mkxl118
-rw-r--r--tex/context/base/mkxl/tabl-tsp.mkxl37
-rw-r--r--tex/context/base/mkxl/tabl-xtb.mklx36
-rw-r--r--tex/context/base/mkxl/trac-tex.mkxl4
-rw-r--r--tex/context/base/mkxl/trac-vis.lmt245
-rw-r--r--tex/context/base/mkxl/trac-vis.mkxl4
-rw-r--r--tex/context/base/mkxl/type-ini.mklx6
-rw-r--r--tex/context/base/mkxl/typo-ada.mkxl21
-rw-r--r--tex/context/base/mkxl/typo-chr.mkxl2
-rw-r--r--tex/context/base/mkxl/typo-del.mkxl12
-rw-r--r--tex/context/base/mkxl/typo-drp.mkxl2
-rw-r--r--tex/context/base/mkxl/typo-hid.mkxl6
-rw-r--r--tex/context/base/mkxl/typo-itm.mkxl24
-rw-r--r--tex/context/base/mkxl/typo-lbx.mkxl14
-rw-r--r--tex/context/base/mkxl/typo-mar.mkxl6
-rw-r--r--tex/context/base/mkxl/typo-ovl.mkxl2
-rw-r--r--tex/context/base/mkxl/typo-shp.mkxl8
-rw-r--r--tex/context/base/mkxl/typo-syn.mkxl8
-rw-r--r--tex/context/base/mkxl/typo-tal.mkxl4
-rw-r--r--tex/context/interface/mkii/keys-ro.xml1
-rw-r--r--tex/context/modules/mkxl/m-crappyspec.mkxl6
-rw-r--r--tex/context/modules/mkxl/m-oldmath.mkxl6
-rw-r--r--tex/context/modules/mkxl/s-colors-show.mkxl4
-rw-r--r--tex/context/modules/mkxl/s-fonts-show.mkxl4
-rw-r--r--tex/context/modules/mkxl/x-mathml.mkxl22
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua4
200 files changed, 3208 insertions, 2715 deletions
diff --git a/context/data/scite/context/lexers/data/scite-context-data-context.lua b/context/data/scite/context/lexers/data/scite-context-data-context.lua
index 2c34100a0..3ff2844fa 100644
--- a/context/data/scite/context/lexers/data/scite-context-data-context.lua
+++ b/context/data/scite/context/lexers/data/scite-context-data-context.lua
@@ -1,4 +1,4 @@
return {
- ["constants"]={ "zerocount", "minusone", "minustwo", "plusone", "plustwo", "plusthree", "plusfour", "plusfive", "plussix", "plusseven", "pluseight", "plusnine", "plusten", "pluseleven", "plustwelve", "plussixteen", "plusfifty", "plushundred", "plusonehundred", "plustwohundred", "plusfivehundred", "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "maxcardminusone", "zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxcount", "maxdimen", "scaledpoint", "thousandpoint", "points", "halfpoint", "zeroskip", "centeringskip", "stretchingskip", "shrinkingskip", "centeringfillskip", "stretchingfillskip", "shrinkingfillskip", "zeromuskip", "onemuskip", "pluscxxvii", "pluscxxviii", "pluscclv", "pluscclvi", "normalpagebox", "binaryshiftedten", "binaryshiftedtwenty", "binaryshiftedthirty", "thickermuskip", "directionlefttoright", "directionrighttoleft", "endoflinetoken", "outputnewlinechar", "emptytoks", "empty", "undefined", "prerollrun", "voidbox", "emptybox", "emptyvbox", "emptyhbox", "bigskipamount", "medskipamount", "smallskipamount", "fmtname", "fmtversion", "texengine", "texenginename", "texengineversion", "texenginefunctionality", "luatexengine", "pdftexengine", "xetexengine", "unknownengine", "contextformat", "contextversion", "contextlmtxmode", "contextmark", "mksuffix", "activecatcode", "bgroup", "egroup", "endline", "conditionaltrue", "conditionalfalse", "attributeunsetvalue", "statuswrite", "uprotationangle", "rightrotationangle", "downrotationangle", "leftrotationangle", "inicatcodes", "ctxcatcodes", "texcatcodes", "notcatcodes", "txtcatcodes", "vrbcatcodes", "prtcatcodes", "nilcatcodes", "luacatcodes", "tpacatcodes", "tpbcatcodes", "xmlcatcodes", "ctdcatcodes", "rlncatcodes", "escapecatcode", "begingroupcatcode", "endgroupcatcode", "mathshiftcatcode", "alignmentcatcode", "endoflinecatcode", "parametercatcode", "superscriptcatcode", "subscriptcatcode", "ignorecatcode", "spacecatcode", "lettercatcode", "othercatcode", "activecatcode", "commentcatcode", "invalidcatcode", "tabasciicode", "newlineasciicode", "formfeedasciicode", "endoflineasciicode", "endoffileasciicode", "commaasciicode", "spaceasciicode", "periodasciicode", "hashasciicode", "dollarasciicode", "commentasciicode", "ampersandasciicode", "colonasciicode", "backslashasciicode", "circumflexasciicode", "underscoreasciicode", "leftbraceasciicode", "barasciicode", "rightbraceasciicode", "tildeasciicode", "delasciicode", "leftparentasciicode", "rightparentasciicode", "lessthanasciicode", "morethanasciicode", "doublecommentsignal", "atsignasciicode", "exclamationmarkasciicode", "questionmarkasciicode", "doublequoteasciicode", "singlequoteasciicode", "forwardslashasciicode", "primeasciicode", "hyphenasciicode", "percentasciicode", "leftbracketasciicode", "rightbracketasciicode", "hsizefrozenparcode", "skipfrozenparcode", "hangfrozenparcode", "indentfrozenparcode", "parfillfrozenparcode", "adjustfrozenparcode", "protrudefrozenparcode", "tolerancefrozenparcode", "stretchfrozenparcode", "loosenessfrozenparcode", "lastlinefrozenparcode", "linepenaltyfrozenparcode", "clubpenaltyfrozenparcode", "widowpenaltyfrozenparcode", "displaypenaltyfrozenparcode", "brokenpenaltyfrozenparcode", "demeritsfrozenparcode", "shapefrozenparcode", "linefrozenparcode", "hyphenationfrozenparcode", "shapingpenaltyfrozenparcode", "orphanpenaltyfrozenparcode", "allfrozenparcode", "mathpenaltyfrozenparcode", "activemathcharcode", "activetabtoken", "activeformfeedtoken", "activeendoflinetoken", "batchmodecode", "nonstopmodecode", "scrollmodecode", "errorstopmodecode", "bottomlevelgroupcode", "simplegroupcode", "hboxgroupcode", "adjustedhboxgroupcode", "vboxgroupcode", "vtopgroupcode", "aligngroupcode", "noaligngroupcode", "outputgroupcode", "mathgroupcode", "discretionarygroupcode", "insertgroupcode", "vadjustgroupcode", "vcentergroupcode", "mathabovegroupcode", "mathchoicegroupcode", "alsosimplegroupcode", "semisimplegroupcode", "mathshiftgroupcode", "mathleftgroupcode", "localboxgroupcode", "splitoffgroupcode", "splitkeepgroupcode", "preamblegroupcode", "alignsetgroupcode", "finrowgroupcode", "discretionarygroupcode", "markautomigrationcode", "insertautomigrationcode", "adjustautomigrationcode", "preautomigrationcode", "postautomigrationcode", "charnodecode", "hlistnodecode", "vlistnodecode", "rulenodecode", "insertnodecode", "marknodecode", "adjustnodecode", "ligaturenodecode", "discretionarynodecode", "whatsitnodecode", "mathnodecode", "gluenodecode", "kernnodecode", "penaltynodecode", "unsetnodecode", "mathsnodecode", "overrulemathcontrolcode", "underrulemathcontrolcode", "radicalrulemathcontrolcode", "fractionrulemathcontrolcode", "accentskewhalfmathcontrolcode", "accentskewapplymathcontrolcode", "applyordinarykernpairmathcontrolcode", "applyverticalitalickernmathcontrolcode", "applyordinaryitalickernmathcontrolcode", "applycharitalickernmathcontrolcode", "reboxcharitalickernmathcontrolcode", "applyboxeditalickernmathcontrolcode", "staircasekernmathcontrolcode", "applytextitalickernmathcontrolcode", "applyscriptitalickernmathcontrolcode", "checkspaceitalickernmathcontrolcode", "checktextitalickernmathcontrolcode", "analyzescriptnucleuscharmathcontrolcode", "analyzescriptnucleuslistmathcontrolcode", "analyzescriptnucleusboxmathcontrolcode", "accenttopskewwithoffsetmathcontrolcode", "ignorekerndimensionsmathcontrolcode", "ignoreflataccentsmathcontrolcode", "extendaccentsmathcontrolcode", "noligaturingglyphoptioncode", "nokerningglyphoptioncode", "noexpansionglyphoptioncode", "noprotrusionglyphoptioncode", "noleftkerningglyphoptioncode", "noleftligaturingglyphoptioncode", "norightkerningglyphoptioncode", "norightligaturingglyphoptioncode", "noitaliccorrectionglyphoptioncode", "islargeoperatorglyphoptioncode", "hasitalicshapeglyphoptioncode", "normalparcontextcode", "vmodeparcontextcode", "vboxparcontextcode", "vtopparcontextcode", "vcenterparcontextcode", "vadjustparcontextcode", "insertparcontextcode", "outputparcontextcode", "alignparcontextcode", "noalignparcontextcode", "spanparcontextcode", "resetparcontextcode", "leftoriginlistanchorcode", "leftheightlistanchorcode", "leftdepthlistanchorcode", "rightoriginlistanchorcode", "rightheightlistanchorcode", "rightdepthlistanchorcode", "centeroriginlistanchorcode", "centerheightlistanchorcode", "centerdepthlistanchorcode", "halfwaytotallistanchorcode", "halfwayheightlistanchorcode", "halfwaydepthlistanchorcode", "halfwayleftlistanchorcode", "halfwayrightlistanchorcode", "negatexlistsigncode", "negateylistsigncode", "negatelistsigncode", "fontslantperpoint", "fontinterwordspace", "fontinterwordstretch", "fontinterwordshrink", "fontexheight", "fontemwidth", "fontextraspace", "slantperpoint", "mathexheight", "mathemwidth", "interwordspace", "interwordstretch", "interwordshrink", "exheight", "emwidth", "extraspace", "mathaxisheight", "muquad", "startmode", "stopmode", "startnotmode", "stopnotmode", "startmodeset", "stopmodeset", "doifmode", "doifelsemode", "doifmodeelse", "doifnotmode", "startmodeset", "stopmodeset", "startallmodes", "stopallmodes", "startnotallmodes", "stopnotallmodes", "doifallmodes", "doifelseallmodes", "doifallmodeselse", "doifnotallmodes", "startenvironment", "stopenvironment", "environment", "startcomponent", "stopcomponent", "component", "startproduct", "stopproduct", "product", "startproject", "stopproject", "project", "starttext", "stoptext", "startnotext", "stopnotext", "startdocument", "stopdocument", "documentvariable", "unexpandeddocumentvariable", "setupdocument", "presetdocument", "doifelsedocumentvariable", "doifdocumentvariableelse", "doifdocumentvariable", "doifnotdocumentvariable", "startmodule", "stopmodule", "usemodule", "usetexmodule", "useluamodule", "setupmodule", "currentmoduleparameter", "moduleparameter", "everystarttext", "everystoptext", "startTEXpage", "stopTEXpage", "enablemode", "disablemode", "preventmode", "definemode", "globalenablemode", "globaldisablemode", "globalpreventmode", "pushmode", "popmode", "typescriptone", "typescripttwo", "typescriptthree", "mathsizesuffix", "mathordinarycode", "mathordcode", "mathoperatorcode", "mathopcode", "mathbinarycode", "mathbincode", "mathrelationcode", "mathrelcode", "mathopencode", "mathclosecode", "mathpunctuationcode", "mathpunctcode", "mathovercode", "mathundercode", "mathinnercode", "mathradicalcode", "mathfractioncode", "mathmiddlecode", "mathaccentcode", "mathfencedcode", "mathghostcode", "mathvariablecode", "mathactivecode", "mathvcentercode", "mathconstructcode", "mathwrappedcode", "mathbegincode", "mathendcode", "mathexplicitcode", "mathdivisioncode", "mathfactorialcode", "mathdimensioncode", "mathexperimentalcode", "mathtextpunctuationcode", "mathimaginarycode", "mathdifferentialcode", "mathexponentialcode", "mathellipsiscode", "mathfunctioncode", "mathdigitcode", "mathalphacode", "mathboxcode", "mathchoicecode", "mathnothingcode", "mathlimopcode", "mathnolopcode", "mathunsetcode", "mathunspacedcode", "mathallcode", "mathfakecode", "mathunarycode", "mathmaybeordinarycode", "mathmayberelationcode", "mathmaybebinarycode", "mathnumbergroupcode", "constantnumber", "constantnumberargument", "constantdimen", "constantdimenargument", "constantemptyargument", "luastringsep", "!!bs", "!!es", "lefttorightmark", "righttoleftmark", "lrm", "rlm", "bidilre", "bidirle", "bidipop", "bidilro", "bidirlo", "breakablethinspace", "nobreakspace", "nonbreakablespace", "narrownobreakspace", "zerowidthnobreakspace", "ideographicspace", "ideographichalffillspace", "twoperemspace", "threeperemspace", "fourperemspace", "fiveperemspace", "sixperemspace", "figurespace", "punctuationspace", "hairspace", "enquad", "emquad", "zerowidthspace", "zerowidthnonjoiner", "zerowidthjoiner", "zwnj", "zwj", "optionalspace", "asciispacechar", "softhyphen", "autoinsertedspace", "Ux", "eUx", "Umathaccents", "parfillleftskip", "parfillrightskip", "startlmtxmode", "stoplmtxmode", "startmkivmode", "stopmkivmode", "wildcardsymbol", "normalhyphenationcode", "automatichyphenationcode", "explicithyphenationcode", "syllablehyphenationcode", "uppercasehyphenationcode", "collapsehyphenationcode", "compoundhyphenationcode", "strictstarthyphenationcode", "strictendhyphenationcode", "automaticpenaltyhyphenationcode", "explicitpenaltyhyphenationcode", "permitgluehyphenationcode", "permitallhyphenationcode", "permitmathreplacehyphenationcode", "forcecheckhyphenationcode", "lazyligatureshyphenationcode", "forcehandlerhyphenationcode", "feedbackcompoundhyphenationcode", "ignoreboundshyphenationcode", "partialhyphenationcode", "completehyphenationcode", "normalizelinenormalizecode", "parindentskipnormalizecode", "swaphangindentnormalizecode", "swapparsshapenormalizecode", "breakafterdirnormalizecode", "removemarginkernsnormalizecode", "clipwidthnormalizecode", "flattendiscretionariesnormalizecode", "discardzerotabskipsnormalizecode", "flattenhleadersnormalizecode", "normalizeparnormalizeparcode", "flattenvleadersnormalizeparcode", "nopreslackclassoptioncode", "nopostslackclassoptioncode", "lefttopkernclassoptioncode", "righttopkernclassoptioncode", "leftbottomkernclassoptioncode", "rightbottomkernclassoptioncode", "lookaheadforendclassoptioncode", "noitaliccorrectionclassoptioncode", "defaultmathclassoptions", "checkligatureclassoptioncode", "checkitaliccorrectionclassoptioncode", "checkkernpairclassoptioncode", "flattenclassoptioncode", "omitpenaltyclassoptioncode", "unpackclassoptioncode", "raiseprimeclassoptioncode", "carryoverlefttopkernclassoptioncode", "carryoverleftbottomkernclassoptioncode", "carryoverrighttopkernclassoptioncode", "carryoverrightbottomkernclassoptioncode", "preferdelimiterdimensionsclassoptioncode", "autoinjectclassoptioncode", "removeitaliccorrectionclassoptioncode", "operatoritaliccorrectionclassoptioncode", "noligaturingglyphoptioncode", "nokerningglyphoptioncode", "noleftligatureglyphoptioncode", "noleftkernglyphoptioncode", "norightligatureglyphoptioncode", "norightkernglyphoptioncode", "noexpansionglyphoptioncode", "noprotrusionglyphoptioncode", "noitaliccorrectionglyphoptioncode", "nokerningcode", "noligaturingcode", "frozenflagcode", "tolerantflagcode", "protectedflagcode", "primitiveflagcode", "permanentflagcode", "noalignedflagcode", "immutableflagcode", "mutableflagcode", "globalflagcode", "overloadedflagcode", "immediateflagcode", "conditionalflagcode", "valueflagcode", "instanceflagcode", "ordmathflattencode", "binmathflattencode", "relmathflattencode", "punctmathflattencode", "innermathflattencode", "normalworddiscoptioncode", "preworddiscoptioncode", "postworddiscoptioncode", "continueifinputfile", "continuewhenlmtxmode", "continuewhenmkivmode" },
- ["helpers"]={ "startsetups", "stopsetups", "startxmlsetups", "stopxmlsetups", "startluasetups", "stopluasetups", "starttexsetups", "stoptexsetups", "startrawsetups", "stoprawsetups", "startlocalsetups", "stoplocalsetups", "starttexdefinition", "stoptexdefinition", "starttexcode", "stoptexcode", "startcontextcode", "stopcontextcode", "startcontextdefinitioncode", "stopcontextdefinitioncode", "texdefinition", "doifelsesetups", "doifsetupselse", "doifsetups", "doifnotsetups", "setup", "setups", "texsetup", "xmlsetup", "luasetup", "directsetup", "fastsetup", "copysetups", "resetsetups", "doifelsecommandhandler", "doifcommandhandlerelse", "doifnotcommandhandler", "doifcommandhandler", "newmode", "setmode", "resetmode", "newsystemmode", "setsystemmode", "resetsystemmode", "pushsystemmode", "popsystemmode", "globalsetmode", "globalresetmode", "globalsetsystemmode", "globalresetsystemmode", "booleanmodevalue", "newcount", "newdimen", "newskip", "newmuskip", "newbox", "newtoks", "newread", "newwrite", "newmarks", "newinsert", "newattribute", "newif", "newlanguage", "newfamily", "newfam", "newhelp", "then", "begcsname", "autorule", "strippedcsname", "checkedstrippedcsname", "nofarguments", "firstargumentfalse", "firstargumenttrue", "secondargumentfalse", "secondargumenttrue", "thirdargumentfalse", "thirdargumenttrue", "fourthargumentfalse", "fourthargumenttrue", "fifthargumentfalse", "fifthargumenttrue", "sixthargumentfalse", "sixthargumenttrue", "seventhargumentfalse", "seventhargumenttrue", "vkern", "hkern", "vpenalty", "hpenalty", "doglobal", "dodoglobal", "redoglobal", "resetglobal", "donothing", "untraceddonothing", "dontcomplain", "moreboxtracing", "lessboxtracing", "noboxtracing", "forgetall", "donetrue", "donefalse", "foundtrue", "foundfalse", "inlineordisplaymath", "indisplaymath", "forcedisplaymath", "startforceddisplaymath", "stopforceddisplaymath", "startpickupmath", "stoppickupmath", "reqno", "forceinlinemath", "mathortext", "thebox", "htdp", "unvoidbox", "hfilll", "vfilll", "mathbox", "mathlimop", "mathnolop", "mathnothing", "mathalpha", "currentcatcodetable", "defaultcatcodetable", "catcodetablename", "newcatcodetable", "startcatcodetable", "stopcatcodetable", "startextendcatcodetable", "stopextendcatcodetable", "pushcatcodetable", "popcatcodetable", "restorecatcodes", "setcatcodetable", "letcatcodecommand", "defcatcodecommand", "uedcatcodecommand", "hglue", "vglue", "hfillneg", "vfillneg", "hfilllneg", "vfilllneg", "ruledhss", "ruledhfil", "ruledhfill", "ruledhfilll", "ruledhfilneg", "ruledhfillneg", "normalhfillneg", "normalhfilllneg", "ruledvss", "ruledvfil", "ruledvfill", "ruledvfilll", "ruledvfilneg", "ruledvfillneg", "normalvfillneg", "normalvfilllneg", "ruledhbox", "ruledvbox", "ruledvtop", "ruledvcenter", "ruledmbox", "ruledhpack", "ruledvpack", "ruledtpack", "ruledhskip", "ruledvskip", "ruledkern", "ruledmskip", "ruledmkern", "ruledhglue", "ruledvglue", "normalhglue", "normalvglue", "ruledpenalty", "filledhboxb", "filledhboxr", "filledhboxg", "filledhboxc", "filledhboxm", "filledhboxy", "filledhboxk", "scratchstring", "scratchstringone", "scratchstringtwo", "tempstring", "scratchcounter", "globalscratchcounter", "privatescratchcounter", "scratchdimen", "globalscratchdimen", "privatescratchdimen", "scratchskip", "globalscratchskip", "privatescratchskip", "scratchmuskip", "globalscratchmuskip", "privatescratchmuskip", "scratchtoks", "globalscratchtoks", "privatescratchtoks", "scratchbox", "globalscratchbox", "privatescratchbox", "scratchmacro", "scratchmacroone", "scratchmacrotwo", "scratchconditiontrue", "scratchconditionfalse", "ifscratchcondition", "scratchconditiononetrue", "scratchconditiononefalse", "ifscratchconditionone", "scratchconditiontwotrue", "scratchconditiontwofalse", "ifscratchconditiontwo", "globalscratchcounterone", "globalscratchcountertwo", "globalscratchcounterthree", "groupedcommand", "groupedcommandcs", "triggergroupedcommand", "triggergroupedcommandcs", "simplegroupedcommand", "simplegroupedcommandcs", "pickupgroupedcommand", "pickupgroupedcommandcs", "mathgroupedcommandcs", "usedbaselineskip", "usedlineskip", "usedlineskiplimit", "availablehsize", "localhsize", "setlocalhsize", "distributedhsize", "hsizefraction", "next", "nexttoken", "nextbox", "dowithnextbox", "dowithnextboxcs", "dowithnextboxcontent", "dowithnextboxcontentcs", "flushnextbox", "boxisempty", "boxtostring", "contentostring", "prerolltostring", "givenwidth", "givenheight", "givendepth", "scangivendimensions", "scratchwidth", "scratchheight", "scratchdepth", "scratchoffset", "scratchdistance", "scratchtotal", "scratchitalic", "scratchhsize", "scratchvsize", "scratchxoffset", "scratchyoffset", "scratchhoffset", "scratchvoffset", "scratchxposition", "scratchyposition", "scratchtopoffset", "scratchbottomoffset", "scratchleftoffset", "scratchrightoffset", "scratchcounterone", "scratchcountertwo", "scratchcounterthree", "scratchcounterfour", "scratchcounterfive", "scratchcountersix", "scratchdimenone", "scratchdimentwo", "scratchdimenthree", "scratchdimenfour", "scratchdimenfive", "scratchdimensix", "scratchskipone", "scratchskiptwo", "scratchskipthree", "scratchskipfour", "scratchskipfive", "scratchskipsix", "scratchmuskipone", "scratchmuskiptwo", "scratchmuskipthree", "scratchmuskipfour", "scratchmuskipfive", "scratchmuskipsix", "scratchtoksone", "scratchtokstwo", "scratchtoksthree", "scratchtoksfour", "scratchtoksfive", "scratchtokssix", "scratchboxone", "scratchboxtwo", "scratchboxthree", "scratchboxfour", "scratchboxfive", "scratchboxsix", "scratchnx", "scratchny", "scratchmx", "scratchmy", "scratchunicode", "scratchmin", "scratchmax", "scratchleftskip", "scratchrightskip", "scratchtopskip", "scratchbottomskip", "doif", "doifnot", "doifelse", "firstinset", "doifinset", "doifnotinset", "doifelseinset", "doifinsetelse", "doifelsenextchar", "doifnextcharelse", "doifelsenextcharcs", "doifnextcharcselse", "doifelsenextoptional", "doifnextoptionalelse", "doifelsenextoptionalcs", "doifnextoptionalcselse", "doifelsefastoptionalcheck", "doiffastoptionalcheckelse", "doifelsefastoptionalcheckcs", "doiffastoptionalcheckcselse", "doifelsenextbgroup", "doifnextbgroupelse", "doifelsenextbgroupcs", "doifnextbgroupcselse", "doifelsenextparenthesis", "doifnextparenthesiselse", "doifelseundefined", "doifundefinedelse", "doifelsedefined", "doifdefinedelse", "doifundefined", "doifdefined", "doifelsevalue", "doifvalue", "doifnotvalue", "doifnothing", "doifsomething", "doifelsenothing", "doifnothingelse", "doifelsesomething", "doifsomethingelse", "doifvaluenothing", "doifvaluesomething", "doifelsevaluenothing", "doifvaluenothingelse", "doifelsedimension", "doifdimensionelse", "doifelsenumber", "doifnumberelse", "doifnumber", "doifnotnumber", "doifelsecommon", "doifcommonelse", "doifcommon", "doifnotcommon", "doifinstring", "doifnotinstring", "doifelseinstring", "doifinstringelse", "doifelseassignment", "doifassignmentelse", "docheckassignment", "doifelseassignmentcs", "doifassignmentelsecs", "validassignment", "novalidassignment", "doiftext", "doifelsetext", "doiftextelse", "doifnottext", "quitcondition", "truecondition", "falsecondition", "tracingall", "tracingnone", "loggingall", "tracingcatcodes", "showluatokens", "aliasmacro", "removetoks", "appendtoks", "prependtoks", "appendtotoks", "prependtotoks", "to", "endgraf", "endpar", "reseteverypar", "finishpar", "empty", "null", "space", "quad", "enspace", "emspace", "charspace", "nbsp", "crlf", "obeyspaces", "obeylines", "obeytabs", "obeypages", "obeyedspace", "obeyedline", "obeyedtab", "obeyedpage", "normalspace", "naturalspace", "controlspace", "normalspaces", "ignoretabs", "ignorelines", "ignorepages", "ignoreeofs", "setcontrolspaces", "executeifdefined", "singleexpandafter", "doubleexpandafter", "tripleexpandafter", "dontleavehmode", "removelastspace", "removeunwantedspaces", "keepunwantedspaces", "removepunctuation", "ignoreparskip", "forcestrutdepth", "onlynonbreakablespace", "wait", "writestatus", "define", "defineexpandable", "redefine", "setmeasure", "setemeasure", "setgmeasure", "setxmeasure", "definemeasure", "freezemeasure", "measure", "measured", "directmeasure", "setquantity", "setequantity", "setgquantity", "setxquantity", "definequantity", "freezequantity", "quantity", "quantitied", "directquantity", "installcorenamespace", "getvalue", "getuvalue", "setvalue", "setevalue", "setgvalue", "setxvalue", "letvalue", "letgvalue", "resetvalue", "undefinevalue", "ignorevalue", "setuvalue", "setuevalue", "setugvalue", "setuxvalue", "globallet", "udef", "ugdef", "uedef", "uxdef", "checked", "unique", "getparameters", "geteparameters", "getgparameters", "getxparameters", "forgetparameters", "copyparameters", "getdummyparameters", "dummyparameter", "directdummyparameter", "setdummyparameter", "letdummyparameter", "setexpandeddummyparameter", "resetdummyparameter", "usedummystyleandcolor", "usedummystyleparameter", "usedummycolorparameter", "processcommalist", "processcommacommand", "quitcommalist", "quitprevcommalist", "processaction", "processallactions", "processfirstactioninset", "processallactionsinset", "unexpanded", "expanded", "startexpanded", "stopexpanded", "protect", "unprotect", "firstofoneargument", "firstoftwoarguments", "secondoftwoarguments", "firstofthreearguments", "secondofthreearguments", "thirdofthreearguments", "firstoffourarguments", "secondoffourarguments", "thirdoffourarguments", "fourthoffourarguments", "firstoffivearguments", "secondoffivearguments", "thirdoffivearguments", "fourthoffivearguments", "fifthoffivearguments", "firstofsixarguments", "secondofsixarguments", "thirdofsixarguments", "fourthofsixarguments", "fifthofsixarguments", "sixthofsixarguments", "firstofoneunexpanded", "firstoftwounexpanded", "secondoftwounexpanded", "firstofthreeunexpanded", "secondofthreeunexpanded", "thirdofthreeunexpanded", "gobbleoneargument", "gobbletwoarguments", "gobblethreearguments", "gobblefourarguments", "gobblefivearguments", "gobblesixarguments", "gobblesevenarguments", "gobbleeightarguments", "gobbleninearguments", "gobbletenarguments", "gobbleoneoptional", "gobbletwooptionals", "gobblethreeoptionals", "gobblefouroptionals", "gobblefiveoptionals", "dorecurse", "doloop", "exitloop", "dostepwiserecurse", "recurselevel", "recursedepth", "dofastloopcs", "fastloopindex", "fastloopfinal", "dowith", "doloopovermatch", "doloopovermatched", "doloopoverlist", "newconstant", "setnewconstant", "setconstant", "setconstantvalue", "newconditional", "settrue", "setfalse", "settruevalue", "setfalsevalue", "setconditional", "newmacro", "setnewmacro", "newfraction", "newsignal", "newboundary", "dosingleempty", "dodoubleempty", "dotripleempty", "doquadrupleempty", "doquintupleempty", "dosixtupleempty", "doseventupleempty", "dosingleargument", "dodoubleargument", "dotripleargument", "doquadrupleargument", "doquintupleargument", "dosixtupleargument", "doseventupleargument", "dosinglegroupempty", "dodoublegroupempty", "dotriplegroupempty", "doquadruplegroupempty", "doquintuplegroupempty", "permitspacesbetweengroups", "dontpermitspacesbetweengroups", "nopdfcompression", "maximumpdfcompression", "normalpdfcompression", "onlypdfobjectcompression", "nopdfobjectcompression", "modulonumber", "dividenumber", "getfirstcharacter", "doifelsefirstchar", "doiffirstcharelse", "mathclassvalue", "startnointerference", "stopnointerference", "twodigits", "threedigits", "leftorright", "offinterlineskip", "oninterlineskip", "nointerlineskip", "strut", "halfstrut", "quarterstrut", "depthstrut", "halflinestrut", "noheightstrut", "setstrut", "strutbox", "strutht", "strutdp", "strutwd", "struthtdp", "strutgap", "begstrut", "endstrut", "lineheight", "leftboundary", "rightboundary", "signalcharacter", "aligncontentleft", "aligncontentmiddle", "aligncontentright", "shiftbox", "vpackbox", "hpackbox", "vpackedbox", "hpackedbox", "ordordspacing", "ordopspacing", "ordbinspacing", "ordrelspacing", "ordopenspacing", "ordclosespacing", "ordpunctspacing", "ordinnerspacing", "ordfracspacing", "ordradspacing", "ordmiddlespacing", "ordaccentspacing", "opordspacing", "opopspacing", "opbinspacing", "oprelspacing", "opopenspacing", "opclosespacing", "oppunctspacing", "opinnerspacing", "opfracspacing", "opradspacing", "opmiddlespacing", "opaccentspacing", "binordspacing", "binopspacing", "binbinspacing", "binrelspacing", "binopenspacing", "binclosespacing", "binpunctspacing", "bininnerspacing", "binfracspacing", "binradspacing", "binmiddlespacing", "binaccentspacing", "relordspacing", "relopspacing", "relbinspacing", "relrelspacing", "relopenspacing", "relclosespacing", "relpunctspacing", "relinnerspacing", "relfracspacing", "relradspacing", "relmiddlespacing", "relaccentspacing", "openordspacing", "openopspacing", "openbinspacing", "openrelspacing", "openopenspacing", "openclosespacing", "openpunctspacing", "openinnerspacing", "openfracspacing", "openradspacing", "openmiddlespacing", "openaccentspacing", "closeordspacing", "closeopspacing", "closebinspacing", "closerelspacing", "closeopenspacing", "closeclosespacing", "closepunctspacing", "closeinnerspacing", "closefracspacing", "closeradspacing", "closemiddlespacing", "closeaccentspacing", "punctordspacing", "punctopspacing", "punctbinspacing", "punctrelspacing", "punctopenspacing", "punctclosespacing", "punctpunctspacing", "punctinnerspacing", "punctfracspacing", "punctradspacing", "punctmiddlespacing", "punctaccentspacing", "innerordspacing", "inneropspacing", "innerbinspacing", "innerrelspacing", "inneropenspacing", "innerclosespacing", "innerpunctspacing", "innerinnerspacing", "innerfracspacing", "innerradspacing", "innermiddlespacing", "inneraccentspacing", "fracordspacing", "fracopspacing", "fracbinspacing", "fracrelspacing", "fracopenspacing", "fracclosespacing", "fracpunctspacing", "fracinnerspacing", "fracfracspacing", "fracradspacing", "fracmiddlespacing", "fracaccentspacing", "radordspacing", "radopspacing", "radbinspacing", "radrelspacing", "radopenspacing", "radclosespacing", "radpunctspacing", "radinnerspacing", "radfracspacing", "radradspacing", "radmiddlespacing", "radaccentspacing", "middleordspacing", "middleopspacing", "middlebinspacing", "middlerelspacing", "middleopenspacing", "middleclosespacing", "middlepunctspacing", "middleinnerspacing", "middlefracspacing", "middleradspacing", "middlemiddlespacing", "middleaccentspacing", "accentordspacing", "accentopspacing", "accentbinspacing", "accentrelspacing", "accentopenspacing", "accentclosespacing", "accentpunctspacing", "accentinnerspacing", "accentfracspacing", "accentradspacing", "accentmiddlespacing", "accentaccentspacing", "normalreqno", "startimath", "stopimath", "normalstartimath", "normalstopimath", "startdmath", "stopdmath", "normalstartdmath", "normalstopdmath", "normalsuperscript", "normalsubscript", "normalnosuperscript", "normalnosubscript", "normalprimescript", "superscript", "subscript", "nosuperscript", "nosubscript", "primescript", "superprescript", "subprescript", "nosuperprescript", "nosubsprecript", "uncramped", "cramped", "mathstyletrigger", "triggermathstyle", "triggeredmathstyle", "mathstylefont", "mathsmallstylefont", "mathstyleface", "mathsmallstyleface", "mathstylecommand", "mathpalette", "mathstylehbox", "mathstylevbox", "mathstylevcenter", "mathstylevcenteredhbox", "mathstylevcenteredvbox", "mathtext", "setmathsmalltextbox", "setmathtextbox", "pushmathstyle", "popmathstyle", "triggerdisplaystyle", "triggertextstyle", "triggerscriptstyle", "triggerscriptscriptstyle", "triggeruncrampedstyle", "triggercrampedstyle", "triggersmallstyle", "triggeruncrampedsmallstyle", "triggercrampedsmallstyle", "triggerbigstyle", "triggeruncrampedbigstyle", "triggercrampedbigstyle", "luaexpr", "expelsedoif", "expdoif", "expdoifnot", "expdoifelsecommon", "expdoifcommonelse", "expdoifelseinset", "expdoifinsetelse", "ctxdirectlua", "ctxlatelua", "ctxsprint", "ctxwrite", "ctxcommand", "ctxdirectcommand", "ctxlatecommand", "ctxreport", "ctxlua", "luacode", "lateluacode", "directluacode", "registerctxluafile", "ctxloadluafile", "luaversion", "luamajorversion", "luaminorversion", "ctxluacode", "luaconditional", "luaexpanded", "ctxluamatch", "startluaparameterset", "stopluaparameterset", "luaparameterset", "definenamedlua", "obeylualines", "obeyluatokens", "startluacode", "stopluacode", "startlua", "stoplua", "startctxfunction", "stopctxfunction", "ctxfunction", "startctxfunctiondefinition", "stopctxfunctiondefinition", "installctxfunction", "installprotectedctxfunction", "installprotectedctxscanner", "installctxscanner", "resetctxscanner", "cldprocessfile", "cldloadfile", "cldloadviafile", "cldcontext", "cldcommand", "carryoverpar", "freezeparagraphproperties", "defrostparagraphproperties", "setparagraphfreezing", "forgetparagraphfreezing", "updateparagraphproperties", "updateparagraphpenalties", "updateparagraphdemerits", "updateparagraphshapes", "updateparagraphlines", "lastlinewidth", "assumelongusagecs", "Umathbottomaccent", "Umathtopaccent", "Umathbotaccent", "righttolefthbox", "lefttorighthbox", "righttoleftvbox", "lefttorightvbox", "righttoleftvtop", "lefttorightvtop", "rtlhbox", "ltrhbox", "rtlvbox", "ltrvbox", "rtlvtop", "ltrvtop", "autodirhbox", "autodirvbox", "autodirvtop", "leftorrighthbox", "leftorrightvbox", "leftorrightvtop", "lefttoright", "righttoleft", "checkedlefttoright", "checkedrighttoleft", "synchronizelayoutdirection", "synchronizedisplaydirection", "synchronizeinlinedirection", "dirlre", "dirrle", "dirlro", "dirrlo", "rtltext", "ltrtext", "lesshyphens", "morehyphens", "nohyphens", "dohyphens", "dohyphencollapsing", "nohyphencollapsing", "compounddiscretionary", "Ucheckedstartdisplaymath", "Ucheckedstopdisplaymath", "break", "nobreak", "allowbreak", "goodbreak", "nospace", "nospacing", "dospacing", "naturalhbox", "naturalvbox", "naturalvtop", "naturalhpack", "naturalvpack", "naturaltpack", "reversehbox", "reversevbox", "reversevtop", "reversehpack", "reversevpack", "reversetpack", "hcontainer", "vcontainer", "tcontainer", "frule", "compoundhyphenpenalty", "start", "stop", "unsupportedcs", "openout", "closeout", "write", "openin", "closein", "read", "readline", "readfromterminal", "boxlines", "boxline", "setboxline", "copyboxline", "boxlinewd", "boxlineht", "boxlinedp", "boxlinenw", "boxlinenh", "boxlinend", "boxlinels", "boxliners", "boxlinelh", "boxlinerh", "boxlinelp", "boxlinerp", "boxlinein", "boxrangewd", "boxrangeht", "boxrangedp", "bitwiseset", "bitwiseand", "bitwiseor", "bitwisexor", "bitwisenot", "bitwisenil", "ifbitwiseand", "bitwise", "bitwiseshift", "bitwiseflip", "textdir", "linedir", "pardir", "boxdir", "prelistbox", "postlistbox", "prelistcopy", "postlistcopy", "setprelistbox", "setpostlistbox", "noligaturing", "nokerning", "noexpansion", "noprotrusion", "noleftkerning", "noleftligaturing", "norightkerning", "norightligaturing", "noitaliccorrection", "futureletnexttoken", "defbackslashbreak", "letbackslashbreak", "pushoverloadmode", "popoverloadmode", "pushrunstate", "poprunstate", "suggestedalias", "showboxhere", "discoptioncodestring", "flagcodestring", "frozenparcodestring", "glyphoptioncodestring", "groupcodestring", "hyphenationcodestring", "mathcontrolcodestring", "mathflattencodestring", "normalizecodestring", "parcontextcodestring", "newlocalcount", "newlocaldimen", "newlocalskip", "newlocalmuskip", "newlocaltoks", "newlocalbox", "newlocalwrite", "newlocalread", "setnewlocalcount", "setnewlocaldimen", "setnewlocalskip", "setnewlocalmuskip", "setnewlocaltoks", "setnewlocalbox", "ifexpression" },
+ ["constants"]={ "zerocount", "minusone", "minustwo", "plusone", "plustwo", "plusthree", "plusfour", "plusfive", "plussix", "plusseven", "pluseight", "plusnine", "plusten", "pluseleven", "plustwelve", "plussixteen", "plusfifty", "plushundred", "plusonehundred", "plustwohundred", "plusfivehundred", "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "maxcardminusone", "maxiterator", "zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxcount", "maxdimen", "scaledpoint", "thousandpoint", "points", "halfpoint", "zeroskip", "centeringskip", "stretchingskip", "shrinkingskip", "centeringfillskip", "stretchingfillskip", "shrinkingfillskip", "zeromuskip", "onemuskip", "pluscxxvii", "pluscxxviii", "pluscclv", "pluscclvi", "normalpagebox", "binaryshiftedten", "binaryshiftedtwenty", "binaryshiftedthirty", "thickermuskip", "directionlefttoright", "directionrighttoleft", "endoflinetoken", "outputnewlinechar", "emptytoks", "empty", "undefined", "prerollrun", "voidbox", "emptybox", "emptyvbox", "emptyhbox", "bigskipamount", "medskipamount", "smallskipamount", "fmtname", "fmtversion", "texengine", "texenginename", "texengineversion", "texenginefunctionality", "luatexengine", "pdftexengine", "xetexengine", "unknownengine", "contextformat", "contextversion", "contextlmtxmode", "contextmark", "mksuffix", "activecatcode", "bgroup", "egroup", "endline", "conditionaltrue", "conditionalfalse", "attributeunsetvalue", "statuswrite", "uprotationangle", "rightrotationangle", "downrotationangle", "leftrotationangle", "inicatcodes", "ctxcatcodes", "texcatcodes", "notcatcodes", "txtcatcodes", "vrbcatcodes", "prtcatcodes", "nilcatcodes", "luacatcodes", "tpacatcodes", "tpbcatcodes", "xmlcatcodes", "ctdcatcodes", "rlncatcodes", "escapecatcode", "begingroupcatcode", "endgroupcatcode", "mathshiftcatcode", "alignmentcatcode", "endoflinecatcode", "parametercatcode", "superscriptcatcode", "subscriptcatcode", "ignorecatcode", "spacecatcode", "lettercatcode", "othercatcode", "activecatcode", "commentcatcode", "invalidcatcode", "tabasciicode", "newlineasciicode", "formfeedasciicode", "endoflineasciicode", "endoffileasciicode", "commaasciicode", "spaceasciicode", "periodasciicode", "hashasciicode", "dollarasciicode", "commentasciicode", "ampersandasciicode", "colonasciicode", "backslashasciicode", "circumflexasciicode", "underscoreasciicode", "leftbraceasciicode", "barasciicode", "rightbraceasciicode", "tildeasciicode", "delasciicode", "leftparentasciicode", "rightparentasciicode", "lessthanasciicode", "morethanasciicode", "doublecommentsignal", "atsignasciicode", "exclamationmarkasciicode", "questionmarkasciicode", "doublequoteasciicode", "singlequoteasciicode", "forwardslashasciicode", "primeasciicode", "hyphenasciicode", "percentasciicode", "leftbracketasciicode", "rightbracketasciicode", "hsizefrozenparcode", "skipfrozenparcode", "hangfrozenparcode", "indentfrozenparcode", "parfillfrozenparcode", "adjustfrozenparcode", "protrudefrozenparcode", "tolerancefrozenparcode", "stretchfrozenparcode", "loosenessfrozenparcode", "lastlinefrozenparcode", "linepenaltyfrozenparcode", "clubpenaltyfrozenparcode", "widowpenaltyfrozenparcode", "displaypenaltyfrozenparcode", "brokenpenaltyfrozenparcode", "demeritsfrozenparcode", "shapefrozenparcode", "linefrozenparcode", "hyphenationfrozenparcode", "shapingpenaltyfrozenparcode", "orphanpenaltyfrozenparcode", "allfrozenparcode", "mathpenaltyfrozenparcode", "activemathcharcode", "activetabtoken", "activeformfeedtoken", "activeendoflinetoken", "batchmodecode", "nonstopmodecode", "scrollmodecode", "errorstopmodecode", "bottomlevelgroupcode", "simplegroupcode", "hboxgroupcode", "adjustedhboxgroupcode", "vboxgroupcode", "vtopgroupcode", "aligngroupcode", "noaligngroupcode", "outputgroupcode", "mathgroupcode", "discretionarygroupcode", "insertgroupcode", "vadjustgroupcode", "vcentergroupcode", "mathabovegroupcode", "mathchoicegroupcode", "alsosimplegroupcode", "semisimplegroupcode", "mathshiftgroupcode", "mathleftgroupcode", "localboxgroupcode", "splitoffgroupcode", "splitkeepgroupcode", "preamblegroupcode", "alignsetgroupcode", "finrowgroupcode", "discretionarygroupcode", "markautomigrationcode", "insertautomigrationcode", "adjustautomigrationcode", "preautomigrationcode", "postautomigrationcode", "charnodecode", "hlistnodecode", "vlistnodecode", "rulenodecode", "insertnodecode", "marknodecode", "adjustnodecode", "ligaturenodecode", "discretionarynodecode", "whatsitnodecode", "mathnodecode", "gluenodecode", "kernnodecode", "penaltynodecode", "unsetnodecode", "mathsnodecode", "overrulemathcontrolcode", "underrulemathcontrolcode", "radicalrulemathcontrolcode", "fractionrulemathcontrolcode", "accentskewhalfmathcontrolcode", "accentskewapplymathcontrolcode", "applyordinarykernpairmathcontrolcode", "applyverticalitalickernmathcontrolcode", "applyordinaryitalickernmathcontrolcode", "applycharitalickernmathcontrolcode", "reboxcharitalickernmathcontrolcode", "applyboxeditalickernmathcontrolcode", "staircasekernmathcontrolcode", "applytextitalickernmathcontrolcode", "applyscriptitalickernmathcontrolcode", "checkspaceitalickernmathcontrolcode", "checktextitalickernmathcontrolcode", "analyzescriptnucleuscharmathcontrolcode", "analyzescriptnucleuslistmathcontrolcode", "analyzescriptnucleusboxmathcontrolcode", "accenttopskewwithoffsetmathcontrolcode", "ignorekerndimensionsmathcontrolcode", "ignoreflataccentsmathcontrolcode", "extendaccentsmathcontrolcode", "noligaturingglyphoptioncode", "nokerningglyphoptioncode", "noexpansionglyphoptioncode", "noprotrusionglyphoptioncode", "noleftkerningglyphoptioncode", "noleftligaturingglyphoptioncode", "norightkerningglyphoptioncode", "norightligaturingglyphoptioncode", "noitaliccorrectionglyphoptioncode", "islargeoperatorglyphoptioncode", "hasitalicshapeglyphoptioncode", "normalparcontextcode", "vmodeparcontextcode", "vboxparcontextcode", "vtopparcontextcode", "vcenterparcontextcode", "vadjustparcontextcode", "insertparcontextcode", "outputparcontextcode", "alignparcontextcode", "noalignparcontextcode", "spanparcontextcode", "resetparcontextcode", "leftoriginlistanchorcode", "leftheightlistanchorcode", "leftdepthlistanchorcode", "rightoriginlistanchorcode", "rightheightlistanchorcode", "rightdepthlistanchorcode", "centeroriginlistanchorcode", "centerheightlistanchorcode", "centerdepthlistanchorcode", "halfwaytotallistanchorcode", "halfwayheightlistanchorcode", "halfwaydepthlistanchorcode", "halfwayleftlistanchorcode", "halfwayrightlistanchorcode", "negatexlistsigncode", "negateylistsigncode", "negatelistsigncode", "fontslantperpoint", "fontinterwordspace", "fontinterwordstretch", "fontinterwordshrink", "fontexheight", "fontemwidth", "fontextraspace", "slantperpoint", "mathexheight", "mathemwidth", "interwordspace", "interwordstretch", "interwordshrink", "exheight", "emwidth", "extraspace", "mathaxisheight", "muquad", "startmode", "stopmode", "startnotmode", "stopnotmode", "startmodeset", "stopmodeset", "doifmode", "doifelsemode", "doifmodeelse", "doifnotmode", "startmodeset", "stopmodeset", "startallmodes", "stopallmodes", "startnotallmodes", "stopnotallmodes", "doifallmodes", "doifelseallmodes", "doifallmodeselse", "doifnotallmodes", "startenvironment", "stopenvironment", "environment", "startcomponent", "stopcomponent", "component", "startproduct", "stopproduct", "product", "startproject", "stopproject", "project", "starttext", "stoptext", "startnotext", "stopnotext", "startdocument", "stopdocument", "documentvariable", "unexpandeddocumentvariable", "setupdocument", "presetdocument", "doifelsedocumentvariable", "doifdocumentvariableelse", "doifdocumentvariable", "doifnotdocumentvariable", "startmodule", "stopmodule", "usemodule", "usetexmodule", "useluamodule", "setupmodule", "currentmoduleparameter", "moduleparameter", "everystarttext", "everystoptext", "startTEXpage", "stopTEXpage", "enablemode", "disablemode", "preventmode", "definemode", "globalenablemode", "globaldisablemode", "globalpreventmode", "pushmode", "popmode", "typescriptone", "typescripttwo", "typescriptthree", "mathsizesuffix", "mathordinarycode", "mathordcode", "mathoperatorcode", "mathopcode", "mathbinarycode", "mathbincode", "mathrelationcode", "mathrelcode", "mathopencode", "mathclosecode", "mathpunctuationcode", "mathpunctcode", "mathovercode", "mathundercode", "mathinnercode", "mathradicalcode", "mathfractioncode", "mathmiddlecode", "mathaccentcode", "mathfencedcode", "mathghostcode", "mathvariablecode", "mathactivecode", "mathvcentercode", "mathconstructcode", "mathwrappedcode", "mathbegincode", "mathendcode", "mathexplicitcode", "mathdivisioncode", "mathfactorialcode", "mathdimensioncode", "mathexperimentalcode", "mathtextpunctuationcode", "mathimaginarycode", "mathdifferentialcode", "mathexponentialcode", "mathellipsiscode", "mathfunctioncode", "mathdigitcode", "mathalphacode", "mathboxcode", "mathchoicecode", "mathnothingcode", "mathlimopcode", "mathnolopcode", "mathunsetcode", "mathunspacedcode", "mathallcode", "mathfakecode", "mathunarycode", "mathmaybeordinarycode", "mathmayberelationcode", "mathmaybebinarycode", "mathnumbergroupcode", "constantnumber", "constantnumberargument", "constantdimen", "constantdimenargument", "constantemptyargument", "luastringsep", "!!bs", "!!es", "lefttorightmark", "righttoleftmark", "lrm", "rlm", "bidilre", "bidirle", "bidipop", "bidilro", "bidirlo", "breakablethinspace", "nobreakspace", "nonbreakablespace", "narrownobreakspace", "zerowidthnobreakspace", "ideographicspace", "ideographichalffillspace", "twoperemspace", "threeperemspace", "fourperemspace", "fiveperemspace", "sixperemspace", "figurespace", "punctuationspace", "hairspace", "enquad", "emquad", "zerowidthspace", "zerowidthnonjoiner", "zerowidthjoiner", "zwnj", "zwj", "optionalspace", "asciispacechar", "softhyphen", "autoinsertedspace", "Ux", "eUx", "Umathaccents", "parfillleftskip", "parfillrightskip", "startlmtxmode", "stoplmtxmode", "startmkivmode", "stopmkivmode", "wildcardsymbol", "normalhyphenationcode", "automatichyphenationcode", "explicithyphenationcode", "syllablehyphenationcode", "uppercasehyphenationcode", "collapsehyphenationcode", "compoundhyphenationcode", "strictstarthyphenationcode", "strictendhyphenationcode", "automaticpenaltyhyphenationcode", "explicitpenaltyhyphenationcode", "permitgluehyphenationcode", "permitallhyphenationcode", "permitmathreplacehyphenationcode", "forcecheckhyphenationcode", "lazyligatureshyphenationcode", "forcehandlerhyphenationcode", "feedbackcompoundhyphenationcode", "ignoreboundshyphenationcode", "partialhyphenationcode", "completehyphenationcode", "normalizelinenormalizecode", "parindentskipnormalizecode", "swaphangindentnormalizecode", "swapparsshapenormalizecode", "breakafterdirnormalizecode", "removemarginkernsnormalizecode", "clipwidthnormalizecode", "flattendiscretionariesnormalizecode", "discardzerotabskipsnormalizecode", "flattenhleadersnormalizecode", "normalizeparnormalizeparcode", "flattenvleadersnormalizeparcode", "nopreslackclassoptioncode", "nopostslackclassoptioncode", "lefttopkernclassoptioncode", "righttopkernclassoptioncode", "leftbottomkernclassoptioncode", "rightbottomkernclassoptioncode", "lookaheadforendclassoptioncode", "noitaliccorrectionclassoptioncode", "defaultmathclassoptions", "checkligatureclassoptioncode", "checkitaliccorrectionclassoptioncode", "checkkernpairclassoptioncode", "flattenclassoptioncode", "omitpenaltyclassoptioncode", "unpackclassoptioncode", "raiseprimeclassoptioncode", "carryoverlefttopkernclassoptioncode", "carryoverleftbottomkernclassoptioncode", "carryoverrighttopkernclassoptioncode", "carryoverrightbottomkernclassoptioncode", "preferdelimiterdimensionsclassoptioncode", "autoinjectclassoptioncode", "removeitaliccorrectionclassoptioncode", "operatoritaliccorrectionclassoptioncode", "noligaturingglyphoptioncode", "nokerningglyphoptioncode", "noleftligatureglyphoptioncode", "noleftkernglyphoptioncode", "norightligatureglyphoptioncode", "norightkernglyphoptioncode", "noexpansionglyphoptioncode", "noprotrusionglyphoptioncode", "noitaliccorrectionglyphoptioncode", "nokerningcode", "noligaturingcode", "frozenflagcode", "tolerantflagcode", "protectedflagcode", "primitiveflagcode", "permanentflagcode", "noalignedflagcode", "immutableflagcode", "mutableflagcode", "globalflagcode", "overloadedflagcode", "immediateflagcode", "conditionalflagcode", "valueflagcode", "instanceflagcode", "ordmathflattencode", "binmathflattencode", "relmathflattencode", "punctmathflattencode", "innermathflattencode", "normalworddiscoptioncode", "preworddiscoptioncode", "postworddiscoptioncode", "continueifinputfile", "continuewhenlmtxmode", "continuewhenmkivmode" },
+ ["helpers"]={ "startsetups", "stopsetups", "startxmlsetups", "stopxmlsetups", "startluasetups", "stopluasetups", "starttexsetups", "stoptexsetups", "startrawsetups", "stoprawsetups", "startlocalsetups", "stoplocalsetups", "starttexdefinition", "stoptexdefinition", "starttexcode", "stoptexcode", "startcontextcode", "stopcontextcode", "startcontextdefinitioncode", "stopcontextdefinitioncode", "texdefinition", "doifelsesetups", "doifsetupselse", "doifsetups", "doifnotsetups", "setup", "setups", "texsetup", "xmlsetup", "luasetup", "directsetup", "fastsetup", "copysetups", "resetsetups", "doifelsecommandhandler", "doifcommandhandlerelse", "doifnotcommandhandler", "doifcommandhandler", "newmode", "setmode", "resetmode", "newsystemmode", "setsystemmode", "resetsystemmode", "pushsystemmode", "popsystemmode", "globalsetmode", "globalresetmode", "globalsetsystemmode", "globalresetsystemmode", "booleanmodevalue", "newcount", "newdimen", "newskip", "newmuskip", "newbox", "newtoks", "newread", "newwrite", "newmarks", "newinsert", "newattribute", "newif", "newlanguage", "newfamily", "newfam", "newhelp", "newinteger", "newdimension", "newgluespec", "newmugluespec", "aliasinteger", "aliasdimension", "then", "begcsname", "autorule", "strippedcsname", "checkedstrippedcsname", "nofarguments", "firstargumentfalse", "firstargumenttrue", "secondargumentfalse", "secondargumenttrue", "thirdargumentfalse", "thirdargumenttrue", "fourthargumentfalse", "fourthargumenttrue", "fifthargumentfalse", "fifthargumenttrue", "sixthargumentfalse", "sixthargumenttrue", "seventhargumentfalse", "seventhargumenttrue", "vkern", "hkern", "vpenalty", "hpenalty", "doglobal", "dodoglobal", "redoglobal", "resetglobal", "donothing", "untraceddonothing", "dontcomplain", "moreboxtracing", "lessboxtracing", "noboxtracing", "forgetall", "donetrue", "donefalse", "foundtrue", "foundfalse", "inlineordisplaymath", "indisplaymath", "forcedisplaymath", "startforceddisplaymath", "stopforceddisplaymath", "startpickupmath", "stoppickupmath", "reqno", "forceinlinemath", "mathortext", "thebox", "htdp", "unvoidbox", "hfilll", "vfilll", "mathbox", "mathlimop", "mathnolop", "mathnothing", "mathalpha", "currentcatcodetable", "defaultcatcodetable", "catcodetablename", "newcatcodetable", "startcatcodetable", "stopcatcodetable", "startextendcatcodetable", "stopextendcatcodetable", "pushcatcodetable", "popcatcodetable", "restorecatcodes", "setcatcodetable", "letcatcodecommand", "defcatcodecommand", "uedcatcodecommand", "hglue", "vglue", "hfillneg", "vfillneg", "hfilllneg", "vfilllneg", "ruledhss", "ruledhfil", "ruledhfill", "ruledhfilll", "ruledhfilneg", "ruledhfillneg", "normalhfillneg", "normalhfilllneg", "ruledvss", "ruledvfil", "ruledvfill", "ruledvfilll", "ruledvfilneg", "ruledvfillneg", "normalvfillneg", "normalvfilllneg", "ruledhbox", "ruledvbox", "ruledvtop", "ruleddbox", "ruledvcenter", "ruledmbox", "ruledhpack", "ruledvpack", "ruledtpack", "ruleddpack", "ruledhskip", "ruledvskip", "ruledkern", "ruledmskip", "ruledmkern", "ruledhglue", "ruledvglue", "normalhglue", "normalvglue", "ruledpenalty", "filledhboxb", "filledhboxr", "filledhboxg", "filledhboxc", "filledhboxm", "filledhboxy", "filledhboxk", "scratchstring", "scratchstringone", "scratchstringtwo", "tempstring", "scratchcounter", "globalscratchcounter", "privatescratchcounter", "scratchdimen", "globalscratchdimen", "privatescratchdimen", "scratchskip", "globalscratchskip", "privatescratchskip", "scratchmuskip", "globalscratchmuskip", "privatescratchmuskip", "scratchtoks", "globalscratchtoks", "privatescratchtoks", "scratchbox", "globalscratchbox", "privatescratchbox", "scratchmacro", "scratchmacroone", "scratchmacrotwo", "scratchconditiontrue", "scratchconditionfalse", "ifscratchcondition", "scratchconditiononetrue", "scratchconditiononefalse", "ifscratchconditionone", "scratchconditiontwotrue", "scratchconditiontwofalse", "ifscratchconditiontwo", "globalscratchcounterone", "globalscratchcountertwo", "globalscratchcounterthree", "groupedcommand", "groupedcommandcs", "triggergroupedcommand", "triggergroupedcommandcs", "simplegroupedcommand", "simplegroupedcommandcs", "pickupgroupedcommand", "pickupgroupedcommandcs", "mathgroupedcommandcs", "usedbaselineskip", "usedlineskip", "usedlineskiplimit", "availablehsize", "localhsize", "setlocalhsize", "distributedhsize", "hsizefraction", "next", "nexttoken", "nextbox", "dowithnextbox", "dowithnextboxcs", "dowithnextboxcontent", "dowithnextboxcontentcs", "flushnextbox", "boxisempty", "boxtostring", "contentostring", "prerolltostring", "givenwidth", "givenheight", "givendepth", "scangivendimensions", "scratchwidth", "scratchheight", "scratchdepth", "scratchoffset", "scratchdistance", "scratchtotal", "scratchitalic", "scratchhsize", "scratchvsize", "scratchxoffset", "scratchyoffset", "scratchhoffset", "scratchvoffset", "scratchxposition", "scratchyposition", "scratchtopoffset", "scratchbottomoffset", "scratchleftoffset", "scratchrightoffset", "scratchcounterone", "scratchcountertwo", "scratchcounterthree", "scratchcounterfour", "scratchcounterfive", "scratchcountersix", "scratchdimenone", "scratchdimentwo", "scratchdimenthree", "scratchdimenfour", "scratchdimenfive", "scratchdimensix", "scratchskipone", "scratchskiptwo", "scratchskipthree", "scratchskipfour", "scratchskipfive", "scratchskipsix", "scratchmuskipone", "scratchmuskiptwo", "scratchmuskipthree", "scratchmuskipfour", "scratchmuskipfive", "scratchmuskipsix", "scratchtoksone", "scratchtokstwo", "scratchtoksthree", "scratchtoksfour", "scratchtoksfive", "scratchtokssix", "scratchboxone", "scratchboxtwo", "scratchboxthree", "scratchboxfour", "scratchboxfive", "scratchboxsix", "scratchnx", "scratchny", "scratchmx", "scratchmy", "scratchunicode", "scratchmin", "scratchmax", "scratchleftskip", "scratchrightskip", "scratchtopskip", "scratchbottomskip", "doif", "doifnot", "doifelse", "firstinset", "doifinset", "doifnotinset", "doifelseinset", "doifinsetelse", "doifelsenextchar", "doifnextcharelse", "doifelsenextcharcs", "doifnextcharcselse", "doifelsenextoptional", "doifnextoptionalelse", "doifelsenextoptionalcs", "doifnextoptionalcselse", "doifelsefastoptionalcheck", "doiffastoptionalcheckelse", "doifelsefastoptionalcheckcs", "doiffastoptionalcheckcselse", "doifelsenextbgroup", "doifnextbgroupelse", "doifelsenextbgroupcs", "doifnextbgroupcselse", "doifelsenextparenthesis", "doifnextparenthesiselse", "doifelseundefined", "doifundefinedelse", "doifelsedefined", "doifdefinedelse", "doifundefined", "doifdefined", "doifelsevalue", "doifvalue", "doifnotvalue", "doifnothing", "doifsomething", "doifelsenothing", "doifnothingelse", "doifelsesomething", "doifsomethingelse", "doifvaluenothing", "doifvaluesomething", "doifelsevaluenothing", "doifvaluenothingelse", "doifelsedimension", "doifdimensionelse", "doifelsenumber", "doifnumberelse", "doifnumber", "doifnotnumber", "doifelsecommon", "doifcommonelse", "doifcommon", "doifnotcommon", "doifinstring", "doifnotinstring", "doifelseinstring", "doifinstringelse", "doifelseassignment", "doifassignmentelse", "docheckassignment", "doifelseassignmentcs", "doifassignmentelsecs", "validassignment", "novalidassignment", "doiftext", "doifelsetext", "doiftextelse", "doifnottext", "quitcondition", "truecondition", "falsecondition", "tracingall", "tracingnone", "loggingall", "tracingcatcodes", "showluatokens", "aliasmacro", "removetoks", "appendtoks", "prependtoks", "appendtotoks", "prependtotoks", "to", "endgraf", "endpar", "reseteverypar", "finishpar", "empty", "null", "space", "quad", "enspace", "emspace", "charspace", "nbsp", "crlf", "obeyspaces", "obeylines", "obeytabs", "obeypages", "obeyedspace", "obeyedline", "obeyedtab", "obeyedpage", "normalspace", "naturalspace", "controlspace", "normalspaces", "ignoretabs", "ignorelines", "ignorepages", "ignoreeofs", "setcontrolspaces", "executeifdefined", "singleexpandafter", "doubleexpandafter", "tripleexpandafter", "dontleavehmode", "removelastspace", "removeunwantedspaces", "keepunwantedspaces", "removepunctuation", "ignoreparskip", "forcestrutdepth", "onlynonbreakablespace", "wait", "writestatus", "define", "defineexpandable", "redefine", "setmeasure", "setemeasure", "setgmeasure", "setxmeasure", "definemeasure", "freezemeasure", "measure", "measured", "directmeasure", "setquantity", "setequantity", "setgquantity", "setxquantity", "definequantity", "freezequantity", "quantity", "quantitied", "directquantity", "installcorenamespace", "getvalue", "getuvalue", "setvalue", "setevalue", "setgvalue", "setxvalue", "letvalue", "letgvalue", "resetvalue", "undefinevalue", "ignorevalue", "setuvalue", "setuevalue", "setugvalue", "setuxvalue", "globallet", "udef", "ugdef", "uedef", "uxdef", "checked", "unique", "getparameters", "geteparameters", "getgparameters", "getxparameters", "forgetparameters", "copyparameters", "getdummyparameters", "dummyparameter", "directdummyparameter", "setdummyparameter", "letdummyparameter", "setexpandeddummyparameter", "resetdummyparameter", "usedummystyleandcolor", "usedummystyleparameter", "usedummycolorparameter", "processcommalist", "processcommacommand", "quitcommalist", "quitprevcommalist", "processaction", "processallactions", "processfirstactioninset", "processallactionsinset", "unexpanded", "expanded", "startexpanded", "stopexpanded", "protect", "unprotect", "firstofoneargument", "firstoftwoarguments", "secondoftwoarguments", "firstofthreearguments", "secondofthreearguments", "thirdofthreearguments", "firstoffourarguments", "secondoffourarguments", "thirdoffourarguments", "fourthoffourarguments", "firstoffivearguments", "secondoffivearguments", "thirdoffivearguments", "fourthoffivearguments", "fifthoffivearguments", "firstofsixarguments", "secondofsixarguments", "thirdofsixarguments", "fourthofsixarguments", "fifthofsixarguments", "sixthofsixarguments", "firstofoneunexpanded", "firstoftwounexpanded", "secondoftwounexpanded", "firstofthreeunexpanded", "secondofthreeunexpanded", "thirdofthreeunexpanded", "gobbleoneargument", "gobbletwoarguments", "gobblethreearguments", "gobblefourarguments", "gobblefivearguments", "gobblesixarguments", "gobblesevenarguments", "gobbleeightarguments", "gobbleninearguments", "gobbletenarguments", "gobbleoneoptional", "gobbletwooptionals", "gobblethreeoptionals", "gobblefouroptionals", "gobblefiveoptionals", "dorecurse", "doloop", "exitloop", "dostepwiserecurse", "recurselevel", "recursedepth", "dofastloopcs", "fastloopindex", "fastloopfinal", "dowith", "doloopovermatch", "doloopovermatched", "doloopoverlist", "newconstant", "setnewconstant", "setconstant", "setconstantvalue", "newconditional", "settrue", "setfalse", "settruevalue", "setfalsevalue", "setconditional", "newmacro", "setnewmacro", "newfraction", "newsignal", "newboundary", "dosingleempty", "dodoubleempty", "dotripleempty", "doquadrupleempty", "doquintupleempty", "dosixtupleempty", "doseventupleempty", "dosingleargument", "dodoubleargument", "dotripleargument", "doquadrupleargument", "doquintupleargument", "dosixtupleargument", "doseventupleargument", "dosinglegroupempty", "dodoublegroupempty", "dotriplegroupempty", "doquadruplegroupempty", "doquintuplegroupempty", "permitspacesbetweengroups", "dontpermitspacesbetweengroups", "nopdfcompression", "maximumpdfcompression", "normalpdfcompression", "onlypdfobjectcompression", "nopdfobjectcompression", "modulonumber", "dividenumber", "getfirstcharacter", "doifelsefirstchar", "doiffirstcharelse", "mathclassvalue", "startnointerference", "stopnointerference", "twodigits", "threedigits", "leftorright", "offinterlineskip", "oninterlineskip", "nointerlineskip", "strut", "halfstrut", "quarterstrut", "depthstrut", "halflinestrut", "noheightstrut", "setstrut", "strutbox", "strutht", "strutdp", "strutwd", "struthtdp", "strutgap", "begstrut", "endstrut", "lineheight", "leftboundary", "rightboundary", "signalcharacter", "aligncontentleft", "aligncontentmiddle", "aligncontentright", "shiftbox", "vpackbox", "hpackbox", "vpackedbox", "hpackedbox", "ordordspacing", "ordopspacing", "ordbinspacing", "ordrelspacing", "ordopenspacing", "ordclosespacing", "ordpunctspacing", "ordinnerspacing", "ordfracspacing", "ordradspacing", "ordmiddlespacing", "ordaccentspacing", "opordspacing", "opopspacing", "opbinspacing", "oprelspacing", "opopenspacing", "opclosespacing", "oppunctspacing", "opinnerspacing", "opfracspacing", "opradspacing", "opmiddlespacing", "opaccentspacing", "binordspacing", "binopspacing", "binbinspacing", "binrelspacing", "binopenspacing", "binclosespacing", "binpunctspacing", "bininnerspacing", "binfracspacing", "binradspacing", "binmiddlespacing", "binaccentspacing", "relordspacing", "relopspacing", "relbinspacing", "relrelspacing", "relopenspacing", "relclosespacing", "relpunctspacing", "relinnerspacing", "relfracspacing", "relradspacing", "relmiddlespacing", "relaccentspacing", "openordspacing", "openopspacing", "openbinspacing", "openrelspacing", "openopenspacing", "openclosespacing", "openpunctspacing", "openinnerspacing", "openfracspacing", "openradspacing", "openmiddlespacing", "openaccentspacing", "closeordspacing", "closeopspacing", "closebinspacing", "closerelspacing", "closeopenspacing", "closeclosespacing", "closepunctspacing", "closeinnerspacing", "closefracspacing", "closeradspacing", "closemiddlespacing", "closeaccentspacing", "punctordspacing", "punctopspacing", "punctbinspacing", "punctrelspacing", "punctopenspacing", "punctclosespacing", "punctpunctspacing", "punctinnerspacing", "punctfracspacing", "punctradspacing", "punctmiddlespacing", "punctaccentspacing", "innerordspacing", "inneropspacing", "innerbinspacing", "innerrelspacing", "inneropenspacing", "innerclosespacing", "innerpunctspacing", "innerinnerspacing", "innerfracspacing", "innerradspacing", "innermiddlespacing", "inneraccentspacing", "fracordspacing", "fracopspacing", "fracbinspacing", "fracrelspacing", "fracopenspacing", "fracclosespacing", "fracpunctspacing", "fracinnerspacing", "fracfracspacing", "fracradspacing", "fracmiddlespacing", "fracaccentspacing", "radordspacing", "radopspacing", "radbinspacing", "radrelspacing", "radopenspacing", "radclosespacing", "radpunctspacing", "radinnerspacing", "radfracspacing", "radradspacing", "radmiddlespacing", "radaccentspacing", "middleordspacing", "middleopspacing", "middlebinspacing", "middlerelspacing", "middleopenspacing", "middleclosespacing", "middlepunctspacing", "middleinnerspacing", "middlefracspacing", "middleradspacing", "middlemiddlespacing", "middleaccentspacing", "accentordspacing", "accentopspacing", "accentbinspacing", "accentrelspacing", "accentopenspacing", "accentclosespacing", "accentpunctspacing", "accentinnerspacing", "accentfracspacing", "accentradspacing", "accentmiddlespacing", "accentaccentspacing", "normalreqno", "startimath", "stopimath", "normalstartimath", "normalstopimath", "startdmath", "stopdmath", "normalstartdmath", "normalstopdmath", "normalsuperscript", "normalsubscript", "normalnosuperscript", "normalnosubscript", "normalprimescript", "superscript", "subscript", "nosuperscript", "nosubscript", "primescript", "superprescript", "subprescript", "nosuperprescript", "nosubsprecript", "uncramped", "cramped", "mathstyletrigger", "triggermathstyle", "triggeredmathstyle", "mathstylefont", "mathsmallstylefont", "mathstyleface", "mathsmallstyleface", "mathstylecommand", "mathpalette", "mathstylehbox", "mathstylevbox", "mathstylevcenter", "mathstylevcenteredhbox", "mathstylevcenteredvbox", "mathtext", "setmathsmalltextbox", "setmathtextbox", "pushmathstyle", "popmathstyle", "triggerdisplaystyle", "triggertextstyle", "triggerscriptstyle", "triggerscriptscriptstyle", "triggeruncrampedstyle", "triggercrampedstyle", "triggersmallstyle", "triggeruncrampedsmallstyle", "triggercrampedsmallstyle", "triggerbigstyle", "triggeruncrampedbigstyle", "triggercrampedbigstyle", "luaexpr", "expelsedoif", "expdoif", "expdoifnot", "expdoifelsecommon", "expdoifcommonelse", "expdoifelseinset", "expdoifinsetelse", "ctxdirectlua", "ctxlatelua", "ctxsprint", "ctxwrite", "ctxcommand", "ctxdirectcommand", "ctxlatecommand", "ctxreport", "ctxlua", "luacode", "lateluacode", "directluacode", "registerctxluafile", "ctxloadluafile", "luaversion", "luamajorversion", "luaminorversion", "ctxluacode", "luaconditional", "luaexpanded", "ctxluamatch", "startluaparameterset", "stopluaparameterset", "luaparameterset", "definenamedlua", "obeylualines", "obeyluatokens", "startluacode", "stopluacode", "startlua", "stoplua", "startctxfunction", "stopctxfunction", "ctxfunction", "startctxfunctiondefinition", "stopctxfunctiondefinition", "installctxfunction", "installprotectedctxfunction", "installprotectedctxscanner", "installctxscanner", "resetctxscanner", "cldprocessfile", "cldloadfile", "cldloadviafile", "cldcontext", "cldcommand", "carryoverpar", "freezeparagraphproperties", "defrostparagraphproperties", "setparagraphfreezing", "forgetparagraphfreezing", "updateparagraphproperties", "updateparagraphpenalties", "updateparagraphdemerits", "updateparagraphshapes", "updateparagraphlines", "lastlinewidth", "assumelongusagecs", "Umathbottomaccent", "Umathtopaccent", "Umathbotaccent", "righttolefthbox", "lefttorighthbox", "righttoleftvbox", "lefttorightvbox", "righttoleftvtop", "lefttorightvtop", "rtlhbox", "ltrhbox", "rtlvbox", "ltrvbox", "rtlvtop", "ltrvtop", "autodirhbox", "autodirvbox", "autodirvtop", "leftorrighthbox", "leftorrightvbox", "leftorrightvtop", "lefttoright", "righttoleft", "checkedlefttoright", "checkedrighttoleft", "synchronizelayoutdirection", "synchronizedisplaydirection", "synchronizeinlinedirection", "dirlre", "dirrle", "dirlro", "dirrlo", "rtltext", "ltrtext", "lesshyphens", "morehyphens", "nohyphens", "dohyphens", "dohyphencollapsing", "nohyphencollapsing", "compounddiscretionary", "Ucheckedstartdisplaymath", "Ucheckedstopdisplaymath", "break", "nobreak", "allowbreak", "goodbreak", "nospace", "nospacing", "dospacing", "naturalhbox", "naturalvbox", "naturalvtop", "naturalhpack", "naturalvpack", "naturaltpack", "reversehbox", "reversevbox", "reversevtop", "reversehpack", "reversevpack", "reversetpack", "hcontainer", "vcontainer", "tcontainer", "frule", "compoundhyphenpenalty", "start", "stop", "unsupportedcs", "openout", "closeout", "write", "openin", "closein", "read", "readline", "readfromterminal", "boxlines", "boxline", "setboxline", "copyboxline", "boxlinewd", "boxlineht", "boxlinedp", "boxlinenw", "boxlinenh", "boxlinend", "boxlinels", "boxliners", "boxlinelh", "boxlinerh", "boxlinelp", "boxlinerp", "boxlinein", "boxrangewd", "boxrangeht", "boxrangedp", "bitwiseset", "bitwiseand", "bitwiseor", "bitwisexor", "bitwisenot", "bitwisenil", "ifbitwiseand", "bitwise", "bitwiseshift", "bitwiseflip", "textdir", "linedir", "pardir", "boxdir", "prelistbox", "postlistbox", "prelistcopy", "postlistcopy", "setprelistbox", "setpostlistbox", "noligaturing", "nokerning", "noexpansion", "noprotrusion", "noleftkerning", "noleftligaturing", "norightkerning", "norightligaturing", "noitaliccorrection", "futureletnexttoken", "defbackslashbreak", "letbackslashbreak", "pushoverloadmode", "popoverloadmode", "pushrunstate", "poprunstate", "suggestedalias", "showboxhere", "discoptioncodestring", "flagcodestring", "frozenparcodestring", "glyphoptioncodestring", "groupcodestring", "hyphenationcodestring", "mathcontrolcodestring", "mathflattencodestring", "normalizecodestring", "parcontextcodestring", "newlocalcount", "newlocaldimen", "newlocalskip", "newlocalmuskip", "newlocaltoks", "newlocalbox", "newlocalwrite", "newlocalread", "setnewlocalcount", "setnewlocaldimen", "setnewlocalskip", "setnewlocalmuskip", "setnewlocaltoks", "setnewlocalbox", "ifexpression" },
} \ No newline at end of file
diff --git a/context/data/scite/context/lexers/data/scite-context-data-tex.lua b/context/data/scite/context/lexers/data/scite-context-data-tex.lua
index 5cbac80a7..f2a3a67b7 100644
--- a/context/data/scite/context/lexers/data/scite-context-data-tex.lua
+++ b/context/data/scite/context/lexers/data/scite-context-data-tex.lua
@@ -1,9 +1,9 @@
return {
["aleph"]={ "Alephminorversion", "Alephrevision", "Alephversion" },
["etex"]={ "botmarks", "clubpenalties", "currentgrouplevel", "currentgrouptype", "currentifbranch", "currentiflevel", "currentiftype", "detokenize", "dimexpr", "displaywidowpenalties", "everyeof", "firstmarks", "fontchardp", "fontcharht", "fontcharic", "fontcharwd", "glueexpr", "glueshrink", "glueshrinkorder", "gluestretch", "gluestretchorder", "gluetomu", "ifcsname", "ifdefined", "iffontchar", "interactionmode", "interlinepenalties", "lastlinefit", "lastnodetype", "marks", "muexpr", "mutoglue", "numexpr", "pagediscards", "parshapedimen", "parshapeindent", "parshapelength", "predisplaydirection", "protected", "savinghyphcodes", "savingvdiscards", "scantokens", "showgroups", "showifs", "showtokens", "splitbotmarks", "splitdiscards", "splitfirstmarks", "topmarks", "tracingassigns", "tracinggroups", "tracingifs", "tracingnesting", "unexpanded", "unless", "widowpenalties" },
- ["luatex"]={ "Uabove", "Uabovewithdelims", "Uatop", "Uatopwithdelims", "Uchar", "Udelcode", "Udelimited", "Udelimiter", "Udelimiterover", "Udelimiterunder", "Uhextensible", "Uleft", "Umathaccent", "Umathaccentbasedepth", "Umathaccentbaseheight", "Umathaccentbottomovershoot", "Umathaccentbottomshiftdown", "Umathaccentextendmargin", "Umathaccentsuperscriptdrop", "Umathaccentsuperscriptpercent", "Umathaccenttopovershoot", "Umathaccenttopshiftup", "Umathaccentvariant", "Umathadapttoleft", "Umathadapttoright", "Umathaxis", "Umathbottomaccentvariant", "Umathchar", "Umathcharclass", "Umathchardef", "Umathcharfam", "Umathcharslot", "Umathclass", "Umathcode", "Umathconnectoroverlapmin", "Umathdegreevariant", "Umathdelimiterovervariant", "Umathdelimiterpercent", "Umathdelimitershortfall", "Umathdelimiterundervariant", "Umathdenominatorvariant", "Umathdict", "Umathdictdef", "Umathdiscretionary", "Umathextrasubpreshift", "Umathextrasubprespace", "Umathextrasubshift", "Umathextrasubspace", "Umathextrasuppreshift", "Umathextrasupprespace", "Umathextrasupshift", "Umathextrasupspace", "Umathflattenedaccentbasedepth", "Umathflattenedaccentbaseheight", "Umathflattenedaccentbottomshiftdown", "Umathflattenedaccenttopshiftup", "Umathfractiondelsize", "Umathfractiondenomdown", "Umathfractiondenomvgap", "Umathfractionnumup", "Umathfractionnumvgap", "Umathfractionrule", "Umathfractionvariant", "Umathhextensiblevariant", "Umathlimitabovebgap", "Umathlimitabovekern", "Umathlimitabovevgap", "Umathlimitbelowbgap", "Umathlimitbelowkern", "Umathlimitbelowvgap", "Umathlimits", "Umathnoaxis", "Umathnolimits", "Umathnolimitsubfactor", "Umathnolimitsupfactor", "Umathnumeratorvariant", "Umathopenupdepth", "Umathopenupheight", "Umathoperatorsize", "Umathoverbarkern", "Umathoverbarrule", "Umathoverbarvgap", "Umathoverdelimiterbgap", "Umathoverdelimitervariant", "Umathoverdelimitervgap", "Umathoverlayaccentvariant", "Umathoverlinevariant", "Umathphantom", "Umathpresubshiftdistance", "Umathpresupshiftdistance", "Umathprimeraise", "Umathprimeraisecomposed", "Umathprimeshiftdrop", "Umathprimeshiftup", "Umathprimespaceafter", "Umathprimevariant", "Umathprimewidth", "Umathquad", "Umathradicaldegreeafter", "Umathradicaldegreebefore", "Umathradicaldegreeraise", "Umathradicalextensibleafter", "Umathradicalextensiblebefore", "Umathradicalkern", "Umathradicalrule", "Umathradicalvariant", "Umathradicalvgap", "Umathruledepth", "Umathruleheight", "Umathskeweddelimitertolerance", "Umathskewedfractionhgap", "Umathskewedfractionvgap", "Umathsource", "Umathspaceafterscript", "Umathspacebeforescript", "Umathstackdenomdown", "Umathstacknumup", "Umathstackvariant", "Umathstackvgap", "Umathsubscriptvariant", "Umathsubshiftdistance", "Umathsubshiftdown", "Umathsubshiftdrop", "Umathsubsupshiftdown", "Umathsubsupvgap", "Umathsubtopmax", "Umathsupbottommin", "Umathsuperscriptvariant", "Umathsupshiftdistance", "Umathsupshiftdrop", "Umathsupshiftup", "Umathsupsubbottommax", "Umathtopaccentvariant", "Umathunderbarkern", "Umathunderbarrule", "Umathunderbarvgap", "Umathunderdelimiterbgap", "Umathunderdelimitervariant", "Umathunderdelimitervgap", "Umathunderlinevariant", "Umathuseaxis", "Umathvextensiblevariant", "Umathvoid", "Umathxscale", "Umathyscale", "Umiddle", "Unosubprescript", "Unosubscript", "Unosuperprescript", "Unosuperscript", "Uoperator", "Uover", "Uoverdelimiter", "Uoverwithdelims", "Uprimescript", "Uradical", "Uright", "Uroot", "Urooted", "Ushiftedsubprescript", "Ushiftedsubscript", "Ushiftedsuperprescript", "Ushiftedsuperscript", "Uskewed", "Uskewedwithdelims", "Ustack", "Ustartdisplaymath", "Ustartmath", "Ustartmathmode", "Ustopdisplaymath", "Ustopmath", "Ustopmathmode", "Ustretched", "Ustretchedwithdelims", "Ustyle", "Usubprescript", "Usubscript", "Usuperprescript", "Usuperscript", "Uunderdelimiter", "Uvextensible", "adjustspacing", "adjustspacingshrink", "adjustspacingstep", "adjustspacingstretch", "afterassigned", "aftergrouped", "aliased", "aligncontent", "alignmark", "alignmentcellsource", "alignmentwrapsource", "aligntab", "allcrampedstyles", "alldisplaystyles", "allmainstyles", "allmathstyles", "allscriptscriptstyles", "allscriptstyles", "allsplitstyles", "alltextstyles", "alluncrampedstyles", "allunsplitstyles", "amcode", "atendofgroup", "atendofgrouped", "attribute", "attributedef", "automaticdiscretionary", "automatichyphenpenalty", "automigrationmode", "autoparagraphmode", "begincsname", "beginlocalcontrol", "beginmathgroup", "beginsimplegroup", "boundary", "boxadapt", "boxanchor", "boxanchors", "boxattribute", "boxdirection", "boxfreeze", "boxgeometry", "boxorientation", "boxrepack", "boxshift", "boxsource", "boxtarget", "boxtotal", "boxxmove", "boxxoffset", "boxymove", "boxyoffset", "catcodetable", "cdef", "cdefcsname", "cfcode", "clearmarks", "constant", "copymathatomrule", "copymathparent", "copymathspacing", "crampeddisplaystyle", "crampedscriptscriptstyle", "crampedscriptstyle", "crampedtextstyle", "csactive", "csstring", "currentloopiterator", "currentloopnesting", "currentmarks", "defcsname", "detokenized", "dimensiondef", "dimexpression", "directlua", "edefcsname", "efcode", "endlocalcontrol", "endmathgroup", "endsimplegroup", "enforced", "etoks", "etoksapp", "etokspre", "everybeforepar", "everymathatom", "everytab", "exceptionpenalty", "expand", "expandactive", "expandafterpars", "expandafterspaces", "expandcstoken", "expanded", "expandedafter", "expandedloop", "expandtoken", "explicitdiscretionary", "explicithyphenpenalty", "firstvalidlanguage", "flushmarks", "fontcharta", "fontid", "fontmathcontrol", "fontspecdef", "fontspecid", "fontspecifiedname", "fontspecifiedsize", "fontspecscale", "fontspecxscale", "fontspecyscale", "fonttextcontrol", "formatname", "frozen", "futurecsname", "futuredef", "futureexpand", "futureexpandis", "futureexpandisap", "gdefcsname", "gleaders", "glet", "gletcsname", "glettonothing", "gluespecdef", "glyph", "glyphdatafield", "glyphoptions", "glyphscale", "glyphscriptfield", "glyphscriptscale", "glyphscriptscriptscale", "glyphstatefield", "glyphtextscale", "glyphxoffset", "glyphxscale", "glyphxscaled", "glyphyoffset", "glyphyscale", "glyphyscaled", "gtoksapp", "gtokspre", "hccode", "hjcode", "hmcode", "holdingmigrations", "hpack", "hyphenationmin", "hyphenationmode", "ifabsdim", "ifabsnum", "ifarguments", "ifboolean", "ifchkdim", "ifchknum", "ifcmpdim", "ifcmpnum", "ifcondition", "ifcstok", "ifdimexpression", "ifdimval", "ifempty", "ifflags", "ifhaschar", "ifhastok", "ifhastoks", "ifhasxtoks", "ifincsname", "ifinsert", "ifmathparameter", "ifmathstyle", "ifnumexpression", "ifnumval", "ifparameter", "ifparameters", "ifrelax", "iftok", "ifzerodim", "ifzeronum", "ignorearguments", "ignorepars", "immediate", "immutable", "indexofcharacter", "indexofregister", "inherited", "initcatcodetable", "insertbox", "insertcopy", "insertdepth", "insertdistance", "insertheight", "insertheights", "insertlimit", "insertmaxdepth", "insertmode", "insertmultiplier", "insertpenalty", "insertprogress", "insertstorage", "insertstoring", "insertunbox", "insertuncopy", "insertwidth", "instance", "integerdef", "lastarguments", "lastatomclass", "lastboundary", "lastchkdim", "lastchknum", "lastleftclass", "lastloopiterator", "lastnamedcs", "lastnodesubtype", "lastpageextra", "lastparcontext", "lastrightclass", "leftmarginkern", "letcharcode", "letcsname", "letfrozen", "letmathatomrule", "letmathparent", "letmathspacing", "letprotected", "lettonothing", "linebreakcriterium", "linedirection", "localbrokenpenalty", "localcontrol", "localcontrolled", "localcontrolledloop", "localinterlinepenalty", "localleftbox", "localleftboxbox", "localmiddlebox", "localmiddleboxbox", "localrightbox", "localrightboxbox", "lpcode", "luabytecode", "luabytecodecall", "luacopyinputnodes", "luadef", "luaescapestring", "luafunction", "luafunctioncall", "luatexbanner", "luatexrevision", "luatexversion", "mathaccent", "mathatom", "mathatomglue", "mathatomskip", "mathbackwardpenalties", "mathbeginclass", "mathcheckfencesmode", "mathdictgroup", "mathdictproperties", "mathdirection", "mathdisplaymode", "mathdisplayskipmode", "mathdoublescriptmode", "mathendclass", "matheqnogapstep", "mathfenced", "mathfontcontrol", "mathforwardpenalties", "mathfrac", "mathghost", "mathgluemode", "mathgroupingmode", "mathleftclass", "mathlimitsmode", "mathmainstyle", "mathmiddle", "mathnolimitsmode", "mathpenaltiesmode", "mathrad", "mathrightclass", "mathrulesfam", "mathrulesmode", "mathscale", "mathscriptsmode", "mathslackmode", "mathspacingmode", "mathstackstyle", "mathstyle", "mathstylefontid", "mathsurroundmode", "mathsurroundskip", "maththreshold", "meaningasis", "meaningfull", "meaningless", "mugluespecdef", "mutable", "noaligned", "noatomruling", "noboundary", "nohrule", "norelax", "normalizelinemode", "normalizeparmode", "nospaces", "novrule", "numericscale", "numexpression", "orelse", "orphanpenalties", "orphanpenalty", "orunless", "outputbox", "overloaded", "overloadmode", "overshoot", "pageboundary", "pageextragoal", "pagevsize", "parametercount", "parametermark", "parattribute", "pardirection", "permanent", "pettymuskip", "postexhyphenchar", "posthyphenchar", "postinlinepenalty", "prebinoppenalty", "predisplaygapfactor", "preexhyphenchar", "prehyphenchar", "preinlinepenalty", "prerelpenalty", "protrudechars", "protrusionboundary", "pxdimen", "quitloop", "quitvmode", "resetmathspacing", "retokenized", "rightmarginkern", "rpcode", "savecatcodetable", "scaledemwidth", "scaledexheight", "scaledextraspace", "scaledfontdimen", "scaledinterwordshrink", "scaledinterwordspace", "scaledinterwordstretch", "scaledmathstyle", "scaledslantperpoint", "scantextokens", "semiexpand", "semiexpanded", "semiprotected", "setdefaultmathcodes", "setfontid", "setmathatomrule", "setmathdisplaypostpenalty", "setmathdisplayprepenalty", "setmathignore", "setmathoptions", "setmathpostpenalty", "setmathprepenalty", "setmathspacing", "shapingpenaltiesmode", "shapingpenalty", "snapshotpar", "srule", "supmarkmode", "swapcsvalues", "tabsize", "textdirection", "thewithoutunit", "tinymuskip", "todimension", "tohexadecimal", "tointeger", "tokenized", "toksapp", "tokspre", "tolerant", "tomathstyle", "toscaled", "tosparsedimension", "tosparsescaled", "tpack", "tracingadjusts", "tracingalignments", "tracingexpressions", "tracingfonts", "tracingfullboxes", "tracinghyphenation", "tracinginserts", "tracinglevels", "tracinglists", "tracingmarks", "tracingmath", "tracingnodes", "tracingpenalties", "uleaders", "undent", "unexpandedloop", "unhpack", "unletfrozen", "unletprotected", "untraced", "unvpack", "variablefam", "vpack", "wordboundary", "wrapuppar", "xdefcsname", "xtoks", "xtoksapp", "xtokspre" },
+ ["luatex"]={ "Uabove", "Uabovewithdelims", "Uatop", "Uatopwithdelims", "Uchar", "Udelcode", "Udelimited", "Udelimiter", "Udelimiterover", "Udelimiterunder", "Uhextensible", "Uleft", "Umathaccent", "Umathaccentbasedepth", "Umathaccentbaseheight", "Umathaccentbottomovershoot", "Umathaccentbottomshiftdown", "Umathaccentextendmargin", "Umathaccentsuperscriptdrop", "Umathaccentsuperscriptpercent", "Umathaccenttopovershoot", "Umathaccenttopshiftup", "Umathaccentvariant", "Umathadapttoleft", "Umathadapttoright", "Umathaxis", "Umathbottomaccentvariant", "Umathchar", "Umathcharclass", "Umathchardef", "Umathcharfam", "Umathcharslot", "Umathclass", "Umathcode", "Umathconnectoroverlapmin", "Umathdegreevariant", "Umathdelimiterovervariant", "Umathdelimiterpercent", "Umathdelimitershortfall", "Umathdelimiterundervariant", "Umathdenominatorvariant", "Umathdict", "Umathdictdef", "Umathdiscretionary", "Umathextrasubpreshift", "Umathextrasubprespace", "Umathextrasubshift", "Umathextrasubspace", "Umathextrasuppreshift", "Umathextrasupprespace", "Umathextrasupshift", "Umathextrasupspace", "Umathflattenedaccentbasedepth", "Umathflattenedaccentbaseheight", "Umathflattenedaccentbottomshiftdown", "Umathflattenedaccenttopshiftup", "Umathfractiondelsize", "Umathfractiondenomdown", "Umathfractiondenomvgap", "Umathfractionnumup", "Umathfractionnumvgap", "Umathfractionrule", "Umathfractionvariant", "Umathhextensiblevariant", "Umathlimitabovebgap", "Umathlimitabovekern", "Umathlimitabovevgap", "Umathlimitbelowbgap", "Umathlimitbelowkern", "Umathlimitbelowvgap", "Umathlimits", "Umathnoaxis", "Umathnolimits", "Umathnolimitsubfactor", "Umathnolimitsupfactor", "Umathnumeratorvariant", "Umathopenupdepth", "Umathopenupheight", "Umathoperatorsize", "Umathoverbarkern", "Umathoverbarrule", "Umathoverbarvgap", "Umathoverdelimiterbgap", "Umathoverdelimitervariant", "Umathoverdelimitervgap", "Umathoverlayaccentvariant", "Umathoverlinevariant", "Umathphantom", "Umathpresubshiftdistance", "Umathpresupshiftdistance", "Umathprimeraise", "Umathprimeraisecomposed", "Umathprimeshiftdrop", "Umathprimeshiftup", "Umathprimespaceafter", "Umathprimevariant", "Umathprimewidth", "Umathquad", "Umathradicaldegreeafter", "Umathradicaldegreebefore", "Umathradicaldegreeraise", "Umathradicalextensibleafter", "Umathradicalextensiblebefore", "Umathradicalkern", "Umathradicalrule", "Umathradicalvariant", "Umathradicalvgap", "Umathruledepth", "Umathruleheight", "Umathskeweddelimitertolerance", "Umathskewedfractionhgap", "Umathskewedfractionvgap", "Umathsource", "Umathspaceafterscript", "Umathspacebeforescript", "Umathstackdenomdown", "Umathstacknumup", "Umathstackvariant", "Umathstackvgap", "Umathsubscriptvariant", "Umathsubshiftdistance", "Umathsubshiftdown", "Umathsubshiftdrop", "Umathsubsupshiftdown", "Umathsubsupvgap", "Umathsubtopmax", "Umathsupbottommin", "Umathsuperscriptvariant", "Umathsupshiftdistance", "Umathsupshiftdrop", "Umathsupshiftup", "Umathsupsubbottommax", "Umathtopaccentvariant", "Umathunderbarkern", "Umathunderbarrule", "Umathunderbarvgap", "Umathunderdelimiterbgap", "Umathunderdelimitervariant", "Umathunderdelimitervgap", "Umathunderlinevariant", "Umathuseaxis", "Umathvextensiblevariant", "Umathvoid", "Umathxscale", "Umathyscale", "Umiddle", "Unosubprescript", "Unosubscript", "Unosuperprescript", "Unosuperscript", "Uoperator", "Uover", "Uoverdelimiter", "Uoverwithdelims", "Uprimescript", "Uradical", "Uright", "Uroot", "Urooted", "Ushiftedsubprescript", "Ushiftedsubscript", "Ushiftedsuperprescript", "Ushiftedsuperscript", "Uskewed", "Uskewedwithdelims", "Ustack", "Ustartdisplaymath", "Ustartmath", "Ustartmathmode", "Ustopdisplaymath", "Ustopmath", "Ustopmathmode", "Ustretched", "Ustretchedwithdelims", "Ustyle", "Usubprescript", "Usubscript", "Usuperprescript", "Usuperscript", "Uunderdelimiter", "Uvextensible", "adjustspacing", "adjustspacingshrink", "adjustspacingstep", "adjustspacingstretch", "afterassigned", "aftergrouped", "aliased", "aligncontent", "alignmark", "alignmentcellsource", "alignmentwrapsource", "aligntab", "allcrampedstyles", "alldisplaystyles", "allmainstyles", "allmathstyles", "allscriptscriptstyles", "allscriptstyles", "allsplitstyles", "alltextstyles", "alluncrampedstyles", "allunsplitstyles", "amcode", "atendofgroup", "atendofgrouped", "attribute", "attributedef", "automaticdiscretionary", "automatichyphenpenalty", "automigrationmode", "autoparagraphmode", "begincsname", "beginlocalcontrol", "beginmathgroup", "beginsimplegroup", "boundary", "boxadapt", "boxanchor", "boxanchors", "boxattribute", "boxdirection", "boxfreeze", "boxgeometry", "boxorientation", "boxrepack", "boxshift", "boxsource", "boxtarget", "boxtotal", "boxxmove", "boxxoffset", "boxymove", "boxyoffset", "catcodetable", "cdef", "cdefcsname", "cfcode", "clearmarks", "constant", "copymathatomrule", "copymathparent", "copymathspacing", "crampeddisplaystyle", "crampedscriptscriptstyle", "crampedscriptstyle", "crampedtextstyle", "csactive", "csstring", "currentloopiterator", "currentloopnesting", "currentmarks", "dbox", "defcsname", "detokenized", "dimensiondef", "dimexpression", "directlua", "dpack", "edefcsname", "efcode", "endlocalcontrol", "endmathgroup", "endsimplegroup", "enforced", "etoks", "etoksapp", "etokspre", "everybeforepar", "everymathatom", "everytab", "exceptionpenalty", "expand", "expandactive", "expandafterpars", "expandafterspaces", "expandcstoken", "expanded", "expandedafter", "expandedloop", "expandtoken", "explicitdiscretionary", "explicithyphenpenalty", "firstvalidlanguage", "flushmarks", "fontcharta", "fontid", "fontmathcontrol", "fontspecdef", "fontspecid", "fontspecifiedname", "fontspecifiedsize", "fontspecscale", "fontspecxscale", "fontspecyscale", "fonttextcontrol", "formatname", "frozen", "futurecsname", "futuredef", "futureexpand", "futureexpandis", "futureexpandisap", "gdefcsname", "gleaders", "glet", "gletcsname", "glettonothing", "gluespecdef", "glyph", "glyphdatafield", "glyphoptions", "glyphscale", "glyphscriptfield", "glyphscriptscale", "glyphscriptscriptscale", "glyphstatefield", "glyphtextscale", "glyphxoffset", "glyphxscale", "glyphxscaled", "glyphyoffset", "glyphyscale", "glyphyscaled", "gtoksapp", "gtokspre", "hccode", "hjcode", "hmcode", "holdingmigrations", "hpack", "hyphenationmin", "hyphenationmode", "ifabsdim", "ifabsnum", "ifarguments", "ifboolean", "ifchkdim", "ifchknum", "ifcmpdim", "ifcmpnum", "ifcondition", "ifcstok", "ifdimexpression", "ifdimval", "ifempty", "ifflags", "ifhaschar", "ifhastok", "ifhastoks", "ifhasxtoks", "ifincsname", "ifinsert", "ifmathparameter", "ifmathstyle", "ifnumexpression", "ifnumval", "ifparameter", "ifparameters", "ifrelax", "iftok", "ifzerodim", "ifzeronum", "ignorearguments", "ignorepars", "immediate", "immutable", "indexofcharacter", "indexofregister", "inherited", "initcatcodetable", "insertbox", "insertcopy", "insertdepth", "insertdistance", "insertheight", "insertheights", "insertlimit", "insertmaxdepth", "insertmode", "insertmultiplier", "insertpenalty", "insertprogress", "insertstorage", "insertstoring", "insertunbox", "insertuncopy", "insertwidth", "instance", "integerdef", "lastarguments", "lastatomclass", "lastboundary", "lastchkdim", "lastchknum", "lastleftclass", "lastloopiterator", "lastnamedcs", "lastnodesubtype", "lastpageextra", "lastparcontext", "lastrightclass", "leftmarginkern", "letcharcode", "letcsname", "letfrozen", "letmathatomrule", "letmathparent", "letmathspacing", "letprotected", "lettonothing", "linebreakcriterium", "linedirection", "localbrokenpenalty", "localcontrol", "localcontrolled", "localcontrolledloop", "localinterlinepenalty", "localleftbox", "localleftboxbox", "localmiddlebox", "localmiddleboxbox", "localrightbox", "localrightboxbox", "lpcode", "luabytecode", "luabytecodecall", "luacopyinputnodes", "luadef", "luaescapestring", "luafunction", "luafunctioncall", "luatexbanner", "luatexrevision", "luatexversion", "mathaccent", "mathatom", "mathatomglue", "mathatomskip", "mathbackwardpenalties", "mathbeginclass", "mathcheckfencesmode", "mathdictgroup", "mathdictproperties", "mathdirection", "mathdisplaymode", "mathdisplayskipmode", "mathdoublescriptmode", "mathendclass", "matheqnogapstep", "mathfenced", "mathfontcontrol", "mathforwardpenalties", "mathfrac", "mathghost", "mathgluemode", "mathgroupingmode", "mathleftclass", "mathlimitsmode", "mathmainstyle", "mathmiddle", "mathnolimitsmode", "mathpenaltiesmode", "mathrad", "mathrightclass", "mathrulesfam", "mathrulesmode", "mathscale", "mathscriptsmode", "mathslackmode", "mathspacingmode", "mathstackstyle", "mathstyle", "mathstylefontid", "mathsurroundmode", "mathsurroundskip", "maththreshold", "meaningasis", "meaningfull", "meaningless", "mugluespecdef", "mutable", "noaligned", "noatomruling", "noboundary", "nohrule", "norelax", "normalizelinemode", "normalizeparmode", "nospaces", "novrule", "numericscale", "numexpression", "orelse", "orphanpenalties", "orphanpenalty", "orunless", "outputbox", "overloaded", "overloadmode", "overshoot", "pageboundary", "pageextragoal", "pagevsize", "parametercount", "parametermark", "parattribute", "pardirection", "permanent", "pettymuskip", "postexhyphenchar", "posthyphenchar", "postinlinepenalty", "prebinoppenalty", "predisplaygapfactor", "preexhyphenchar", "prehyphenchar", "preinlinepenalty", "prerelpenalty", "protrudechars", "protrusionboundary", "pxdimen", "quitloop", "quitvmode", "resetmathspacing", "retokenized", "rightmarginkern", "rpcode", "savecatcodetable", "scaledemwidth", "scaledexheight", "scaledextraspace", "scaledfontdimen", "scaledinterwordshrink", "scaledinterwordspace", "scaledinterwordstretch", "scaledmathstyle", "scaledslantperpoint", "scantextokens", "semiexpand", "semiexpanded", "semiprotected", "setdefaultmathcodes", "setfontid", "setmathatomrule", "setmathdisplaypostpenalty", "setmathdisplayprepenalty", "setmathignore", "setmathoptions", "setmathpostpenalty", "setmathprepenalty", "setmathspacing", "shapingpenaltiesmode", "shapingpenalty", "snapshotpar", "srule", "supmarkmode", "swapcsvalues", "tabsize", "textdirection", "thewithoutunit", "tinymuskip", "todimension", "tohexadecimal", "tointeger", "tokenized", "toksapp", "tokspre", "tolerant", "tomathstyle", "toscaled", "tosparsedimension", "tosparsescaled", "tpack", "tracingadjusts", "tracingalignments", "tracingexpressions", "tracingfonts", "tracingfullboxes", "tracinghyphenation", "tracinginserts", "tracinglevels", "tracinglists", "tracingmarks", "tracingmath", "tracingnodes", "tracingpenalties", "uleaders", "undent", "unexpandedloop", "unhpack", "unletfrozen", "unletprotected", "untraced", "unvpack", "variablefam", "vpack", "wordboundary", "wrapuppar", "xdefcsname", "xtoks", "xtoksapp", "xtokspre" },
["omega"]={ "Omegaminorversion", "Omegarevision", "Omegaversion" },
["pdftex"]={ "ifpdfabsdim", "ifpdfabsnum", "ifpdfprimitive", "pdfadjustspacing", "pdfannot", "pdfcatalog", "pdfcolorstack", "pdfcolorstackinit", "pdfcompresslevel", "pdfcopyfont", "pdfcreationdate", "pdfdecimaldigits", "pdfdest", "pdfdestmargin", "pdfdraftmode", "pdfeachlinedepth", "pdfeachlineheight", "pdfendlink", "pdfendthread", "pdffirstlineheight", "pdffontattr", "pdffontexpand", "pdffontname", "pdffontobjnum", "pdffontsize", "pdfgamma", "pdfgentounicode", "pdfglyphtounicode", "pdfhorigin", "pdfignoreddimen", "pdfignoreunknownimages", "pdfimageaddfilename", "pdfimageapplygamma", "pdfimagegamma", "pdfimagehicolor", "pdfimageresolution", "pdfincludechars", "pdfinclusioncopyfonts", "pdfinclusionerrorlevel", "pdfinfo", "pdfinfoomitdate", "pdfinsertht", "pdflastannot", "pdflastlinedepth", "pdflastlink", "pdflastobj", "pdflastxform", "pdflastximage", "pdflastximagepages", "pdflastxpos", "pdflastypos", "pdflinkmargin", "pdfliteral", "pdfmajorversion", "pdfmapfile", "pdfmapline", "pdfminorversion", "pdfnames", "pdfnoligatures", "pdfnormaldeviate", "pdfobj", "pdfobjcompresslevel", "pdfomitcharset", "pdfomitcidset", "pdfomitinfodict", "pdfoutline", "pdfoutput", "pdfpageattr", "pdfpagebox", "pdfpageheight", "pdfpageref", "pdfpageresources", "pdfpagesattr", "pdfpagewidth", "pdfpkfixeddpi", "pdfpkmode", "pdfpkresolution", "pdfprimitive", "pdfprotrudechars", "pdfpxdimen", "pdfrandomseed", "pdfrecompress", "pdfrefobj", "pdfrefxform", "pdfrefximage", "pdfreplacefont", "pdfrestore", "pdfretval", "pdfsave", "pdfsavepos", "pdfsetmatrix", "pdfsetrandomseed", "pdfstartlink", "pdfstartthread", "pdfsuppressoptionalinfo", "pdfsuppressptexinfo", "pdftexbanner", "pdftexrevision", "pdftexversion", "pdfthread", "pdfthreadmargin", "pdftracingfonts", "pdftrailer", "pdftrailerid", "pdfuniformdeviate", "pdfuniqueresname", "pdfvorigin", "pdfxform", "pdfxformattr", "pdfxformmargin", "pdfxformname", "pdfxformresources", "pdfximage" },
- ["tex"]={ " ", "-", "/", "above", "abovedisplayshortskip", "abovedisplayskip", "abovewithdelims", "accent", "adjdemerits", "advance", "afterassignment", "aftergroup", "atop", "atopwithdelims", "badness", "baselineskip", "batchmode", "begingroup", "belowdisplayshortskip", "belowdisplayskip", "binoppenalty", "botmark", "box", "boxmaxdepth", "brokenpenalty", "catcode", "char", "chardef", "cleaders", "clubpenalty", "copy", "count", "countdef", "cr", "crcr", "csname", "day", "deadcycles", "def", "defaulthyphenchar", "defaultskewchar", "delcode", "delimiter", "delimiterfactor", "delimitershortfall", "dimen", "dimendef", "discretionary", "displayindent", "displaylimits", "displaystyle", "displaywidowpenalty", "displaywidth", "divide", "doublehyphendemerits", "dp", "dump", "edef", "else", "emergencystretch", "end", "endcsname", "endgroup", "endinput", "endlinechar", "eqno", "errhelp", "errmessage", "errorcontextlines", "errorstopmode", "escapechar", "everycr", "everydisplay", "everyhbox", "everyjob", "everymath", "everypar", "everyvbox", "exhyphenchar", "exhyphenpenalty", "expandafter", "fam", "fi", "finalhyphendemerits", "firstmark", "floatingpenalty", "font", "fontdimen", "fontname", "futurelet", "gdef", "global", "globaldefs", "halign", "hangafter", "hangindent", "hbadness", "hbox", "hfil", "hfill", "hfilneg", "hfuzz", "holdinginserts", "hrule", "hsize", "hskip", "hss", "ht", "hyphenation", "hyphenchar", "hyphenpenalty", "if", "ifcase", "ifcat", "ifdim", "iffalse", "ifhbox", "ifhmode", "ifinner", "ifmmode", "ifnum", "ifodd", "iftrue", "ifvbox", "ifvmode", "ifvoid", "ifx", "ignorespaces", "indent", "input", "inputlineno", "insert", "insertpenalties", "interlinepenalty", "jobname", "kern", "language", "lastbox", "lastkern", "lastpenalty", "lastskip", "lccode", "leaders", "left", "lefthyphenmin", "leftskip", "leqno", "let", "limits", "linepenalty", "lineskip", "lineskiplimit", "long", "looseness", "lower", "lowercase", "mark", "mathbin", "mathchar", "mathchardef", "mathchoice", "mathclose", "mathcode", "mathinner", "mathop", "mathopen", "mathord", "mathpunct", "mathrel", "mathsurround", "maxdeadcycles", "maxdepth", "meaning", "medmuskip", "message", "middle", "mkern", "month", "moveleft", "moveright", "mskip", "multiply", "muskip", "muskipdef", "newlinechar", "noalign", "noexpand", "noindent", "nolimits", "nonscript", "nonstopmode", "nulldelimiterspace", "nullfont", "number", "omit", "or", "outer", "output", "outputpenalty", "over", "overfullrule", "overline", "overwithdelims", "pagedepth", "pagefilllstretch", "pagefillstretch", "pagefilstretch", "pagegoal", "pageshrink", "pagestretch", "pagetotal", "par", "parfillleftskip", "parfillskip", "parindent", "parinitleftskip", "parinitrightskip", "parshape", "parskip", "patterns", "pausing", "penalty", "postdisplaypenalty", "predisplaypenalty", "predisplaysize", "pretolerance", "prevdepth", "prevgraf", "radical", "raise", "relax", "relpenalty", "right", "righthyphenmin", "rightskip", "romannumeral", "scriptfont", "scriptscriptfont", "scriptscriptstyle", "scriptspace", "scriptstyle", "scrollmode", "setbox", "setlanguage", "sfcode", "shipout", "show", "showbox", "showboxbreadth", "showboxdepth", "showlists", "shownodedetails", "showthe", "skewchar", "skip", "skipdef", "spacefactor", "spaceskip", "span", "splitbotmark", "splitfirstmark", "splitmaxdepth", "splittopskip", "string", "tabskip", "textfont", "textstyle", "the", "thickmuskip", "thinmuskip", "time", "toks", "toksdef", "tolerance", "topmark", "topskip", "tracingcommands", "tracinglostchars", "tracingmacros", "tracingonline", "tracingoutput", "tracingpages", "tracingparagraphs", "tracingrestores", "tracingstats", "uccode", "uchyph", "unboundary", "underline", "unhbox", "unhcopy", "unkern", "unpenalty", "unskip", "unvbox", "unvcopy", "uppercase", "vadjust", "valign", "vbadness", "vbox", "vcenter", "vfil", "vfill", "vfilneg", "vfuzz", "vrule", "vsize", "vskip", "vsplit", "vss", "vtop", "wd", "widowpenalty", "xdef", "xleaders", "xspaceskip", "year" },
+ ["tex"]={ " ", "-", "/", "above", "abovedisplayshortskip", "abovedisplayskip", "abovewithdelims", "accent", "adjdemerits", "advance", "advanceby", "afterassignment", "aftergroup", "atop", "atopwithdelims", "badness", "baselineskip", "batchmode", "begingroup", "belowdisplayshortskip", "belowdisplayskip", "binoppenalty", "botmark", "box", "boxmaxdepth", "brokenpenalty", "catcode", "char", "chardef", "cleaders", "clubpenalty", "copy", "count", "countdef", "cr", "crcr", "csname", "day", "deadcycles", "def", "defaulthyphenchar", "defaultskewchar", "delcode", "delimiter", "delimiterfactor", "delimitershortfall", "dimen", "dimendef", "discretionary", "displayindent", "displaylimits", "displaystyle", "displaywidowpenalty", "displaywidth", "divide", "divideby", "doublehyphendemerits", "dp", "dump", "edef", "else", "emergencystretch", "end", "endcsname", "endgroup", "endinput", "endlinechar", "eqno", "errhelp", "errmessage", "errorcontextlines", "errorstopmode", "escapechar", "everycr", "everydisplay", "everyhbox", "everyjob", "everymath", "everypar", "everyvbox", "exhyphenchar", "exhyphenpenalty", "expandafter", "fam", "fi", "finalhyphendemerits", "firstmark", "floatingpenalty", "font", "fontdimen", "fontname", "futurelet", "gdef", "global", "globaldefs", "halign", "hangafter", "hangindent", "hbadness", "hbox", "hfil", "hfill", "hfilneg", "hfuzz", "holdinginserts", "hrule", "hsize", "hskip", "hss", "ht", "hyphenation", "hyphenchar", "hyphenpenalty", "if", "ifcase", "ifcat", "ifdim", "iffalse", "ifhbox", "ifhmode", "ifinner", "ifmmode", "ifnum", "ifodd", "iftrue", "ifvbox", "ifvmode", "ifvoid", "ifx", "ignorespaces", "indent", "input", "inputlineno", "insert", "insertpenalties", "interlinepenalty", "jobname", "kern", "language", "lastbox", "lastkern", "lastpenalty", "lastskip", "lccode", "leaders", "left", "lefthyphenmin", "leftskip", "leqno", "let", "limits", "linepenalty", "lineskip", "lineskiplimit", "long", "looseness", "lower", "lowercase", "mark", "mathbin", "mathchar", "mathchardef", "mathchoice", "mathclose", "mathcode", "mathinner", "mathop", "mathopen", "mathord", "mathpunct", "mathrel", "mathsurround", "maxdeadcycles", "maxdepth", "meaning", "medmuskip", "message", "middle", "mkern", "month", "moveleft", "moveright", "mskip", "multiply", "multiplyby", "muskip", "muskipdef", "newlinechar", "noalign", "noexpand", "noindent", "nolimits", "nonscript", "nonstopmode", "nulldelimiterspace", "nullfont", "number", "omit", "or", "outer", "output", "outputpenalty", "over", "overfullrule", "overline", "overwithdelims", "pagedepth", "pagefilllstretch", "pagefillstretch", "pagefilstretch", "pagegoal", "pageshrink", "pagestretch", "pagetotal", "par", "parfillleftskip", "parfillskip", "parindent", "parinitleftskip", "parinitrightskip", "parshape", "parskip", "patterns", "pausing", "penalty", "postdisplaypenalty", "predisplaypenalty", "predisplaysize", "pretolerance", "prevdepth", "prevgraf", "radical", "raise", "relax", "relpenalty", "right", "righthyphenmin", "rightskip", "romannumeral", "scriptfont", "scriptscriptfont", "scriptscriptstyle", "scriptspace", "scriptstyle", "scrollmode", "setbox", "setlanguage", "sfcode", "shipout", "show", "showbox", "showboxbreadth", "showboxdepth", "showlists", "shownodedetails", "showthe", "skewchar", "skip", "skipdef", "spacefactor", "spaceskip", "span", "splitbotmark", "splitfirstmark", "splitmaxdepth", "splittopskip", "string", "tabskip", "textfont", "textstyle", "the", "thickmuskip", "thinmuskip", "time", "toks", "toksdef", "tolerance", "topmark", "topskip", "tracingcommands", "tracinglostchars", "tracingmacros", "tracingonline", "tracingoutput", "tracingpages", "tracingparagraphs", "tracingrestores", "tracingstats", "uccode", "uchyph", "unboundary", "underline", "unhbox", "unhcopy", "unkern", "unpenalty", "unskip", "unvbox", "unvcopy", "uppercase", "vadjust", "valign", "vbadness", "vbox", "vcenter", "vfil", "vfill", "vfilneg", "vfuzz", "vrule", "vsize", "vskip", "vsplit", "vss", "vtop", "wd", "widowpenalty", "xdef", "xleaders", "xspaceskip", "year" },
["xetex"]={ "XeTeXversion" },
} \ No newline at end of file
diff --git a/context/data/scite/context/scite-context-data-context.properties b/context/data/scite/context/scite-context-data-context.properties
index 3adb1cd7b..b5691cf3b 100644
--- a/context/data/scite/context/scite-context-data-context.properties
+++ b/context/data/scite/context/scite-context-data-context.properties
@@ -4,121 +4,121 @@ plustwo plusthree plusfour plusfive plussix \
plusseven pluseight plusnine plusten pluseleven \
plustwelve plussixteen plusfifty plushundred plusonehundred \
plustwohundred plusfivehundred plusthousand plustenthousand plustwentythousand \
-medcard maxcard maxcardminusone zeropoint onepoint \
-halfapoint onebasepoint maxcount maxdimen scaledpoint \
-thousandpoint points halfpoint zeroskip centeringskip \
-stretchingskip shrinkingskip centeringfillskip stretchingfillskip shrinkingfillskip \
-zeromuskip onemuskip pluscxxvii pluscxxviii pluscclv \
-pluscclvi normalpagebox binaryshiftedten binaryshiftedtwenty binaryshiftedthirty \
-thickermuskip directionlefttoright directionrighttoleft endoflinetoken outputnewlinechar \
-emptytoks empty undefined prerollrun voidbox \
-emptybox emptyvbox emptyhbox bigskipamount medskipamount \
-smallskipamount fmtname fmtversion texengine texenginename \
-texengineversion texenginefunctionality luatexengine pdftexengine xetexengine \
-unknownengine contextformat contextversion contextlmtxmode contextmark \
-mksuffix activecatcode bgroup egroup endline \
-conditionaltrue conditionalfalse attributeunsetvalue statuswrite uprotationangle \
-rightrotationangle downrotationangle leftrotationangle inicatcodes ctxcatcodes \
-texcatcodes notcatcodes txtcatcodes vrbcatcodes prtcatcodes \
-nilcatcodes luacatcodes tpacatcodes tpbcatcodes xmlcatcodes \
-ctdcatcodes rlncatcodes escapecatcode begingroupcatcode endgroupcatcode \
-mathshiftcatcode alignmentcatcode endoflinecatcode parametercatcode superscriptcatcode \
-subscriptcatcode ignorecatcode spacecatcode lettercatcode othercatcode \
-activecatcode commentcatcode invalidcatcode tabasciicode newlineasciicode \
-formfeedasciicode endoflineasciicode endoffileasciicode commaasciicode spaceasciicode \
-periodasciicode hashasciicode dollarasciicode commentasciicode ampersandasciicode \
-colonasciicode backslashasciicode circumflexasciicode underscoreasciicode leftbraceasciicode \
-barasciicode rightbraceasciicode tildeasciicode delasciicode leftparentasciicode \
-rightparentasciicode lessthanasciicode morethanasciicode doublecommentsignal atsignasciicode \
-exclamationmarkasciicode questionmarkasciicode doublequoteasciicode singlequoteasciicode forwardslashasciicode \
-primeasciicode hyphenasciicode percentasciicode leftbracketasciicode rightbracketasciicode \
-hsizefrozenparcode skipfrozenparcode hangfrozenparcode indentfrozenparcode parfillfrozenparcode \
-adjustfrozenparcode protrudefrozenparcode tolerancefrozenparcode stretchfrozenparcode loosenessfrozenparcode \
-lastlinefrozenparcode linepenaltyfrozenparcode clubpenaltyfrozenparcode widowpenaltyfrozenparcode displaypenaltyfrozenparcode \
-brokenpenaltyfrozenparcode demeritsfrozenparcode shapefrozenparcode linefrozenparcode hyphenationfrozenparcode \
-shapingpenaltyfrozenparcode orphanpenaltyfrozenparcode allfrozenparcode mathpenaltyfrozenparcode activemathcharcode \
-activetabtoken activeformfeedtoken activeendoflinetoken batchmodecode nonstopmodecode \
-scrollmodecode errorstopmodecode bottomlevelgroupcode simplegroupcode hboxgroupcode \
-adjustedhboxgroupcode vboxgroupcode vtopgroupcode aligngroupcode noaligngroupcode \
-outputgroupcode mathgroupcode discretionarygroupcode insertgroupcode vadjustgroupcode \
-vcentergroupcode mathabovegroupcode mathchoicegroupcode alsosimplegroupcode semisimplegroupcode \
-mathshiftgroupcode mathleftgroupcode localboxgroupcode splitoffgroupcode splitkeepgroupcode \
-preamblegroupcode alignsetgroupcode finrowgroupcode discretionarygroupcode markautomigrationcode \
-insertautomigrationcode adjustautomigrationcode preautomigrationcode postautomigrationcode charnodecode \
-hlistnodecode vlistnodecode rulenodecode insertnodecode marknodecode \
-adjustnodecode ligaturenodecode discretionarynodecode whatsitnodecode mathnodecode \
-gluenodecode kernnodecode penaltynodecode unsetnodecode mathsnodecode \
-overrulemathcontrolcode underrulemathcontrolcode radicalrulemathcontrolcode fractionrulemathcontrolcode accentskewhalfmathcontrolcode \
-accentskewapplymathcontrolcode applyordinarykernpairmathcontrolcode applyverticalitalickernmathcontrolcode applyordinaryitalickernmathcontrolcode applycharitalickernmathcontrolcode \
-reboxcharitalickernmathcontrolcode applyboxeditalickernmathcontrolcode staircasekernmathcontrolcode applytextitalickernmathcontrolcode applyscriptitalickernmathcontrolcode \
-checkspaceitalickernmathcontrolcode checktextitalickernmathcontrolcode analyzescriptnucleuscharmathcontrolcode analyzescriptnucleuslistmathcontrolcode analyzescriptnucleusboxmathcontrolcode \
-accenttopskewwithoffsetmathcontrolcode ignorekerndimensionsmathcontrolcode ignoreflataccentsmathcontrolcode extendaccentsmathcontrolcode noligaturingglyphoptioncode \
-nokerningglyphoptioncode noexpansionglyphoptioncode noprotrusionglyphoptioncode noleftkerningglyphoptioncode noleftligaturingglyphoptioncode \
-norightkerningglyphoptioncode norightligaturingglyphoptioncode noitaliccorrectionglyphoptioncode islargeoperatorglyphoptioncode hasitalicshapeglyphoptioncode \
-normalparcontextcode vmodeparcontextcode vboxparcontextcode vtopparcontextcode vcenterparcontextcode \
-vadjustparcontextcode insertparcontextcode outputparcontextcode alignparcontextcode noalignparcontextcode \
-spanparcontextcode resetparcontextcode leftoriginlistanchorcode leftheightlistanchorcode leftdepthlistanchorcode \
-rightoriginlistanchorcode rightheightlistanchorcode rightdepthlistanchorcode centeroriginlistanchorcode centerheightlistanchorcode \
-centerdepthlistanchorcode halfwaytotallistanchorcode halfwayheightlistanchorcode halfwaydepthlistanchorcode halfwayleftlistanchorcode \
-halfwayrightlistanchorcode negatexlistsigncode negateylistsigncode negatelistsigncode fontslantperpoint \
-fontinterwordspace fontinterwordstretch fontinterwordshrink fontexheight fontemwidth \
-fontextraspace slantperpoint mathexheight mathemwidth interwordspace \
-interwordstretch interwordshrink exheight emwidth extraspace \
-mathaxisheight muquad startmode stopmode startnotmode \
-stopnotmode startmodeset stopmodeset doifmode doifelsemode \
-doifmodeelse doifnotmode startmodeset stopmodeset startallmodes \
-stopallmodes startnotallmodes stopnotallmodes doifallmodes doifelseallmodes \
-doifallmodeselse doifnotallmodes startenvironment stopenvironment environment \
-startcomponent stopcomponent component startproduct stopproduct \
-product startproject stopproject project starttext \
-stoptext startnotext stopnotext startdocument stopdocument \
-documentvariable unexpandeddocumentvariable setupdocument presetdocument doifelsedocumentvariable \
-doifdocumentvariableelse doifdocumentvariable doifnotdocumentvariable startmodule stopmodule \
-usemodule usetexmodule useluamodule setupmodule currentmoduleparameter \
-moduleparameter everystarttext everystoptext startTEXpage stopTEXpage \
-enablemode disablemode preventmode definemode globalenablemode \
-globaldisablemode globalpreventmode pushmode popmode typescriptone \
-typescripttwo typescriptthree mathsizesuffix mathordinarycode mathordcode \
-mathoperatorcode mathopcode mathbinarycode mathbincode mathrelationcode \
-mathrelcode mathopencode mathclosecode mathpunctuationcode mathpunctcode \
-mathovercode mathundercode mathinnercode mathradicalcode mathfractioncode \
-mathmiddlecode mathaccentcode mathfencedcode mathghostcode mathvariablecode \
-mathactivecode mathvcentercode mathconstructcode mathwrappedcode mathbegincode \
-mathendcode mathexplicitcode mathdivisioncode mathfactorialcode mathdimensioncode \
-mathexperimentalcode mathtextpunctuationcode mathimaginarycode mathdifferentialcode mathexponentialcode \
-mathellipsiscode mathfunctioncode mathdigitcode mathalphacode mathboxcode \
-mathchoicecode mathnothingcode mathlimopcode mathnolopcode mathunsetcode \
-mathunspacedcode mathallcode mathfakecode mathunarycode mathmaybeordinarycode \
-mathmayberelationcode mathmaybebinarycode mathnumbergroupcode constantnumber constantnumberargument \
-constantdimen constantdimenargument constantemptyargument luastringsep !!bs \
-!!es lefttorightmark righttoleftmark lrm rlm \
-bidilre bidirle bidipop bidilro bidirlo \
-breakablethinspace nobreakspace nonbreakablespace narrownobreakspace zerowidthnobreakspace \
-ideographicspace ideographichalffillspace twoperemspace threeperemspace fourperemspace \
-fiveperemspace sixperemspace figurespace punctuationspace hairspace \
-enquad emquad zerowidthspace zerowidthnonjoiner zerowidthjoiner \
-zwnj zwj optionalspace asciispacechar softhyphen \
-autoinsertedspace Ux eUx Umathaccents parfillleftskip \
-parfillrightskip startlmtxmode stoplmtxmode startmkivmode stopmkivmode \
-wildcardsymbol normalhyphenationcode automatichyphenationcode explicithyphenationcode syllablehyphenationcode \
-uppercasehyphenationcode collapsehyphenationcode compoundhyphenationcode strictstarthyphenationcode strictendhyphenationcode \
-automaticpenaltyhyphenationcode explicitpenaltyhyphenationcode permitgluehyphenationcode permitallhyphenationcode permitmathreplacehyphenationcode \
-forcecheckhyphenationcode lazyligatureshyphenationcode forcehandlerhyphenationcode feedbackcompoundhyphenationcode ignoreboundshyphenationcode \
-partialhyphenationcode completehyphenationcode normalizelinenormalizecode parindentskipnormalizecode swaphangindentnormalizecode \
-swapparsshapenormalizecode breakafterdirnormalizecode removemarginkernsnormalizecode clipwidthnormalizecode flattendiscretionariesnormalizecode \
-discardzerotabskipsnormalizecode flattenhleadersnormalizecode normalizeparnormalizeparcode flattenvleadersnormalizeparcode nopreslackclassoptioncode \
-nopostslackclassoptioncode lefttopkernclassoptioncode righttopkernclassoptioncode leftbottomkernclassoptioncode rightbottomkernclassoptioncode \
-lookaheadforendclassoptioncode noitaliccorrectionclassoptioncode defaultmathclassoptions checkligatureclassoptioncode checkitaliccorrectionclassoptioncode \
-checkkernpairclassoptioncode flattenclassoptioncode omitpenaltyclassoptioncode unpackclassoptioncode raiseprimeclassoptioncode \
-carryoverlefttopkernclassoptioncode carryoverleftbottomkernclassoptioncode carryoverrighttopkernclassoptioncode carryoverrightbottomkernclassoptioncode preferdelimiterdimensionsclassoptioncode \
-autoinjectclassoptioncode removeitaliccorrectionclassoptioncode operatoritaliccorrectionclassoptioncode noligaturingglyphoptioncode nokerningglyphoptioncode \
-noleftligatureglyphoptioncode noleftkernglyphoptioncode norightligatureglyphoptioncode norightkernglyphoptioncode noexpansionglyphoptioncode \
-noprotrusionglyphoptioncode noitaliccorrectionglyphoptioncode nokerningcode noligaturingcode frozenflagcode \
-tolerantflagcode protectedflagcode primitiveflagcode permanentflagcode noalignedflagcode \
-immutableflagcode mutableflagcode globalflagcode overloadedflagcode immediateflagcode \
-conditionalflagcode valueflagcode instanceflagcode ordmathflattencode binmathflattencode \
-relmathflattencode punctmathflattencode innermathflattencode normalworddiscoptioncode preworddiscoptioncode \
-postworddiscoptioncode continueifinputfile continuewhenlmtxmode continuewhenmkivmode
+medcard maxcard maxcardminusone maxiterator zeropoint \
+onepoint halfapoint onebasepoint maxcount maxdimen \
+scaledpoint thousandpoint points halfpoint zeroskip \
+centeringskip stretchingskip shrinkingskip centeringfillskip stretchingfillskip \
+shrinkingfillskip zeromuskip onemuskip pluscxxvii pluscxxviii \
+pluscclv pluscclvi normalpagebox binaryshiftedten binaryshiftedtwenty \
+binaryshiftedthirty thickermuskip directionlefttoright directionrighttoleft endoflinetoken \
+outputnewlinechar emptytoks empty undefined prerollrun \
+voidbox emptybox emptyvbox emptyhbox bigskipamount \
+medskipamount smallskipamount fmtname fmtversion texengine \
+texenginename texengineversion texenginefunctionality luatexengine pdftexengine \
+xetexengine unknownengine contextformat contextversion contextlmtxmode \
+contextmark mksuffix activecatcode bgroup egroup \
+endline conditionaltrue conditionalfalse attributeunsetvalue statuswrite \
+uprotationangle rightrotationangle downrotationangle leftrotationangle inicatcodes \
+ctxcatcodes texcatcodes notcatcodes txtcatcodes vrbcatcodes \
+prtcatcodes nilcatcodes luacatcodes tpacatcodes tpbcatcodes \
+xmlcatcodes ctdcatcodes rlncatcodes escapecatcode begingroupcatcode \
+endgroupcatcode mathshiftcatcode alignmentcatcode endoflinecatcode parametercatcode \
+superscriptcatcode subscriptcatcode ignorecatcode spacecatcode lettercatcode \
+othercatcode activecatcode commentcatcode invalidcatcode tabasciicode \
+newlineasciicode formfeedasciicode endoflineasciicode endoffileasciicode commaasciicode \
+spaceasciicode periodasciicode hashasciicode dollarasciicode commentasciicode \
+ampersandasciicode colonasciicode backslashasciicode circumflexasciicode underscoreasciicode \
+leftbraceasciicode barasciicode rightbraceasciicode tildeasciicode delasciicode \
+leftparentasciicode rightparentasciicode lessthanasciicode morethanasciicode doublecommentsignal \
+atsignasciicode exclamationmarkasciicode questionmarkasciicode doublequoteasciicode singlequoteasciicode \
+forwardslashasciicode primeasciicode hyphenasciicode percentasciicode leftbracketasciicode \
+rightbracketasciicode hsizefrozenparcode skipfrozenparcode hangfrozenparcode indentfrozenparcode \
+parfillfrozenparcode adjustfrozenparcode protrudefrozenparcode tolerancefrozenparcode stretchfrozenparcode \
+loosenessfrozenparcode lastlinefrozenparcode linepenaltyfrozenparcode clubpenaltyfrozenparcode widowpenaltyfrozenparcode \
+displaypenaltyfrozenparcode brokenpenaltyfrozenparcode demeritsfrozenparcode shapefrozenparcode linefrozenparcode \
+hyphenationfrozenparcode shapingpenaltyfrozenparcode orphanpenaltyfrozenparcode allfrozenparcode mathpenaltyfrozenparcode \
+activemathcharcode activetabtoken activeformfeedtoken activeendoflinetoken batchmodecode \
+nonstopmodecode scrollmodecode errorstopmodecode bottomlevelgroupcode simplegroupcode \
+hboxgroupcode adjustedhboxgroupcode vboxgroupcode vtopgroupcode aligngroupcode \
+noaligngroupcode outputgroupcode mathgroupcode discretionarygroupcode insertgroupcode \
+vadjustgroupcode vcentergroupcode mathabovegroupcode mathchoicegroupcode alsosimplegroupcode \
+semisimplegroupcode mathshiftgroupcode mathleftgroupcode localboxgroupcode splitoffgroupcode \
+splitkeepgroupcode preamblegroupcode alignsetgroupcode finrowgroupcode discretionarygroupcode \
+markautomigrationcode insertautomigrationcode adjustautomigrationcode preautomigrationcode postautomigrationcode \
+charnodecode hlistnodecode vlistnodecode rulenodecode insertnodecode \
+marknodecode adjustnodecode ligaturenodecode discretionarynodecode whatsitnodecode \
+mathnodecode gluenodecode kernnodecode penaltynodecode unsetnodecode \
+mathsnodecode overrulemathcontrolcode underrulemathcontrolcode radicalrulemathcontrolcode fractionrulemathcontrolcode \
+accentskewhalfmathcontrolcode accentskewapplymathcontrolcode applyordinarykernpairmathcontrolcode applyverticalitalickernmathcontrolcode applyordinaryitalickernmathcontrolcode \
+applycharitalickernmathcontrolcode reboxcharitalickernmathcontrolcode applyboxeditalickernmathcontrolcode staircasekernmathcontrolcode applytextitalickernmathcontrolcode \
+applyscriptitalickernmathcontrolcode checkspaceitalickernmathcontrolcode checktextitalickernmathcontrolcode analyzescriptnucleuscharmathcontrolcode analyzescriptnucleuslistmathcontrolcode \
+analyzescriptnucleusboxmathcontrolcode accenttopskewwithoffsetmathcontrolcode ignorekerndimensionsmathcontrolcode ignoreflataccentsmathcontrolcode extendaccentsmathcontrolcode \
+noligaturingglyphoptioncode nokerningglyphoptioncode noexpansionglyphoptioncode noprotrusionglyphoptioncode noleftkerningglyphoptioncode \
+noleftligaturingglyphoptioncode norightkerningglyphoptioncode norightligaturingglyphoptioncode noitaliccorrectionglyphoptioncode islargeoperatorglyphoptioncode \
+hasitalicshapeglyphoptioncode normalparcontextcode vmodeparcontextcode vboxparcontextcode vtopparcontextcode \
+vcenterparcontextcode vadjustparcontextcode insertparcontextcode outputparcontextcode alignparcontextcode \
+noalignparcontextcode spanparcontextcode resetparcontextcode leftoriginlistanchorcode leftheightlistanchorcode \
+leftdepthlistanchorcode rightoriginlistanchorcode rightheightlistanchorcode rightdepthlistanchorcode centeroriginlistanchorcode \
+centerheightlistanchorcode centerdepthlistanchorcode halfwaytotallistanchorcode halfwayheightlistanchorcode halfwaydepthlistanchorcode \
+halfwayleftlistanchorcode halfwayrightlistanchorcode negatexlistsigncode negateylistsigncode negatelistsigncode \
+fontslantperpoint fontinterwordspace fontinterwordstretch fontinterwordshrink fontexheight \
+fontemwidth fontextraspace slantperpoint mathexheight mathemwidth \
+interwordspace interwordstretch interwordshrink exheight emwidth \
+extraspace mathaxisheight muquad startmode stopmode \
+startnotmode stopnotmode startmodeset stopmodeset doifmode \
+doifelsemode doifmodeelse doifnotmode startmodeset stopmodeset \
+startallmodes stopallmodes startnotallmodes stopnotallmodes doifallmodes \
+doifelseallmodes doifallmodeselse doifnotallmodes startenvironment stopenvironment \
+environment startcomponent stopcomponent component startproduct \
+stopproduct product startproject stopproject project \
+starttext stoptext startnotext stopnotext startdocument \
+stopdocument documentvariable unexpandeddocumentvariable setupdocument presetdocument \
+doifelsedocumentvariable doifdocumentvariableelse doifdocumentvariable doifnotdocumentvariable startmodule \
+stopmodule usemodule usetexmodule useluamodule setupmodule \
+currentmoduleparameter moduleparameter everystarttext everystoptext startTEXpage \
+stopTEXpage enablemode disablemode preventmode definemode \
+globalenablemode globaldisablemode globalpreventmode pushmode popmode \
+typescriptone typescripttwo typescriptthree mathsizesuffix mathordinarycode \
+mathordcode mathoperatorcode mathopcode mathbinarycode mathbincode \
+mathrelationcode mathrelcode mathopencode mathclosecode mathpunctuationcode \
+mathpunctcode mathovercode mathundercode mathinnercode mathradicalcode \
+mathfractioncode mathmiddlecode mathaccentcode mathfencedcode mathghostcode \
+mathvariablecode mathactivecode mathvcentercode mathconstructcode mathwrappedcode \
+mathbegincode mathendcode mathexplicitcode mathdivisioncode mathfactorialcode \
+mathdimensioncode mathexperimentalcode mathtextpunctuationcode mathimaginarycode mathdifferentialcode \
+mathexponentialcode mathellipsiscode mathfunctioncode mathdigitcode mathalphacode \
+mathboxcode mathchoicecode mathnothingcode mathlimopcode mathnolopcode \
+mathunsetcode mathunspacedcode mathallcode mathfakecode mathunarycode \
+mathmaybeordinarycode mathmayberelationcode mathmaybebinarycode mathnumbergroupcode constantnumber \
+constantnumberargument constantdimen constantdimenargument constantemptyargument luastringsep \
+!!bs !!es lefttorightmark righttoleftmark lrm \
+rlm bidilre bidirle bidipop bidilro \
+bidirlo breakablethinspace nobreakspace nonbreakablespace narrownobreakspace \
+zerowidthnobreakspace ideographicspace ideographichalffillspace twoperemspace threeperemspace \
+fourperemspace fiveperemspace sixperemspace figurespace punctuationspace \
+hairspace enquad emquad zerowidthspace zerowidthnonjoiner \
+zerowidthjoiner zwnj zwj optionalspace asciispacechar \
+softhyphen autoinsertedspace Ux eUx Umathaccents \
+parfillleftskip parfillrightskip startlmtxmode stoplmtxmode startmkivmode \
+stopmkivmode wildcardsymbol normalhyphenationcode automatichyphenationcode explicithyphenationcode \
+syllablehyphenationcode uppercasehyphenationcode collapsehyphenationcode compoundhyphenationcode strictstarthyphenationcode \
+strictendhyphenationcode automaticpenaltyhyphenationcode explicitpenaltyhyphenationcode permitgluehyphenationcode permitallhyphenationcode \
+permitmathreplacehyphenationcode forcecheckhyphenationcode lazyligatureshyphenationcode forcehandlerhyphenationcode feedbackcompoundhyphenationcode \
+ignoreboundshyphenationcode partialhyphenationcode completehyphenationcode normalizelinenormalizecode parindentskipnormalizecode \
+swaphangindentnormalizecode swapparsshapenormalizecode breakafterdirnormalizecode removemarginkernsnormalizecode clipwidthnormalizecode \
+flattendiscretionariesnormalizecode discardzerotabskipsnormalizecode flattenhleadersnormalizecode normalizeparnormalizeparcode flattenvleadersnormalizeparcode \
+nopreslackclassoptioncode nopostslackclassoptioncode lefttopkernclassoptioncode righttopkernclassoptioncode leftbottomkernclassoptioncode \
+rightbottomkernclassoptioncode lookaheadforendclassoptioncode noitaliccorrectionclassoptioncode defaultmathclassoptions checkligatureclassoptioncode \
+checkitaliccorrectionclassoptioncode checkkernpairclassoptioncode flattenclassoptioncode omitpenaltyclassoptioncode unpackclassoptioncode \
+raiseprimeclassoptioncode carryoverlefttopkernclassoptioncode carryoverleftbottomkernclassoptioncode carryoverrighttopkernclassoptioncode carryoverrightbottomkernclassoptioncode \
+preferdelimiterdimensionsclassoptioncode autoinjectclassoptioncode removeitaliccorrectionclassoptioncode operatoritaliccorrectionclassoptioncode noligaturingglyphoptioncode \
+nokerningglyphoptioncode noleftligatureglyphoptioncode noleftkernglyphoptioncode norightligatureglyphoptioncode norightkernglyphoptioncode \
+noexpansionglyphoptioncode noprotrusionglyphoptioncode noitaliccorrectionglyphoptioncode nokerningcode noligaturingcode \
+frozenflagcode tolerantflagcode protectedflagcode primitiveflagcode permanentflagcode \
+noalignedflagcode immutableflagcode mutableflagcode globalflagcode overloadedflagcode \
+immediateflagcode conditionalflagcode valueflagcode instanceflagcode ordmathflattencode \
+binmathflattencode relmathflattencode punctmathflattencode innermathflattencode normalworddiscoptioncode \
+preworddiscoptioncode postworddiscoptioncode continueifinputfile continuewhenlmtxmode continuewhenmkivmode
keywordclass.context.helpers=\
startsetups stopsetups startxmlsetups stopxmlsetups \
@@ -134,210 +134,211 @@ pushsystemmode popsystemmode globalsetmode globalresetmode globalsetsystemmode \
globalresetsystemmode booleanmodevalue newcount newdimen newskip \
newmuskip newbox newtoks newread newwrite \
newmarks newinsert newattribute newif newlanguage \
-newfamily newfam newhelp then begcsname \
-autorule strippedcsname checkedstrippedcsname nofarguments firstargumentfalse \
-firstargumenttrue secondargumentfalse secondargumenttrue thirdargumentfalse thirdargumenttrue \
-fourthargumentfalse fourthargumenttrue fifthargumentfalse fifthargumenttrue sixthargumentfalse \
-sixthargumenttrue seventhargumentfalse seventhargumenttrue vkern hkern \
-vpenalty hpenalty doglobal dodoglobal redoglobal \
-resetglobal donothing untraceddonothing dontcomplain moreboxtracing \
-lessboxtracing noboxtracing forgetall donetrue donefalse \
-foundtrue foundfalse inlineordisplaymath indisplaymath forcedisplaymath \
-startforceddisplaymath stopforceddisplaymath startpickupmath stoppickupmath reqno \
-forceinlinemath mathortext thebox htdp unvoidbox \
-hfilll vfilll mathbox mathlimop mathnolop \
-mathnothing mathalpha currentcatcodetable defaultcatcodetable catcodetablename \
-newcatcodetable startcatcodetable stopcatcodetable startextendcatcodetable stopextendcatcodetable \
-pushcatcodetable popcatcodetable restorecatcodes setcatcodetable letcatcodecommand \
-defcatcodecommand uedcatcodecommand hglue vglue hfillneg \
-vfillneg hfilllneg vfilllneg ruledhss ruledhfil \
-ruledhfill ruledhfilll ruledhfilneg ruledhfillneg normalhfillneg \
-normalhfilllneg ruledvss ruledvfil ruledvfill ruledvfilll \
-ruledvfilneg ruledvfillneg normalvfillneg normalvfilllneg ruledhbox \
-ruledvbox ruledvtop ruledvcenter ruledmbox ruledhpack \
-ruledvpack ruledtpack ruledhskip ruledvskip ruledkern \
-ruledmskip ruledmkern ruledhglue ruledvglue normalhglue \
-normalvglue ruledpenalty filledhboxb filledhboxr filledhboxg \
-filledhboxc filledhboxm filledhboxy filledhboxk scratchstring \
-scratchstringone scratchstringtwo tempstring scratchcounter globalscratchcounter \
-privatescratchcounter scratchdimen globalscratchdimen privatescratchdimen scratchskip \
-globalscratchskip privatescratchskip scratchmuskip globalscratchmuskip privatescratchmuskip \
-scratchtoks globalscratchtoks privatescratchtoks scratchbox globalscratchbox \
-privatescratchbox scratchmacro scratchmacroone scratchmacrotwo scratchconditiontrue \
-scratchconditionfalse ifscratchcondition scratchconditiononetrue scratchconditiononefalse ifscratchconditionone \
-scratchconditiontwotrue scratchconditiontwofalse ifscratchconditiontwo globalscratchcounterone globalscratchcountertwo \
-globalscratchcounterthree groupedcommand groupedcommandcs triggergroupedcommand triggergroupedcommandcs \
-simplegroupedcommand simplegroupedcommandcs pickupgroupedcommand pickupgroupedcommandcs mathgroupedcommandcs \
-usedbaselineskip usedlineskip usedlineskiplimit availablehsize localhsize \
-setlocalhsize distributedhsize hsizefraction next nexttoken \
-nextbox dowithnextbox dowithnextboxcs dowithnextboxcontent dowithnextboxcontentcs \
-flushnextbox boxisempty boxtostring contentostring prerolltostring \
-givenwidth givenheight givendepth scangivendimensions scratchwidth \
-scratchheight scratchdepth scratchoffset scratchdistance scratchtotal \
-scratchitalic scratchhsize scratchvsize scratchxoffset scratchyoffset \
-scratchhoffset scratchvoffset scratchxposition scratchyposition scratchtopoffset \
-scratchbottomoffset scratchleftoffset scratchrightoffset scratchcounterone scratchcountertwo \
-scratchcounterthree scratchcounterfour scratchcounterfive scratchcountersix scratchdimenone \
-scratchdimentwo scratchdimenthree scratchdimenfour scratchdimenfive scratchdimensix \
-scratchskipone scratchskiptwo scratchskipthree scratchskipfour scratchskipfive \
-scratchskipsix scratchmuskipone scratchmuskiptwo scratchmuskipthree scratchmuskipfour \
-scratchmuskipfive scratchmuskipsix scratchtoksone scratchtokstwo scratchtoksthree \
-scratchtoksfour scratchtoksfive scratchtokssix scratchboxone scratchboxtwo \
-scratchboxthree scratchboxfour scratchboxfive scratchboxsix scratchnx \
-scratchny scratchmx scratchmy scratchunicode scratchmin \
-scratchmax scratchleftskip scratchrightskip scratchtopskip scratchbottomskip \
-doif doifnot doifelse firstinset doifinset \
-doifnotinset doifelseinset doifinsetelse doifelsenextchar doifnextcharelse \
-doifelsenextcharcs doifnextcharcselse doifelsenextoptional doifnextoptionalelse doifelsenextoptionalcs \
-doifnextoptionalcselse doifelsefastoptionalcheck doiffastoptionalcheckelse doifelsefastoptionalcheckcs doiffastoptionalcheckcselse \
-doifelsenextbgroup doifnextbgroupelse doifelsenextbgroupcs doifnextbgroupcselse doifelsenextparenthesis \
-doifnextparenthesiselse doifelseundefined doifundefinedelse doifelsedefined doifdefinedelse \
-doifundefined doifdefined doifelsevalue doifvalue doifnotvalue \
-doifnothing doifsomething doifelsenothing doifnothingelse doifelsesomething \
-doifsomethingelse doifvaluenothing doifvaluesomething doifelsevaluenothing doifvaluenothingelse \
-doifelsedimension doifdimensionelse doifelsenumber doifnumberelse doifnumber \
-doifnotnumber doifelsecommon doifcommonelse doifcommon doifnotcommon \
-doifinstring doifnotinstring doifelseinstring doifinstringelse doifelseassignment \
-doifassignmentelse docheckassignment doifelseassignmentcs doifassignmentelsecs validassignment \
-novalidassignment doiftext doifelsetext doiftextelse doifnottext \
-quitcondition truecondition falsecondition tracingall tracingnone \
-loggingall tracingcatcodes showluatokens aliasmacro removetoks \
-appendtoks prependtoks appendtotoks prependtotoks to \
-endgraf endpar reseteverypar finishpar empty \
-null space quad enspace emspace \
-charspace nbsp crlf obeyspaces obeylines \
-obeytabs obeypages obeyedspace obeyedline obeyedtab \
-obeyedpage normalspace naturalspace controlspace normalspaces \
-ignoretabs ignorelines ignorepages ignoreeofs setcontrolspaces \
-executeifdefined singleexpandafter doubleexpandafter tripleexpandafter dontleavehmode \
-removelastspace removeunwantedspaces keepunwantedspaces removepunctuation ignoreparskip \
-forcestrutdepth onlynonbreakablespace wait writestatus define \
-defineexpandable redefine setmeasure setemeasure setgmeasure \
-setxmeasure definemeasure freezemeasure measure measured \
-directmeasure setquantity setequantity setgquantity setxquantity \
-definequantity freezequantity quantity quantitied directquantity \
-installcorenamespace getvalue getuvalue setvalue setevalue \
-setgvalue setxvalue letvalue letgvalue resetvalue \
-undefinevalue ignorevalue setuvalue setuevalue setugvalue \
-setuxvalue globallet udef ugdef uedef \
-uxdef checked unique getparameters geteparameters \
-getgparameters getxparameters forgetparameters copyparameters getdummyparameters \
-dummyparameter directdummyparameter setdummyparameter letdummyparameter setexpandeddummyparameter \
-resetdummyparameter usedummystyleandcolor usedummystyleparameter usedummycolorparameter processcommalist \
-processcommacommand quitcommalist quitprevcommalist processaction processallactions \
-processfirstactioninset processallactionsinset unexpanded expanded startexpanded \
-stopexpanded protect unprotect firstofoneargument firstoftwoarguments \
-secondoftwoarguments firstofthreearguments secondofthreearguments thirdofthreearguments firstoffourarguments \
-secondoffourarguments thirdoffourarguments fourthoffourarguments firstoffivearguments secondoffivearguments \
-thirdoffivearguments fourthoffivearguments fifthoffivearguments firstofsixarguments secondofsixarguments \
-thirdofsixarguments fourthofsixarguments fifthofsixarguments sixthofsixarguments firstofoneunexpanded \
-firstoftwounexpanded secondoftwounexpanded firstofthreeunexpanded secondofthreeunexpanded thirdofthreeunexpanded \
-gobbleoneargument gobbletwoarguments gobblethreearguments gobblefourarguments gobblefivearguments \
-gobblesixarguments gobblesevenarguments gobbleeightarguments gobbleninearguments gobbletenarguments \
-gobbleoneoptional gobbletwooptionals gobblethreeoptionals gobblefouroptionals gobblefiveoptionals \
-dorecurse doloop exitloop dostepwiserecurse recurselevel \
-recursedepth dofastloopcs fastloopindex fastloopfinal dowith \
-doloopovermatch doloopovermatched doloopoverlist newconstant setnewconstant \
-setconstant setconstantvalue newconditional settrue setfalse \
-settruevalue setfalsevalue setconditional newmacro setnewmacro \
-newfraction newsignal newboundary dosingleempty dodoubleempty \
-dotripleempty doquadrupleempty doquintupleempty dosixtupleempty doseventupleempty \
-dosingleargument dodoubleargument dotripleargument doquadrupleargument doquintupleargument \
-dosixtupleargument doseventupleargument dosinglegroupempty dodoublegroupempty dotriplegroupempty \
-doquadruplegroupempty doquintuplegroupempty permitspacesbetweengroups dontpermitspacesbetweengroups nopdfcompression \
-maximumpdfcompression normalpdfcompression onlypdfobjectcompression nopdfobjectcompression modulonumber \
-dividenumber getfirstcharacter doifelsefirstchar doiffirstcharelse mathclassvalue \
-startnointerference stopnointerference twodigits threedigits leftorright \
-offinterlineskip oninterlineskip nointerlineskip strut halfstrut \
-quarterstrut depthstrut halflinestrut noheightstrut setstrut \
-strutbox strutht strutdp strutwd struthtdp \
-strutgap begstrut endstrut lineheight leftboundary \
-rightboundary signalcharacter aligncontentleft aligncontentmiddle aligncontentright \
-shiftbox vpackbox hpackbox vpackedbox hpackedbox \
-ordordspacing ordopspacing ordbinspacing ordrelspacing ordopenspacing \
-ordclosespacing ordpunctspacing ordinnerspacing ordfracspacing ordradspacing \
-ordmiddlespacing ordaccentspacing opordspacing opopspacing opbinspacing \
-oprelspacing opopenspacing opclosespacing oppunctspacing opinnerspacing \
-opfracspacing opradspacing opmiddlespacing opaccentspacing binordspacing \
-binopspacing binbinspacing binrelspacing binopenspacing binclosespacing \
-binpunctspacing bininnerspacing binfracspacing binradspacing binmiddlespacing \
-binaccentspacing relordspacing relopspacing relbinspacing relrelspacing \
-relopenspacing relclosespacing relpunctspacing relinnerspacing relfracspacing \
-relradspacing relmiddlespacing relaccentspacing openordspacing openopspacing \
-openbinspacing openrelspacing openopenspacing openclosespacing openpunctspacing \
-openinnerspacing openfracspacing openradspacing openmiddlespacing openaccentspacing \
-closeordspacing closeopspacing closebinspacing closerelspacing closeopenspacing \
-closeclosespacing closepunctspacing closeinnerspacing closefracspacing closeradspacing \
-closemiddlespacing closeaccentspacing punctordspacing punctopspacing punctbinspacing \
-punctrelspacing punctopenspacing punctclosespacing punctpunctspacing punctinnerspacing \
-punctfracspacing punctradspacing punctmiddlespacing punctaccentspacing innerordspacing \
-inneropspacing innerbinspacing innerrelspacing inneropenspacing innerclosespacing \
-innerpunctspacing innerinnerspacing innerfracspacing innerradspacing innermiddlespacing \
-inneraccentspacing fracordspacing fracopspacing fracbinspacing fracrelspacing \
-fracopenspacing fracclosespacing fracpunctspacing fracinnerspacing fracfracspacing \
-fracradspacing fracmiddlespacing fracaccentspacing radordspacing radopspacing \
-radbinspacing radrelspacing radopenspacing radclosespacing radpunctspacing \
-radinnerspacing radfracspacing radradspacing radmiddlespacing radaccentspacing \
-middleordspacing middleopspacing middlebinspacing middlerelspacing middleopenspacing \
-middleclosespacing middlepunctspacing middleinnerspacing middlefracspacing middleradspacing \
-middlemiddlespacing middleaccentspacing accentordspacing accentopspacing accentbinspacing \
-accentrelspacing accentopenspacing accentclosespacing accentpunctspacing accentinnerspacing \
-accentfracspacing accentradspacing accentmiddlespacing accentaccentspacing normalreqno \
-startimath stopimath normalstartimath normalstopimath startdmath \
-stopdmath normalstartdmath normalstopdmath normalsuperscript normalsubscript \
-normalnosuperscript normalnosubscript normalprimescript superscript subscript \
-nosuperscript nosubscript primescript superprescript subprescript \
-nosuperprescript nosubsprecript uncramped cramped mathstyletrigger \
-triggermathstyle triggeredmathstyle mathstylefont mathsmallstylefont mathstyleface \
-mathsmallstyleface mathstylecommand mathpalette mathstylehbox mathstylevbox \
-mathstylevcenter mathstylevcenteredhbox mathstylevcenteredvbox mathtext setmathsmalltextbox \
-setmathtextbox pushmathstyle popmathstyle triggerdisplaystyle triggertextstyle \
-triggerscriptstyle triggerscriptscriptstyle triggeruncrampedstyle triggercrampedstyle triggersmallstyle \
-triggeruncrampedsmallstyle triggercrampedsmallstyle triggerbigstyle triggeruncrampedbigstyle triggercrampedbigstyle \
-luaexpr expelsedoif expdoif expdoifnot expdoifelsecommon \
-expdoifcommonelse expdoifelseinset expdoifinsetelse ctxdirectlua ctxlatelua \
-ctxsprint ctxwrite ctxcommand ctxdirectcommand ctxlatecommand \
-ctxreport ctxlua luacode lateluacode directluacode \
-registerctxluafile ctxloadluafile luaversion luamajorversion luaminorversion \
-ctxluacode luaconditional luaexpanded ctxluamatch startluaparameterset \
-stopluaparameterset luaparameterset definenamedlua obeylualines obeyluatokens \
-startluacode stopluacode startlua stoplua startctxfunction \
-stopctxfunction ctxfunction startctxfunctiondefinition stopctxfunctiondefinition installctxfunction \
-installprotectedctxfunction installprotectedctxscanner installctxscanner resetctxscanner cldprocessfile \
-cldloadfile cldloadviafile cldcontext cldcommand carryoverpar \
-freezeparagraphproperties defrostparagraphproperties setparagraphfreezing forgetparagraphfreezing updateparagraphproperties \
-updateparagraphpenalties updateparagraphdemerits updateparagraphshapes updateparagraphlines lastlinewidth \
-assumelongusagecs Umathbottomaccent Umathtopaccent Umathbotaccent righttolefthbox \
-lefttorighthbox righttoleftvbox lefttorightvbox righttoleftvtop lefttorightvtop \
-rtlhbox ltrhbox rtlvbox ltrvbox rtlvtop \
-ltrvtop autodirhbox autodirvbox autodirvtop leftorrighthbox \
-leftorrightvbox leftorrightvtop lefttoright righttoleft checkedlefttoright \
-checkedrighttoleft synchronizelayoutdirection synchronizedisplaydirection synchronizeinlinedirection dirlre \
-dirrle dirlro dirrlo rtltext ltrtext \
-lesshyphens morehyphens nohyphens dohyphens dohyphencollapsing \
-nohyphencollapsing compounddiscretionary Ucheckedstartdisplaymath Ucheckedstopdisplaymath break \
-nobreak allowbreak goodbreak nospace nospacing \
-dospacing naturalhbox naturalvbox naturalvtop naturalhpack \
-naturalvpack naturaltpack reversehbox reversevbox reversevtop \
-reversehpack reversevpack reversetpack hcontainer vcontainer \
-tcontainer frule compoundhyphenpenalty start stop \
-unsupportedcs openout closeout write openin \
-closein read readline readfromterminal boxlines \
-boxline setboxline copyboxline boxlinewd boxlineht \
-boxlinedp boxlinenw boxlinenh boxlinend boxlinels \
-boxliners boxlinelh boxlinerh boxlinelp boxlinerp \
-boxlinein boxrangewd boxrangeht boxrangedp bitwiseset \
-bitwiseand bitwiseor bitwisexor bitwisenot bitwisenil \
-ifbitwiseand bitwise bitwiseshift bitwiseflip textdir \
-linedir pardir boxdir prelistbox postlistbox \
-prelistcopy postlistcopy setprelistbox setpostlistbox noligaturing \
-nokerning noexpansion noprotrusion noleftkerning noleftligaturing \
-norightkerning norightligaturing noitaliccorrection futureletnexttoken defbackslashbreak \
-letbackslashbreak pushoverloadmode popoverloadmode pushrunstate poprunstate \
-suggestedalias showboxhere discoptioncodestring flagcodestring frozenparcodestring \
-glyphoptioncodestring groupcodestring hyphenationcodestring mathcontrolcodestring mathflattencodestring \
-normalizecodestring parcontextcodestring newlocalcount newlocaldimen newlocalskip \
-newlocalmuskip newlocaltoks newlocalbox newlocalwrite newlocalread \
-setnewlocalcount setnewlocaldimen setnewlocalskip setnewlocalmuskip setnewlocaltoks \
-setnewlocalbox ifexpression
+newfamily newfam newhelp newinteger newdimension \
+newgluespec newmugluespec aliasinteger aliasdimension then \
+begcsname autorule strippedcsname checkedstrippedcsname nofarguments \
+firstargumentfalse firstargumenttrue secondargumentfalse secondargumenttrue thirdargumentfalse \
+thirdargumenttrue fourthargumentfalse fourthargumenttrue fifthargumentfalse fifthargumenttrue \
+sixthargumentfalse sixthargumenttrue seventhargumentfalse seventhargumenttrue vkern \
+hkern vpenalty hpenalty doglobal dodoglobal \
+redoglobal resetglobal donothing untraceddonothing dontcomplain \
+moreboxtracing lessboxtracing noboxtracing forgetall donetrue \
+donefalse foundtrue foundfalse inlineordisplaymath indisplaymath \
+forcedisplaymath startforceddisplaymath stopforceddisplaymath startpickupmath stoppickupmath \
+reqno forceinlinemath mathortext thebox htdp \
+unvoidbox hfilll vfilll mathbox mathlimop \
+mathnolop mathnothing mathalpha currentcatcodetable defaultcatcodetable \
+catcodetablename newcatcodetable startcatcodetable stopcatcodetable startextendcatcodetable \
+stopextendcatcodetable pushcatcodetable popcatcodetable restorecatcodes setcatcodetable \
+letcatcodecommand defcatcodecommand uedcatcodecommand hglue vglue \
+hfillneg vfillneg hfilllneg vfilllneg ruledhss \
+ruledhfil ruledhfill ruledhfilll ruledhfilneg ruledhfillneg \
+normalhfillneg normalhfilllneg ruledvss ruledvfil ruledvfill \
+ruledvfilll ruledvfilneg ruledvfillneg normalvfillneg normalvfilllneg \
+ruledhbox ruledvbox ruledvtop ruleddbox ruledvcenter \
+ruledmbox ruledhpack ruledvpack ruledtpack ruleddpack \
+ruledhskip ruledvskip ruledkern ruledmskip ruledmkern \
+ruledhglue ruledvglue normalhglue normalvglue ruledpenalty \
+filledhboxb filledhboxr filledhboxg filledhboxc filledhboxm \
+filledhboxy filledhboxk scratchstring scratchstringone scratchstringtwo \
+tempstring scratchcounter globalscratchcounter privatescratchcounter scratchdimen \
+globalscratchdimen privatescratchdimen scratchskip globalscratchskip privatescratchskip \
+scratchmuskip globalscratchmuskip privatescratchmuskip scratchtoks globalscratchtoks \
+privatescratchtoks scratchbox globalscratchbox privatescratchbox scratchmacro \
+scratchmacroone scratchmacrotwo scratchconditiontrue scratchconditionfalse ifscratchcondition \
+scratchconditiononetrue scratchconditiononefalse ifscratchconditionone scratchconditiontwotrue scratchconditiontwofalse \
+ifscratchconditiontwo globalscratchcounterone globalscratchcountertwo globalscratchcounterthree groupedcommand \
+groupedcommandcs triggergroupedcommand triggergroupedcommandcs simplegroupedcommand simplegroupedcommandcs \
+pickupgroupedcommand pickupgroupedcommandcs mathgroupedcommandcs usedbaselineskip usedlineskip \
+usedlineskiplimit availablehsize localhsize setlocalhsize distributedhsize \
+hsizefraction next nexttoken nextbox dowithnextbox \
+dowithnextboxcs dowithnextboxcontent dowithnextboxcontentcs flushnextbox boxisempty \
+boxtostring contentostring prerolltostring givenwidth givenheight \
+givendepth scangivendimensions scratchwidth scratchheight scratchdepth \
+scratchoffset scratchdistance scratchtotal scratchitalic scratchhsize \
+scratchvsize scratchxoffset scratchyoffset scratchhoffset scratchvoffset \
+scratchxposition scratchyposition scratchtopoffset scratchbottomoffset scratchleftoffset \
+scratchrightoffset scratchcounterone scratchcountertwo scratchcounterthree scratchcounterfour \
+scratchcounterfive scratchcountersix scratchdimenone scratchdimentwo scratchdimenthree \
+scratchdimenfour scratchdimenfive scratchdimensix scratchskipone scratchskiptwo \
+scratchskipthree scratchskipfour scratchskipfive scratchskipsix scratchmuskipone \
+scratchmuskiptwo scratchmuskipthree scratchmuskipfour scratchmuskipfive scratchmuskipsix \
+scratchtoksone scratchtokstwo scratchtoksthree scratchtoksfour scratchtoksfive \
+scratchtokssix scratchboxone scratchboxtwo scratchboxthree scratchboxfour \
+scratchboxfive scratchboxsix scratchnx scratchny scratchmx \
+scratchmy scratchunicode scratchmin scratchmax scratchleftskip \
+scratchrightskip scratchtopskip scratchbottomskip doif doifnot \
+doifelse firstinset doifinset doifnotinset doifelseinset \
+doifinsetelse doifelsenextchar doifnextcharelse doifelsenextcharcs doifnextcharcselse \
+doifelsenextoptional doifnextoptionalelse doifelsenextoptionalcs doifnextoptionalcselse doifelsefastoptionalcheck \
+doiffastoptionalcheckelse doifelsefastoptionalcheckcs doiffastoptionalcheckcselse doifelsenextbgroup doifnextbgroupelse \
+doifelsenextbgroupcs doifnextbgroupcselse doifelsenextparenthesis doifnextparenthesiselse doifelseundefined \
+doifundefinedelse doifelsedefined doifdefinedelse doifundefined doifdefined \
+doifelsevalue doifvalue doifnotvalue doifnothing doifsomething \
+doifelsenothing doifnothingelse doifelsesomething doifsomethingelse doifvaluenothing \
+doifvaluesomething doifelsevaluenothing doifvaluenothingelse doifelsedimension doifdimensionelse \
+doifelsenumber doifnumberelse doifnumber doifnotnumber doifelsecommon \
+doifcommonelse doifcommon doifnotcommon doifinstring doifnotinstring \
+doifelseinstring doifinstringelse doifelseassignment doifassignmentelse docheckassignment \
+doifelseassignmentcs doifassignmentelsecs validassignment novalidassignment doiftext \
+doifelsetext doiftextelse doifnottext quitcondition truecondition \
+falsecondition tracingall tracingnone loggingall tracingcatcodes \
+showluatokens aliasmacro removetoks appendtoks prependtoks \
+appendtotoks prependtotoks to endgraf endpar \
+reseteverypar finishpar empty null space \
+quad enspace emspace charspace nbsp \
+crlf obeyspaces obeylines obeytabs obeypages \
+obeyedspace obeyedline obeyedtab obeyedpage normalspace \
+naturalspace controlspace normalspaces ignoretabs ignorelines \
+ignorepages ignoreeofs setcontrolspaces executeifdefined singleexpandafter \
+doubleexpandafter tripleexpandafter dontleavehmode removelastspace removeunwantedspaces \
+keepunwantedspaces removepunctuation ignoreparskip forcestrutdepth onlynonbreakablespace \
+wait writestatus define defineexpandable redefine \
+setmeasure setemeasure setgmeasure setxmeasure definemeasure \
+freezemeasure measure measured directmeasure setquantity \
+setequantity setgquantity setxquantity definequantity freezequantity \
+quantity quantitied directquantity installcorenamespace getvalue \
+getuvalue setvalue setevalue setgvalue setxvalue \
+letvalue letgvalue resetvalue undefinevalue ignorevalue \
+setuvalue setuevalue setugvalue setuxvalue globallet \
+udef ugdef uedef uxdef checked \
+unique getparameters geteparameters getgparameters getxparameters \
+forgetparameters copyparameters getdummyparameters dummyparameter directdummyparameter \
+setdummyparameter letdummyparameter setexpandeddummyparameter resetdummyparameter usedummystyleandcolor \
+usedummystyleparameter usedummycolorparameter processcommalist processcommacommand quitcommalist \
+quitprevcommalist processaction processallactions processfirstactioninset processallactionsinset \
+unexpanded expanded startexpanded stopexpanded protect \
+unprotect firstofoneargument firstoftwoarguments secondoftwoarguments firstofthreearguments \
+secondofthreearguments thirdofthreearguments firstoffourarguments secondoffourarguments thirdoffourarguments \
+fourthoffourarguments firstoffivearguments secondoffivearguments thirdoffivearguments fourthoffivearguments \
+fifthoffivearguments firstofsixarguments secondofsixarguments thirdofsixarguments fourthofsixarguments \
+fifthofsixarguments sixthofsixarguments firstofoneunexpanded firstoftwounexpanded secondoftwounexpanded \
+firstofthreeunexpanded secondofthreeunexpanded thirdofthreeunexpanded gobbleoneargument gobbletwoarguments \
+gobblethreearguments gobblefourarguments gobblefivearguments gobblesixarguments gobblesevenarguments \
+gobbleeightarguments gobbleninearguments gobbletenarguments gobbleoneoptional gobbletwooptionals \
+gobblethreeoptionals gobblefouroptionals gobblefiveoptionals dorecurse doloop \
+exitloop dostepwiserecurse recurselevel recursedepth dofastloopcs \
+fastloopindex fastloopfinal dowith doloopovermatch doloopovermatched \
+doloopoverlist newconstant setnewconstant setconstant setconstantvalue \
+newconditional settrue setfalse settruevalue setfalsevalue \
+setconditional newmacro setnewmacro newfraction newsignal \
+newboundary dosingleempty dodoubleempty dotripleempty doquadrupleempty \
+doquintupleempty dosixtupleempty doseventupleempty dosingleargument dodoubleargument \
+dotripleargument doquadrupleargument doquintupleargument dosixtupleargument doseventupleargument \
+dosinglegroupempty dodoublegroupempty dotriplegroupempty doquadruplegroupempty doquintuplegroupempty \
+permitspacesbetweengroups dontpermitspacesbetweengroups nopdfcompression maximumpdfcompression normalpdfcompression \
+onlypdfobjectcompression nopdfobjectcompression modulonumber dividenumber getfirstcharacter \
+doifelsefirstchar doiffirstcharelse mathclassvalue startnointerference stopnointerference \
+twodigits threedigits leftorright offinterlineskip oninterlineskip \
+nointerlineskip strut halfstrut quarterstrut depthstrut \
+halflinestrut noheightstrut setstrut strutbox strutht \
+strutdp strutwd struthtdp strutgap begstrut \
+endstrut lineheight leftboundary rightboundary signalcharacter \
+aligncontentleft aligncontentmiddle aligncontentright shiftbox vpackbox \
+hpackbox vpackedbox hpackedbox ordordspacing ordopspacing \
+ordbinspacing ordrelspacing ordopenspacing ordclosespacing ordpunctspacing \
+ordinnerspacing ordfracspacing ordradspacing ordmiddlespacing ordaccentspacing \
+opordspacing opopspacing opbinspacing oprelspacing opopenspacing \
+opclosespacing oppunctspacing opinnerspacing opfracspacing opradspacing \
+opmiddlespacing opaccentspacing binordspacing binopspacing binbinspacing \
+binrelspacing binopenspacing binclosespacing binpunctspacing bininnerspacing \
+binfracspacing binradspacing binmiddlespacing binaccentspacing relordspacing \
+relopspacing relbinspacing relrelspacing relopenspacing relclosespacing \
+relpunctspacing relinnerspacing relfracspacing relradspacing relmiddlespacing \
+relaccentspacing openordspacing openopspacing openbinspacing openrelspacing \
+openopenspacing openclosespacing openpunctspacing openinnerspacing openfracspacing \
+openradspacing openmiddlespacing openaccentspacing closeordspacing closeopspacing \
+closebinspacing closerelspacing closeopenspacing closeclosespacing closepunctspacing \
+closeinnerspacing closefracspacing closeradspacing closemiddlespacing closeaccentspacing \
+punctordspacing punctopspacing punctbinspacing punctrelspacing punctopenspacing \
+punctclosespacing punctpunctspacing punctinnerspacing punctfracspacing punctradspacing \
+punctmiddlespacing punctaccentspacing innerordspacing inneropspacing innerbinspacing \
+innerrelspacing inneropenspacing innerclosespacing innerpunctspacing innerinnerspacing \
+innerfracspacing innerradspacing innermiddlespacing inneraccentspacing fracordspacing \
+fracopspacing fracbinspacing fracrelspacing fracopenspacing fracclosespacing \
+fracpunctspacing fracinnerspacing fracfracspacing fracradspacing fracmiddlespacing \
+fracaccentspacing radordspacing radopspacing radbinspacing radrelspacing \
+radopenspacing radclosespacing radpunctspacing radinnerspacing radfracspacing \
+radradspacing radmiddlespacing radaccentspacing middleordspacing middleopspacing \
+middlebinspacing middlerelspacing middleopenspacing middleclosespacing middlepunctspacing \
+middleinnerspacing middlefracspacing middleradspacing middlemiddlespacing middleaccentspacing \
+accentordspacing accentopspacing accentbinspacing accentrelspacing accentopenspacing \
+accentclosespacing accentpunctspacing accentinnerspacing accentfracspacing accentradspacing \
+accentmiddlespacing accentaccentspacing normalreqno startimath stopimath \
+normalstartimath normalstopimath startdmath stopdmath normalstartdmath \
+normalstopdmath normalsuperscript normalsubscript normalnosuperscript normalnosubscript \
+normalprimescript superscript subscript nosuperscript nosubscript \
+primescript superprescript subprescript nosuperprescript nosubsprecript \
+uncramped cramped mathstyletrigger triggermathstyle triggeredmathstyle \
+mathstylefont mathsmallstylefont mathstyleface mathsmallstyleface mathstylecommand \
+mathpalette mathstylehbox mathstylevbox mathstylevcenter mathstylevcenteredhbox \
+mathstylevcenteredvbox mathtext setmathsmalltextbox setmathtextbox pushmathstyle \
+popmathstyle triggerdisplaystyle triggertextstyle triggerscriptstyle triggerscriptscriptstyle \
+triggeruncrampedstyle triggercrampedstyle triggersmallstyle triggeruncrampedsmallstyle triggercrampedsmallstyle \
+triggerbigstyle triggeruncrampedbigstyle triggercrampedbigstyle luaexpr expelsedoif \
+expdoif expdoifnot expdoifelsecommon expdoifcommonelse expdoifelseinset \
+expdoifinsetelse ctxdirectlua ctxlatelua ctxsprint ctxwrite \
+ctxcommand ctxdirectcommand ctxlatecommand ctxreport ctxlua \
+luacode lateluacode directluacode registerctxluafile ctxloadluafile \
+luaversion luamajorversion luaminorversion ctxluacode luaconditional \
+luaexpanded ctxluamatch startluaparameterset stopluaparameterset luaparameterset \
+definenamedlua obeylualines obeyluatokens startluacode stopluacode \
+startlua stoplua startctxfunction stopctxfunction ctxfunction \
+startctxfunctiondefinition stopctxfunctiondefinition installctxfunction installprotectedctxfunction installprotectedctxscanner \
+installctxscanner resetctxscanner cldprocessfile cldloadfile cldloadviafile \
+cldcontext cldcommand carryoverpar freezeparagraphproperties defrostparagraphproperties \
+setparagraphfreezing forgetparagraphfreezing updateparagraphproperties updateparagraphpenalties updateparagraphdemerits \
+updateparagraphshapes updateparagraphlines lastlinewidth assumelongusagecs Umathbottomaccent \
+Umathtopaccent Umathbotaccent righttolefthbox lefttorighthbox righttoleftvbox \
+lefttorightvbox righttoleftvtop lefttorightvtop rtlhbox ltrhbox \
+rtlvbox ltrvbox rtlvtop ltrvtop autodirhbox \
+autodirvbox autodirvtop leftorrighthbox leftorrightvbox leftorrightvtop \
+lefttoright righttoleft checkedlefttoright checkedrighttoleft synchronizelayoutdirection \
+synchronizedisplaydirection synchronizeinlinedirection dirlre dirrle dirlro \
+dirrlo rtltext ltrtext lesshyphens morehyphens \
+nohyphens dohyphens dohyphencollapsing nohyphencollapsing compounddiscretionary \
+Ucheckedstartdisplaymath Ucheckedstopdisplaymath break nobreak allowbreak \
+goodbreak nospace nospacing dospacing naturalhbox \
+naturalvbox naturalvtop naturalhpack naturalvpack naturaltpack \
+reversehbox reversevbox reversevtop reversehpack reversevpack \
+reversetpack hcontainer vcontainer tcontainer frule \
+compoundhyphenpenalty start stop unsupportedcs openout \
+closeout write openin closein read \
+readline readfromterminal boxlines boxline setboxline \
+copyboxline boxlinewd boxlineht boxlinedp boxlinenw \
+boxlinenh boxlinend boxlinels boxliners boxlinelh \
+boxlinerh boxlinelp boxlinerp boxlinein boxrangewd \
+boxrangeht boxrangedp bitwiseset bitwiseand bitwiseor \
+bitwisexor bitwisenot bitwisenil ifbitwiseand bitwise \
+bitwiseshift bitwiseflip textdir linedir pardir \
+boxdir prelistbox postlistbox prelistcopy postlistcopy \
+setprelistbox setpostlistbox noligaturing nokerning noexpansion \
+noprotrusion noleftkerning noleftligaturing norightkerning norightligaturing \
+noitaliccorrection futureletnexttoken defbackslashbreak letbackslashbreak pushoverloadmode \
+popoverloadmode pushrunstate poprunstate suggestedalias showboxhere \
+discoptioncodestring flagcodestring frozenparcodestring glyphoptioncodestring groupcodestring \
+hyphenationcodestring mathcontrolcodestring mathflattencodestring normalizecodestring parcontextcodestring \
+newlocalcount newlocaldimen newlocalskip newlocalmuskip newlocaltoks \
+newlocalbox newlocalwrite newlocalread setnewlocalcount setnewlocaldimen \
+setnewlocalskip setnewlocalmuskip setnewlocaltoks setnewlocalbox ifexpression
diff --git a/context/data/scite/context/scite-context-data-tex.properties b/context/data/scite/context/scite-context-data-tex.properties
index 8d720a08e..8dec975b5 100644
--- a/context/data/scite/context/scite-context-data-tex.properties
+++ b/context/data/scite/context/scite-context-data-tex.properties
@@ -66,77 +66,77 @@ boxtotal boxxmove boxxoffset boxymove boxyoffset \
catcodetable cdef cdefcsname cfcode clearmarks \
constant copymathatomrule copymathparent copymathspacing crampeddisplaystyle \
crampedscriptscriptstyle crampedscriptstyle crampedtextstyle csactive csstring \
-currentloopiterator currentloopnesting currentmarks defcsname detokenized \
-dimensiondef dimexpression directlua edefcsname efcode \
-endlocalcontrol endmathgroup endsimplegroup enforced etoks \
-etoksapp etokspre everybeforepar everymathatom everytab \
-exceptionpenalty expand expandactive expandafterpars expandafterspaces \
-expandcstoken expanded expandedafter expandedloop expandtoken \
-explicitdiscretionary explicithyphenpenalty firstvalidlanguage flushmarks fontcharta \
-fontid fontmathcontrol fontspecdef fontspecid fontspecifiedname \
-fontspecifiedsize fontspecscale fontspecxscale fontspecyscale fonttextcontrol \
-formatname frozen futurecsname futuredef futureexpand \
-futureexpandis futureexpandisap gdefcsname gleaders glet \
-gletcsname glettonothing gluespecdef glyph glyphdatafield \
-glyphoptions glyphscale glyphscriptfield glyphscriptscale glyphscriptscriptscale \
-glyphstatefield glyphtextscale glyphxoffset glyphxscale glyphxscaled \
-glyphyoffset glyphyscale glyphyscaled gtoksapp gtokspre \
-hccode hjcode hmcode holdingmigrations hpack \
-hyphenationmin hyphenationmode ifabsdim ifabsnum ifarguments \
-ifboolean ifchkdim ifchknum ifcmpdim ifcmpnum \
-ifcondition ifcstok ifdimexpression ifdimval ifempty \
-ifflags ifhaschar ifhastok ifhastoks ifhasxtoks \
-ifincsname ifinsert ifmathparameter ifmathstyle ifnumexpression \
-ifnumval ifparameter ifparameters ifrelax iftok \
-ifzerodim ifzeronum ignorearguments ignorepars immediate \
-immutable indexofcharacter indexofregister inherited initcatcodetable \
-insertbox insertcopy insertdepth insertdistance insertheight \
-insertheights insertlimit insertmaxdepth insertmode insertmultiplier \
-insertpenalty insertprogress insertstorage insertstoring insertunbox \
-insertuncopy insertwidth instance integerdef lastarguments \
-lastatomclass lastboundary lastchkdim lastchknum lastleftclass \
-lastloopiterator lastnamedcs lastnodesubtype lastpageextra lastparcontext \
-lastrightclass leftmarginkern letcharcode letcsname letfrozen \
-letmathatomrule letmathparent letmathspacing letprotected lettonothing \
-linebreakcriterium linedirection localbrokenpenalty localcontrol localcontrolled \
-localcontrolledloop localinterlinepenalty localleftbox localleftboxbox localmiddlebox \
-localmiddleboxbox localrightbox localrightboxbox lpcode luabytecode \
-luabytecodecall luacopyinputnodes luadef luaescapestring luafunction \
-luafunctioncall luatexbanner luatexrevision luatexversion mathaccent \
-mathatom mathatomglue mathatomskip mathbackwardpenalties mathbeginclass \
-mathcheckfencesmode mathdictgroup mathdictproperties mathdirection mathdisplaymode \
-mathdisplayskipmode mathdoublescriptmode mathendclass matheqnogapstep mathfenced \
-mathfontcontrol mathforwardpenalties mathfrac mathghost mathgluemode \
-mathgroupingmode mathleftclass mathlimitsmode mathmainstyle mathmiddle \
-mathnolimitsmode mathpenaltiesmode mathrad mathrightclass mathrulesfam \
-mathrulesmode mathscale mathscriptsmode mathslackmode mathspacingmode \
-mathstackstyle mathstyle mathstylefontid mathsurroundmode mathsurroundskip \
-maththreshold meaningasis meaningfull meaningless mugluespecdef \
-mutable noaligned noatomruling noboundary nohrule \
-norelax normalizelinemode normalizeparmode nospaces novrule \
-numericscale numexpression orelse orphanpenalties orphanpenalty \
-orunless outputbox overloaded overloadmode overshoot \
-pageboundary pageextragoal pagevsize parametercount parametermark \
-parattribute pardirection permanent pettymuskip postexhyphenchar \
-posthyphenchar postinlinepenalty prebinoppenalty predisplaygapfactor preexhyphenchar \
-prehyphenchar preinlinepenalty prerelpenalty protrudechars protrusionboundary \
-pxdimen quitloop quitvmode resetmathspacing retokenized \
-rightmarginkern rpcode savecatcodetable scaledemwidth scaledexheight \
-scaledextraspace scaledfontdimen scaledinterwordshrink scaledinterwordspace scaledinterwordstretch \
-scaledmathstyle scaledslantperpoint scantextokens semiexpand semiexpanded \
-semiprotected setdefaultmathcodes setfontid setmathatomrule setmathdisplaypostpenalty \
-setmathdisplayprepenalty setmathignore setmathoptions setmathpostpenalty setmathprepenalty \
-setmathspacing shapingpenaltiesmode shapingpenalty snapshotpar srule \
-supmarkmode swapcsvalues tabsize textdirection thewithoutunit \
-tinymuskip todimension tohexadecimal tointeger tokenized \
-toksapp tokspre tolerant tomathstyle toscaled \
-tosparsedimension tosparsescaled tpack tracingadjusts tracingalignments \
-tracingexpressions tracingfonts tracingfullboxes tracinghyphenation tracinginserts \
-tracinglevels tracinglists tracingmarks tracingmath tracingnodes \
-tracingpenalties uleaders undent unexpandedloop unhpack \
-unletfrozen unletprotected untraced unvpack variablefam \
-vpack wordboundary wrapuppar xdefcsname xtoks \
-xtoksapp xtokspre
+currentloopiterator currentloopnesting currentmarks dbox defcsname \
+detokenized dimensiondef dimexpression directlua dpack \
+edefcsname efcode endlocalcontrol endmathgroup endsimplegroup \
+enforced etoks etoksapp etokspre everybeforepar \
+everymathatom everytab exceptionpenalty expand expandactive \
+expandafterpars expandafterspaces expandcstoken expanded expandedafter \
+expandedloop expandtoken explicitdiscretionary explicithyphenpenalty firstvalidlanguage \
+flushmarks fontcharta fontid fontmathcontrol fontspecdef \
+fontspecid fontspecifiedname fontspecifiedsize fontspecscale fontspecxscale \
+fontspecyscale fonttextcontrol formatname frozen futurecsname \
+futuredef futureexpand futureexpandis futureexpandisap gdefcsname \
+gleaders glet gletcsname glettonothing gluespecdef \
+glyph glyphdatafield glyphoptions glyphscale glyphscriptfield \
+glyphscriptscale glyphscriptscriptscale glyphstatefield glyphtextscale glyphxoffset \
+glyphxscale glyphxscaled glyphyoffset glyphyscale glyphyscaled \
+gtoksapp gtokspre hccode hjcode hmcode \
+holdingmigrations hpack hyphenationmin hyphenationmode ifabsdim \
+ifabsnum ifarguments ifboolean ifchkdim ifchknum \
+ifcmpdim ifcmpnum ifcondition ifcstok ifdimexpression \
+ifdimval ifempty ifflags ifhaschar ifhastok \
+ifhastoks ifhasxtoks ifincsname ifinsert ifmathparameter \
+ifmathstyle ifnumexpression ifnumval ifparameter ifparameters \
+ifrelax iftok ifzerodim ifzeronum ignorearguments \
+ignorepars immediate immutable indexofcharacter indexofregister \
+inherited initcatcodetable insertbox insertcopy insertdepth \
+insertdistance insertheight insertheights insertlimit insertmaxdepth \
+insertmode insertmultiplier insertpenalty insertprogress insertstorage \
+insertstoring insertunbox insertuncopy insertwidth instance \
+integerdef lastarguments lastatomclass lastboundary lastchkdim \
+lastchknum lastleftclass lastloopiterator lastnamedcs lastnodesubtype \
+lastpageextra lastparcontext lastrightclass leftmarginkern letcharcode \
+letcsname letfrozen letmathatomrule letmathparent letmathspacing \
+letprotected lettonothing linebreakcriterium linedirection localbrokenpenalty \
+localcontrol localcontrolled localcontrolledloop localinterlinepenalty localleftbox \
+localleftboxbox localmiddlebox localmiddleboxbox localrightbox localrightboxbox \
+lpcode luabytecode luabytecodecall luacopyinputnodes luadef \
+luaescapestring luafunction luafunctioncall luatexbanner luatexrevision \
+luatexversion mathaccent mathatom mathatomglue mathatomskip \
+mathbackwardpenalties mathbeginclass mathcheckfencesmode mathdictgroup mathdictproperties \
+mathdirection mathdisplaymode mathdisplayskipmode mathdoublescriptmode mathendclass \
+matheqnogapstep mathfenced mathfontcontrol mathforwardpenalties mathfrac \
+mathghost mathgluemode mathgroupingmode mathleftclass mathlimitsmode \
+mathmainstyle mathmiddle mathnolimitsmode mathpenaltiesmode mathrad \
+mathrightclass mathrulesfam mathrulesmode mathscale mathscriptsmode \
+mathslackmode mathspacingmode mathstackstyle mathstyle mathstylefontid \
+mathsurroundmode mathsurroundskip maththreshold meaningasis meaningfull \
+meaningless mugluespecdef mutable noaligned noatomruling \
+noboundary nohrule norelax normalizelinemode normalizeparmode \
+nospaces novrule numericscale numexpression orelse \
+orphanpenalties orphanpenalty orunless outputbox overloaded \
+overloadmode overshoot pageboundary pageextragoal pagevsize \
+parametercount parametermark parattribute pardirection permanent \
+pettymuskip postexhyphenchar posthyphenchar postinlinepenalty prebinoppenalty \
+predisplaygapfactor preexhyphenchar prehyphenchar preinlinepenalty prerelpenalty \
+protrudechars protrusionboundary pxdimen quitloop quitvmode \
+resetmathspacing retokenized rightmarginkern rpcode savecatcodetable \
+scaledemwidth scaledexheight scaledextraspace scaledfontdimen scaledinterwordshrink \
+scaledinterwordspace scaledinterwordstretch scaledmathstyle scaledslantperpoint scantextokens \
+semiexpand semiexpanded semiprotected setdefaultmathcodes setfontid \
+setmathatomrule setmathdisplaypostpenalty setmathdisplayprepenalty setmathignore setmathoptions \
+setmathpostpenalty setmathprepenalty setmathspacing shapingpenaltiesmode shapingpenalty \
+snapshotpar srule supmarkmode swapcsvalues tabsize \
+textdirection thewithoutunit tinymuskip todimension tohexadecimal \
+tointeger tokenized toksapp tokspre tolerant \
+tomathstyle toscaled tosparsedimension tosparsescaled tpack \
+tracingadjusts tracingalignments tracingexpressions tracingfonts tracingfullboxes \
+tracinghyphenation tracinginserts tracinglevels tracinglists tracingmarks \
+tracingmath tracingnodes tracingpenalties uleaders undent \
+unexpandedloop unhpack unletfrozen unletprotected untraced \
+unvpack variablefam vpack wordboundary wrapuppar \
+xdefcsname xtoks xtoksapp xtokspre
keywordclass.tex.omega=\
Omegaminorversion Omegarevision Omegaversion
@@ -169,68 +169,69 @@ pdfxformmargin pdfxformname pdfxformresources pdfximage
keywordclass.tex.tex=\
- / above \
abovedisplayshortskip abovedisplayskip abovewithdelims accent adjdemerits \
-advance afterassignment aftergroup atop atopwithdelims \
-badness baselineskip batchmode begingroup belowdisplayshortskip \
-belowdisplayskip binoppenalty botmark box boxmaxdepth \
-brokenpenalty catcode char chardef cleaders \
-clubpenalty copy count countdef cr \
-crcr csname day deadcycles def \
-defaulthyphenchar defaultskewchar delcode delimiter delimiterfactor \
-delimitershortfall dimen dimendef discretionary displayindent \
-displaylimits displaystyle displaywidowpenalty displaywidth divide \
-doublehyphendemerits dp dump edef else \
-emergencystretch end endcsname endgroup endinput \
-endlinechar eqno errhelp errmessage errorcontextlines \
-errorstopmode escapechar everycr everydisplay everyhbox \
-everyjob everymath everypar everyvbox exhyphenchar \
-exhyphenpenalty expandafter fam fi finalhyphendemerits \
-firstmark floatingpenalty font fontdimen fontname \
-futurelet gdef global globaldefs halign \
-hangafter hangindent hbadness hbox hfil \
-hfill hfilneg hfuzz holdinginserts hrule \
-hsize hskip hss ht hyphenation \
-hyphenchar hyphenpenalty if ifcase ifcat \
-ifdim iffalse ifhbox ifhmode ifinner \
-ifmmode ifnum ifodd iftrue ifvbox \
-ifvmode ifvoid ifx ignorespaces indent \
-input inputlineno insert insertpenalties interlinepenalty \
-jobname kern language lastbox lastkern \
-lastpenalty lastskip lccode leaders left \
-lefthyphenmin leftskip leqno let limits \
-linepenalty lineskip lineskiplimit long looseness \
-lower lowercase mark mathbin mathchar \
-mathchardef mathchoice mathclose mathcode mathinner \
-mathop mathopen mathord mathpunct mathrel \
-mathsurround maxdeadcycles maxdepth meaning medmuskip \
-message middle mkern month moveleft \
-moveright mskip multiply muskip muskipdef \
-newlinechar noalign noexpand noindent nolimits \
-nonscript nonstopmode nulldelimiterspace nullfont number \
-omit or outer output outputpenalty \
-over overfullrule overline overwithdelims pagedepth \
-pagefilllstretch pagefillstretch pagefilstretch pagegoal pageshrink \
-pagestretch pagetotal par parfillleftskip parfillskip \
-parindent parinitleftskip parinitrightskip parshape parskip \
-patterns pausing penalty postdisplaypenalty predisplaypenalty \
-predisplaysize pretolerance prevdepth prevgraf radical \
-raise relax relpenalty right righthyphenmin \
-rightskip romannumeral scriptfont scriptscriptfont scriptscriptstyle \
-scriptspace scriptstyle scrollmode setbox setlanguage \
-sfcode shipout show showbox showboxbreadth \
-showboxdepth showlists shownodedetails showthe skewchar \
-skip skipdef spacefactor spaceskip span \
-splitbotmark splitfirstmark splitmaxdepth splittopskip string \
-tabskip textfont textstyle the thickmuskip \
-thinmuskip time toks toksdef tolerance \
-topmark topskip tracingcommands tracinglostchars tracingmacros \
-tracingonline tracingoutput tracingpages tracingparagraphs tracingrestores \
-tracingstats uccode uchyph unboundary underline \
-unhbox unhcopy unkern unpenalty unskip \
-unvbox unvcopy uppercase vadjust valign \
-vbadness vbox vcenter vfil vfill \
-vfilneg vfuzz vrule vsize vskip \
-vsplit vss vtop wd widowpenalty \
-xdef xleaders xspaceskip year
+advance advanceby afterassignment aftergroup atop \
+atopwithdelims badness baselineskip batchmode begingroup \
+belowdisplayshortskip belowdisplayskip binoppenalty botmark box \
+boxmaxdepth brokenpenalty catcode char chardef \
+cleaders clubpenalty copy count countdef \
+cr crcr csname day deadcycles \
+def defaulthyphenchar defaultskewchar delcode delimiter \
+delimiterfactor delimitershortfall dimen dimendef discretionary \
+displayindent displaylimits displaystyle displaywidowpenalty displaywidth \
+divide divideby doublehyphendemerits dp dump \
+edef else emergencystretch end endcsname \
+endgroup endinput endlinechar eqno errhelp \
+errmessage errorcontextlines errorstopmode escapechar everycr \
+everydisplay everyhbox everyjob everymath everypar \
+everyvbox exhyphenchar exhyphenpenalty expandafter fam \
+fi finalhyphendemerits firstmark floatingpenalty font \
+fontdimen fontname futurelet gdef global \
+globaldefs halign hangafter hangindent hbadness \
+hbox hfil hfill hfilneg hfuzz \
+holdinginserts hrule hsize hskip hss \
+ht hyphenation hyphenchar hyphenpenalty if \
+ifcase ifcat ifdim iffalse ifhbox \
+ifhmode ifinner ifmmode ifnum ifodd \
+iftrue ifvbox ifvmode ifvoid ifx \
+ignorespaces indent input inputlineno insert \
+insertpenalties interlinepenalty jobname kern language \
+lastbox lastkern lastpenalty lastskip lccode \
+leaders left lefthyphenmin leftskip leqno \
+let limits linepenalty lineskip lineskiplimit \
+long looseness lower lowercase mark \
+mathbin mathchar mathchardef mathchoice mathclose \
+mathcode mathinner mathop mathopen mathord \
+mathpunct mathrel mathsurround maxdeadcycles maxdepth \
+meaning medmuskip message middle mkern \
+month moveleft moveright mskip multiply \
+multiplyby muskip muskipdef newlinechar noalign \
+noexpand noindent nolimits nonscript nonstopmode \
+nulldelimiterspace nullfont number omit or \
+outer output outputpenalty over overfullrule \
+overline overwithdelims pagedepth pagefilllstretch pagefillstretch \
+pagefilstretch pagegoal pageshrink pagestretch pagetotal \
+par parfillleftskip parfillskip parindent parinitleftskip \
+parinitrightskip parshape parskip patterns pausing \
+penalty postdisplaypenalty predisplaypenalty predisplaysize pretolerance \
+prevdepth prevgraf radical raise relax \
+relpenalty right righthyphenmin rightskip romannumeral \
+scriptfont scriptscriptfont scriptscriptstyle scriptspace scriptstyle \
+scrollmode setbox setlanguage sfcode shipout \
+show showbox showboxbreadth showboxdepth showlists \
+shownodedetails showthe skewchar skip skipdef \
+spacefactor spaceskip span splitbotmark splitfirstmark \
+splitmaxdepth splittopskip string tabskip textfont \
+textstyle the thickmuskip thinmuskip time \
+toks toksdef tolerance topmark topskip \
+tracingcommands tracinglostchars tracingmacros tracingonline tracingoutput \
+tracingpages tracingparagraphs tracingrestores tracingstats uccode \
+uchyph unboundary underline unhbox unhcopy \
+unkern unpenalty unskip unvbox unvcopy \
+uppercase vadjust valign vbadness vbox \
+vcenter vfil vfill vfilneg vfuzz \
+vrule vsize vskip vsplit vss \
+vtop wd widowpenalty xdef xleaders \
+xspaceskip year
keywordclass.tex.xetex=\
XeTeXversion
diff --git a/doc/context/sources/general/manuals/lowlevel/lowlevel-boxes.tex b/doc/context/sources/general/manuals/lowlevel/lowlevel-boxes.tex
index d5105fc8c..dd6c2f2d4 100644
--- a/doc/context/sources/general/manuals/lowlevel/lowlevel-boxes.tex
+++ b/doc/context/sources/general/manuals/lowlevel/lowlevel-boxes.tex
@@ -689,6 +689,38 @@ test\quad
\ruledhbox{\getbuffer}
\stoplinecorrection
+Where a \type {\vtop} has the baseline at the top, a \type {\vbox} has it at the
+bottom. In \LUAMETATEX\ we also have a \type {\dbox}, which is a \type {\vbox} with
+that behaves like a \type {\vtop} when it's appended to a vertical list: the height of
+the first box or rule determines the (base)line correction that gets applied. The following
+example demonstrates this:
+
+\startlinecorrection
+\startcombination [nx=3,ny=1,location=top]
+ {\vbox \bgroup \hsize .3\textwidth
+ \small\small \setupalign[tolerant,stretch] \dontcomplain
+ xxxxxxxxxxxxxxxx\par
+ \ruledvbox{\samplefile{tufte}}\par
+ xxxxxxxxxxxxxxxx\par
+ \egroup} {\type {\vbox}}
+ {\vbox \bgroup \hsize .3\textwidth
+ \small\small \setupalign[tolerant,stretch] \dontcomplain
+ xxxxxxxxxxxxxxxx\par
+ \ruledvtop{\samplefile{tufte}}\par
+ xxxxxxxxxxxxxxxx\par
+ \egroup} {\type {\vtop}}
+ {\vbox \bgroup \hsize .3\textwidth
+ \small\small \setupalign[tolerant,stretch] \dontcomplain
+ xxxxxxxxxxxxxxxx\par
+ \ruleddbox{\samplefile{tufte} }\par
+ xxxxxxxxxxxxxxxx\par
+ \egroup} {\type {\dbox}}
+\stopcombination
+\stoplinecorrection
+
+The \type {d} stands for \quote {dual} because we (sort of) have two baselines. The
+regular height and depth are those of a \type {\vbox}.
+
\stopsectionlevel
\stopdocument
diff --git a/doc/context/sources/general/manuals/lowlevel/lowlevel-registers.tex b/doc/context/sources/general/manuals/lowlevel/lowlevel-registers.tex
index 4dbee67cd..233a8c178 100644
--- a/doc/context/sources/general/manuals/lowlevel/lowlevel-registers.tex
+++ b/doc/context/sources/general/manuals/lowlevel/lowlevel-registers.tex
@@ -245,7 +245,40 @@ better use the proper more high level definers (not discussed here).
\startsectionlevel[title={\LUAMETATEX\ primitives}]
-{\em todo}
+The fact that scanning stops at a non-number or \type {\relax} can be sort of
+unpredictable which is why in \LUAMETATEX\ we also support the following variant:
+
+\starttyping[option=TEX]
+\scratchdimen\dimexpr 10pt + 3pt \relax
+\scratchdimen\dimexpr {10pt + 3pt}
+\stoptyping
+
+At the cost of one more token braces can be used as boundaries instead of the
+single \type {\relax} boundary.
+
+An important property of registers is that they can be accessed by a number. This
+has big consequences for the implementation: they are part of the big memory
+store and consume dedicated ranges. If we had only named access \TEX's memory
+layout could be a bit leaner. In principle we could make the number of registers
+smaller because any limit on the amount at some point can be an obstacle. It is
+for that reason that we also have name-only variants:
+
+\starttyping[option=TEX]
+\dimensiondef \MyDimenA 12pt
+\integerdef \MyIntegerA 12
+\gluespecdef \MyGlueA 12pt + 3pt minus 4pt
+\mugluespecdef\MyMuA 12mu + 3mu minus 4mu
+\stoptyping
+
+These are as efficient but not accessible by number but they behave like
+registers which means that you (can) use \type {\the}, \type {\advance}, \type
+{\multiply} and \type {\divide} with them. \footnote {There are also the slightly
+more efficient \type {\advanceby}, \type {\multiplyby} and \type {\divideby} that
+don't check for the \type {by} keyword.} In case you wonder why there is no
+alternative for \type {\toksdef}, there actually are multiple: they are called
+macros.
+
+{\em todo: expressions}
\stopsectionlevel
diff --git a/doc/context/sources/general/manuals/luametatex/luametatex.tex b/doc/context/sources/general/manuals/luametatex/luametatex.tex
index 96f700355..ba19d58e1 100644
--- a/doc/context/sources/general/manuals/luametatex/luametatex.tex
+++ b/doc/context/sources/general/manuals/luametatex/luametatex.tex
@@ -21,10 +21,6 @@
% clang bins are still slower .. quite inconsistent differences between 32 and
% 64 bit (not all compilers are the same version)
-% \loggingall
-% \tracingonline \zerocount
-% \tracingmacros \plusone
-
% \enableautoglyphscaling % saves only a few instances ... no gain .. a few pages more
% \enabletexdirective{vspacing.experimental}
diff --git a/metapost/context/base/mpxl/mp-apos.mpxl b/metapost/context/base/mpxl/mp-apos.mpxl
index a64229715..021edfc79 100644
--- a/metapost/context/base/mpxl/mp-apos.mpxl
+++ b/metapost/context/base/mpxl/mp-apos.mpxl
@@ -263,6 +263,9 @@ def anch_box_arrows_draw =
skip := (not spanpages) and ((mpvars("span")) = "yes") ;
if skip :
% we skip the second just in case
+ elseif alternative = "" :
+ message("invalid alternative in draw box arrow");
+ skip := true;
elseif alternative = "bottom" :
ff := (xpart f, min(ypart f, ypart t)) ;
tt := (xpart t, ypart ff) ;
diff --git a/source/luametatex/source/lua/lmtinterface.c b/source/luametatex/source/lua/lmtinterface.c
index bc546a9e2..641c22f8f 100644
--- a/source/luametatex/source/lua/lmtinterface.c
+++ b/source/luametatex/source/lua/lmtinterface.c
@@ -88,6 +88,7 @@ void lmt_initialize_interface(void)
set_group_code_value(adjusted_hbox_group, adjustedhbox);
set_group_code_value(vbox_group, vbox);
set_group_code_value(vtop_group, vtop);
+ set_group_code_value(dbox_group, dbox);
set_group_code_value(align_group, align);
set_group_code_value(no_align_group, noalign);
set_group_code_value(output_group, output);
@@ -123,6 +124,7 @@ void lmt_initialize_interface(void)
set_par_context_value(vmode_par_context, vmode);
set_par_context_value(vbox_par_context, vbox);
set_par_context_value(vtop_par_context, vtop);
+ set_par_context_value(dbox_par_context, dbox);
set_par_context_value(vcenter_par_context, vcenter);
set_par_context_value(vadjust_par_context, vadjust);
set_par_context_value(insert_par_context, insert);
diff --git a/source/luametatex/source/lua/lmtinterface.h b/source/luametatex/source/lua/lmtinterface.h
index c60a78266..40cfbad29 100644
--- a/source/luametatex/source/lua/lmtinterface.h
+++ b/source/luametatex/source/lua/lmtinterface.h
@@ -1456,6 +1456,7 @@ make_lua_key(L, void);\
make_lua_key(L, vrule);\
make_lua_key(L, vskip);\
make_lua_key(L, vtop);\
+make_lua_key(L, dbox);\
make_lua_key(L, whatsit);\
make_lua_key(L, widowpenalties);\
make_lua_key(L, widowpenalty);\
diff --git a/source/luametatex/source/lua/lmtnodelib.c b/source/luametatex/source/lua/lmtnodelib.c
index cc7501786..5ad42124d 100644
--- a/source/luametatex/source/lua/lmtnodelib.c
+++ b/source/luametatex/source/lua/lmtnodelib.c
@@ -8133,7 +8133,6 @@ static int nodelib_userdata_instock(lua_State *L)
return 2;
}
-
/* node.usedlist */
static int nodelib_userdata_usedlist(lua_State *L)
diff --git a/source/luametatex/source/lua/lmttexlib.c b/source/luametatex/source/lua/lmttexlib.c
index 0d84eebdd..9c1247884 100644
--- a/source/luametatex/source/lua/lmttexlib.c
+++ b/source/luametatex/source/lua/lmttexlib.c
@@ -1144,7 +1144,7 @@ static int texlib_error(lua_State *L)
*/
-inline static int texlib_aux_valid_register_index(lua_State *L, int slot, int cmd, int base, int max)
+inline static int texlib_aux_valid_register_index(lua_State *L, int slot, int cmd, int base, int max, int constant_cmd)
{
int index = -1;
switch (lua_type(L, slot)) {
@@ -1155,6 +1155,8 @@ inline static int texlib_aux_valid_register_index(lua_State *L, int slot, int cm
int cs = tex_string_locate(str, len, 0);
if (eq_type(cs) == cmd) {
index = eq_value(cs) - base;
+ } else if (eq_type(cs) == constant_cmd) {
+ return 0xFFFF + cs; // way above max
}
}
break;
@@ -1167,6 +1169,8 @@ inline static int texlib_aux_valid_register_index(lua_State *L, int slot, int cm
}
if (index >= 0 && index <= max) {
return index;
+ } else if (index < (eqtb_size + lmt_hash_state.hash_data.ptr + 1) && eq_type(index) == constant_cmd) {
+ return index;
} else {
return -1;
}
@@ -1194,9 +1198,9 @@ static int texlib_get_register_index(lua_State *L)
return 1;
}
-inline static int texlib_aux_checked_register(lua_State *L, int cmd, int base, int max)
+inline static int texlib_aux_checked_register(lua_State *L, int cmd, int base, int max, int constant_cmd)
{
- int index = texlib_aux_valid_register_index(L, 1, cmd, base, max);
+ int index = texlib_aux_valid_register_index(L, 1, cmd, base, max, constant_cmd);
if (index >= 0) {
lua_pushinteger(L, index);
} else {
@@ -1302,7 +1306,8 @@ static int texlib_aux_check_for_index(
int register_cmd,
int internal_base,
int register_base,
- int max_index
+ int max_index,
+ int constant_cmd
) {
*index = -1;
switch (lua_type(L, slot)) {
@@ -1317,6 +1322,9 @@ static int texlib_aux_check_for_index(
} else if (eq_type(cs) == register_cmd) {
*index = eq_value(cs) - register_base;
return 0;
+ } else if (eq_type(cs) == constant_cmd) {
+ *index = cs;
+ return 2;
} else {
luaL_error(L, "incorrect %s name", what);
return -1;
@@ -1326,9 +1334,14 @@ static int texlib_aux_check_for_index(
*index = lmt_tointeger(L, slot);
if (*index >= 0 && *index <= max_index) {
return 0;
- } else {
- return -1;
+ } else {
+ halfword i = *index - 0xFFFF;
+ if (i < (eqtb_size + lmt_hash_state.hash_data.ptr + 1) && eq_type(i) == constant_cmd) {
+ *index = i;
+ return 2;
+ }
}
+ return -1;
default:
luaL_error(L, "%s name or valid index expected", what);
return -1;
@@ -1347,7 +1360,7 @@ static int texlib_get(lua_State *L);
static int texlib_isdimen(lua_State *L)
{
- return texlib_aux_checked_register(L, register_dimen_cmd, register_dimen_base, max_dimen_register_index);
+ return texlib_aux_checked_register(L, register_dimen_cmd, register_dimen_base, max_dimen_register_index, dimension_cmd);
}
/* [global] name|index integer|dimension|false|nil */
@@ -1357,7 +1370,7 @@ static int texlib_setdimen(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "dimen", &index, internal_dimen_cmd, register_dimen_cmd, internal_dimen_base, register_dimen_base, max_dimen_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "dimen", &index, internal_dimen_cmd, register_dimen_cmd, internal_dimen_base, register_dimen_base, max_dimen_register_index, dimension_cmd);
if (state >= 0) {
halfword value = 0;
switch (lua_type(L, slot)) {
@@ -1380,9 +1393,13 @@ static int texlib_setdimen(lua_State *L)
luaL_error(L, "unsupported dimen value type");
break;
}
- tex_set_tex_dimen_register(index, value, flags, state);
- if (state == 1 && lua_toboolean(L, slot)) {
- tex_update_par_par(internal_dimen_cmd, index);
+ if (state == 2) {
+ tex_define(flags, index, dimension_cmd, value);
+ } else {
+ tex_set_tex_dimen_register(index, value, flags, state);
+ if (state == 1 && lua_toboolean(L, slot)) {
+ tex_update_par_par(internal_dimen_cmd, index);
+ }
}
}
return 0;
@@ -1391,8 +1408,16 @@ static int texlib_setdimen(lua_State *L)
static int texlib_getdimen(lua_State *L)
{
int index;
- int state = texlib_aux_check_for_index(L, 1, "dimen", &index, internal_dimen_cmd, register_dimen_cmd, internal_dimen_base, register_dimen_base, max_dimen_register_index);
- lua_pushinteger(L, state >= 0 ? tex_get_tex_dimen_register(index, state) : 0);
+ int state = texlib_aux_check_for_index(L, 1, "dimen", &index, internal_dimen_cmd, register_dimen_cmd, internal_dimen_base, register_dimen_base, max_dimen_register_index, dimension_cmd);
+ lua_pushinteger(L, state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_dimen_register(index, state)) : 0);
+ // halfword value;
+ // switch (state) {
+ // case 0 : value = dimen_parameter(index); break;
+ // case 1 : value = dimen_parameter(index); break;
+ // case 2 : value = eq_value(index); break;
+ // default: value = 0;
+ // }
+ // lua_pushinteger(L, value);
return 1;
}
@@ -1459,7 +1484,7 @@ static halfword texlib_aux_get_glue_spec(lua_State *L, int slot)
static int texlib_isskip(lua_State *L)
{
- return texlib_aux_checked_register(L, register_glue_cmd, register_glue_base, max_glue_register_index);
+ return texlib_aux_checked_register(L, register_glue_cmd, register_glue_base, max_glue_register_index, gluespec_cmd);
}
/* [global] name|index gluespec|false|nil */
@@ -1469,13 +1494,17 @@ static int texlib_setskip(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index, gluespec_cmd);
if (state >= 0) {
- halfword value = texlib_aux_get_glue_spec(L, slot++);
- tex_set_tex_skip_register(index, value, flags, state);
- if (state == 1 && lua_toboolean(L, slot)) {
- tex_update_par_par(internal_glue_cmd, index);
- }
+ halfword value = texlib_aux_get_glue_spec(L, slot++);
+ if (state == 2) {
+ tex_define(flags, index, gluespec_cmd, value);
+ } else {
+ tex_set_tex_skip_register(index, value, flags, state);
+ if (state == 1 && lua_toboolean(L, slot)) {
+ tex_update_par_par(internal_glue_cmd, index);
+ }
+ }
}
return 0;
}
@@ -1483,15 +1512,15 @@ static int texlib_setskip(lua_State *L)
static int texlib_getskip(lua_State *L)
{
int index;
- int state = texlib_aux_check_for_index(L, 1, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index);
- halfword value = state >= 0 ? tex_get_tex_skip_register(index, state) : null;
+ int state = texlib_aux_check_for_index(L, 1, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index, gluespec_cmd);
+ halfword value = state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_skip_register(index, state)) : null;
lmt_push_node_fast(L, tex_copy_node(value ? value : zero_glue));
return 1;
}
static int texlib_isglue(lua_State *L)
{
- return texlib_aux_checked_register(L, register_glue_cmd, register_glue_base, max_glue_register_index);
+ return texlib_aux_checked_register(L, register_glue_cmd, register_glue_base, max_glue_register_index, gluespec_cmd);
}
/* [global] slot [width] [stretch] [shrink] [stretch_order] [shrink_order] */
@@ -1501,9 +1530,14 @@ static int texlib_setglue(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index, gluespec_cmd);
if (state >= 0) {
- tex_set_tex_skip_register(index, texlib_aux_make_glue(L, lua_gettop(L), slot), flags, state);
+ halfword value = texlib_aux_make_glue(L, lua_gettop(L), slot);
+ if (state == 2) {
+ tex_define(flags, index, gluespec_cmd, value);
+ } else {
+ tex_set_tex_skip_register(index, value, flags, state);
+ }
}
return 0;
}
@@ -1512,8 +1546,8 @@ static int texlib_getglue(lua_State *L)
{
int index;
int all = (lua_type(L, 2) == LUA_TBOOLEAN) ? lua_toboolean(L, 2) : 1;
- int state = texlib_aux_check_for_index(L, 1, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index);
- halfword value = state >= 0 ? tex_get_tex_skip_register(index, state) : null;
+ int state = texlib_aux_check_for_index(L, 1, "skip", &index, internal_glue_cmd, register_glue_cmd, internal_glue_base, register_glue_base, max_glue_register_index, gluespec_cmd);
+ halfword value = state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_skip_register(index, state)) : null;
if (! value) {
lua_pushinteger(L, 0);
if (all) {
@@ -1535,7 +1569,7 @@ static int texlib_getglue(lua_State *L)
static int texlib_ismuskip(lua_State *L)
{
- return texlib_aux_checked_register(L, register_mu_glue_cmd, register_mu_glue_base, max_mu_glue_register_index);
+ return texlib_aux_checked_register(L, register_mu_glue_cmd, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
}
static int texlib_setmuskip(lua_State *L)
@@ -1543,23 +1577,30 @@ static int texlib_setmuskip(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index);
- tex_set_tex_mu_skip_register(index, texlib_aux_get_glue_spec(L, slot), flags, state);
+ int state = texlib_aux_check_for_index(L, slot++, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
+ if (state >= 0) {
+ halfword value =texlib_aux_get_glue_spec(L, slot);
+ if (state == 2) {
+ tex_define(flags, index, mugluespec_cmd, value);
+ } else {
+ tex_set_tex_mu_skip_register(index, value, flags, state);
+ }
+ }
return 0;
}
static int texlib_getmuskip(lua_State *L)
{
int index;
- int state = texlib_aux_check_for_index(L, 1, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index);
- halfword value = state >= 0 ? tex_get_tex_mu_skip_register(index, state) : null;
+ int state = texlib_aux_check_for_index(L, 1, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
+ halfword value = state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_mu_skip_register(index, state)) : null;
lmt_push_node_fast(L, tex_copy_node(value ? value : zero_glue));
return 1;
}
static int texlib_ismuglue(lua_State *L)
{
- return texlib_aux_checked_register(L, register_mu_glue_cmd, register_mu_glue_base, max_mu_glue_register_index);
+ return texlib_aux_checked_register(L, register_mu_glue_cmd, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
}
static int texlib_setmuglue(lua_State *L)
@@ -1567,10 +1608,14 @@ static int texlib_setmuglue(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index);
- halfword value = texlib_aux_make_glue(L, lua_gettop(L), slot);
+ int state = texlib_aux_check_for_index(L, slot++, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
if (state >= 0) {
- tex_set_tex_mu_skip_register(index, value, flags, state);
+ halfword value = texlib_aux_make_glue(L, lua_gettop(L), slot);
+ if (state == 2) {
+ tex_define(flags, index, mugluespec_cmd, value);
+ } else {
+ tex_set_tex_mu_skip_register(index, value, flags, state);
+ }
}
return 0;
}
@@ -1579,8 +1624,8 @@ static int texlib_getmuglue(lua_State *L)
{
int index;
int all = (lua_type(L, 2) == LUA_TBOOLEAN) ? lua_toboolean(L, 2) : 1;
- int state = texlib_aux_check_for_index(L, 1, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index);
- halfword value = state >= 0 ? tex_get_tex_mu_skip_register(index, state) : null;
+ int state = texlib_aux_check_for_index(L, 1, "muskip", &index, internal_mu_glue_cmd, register_mu_glue_cmd, internal_mu_glue_base, register_mu_glue_base, max_mu_glue_register_index, mugluespec_cmd);
+ halfword value = state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_mu_skip_register(index, state)) : null;
if (! value) {
lua_pushinteger(L, 0);
return 1;
@@ -1595,7 +1640,7 @@ static int texlib_getmuglue(lua_State *L)
static int texlib_iscount(lua_State *L)
{
- return texlib_aux_checked_register(L, register_int_cmd, register_int_base, max_int_register_index);
+ return texlib_aux_checked_register(L, register_int_cmd, register_int_base, max_int_register_index, integer_cmd);
}
static int texlib_setcount(lua_State *L)
@@ -1603,12 +1648,16 @@ static int texlib_setcount(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "count", &index, internal_int_cmd, register_int_cmd, internal_int_base, register_int_base, max_int_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "count", &index, internal_int_cmd, register_int_cmd, internal_int_base, register_int_base, max_int_register_index, integer_cmd);
if (state >= 0) {
halfword value = lmt_optinteger(L, slot++, 0);
- tex_set_tex_count_register(index, value, flags, state);
- if (state == 1 && lua_toboolean(L, slot)) {
- tex_update_par_par(internal_int_cmd, index);
+ if (state == 2) {
+ tex_define(flags, index, integer_cmd, value);
+ } else {
+ tex_set_tex_count_register(index, value, flags, state);
+ if (state == 1 && lua_toboolean(L, slot)) {
+ tex_update_par_par(internal_int_cmd, index);
+ }
}
}
return 0;
@@ -1617,14 +1666,14 @@ static int texlib_setcount(lua_State *L)
static int texlib_getcount(lua_State *L)
{
int index;
- int state = texlib_aux_check_for_index(L, 1, "count", &index, internal_int_cmd, register_int_cmd, internal_int_base, register_int_base, max_int_register_index);
- lua_pushinteger(L, state >= 0 ? tex_get_tex_count_register(index, state) : 0);
+ int state = texlib_aux_check_for_index(L, 1, "count", &index, internal_int_cmd, register_int_cmd, internal_int_base, register_int_base, max_int_register_index, integer_cmd);
+ lua_pushinteger(L, state >= 0 ? (state == 2 ? eq_value(index) : tex_get_tex_count_register(index, state)) : 0);
return 1;
}
static int texlib_isattribute(lua_State *L)
{
- return texlib_aux_checked_register(L, register_attribute_cmd, register_attribute_base, max_attribute_register_index);
+ return texlib_aux_checked_register(L, register_attribute_cmd, register_attribute_base, max_attribute_register_index, -1);
}
/*tex there are no system set attributes so this is a bit overkill */
@@ -1634,7 +1683,7 @@ static int texlib_setattribute(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "attribute", &index, internal_attribute_cmd, register_attribute_cmd, internal_attribute_base, register_attribute_base, max_attribute_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "attribute", &index, internal_attribute_cmd, register_attribute_cmd, internal_attribute_base, register_attribute_base, max_attribute_register_index, 0);
if (state >= 0) {
halfword value = lmt_optinteger(L, slot++, unused_attribute_value);
tex_set_tex_attribute_register(index, value, flags, state);
@@ -1645,7 +1694,7 @@ static int texlib_setattribute(lua_State *L)
static int texlib_getattribute(lua_State *L)
{
int index;
- int state = texlib_aux_check_for_index(L, 1, "attribute", &index, internal_attribute_cmd, register_attribute_cmd, internal_attribute_base, register_attribute_base, max_attribute_register_index);
+ int state = texlib_aux_check_for_index(L, 1, "attribute", &index, internal_attribute_cmd, register_attribute_cmd, internal_attribute_base, register_attribute_base, max_attribute_register_index, 0);
lua_pushinteger(L, state >= 0 ? tex_get_tex_attribute_register(index, state) : 0);
return 1;
}
@@ -1656,7 +1705,7 @@ static int texlib_getattribute(lua_State *L)
static int texlib_istoks(lua_State *L)
{
- return texlib_aux_checked_register(L, register_toks_cmd, register_toks_base, max_toks_register_index);
+ return texlib_aux_checked_register(L, register_toks_cmd, register_toks_base, max_toks_register_index, -1);
}
/* [global] name|integer string|nil */
@@ -1666,7 +1715,7 @@ static int texlib_settoks(lua_State *L)
int flags = 0;
int index = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base,max_toks_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base,max_toks_register_index, 0);
if (state >= 0) {
lstring value = { .c = NULL, .l = 0 };
switch (lua_type(L, slot)) {
@@ -1691,7 +1740,7 @@ static int texlib_scantoks(lua_State *L) // TODO
int index = 0;
int flags = 0;
int slot = lmt_check_for_flags(L, 1, &flags, 1, 0);
- int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base,max_toks_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base,max_toks_register_index, 0);
if (state >= 0) {
lstring value = { .c = NULL, .l = 0 };
int cattable = lmt_checkinteger(L, slot++);
@@ -1714,7 +1763,7 @@ static int texlib_gettoks(lua_State *L)
{
int index;
int slot = 1;
- int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base, max_toks_register_index);
+ int state = texlib_aux_check_for_index(L, slot++, "toks", &index, internal_toks_cmd, register_toks_cmd, internal_toks_base, register_toks_base, max_toks_register_index, 0);
if (state >= 0) {
if (lua_toboolean(L, slot)) {
lmt_token_register_to_lua(L, state ? toks_parameter(index) : toks_register(index));
diff --git a/source/luametatex/source/lua/lmttokenlib.c b/source/luametatex/source/lua/lmttokenlib.c
index 41ee6c485..c591bd7f6 100644
--- a/source/luametatex/source/lua/lmttokenlib.c
+++ b/source/luametatex/source/lua/lmttokenlib.c
@@ -2952,11 +2952,13 @@ static int tokenlib_scan_box(lua_State *L)
const char *s = lua_tostring(L, 1);
halfword code = -1 ;
if (lua_key_eq(s, hbox)) {
- code = vtop_code + hmode;
+ code = hbox_code;
} else if (lua_key_eq(s, vbox)) {
- code = vtop_code + vmode;
+ code = vbox_code;
} else if (lua_key_eq(s, vtop)) {
code = vtop_code;
+ } else if (lua_key_eq(s, dbox)) {
+ code = dbox_code;
}
if (code >= 0) {
tex_back_input(token_val(make_box_cmd, code));
diff --git a/source/luametatex/source/luametatex.h b/source/luametatex/source/luametatex.h
index 973b405ae..c92599fbc 100644
--- a/source/luametatex/source/luametatex.h
+++ b/source/luametatex/source/luametatex.h
@@ -89,7 +89,7 @@
# define luametatex_version 210
# define luametatex_revision 04
# define luametatex_version_string "2.10.04"
-# define luametatex_development_id 20221214
+# define luametatex_development_id 20221221
# define luametatex_name_camelcase "LuaMetaTeX"
# define luametatex_name_lowercase "luametatex"
diff --git a/source/luametatex/source/tex/texcommands.c b/source/luametatex/source/tex/texcommands.c
index 0ad91e420..eeef6b9f6 100644
--- a/source/luametatex/source/tex/texcommands.c
+++ b/source/luametatex/source/tex/texcommands.c
@@ -316,6 +316,11 @@ void tex_initialize_commands(void)
tex_primitive(tex_command, "advance", arithmic_cmd, advance_code, 0);
tex_primitive(tex_command, "divide", arithmic_cmd, divide_code, 0);
tex_primitive(tex_command, "multiply", arithmic_cmd, multiply_code, 0);
+ tex_primitive(tex_command, "advanceby", arithmic_cmd, advance_by_code, 0);
+ tex_primitive(tex_command, "divideby", arithmic_cmd, divide_by_code, 0);
+ tex_primitive(tex_command, "multiplyby", arithmic_cmd, multiply_by_code, 0);
+ /* tex_primitive(tex_command, "advancebyplusone", arithmic_cmd, advance_by_plus_one_code, 0); */
+ /* tex_primitive(tex_command, "advancebyminusone", arithmic_cmd, advance_by_minus_one_code, 0); */
/*tex We combined the after thingies into one category:*/
@@ -877,9 +882,11 @@ void tex_initialize_commands(void)
tex_primitive(luatex_command, "tpack", make_box_cmd, tpack_code, 0);
tex_primitive(luatex_command, "vpack", make_box_cmd, vpack_code, 0);
tex_primitive(luatex_command, "hpack", make_box_cmd, hpack_code, 0);
+ tex_primitive(luatex_command, "dpack", make_box_cmd, dpack_code, 0);
tex_primitive(tex_command, "vtop", make_box_cmd, vtop_code, 0);
tex_primitive(tex_command, "vbox", make_box_cmd, vbox_code, 0);
tex_primitive(tex_command, "hbox", make_box_cmd, hbox_code, 0);
+ tex_primitive(luatex_command, "dbox", make_box_cmd, dbox_code, 0);
tex_primitive(luatex_command, "insertbox", make_box_cmd, insert_box_code, 0);
tex_primitive(luatex_command, "insertcopy", make_box_cmd, insert_copy_code, 0);
tex_primitive(luatex_command, "localleftboxbox", make_box_cmd, local_left_box_box_code, 0);
@@ -985,7 +992,7 @@ void tex_initialize_commands(void)
tex_primitive(tex_command, "muskipdef", shorthand_def_cmd, mu_skip_def_code, 0);
tex_primitive(tex_command, "skipdef", shorthand_def_cmd, skip_def_code, 0);
tex_primitive(tex_command, "toksdef", shorthand_def_cmd, toks_def_code, 0);
- /* tex_primitive(tex_command, "stringdef", shorthand_def_cmd, string_def_code, 0); */
+ /* tex_primitive(luatex_command, "stringdef", shorthand_def_cmd, string_def_code, 0); */
tex_primitive(luatex_command, "Umathchardef", shorthand_def_cmd, math_xchar_def_code, 0);
tex_primitive(luatex_command, "Umathdictdef", shorthand_def_cmd, math_dchar_def_code, 0);
tex_primitive(luatex_command, "attributedef", shorthand_def_cmd, attribute_def_code, 0);
@@ -996,6 +1003,8 @@ void tex_initialize_commands(void)
tex_primitive(luatex_command, "mugluespecdef", shorthand_def_cmd, mugluespec_def_code, 0);
/* tex_primitive(luatex_command, "mathspecdef", shorthand_def_cmd, mathspec_def_code, 0); */
tex_primitive(luatex_command, "fontspecdef", shorthand_def_cmd, fontspec_def_code, 0);
+ /* tex_primitive(luatex_command, "integerdefcsname", shorthand_def_cmd, integer_def_csname_code, 0); */
+ /* tex_primitive(luatex_command, "dimensiondefcsname", shorthand_def_cmd, dimension_def_csname_code, 0); */
tex_primitive(tex_command, "noindent", begin_paragraph_cmd, noindent_par_code, 0);
tex_primitive(tex_command, "indent", begin_paragraph_cmd, indent_par_code, 0);
diff --git a/source/luametatex/source/tex/texcommands.h b/source/luametatex/source/tex/texcommands.h
index 8df61a4db..be0639af7 100644
--- a/source/luametatex/source/tex/texcommands.h
+++ b/source/luametatex/source/tex/texcommands.h
@@ -334,7 +334,7 @@ typedef enum tex_command_code {
# define is_referenced_cmd(cmd) (cmd >= call_cmd)
# define is_nodebased_cmd(cmd) (cmd >= gluespec_cmd && cmd <= fontspec_cmd)
-
+# define is_constant_cmd(cmd) (cmd >= integer_cmd && cmd <= gluespec_cmd)
# if (main_control_mode == 1)
@@ -362,10 +362,15 @@ typedef enum arithmic_codes {
advance_code,
multiply_code,
divide_code,
+ advance_by_code,
+ multiply_by_code,
+ divide_by_code,
/* bitwise_and_code, */
/* bitwise_xor_code, */
/* bitwise_or_code, */
/* bitwise_not_code, */
+ /* advance_by_plus_one_code, */
+ /* advance_by_minus_one_code, */
} arithmic_codes;
# define last_arithmic_code divide_code
@@ -690,6 +695,8 @@ typedef enum shorthand_def_codes {
mugluespec_def_code,
/* mathspec_def_code, */
fontspec_def_code,
+ /* integer_def_csname_code, */
+ /* dimension_def_csname_code, */
} shorthand_def_codes;
# define last_shorthand_def_code fontspec_def_code
diff --git a/source/luametatex/source/tex/texdumpdata.h b/source/luametatex/source/tex/texdumpdata.h
index 4f3450ef4..6a9eb5fa4 100644
--- a/source/luametatex/source/tex/texdumpdata.h
+++ b/source/luametatex/source/tex/texdumpdata.h
@@ -55,7 +55,7 @@
*/
-# define luametatex_format_fingerprint 679
+# define luametatex_format_fingerprint 680
/* These end up in the string pool. */
diff --git a/source/luametatex/source/tex/texequivalents.c b/source/luametatex/source/tex/texequivalents.c
index 223e46e15..d91663dd3 100644
--- a/source/luametatex/source/tex/texequivalents.c
+++ b/source/luametatex/source/tex/texequivalents.c
@@ -569,6 +569,9 @@ void tex_show_save_groups(void)
case vtop_group:
package = "vtop";
break;
+ case dbox_group:
+ package = "dbox";
+ break;
case align_group:
if (alignmentstate == 0) {
package = (mode == -vmode) ? "halign" : "valign";
@@ -1176,6 +1179,37 @@ void tex_define(int g, halfword p, singleword t, halfword e) /* int g -> singlew
}
}
+void tex_define_again(int g, halfword p, singleword t, halfword e) /* int g -> singleword g */
+{
+ if (tracing_assigns_par > 0) {
+ singleword f = make_eq_flag_bits(g);
+ if (is_global(g)) {
+ /* what if already global */
+ tex_aux_diagnostic_trace(p, "globally changing");
+ // if (tex_aux_equal_eq(p, t, f, e) && (eq_level(p) == level_one)) {
+ // return; /* we can save some stack */
+ // }
+ tex_aux_eq_destroy(lmt_hash_state.eqtb[p]);
+ tex_aux_set_eq_data(p, t, e, f, level_one);
+ } else if (tex_aux_equal_eq(p, t, f, e)) {
+ /* hm, we tweak the ref ! */
+ tex_aux_diagnostic_trace(p, "reassigning");
+ } else {
+ tex_aux_diagnostic_trace(p, "changing");
+ if (eq_level(p) == cur_level) {
+ tex_aux_eq_destroy(lmt_hash_state.eqtb[p]);
+ } else if (cur_level > level_one) {
+ tex_aux_eq_save(p, eq_level(p));
+ }
+ tex_aux_set_eq_data(p, t, e, f, cur_level);
+ }
+ tex_aux_diagnostic_trace(p, "into");
+ } else {
+ set_eq_type(p, t);
+ set_eq_value(p, e);
+ }
+}
+
void tex_define_inherit(int g, halfword p, singleword f, singleword t, halfword e)
{
int trace = tracing_assigns_par > 0;
diff --git a/source/luametatex/source/tex/texequivalents.h b/source/luametatex/source/tex/texequivalents.h
index c84b90226..511463c6a 100644
--- a/source/luametatex/source/tex/texequivalents.h
+++ b/source/luametatex/source/tex/texequivalents.h
@@ -719,7 +719,10 @@ typedef enum attribute_codes {
# define internal_specification_location(a) (internal_specification_base + (a))
# define internal_specification_number(a) ((a) - internal_specification_base)
-# define eqtb_size (internal_specification_base + number_specification_pars)
+# define eqtb_size (internal_specification_base + number_specification_pars)
+# define eqtb_max_so_far (eqtb_size + lmt_hash_state.hash_data.ptr + 1)
+
+/* below: top or ptr +1 ? */
# define eqtb_indirect_range(n) ((n < internal_glue_base) || ((n > eqtb_size) && (n <= lmt_hash_state.hash_data.top)))
# define eqtb_out_of_range(n) ((n >= undefined_control_sequence) && ((n <= eqtb_size) || n > lmt_hash_state.hash_data.top))
@@ -968,6 +971,7 @@ typedef enum tex_group_codes {
adjusted_hbox_group, /*tex code for |\hbox| in vertical mode */
vbox_group, /*tex code for |\vbox| */
vtop_group, /*tex code for |\vtop| */
+ dbox_group, /*tex code for |\dbox| */
align_group, /*tex code for |\halign|, |\valign| */
no_align_group, /*tex code for |\noalign| */
output_group, /*tex code for output routine */
@@ -1012,6 +1016,7 @@ typedef enum tex_par_context_codes {
vmode_par_context,
vbox_par_context,
vtop_par_context,
+ dbox_par_context,
vcenter_par_context,
vadjust_par_context,
insert_par_context,
@@ -1257,6 +1262,7 @@ inline static singleword tex_flags_to_cmd(int flags)
extern int tex_define_permitted (halfword cs, halfword prefixes);
extern void tex_define (int g, halfword p, singleword cmd, halfword chr);
+extern void tex_define_again (int g, halfword p, singleword cmd, halfword chr);
extern void tex_define_inherit (int g, halfword p, singleword flag, singleword cmd, halfword chr);
extern void tex_define_swapped (int g, halfword p1, halfword p2, int force);
extern void tex_forced_define (int g, halfword p, singleword flag, singleword cmd, halfword chr);
diff --git a/source/luametatex/source/tex/texmaincontrol.c b/source/luametatex/source/tex/texmaincontrol.c
index dbb52ab15..aa160968e 100644
--- a/source/luametatex/source/tex/texmaincontrol.c
+++ b/source/luametatex/source/tex/texmaincontrol.c
@@ -2487,7 +2487,7 @@ static void tex_aux_extra_right_brace_error(void)
inline static void tex_aux_finish_hbox(void)
{
tex_aux_fixup_directions_only();
- tex_package(hpack_code);
+ tex_package(hbox_code);
}
inline static void tex_aux_finish_adjusted_hbox(void)
@@ -2496,14 +2496,14 @@ inline static void tex_aux_finish_adjusted_hbox(void)
lmt_packaging_state.pre_adjust_tail = pre_adjust_head;
lmt_packaging_state.post_migrate_tail = post_migrate_head;
lmt_packaging_state.pre_migrate_tail = pre_migrate_head;
- tex_package(hpack_code);
+ tex_package(hbox_code);
}
inline static void tex_aux_finish_vbox(void)
{
if (! tex_wrapped_up_paragraph(vbox_par_context)) {
tex_end_paragraph(vbox_group, vbox_par_context);
- tex_package(vpack_code);
+ tex_package(vbox_code);
}
}
@@ -2515,6 +2515,14 @@ inline static void tex_aux_finish_vtop(void)
}
}
+inline static void tex_aux_finish_dbox(void)
+{
+ if (! tex_wrapped_up_paragraph(dbox_par_context)) {
+ tex_end_paragraph(dbox_group, dbox_par_context);
+ tex_package(dbox_code);
+ }
+}
+
inline static void tex_aux_finish_simple_group(void)
{
tex_aux_fixup_directions_and_unsave();
@@ -2557,6 +2565,9 @@ static void tex_aux_run_right_brace(void)
case vtop_group:
tex_aux_finish_vtop();
break;
+ case dbox_group:
+ tex_aux_finish_dbox();
+ break;
case align_group:
tex_finish_alignment_group();
break;
@@ -3538,40 +3549,71 @@ inline static halfword tex_aux_get_register_value(int level, int optionalequal)
}
}
-static int tex_aux_valid_arithmic(int cmd, int *index, int *level, int *varcmd)
+static int tex_aux_valid_arithmic(int cmd, int *index, int *level, int *varcmd, int *simple, int *original)
{
/*tex So: |\multiply|, |\divide| or |\advance|. */
tex_get_x_token();
*varcmd = cur_cmd;
+ /* *simple = 0; */
switch (cur_cmd) {
case register_int_cmd:
case internal_int_cmd:
*index = cur_chr;
*level = int_val_level;
+ *original = eq_value(*index);
return 1;
case register_attribute_cmd:
case internal_attribute_cmd:
*index = cur_chr;
*level = attr_val_level;
+ *original = eq_value(*index);
return 1;
case register_dimen_cmd:
case internal_dimen_cmd:
*index = cur_chr;
*level = dimen_val_level;
+ *original = eq_value(*index);
return 1;
case register_glue_cmd:
case internal_glue_cmd:
*index = cur_chr;
*level = glue_val_level;
+ *original = eq_value(*index);
return 1;
case register_mu_glue_cmd:
case internal_mu_glue_cmd:
*index = cur_chr;
*level = mu_val_level;
+ *original = eq_value(*index);
return 1;
case register_cmd:
- *level = cur_chr;
*index = tex_aux_get_register_index(*level);
+ *level = cur_chr;
+ *original = eq_value(*index);
+ return 1;
+ case integer_cmd:
+ *index = cur_cs;
+ *level = int_val_level;
+ *original = cur_chr;
+ *simple = integer_cmd;
+ return 1;
+ case dimension_cmd:
+ *index = cur_cs;
+ *level = dimen_val_level;
+ *original = cur_chr;
+ *simple = dimension_cmd;
+ return 1;
+ case gluespec_cmd:
+ *index = cur_cs;
+ *level = glue_val_level;
+ *original = cur_chr;
+ *simple = gluespec_cmd;
+ return 1;
+ case mugluespec_cmd:
+ *index = cur_cs;
+ *level = mu_val_level;
+ *original = cur_chr;
+ *simple = mugluespec_cmd;
return 1;
default:
tex_handle_error(
@@ -3635,7 +3677,7 @@ inline static void tex_aux_update_register(int a, int level, halfword index, hal
}
}
-static void tex_aux_set_register(int a)
+inline static void tex_aux_set_register(int a)
{
halfword level = cur_chr;
halfword varcmd = cur_cmd;
@@ -3644,51 +3686,60 @@ static void tex_aux_set_register(int a)
tex_aux_update_register(a, level, index, value, varcmd);
}
+/*tex
+ The by-less variant is more efficient as there is no push back of the token when there is not
+ such keyword. It goes unnoticed on an average run but not on the total runtime of 15.000
+ (times 2) runs of a 30 page \CONTEXT\ document with plenty of complex tables. So this is one
+ of the few obscure optimizations I grand myself (if only to be able to discuss it).
+*/
+
static void tex_aux_arithmic_register(int a, int code)
{
halfword cmd = cur_cmd;
halfword level = cur_chr;
halfword index = 0;
halfword varcmd = 0;
- if (tex_aux_valid_arithmic(cmd, &index, &level, &varcmd)) {
+ halfword simple = 0;
+ halfword original = 0;
+ if (tex_aux_valid_arithmic(cmd, &index, &level, &varcmd, &simple, &original)) {
halfword value = null;
- tex_scan_optional_keyword("by");
lmt_scanner_state.arithmic_error = 0;
switch (code) {
case advance_code:
+ tex_scan_optional_keyword("by");
+ case advance_by_code:
{
value = tex_aux_get_register_value(level, 0);
switch (level) {
case int_val_level:
case attr_val_level:
case dimen_val_level:
- value += eq_value(index);
+ value += original;
break;
case glue_val_level:
case mu_val_level:
{
/* Compute the sum of two glue specs */
- halfword oldvalue = eq_value(index);
halfword newvalue = tex_new_glue_spec_node(value);
tex_flush_node(value);
- glue_amount(newvalue) += glue_amount(oldvalue);
+ glue_amount(newvalue) += glue_amount(original);
if (glue_stretch(newvalue) == 0) {
glue_stretch_order(newvalue) = normal_glue_order;
}
- if (glue_stretch_order(newvalue) == glue_stretch_order(oldvalue)) {
- glue_stretch(newvalue) += glue_stretch(oldvalue);
- } else if ((glue_stretch_order(newvalue) < glue_stretch_order(oldvalue)) && (glue_stretch(oldvalue))) {
- glue_stretch(newvalue) = glue_stretch(oldvalue);
- glue_stretch_order(newvalue) = glue_stretch_order(oldvalue);
+ if (glue_stretch_order(newvalue) == glue_stretch_order(original)) {
+ glue_stretch(newvalue) += glue_stretch(original);
+ } else if ((glue_stretch_order(newvalue) < glue_stretch_order(original)) && (glue_stretch(original))) {
+ glue_stretch(newvalue) = glue_stretch(original);
+ glue_stretch_order(newvalue) = glue_stretch_order(original);
}
if (glue_shrink(newvalue) == 0) {
glue_shrink_order(newvalue) = normal_glue_order;
}
- if (glue_shrink_order(newvalue) == glue_shrink_order(oldvalue)) {
- glue_shrink(newvalue) += glue_shrink(oldvalue);
- } else if ((glue_shrink_order(newvalue) < glue_shrink_order(oldvalue)) && (glue_shrink(oldvalue))) {
- glue_shrink(newvalue) = glue_shrink(oldvalue);
- glue_shrink_order(newvalue) = glue_shrink_order(oldvalue);
+ if (glue_shrink_order(newvalue) == glue_shrink_order(original)) {
+ glue_shrink(newvalue) += glue_shrink(original);
+ } else if ((glue_shrink_order(newvalue) < glue_shrink_order(original)) && (glue_shrink(original))) {
+ glue_shrink(newvalue) = glue_shrink(original);
+ glue_shrink_order(newvalue) = glue_shrink_order(original);
}
value = newvalue;
break;
@@ -3698,29 +3749,34 @@ static void tex_aux_arithmic_register(int a, int code)
break;
}
/*tex There is no overflow detection for addition, just wraparound. */
- tex_aux_update_register(a, level, index, value, varcmd);
+ if (simple) {
+ tex_define(a, index, simple, value);
+ } else {
+ tex_aux_update_register(a, level, index, value, varcmd);
+ }
break;
}
case multiply_code:
+ tex_scan_optional_keyword("by");
+ case multiply_by_code:
{
halfword amount = tex_scan_int(0, NULL);
switch (level) {
case int_val_level:
case attr_val_level:
- value = tex_multiply_integers(eq_value(index), amount);
+ value = tex_multiply_integers(original, amount);
break;
case dimen_val_level:
- value = tex_nx_plus_y(eq_value(index), amount, 0);
+ value = tex_nx_plus_y(original, amount, 0);
break;
case glue_val_level:
case mu_val_level:
{
- halfword s = eq_value(index);
- halfword r = tex_new_glue_spec_node(s);
- glue_amount(r) = tex_nx_plus_y(glue_amount(s), amount, 0);
- glue_stretch(r) = tex_nx_plus_y(glue_stretch(s), amount, 0);
- glue_shrink(r) = tex_nx_plus_y(glue_shrink(s), amount, 0);
- value = r;
+ halfword newvalue = tex_new_glue_spec_node(original);
+ glue_amount(newvalue) = tex_nx_plus_y(glue_amount(original), amount, 0);
+ glue_stretch(newvalue) = tex_nx_plus_y(glue_stretch(original), amount, 0);
+ glue_shrink(newvalue) = tex_nx_plus_y(glue_shrink(original), amount, 0);
+ value = newvalue;
break;
}
default:
@@ -3729,29 +3785,32 @@ static void tex_aux_arithmic_register(int a, int code)
}
if (lmt_scanner_state.arithmic_error) {
tex_aux_arithmic_overflow_error(level, value);
+ } else if (simple) {
+ tex_define(a, index, simple, value);
} else {
tex_aux_update_register(a, level, index, value, varcmd);
}
break;
}
case divide_code:
+ tex_scan_optional_keyword("by");
+ case divide_by_code:
{
halfword amount = tex_scan_int(0, NULL);
switch (level) {
case int_val_level:
case attr_val_level:
case dimen_val_level:
- value = tex_x_over_n(eq_value(index), amount);
+ value = tex_x_over_n(original, amount);
break;
case glue_val_level:
case mu_val_level:
{
- halfword s = eq_value(index);
- halfword r = tex_new_glue_spec_node(s);
- glue_amount(r) = tex_x_over_n(glue_amount(s), amount);
- glue_stretch(r) = tex_x_over_n(glue_stretch(s), amount);
- glue_shrink(r) = tex_x_over_n(glue_shrink(s), amount);
- value = r;
+ halfword newvalue = tex_new_glue_spec_node(original);
+ glue_amount(newvalue) = tex_x_over_n(glue_amount(original), amount);
+ glue_stretch(newvalue) = tex_x_over_n(glue_stretch(original), amount);
+ glue_shrink(newvalue) = tex_x_over_n(glue_shrink(original), amount);
+ value = newvalue;
break;
}
default:
@@ -3760,11 +3819,31 @@ static void tex_aux_arithmic_register(int a, int code)
}
if (lmt_scanner_state.arithmic_error) {
tex_aux_arithmic_overflow_error(level, value);
+ } else if (simple) {
+ tex_define(a, index, simple, value);
} else {
tex_aux_update_register(a, level, index, value, varcmd);
}
break;
}
+ /*
+ case advance_by_plus_one_code:
+ case advance_by_minus_one_code:
+ {
+ switch (level) {
+ case int_val_level:
+ case attr_val_level:
+ original += code == advance_by_plus_one_code ? 1 : -1;
+ if (simple) {
+ tex_define(a, index, simple, original);
+ } else {
+ tex_aux_update_register(a, level, index, original, varcmd);
+ }
+ break;
+ }
+ break;
+ }
+ */
}
}
}
@@ -4171,8 +4250,20 @@ static void tex_aux_set_box(int a)
static void tex_aux_set_shorthand_def(int a, int force)
{
halfword code = cur_chr;
+ /*
+ switch (code) {
+ case integer_def_csname_code:
+ case dimension_def_csname_code:
+ cur_cs = tex_create_csname();
+ break;
+ default:
+ tex_get_r_token();
+ break;
+ }
+ */
tex_get_r_token();
if (force || tex_define_permitted(cur_cs, a)) {
+ /* can we optimize the dual define, like no need to destroy in second call */
halfword p = cur_cs;
tex_define(a, p, relax_cmd, relax_code);
tex_scan_optional_equals();
@@ -4180,92 +4271,94 @@ static void tex_aux_set_shorthand_def(int a, int force)
case char_def_code:
{
halfword chr = tex_scan_char_number(0); /* maybe 1 */
- tex_define(a, p, char_given_cmd, chr);
+ tex_define_again(a, p, char_given_cmd, chr);
break;
}
case math_char_def_code:
{
mathcodeval mval = tex_scan_mathchar(tex_mathcode);
- tex_define(a, p, mathspec_cmd, tex_new_math_spec(mval, tex_mathcode));
+ tex_define_again(a, p, mathspec_cmd, tex_new_math_spec(mval, tex_mathcode));
break;
}
case math_dchar_def_code:
{
mathdictval dval = tex_scan_mathdict();
mathcodeval mval = tex_scan_mathchar(umath_mathcode);
- tex_define(a, p, mathspec_cmd, tex_new_math_dict_spec(dval, mval, umath_mathcode));
+ tex_define_again(a, p, mathspec_cmd, tex_new_math_dict_spec(dval, mval, umath_mathcode));
break;
}
case math_xchar_def_code:
{
mathcodeval mval = tex_scan_mathchar(umath_mathcode);
- tex_define(a, p, mathspec_cmd, tex_new_math_spec(mval, umath_mathcode));
+ tex_define_again(a, p, mathspec_cmd, tex_new_math_spec(mval, umath_mathcode));
break;
}
case count_def_code:
{
halfword n = tex_scan_int_register_number();
- tex_define(a, p, register_int_cmd, register_int_location(n));
+ tex_define_again(a, p, register_int_cmd, register_int_location(n));
break;
}
case attribute_def_code:
{
halfword n = tex_scan_attribute_register_number();
- tex_define(a, p, register_attribute_cmd, register_attribute_location(n));
+ tex_define_again(a, p, register_attribute_cmd, register_attribute_location(n));
break;
}
case dimen_def_code:
{
scaled n = tex_scan_dimen_register_number();
- tex_define(a, p, register_dimen_cmd, register_dimen_location(n));
+ tex_define_again(a, p, register_dimen_cmd, register_dimen_location(n));
break;
}
case skip_def_code:
{
halfword n = tex_scan_glue_register_number();
- tex_define(a, p, register_glue_cmd, register_glue_location(n));
+ tex_define_again(a, p, register_glue_cmd, register_glue_location(n));
break;
}
case mu_skip_def_code:
{
halfword n = tex_scan_mu_glue_register_number();
- tex_define(a, p, register_mu_glue_cmd, register_mu_glue_location(n));
+ tex_define_again(a, p, register_mu_glue_cmd, register_mu_glue_location(n));
break;
}
case toks_def_code:
{
halfword n = tex_scan_toks_register_number();
- tex_define(a, p, register_toks_cmd, register_toks_location(n));
+ tex_define_again(a, p, register_toks_cmd, register_toks_location(n));
break;
}
case lua_def_code:
{
halfword v = tex_scan_function_reference(1);
- tex_define(a, p, is_protected(a) ? lua_protected_call_cmd : lua_call_cmd, v);
+ tex_define_again(a, p, is_protected(a) ? lua_protected_call_cmd : lua_call_cmd, v);
}
break;
case integer_def_code:
+ /* case integer_def_csname_code: */
{
halfword v = tex_scan_int(1, NULL);
- tex_define(a, p, integer_cmd, v);
+ tex_define_again(a, p, integer_cmd, v);
}
break;
case dimension_def_code:
+ /* case dimension_def_csname_code: */
{
scaled v = tex_scan_dimen(0, 0, 0, 1, NULL);
- tex_define(a, p, dimension_cmd, v);
+ tex_define_again(a, p, dimension_cmd, v);
}
break;
case gluespec_def_code:
{
halfword v = tex_scan_glue(glue_val_level, 1);
- tex_define(a, p, gluespec_cmd, v);
+ tex_define_again(a, p, gluespec_cmd, v);
}
break;
case mugluespec_def_code:
{
halfword v = tex_scan_glue(mu_val_level, 1);
- tex_define(a, p, mugluespec_cmd, v);
+ tex_define_again(a, p, mugluespec_cmd, v);
}
break;
/*
@@ -4677,13 +4770,13 @@ static void tex_aux_set_let(int a, int force)
a = add_global_flag(a);
}
if (force || tex_define_permitted(cur_cs, a)) {
- /*tex
- The commented line permits plenty empty definitions, a |\let| can run out of
- ref count so maybe some day \unknown
- */
+ // /*tex
+ // The commented line permits plenty empty definitions, a |\let| can run out of
+ // ref count so maybe some day \unknown
+ // */
// halfword empty = get_reference_token();
- halfword empty = lmt_token_state.empty;
// tex_add_token_reference(empty);
+ halfword empty = lmt_token_state.empty;
tex_define(a, cur_cs, tex_flags_to_cmd(a), empty);
}
return;
@@ -4704,6 +4797,10 @@ static void tex_aux_set_let(int a, int force)
singleword newf = 0;
singleword cmd = (singleword) cur_cmd;
if (is_aliased(a)) {
+ /*tex
+ Aliases only work for non constants: else make a |\def| of it or we need some
+ pointer to the original but as the meaning can change. Too tricky.
+ */
newf = oldf;
} else {
oldf = remove_overload_flags(oldf);
@@ -5393,6 +5490,36 @@ static int tex_aux_set_some_item(halfword a)
}
}
+static void tex_aux_set_constant_register(halfword cmd, halfword cs, halfword flags)
+{
+ switch(cmd) {
+ case integer_cmd:
+ {
+ halfword v = tex_scan_int(1, NULL);
+ tex_define(flags, cs, integer_cmd, v);
+ }
+ break;
+ case dimension_cmd:
+ {
+ scaled v = tex_scan_dimen(0, 0, 0, 1, NULL);
+ tex_define(flags, cs, dimension_cmd, v);
+ }
+ break;
+ case gluespec_cmd:
+ {
+ halfword v = tex_scan_glue(glue_val_level, 1);
+ tex_define(flags, cs, gluespec_cmd, v);
+ }
+ break;
+ case mugluespec_cmd:
+ {
+ halfword v = tex_scan_glue(mu_val_level, 1);
+ tex_define(flags, cs, mugluespec_cmd, v);
+ }
+ break;
+ }
+}
+
void tex_run_prefixed_command(void)
{
/*tex accumulated prefix codes so far */
@@ -5550,6 +5677,12 @@ void tex_run_prefixed_command(void)
tex_aux_run_illegal_case();
}
break;
+ case integer_cmd:
+ case dimension_cmd:
+ case gluespec_cmd:
+ case mugluespec_cmd:
+ tex_aux_set_constant_register(cur_cmd, cur_cs, flags);
+ break;
default:
if (lastprefix < 0) {
tex_confusion("prefixed command");
@@ -6340,11 +6473,10 @@ inline static void tex_aux_big_switch(int mode, int cmd)
register_simple(set_specification_cmd, tex_run_prefixed_command);
register_simple(shorthand_def_cmd, tex_run_prefixed_command);
register_simple(lua_value_cmd, tex_run_prefixed_command);
-
- register_simple(integer_cmd, tex_aux_run_illegal_case); /*tex This is better than |run_relax|. */
- register_simple(dimension_cmd, tex_aux_run_illegal_case); /*tex This is better than |run_relax|. */
- register_simple(gluespec_cmd, tex_aux_run_illegal_case); /*tex This is better than |run_relax|. */
- register_simple(mugluespec_cmd, tex_aux_run_illegal_case); /*tex This is better than |run_relax|. */
+ register_simple(integer_cmd, tex_run_prefixed_command);
+ register_simple(dimension_cmd, tex_run_prefixed_command);
+ register_simple(gluespec_cmd, tex_run_prefixed_command);
+ register_simple(mugluespec_cmd, tex_run_prefixed_command);
register_simple(fontspec_cmd, tex_run_font_spec);
diff --git a/source/luametatex/source/tex/texmath.c b/source/luametatex/source/tex/texmath.c
index 216ba553b..ffc73cd12 100644
--- a/source/luametatex/source/tex/texmath.c
+++ b/source/luametatex/source/tex/texmath.c
@@ -3756,7 +3756,8 @@ static void tex_aux_flatten_math_list(halfword parent)
switch (node_type(p)) {
case simple_noad:
{
- if (! noad_has_following_scripts(p) && tex_math_has_class_option(node_subtype(p), flatten_class_option)) {
+ // how about the options and class
+ if (! noad_has_following_scripts(p) && tex_math_has_class_option(node_subtype(p), flatten_class_option) && ! noad_source(p)) {
halfword n = noad_nucleus(p);
halfword s = parent;
node_type(s) = node_type(n);
diff --git a/source/luametatex/source/tex/texnodes.c b/source/luametatex/source/tex/texnodes.c
index a0601e594..f6daab056 100644
--- a/source/luametatex/source/tex/texnodes.c
+++ b/source/luametatex/source/tex/texnodes.c
@@ -1770,6 +1770,8 @@ int tex_n_of_used_nodes(int counts[])
return n;
}
+/* needs checking as we take from the pool */
+
halfword tex_list_node_mem_usage(void)
{
char *saved_varmem_sizes = aux_allocate_array(sizeof(char), lmt_node_memory_state.nodes_data.allocated, 1);
diff --git a/source/luametatex/source/tex/texnodes.h b/source/luametatex/source/tex/texnodes.h
index 45e53187a..9cc1cbb39 100644
--- a/source/luametatex/source/tex/texnodes.h
+++ b/source/luametatex/source/tex/texnodes.h
@@ -898,18 +898,19 @@ typedef enum package_states {
hbox_package_state = 0x01,
vbox_package_state = 0x02,
vtop_package_state = 0x03,
+ dbox_package_state = 0x04,
/* maybe vcenter */
} package_states;
typedef enum package_dimension_states {
package_dimension_not_set = 0x00,
- package_dimension_size_set = 0x04,
+ package_dimension_size_set = 0x10,
} package_dimension_states;
typedef enum package_leader_states {
package_u_leader_not_set = 0x00,
- package_u_leader_set = 0x08,
- package_u_leader_delayed = 0x10,
+ package_u_leader_set = 0x20,
+ package_u_leader_delayed = 0x40,
} package_leader_states;
# define set_box_package_state(p,s) box_package_state(p) |= s
diff --git a/source/luametatex/source/tex/texpackaging.c b/source/luametatex/source/tex/texpackaging.c
index 796c3c1b7..9b7ff31bf 100644
--- a/source/luametatex/source/tex/texpackaging.c
+++ b/source/luametatex/source/tex/texpackaging.c
@@ -2335,7 +2335,7 @@ void tex_finish_vcenter_group(void)
if (! tex_wrapped_up_paragraph(vcenter_par_context)) {
halfword p;
tex_end_paragraph(vcenter_group, vcenter_par_context);
- tex_package(vpack_code);
+ tex_package(vbox_code); /* todo: vcenter_code */
p = tex_pop_tail();
if (p) {
switch (node_type(p)) {
@@ -2381,6 +2381,21 @@ inline static scaled tex_aux_checked_dimen2(halfword v)
}
}
+static scaled tex_aux_first_height(halfword boxnode)
+{
+ halfword list = box_list(boxnode);
+ if (list) {
+ switch (node_type(list)) {
+ case hlist_node:
+ case vlist_node:
+ return box_height(list);
+ case rule_node:
+ return rule_height(list);
+ }
+ }
+ return 0;
+}
+
void tex_package(singleword nature)
{
halfword context, spec, dirptr, attrlist, justpack, orientation, anchor, geometry, source, target, axis, mainclass, state, retain;
@@ -2416,32 +2431,28 @@ void tex_package(singleword nature)
} else {
boxnode = tex_filtered_vpack(node_next(cur_list.head), spec, saved_level(saved_full_spec_item_packaging),
maxdepth, grp, saved_level(saved_full_spec_item_direction), justpack, attrlist, state, retain);
- if (nature == vtop_code) {
- /*tex
+ switch (nature) {
+ case vtop_code:
+ {
+ /*tex
- Read just the height and depth of |boxnode| (|boxnode|), for |\vtop|. The height of
- a |\vtop| box is inherited from the first item on its list, if that item is an
- |hlist_node|, |vlist_node|, or |rule_node|; otherwise the |\vtop| height is zero.
+ Read just the height and depth of |boxnode| (|boxnode|), for |\vtop|. The height of
+ a |\vtop| box is inherited from the first item on its list, if that item is an
+ |hlist_node|, |vlist_node|, or |rule_node|; otherwise the |\vtop| height is zero.
- */
- scaled height = 0;
- halfword list = box_list(boxnode);
- if (list) {
- switch (node_type(list)) {
- case hlist_node:
- case vlist_node:
- height = box_height(list);
- break;
- case rule_node:
- height = rule_height(list);
- break;
+ */
+ scaled height = tex_aux_first_height(boxnode);
+ box_depth(boxnode) = box_total(boxnode) - height;
+ box_height(boxnode) = height;
+ box_package_state(boxnode) = vtop_package_state;
}
- }
- box_depth(boxnode) = box_total(boxnode) - height;
- box_height(boxnode) = height;
- box_package_state(boxnode) = vtop_package_state;
- } else {
- box_package_state(boxnode) = vbox_package_state;
+ break;
+ case vbox_code:
+ box_package_state(boxnode) = vbox_package_state;
+ break;
+ case dbox_code:
+ box_package_state(boxnode) = dbox_package_state;
+ break;
}
}
if (dirptr) {
@@ -2779,8 +2790,10 @@ inline static halfword tex_aux_depth_correction(halfword b, const line_break_pro
{
/*tex The deficiency of space between baselines: */
halfword p;
+ halfword height = has_box_package_state(b, dbox_package_state) ? tex_aux_first_height(b) : box_height(b);
+ halfword depth = cur_list.prev_depth;
if (properties) {
- scaled d = glue_amount(properties->baseline_skip) - cur_list.prev_depth - box_height(b);
+ scaled d = glue_amount(properties->baseline_skip) - depth - height;
if (d < properties->line_skip_limit) {
p = tex_new_glue_node(properties->line_skip, line_skip_glue);
} else {
@@ -2788,7 +2801,7 @@ inline static halfword tex_aux_depth_correction(halfword b, const line_break_pro
glue_amount(p) = d;
}
} else {
- scaled d = glue_amount(baseline_skip_par) - cur_list.prev_depth - box_height(b);
+ scaled d = glue_amount(baseline_skip_par) - depth - height;
if (d < line_skip_limit_par) {
p = tex_new_param_glue_node(line_skip_code, line_skip_glue);
} else {
@@ -3234,12 +3247,12 @@ void tex_begin_box(int boxcontext, scaled shift)
boxnode = tex_copy_node(box_register(n));
break;
}
- case last_box_code:
+ /* case unpack_code: */
+ /* break; */
+ case last_box_code:
/*tex
-
If the current list ends with a box node, delete it from the list and make |boxnode|
point to it; otherwise set |boxnode := null|.
-
*/
boxnode = null;
if (abs(cur_list.mode) == mmode) {
@@ -3276,11 +3289,8 @@ void tex_begin_box(int boxcontext, scaled shift)
case vsplit_code:
{
/*tex
-
Split off part of a vertical box, make |boxnode| point to it. Here we deal with
- things like |\vsplit 13 to 100pt|.
-
- Maybe todo: just split off one line.
+ things like |\vsplit 13 to 100pt|. Maybe todo: just split off one line.
*/
halfword mode = packing_exactly ;
@@ -3342,15 +3352,23 @@ void tex_begin_box(int boxcontext, scaled shift)
boxnode = tex_get_local_boxes(local_middle_box_code);
break;
}
- default:
- {
- /*tex
+ /*tex
- Initiate the construction of an hbox or vbox, then |return|. Here is where we
- enter restricted horizontal mode or internal vertical mode, in order to make a
- box.
+ Initiate the construction of an hbox or vbox, then |return|. Here is where we
+ enter restricted horizontal mode or internal vertical mode, in order to make a
+ box. The juggling with codes and addition or subtraction was somewhat messy.
- */
+ */
+ /* case tpack_code: */
+ /* case vpack_code: */
+ /* case hpack_code: */
+ /* case dpack_code: */
+ /* case vtop_code: */
+ /* case vbox_code: */
+ /* case hbox_code: */
+ /* case dbox_code: */
+ default:
+ {
int just_pack = 0;
quarterword spec_direction = direction_unknown;
/*tex 0 or |vmode| or |hmode| */
@@ -3368,6 +3386,10 @@ void tex_begin_box(int boxcontext, scaled shift)
code = vtop_code + hmode;
just_pack = 1;
break;
+ case dpack_code:
+ code = dbox_code + hmode;
+ just_pack = 1;
+ break;
}
mode = code - vtop_code;
tex_set_saved_record(saved_full_spec_item_context, box_context_save_type, 0, boxcontext);
@@ -3392,7 +3414,7 @@ void tex_begin_box(int boxcontext, scaled shift)
if (mode == vmode) {
tex_aux_scan_full_spec(vbox_group, spec_direction, just_pack, shift);
} else {
- tex_aux_scan_full_spec(vtop_group, spec_direction, just_pack, shift);
+ tex_aux_scan_full_spec((code == dbox_code || code == dpack_code) ? dbox_group : vtop_group, spec_direction, just_pack, shift);
mode = vmode;
}
tex_normal_paragraph(vmode_par_context);
diff --git a/source/luametatex/source/tex/texpackaging.h b/source/luametatex/source/tex/texpackaging.h
index b96d31353..5fd4bf9e4 100644
--- a/source/luametatex/source/tex/texpackaging.h
+++ b/source/luametatex/source/tex/texpackaging.h
@@ -27,9 +27,11 @@ typedef enum box_codes {
tpack_code,
vpack_code,
hpack_code,
+ dpack_code,
vtop_code, /*tex |chr_code| for |\vtop| */
vbox_code,
hbox_code,
+ dbox_code,
insert_box_code,
insert_copy_code,
local_left_box_box_code,
diff --git a/source/luametatex/source/tex/texscanning.c b/source/luametatex/source/tex/texscanning.c
index e4354bba1..a78a68a23 100644
--- a/source/luametatex/source/tex/texscanning.c
+++ b/source/luametatex/source/tex/texscanning.c
@@ -3111,8 +3111,6 @@ strnumber tex_the_scanned_result(void)
push_selector;
switch (cur_val_level) {
case int_val_level:
- tex_print_int(cur_val);
- break;
case attr_val_level:
tex_print_int(cur_val);
break;
@@ -4134,7 +4132,7 @@ int tex_fract(int x, int n, int d, int max_answer)
/*tex
The main stacking logic approach is kept but I get the impression that the code is still
- suboptimal.
+ suboptimal. We also accept braced expressions.
*/
@@ -4159,6 +4157,7 @@ static void tex_aux_scan_expr(halfword level)
int error_b = 0;
/*tex top of expression stack */
halfword top = null;
+int braced = 0;
/*tex Scan and evaluate an expression |e| of type |l|. */
cur_val_level = level; /* for now */
lmt_scanner_state.expression_depth++;
@@ -4174,14 +4173,21 @@ static void tex_aux_scan_expr(halfword level)
CONTINUE:
operation = state == expression_none ? level : int_val_level; /* we abuse operation */
/*tex
-
Scan a factor |f| of type |o| or start a subexpression. Get the next non-blank non-call
token.
-
*/
+ AGAIN:
do {
tex_get_x_token();
} while (cur_cmd == spacer_cmd);
+ if (! braced) {
+ if (cur_cmd == left_brace_cmd) {
+ braced = 1;
+ goto AGAIN;
+ } else {
+ braced = 2;
+ }
+ }
if (cur_tok == left_parent_token) {
/*tex Push the expression stack and |goto restart|. */
halfword t = tex_get_node(expression_node_size);
@@ -4248,6 +4254,9 @@ static void tex_aux_scan_expr(halfword level)
operation = expression_none;
if (! top) {
if (cur_cmd != relax_cmd) {
+ if (cur_cmd == right_brace_cmd && braced == 1) {
+ break;
+ }
tex_back_input(cur_tok);
}
} else if (cur_tok != right_parent_token) {
@@ -5085,10 +5094,11 @@ static void tex_aux_scan_expression(int level)
stack_info stack = tex_aux_new_stack();
halfword operation = bit_expression_none;
int alreadygotten = 0;
+ int braced = 0;
int trace = tracing_expressions_par;
while (1) {
if (alreadygotten) {
- alreadygotten= 0;
+ alreadygotten = 0;
} else {
tex_get_x_token();
}
@@ -5096,6 +5106,21 @@ static void tex_aux_scan_expression(int level)
switch (cur_cmd) {
case relax_cmd:
goto COLLECTED;
+ case left_brace_cmd:
+ if (! braced) {
+ braced = 1;
+ continue;
+ } else {
+ goto NUMBER;
+ // goto UNEXPECTED;
+ }
+ case right_brace_cmd:
+ if (braced) {
+ goto COLLECTED;
+ } else {
+ goto NUMBER;
+ // goto UNEXPECTED;
+ }
case spacer_cmd:
continue;
case superscript_cmd:
diff --git a/source/luametatex/source/tex/textoken.c b/source/luametatex/source/tex/textoken.c
index f820e51d7..7a30b97eb 100644
--- a/source/luametatex/source/tex/textoken.c
+++ b/source/luametatex/source/tex/textoken.c
@@ -3359,6 +3359,8 @@ char *tex_tokenlist_to_tstring(int pp, int inhibit_par, int *siz, int skippreamb
*/
+/* The bin gets 1.2K smaller if we inline these. */
+
halfword tex_get_tex_dimen_register (int j, int internal) { return internal ? dimen_parameter(j) : dimen_register(j) ; }
halfword tex_get_tex_skip_register (int j, int internal) { return internal ? glue_parameter(j) : skip_register(j) ; }
halfword tex_get_tex_mu_skip_register (int j, int internal) { return internal ? mu_glue_parameter(j) : mu_skip_register(j); }
diff --git a/source/luametatex/source/tex/textypes.h b/source/luametatex/source/tex/textypes.h
index c2cd57e64..0fa80dd99 100644
--- a/source/luametatex/source/tex/textypes.h
+++ b/source/luametatex/source/tex/textypes.h
@@ -208,6 +208,7 @@ extern halfword tex_badness(
# define default_output_box 255
/*tex
+
For practical reasons all these registers were max'd to 64K but that really makes no sense for
e.g. glue and mu glue and even attributes. Imagine using more than 8K attributes: we get long
linked lists, slow lookup, lots of copying, need plenty node memory. These large ranges also
@@ -225,31 +226,29 @@ extern halfword tex_badness(
use less than in \LUATEX\ because we got rid of some parallel array so there it would have more
impact).
+ At some point we might actually drop these maxima indeed as we really don't need that many
+ if these registers and if (say) 16K is not enough, then nothing is.
+
*/
# if 1
-
# define max_toks_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x7FFF */ /* 64 64 32 */
# define max_box_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x7FFF */ /* 64 64 32 */
- # define max_int_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x7FFF */ /* 64 64 32 */
- # define max_dimen_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x7FFF */ /* 64 64 32 */
+ # define max_int_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x3FFF */ /* 64 64 16 */
+ # define max_dimen_register_index 0xFFFF /* 0xFFFF 0xFFFF 0x3FFF */ /* 64 64 16 */
# define max_attribute_register_index 0xFFFF /* 0xFFFF 0x7FFF 0x1FFF */ /* 64 32 8 */
- # define max_glue_register_index 0xFFFF /* 0xFFFF 0x7FFF 0x3FFF */ /* 64 32 8 */
+ # define max_glue_register_index 0xFFFF /* 0xFFFF 0x7FFF 0x1FFF */ /* 64 32 8 */
# define max_mu_glue_register_index 0xFFFF /* 0xFFFF 0x3FFF 0x1FFF */ /* 64 16 8 */
- # define max_em_glue_register_index 0xFFFF /* 0xFFFF 0x3FFF 0x1FFF */ /* 64 16 8 */
- # define max_ex_glue_register_index 0xFFFF /* 0xFFFF 0x3FFF 0x1FFF */ /* 64 16 8 */
# else
- # define max_toks_register_index 0x7FFF
+ # define max_toks_register_index 0x3FFF
# define max_box_register_index 0x7FFF
- # define max_int_register_index 0x7FFF
- # define max_dimen_register_index 0x7FFF
+ # define max_int_register_index 0x1FFF
+ # define max_dimen_register_index 0x1FFF
# define max_attribute_register_index 0x1FFF
- # define max_glue_register_index 0x3FFF
+ # define max_glue_register_index 0x1FFF
# define max_mu_glue_register_index 0x1FFF
- # define max_em_glue_register_index 0x1FFF
- # define max_ex_glue_register_index 0x1FFF
# endif
@@ -260,8 +259,6 @@ extern halfword tex_badness(
# define max_n_of_attribute_registers (max_attribute_register_index + 1)
# define max_n_of_glue_registers (max_glue_register_index + 1)
# define max_n_of_mu_glue_registers (max_mu_glue_register_index + 1)
-# define max_n_of_em_glue_registers (max_em_glue_register_index + 1)
-# define max_n_of_ex_glue_registers (max_ex_glue_register_index + 1)
# define max_n_of_bytecodes 65536 /* dynamic */
# define max_n_of_math_families 64
diff --git a/tex/context/base/mkii/cont-new.mkii b/tex/context/base/mkii/cont-new.mkii
index b557f5666..f1976200c 100644
--- a/tex/context/base/mkii/cont-new.mkii
+++ b/tex/context/base/mkii/cont-new.mkii
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2022.12.15 17:49}
+\newcontextversion{2022.12.21 17:10}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/mkii/context.mkii b/tex/context/base/mkii/context.mkii
index 1c6f24507..503abc26c 100644
--- a/tex/context/base/mkii/context.mkii
+++ b/tex/context/base/mkii/context.mkii
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2022.12.15 17:49}
+\edef\contextversion{2022.12.21 17:10}
%D For those who want to use this:
diff --git a/tex/context/base/mkii/mult-ro.mkii b/tex/context/base/mkii/mult-ro.mkii
index 9e9969c3d..f08babafd 100644
--- a/tex/context/base/mkii/mult-ro.mkii
+++ b/tex/context/base/mkii/mult-ro.mkii
@@ -591,6 +591,7 @@
\setinterfacevariable{temporary}{temporar}
\setinterfacevariable{test}{test}
\setinterfacevariable{text}{text}
+\setinterfacevariable{textdisplay}{textdisplay}
\setinterfacevariable{textnote}{textnote}
\setinterfacevariable{three}{trei}
\setinterfacevariable{thursday}{joi}
diff --git a/tex/context/base/mkiv/char-def.lua b/tex/context/base/mkiv/char-def.lua
index 276d0f700..1aea51318 100644
--- a/tex/context/base/mkiv/char-def.lua
+++ b/tex/context/base/mkiv/char-def.lua
@@ -64045,6 +64045,7 @@ characters.data={
linebreak="cm",
mathclass="topaccent",
mathname="vec",
+ mathstretch="h",
synonyms={ "vector" },
unicodeslot=0x20D7,
},
diff --git a/tex/context/base/mkiv/colo-ini.lua b/tex/context/base/mkiv/colo-ini.lua
index 5bfe4635c..de319be46 100644
--- a/tex/context/base/mkiv/colo-ini.lua
+++ b/tex/context/base/mkiv/colo-ini.lua
@@ -43,6 +43,7 @@ local texsetattribute = tex.setattribute
local texgetattribute = tex.getattribute
local texgetcount = tex.getcount
local texgettoks = tex.gettoks
+local texiscount = tex.iscount
local texgetmacro = tokens.getters.macro
local a_color = attributes.private('color')
@@ -82,8 +83,19 @@ local function synccolorclone(name,clone)
valid[name] = clone
end
-local function synccolorcount(name,n)
- counts[name] = n
+local synccolorcount if CONTEXTLMTXMODE > 0 then
+-- local prefix = texgetmacro("??colornumber")
+-- for k, v in next, counts do
+-- counts[k] = texiscount(prefix..k)
+-- print(k,v,counts[k])
+-- end
+ synccolorcount = function(name,n)
+ counts[name] = texiscount(n)
+ end
+else
+ synccolorcount = function(name,n)
+ counts[name] = n
+ end
end
local stack = { }
@@ -1139,7 +1151,7 @@ local setcolormodel = colors.setmodel
implement {
name = "synccolorcount",
actions = synccolorcount,
- arguments = { "string", "integer" }
+ arguments = { "string", CONTEXTLMTXMODE > 0 and "string" or "integer" }
}
implement {
diff --git a/tex/context/base/mkiv/cont-new.mkiv b/tex/context/base/mkiv/cont-new.mkiv
index ac24c71a5..e8c7f0e07 100644
--- a/tex/context/base/mkiv/cont-new.mkiv
+++ b/tex/context/base/mkiv/cont-new.mkiv
@@ -13,7 +13,7 @@
% \normalend % uncomment this to get the real base runtime
-\newcontextversion{2022.12.15 17:49}
+\newcontextversion{2022.12.21 17:10}
%D This file is loaded at runtime, thereby providing an excellent place for hacks,
%D patches, extensions and new features. There can be local overloads in cont-loc
diff --git a/tex/context/base/mkiv/context.mkiv b/tex/context/base/mkiv/context.mkiv
index 2e915c2a4..6d7353656 100644
--- a/tex/context/base/mkiv/context.mkiv
+++ b/tex/context/base/mkiv/context.mkiv
@@ -49,7 +49,7 @@
%D {YYYY.MM.DD HH:MM} format.
\edef\contextformat {\jobname}
-\edef\contextversion{2022.12.15 17:49}
+\edef\contextversion{2022.12.21 17:10}
%D Kind of special:
diff --git a/tex/context/base/mkiv/font-dsp.lua b/tex/context/base/mkiv/font-dsp.lua
index 6ed0c04d1..f0f8e50cf 100644
--- a/tex/context/base/mkiv/font-dsp.lua
+++ b/tex/context/base/mkiv/font-dsp.lua
@@ -378,7 +378,7 @@ local function getaxisscale(segments,minimum,default,maximum,user)
for i=1,#segments do
local s = segments[i]
if type(s) ~= "number" then
- report("using default axis scale")
+ -- report("using default axis scale")
return default
elseif s[1] >= default then
if s[2] == default then
@@ -3843,7 +3843,7 @@ function readers.hvar(f,fontdata,specification)
end
local tableoffset = gotodatatable(f,fontdata,"hvar",specification.variable)
if not tableoffset then
- report("no hvar table, expect problems due to messy widths")
+ -- report("no hvar table, expect problems due to messy widths")
return
end
diff --git a/tex/context/base/mkiv/meta-imp-dum.mkiv b/tex/context/base/mkiv/meta-imp-dum.mkiv
index 74a2de875..50a07f415 100644
--- a/tex/context/base/mkiv/meta-imp-dum.mkiv
+++ b/tex/context/base/mkiv/meta-imp-dum.mkiv
@@ -98,7 +98,7 @@
[placeholder]
[1=red,2=green,3=blue,4=cyan,5=magenta,6=yellow]
-\newcount\c_grph_replacement_n
+\newinteger\c_grph_replacement_n
\setupexternalfigures
[\c!reduction=0,
@@ -111,8 +111,8 @@
% \setuppalet[placeholder]%
\getpaletsize[placeholder]%
\ifnum\c_grph_replacement_n=\zerocount
- \getrandomnumber \m_grph_replacement_n\plusone\paletsize
- \global\c_grph_replacement_n \m_grph_replacement_n\relax
+ \getrandomnumber\m_grph_replacement_n\plusone\paletsize
+ \global\c_grph_replacement_n\m_grph_replacement_n\relax
\else
\global\advance\c_grph_replacement_n\plusone
\fi
diff --git a/tex/context/base/mkiv/mult-def.lua b/tex/context/base/mkiv/mult-def.lua
index 6a6c41a4c..87e325c41 100644
--- a/tex/context/base/mkiv/mult-def.lua
+++ b/tex/context/base/mkiv/mult-def.lua
@@ -19193,6 +19193,9 @@ return {
["pe"]="متن",
["ro"]="text",
},
+ ["textdisplay"]={
+ ["en"]="textdisplay",
+ },
["textnote"]={
["en"]="textnote",
["fr"]="notetexte",
diff --git a/tex/context/base/mkiv/mult-low.lua b/tex/context/base/mkiv/mult-low.lua
index d213bf7d7..ac4ce2e91 100644
--- a/tex/context/base/mkiv/mult-low.lua
+++ b/tex/context/base/mkiv/mult-low.lua
@@ -14,7 +14,7 @@ return {
"zerocount", "minusone", "minustwo", "plusone", "plustwo", "plusthree", "plusfour", "plusfive",
"plussix", "plusseven", "pluseight", "plusnine", "plusten", "pluseleven", "plustwelve", "plussixteen",
"plusfifty", "plushundred", "plusonehundred", "plustwohundred", "plusfivehundred",
- "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "maxcardminusone",
+ "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "maxcardminusone", "maxiterator",
"zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxcount", "maxdimen", "scaledpoint", "thousandpoint",
"points", "halfpoint",
"zeroskip", "centeringskip", "stretchingskip", "shrinkingskip",
@@ -262,6 +262,9 @@ return {
"newcount", "newdimen", "newskip", "newmuskip", "newbox", "newtoks", "newread", "newwrite", "newmarks", "newinsert", "newattribute", "newif",
"newlanguage", "newfamily", "newfam", "newhelp", -- not used
--
+ "newinteger", "newdimension", "newgluespec", "newmugluespec",
+ "aliasinteger", "aliasdimension",
+ --
"then",
"begcsname",
--
@@ -307,8 +310,8 @@ return {
--
"ruledhss", "ruledhfil", "ruledhfill", "ruledhfilll", "ruledhfilneg", "ruledhfillneg", "normalhfillneg", "normalhfilllneg",
"ruledvss", "ruledvfil", "ruledvfill", "ruledvfilll", "ruledvfilneg", "ruledvfillneg", "normalvfillneg", "normalvfilllneg",
- "ruledhbox", "ruledvbox", "ruledvtop", "ruledvcenter", "ruledmbox",
- "ruledhpack", "ruledvpack", "ruledtpack",
+ "ruledhbox", "ruledvbox", "ruledvtop", "ruleddbox", "ruledvcenter", "ruledmbox",
+ "ruledhpack", "ruledvpack", "ruledtpack", "ruleddpack",
"ruledhskip", "ruledvskip", "ruledkern", "ruledmskip", "ruledmkern",
"ruledhglue", "ruledvglue", "normalhglue", "normalvglue",
"ruledpenalty",
diff --git a/tex/context/base/mkiv/mult-prm.lua b/tex/context/base/mkiv/mult-prm.lua
index 2a73d765b..8285b26be 100644
--- a/tex/context/base/mkiv/mult-prm.lua
+++ b/tex/context/base/mkiv/mult-prm.lua
@@ -315,11 +315,13 @@ return {
"currentloopiterator",
"currentloopnesting",
"currentmarks",
+ "dbox",
"defcsname",
"detokenized",
"dimensiondef",
"dimexpression",
"directlua",
+ "dpack",
"edefcsname",
"efcode",
"endlocalcontrol",
@@ -796,6 +798,7 @@ return {
"accent",
"adjdemerits",
"advance",
+ "advanceby",
"afterassignment",
"aftergroup",
"atop",
@@ -840,6 +843,7 @@ return {
"displaywidowpenalty",
"displaywidth",
"divide",
+ "divideby",
"doublehyphendemerits",
"dp",
"dump",
@@ -968,6 +972,7 @@ return {
"moveright",
"mskip",
"multiply",
+ "multiplyby",
"muskip",
"muskipdef",
"newlinechar",
diff --git a/tex/context/base/mkiv/status-files.pdf b/tex/context/base/mkiv/status-files.pdf
index 8f7009b07..fe10b5bff 100644
--- a/tex/context/base/mkiv/status-files.pdf
+++ b/tex/context/base/mkiv/status-files.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/status-lua.pdf b/tex/context/base/mkiv/status-lua.pdf
index 36e22cc39..bd12d076b 100644
--- a/tex/context/base/mkiv/status-lua.pdf
+++ b/tex/context/base/mkiv/status-lua.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/syst-ini.mkiv b/tex/context/base/mkiv/syst-ini.mkiv
index dd3e7c822..ae1978eb6 100644
--- a/tex/context/base/mkiv/syst-ini.mkiv
+++ b/tex/context/base/mkiv/syst-ini.mkiv
@@ -1257,4 +1257,8 @@
\newcount\autoparagraphmode
\fi
+\let\advanceby \advance
+\let\multiplyby\multiply
+\let\divideby \divide
+
\protect \endinput
diff --git a/tex/context/base/mkxl/anch-bar.mkxl b/tex/context/base/mkxl/anch-bar.mkxl
index 23a009e97..f99e61428 100644
--- a/tex/context/base/mkxl/anch-bar.mkxl
+++ b/tex/context/base/mkxl/anch-bar.mkxl
@@ -59,10 +59,10 @@
\installcommandhandler \??sidebar {sidebar} \??sidebar
-\newcount\c_anch_sidebars_n
-\newcount\c_anch_sidebars_current % local
-\newdimen\d_anch_sidebars_distance
-\newcount\c_anch_sidebars_level
+\newinteger \c_anch_sidebars_n
+\newinteger \c_anch_sidebars_current % local
+\newdimension\d_anch_sidebars_distance
+\newinteger \c_anch_sidebars_level
% \setupMPvariables
% [mpos:sidebar]
@@ -86,8 +86,8 @@
\permanent\tolerant\protected\def\startsidebar[#1]#*[#2]%
{\bgroup
\dontleavehmode
- \advance\c_anch_sidebars_level\plusone
- \global\advance\c_anch_sidebars_n\plusone
+ \advanceby\c_anch_sidebars_level\plusone
+ \global\advanceby\c_anch_sidebars_n\plusone
\c_anch_sidebars_current\c_anch_sidebars_n\relax % relax needed
\ifhastok={#1}%
\edef\currentsidebar{\the\c_anch_sidebars_level}%
@@ -103,16 +103,16 @@
\ifempty\m_level
\ifnum\c_anch_sidebars_level=\plusone
\ifzeropt\scratchdimen
- \advance\d_anch_sidebars_distance\scratchdistance\relax
+ \advanceby\d_anch_sidebars_distance\scratchdistance\relax
\else
\d_anch_sidebars_distance\scratchdimen
\fi
\else
- \advance\d_anch_sidebars_distance\scratchdistance\relax
+ \advanceby\d_anch_sidebars_distance\scratchdistance\relax
\fi
\orelse\ifnum\m_level=\plusone
\ifzeropt\scratchdimen
- \advance\d_anch_sidebars_distance\scratchdistance\relax
+ \advanceby\d_anch_sidebars_distance\scratchdistance\relax
\else
\d_anch_sidebars_distance\scratchdimen
\fi
diff --git a/tex/context/base/mkxl/anch-bck.mklx b/tex/context/base/mkxl/anch-bck.mklx
index 2eeebd547..ea6999f45 100644
--- a/tex/context/base/mkxl/anch-bck.mklx
+++ b/tex/context/base/mkxl/anch-bck.mklx
@@ -31,14 +31,14 @@
% Paragraph positions:
-\newcount\c_anch_backgrounds_text_n
+\newinteger\c_anch_backgrounds_text_n
\def\v_anch_backgrounds_text_current {tbg:0}
\def\v_anch_backgrounds_anchor_current_b{b:\v_anch_backgrounds_text_current}
\def\v_anch_backgrounds_anchor_current_e{e:\v_anch_backgrounds_text_current}
\def\anch_backgrounds_text_initialize_next
- {\global\advance\c_anch_backgrounds_text_n\plusone
+ {\global\advanceby\c_anch_backgrounds_text_n\plusone
\edef\v_anch_backgrounds_text_current{tbg:\number\c_anch_backgrounds_text_n}}
% The first position can be used in the middle of a paragraph in which case we're
@@ -57,7 +57,7 @@
%D Some MP
-\newcount\MPparcounter
+\newinteger\MPparcounter
\permanent\def\MPself {\MPvar{self}}
\permanent\def\MPbself {b:\MPvar{self}}
@@ -89,7 +89,7 @@
% \readfile{ward}{}{}
% \stoptextbackground
-\newcount\c_anch_backgrounds_text_level
+\newinteger\c_anch_backgrounds_text_level
\installcorenamespace{textbackground}
\installcorenamespace{textbackgroundlevel}
@@ -121,14 +121,14 @@
% ugly hack to register usage
-\newcount \c_anch_backgrounds_text_count
-\newcount \c_anch_backgrounds_text_check
+\newinteger \c_anch_backgrounds_text_count
+\newinteger \c_anch_backgrounds_text_check
\newconstant\c_anch_backgrounds_text_state
\permanent\tolerant\protected\def\starttextbackground[#tag]#spacer[#settings]%
{\begingroup
- \global\advance\c_anch_backgrounds_text_count\plusone
- \advance\c_anch_backgrounds_text_level\plusone
+ \global\advanceby\c_anch_backgrounds_text_count\plusone
+ \advanceby\c_anch_backgrounds_text_level\plusone
\def\currenttextbackground{#tag}%
\anch_backgrounds_text_initialize_next
\ifparameter#settings\or
@@ -255,7 +255,7 @@
{\anch_backgrounds_epos
\carryoverpar\endgroup}
-\newskip\textbackgroundskip
+\newgluespec\textbackgroundskip
% maybe we should have a resetter for such compensation struts
@@ -311,7 +311,7 @@
\removelastskip % new
\spac_helpers_assign_skip\textbackgroundskip{\textbackgroundparameter\c!bottomoffset}%
\ifdim\lastskip>\zeropoint
- \advance\textbackgroundskip-\lastskip
+ \advanceby\textbackgroundskip-\lastskip
\fi
\ifgridsnapping
\orelse\ifdim\textbackgroundskip>\zeropoint
@@ -392,10 +392,10 @@
\newconditional\c_strc_floats_mark_as_free
\newconditional\c_strc_floats_trace_free
\newconstant \c_free_offset_kind
-\newdimen \d_free_offset_left
-\newdimen \d_free_offset_right
-\newdimen \d_free_offset_top
-\newdimen \d_free_offset_bottom
+\newdimension \d_free_offset_left
+\newdimension \d_free_offset_right
+\newdimension \d_free_offset_top
+\newdimension \d_free_offset_bottom
\installtextracker{floats.freeregion}
{\settrue \c_strc_floats_trace_free}
diff --git a/tex/context/base/mkxl/anch-box.mkxl b/tex/context/base/mkxl/anch-box.mkxl
index 9885123c2..d480b2214 100644
--- a/tex/context/base/mkxl/anch-box.mkxl
+++ b/tex/context/base/mkxl/anch-box.mkxl
@@ -19,29 +19,19 @@
anch_box_arrows_draw ;
\stopMPpositiongraphic
-% \tolerant\permanent\protected\def\connectboxanchors[#1]#*[#2]#*[#3]#*[#4]#*#:#5#6%
-% {\begingroup
-% \defineboxanchor[#5]%
-% \setboxanchor[#5][#1][#3]\hpack{\xypos{\namespacedboxanchor{#5}}}%
-% \ifparameter#3\or\setupboxanchorcontent[#1][#3]\fi
-% \defineboxanchor[#6]%
-% \setboxanchor[#6][#2][#4]\hpack{\xypos{\namespacedboxanchor{#6}}}%
-% \ifparameter#4\or\setupboxanchorcontent[#1][#4]\fi
-% %\startpositionoverlay{text-1}% will become configurable region
-% \startpositionoverlay{text+1}% will become configurable region
-% \setMPpositiongraphic
-% {\namespacedboxanchor{#5}}%
-% {\namedboxanchorcontentparameter{#1}\c!mp}%
-% {from=\namespacedboxanchor{#5},%
-% to=\namespacedboxanchor{#6},%
-% distance={\namedboxanchorcontentparameter{#1}\c!distance},%
-% dashtype={\namedboxanchorcontentparameter{#1}\c!dash},%
-% alternative={\namedboxanchorcontentparameter{#1}\c!alternative},%
-% text={\namedboxanchorcontentparameter{#1}\c!text},%
-% rulethickness={\namedboxanchorcontentparameter{#1}\c!rulethickness},%
-% linecolor=\namedboxanchorcontentparameter{#1}{\c!rulecolor}}%
-% \stoppositionoverlay
-% \endgroup}
+\def\anch_box_connect_parameters#1#2%
+ {span=no,
+ from=\boxanchorposone,%
+ to=\boxanchorpostwo,%
+ distance={\namedboxanchorcontentparameter{#1}\c!distance},%
+ dashtype={\namedboxanchorcontentparameter{#1}\c!dash},%
+ arrow={\namedboxanchorcontentparameter{#1}\c!arrow},%
+ alternative={\namedboxanchorcontentparameter{#1}\c!alternative},%
+ text={\namedboxanchorcontentparameter{#1}\c!text},%
+ rulethickness={\namedboxanchorcontentparameter{#1}\c!rulethickness},%
+ linecolor=\namedboxanchorcontentparameter{#1}{\c!rulecolor},
+ #2}
+
\tolerant\permanent\protected\def\connectboxanchors[#1]#*[#2]#*[#3]#*[#4]#*#:#5#6%
{\begingroup
%
@@ -69,19 +59,8 @@
\setMPpositiongraphic
{\boxanchorposone}%
{\namedboxanchorcontentparameter{#1}\c!mp}%
- {span=no,
- from=\boxanchorposone,%
- to=\boxanchorpostwo,%
- % distance={\namedboxanchorcontentparameter{#1}\c!distance},%
- dashtype={\namedboxanchorcontentparameter{#1}\c!dash},%
- % arrow={\namedboxanchorcontentparameter{#1}\c!arrow},%
- % alternative={\namedboxanchorcontentparameter{#1}\c!alternative},%
- % text={\namedboxanchorcontentparameter{#1}\c!text},%
- % rulethickness={\namedboxanchorcontentparameter{#1}\c!rulethickness},%
- linecolor=\namedboxanchorcontentparameter{#1}{\c!rulecolor},
- #3}%
- %
- \stoppositionoverlay
+ {\anch_box_connect_parameters{#1}{#3}}%
+ \stoppositionoverlay
}%
\ifcstok{\namedboxanchorcontentparameter{#1}\c!page}\v!yes
\normalexpanded{%
@@ -89,17 +68,7 @@
\setMPpositiongraphic
{\boxanchorpostwo}%
{\namedboxanchorcontentparameter{#1}\c!mp}%
- {span=yes,
- from=\boxanchorposone,%
- to=\boxanchorpostwo,%
- % distance={\namedboxanchorcontentparameter{#1}\c!distance},%
- dashtype={\namedboxanchorcontentparameter{#1}\c!dash},%
- % arrow={\namedboxanchorcontentparameter{#1}\c!arrow},%
- % alternative={\namedboxanchorcontentparameter{#1}\c!alternative},%
- % text={\namedboxanchorcontentparameter{#1}\c!text},%
- % rulethickness={\namedboxanchorcontentparameter{#1}\c!rulethickness},%
- linecolor=\namedboxanchorcontentparameter{#1}{\c!rulecolor}%
- #3}%
+ {\anch_box_connect_parameters{#1}{#3}}%
\stoppositionoverlay
}%
\fi
diff --git a/tex/context/base/mkxl/anch-pgr.mkxl b/tex/context/base/mkxl/anch-pgr.mkxl
index 5071f16d5..10c66b665 100644
--- a/tex/context/base/mkxl/anch-pgr.mkxl
+++ b/tex/context/base/mkxl/anch-pgr.mkxl
@@ -116,8 +116,8 @@
%D stick to just one anchor and derive the head and tail anchors from this one. We
%D set these anchors before and after each page.
-\newdimen\c_anch_page_width
-\newdimen\c_anch_page_height
+\newdimension\c_anch_page_width
+\newdimension\c_anch_page_height
\protected\def\anch_positions_register_page#1% this one is flushed first ! ... can't we avoid this one
{\ifpositioning\ifcase\realpageno\or
diff --git a/tex/context/base/mkxl/anch-pos.mkxl b/tex/context/base/mkxl/anch-pos.mkxl
index 75e8f87d7..ecb2091c6 100644
--- a/tex/context/base/mkxl/anch-pos.mkxl
+++ b/tex/context/base/mkxl/anch-pos.mkxl
@@ -19,14 +19,13 @@
\unprotect
-\newcount\c_anch_column % will be delegated to lua
-\newcount\c_anch_text % will be delegated to lua
-\newcount\c_anch_free
-\newtoks \t_anch_positions_tracers
-\newcount\c_anch_positions_paragraph
-
-\newbox \b_anch_position
-\newif \ifpositioning % sort of public
+\newinteger\c_anch_column % will be delegated to lua
+\newinteger\c_anch_text % will be delegated to lua
+\newinteger\c_anch_free
+\newtoks \t_anch_positions_tracers
+\newinteger\c_anch_positions_paragraph
+\newbox \b_anch_position
+\newif \ifpositioning % sort of public
\registerctxluafile{anch-pos}{autosuffix}
@@ -291,8 +290,8 @@
\permanent\def\textanchor {text:\the\realpageno}
\permanent\def\regionanchor{region:0}
-% see top: \newcount\c_anch_column % will be delegated to lua
-% see top: \newcount\c_anch_text % will be delegated to lua
+% see top: \newinteger\c_anch_column % will be delegated to lua
+% see top: \newinteger\c_anch_text % will be delegated to lua
% beware we need to pass \somethingexpanded or { }
@@ -303,7 +302,7 @@
% that many variants: text, page, textarea, columnarea, free.
\protected\def\anch_mark_column_box#1#2% box n
- {\global\advance\c_anch_column\plusone
+ {\global\advanceby\c_anch_column\plusone
\clf_markregionboxtaggedn#1{columnarea}\c_anch_column#2\relax} % extra height
\protected\def\anch_mark_region_box % auto region:index
@@ -320,7 +319,7 @@
\protected\def\anch_mark_flow_box#1% will be extended / renamed
{\hpack\bgroup
- \global\advance\c_anch_text\plusone
+ \global\advanceby\c_anch_text\plusone
\clf_markregionboxtagged#1{textarea}\c_anch_text % will become flow:
\box#1%
\egroup}
@@ -329,7 +328,7 @@
{\clf_markregionboxtagged#1{#2}#3\relax}
\protected\def\anch_mark_flow_only#1% will be extended / renamed
- {\global\advance\c_anch_text\plusone
+ {\global\advanceby\c_anch_text\plusone
\clf_markregionboxcorrected#1{textarea}\c_anch_text}% will become flow:
\protected\def\anch_make_page_box#1% maybe like text
@@ -345,10 +344,10 @@
\expandafter\gobblesixarguments
\fi}
-% see top: \newcount\c_anch_free
+% see top: \newinteger\c_anch_free
\protected\def\anch_mark_tagged_box_free_yes#1#2#3#4#5#6% only needed when positions
- {\global\advance\c_anch_free\plusone % could be done at the lua end
+ {\global\advanceby\c_anch_free\plusone % could be done at the lua end
\clf_markregionboxtaggedkind
#1%
{free}%
@@ -417,8 +416,8 @@
%D can keep track of them. This mechanism is activated automatically based on
%D information collected in the previous pass.
-% see top: \newtoks \t_anch_positions_tracers
-% see top: \newcount\c_anch_positions_paragraph
+% see top: \newtoks \t_anch_positions_tracers
+% see top: \newinteger\c_anch_positions_paragraph
\permanent\protected\def\tracepositions
{\the\t_anch_positions_tracers}
diff --git a/tex/context/base/mkxl/anch-snc.mkxl b/tex/context/base/mkxl/anch-snc.mkxl
index dcf2c86cb..a2df714b7 100644
--- a/tex/context/base/mkxl/anch-snc.mkxl
+++ b/tex/context/base/mkxl/anch-snc.mkxl
@@ -136,14 +136,14 @@
\permanent\protected\def\definesyncpositions[#1]%
{\ifcsname\??syncposcounter:#1\endcsname \else
- \expandafter\newcount\csname\??syncposcounter:#1\endcsname
+ \expandafter\newinteger\csname\??syncposcounter:#1\endcsname
\fi}
\permanent\tolerant\protected\def\syncposition[#1]#*[#2]%
{\dontleavehmode
\ifcsname\??syncposcounter:#1\endcsname
\let\c_sync_n\lastnamedcs
- \global\advance\c_sync_n\plusone
+ \global\advanceby\c_sync_n\plusone
\enabletextarearegistration
\setpositionplus{\s!syncpos:#1:\the\c_sync_n}{#2}\hpack{\strut}%
\else
diff --git a/tex/context/base/mkxl/anch-tab.mkxl b/tex/context/base/mkxl/anch-tab.mkxl
index 1c89666dc..94e021653 100644
--- a/tex/context/base/mkxl/anch-tab.mkxl
+++ b/tex/context/base/mkxl/anch-tab.mkxl
@@ -18,7 +18,7 @@
\unprotect
-\newcount\c_anch_tabs
+\newinteger\c_anch_tabs
\protected\def\tabl_tabulate_hook_b
{\iftrialtypesetting\else
@@ -54,7 +54,7 @@
% \appendtoks \registerparoptions \to \everypar
\appendtoks
- \global\advance\c_anch_tabs\plusone
+ \global\advanceby\c_anch_tabs\plusone
\to \everytabulate
% for text backgrounds
@@ -74,7 +74,7 @@
%D references to the graphics involved. Each table has its own namespace.
\newconditional\tablehaspositions
-\newcount \noftabpositions
+\newinteger \noftabpositions
\newtoks \posXCtoks
\protected\def\anch_tabulate_bpos{\bpos}
@@ -195,7 +195,7 @@
\box\scratchbox}
\appendtoks
- \global\advance\noftabpositions\plusone
+ \global\advanceby\noftabpositions\plusone
\global\setfalse\tablehaspositions
\to \everytabulate
@@ -274,7 +274,7 @@
\permanent\def\normalTABLEquote {\unskip\!ttRightGlue&\omit\tablepos&} % "
\appendtoks
- \global\advance\noftabpositions\plusone
+ \global\advanceby\noftabpositions\plusone
\global\setfalse\tablehaspositions
\to \everytable
diff --git a/tex/context/base/mkxl/attr-ini.mkxl b/tex/context/base/mkxl/attr-ini.mkxl
index e3538cf3d..ce21be081 100644
--- a/tex/context/base/mkxl/attr-ini.mkxl
+++ b/tex/context/base/mkxl/attr-ini.mkxl
@@ -23,16 +23,16 @@
\installcorenamespace{attributepickup}
\permanent\protected\def\pushattribute#1%
- {\global\advance\csname\??attributestack\string#1\endcsname\plusone
+ {\global\advanceby\csname\??attributestack\string#1\endcsname\plusone
\gdefcsname\??attributestack\string#1:\number\csname\??attributestack\string#1\endcsname\endcsname{\number\attribute#1}}
\permanent\protected\def\popattribute#1%
{\attribute#1\csname\??attributestack\string#1:\number\csname\??attributestack\string#1\endcsname\endcsname\relax
- \global\advance\csname\??attributestack\string#1\endcsname\minusone}
+ \global\advanceby\csname\??attributestack\string#1\endcsname\minusone}
\permanent\protected\def\installattributestack#1%
{\ifcsname\??attributestack\string#1\endcsname \else
- \expandafter\newcount\csname\??attributestack\string#1\endcsname
+ \expandafter\newinteger\csname\??attributestack\string#1\endcsname
\fi}
\newtoks \t_attr_list_global
diff --git a/tex/context/base/mkxl/back-exp.mkxl b/tex/context/base/mkxl/back-exp.mkxl
index 3c8c23c59..ff0602aee 100644
--- a/tex/context/base/mkxl/back-exp.mkxl
+++ b/tex/context/base/mkxl/back-exp.mkxl
@@ -15,6 +15,8 @@
\writestatus{loading}{ConTeXt Backend Macros / XML export}
+\newinteger\tagparcounter
+
\registerctxluafile{back-exp} {autosuffix}
\registerctxluafile{back-exp-imp-tag}{autosuffix}
\registerctxluafile{back-exp-imp-mth}{autosuffix}
@@ -49,8 +51,6 @@
\expandafter\ctxcommand
\fi}
-\newcount\tagparcounter
-
\permanent\protected\lettonothing\dotagsetparcounter
\permanent\protected\lettonothing\doresetparcounter
@@ -158,7 +158,7 @@
\appendtoks
\enforced\permanent\protected\def\dotagsetparcounter
- {\global\advance\tagparcounter\plusone\c_attr_taggedpar\tagparcounter}%
+ {\global\advanceby\tagparcounter\plusone\c_attr_taggedpar\tagparcounter}%
\enforced\permanent\protected\def\doresetparcounter
{\c_attr_taggedpar\attributeunsetvalue}%
\to \everyenableelements
diff --git a/tex/context/base/mkxl/bibl-bib.mkxl b/tex/context/base/mkxl/bibl-bib.mkxl
index d8ab26d28..ffdb5b954 100644
--- a/tex/context/base/mkxl/bibl-bib.mkxl
+++ b/tex/context/base/mkxl/bibl-bib.mkxl
@@ -344,8 +344,8 @@
% variables
-\ifdefined\bibtexblock \else \newcount\bibtexblock \fi \bibtexblock\plusone
-\ifdefined\bibtexcounter \else \newcount\bibtexcounter \fi
+\ifdefined\bibtexblock \else \newinteger\bibtexblock \fi \bibtexblock\plusone
+\ifdefined\bibtexcounter \else \newinteger\bibtexcounter \fi
\newtoks \everysetupbibtexpublications
\newtoks \everysetupbibtexcitations
@@ -551,7 +551,7 @@
\the\everysetupbibtexlistplacement
\forgetall
\typesetbibtexlist
- \global\advance\bibtexblock\plusone}
+ \global\advanceby\bibtexblock\plusone}
\setvalue{\??pb:\c!numbering:\v!short}#1% todo var s -> short tag
{\bibtexlistnumberbox{\bibtexpublicationsparameter\c!numbercommand{\bibtexgetshort\currentpublicationtag}}}
@@ -580,7 +580,7 @@
\fi
\to \everysetupbibtexlistplacement
-\newdimen\bibtexnumberwidth
+\newdimension\bibtexnumberwidth
\def\bibtexlistnumberbox{\hbox \ifcase\bibtexnumberwidth\else to \bibtexnumberwidth\fi}
@@ -652,7 +652,7 @@
\def\dotypesetbibtexpublication
{\doifelsebibreferencefound\currentbibtexsessiontag
- {\global\advance\bibtexcounter\plusone
+ {\global\advanceby\bibtexcounter\plusone
\ctxlua{bibtex.hacks.registerplaced("\currentbibtexsessiontag")}%
\let\currentlist\currentbibtexsession
\let\currentlistentrynumber\bibtexcounter
diff --git a/tex/context/base/mkxl/bibl-tra.mkxl b/tex/context/base/mkxl/bibl-tra.mkxl
index fc21724b3..d197e8ea4 100644
--- a/tex/context/base/mkxl/bibl-tra.mkxl
+++ b/tex/context/base/mkxl/bibl-tra.mkxl
@@ -202,8 +202,8 @@
\installstructurelistprocessor{pubs:userdata}%
{\ctxlua{bibtex.hacks.add(structures.lists.uservalue("\currentlist",\currentlistindex,"bibref"),\currentlistindex)}}
-\ifdefined\bibtexblock \else \newcount\bibtexblock \fi \bibtexblock\plusone
-\ifdefined\bibtexcounter \else \newcount\bibtexcounter \fi
+\ifdefined\bibtexblock \else \newinteger\bibtexblock \fi \bibtexblock\plusone
+\ifdefined\bibtexcounter \else \newinteger\bibtexcounter \fi
%D \macros{bibdoif,bibdoifnot,bibdoifelse}
%D
@@ -517,9 +517,9 @@
%D Another level of indirection is needed to control the typesetting of all of these
%D arguments.
-\newcount\etallimitcounter
-\newcount\etaldisplaycounter
-\newcount\todocounter
+\newinteger\etallimitcounter
+\newinteger\etaldisplaycounter
+\newinteger\todocounter
\protected\def\specialbibinsert#1#2#3#4#5%
{\bgroup
@@ -559,7 +559,7 @@
%D \#3 = commacommand containing authors
\protected\def\doprocessauthoritem#1#2#3%
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\ifnum\numexpr\scratchcounter-\plusone\relax<#2\relax
\publicationlistparameter{#1}#3%
\ifnum\scratchcounter=#2\relax
@@ -855,7 +855,7 @@
\inpublisttrue
\typesetpubslist
\inpublistfalse
- \global\advance\bibtexblock\plusone}
+ \global\advanceby\bibtexblock\plusone}
%D \subsubject{What's in a publication}
%D
@@ -878,7 +878,7 @@
\protected\def\doplacepublicationindeed#1%
{\doifelsebibreferencefound{#1}
- {\global\advance\bibtexcounter\plusone
+ {\global\advanceby\bibtexcounter\plusone
\def\currentpublicationkey{#1}%
\ctxlua{bibtex.hacks.registerplaced("#1")}%
\def\currentlist{pubs}%
@@ -1088,7 +1088,7 @@
\expandafter\processcommalist\expandafter[\thebibauthors]\dodobibauthoryear}
\protected\def\dodobibauthoryear#1%
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\edef\wantednumber{\the\scratchcounter}%
\getfromcommacommand[\thebibyears][\wantednumber]%
\expandafter\def\expandafter\currentbibyear\expandafter{\commalistelement}%
@@ -1114,13 +1114,13 @@
\handlemultiplebibauthors{\commalistsize}{#1}%
\fi}
-\newcount\citescratchcounter
+\newinteger\citescratchcounter
\protected\def\handlemultiplebibauthors#1#2%
{\citescratchcounter\zerocount
\lettonothing\currentbibauthor
\protected\def\bibprocessauthoritem##1%
- {\advance\citescratchcounter\plusone
+ {\advanceby\citescratchcounter\plusone
\ifnum \citescratchcounter=#1\relax
\edef\currentbibauthor{\currentbibauthor##1}%
\orelse\ifnum\numexpr\citescratchcounter+\plusone\relax=#1\relax
@@ -1196,8 +1196,8 @@
%D Two temporary counters. One of these two can possibly be replaced by \type
%D {\scratchcounter}.
-\newcount\bibitemcounter
-\newcount\bibitemwanted
+\newinteger\bibitemcounter
+\newinteger\bibitemwanted
%D The first portion is simple enough: if this is the very first author it is quite
%D straightforward to add it. \type {\bibitemcounter} and \type {\bibitemwanted} are
@@ -1223,12 +1223,12 @@
%D setup properly to insert the year info.
\protected\def\docomparemyauthor#1%
- {\global\advance\bibitemwanted \plusone
+ {\global\advanceby\bibitemwanted \plusone
\def\mytempc{#1}%
\ifx\mytempc\myauthor
\quitcommalist
\orelse\ifnum\bibitemwanted=\bibitemcounter\relax
- \global\advance\bibitemwanted \plusone
+ \global\advanceby\bibitemwanted \plusone
\global\bibitemcounter\bibitemwanted\relax
\expandafter\doglobal\expandafter\robustaddtocommalist\expandafter{{\myauthor}}\thebibauthors
\fi}
diff --git a/tex/context/base/mkxl/buff-ini.mkxl b/tex/context/base/mkxl/buff-ini.mkxl
index d561841ff..e7b243374 100644
--- a/tex/context/base/mkxl/buff-ini.mkxl
+++ b/tex/context/base/mkxl/buff-ini.mkxl
@@ -120,12 +120,12 @@
\c!after=,
\c!define=\v!yes]
-\newcount\c_buff_n_of_defined
+\newinteger\c_buff_n_of_defined
\mutable\let\currentdefinedbuffer\s!dummy
\appendtoks
- \global\advance\c_buff_n_of_defined\plusone
+ \global\advanceby\c_buff_n_of_defined\plusone
\setexpandedbufferparameter\c!number{\number\c_buff_n_of_defined}%
\edef\currentdefinedbuffer{def-\number\c_buff_n_of_defined}%
\ifcstok{\bufferparameter\c!define}\v!yes
@@ -245,7 +245,7 @@
\appendtoks
\ifcsname\e!stop\currentsavebuffer\endcsname\else
\definebuffer[\currentsavebuffer]%
- \expandafter\newcount\csname\??savebuffercounter\currentsavebuffer\endcsname
+ \expandafter\newinteger\csname\??savebuffercounter\currentsavebuffer\endcsname
\protected\edefcsname\e!stop\currentsavebuffer\endcsname{\buff_stop_save_buffer{\currentsavebuffer}}%
\setsavebufferparameter\c!file{\currentsavebuffer.tex}%
\fi
@@ -253,7 +253,7 @@
\protected\def\buff_stop_save_buffer#1%
{\edef\currentsavebuffer{#1}%
- \global\advance\csname\??savebuffercounter\currentsavebuffer\endcsname\plusone
+ \global\advanceby\csname\??savebuffercounter\currentsavebuffer\endcsname\plusone
\clf_savebuffer % will become key/value
{\thedefinedbuffer{\currentsavebuffer}}%
{\savebufferparameter\c!file}%
diff --git a/tex/context/base/mkxl/buff-ver.mkxl b/tex/context/base/mkxl/buff-ver.mkxl
index 6fef148f1..28ffe4988 100644
--- a/tex/context/base/mkxl/buff-ver.mkxl
+++ b/tex/context/base/mkxl/buff-ver.mkxl
@@ -915,11 +915,11 @@
% line numbering, keep broken lines together
-\newcount\nofverbatimlines
+\newinteger\nofverbatimlines
\protected\def\buff_verbatim_begin_of_line
{\ifconditional\verbatimnumberinglines
- \global\advance\nofverbatimlines\plusone
+ \global\advanceby\nofverbatimlines\plusone
\c_attr_verbatimline\nofverbatimlines
\fi
\noindent
@@ -947,8 +947,8 @@
% hooks (todo: frozen):
-\newcount \c_buff_verbatim_noflines
-\newcount \c_buff_verbatim_current
+\newinteger \c_buff_verbatim_noflines
+\newinteger \c_buff_verbatim_current
\newconditional\c_buff_optimize_linebreaks
\permanent\protected\def\doverbatimspace {\obeyedspace}
@@ -959,10 +959,10 @@
\permanent\protected\def\doinlineverbatimnewline {\obeyedspace}
\permanent\protected\def\doinlineverbatimemptyline {\obeyedspace}
-\permanent\protected\def\dodisplayverbatimstart {\advance\c_buff_verbatim_current\plusone
+\permanent\protected\def\dodisplayverbatimstart {\advanceby\c_buff_verbatim_current\plusone
\buff_verbatim_begin_of_line}
\permanent\protected\def\dodisplayverbatimstop {\buff_verbatim_end_of_line}
-\permanent\protected\def\dodisplayverbatimbeginline{\advance\c_buff_verbatim_current\plusone
+\permanent\protected\def\dodisplayverbatimbeginline{\advanceby\c_buff_verbatim_current\plusone
\buff_verbatim_begin_of_line}
\permanent\protected\def\dodisplayverbatimnewline {\buff_verbatim_end_of_line
\par
diff --git a/tex/context/base/mkxl/catc-ini.mkxl b/tex/context/base/mkxl/catc-ini.mkxl
index 6e40ca822..d8c4da040 100644
--- a/tex/context/base/mkxl/catc-ini.mkxl
+++ b/tex/context/base/mkxl/catc-ini.mkxl
@@ -47,14 +47,14 @@
\installsystemnamespace{catcodetablet}
\installsystemnamespace{catcodetablen}
-\newcount\c_syst_catcodes_n \c_syst_catcodes_n\zerocount % 0 = signal, so advance before allocate
+\newinteger\c_syst_catcodes_n \c_syst_catcodes_n\zerocount % 0 = signal, so advance before allocate
-% \newcount\c_syst_catcodes_a
-% \newcount\c_syst_catcodes_b
-% \newcount\c_syst_catcodes_c
+%newinteger\c_syst_catcodes_a
+%newinteger\c_syst_catcodes_b
+%newinteger\c_syst_catcodes_c
\permanent\protected\def\newcatcodetable#1% we could move the cctdefcounter to lua
- {\global\advance\c_syst_catcodes_n\plusone
+ {\global\advanceby\c_syst_catcodes_n\plusone
\gdefcsname\??catcodetablen\number\c_syst_catcodes_n\endcsname{\string#1}% logging
\immutable\integerdef#1\c_syst_catcodes_n
\ctxlua{catcodes.register("\expandafter\gobbleoneargument\string#1",\number#1)}}
@@ -262,10 +262,10 @@
%D pop catcode tables and as we keep track of used tables users seldom need to deal
%D with this themselves.
-\newcount\c_syst_catcodes_level
+\newinteger\c_syst_catcodes_level
\permanent\protected\def\pushcatcodetable
- {\advance\c_syst_catcodes_level\plusone
+ {\advanceby\c_syst_catcodes_level\plusone
\syst_catcodes_trace_push
\expandafter\integerdef\csname\??catcodetablet\number\c_syst_catcodes_level\endcsname\currentcatcodetable}
@@ -275,7 +275,7 @@
\else
\catcodetable\csname\??catcodetablet\number\c_syst_catcodes_level\endcsname
\syst_catcodes_trace_pop
- \advance\c_syst_catcodes_level\minusone
+ \advanceby\c_syst_catcodes_level\minusone
\fi}
\protected\def\syst_catcodes_trace_nesting_error
diff --git a/tex/context/base/mkxl/chem-str.mkxl b/tex/context/base/mkxl/chem-str.mkxl
index 5f3f8b6c7..a4cf376c3 100644
--- a/tex/context/base/mkxl/chem-str.mkxl
+++ b/tex/context/base/mkxl/chem-str.mkxl
@@ -131,9 +131,9 @@
\newtoks \t_chem_every_box
\newbox \b_chem_result
\newconditional\c_chem_some_text
-\newdimen \d_chem_width
-\newdimen \d_chem_height
-\newdimen \d_chem_depth
+\newdimension \d_chem_width
+\newdimension \d_chem_height
+\newdimension \d_chem_depth
\permanent\tolerant\protected\def\startchemical[#1]#*[#2]%
{\ifmmode\vcenter\else\vbox\fi % vpack ?
diff --git a/tex/context/base/mkxl/cldf-ini.mkxl b/tex/context/base/mkxl/cldf-ini.mkxl
index b393eb9b5..0c5788bb2 100644
--- a/tex/context/base/mkxl/cldf-ini.mkxl
+++ b/tex/context/base/mkxl/cldf-ini.mkxl
@@ -13,7 +13,7 @@
\writestatus{loading}{ConTeXt Lua Documents / Initialization}
-\newcount\trialtypesettingstate % gets aliased at the Lua end
+% \newcount\trialtypesettingstate % gets aliased at the Lua end
\registerctxluafile{cldf-ini}{autosuffix}
diff --git a/tex/context/base/mkxl/colo-ext.mkxl b/tex/context/base/mkxl/colo-ext.mkxl
index f3779bb58..51e9b91ff 100644
--- a/tex/context/base/mkxl/colo-ext.mkxl
+++ b/tex/context/base/mkxl/colo-ext.mkxl
@@ -58,7 +58,7 @@
\installattributestack\colorintentattribute
-\setevalue{\??colorintent\v!none}{\c_attr_colorintent\attributeunsetvalue} % or reset? used at all?
+\edefcsname\??colorintent\v!none\endcsname{\c_attr_colorintent\attributeunsetvalue} % or reset? used at all?
\permanent\protected\def\startcolorintent[#1]%
{\pushattribute\colorintentattribute
diff --git a/tex/context/base/mkxl/colo-grp.mkxl b/tex/context/base/mkxl/colo-grp.mkxl
index 9237952d7..952bb18b3 100644
--- a/tex/context/base/mkxl/colo-grp.mkxl
+++ b/tex/context/base/mkxl/colo-grp.mkxl
@@ -47,7 +47,7 @@
\installcorenamespace{colorgroup}
\installcorenamespace{colorgroupsetter}
-\newcount\c_colo_groups_n % scratch counter
+\newinteger\c_colo_groups_n % scratch counter
\permanent\tolerant\protected\def\definecolorgroup[#1]#*[#2]#*[#3]% % sort of obsolete, just use palets directly
{\ifarguments\or\or
@@ -73,7 +73,7 @@
\fi}}
\def\colo_groups_define_entry#1#2#3% name mode specification
- {\advance\c_colo_groups_n\plusone
+ {\advanceby\c_colo_groups_n\plusone
\csname\??colorgroupsetter\ifcsname\??colorgroupsetter#2\endcsname#2\else\s!rgb\fi\endcsname[#1:\the\c_colo_groups_n][#3:0:0:0:0]}
\setvalue{\??colorgroupsetter\s!gray}[#1][#2:#3]{\definecolor[#1][s=#2]}
diff --git a/tex/context/base/mkxl/colo-ini.mkxl b/tex/context/base/mkxl/colo-ini.mkxl
index 68aba39ab..f17ec0b2b 100644
--- a/tex/context/base/mkxl/colo-ini.mkxl
+++ b/tex/context/base/mkxl/colo-ini.mkxl
@@ -345,7 +345,7 @@
% \newcount\c_colo_nesting
%
% \permanent\protected\def\pushcolor[#1]%
-% {\global\advance\c_colo_nesting\plusone
+% {\global\advanceby\c_colo_nesting\plusone
% \edefcsname\??colorstack\number\c_colo_nesting\endcsname
% {\c_attr_colormodel \the\c_attr_colormodel
% \c_attr_color \the\c_attr_color
@@ -355,7 +355,7 @@
%
% \permanent\protected\def\popcolor
% {\csname\??colorstack\number\c_colo_nesting\endcsname
-% \global\advance\c_colo_nesting\minusone}
+% \global\advanceby\c_colo_nesting\minusone}
%
% more efficient:
@@ -375,8 +375,8 @@
% a simple one: assumes grouping
-\newcount\c_colo_saved_attribute_color
-\newcount\c_colo_saved_attribute_transparency
+\newinteger\c_colo_saved_attribute_color
+\newinteger\c_colo_saved_attribute_transparency
\permanent\protected\def\savecolor
{\c_colo_saved_attribute_color \c_attr_color
@@ -464,7 +464,7 @@
\def\colo_palet_allocate#1%
{\letcsname\??paletlist#1\endcsname\empty
\ifcsname\??paletsize#1\endcsname\else
- \expandafter\newcount\csname\??paletsize#1\endcsname
+ \expandafter\newinteger\csname\??paletsize#1\endcsname
\fi}
\def\colo_palet_prepare#1%
@@ -474,14 +474,15 @@
\else
\colo_palet_allocate\colo_palet_name
\fi
- \enforced\expandafter\let\expandafter\c_colo_palet\csname\??paletsize\colo_palet_name\endcsname
+ % \enforced\expandafter\integerdef\expandafter\c_colo_palet\csname\??paletsize\colo_palet_name\endcsname
+ \edef\c_colo_palet{\csname\??paletsize\colo_palet_name\endcsname}% we can't alias as they are integers
\edef\m_colo_palet{\begincsname\??paletlist\colo_palet_name\endcsname}}
\def\colo_palet_extend#1%
{\addtocommalist{#1}\m_colo_palet
\letcsname\??paletlist\colo_palet_name\endcsname\m_colo_palet
- %\advance\csname\??paletsize\colo_palet_name\endcsname\plusone
- \advance\c_colo_palet\plusone}
+ %\advanceby\csname\??paletsize\colo_palet_name\endcsname\plusone
+ \advanceby\c_colo_palet\plusone}
\permanent\protected\def\doifelsecolorpalet#1%
{\ifcsname\??paletlist#1\endcsname
@@ -849,8 +850,8 @@
% \let\colo_basics_inherit \gobbletwoarguments % used in mp interface
\def\colo_basics_allocate#1%
- {\expandafter\newcount\csname\??colornumber#1\endcsname
- \clf_synccolorcount{#1}\c_syst_last_allocated_count}
+ {\expandafter\newinteger\csname\??colornumber#1\endcsname
+ \clf_synccolorcount{#1}{\??colornumber#1}}
\def\colo_basics_synchronize#1%
{\ifcsname\??colornumber#1\endcsname\else
@@ -862,10 +863,10 @@
\let\colo_basics_inherit\clf_synccolorclone
-\newcount\c_colo_protection
+\newinteger\c_colo_protection
-\permanent\protected\def\startprotectedcolors{\advance\c_colo_protection\plusone }
-\permanent\protected\def\stopprotectedcolors {\advance\c_colo_protection\minusone}
+\permanent\protected\def\startprotectedcolors{\advanceby\c_colo_protection\plusone }
+\permanent\protected\def\stopprotectedcolors {\advanceby\c_colo_protection\minusone}
\permanent\tolerant\protected\def\definecolor[#1]#*[#2]%
{\iftok{#1}{#2}%
@@ -885,7 +886,7 @@
\clf_defineprocesscolorglobal{#1}{#2}\v_colo_freeze_state\relax
\colo_basics_synchronize{#1}%
\ifcase\c_colo_protection
- \protected\instance\setgvalue{#1}{\colo_helpers_activate{#1}}%
+ \protected\instance\gdefcsname#1\endcsname{\colo_helpers_activate{#1}}%
\fi
\fi}
@@ -920,14 +921,14 @@
{\clf_definespotcolorglobal{#1}{#2}{#3}%
\colo_basics_synchronize{#1}%
\ifcase\c_colo_protection
- \protected\instance\setgvalue{#1}{\colo_helpers_activate{#1}}%
+ \protected\instance\gdefcsname#1\endcsname{\colo_helpers_activate{#1}}%
\fi}
\permanent\tolerant\protected\def\definemultitonecolor[#1]#*[#2]#*[#3]#*[#4]%
{\clf_definemultitonecolorglobal{#1}{#2}{#3}{#4}%
\colo_basics_synchronize{#1}%
\ifcase\c_colo_protection
- \protected\instance\setgvalue{#1}{\colo_helpers_activate{#1}}%
+ \protected\instance\gdefcsname#1\endcsname{\colo_helpers_activate{#1}}%
\fi}
%D Transparencies (only):
diff --git a/tex/context/base/mkxl/cont-new.mkxl b/tex/context/base/mkxl/cont-new.mkxl
index b777a015c..38e7f7b70 100644
--- a/tex/context/base/mkxl/cont-new.mkxl
+++ b/tex/context/base/mkxl/cont-new.mkxl
@@ -13,7 +13,7 @@
% \normalend % uncomment this to get the real base runtime
-\newcontextversion{2022.12.15 17:49}
+\newcontextversion{2022.12.21 17:10}
%D This file is loaded at runtime, thereby providing an excellent place for hacks,
%D patches, extensions and new features. There can be local overloads in cont-loc
diff --git a/tex/context/base/mkxl/context.mkxl b/tex/context/base/mkxl/context.mkxl
index 882be6cc3..897cf8bf7 100644
--- a/tex/context/base/mkxl/context.mkxl
+++ b/tex/context/base/mkxl/context.mkxl
@@ -29,7 +29,7 @@
%D {YYYY.MM.DD HH:MM} format.
\immutable\edef\contextformat {\jobname}
-\immutable\edef\contextversion{2022.12.15 17:49}
+\immutable\edef\contextversion{2022.12.21 17:10}
%overloadmode 1 % check frozen / warning
%overloadmode 2 % check frozen / error
diff --git a/tex/context/base/mkxl/core-dat.mkxl b/tex/context/base/mkxl/core-dat.mkxl
index 540f5b747..ab40d874c 100644
--- a/tex/context/base/mkxl/core-dat.mkxl
+++ b/tex/context/base/mkxl/core-dat.mkxl
@@ -84,7 +84,7 @@
\installcommandhandler \??pagestate {pagestate} \??pagestate
\def\syst_pagestates_allocate
- {\expandafter\newcount\csname\??pagestatecounter\currentpagestate\endcsname}
+ {\expandafter\newinteger\csname\??pagestatecounter\currentpagestate\endcsname}
\appendtoks
\syst_pagestates_allocate
@@ -98,7 +98,7 @@
\edef\currentpagestate{#1}%
\ifcsname\??pagestatecounter\currentpagestate\endcsname
\scratchcounter\lastnamedcs
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\else
\scratchcounter\plusone
\syst_pagestates_allocate
diff --git a/tex/context/base/mkxl/core-ini.mkxl b/tex/context/base/mkxl/core-ini.mkxl
index 4e4c696a7..a0fd8af10 100644
--- a/tex/context/base/mkxl/core-ini.mkxl
+++ b/tex/context/base/mkxl/core-ini.mkxl
@@ -176,8 +176,8 @@
\newconstant\pageduplexmode % 0 single 1 double 2 mix
\newconstant\pagebodymode % 0 not 1 normal pagebody 2 spread
-\newcount\nofcolumns \nofcolumns \plusone
-\newcount\nofmulticolumns \nofmulticolumns\plusone
+\newinteger\nofcolumns \nofcolumns \plusone
+\newinteger\nofmulticolumns \nofmulticolumns\plusone
%D \macros
%D {ifproductionrun}
diff --git a/tex/context/base/mkxl/core-sys.mkxl b/tex/context/base/mkxl/core-sys.mkxl
index a928508bb..393d85d77 100644
--- a/tex/context/base/mkxl/core-sys.mkxl
+++ b/tex/context/base/mkxl/core-sys.mkxl
@@ -129,9 +129,9 @@
\scratchcounter\normaltime
\processaction
[#1]
- [ \v!small=>\divide\scratchcounter 15, % 900,
- \v!medium=>\divide\scratchcounter 30, % 1800,
- \v!big=>\divide\scratchcounter 60, % 3600,
+ [ \v!small=>\divideby\scratchcounter 15, % 900,
+ \v!medium=>\divideby\scratchcounter 30, % 1800,
+ \v!big=>\divideby\scratchcounter 60, % 3600,
\v!normal=>\scratchcounter\newrandomseed,
\s!default=>\scratchcounter\newrandomseed,
\s!unknown=>\scratchcounter#1]%
diff --git a/tex/context/base/mkxl/file-ini.mklx b/tex/context/base/mkxl/file-ini.mklx
index 8febbdea1..66107a083 100644
--- a/tex/context/base/mkxl/file-ini.mklx
+++ b/tex/context/base/mkxl/file-ini.mklx
@@ -71,16 +71,16 @@
\installsystemnamespace{eolstack}
-\newcount\c_system_files_eol_level
+\newinteger\c_system_files_eol_level
\permanent\protected\def\pushendofline
- {\advance\c_system_files_eol_level\plusone
+ {\advanceby\c_system_files_eol_level\plusone
\expandafter\chardef\csname\??eolstack\number\c_system_files_eol_level\endcsname\catcode\endoflineasciicode
\catcode\endoflineasciicode\commentcatcode}
\permanent\protected\def\popendofline
{\catcode\endoflineasciicode\csname\??eolstack\number\c_system_files_eol_level\endcsname
- \advance\c_system_files_eol_level\minusone}
+ \advanceby\c_system_files_eol_level\minusone}
\permanent\protected\def\restoreendofline
{\catcode\endoflineasciicode\endoflinecatcode}
@@ -90,12 +90,12 @@
%D
%D A low level capsule:
-\newcount\readingfilelevel % no longer needed
-\newtoks \everystartreadingfile
-\newtoks \everystopreadingfile
+\newinteger\readingfilelevel % no longer needed
+\newtoks \everystartreadingfile
+\newtoks \everystopreadingfile
\permanent\protected\def\startreadingfile% beter een every en \setnormalcatcodes
- {\global\advance\readingfilelevel\plusone
+ {\global\advanceby\readingfilelevel\plusone
\the\everystartreadingfile
\pushcatcodetable % saveguard
\setcatcodetable\ctxcatcodes
@@ -105,7 +105,7 @@
{\popcatcodetable % saveguard
\clf_popregime % temporarily this way
\the\everystopreadingfile
- \global\advance\readingfilelevel\minusone}
+ \global\advanceby\readingfilelevel\minusone}
%D \macros
%D {input, normalinput}
diff --git a/tex/context/base/mkxl/file-job.lmt b/tex/context/base/mkxl/file-job.lmt
index 367ec4562..be2886fba 100644
--- a/tex/context/base/mkxl/file-job.lmt
+++ b/tex/context/base/mkxl/file-job.lmt
@@ -11,7 +11,7 @@ if not modules then modules = { } end modules ['file-job'] = {
local next, rawget, tostring, tonumber = next, rawget, tostring, tonumber
local gsub, match, gmatch, ind = string.gsub, string.match, string.gmatch, string.find
-local insert, remove, concat = table.insert, table.remove, table.concat
+local insert, remove, concat, unique, imerged = table.insert, table.remove, table.concat, table.unique, table.imerged
local validstring, formatters = string.valid, string.formatters
local sortedhash = table.sortedhash
local setmetatableindex, setmetatablenewindex = table.setmetatableindex, table.setmetatablenewindex
@@ -1350,3 +1350,17 @@ implement {
end,
}
+implement {
+ name = "adddefaultsuffix",
+ public = true,
+ protected = true,
+ actions = function(list)
+ resolvers.defaultsuffixes = unique(
+ imerged(
+ resolvers.defaultsuffixes,
+ list
+ )
+ )
+ end,
+ arguments = "array",
+}
diff --git a/tex/context/base/mkxl/file-job.mklx b/tex/context/base/mkxl/file-job.mklx
index 8f6c0aa56..6dc3d34be 100644
--- a/tex/context/base/mkxl/file-job.mklx
+++ b/tex/context/base/mkxl/file-job.mklx
@@ -78,7 +78,7 @@
% document structure
-\ifdefined\textlevel \else \newcount\textlevel \fi % might go away
+\ifdefined\textlevel \else \newinteger\textlevel \fi % might go away
\ifdefined\strc_pagenumbers_flush_final_page \else \let\strc_pagenumbers_flush_final_page\relax \fi % ugly
\permanent\protected\def\dostarttext
@@ -345,4 +345,11 @@
\permanent\protected\def\samplefile#1{\clf_samplefile{#1}}
+% \adddefaultsuffix[foo,{},crap]
+% \adddefaultsuffix[{}]
+%
+% \typefile{./crapcrap}
+% \typefile{crapcrap}
+
+
\protect \endinput
diff --git a/tex/context/base/mkxl/file-mod.mklx b/tex/context/base/mkxl/file-mod.mklx
index c0059bf94..a64529dd6 100644
--- a/tex/context/base/mkxl/file-mod.mklx
+++ b/tex/context/base/mkxl/file-mod.mklx
@@ -89,11 +89,11 @@
\aliased\let\usemodule \usemodules
\aliased\let\usetexmodule\usemodules
-\newcount\c_syst_modules_nesting
-\newtoks \everysetupmodule
+\newinteger\c_syst_modules_nesting
+\newtoks \everysetupmodule
\permanent\tolerant\protected\def\startmodule[#1]#;#2 %
- {\global\advance\c_syst_modules_nesting\plusone
+ {\global\advanceby\c_syst_modules_nesting\plusone
\push_macro_currentmodule
\push_macro_currentmoduleparameters
\def\currentmodule{#1#2}}
@@ -104,7 +104,7 @@
\else
\pop_macro_currentmoduleparameters
\pop_macro_currentmodule
- \global\advance\c_syst_modules_nesting\minusone
+ \global\advanceby\c_syst_modules_nesting\minusone
\fi}
\permanent\protected\def\setupmodule % to be lmtx'd
diff --git a/tex/context/base/mkxl/font-dsp.lmt b/tex/context/base/mkxl/font-dsp.lmt
index a8dc2e5dc..0cb05786b 100644
--- a/tex/context/base/mkxl/font-dsp.lmt
+++ b/tex/context/base/mkxl/font-dsp.lmt
@@ -381,7 +381,7 @@ local function getaxisscale(segments,minimum,default,maximum,user)
for i=1,#segments do
local s = segments[i]
if type(s) ~= "number" then
- report("using default axis scale")
+ -- report("using default axis scale")
return default
elseif s[1] >= default then
if s[2] == default then
@@ -4583,7 +4583,7 @@ function readers.hvar(f,fontdata,specification)
end
local tableoffset = gotodatatable(f,fontdata,"hvar",specification.variable)
if not tableoffset then
- report("no hvar table, expect problems due to messy widths")
+ -- report("no hvar table, expect problems due to messy widths")
return
end
local version = readulong(f) -- 0x00010000
diff --git a/tex/context/base/mkxl/font-ini.mklx b/tex/context/base/mkxl/font-ini.mklx
index f1691c8eb..e32ed0bf2 100644
--- a/tex/context/base/mkxl/font-ini.mklx
+++ b/tex/context/base/mkxl/font-ini.mklx
@@ -401,9 +401,9 @@
%D local (sometimes in the textflow) size. We store these dimensions in two
%D \DIMENSION\ registers. These registers are not to be misused in calculations.
-\ifdefined\globalbodyfontsize \else \newdimen\globalbodyfontsize \fi \globalbodyfontsize=12pt
-\ifdefined\localbodyfontsize \else \newdimen\localbodyfontsize \fi \localbodyfontsize =\globalbodyfontsize
-\ifdefined\bodyfontsize \else \newdimen\bodyfontsize \fi \bodyfontsize =\globalbodyfontsize
+\ifdefined\globalbodyfontsize \else \newdimension\globalbodyfontsize \fi \globalbodyfontsize=12pt
+\ifdefined\localbodyfontsize \else \newdimension\localbodyfontsize \fi \localbodyfontsize =\globalbodyfontsize
+\ifdefined\bodyfontsize \else \newdimension\bodyfontsize \fi \bodyfontsize =\globalbodyfontsize
%D When we assign for instance 12pt to a \DIMENSION\ register the \type {\the}'d
%D value comes out as 12.0pt, which is often not the way users specify the bodyfont
@@ -716,9 +716,9 @@
\mutable\lettonothing\somefontsizex
\mutable\lettonothing\somefontsizey
-% \newcount\scaledfontmode % font-lib.mklx
-% \newcount\scaledfontsize % font-lib.mklx
-% \newcount\lastfontid % font-lib.mklx
+% \newinteger\scaledfontmode % font-lib.mklx
+% \newinteger\scaledfontsize % font-lib.mklx
+% \newinteger\lastfontid % font-lib.mklx
\newtoks \everydefinefont
@@ -732,21 +732,21 @@
\setnewconstant\c_font_feature_inheritance_mode \c_font_feature_inheritance_default
-\newdimen \d_font_scaled_text_face
-\newdimen \d_font_scaled_font_size
+\newdimension \d_font_scaled_text_face
+\newdimension \d_font_scaled_font_size
\newconditional\c_font_body_scale
\newfraction \f_font_body_scale
\newconditional\c_font_compact
-\newcount \c_font_scaled_glyph_scale
+\newinteger \c_font_scaled_glyph_scale
\immutable\dimensiondef\d_font_scaled_default 10pt
% todo: move all to lua: use localcall for resolving filename
-% \newcount\c_font_future_glyph_scale % font-lib.mklx
-% \newcount\c_font_scaled_font_mode_saved % font-lib.mklx
-% \newcount\c_font_scaled_points % font-lib.mklx
+% \newcountinteger\c_font_future_glyph_scale % font-lib.mklx
+% \newcountinteger\c_font_scaled_font_mode_saved % font-lib.mklx
+% \newcountinteger\c_font_scaled_points % font-lib.mklx
\mutable\lettonothing\somefontspec
diff --git a/tex/context/base/mkxl/font-lib.mklx b/tex/context/base/mkxl/font-lib.mklx
index d3a18f8b5..3ce1b8bff 100644
--- a/tex/context/base/mkxl/font-lib.mklx
+++ b/tex/context/base/mkxl/font-lib.mklx
@@ -15,17 +15,17 @@
\unprotect
-\newcount\scaledfontmode
-\newcount\scaledfontsize
-\newcount\lastfontid
+\newinteger\scaledfontmode
+\newinteger\scaledfontsize
+\newinteger\lastfontid
-\newcount\c_font_future_glyph_scale
-\newcount\c_font_scaled_font_mode_saved
-\newcount\c_font_scaled_points
+\newinteger\c_font_future_glyph_scale
+\newinteger\c_font_scaled_font_mode_saved
+\newinteger\c_font_scaled_points
-\ifdefined\globalbodyfontsize \else \newdimen\globalbodyfontsize \fi
-\ifdefined\localbodyfontsize \else \newdimen\localbodyfontsize \fi
-\ifdefined\bodyfontsize \else \newdimen\bodyfontsize \fi
+\ifdefined\globalbodyfontsize \else \newdimension\globalbodyfontsize \fi
+\ifdefined\localbodyfontsize \else \newdimension\localbodyfontsize \fi
+\ifdefined\bodyfontsize \else \newdimension\bodyfontsize \fi
\registerctxluafile{font-ini}{autosuffix}
\registerctxluafile{font-log}{}
diff --git a/tex/context/base/mkxl/font-mat.mklx b/tex/context/base/mkxl/font-mat.mklx
index e7a7574a3..11917efe6 100644
--- a/tex/context/base/mkxl/font-mat.mklx
+++ b/tex/context/base/mkxl/font-mat.mklx
@@ -125,7 +125,7 @@
\mutable\let\fontfamily\relax % for now public but it is a helper
-\newcount \c_math_last_family_used
+\newinteger\c_math_last_family_used
\def\font_helpers_set_math_family_indeed_normal#mrtag#family% \fontface etc are also used later on
{\let\savedfontbody\fontbody
diff --git a/tex/context/base/mkxl/grph-fig.mkxl b/tex/context/base/mkxl/grph-fig.mkxl
index 0d4462730..e25c9cf32 100644
--- a/tex/context/base/mkxl/grph-fig.mkxl
+++ b/tex/context/base/mkxl/grph-fig.mkxl
@@ -113,10 +113,10 @@
%D \externalfigure[mycow]
%D \stoptyping
-\newcount\c_grph_steps_reference
-\newdimen\d_grph_steps_x
-\newdimen\d_grph_steps_y
-\newbox \b_grph_steps_colorbar
+\newinteger \c_grph_steps_reference
+\newdimension\d_grph_steps_x
+\newdimension\d_grph_steps_y
+\newbox \b_grph_steps_colorbar
\ifdefined\referring\else \mutable\let\referring\relax \fi
\ifdefined\marking \else \mutable\let\marking \relax \fi
@@ -264,7 +264,7 @@
\definesystemconstant{vwb}
\tolerant\protected\def\grph_steps_three_referring(#1,#2)#*(#3,#4)#*[#5]%
- {\advance\c_grph_steps_reference\plusone
+ {\advanceby\c_grph_steps_reference\plusone
\position(#1,#2)
{\hbox{\the\c_grph_steps_reference}}%
\position(#1,#2)
@@ -291,15 +291,15 @@
\setexternalfigureparameter\c!ymax{24}%
\fi
\d_grph_steps_y\figureheight
- \divide\d_grph_steps_y \externalfigureparameter\c!ymax
+ \divideby\d_grph_steps_y \externalfigureparameter\c!ymax
\d_grph_steps_x\d_grph_steps_y
\scratchdimen\figurewidth
- \advance\scratchdimen\d_grph_steps_y
- \divide \scratchdimen\d_grph_steps_y
+ \advanceby\scratchdimen\d_grph_steps_y
+ \divideby \scratchdimen\d_grph_steps_y
\setexternalfigureparameter\c!xmax{\number\scratchdimen}%
\else
- \d_grph_steps_x\figurewidth \divide\d_grph_steps_x \externalfigureparameter\c!xmax\relax
- \d_grph_steps_y\figureheight \divide\d_grph_steps_y \externalfigureparameter\c!ymax\relax
+ \d_grph_steps_x\figurewidth \divideby\d_grph_steps_x \externalfigureparameter\c!xmax\relax
+ \d_grph_steps_y\figureheight \divideby\d_grph_steps_y \externalfigureparameter\c!ymax\relax
\fi}
\tolerant\def\grph_steps_comment#1(#2,#3)#*(#4,#5)#*[#6]#*#:#7% {kader}(x,y)(h,b)[...]{tekst}
@@ -314,7 +314,7 @@
{\gotobox{\vpack{\grph_steps_area(#1,#2)#3{}}}[#4]}
\tolerant\def\grph_steps_text#1(#2,#3)#*(#4,#5)#*[#6]%
- {\advance\c_grph_steps_reference\plusone
+ {\advanceby\c_grph_steps_reference\plusone
\hbox % \hpack ?
{\quad
\thisissomeinternal\s!vwb{#6}%
diff --git a/tex/context/base/mkxl/grph-inc.mkxl b/tex/context/base/mkxl/grph-inc.mkxl
index 19cce3511..b8fd40a89 100644
--- a/tex/context/base/mkxl/grph-inc.mkxl
+++ b/tex/context/base/mkxl/grph-inc.mkxl
@@ -119,10 +119,10 @@
%D Defining figures.
-\newcount\c_grph_include_nesting
+\newinteger\c_grph_include_nesting
-\newtoks \everyexternalfigureresets % for the moment still public
-\newtoks \everyexternalfigurechecks % for the moment still public
+\newtoks \everyexternalfigureresets % for the moment still public
+\newtoks \everyexternalfigurechecks % for the moment still public
% \useexternalfigure[alpha][cow]
% \useexternalfigure[beta] [cow] [width=1cm]
@@ -274,7 +274,7 @@
\def\grph_include_place[#1][#2][#3]% [label][file][settings] | [file][settings] | [file][parent][settings]
{\bgroup
- \advance\c_grph_include_nesting\plusone
+ \advanceby\c_grph_include_nesting\plusone
\edef\currentexternalfigure{\the\c_grph_include_nesting}%
\checkexternalfigureparent % each inherits from the root
%
@@ -788,10 +788,10 @@
\newconditional\c_grph_include_in_collection
-\newdimen\d_grph_include_collection_minwidth
-\newdimen\d_grph_include_collection_maxwidth
-\newdimen\d_grph_include_collection_minheight
-\newdimen\d_grph_include_collection_maxheight
+\newdimension \d_grph_include_collection_minwidth
+\newdimension \d_grph_include_collection_maxwidth
+\newdimension \d_grph_include_collection_minheight
+\newdimension \d_grph_include_collection_maxheight
\def\grph_include_analyze_collection[#1][#2]%
{\ifconditional\c_grph_include_in_collection
diff --git a/tex/context/base/mkxl/grph-trf.mkxl b/tex/context/base/mkxl/grph-trf.mkxl
index 639eacbbc..4cac29282 100644
--- a/tex/context/base/mkxl/grph-trf.mkxl
+++ b/tex/context/base/mkxl/grph-trf.mkxl
@@ -28,13 +28,13 @@
% local:
-\newdimen\d_grph_scale_x_size
-\newdimen\d_grph_scale_y_size
-\newdimen\d_grph_scale_x_offset
-\newdimen\d_grph_scale_y_offset
+\newdimension\d_grph_scale_x_size
+\newdimension\d_grph_scale_y_size
+\newdimension\d_grph_scale_x_offset
+\newdimension\d_grph_scale_y_offset
-\newdimen\d_grph_scale_h_size
-\newdimen\d_grph_scale_v_size
+\newdimension\d_grph_scale_h_size
+\newdimension\d_grph_scale_v_size
\newconditional\c_grph_scale_done
\newconditional\c_grph_scale_scaling_done
@@ -42,22 +42,22 @@
\newconditional\c_grph_scale_swap_factor
-\newdimen\d_grph_scale_wd
-\newdimen\d_grph_scale_ht
-\newdimen\d_grph_scale_dp
+\newdimension\d_grph_scale_wd
+\newdimension\d_grph_scale_ht
+\newdimension\d_grph_scale_dp
% global
-\newdimen\d_grph_scale_used_x_size
-\newdimen\d_grph_scale_used_y_size
+\newdimension\d_grph_scale_used_x_size
+\newdimension\d_grph_scale_used_y_size
-\newcount\c_grph_scale_used_x_scale
-\newcount\c_grph_scale_used_y_scale
+\newinteger\c_grph_scale_used_x_scale
+\newinteger\c_grph_scale_used_y_scale
-\let \m_grph_scale_used_x_scale\!!plusone
-\let \m_grph_scale_used_y_scale\!!plusone
+\let\m_grph_scale_used_x_scale\!!plusone
+\let\m_grph_scale_used_y_scale\!!plusone
-\newdimen\d_grph_scale_outer_v_size % we cannot manipulate any global vsize !
+\newdimension\d_grph_scale_outer_v_size % we cannot manipulate any global vsize !
% scratch:
@@ -645,11 +645,11 @@
\scratchheight\dimexpr\ht\nextbox/\clippingparameter\c!ny\relax
\scratchyoffset\dimexpr-\clippingparameter\c!y\scratchheight-\clippingparameter\c!sy\scratchheight+\scratchheight\relax
\scratchheight\clippingparameter\c!sy\scratchheight
- \advance\scratchyoffset \ht\nextbox
+ \advanceby\scratchyoffset \ht\nextbox
\fi
\setbox\nextbox\naturalhpack
- {\advance\scratchxoffset -\clippingparameter\c!leftoffset \relax
- \advance\scratchyoffset -\clippingparameter\c!bottomoffset\relax
+ {\advanceby\scratchxoffset -\clippingparameter\c!leftoffset \relax
+ \advanceby\scratchyoffset -\clippingparameter\c!bottomoffset\relax
\hskip-\scratchxoffset
\lower\scratchyoffset
\box\nextbox}%
@@ -657,8 +657,8 @@
\ht\nextbox\zeropoint
\dp\nextbox\zeropoint
\setbox\nextbox\naturalhpack
- {\advance\scratchwidth \dimexpr\clippingparameter\c!leftoffset +\clippingparameter\c!rightoffset\relax
- \advance\scratchheight\dimexpr\clippingparameter\c!bottomoffset+\clippingparameter\c!topoffset \relax
+ {\advanceby\scratchwidth \dimexpr\clippingparameter\c!leftoffset +\clippingparameter\c!rightoffset\relax
+ \advanceby\scratchheight\dimexpr\clippingparameter\c!bottomoffset+\clippingparameter\c!topoffset \relax
\dostartclipping{\clippingparameter\c!mp}\scratchwidth\scratchheight
\box\nextbox
\dostopclipping}%
@@ -771,15 +771,15 @@
%D These aren't:
-\newdimen\d_grph_rotate_used_height
+\newdimension\d_grph_rotate_used_height
-\newdimen\d_grph_rotate_width
-\newdimen\d_grph_rotate_height
-\newdimen\d_grph_rotate_depth
+\newdimension\d_grph_rotate_width
+\newdimension\d_grph_rotate_height
+\newdimension\d_grph_rotate_depth
-\newdimen\d_grph_rotate_saved_width
-\newdimen\d_grph_rotate_saved_height
-\newdimen\d_grph_rotate_saved_depth
+\newdimension\d_grph_rotate_saved_width
+\newdimension\d_grph_rotate_saved_height
+\newdimension\d_grph_rotate_saved_depth
\newconditional\c_grph_rotate_obey_depth
\newconditional\c_grph_rotate_not_fit
diff --git a/tex/context/base/mkxl/lang-frq.mkxl b/tex/context/base/mkxl/lang-frq.mkxl
index 6b9853af5..7a35b8d51 100644
--- a/tex/context/base/mkxl/lang-frq.mkxl
+++ b/tex/context/base/mkxl/lang-frq.mkxl
@@ -94,7 +94,7 @@
\permanent\protected\def\startcharactertable[#1]#2\stopcharactertable % \dimexpr has fuzzy lookahead
{\startnointerference
\gdefcsname\??frequencywidths#1\endcsname{#2}% the width vector
- \scratchcounter\zerocount \def\charfreq##1 ##2 {\advance\scratchcounter\plusone} #2%
+ \scratchcounter\zerocount \def\charfreq##1 ##2 {\advanceby\scratchcounter\plusone} #2%
\xdefcsname\??frequencycounts#1\endcsname{\the\scratchcounter}% the character count
\stopnointerference}
diff --git a/tex/context/base/mkxl/lang-hup.mkxl b/tex/context/base/mkxl/lang-hup.mkxl
index b7bebce52..444863cc5 100644
--- a/tex/context/base/mkxl/lang-hup.mkxl
+++ b/tex/context/base/mkxl/lang-hup.mkxl
@@ -24,7 +24,7 @@
%D \enabletrackers[hyphenation.applied.console]
%D
%D \dontcomplain \dostepwiserecurse{0}{15}{1}{
-%D {\advance\hsize -#1cm \input tufte \par}
+%D {\advanceby\hsize -#1cm \input tufte \par}
%D }
%D
%D \stoptext
diff --git a/tex/context/base/mkxl/lang-hyp.mkxl b/tex/context/base/mkxl/lang-hyp.mkxl
index 25699696e..355804ca3 100644
--- a/tex/context/base/mkxl/lang-hyp.mkxl
+++ b/tex/context/base/mkxl/lang-hyp.mkxl
@@ -43,7 +43,7 @@
%D and such are now more or less default in \CONTEXT\ so we can simplify some of the
%D code. We also use the new penalty mechanism.
-\newcount\compoundhyphenpenalty
+\newinteger\compoundhyphenpenalty
% \ifcase\contextlmtxmode
% \hyphenpenaltymode\plusfour
diff --git a/tex/context/base/mkxl/lang-ini.mkxl b/tex/context/base/mkxl/lang-ini.mkxl
index 9acc2535b..ef85838dc 100644
--- a/tex/context/base/mkxl/lang-ini.mkxl
+++ b/tex/context/base/mkxl/lang-ini.mkxl
@@ -395,8 +395,8 @@
\the\everylanguage
\relax}
-\newcount\hyphenstate
-\newcount\hyphenminoffset
+\newinteger\hyphenstate
+\newinteger\hyphenminoffset
% This is the old implementation: a hack that sets the min values, because we want
% to keep the language set:
@@ -502,12 +502,12 @@
%D The rest stays the same as in mkiv:
\permanent\protected\def\lesshyphens
- {\advance\hyphenminoffset\plusone
+ {\advanceby\hyphenminoffset\plusone
\lang_basics_synchronize_min_max}
\permanent\protected\def\morehyphens
{\ifcase\hyphenminoffset \else
- \advance\hyphenminoffset\minusone
+ \advanceby\hyphenminoffset\minusone
\fi
\lang_basics_synchronize_min_max}
@@ -628,7 +628,7 @@
\popoverloadmode
-\newcount\mainlanguagenumber
+\newinteger\mainlanguagenumber
%D Beware: you might need to use \type {\dontleavehmode} outside and|/|or \type {\par}
%D inside the group!
diff --git a/tex/context/base/mkxl/layo-ini.mkxl b/tex/context/base/mkxl/layo-ini.mkxl
index 73b7e978e..a3ed6236b 100644
--- a/tex/context/base/mkxl/layo-ini.mkxl
+++ b/tex/context/base/mkxl/layo-ini.mkxl
@@ -22,8 +22,8 @@
\ifdefined\layoutisdoublesided \else \newconditional\layoutisdoublesided \fi
\ifdefined\layoutissinglesided \else \newconditional\layoutissinglesided \fi
-\ifdefined\pagenoshift \else \newcount \pagenoshift \fi
-\ifdefined\realpageno \else \newcount \realpageno \fi
+\ifdefined\pagenoshift \else \newinteger \pagenoshift \fi
+\ifdefined\realpageno \else \newinteger \realpageno \fi
\registerctxluafile{layo-ini}{autosuffix}
diff --git a/tex/context/base/mkxl/lpdf-rul.lmt b/tex/context/base/mkxl/lpdf-rul.lmt
index 2c8227be9..bfedf23b2 100644
--- a/tex/context/base/mkxl/lpdf-rul.lmt
+++ b/tex/context/base/mkxl/lpdf-rul.lmt
@@ -355,6 +355,7 @@ do
local f_rectangle = formatters["%.6N w %.6N %.6N %.6N %.6N re %s"]
local f_baselined = formatters["%.6N w %.6N %.6N %.6N %.6N re s %.6N %.6N m %.6N %.6N l s"]
local f_dashlined = formatters["%.6N w %.6N %.6N %.6N %.6N re s [%.6N %.6N] 2 d %.6N %.6N m %.6N %.6N l s"]
+ local f_dashtwice = formatters["%.6N w %.6N %.6N %.6N %.6N re s [%.6N %.6N] 2 d %.6N %.6N m %.6N %.6N l s %.6N %.6N m %.6N %.6N l s"]
local f_radtangle = formatters[
[[%.6N w %.6N %.6N m
%.6N %.6N l %.6N %.6N %.6N %.6N y
@@ -396,34 +397,18 @@ h %s]]
local h = h * bpfactor
local d = d * bpfactor
local o = l / 2
- if (d >= 0 and h >= 0) or (d <= 0 and h <= 0) then
- local dashed = tonumber(p.dashed)
- if dashed and dashed > 5*line then
- dashed = dashed * bpfactor
- local delta = (w - 2*dashed*floor(w/(2*dashed)))/2
- pdfprint("direct",f_dashlined(l,o,o,w-l,h+d-l,dashed,dashed,delta,d,w-delta,d))
- else
- pdfprint("direct",f_baselined(l,o,o,w-l,h+d-l,0,d,w,d))
- end
- else
- pdfprint("direct",f_rectangle(l,o,o,w-l,h+d-l,"s"))
- end
- end
-
- local function rule_box(p,h,v,i,n)
- local w, h, d = getwhd(n)
- local line = p.line or 65536
- local l = line *bpfactor
- local w = w * bpfactor
- local h = h * bpfactor
- local d = d * bpfactor
- local o = l / 2
+ local u = p.double
if p.baseline ~= false and ((d >= 0 and h >= 0) or (d <= 0 and h <= 0)) then
local dashed = tonumber(p.dashed)
if dashed and dashed > 5*line then
dashed = dashed * bpfactor
local delta = (w - 2*dashed*floor(w/(2*dashed)))/2
- pdfprint("direct",f_dashlined(l,o,o,w-l,h+d-l,dashed,dashed,delta,d,w-delta,d))
+ if u then
+ u = u * bpfactor
+ pdfprint("direct",f_dashtwice(l,o,o,w-l,h+d-l,dashed,dashed,delta,d,w-delta,d,delta,d+u,w-delta,d+u))
+ else
+ pdfprint("direct",f_dashlined(l,o,o,w-l,h+d-l,dashed,dashed,delta,d,w-delta,d))
+ end
else
pdfprint("direct",f_baselined(l,o,o,w-l,h+d-l,0,d,w,d))
end
diff --git a/tex/context/base/mkxl/math-act.lmt b/tex/context/base/mkxl/math-act.lmt
index 65e154b22..62645ba54 100644
--- a/tex/context/base/mkxl/math-act.lmt
+++ b/tex/context/base/mkxl/math-act.lmt
@@ -312,7 +312,8 @@ local function getalso(target,original)
local also = target.tweakalso -- maybe
if not also then
also = { }
- for k, v in sortedhash(target.characters) do
+ -- for k, v in sortedhash(target.characters) do
+ for k, v in next, target.characters do
local u = v.unicode
if u and k ~= u then
local a = also[u]
@@ -1177,7 +1178,8 @@ do
function mathtweaks.simplifykerns(target,original,parameters)
local characters = target.characters
local done = false
- for u, v in sortedhash(characters) do
+ -- for u, v in sortedhash(characters) do
+ for u, v in next, characters do
local mathkerns = v.mathkerns
if mathkerns then
local k = mathkerns.topleft
@@ -1244,7 +1246,7 @@ do
end
return false
end
- local function step(s,l)
+ local function step(s)
while s do
local u = mathgaps[s] or s
local c = targetcharacters[u]
@@ -1314,7 +1316,8 @@ do
local list = parameters.list -- todo: ranges
if list == "letters" or parameters.letters then
local chardata = characters.data
- for k, v in sortedhash(targetcharacters) do
+ -- for k, v in sortedhash(targetcharacters) do
+ for k, v in next, targetcharacters do
if v.italic then
local d = chardata[v.unicode]
local c = d and d.category
@@ -1331,17 +1334,20 @@ do
end
for i=1,#list do
local l = list[i]
+ local t = type(l)
if not l then
-- can be false
- elseif type(l) == "table" then
+ elseif t == "table" then
for i=1,#l do
- step(i,l[i])
+ step(l[i])
end
+ elseif t == "number" then
+ step(l)
else
local r = blocks[l]
if r then
for i=r.first,r.last do
- step(i,l)
+ step(i)
end
else
stepper(l,step)
@@ -3109,7 +3115,8 @@ do
function mathtweaks.addmirrors(target,original,parameters)
local characters = target.characters
- for unicode, detail in sortedhash(characters) do
+ -- for unicode, detail in sortedhash(characters) do
+ for unicode, detail in next, characters do
local data = chardata[unicode]
if data and data.mirror then
add(target,original,characters,unicode,"mirror")
@@ -3566,7 +3573,8 @@ do
local italics = 0
local metadata = original.shared.rawdata.metadata
local fontname = metadata and metadata.fontname or false
- for k, v in sortedhash(characters) do
+ -- for k, v in sortedhash(characters) do
+ for k, v in next, characters do
local italic = v.italic
if italic then
local unicode = v.unicode
diff --git a/tex/context/base/mkxl/math-ali.mkxl b/tex/context/base/mkxl/math-ali.mkxl
index 6c0fb6b82..1fc01c6f7 100644
--- a/tex/context/base/mkxl/math-ali.mkxl
+++ b/tex/context/base/mkxl/math-ali.mkxl
@@ -71,15 +71,15 @@
% \stopalign
% \stopformula
-\newtoks\mathdisplayaligntweaks
+\newtoks \mathdisplayaligntweaks
-\newtoks \t_math_align_a
-\newtoks \t_math_align_b
-\newtoks \t_math_align_c
-\newskip \d_math_eqalign_distance
-\newskip \d_math_eqalign_rulethickness
-\newdimen\d_math_eqalign_number_distance
-\newcount\c_math_eqalign_repeat
+\newtoks \t_math_align_a
+\newtoks \t_math_align_b
+\newtoks \t_math_align_c
+\newgluespec \d_math_eqalign_distance
+\newgluespec \d_math_eqalign_rulethickness
+\newdimension\d_math_eqalign_number_distance
+\newinteger \c_math_eqalign_repeat
\mutable\def\displayopenupvalue{.25\bodyfontsize}
@@ -110,9 +110,9 @@
\toksapp\scratchtoks {\tabskip\d_math_eqalign_distance}%
% so ...
\toksapp\scratchtoks {\relax\math_eqalign_distance}%
- \etoksapp\scratchtoks{\global\advance\c_math_eqalign_repeat\the\scratchcountertwo\relax}%
+ \etoksapp\scratchtoks{\global\advanceby\c_math_eqalign_repeat\the\scratchcountertwo\relax}%
\else
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\fi
\toksapp\scratchtoks\t_math_align_b}%
\toksapp\scratchtoks\t_math_align_c
@@ -381,14 +381,14 @@
%D Here we implement the user interface part. We start with basic math alignments:
-\newcount \c_math_eqalign_column
-\newcount \c_math_eqalign_row
+\newinteger \c_math_eqalign_column
+\newinteger \c_math_eqalign_row
\newconditional\c_math_eqalign_first
-\newtoks \everymathalignment
-\newtoks \everymathalignmentdone
+\newtoks \everymathalignment
+\newtoks \everymathalignmentdone
-\newdimen\d_math_eqalign_number_threshold
+\newdimension \d_math_eqalign_number_threshold
\definesystemattribute[mathnumberlocation] [public]
\definesystemattribute[mathnumberthreshold][public]
@@ -519,7 +519,7 @@
% % [align=2:right]
% % [align={1:left,2:middle,3:right}]
-\newskip\s_strc_math_alignment_inbetween
+\newgluespec\s_strc_math_alignment_inbetween
\def\strc_math_setup_spacing_aligned#1%
{\begingroup
@@ -551,7 +551,7 @@
\edef\p_math_alignment_number{\mathalignmentparameter\c!number}%
\processcommacommand
[\mathalignmentparameter\c!align]%
- {\advance\c_math_eqalign_column\plusone\math_eqalign_set_column}% takes argument
+ {\advanceby\c_math_eqalign_column\plusone\math_eqalign_set_column}% takes argument
\global\c_math_eqalign_column\plusone
\strc_math_setup_spacing_aligned\mathalignmentparameter
\dostarttagged\t!math\empty
@@ -667,12 +667,12 @@
\def\math_first_in_eqalign
{\global\c_math_eqalign_column\plusone
- \global\advance\c_math_eqalign_row\plusone
+ \global\advanceby\c_math_eqalign_row\plusone
\dostarttagged\t!mtablerow \empty
\dostarttagged\t!mtablecell\empty}
\def\math_next_in_eqalign
- {\global\advance\c_math_eqalign_column\plusone
+ {\global\advanceby\c_math_eqalign_column\plusone
\dostoptagged % finish cell
\dostarttagged\t!mtablecell\empty}
@@ -731,7 +731,7 @@
{\normalexpanded{\math_eqalign_set_column_indeed[#1::]}}
\def\math_eqalign_set_columns_step
- {\advance\c_math_eqalign_column\plusone
+ {\advanceby\c_math_eqalign_column\plusone
%\c_math_matrix_columns\c_math_eqalign_column
\math_eqalign_set_column}
@@ -920,7 +920,7 @@
\let\math_cases_strut\relax
-\newcount\c_math_cases_nc
+\newinteger\c_math_cases_nc
\def\math_cases_NC_zero
{\ifmmode\else\startimath\fi}
@@ -950,7 +950,7 @@
\else
% error
\fi
- \global\advance\c_math_cases_nc\plusone}
+ \global\advanceby\c_math_cases_nc\plusone}
\permanent\protected\def\math_cases_TC
{\ifcase\c_math_cases_nc
@@ -962,7 +962,7 @@
\else
% error
\fi
- \global\advance\c_math_cases_nc\plusone}
+ \global\advanceby\c_math_cases_nc\plusone}
\noaligned\tolerant\permanent\protected\def\math_cases_NR[#1]#*[#2]%
{\unskip
@@ -1124,7 +1124,7 @@
\frozen\instance \defcsname \e!stop \currentmathmatrix\endcsname{\math_matrix_stop}% no u else lookahead problem
\to \everydefinemathmatrix
-\newcount\c_math_matrix_columns
+\newinteger\c_math_matrix_columns
\def\math_matrix_start_table
{\global\c_math_eqalign_column\zerocount
@@ -1141,7 +1141,7 @@
{\beginlocalcontrol
\global\c_math_matrix_columns\c_math_eqalign_column
\global\c_math_eqalign_column\zerocount
- \global\advance\c_math_eqalign_row\plusone
+ \global\advanceby\c_math_eqalign_row\plusone
\dostarttagged\t!mtablerow\empty
\endlocalcontrol}
@@ -1305,7 +1305,7 @@
\def\math_matrix_preamble
{\math_matrix_strut
\math_matrix_anchor_first
- \global\advance\c_math_eqalign_column\plusone
+ \global\advanceby\c_math_eqalign_column\plusone
\math_matrix_start_cell
\aligncontent
\math_matrix_stop_cell
@@ -1315,7 +1315,7 @@
\kern.5\d_math_eqalign_distance % hskip
\aligncontent
\aligntab
- \global\advance\c_math_eqalign_column\plusone
+ \global\advanceby\c_math_eqalign_column\plusone
\math_matrix_start_cell
\aligncontent
\math_matrix_stop_cell}
@@ -1401,7 +1401,7 @@
\noaligned\permanent\tolerant\protected\def\math_matrix_HL[#1]#*%
{\noalign\bgroup
\math_matrix_check_rule[#1]%
- \divide\scratchdimen\plustwo
+ \divideby\scratchdimen\plustwo
\ifdim\scratchdimen>\zeropoint
% \autorule\s!height\scratchdimen\s!depth\scratchdimen\relax
\scratchdistance\mathmatrixparameter\c!toffset\relax
@@ -1567,7 +1567,7 @@
{\beginlocalcontrol
\global\c_math_matrix_columns\c_math_eqalign_column
\global\c_math_eqalign_column\zerocount
- \global\advance\c_math_eqalign_row\plusone
+ \global\advanceby\c_math_eqalign_row\plusone
\dostarttagged\t!mtablerow\empty
\endlocalcontrol}
@@ -1584,15 +1584,15 @@
\definesystemattribute[mathmatrixornament][public]
-\newdimen\d_math_matrix_margin_l
-\newdimen\d_math_matrix_margin_r
-\newdimen\d_math_matrix_margin_t
-\newdimen\d_math_matrix_margin_b
+\newdimension\d_math_matrix_margin_l
+\newdimension\d_math_matrix_margin_r
+\newdimension\d_math_matrix_margin_t
+\newdimension\d_math_matrix_margin_b
-\newboundary\c_math_matrix_ornament_l
-\newboundary\c_math_matrix_ornament_r
-\newboundary\c_math_matrix_ornament_t
-\newboundary\c_math_matrix_ornament_b
+\newboundary \c_math_matrix_ornament_l
+\newboundary \c_math_matrix_ornament_r
+\newboundary \c_math_matrix_ornament_t
+\newboundary \c_math_matrix_ornament_b
% anchors are wrong now
@@ -1686,8 +1686,8 @@
% \edef\p_rulecolor{\mathmatrixparameter\c!rulecolor}
\edef\math_matrix_set_style{\mathmatrixparameter\c!style}}
-\newcount\c_math_eqalign_column_saved
-\newcount\c_math_eqalign_row_saved
+\newinteger\c_math_eqalign_column_saved
+\newinteger\c_math_eqalign_row_saved
% \installglobalmacrostack\c_math_matrix_first
@@ -1750,8 +1750,8 @@
\ifconditional\c_math_matrix_text
\ifcstok{\mathmatrixparameter\c!left\mathmatrixparameter\c!right}\emptytoks\else
\scratchdistance\dimexpr(\wd\scratchbox-\scratchwidth)/\plustwo\relax
- \advance\d_math_matrix_margin_l\scratchdistance
- \advance\d_math_matrix_margin_r\scratchdistance
+ \advanceby\d_math_matrix_margin_l\scratchdistance
+ \advanceby\d_math_matrix_margin_r\scratchdistance
\clf_shiftmatrixornaments\scratchbox
\fi
\fi
@@ -2136,12 +2136,11 @@
\newconditional\c_strc_math_display_overflow
\newconstant \c_strc_math_number_location
\newconstant \c_strc_math_number_variant
-\newdimen \d_strc_math_display_width
+\newdimension \d_strc_math_display_width
\newconstant \c_strc_formulas_frame_mode
-\newdimen \d_strc_math_indent
+\newdimension \d_strc_math_indent
\newconditional\c_strc_math_indent
-
-\newdimen\d_strc_math_framed_width
+\newdimension \d_strc_math_framed_width
\defcsname\??formulaoption\v!frame\endcsname
{\edef\p_frame{\formulaparameter\c!frame}%
@@ -2797,14 +2796,14 @@
\enablematrixalign
\halign callback \s!attr \mathnumberlocationattribute \zerocount \bgroup
\global\c_math_eqalign_column\zerocount
- \global\advance\c_math_eqalign_row\zerocount
+ \global\advanceby\c_math_eqalign_row\zerocount
\ignorespaces
\aligncontent % dummy
\removeunwantedspaces
\lastleftclass \mathbegincode
\lastrightclass\mathendcode
\aligntab
- \global\advance\c_math_eqalign_column\plusone
+ \global\advanceby\c_math_eqalign_column\plusone
\math_left_of_eqalign % \hfil
\ignorespaces
\math_align_strut
@@ -2815,7 +2814,7 @@
\math_right_of_eqalign % \hfil
\aligntab
\aligntab
- \global\advance\c_math_eqalign_column\plusone
+ \global\advanceby\c_math_eqalign_column\plusone
\math_left_of_eqalign % \hfil
\ifx\m_simplealign_distance\v!math
\mathbeginclass\lastrightclass
diff --git a/tex/context/base/mkxl/math-del.mkxl b/tex/context/base/mkxl/math-del.mkxl
index 47febc180..35d71460b 100644
--- a/tex/context/base/mkxl/math-del.mkxl
+++ b/tex/context/base/mkxl/math-del.mkxl
@@ -31,10 +31,10 @@
% Actually we can do better now with lua hacks.
-\newcount\c_math_delimiter_nesting
+\newinteger\c_math_delimiter_nesting
-\permanent\protected\def\leftfakedelimiter {\advance\c_math_delimiter_nesting\minusone\gobbleoneargument}
-\permanent\protected\def\rightfakedelimiter{\advance\c_math_delimiter_nesting\plusone \gobbleoneargument}
+\permanent\protected\def\leftfakedelimiter {\advanceby\c_math_delimiter_nesting\minusone\gobbleoneargument}
+\permanent\protected\def\rightfakedelimiter{\advanceby\c_math_delimiter_nesting\plusone \gobbleoneargument}
\permanent\protected\def\checkdelimiters#1%
{\c_math_delimiter_nesting\zerocount
diff --git a/tex/context/base/mkxl/math-fen.mkxl b/tex/context/base/mkxl/math-fen.mkxl
index 69be6adca..806581b34 100644
--- a/tex/context/base/mkxl/math-fen.mkxl
+++ b/tex/context/base/mkxl/math-fen.mkxl
@@ -100,8 +100,7 @@
\newconditional\c_math_fenced_mirror \settrue \c_math_fenced_mirror
\newconditional\c_math_fenced_sized \setfalse\c_math_fenced_sized
-
-\newcount\c_math_fence_nesting
+\newinteger \c_math_fence_nesting
\installcorenamespace {mathfencesize}
@@ -152,7 +151,7 @@
% \stopTEXpage
\newconstant\c_math_fenced_class
-\integerdef \c_math_fence_check \zerocount
+\newinteger \c_math_fence_check
\protected\def\math_fenced_common#1#2#3#4% \Uwhatever class symbol source
{\c_math_fenced_class\mathfenceparameter#2\relax
@@ -238,12 +237,12 @@
\fi}
\def\math_fenced_left
- {\advance\c_math_fence_nesting\plusone
+ {\advanceby\c_math_fence_nesting\plusone
\math_fenced_common\Uleft\c!leftclass\math_fenced_p_left\c!leftsource}
\def\math_fenced_right
{\math_fenced_common\Uright\c!rightclass\math_fenced_p_right\c!rightsource
- \advance\c_math_fence_nesting\minusone}
+ \advanceby\c_math_fence_nesting\minusone}
\def\math_fenced_middle_normal
{\math_fenced_common\Umiddle\c!middleclass\math_fenced_p_middle\c!middlesource}
@@ -532,7 +531,7 @@
%D \stopTEXpage
%D \stoptyping
-\newcount \c_math_fenced_level
+\newinteger \c_math_fenced_level
\newconditional\c_math_fenced_level_mode
\integerdef\c_math_fenced_stack \zerocount
@@ -542,8 +541,8 @@
\installcorenamespace{fencelevels}
\installcorenamespace{fencestack}
-\defcsname\??fencelevels+\endcsname{\advance\c_math_fenced_level\plusone }
-\defcsname\??fencelevels-\endcsname{\advance\c_math_fenced_level\minusone }
+\defcsname\??fencelevels+\endcsname{\advanceby\c_math_fenced_level\plusone }
+\defcsname\??fencelevels-\endcsname{\advanceby\c_math_fenced_level\minusone }
\defcsname\??fencelevels=\endcsname {\c_math_fenced_level\zerocount}
\letcsname\??fencelevels*\endcsname\donothing
@@ -557,7 +556,7 @@
\permanent\protected\def\F#1%
{\ifconditional\c_math_fenced_level_mode\else
- \integerdef\c_math_fence_check\c_math_fence_nesting
+ \c_math_fence_check\c_math_fence_nesting
\fi
\settrue\c_math_fenced_level_mode
\ifchknum#1\or
@@ -695,14 +694,14 @@
% \im { \left\lbrace \frac{1}{2} \right\rbrace }
\def\math_fenced_x_left
- {\advance\c_math_fence_nesting\plusone
+ {\advanceby\c_math_fence_nesting\plusone
\ifx\math_fenced_x_p_left\bgroup\let\math_fenced_x_p_left\letterleftbrace\fi
\math_fenced_common\Uleft\c!leftclass\math_fenced_x_p_left\c!leftsource}
\def\math_fenced_x_right
{\ifx\math_fenced_x_p_right\egroup\let\math_fenced_x_p_right\letterrightbrace\fi
\math_fenced_common\Uright\c!rightclass\math_fenced_x_p_right\c!rightsource
- \advance\c_math_fence_nesting\minusone}
+ \advanceby\c_math_fence_nesting\minusone}
\def\math_fenced_x_middle
{\math_fenced_common\Umiddle\c!middleclass\math_fenced_x_p_middle\c!middlesource}
diff --git a/tex/context/base/mkxl/math-frc.mkxl b/tex/context/base/mkxl/math-frc.mkxl
index 42e665f75..05e3957c7 100644
--- a/tex/context/base/mkxl/math-frc.mkxl
+++ b/tex/context/base/mkxl/math-frc.mkxl
@@ -183,7 +183,7 @@
\math_frac_no_strut
-\newdimen\d_math_fraction_margin
+\newdimension\d_math_fraction_margin
\def\math_fraction_margin_kern_indeed{\kern\d_math_fraction_margin}
diff --git a/tex/context/base/mkxl/math-ini.mkxl b/tex/context/base/mkxl/math-ini.mkxl
index 480a56642..8880956af 100644
--- a/tex/context/base/mkxl/math-ini.mkxl
+++ b/tex/context/base/mkxl/math-ini.mkxl
@@ -51,9 +51,9 @@
\unprotect
-\newdimen\mathstrutht
-\newdimen\mathstrutdp
-\newcount\mathnestinglevel
+\newdimension\mathstrutht
+\newdimension\mathstrutdp
+\newinteger \mathnestinglevel
\registerctxluafile{math-ini}{autosuffix}
\registerctxluafile{math-dim}{autosuffix}
@@ -512,7 +512,7 @@
\noitaliccorrectionclassoptioncode
% +\checkligatureclassoptioncode
+\checkkernpairclassoptioncode
- +\flattenclassoptioncode
+ % +\flattenclassoptioncode
\relax
\setmathoptions\mathoperatorcode\numexpr
@@ -541,7 +541,7 @@
+\noitaliccorrectionclassoptioncode
% +\checkligatureclassoptioncode
+\checkkernpairclassoptioncode
- +\flattenclassoptioncode
+ % +\flattenclassoptioncode
\relax
\setmathoptions\mathrelationcode\numexpr
@@ -549,7 +549,7 @@
+\noitaliccorrectionclassoptioncode
% +\checkligatureclassoptioncode
+\checkkernpairclassoptioncode
- +\flattenclassoptioncode
+ % +\flattenclassoptioncode
% +\omitpenaltyclassoptioncode
\relax
@@ -574,7 +574,7 @@
\defaultmathclassoptions
+\noitaliccorrectionclassoptioncode
% +\checkligatureclassoptioncode
- +\flattenclassoptioncode
+ % +\flattenclassoptioncode
+\checkkernpairclassoptioncode
+\removeitaliccorrectionclassoptioncode
\relax
@@ -724,10 +724,10 @@
%D
%D \start \blank \getbuffer \blank \stop
-% \newcount\mathnestinglevel % see top
+% \newinteger\mathnestinglevel % see top
\appendtoks
- \advance\mathnestinglevel\plusone
+ \advanceby\mathnestinglevel\plusone
\to \everymathematics
%D A few compatibility helpers:
@@ -1101,9 +1101,9 @@
% granular, but more clutter
%
-% \newskip\mathinterwordtextskip
-% \newskip\mathinterwordscriptskip
-% \newskip\mathinterwordscriptscriptskip
+% \newgluespec\mathinterwordtextskip
+% \newgluespec\mathinterwordscriptskip
+% \newgluespec\mathinterwordscriptscriptskip
%
% \appendtoks
% \mathinterwordtextskip \fontinterwordspace\textfont \zerocount \fontinterwordstretch\textfont \zerocount \fontinterwordshrink\textfont \zerocount \relax
@@ -1642,7 +1642,7 @@
%D \stopformula
%D \stoptyping
-\newcount\c_math_renderings_attribute
+\newinteger\c_math_renderings_attribute
\appendtoks
\c_math_renderings_attribute\clf_mathrenderset{\mathematicsparameter\c!symbolset}\relax
@@ -1867,8 +1867,8 @@
\permanent\protected\def\topstrut{\srule\s!width\zeropoint\s!height\strutht \s!depth\zeropoint\relax}
\permanent\protected\def\botstrut{\srule\s!width\zeropoint\s!height\zeropoint\s!depth\strutdp \relax}
-% \newdimen\mathstrutht % see top
-% \newdimen\mathstrutdp % see top
+% \newdimension\mathstrutht % see top
+% \newdimension\mathstrutdp % see top
\appendtoks
\mathstrutht\strutht
@@ -3367,7 +3367,7 @@
\crampedscriptstyle \or
\fi}
-\newcount\c_math_saved_style
+\newinteger\c_math_saved_style
\permanent\protected\def\pushmathstyle % assumes begingroup .. endgroup
{\c_math_saved_style\mathstyle}
@@ -3796,7 +3796,7 @@
\enforced\let\text\mathtext
\to \everymathematics
-\newcount\interdisplaylinepenalty \interdisplaylinepenalty\plushundred
+\newinteger\interdisplaylinepenalty \interdisplaylinepenalty\plushundred
%D Text in math:
@@ -3993,7 +3993,7 @@
%D Experiment, replaced by dictionaries but for now we keep the code as the domain key
%D might come back.
%
-% \newcount\c_math_domain_attribute
+% \newinteger\c_math_domain_attribute
%
% \def\math_domain_initialize
% {\ifnum\c_math_domain_attribute=\attributeunsetvalue \else
@@ -4491,7 +4491,7 @@
\scratchdimentwo-\Umathsubsupshiftdown\mathstyle
\math_axis_inject_indeed#2%
% \scratchdimenone.125\Umathfractionrule\mathstyle
- \divide\scratchdimenone\plustwo
+ \divideby\scratchdimenone\plustwo
\scratchdimentwo\Umathprimeshiftup\mathstyle
\math_axis_inject_indeed#2%
\fi}}
diff --git a/tex/context/base/mkxl/math-stc.mklx b/tex/context/base/mkxl/math-stc.mklx
index 8eb9d59ad..96ed80a89 100644
--- a/tex/context/base/mkxl/math-stc.mklx
+++ b/tex/context/base/mkxl/math-stc.mklx
@@ -288,8 +288,8 @@
% heads/tails + hoffset
\orelse\ifx\p_offset\v!min
% heads/tails - hoffset
- \advance\scratchleftoffset -\scratchhoffset
- \advance\scratchrightoffset-\scratchhoffset
+ \advanceby\scratchleftoffset -\scratchhoffset
+ \advanceby\scratchrightoffset-\scratchhoffset
\else % \v!normal
% hoffset
\scratchleftoffset\zeropoint
@@ -317,8 +317,8 @@
\scratchdepth\scratchdimen
\dp\scratchboxthree\scratchdepth
\fi
- \advance\scratchtopoffset -\scratchheight
- \advance\scratchbottomoffset-\scratchdepth
+ \advanceby\scratchtopoffset -\scratchheight
+ \advanceby\scratchbottomoffset-\scratchdepth
\ifdim\scratchtopoffset<\zeropoint
\scratchtopoffset\zeropoint
\fi
@@ -403,7 +403,7 @@
\ifdim\scratchwidth<\scratchdimen
\scratchwidth\scratchdimen
\fi
- \advance\scratchwidth2\scratchhoffset
+ \advanceby\scratchwidth2\scratchhoffset
%
\ifcase#method\relax
\dostarttagged\t!mstackermid\empty
@@ -543,12 +543,12 @@
\let\math_stackers_stop_group\endgroup
\fi}
-\newconstant\c_math_stackers_top
-\newconstant\c_math_stackers_bottom
-\newconstant\c_math_stackers_codepoint
-\newconstant\c_math_stackers_extracode
-\newdimen \d_math_stackers_offset_l
-\newdimen \d_math_stackers_offset_r
+\newconstant \c_math_stackers_top
+\newconstant \c_math_stackers_bottom
+\newconstant \c_math_stackers_codepoint
+\newconstant \c_math_stackers_extracode
+\newdimension\d_math_stackers_offset_l
+\newdimension\d_math_stackers_offset_r
\setupmathstackers[lt=\zeropoint,rt=\zeropoint,lb=\zeropoint,rb=\zeropoint]
@@ -587,7 +587,7 @@
\ifdim\scratchwidth<\scratchdimen
\scratchwidth\scratchdimen
\fi
- \advance\scratchwidth2\scratchhoffset
+ \advanceby\scratchwidth2\scratchhoffset
%
%\scratchunicode\c_math_stackers_codepoint
\ifcase\c_math_stackers_bottom
@@ -798,7 +798,7 @@
\ifdim\scratchwidth<\scratchdimen
\scratchwidth\scratchdimen
\fi
- \advance\scratchwidth2\scratchhoffset
+ \advanceby\scratchwidth2\scratchhoffset
%
\ifdim\wd\scratchboxone<\scratchwidth
\setbox\scratchboxone\hpack to \scratchwidth{\hss\unhbox\scratchboxone\hss}%
diff --git a/tex/context/base/mkxl/meta-ini.mkxl b/tex/context/base/mkxl/meta-ini.mkxl
index bd4445a2f..9a8b3f7f7 100644
--- a/tex/context/base/mkxl/meta-ini.mkxl
+++ b/tex/context/base/mkxl/meta-ini.mkxl
@@ -596,8 +596,8 @@
%D \uniqueMPgraphic{meta:hash}{gap=10pt,angle=30}
%D \stoptyping
-\newcount\c_meta_object_counter
-\newbox \b_meta_graphic
+\newinteger\c_meta_object_counter
+\newbox \b_meta_graphic
% hm, isn't this already done elsewhere?
@@ -648,7 +648,7 @@
\lastnamedcs
\else
\meta_enable_include % redundant
- \global\advance\c_meta_object_counter\plusone
+ \global\advanceby\c_meta_object_counter\plusone
\meta_use_box{\number\c_meta_object_counter}\hpack{\meta_process_graphic{#3}}% was vbox, graphic must end up as hbox
\xdefcsname\??mpgraphic\overlaystamp:#1\endcsname{\meta_reuse_box{\number\c_meta_object_counter}{\the\MPllx}{\the\MPlly}{\the\MPurx}{\the\MPury}}%
\csname\??mpgraphic\overlaystamp:#1\endcsname\empty
@@ -733,7 +733,7 @@
{\begingroup
% \currentmpcategory already set
\meta_enable_include % redundant
- \global\advance\c_meta_object_counter\plusone
+ \global\advanceby\c_meta_object_counter\plusone
\meta_use_box{\number\c_meta_object_counter}\hpack{\meta_process_graphic{#3}}% was vbox, graphic must end up as hbox
\xdefcsname\??mpgraphic#1\endcsname{\meta_reuse_box{\number\c_meta_object_counter}{\the\MPllx}{\the\MPlly}{\the\MPurx}{\the\MPury}}%
\csname\??mpgraphic#1\endcsname\empty
diff --git a/tex/context/base/mkxl/meta-nod.mkxl b/tex/context/base/mkxl/meta-nod.mkxl
index 17264d9b9..3cfc384aa 100644
--- a/tex/context/base/mkxl/meta-nod.mkxl
+++ b/tex/context/base/mkxl/meta-nod.mkxl
@@ -106,7 +106,7 @@
%D Hm, we started out simple but it now quickly becomes the usual mess of \TEX,
%D \METAPOST\ and \LUA. Hard to understand.
-\newcount\c_meta_nodes_n
+\newinteger\c_meta_nodes_n
\permanent\protected\lettonothing\stopnodes
@@ -154,7 +154,7 @@
\fi
);%
}}%
- \advance\c_meta_nodes_n\plusone}
+ \advanceby\c_meta_nodes_n\plusone}
\permanent\protected\lettonothing\placenode
diff --git a/tex/context/base/mkxl/meta-pdh.mkxl b/tex/context/base/mkxl/meta-pdh.mkxl
index 0313d0669..7f16ca340 100644
--- a/tex/context/base/mkxl/meta-pdh.mkxl
+++ b/tex/context/base/mkxl/meta-pdh.mkxl
@@ -466,7 +466,7 @@
%D \NC /N \NC smaller values, bigger inner circles \NC \NR
%D \stoptabulate
-% \newcount\currentPDFshade % 0 % global (document wide) counter
+% \newinteger\currentPDFshade % 0 % global (document wide) counter
%
% \def\dosetMPsomePDFshade#1#2%
% {\immediate\pdfobj
@@ -481,7 +481,7 @@
% /Function \the\pdflastobj\space 0 R
% /Coords [\MPshadeC]
% /Extend [true true]>>}%
-% \global\advance\currentPDFshade \plusone
+% \global\advanceby\currentPDFshade \plusone
% \ctxlua{lpdf.adddocumentshade("Sh\the\currentPDFshade",lpdf.reference(\the\pdflastobj))}%
% \setxvalue{\@@MPSK#2}{\noexpand\dohandleMPshade{\the\currentPDFshade}}}
%
diff --git a/tex/context/base/mkxl/mlib-pdf.mkxl b/tex/context/base/mkxl/mlib-pdf.mkxl
index d8b800ba1..744c461d7 100644
--- a/tex/context/base/mkxl/mlib-pdf.mkxl
+++ b/tex/context/base/mkxl/mlib-pdf.mkxl
@@ -20,15 +20,15 @@
%D Some code is shared between MPLIB and MPS. The following variables are also
%D available for introspection and other purposes.
-\ifdefined\MPwidth \else \newdimen\MPwidth \fi
-\ifdefined\MPheight \else \newdimen\MPheight \fi
+\newdimension\MPwidth
+\newdimension\MPheight
-\ifdefined\MPllx \else \newdimen\MPllx \fi
-\ifdefined\MPlly \else \newdimen\MPlly \fi
-\ifdefined\MPurx \else \newdimen\MPurx \fi
-\ifdefined\MPury \else \newdimen\MPury \fi
+\newdimension\MPllx
+\newdimension\MPlly
+\newdimension\MPurx
+\newdimension\MPury
-\ifdefined\MPbox \else \newbox \MPbox \fi
+\ifdefined\MPbox\else \newbox\MPbox\fi
\permanent\protected\def\setMPboundingbox#1#2#3#4% at some point we might pass them as base or scaled points
{\global\MPllx #1\onebasepoint
diff --git a/tex/context/base/mkxl/mult-aux.mkxl b/tex/context/base/mkxl/mult-aux.mkxl
index 93d1113a3..d45a48923 100644
--- a/tex/context/base/mkxl/mult-aux.mkxl
+++ b/tex/context/base/mkxl/mult-aux.mkxl
@@ -818,7 +818,7 @@
% todo: register namespaces at lua end for logging and reverse resolve
% todo: move this to syst-ini so that we can use it real early
-\newcount\c_mult_interfaces_n_of_namespaces
+\newinteger\c_mult_interfaces_n_of_namespaces
% \def\v_interfaces_prefix_template
% {\number\c_mult_interfaces_n_of_namespaces>}
@@ -830,7 +830,7 @@
{\ifcsname ????#1\endcsname
\writestatus\m!system{duplicate user namespace '#1'}\wait
\else
- \global\advance\c_mult_interfaces_n_of_namespaces\plusone
+ \global\advanceby\c_mult_interfaces_n_of_namespaces\plusone
\global\immutable\cdefcsname ????#1\endcsname{\v_interfaces_prefix_template}%
\fi}
@@ -838,7 +838,7 @@
{\ifcsname ??#1\endcsname
\writestatus\m!system{duplicate core namespace '#1'}\wait
\else
- \global\advance\c_mult_interfaces_n_of_namespaces\plusone
+ \global\advanceby\c_mult_interfaces_n_of_namespaces\plusone
\global\immutable\cdefcsname ??#1\endcsname{\v_interfaces_prefix_template}%
\clf_registernamespace\c_mult_interfaces_n_of_namespaces{#1}%
\fi}
@@ -992,11 +992,11 @@
%D Conventions:
%D
%D \starttyping
-%D \newcount \c_class_whatever
+%D \newinteger \c_class_whatever
%D \newconditional \c_class_whatever
%D \newconstant \c_class_whatever
-%D \newdimen \d_class_whatever
-%D \newskip \s_class_whatever
+%D \newdimension \d_class_whatever
+%D \newgluespec \s_class_whatever
%D \newmuskip \s_class_whatever
%D \newbox \b_class_whatever
%D \newtoks \t_class_whatever
@@ -1012,7 +1012,7 @@
\mutable\let\c_mult_set\relax
\protected\def\mult_interfaces_install_definition_set#1#2#3#4#5#6#7%
- {\newcount#3%
+ {\newinteger#3%
\lettonothing#6%
\protected\def#2%
{\expandafter\let\expandafter\c_mult_set\csname #1_t_#6\endcsname
@@ -1022,12 +1022,12 @@
\fi}
\frozen\protected\def#4##1%
{\pushmacro#6%
- \advance#3\plusone
+ \advanceby#3\plusone
\edef#6{##1}%
\unprotect}%
\frozen\protected\def#5%
{\protect
- \advance#3\minusone
+ \advanceby#3\minusone
\popmacro#6}%
\frozen\protected\def#7##1%
{\edef#6{##1}%
@@ -1087,12 +1087,12 @@
\permanent\protected\def\mult_interfaces_install_local_current_injector#1#2#3#4%
{\protected\def#4##1%
- {\advance#2\plusone
+ {\advanceby#2\plusone
\edef#3{##1:\the#2}% \currentXXX
\edefcsname#1#3:\s!parent\endcsname{#1##1}}}
\permanent\protected\def\installlocalcurrenthandler#1#2% \??XXX {XXX}
- {\expandafter\newcount\csname#1:\s!counter\endcsname
+ {\expandafter\newinteger\csname#1:\s!counter\endcsname
\normalexpanded{\mult_interfaces_install_local_current_injector
{\noexpand#1}%
\expandafter\noexpand\csname #1:\s!counter\endcsname
diff --git a/tex/context/base/mkxl/node-bck.lmt b/tex/context/base/mkxl/node-bck.lmt
index 5d4694600..0982871a3 100644
--- a/tex/context/base/mkxl/node-bck.lmt
+++ b/tex/context/base/mkxl/node-bck.lmt
@@ -52,6 +52,7 @@ local nexthlist = nuts.traversers.hlist
local nextlist = nuts.traversers.list
local flushnodelist = nuts.flushlist
+local flushnode = nuts.flush
local new_rule = nodepool.rule
local new_kern = nodepool.kern
@@ -166,7 +167,7 @@ local function add_alignbackgrounds(head,list)
local template = getprop(head,"alignmentchecked")
if template then
list = colored_b(head,list,template[1],hlist_code,template[2])
- flushnodelist(template)
+ flushnodelist(template[1])
templates[currentrow] = false
return list
end
diff --git a/tex/context/base/mkxl/node-fin.mkxl b/tex/context/base/mkxl/node-fin.mkxl
index 361744b8e..c0ad58f7d 100644
--- a/tex/context/base/mkxl/node-fin.mkxl
+++ b/tex/context/base/mkxl/node-fin.mkxl
@@ -27,7 +27,7 @@
%
% \definesystemattribute[trigger][public]
%
-% \newcount\c_syst_attr_trigger
+% \newinteger\c_syst_attr_trigger
%
% \permanent\edef\startinheritattributes{\c_attr_trigger\plusone}
% \permanent\edef\stopinheritattributes {\c_attr_trigger\attributeunsetvalue}
@@ -72,7 +72,7 @@
% This is just a compatibility hack:
-\newcount\c_syst_attr_trigger
+\newinteger\c_syst_attr_trigger
\permanent\protected\def\attributedcopy{\afterassignment\syst_attr_copy\c_syst_attr_trigger}
\permanent\protected\def\attributedbox {\afterassignment\syst_attr_box \c_syst_attr_trigger}
diff --git a/tex/context/base/mkxl/node-ini.mkxl b/tex/context/base/mkxl/node-ini.mkxl
index c843fc685..df2df0f18 100644
--- a/tex/context/base/mkxl/node-ini.mkxl
+++ b/tex/context/base/mkxl/node-ini.mkxl
@@ -15,7 +15,7 @@
\unprotect
-\newcount\filterstate \filterstate\plusone % hm, public
+\newinteger\filterstate \filterstate\plusone % hm, public
\registerctxluafile{node-cmp}{autosuffix}
\registerctxluafile{node-ini}{autosuffix}
@@ -42,7 +42,7 @@
%D This might go away (needs checking anyway, very old code):
-\newcount\c_node_tracers_show_box % box number
+\newinteger\c_node_tracers_show_box % box number
\permanent\protected\def\shownextnodes{\afterassignment\node_tracers_show_next\c_node_tracers_show_box}
\permanent\protected\def\showflatnodes{\afterassignment\node_tracers_show_flat\c_node_tracers_show_box}
diff --git a/tex/context/base/mkxl/node-rul.mkxl b/tex/context/base/mkxl/node-rul.mkxl
index 6f62e3022..24b7d5ef0 100644
--- a/tex/context/base/mkxl/node-rul.mkxl
+++ b/tex/context/base/mkxl/node-rul.mkxl
@@ -115,20 +115,20 @@
%D \underbar {\underdots{\samplefile{tufte}}}\par
%D \underdots{\underdots{\samplefile{tufte}}}\par
-\newcount\c_node_rules_nesting % todo: same as colors
-\newcount\c_node_rules_level
-\newcount\c_node_rules_up
-\newcount\c_node_rules_down
+\newinteger\c_node_rules_nesting % todo: same as colors
+\newinteger\c_node_rules_level
+\newinteger\c_node_rules_up
+\newinteger\c_node_rules_down
\permanent\protected\def\node_rules_set#1%
{\edef\currentbar{#1}%
- \advance\c_node_rules_level\plusone
+ \advanceby\c_node_rules_level\plusone
\usebarstyleandcolor\c!foregroundstyle\c!foregroundcolor
\edef\p_node_color {\barparameter\c!color}% todo
\edef\p_node_text {\barparameter\c!text}%
\edef\p_node_offset{\barparameter\c!offset}%
% better is a dedicated key: up/down .. todo
- \advance\ifdim\p_node_offset\onepoint<\zeropoint\c_node_rules_down\else\c_node_rules_up\fi\plusone
+ \advanceby\ifdim\p_node_offset\onepoint<\zeropoint\c_node_rules_down\else\c_node_rules_up\fi\plusone
\clf_setrule
continue {\barparameter\c!continue}%
unit {\barparameter\c!unit}%
@@ -178,7 +178,7 @@
% ungrouped % todo: use the lua based stacker
\permanent\protected\def\pushbar[#1]%
- {\global\advance\c_node_rules_nesting\plusone
+ {\global\advanceby\c_node_rules_nesting\plusone
\edefcsname\??barstack\number\c_node_rules_nesting\endcsname
{\c_node_rules_level\the\c_node_rules_level
\c_attr_ruled \the\c_attr_ruled}%
@@ -186,7 +186,7 @@
\permanent\protected\def\popbar
{\csname\??barstack\number\c_node_rules_nesting\endcsname\relax
- \global\advance\c_node_rules_nesting\minusone}
+ \global\advanceby\c_node_rules_nesting\minusone}
\setupbars
[\c!method=0, % new: 0=center nested, 1=stack nested
@@ -289,14 +289,14 @@
%D
%D \typebuffer \getbuffer
-\newdimen\d_rule_width
-\newdimen\d_rule_height
-\newdimen\d_rule_depth
-\newdimen\d_rule_h
-\newdimen\d_rule_v
-\newdimen\d_rule_line
-\newdimen\d_rule_offset
-\newdimen\d_rule_factor
+\newdimension\d_rule_width
+\newdimension\d_rule_height
+\newdimension\d_rule_depth
+\newdimension\d_rule_h
+\newdimension\d_rule_v
+\newdimension\d_rule_line
+\newdimension\d_rule_offset
+\newdimension\d_rule_factor
\mutable\lettonothing\m_rule_direction
%mutable\lettonothing\m_rule_factor
diff --git a/tex/context/base/mkxl/pack-bck.mklx b/tex/context/base/mkxl/pack-bck.mklx
index 3c15beb5f..e754c2451 100644
--- a/tex/context/base/mkxl/pack-bck.mklx
+++ b/tex/context/base/mkxl/pack-bck.mklx
@@ -131,7 +131,7 @@
\ifdim\scratchdimen<\zeropoint
\scratchdimen\pagegoal
\fi
- \advance\scratchdimen\dimexpr
+ \advanceby\scratchdimen\dimexpr
-\backgroundparameter\c!topoffset
-\backgroundparameter\c!bottomoffset
\relax
diff --git a/tex/context/base/mkxl/pack-box.mkxl b/tex/context/base/mkxl/pack-box.mkxl
index 746d225cb..5a66d3945 100644
--- a/tex/context/base/mkxl/pack-box.mkxl
+++ b/tex/context/base/mkxl/pack-box.mkxl
@@ -92,18 +92,18 @@
\def\pack_anchor_notdefined_two #1#2{\dowithnextbox{\pack_anchors_process_finish\currentanchor{#1}{#2}}\vbox}
\def\pack_anchors_process_indeed#1#2#3{\dowithnextbox{\pack_anchors_process_finish {#1}{#2}{#3}}\vbox}
-\newbox \b_pack_anchors
-\newdimen\d_pack_anchors_width
-\newdimen\d_pack_anchors_height
-\newdimen\d_pack_anchors_depth
+\newbox \b_pack_anchors
+\newdimension\d_pack_anchors_width
+\newdimension\d_pack_anchors_height
+\newdimension\d_pack_anchors_depth
% \definelayer[anchor]
-\newcount\c_pack_anchors_n
-\newtoks \t_pack_anchors_flush
+\newinteger\c_pack_anchors_n
+\newtoks \t_pack_anchors_flush
\protected\def\pack_anchors_register#1#2%
- {\global\advance\c_pack_anchors_n\plusone
+ {\global\advanceby\c_pack_anchors_n\plusone
\pagereference[\v!layer:\v!anchor:\number\c_pack_anchors_n]%
\putboxincache\v!anchor{\number\c_pack_anchors_n}\b_pack_anchors
% \xtoksapp\t_pack_anchors_flush{\pack_anchors_flush{\number\c_pack_anchors_n}{#1}{#2}}%
@@ -230,21 +230,21 @@
\defcsname\??collectorcorners\v!middle\endcsname
{\ifdim\d_pack_layers_x_size>\zeropoint
- \advance\d_pack_layers_x_position.5\d_pack_layers_x_size
+ \advanceby\d_pack_layers_x_position.5\d_pack_layers_x_size
\fi
\ifdim\d_pack_layers_y_size>\zeropoint
- \advance\d_pack_layers_y_position.5\d_pack_layers_y_size
+ \advanceby\d_pack_layers_y_position.5\d_pack_layers_y_size
\fi}
\defcsname\??collectorcorners\v!bottom\endcsname
{\ifdim\d_pack_layers_y_size>\zeropoint
- \advance\d_pack_layers_y_position-\d_pack_layers_y_size
+ \advanceby\d_pack_layers_y_position-\d_pack_layers_y_size
\d_pack_layers_y_position-\d_pack_layers_y_position
\fi}
\defcsname\??collectorcorners\v!right\endcsname
{\ifdim\d_pack_layers_x_size>\zeropoint
- \advance\d_pack_layers_x_position-\d_pack_layers_x_size
+ \advanceby\d_pack_layers_x_position-\d_pack_layers_x_size
\d_pack_layers_x_position-\d_pack_layers_x_position
\fi}
@@ -271,13 +271,13 @@
\setbox\nextbox\hpack
{\alignedbox[\collectorparameter\c!location]\vpack{\box\nextbox}}%
\boxmaxdepth\zeropoint % really needed, nice example
- \global\advance\boxhdisplacement\d_pack_layers_x_position
+ \global\advanceby\boxhdisplacement\d_pack_layers_x_position
\ifdim\boxhdisplacement<\zeropoint
\global\setbox\b_pack_boxes_collector\hpack
{\kern-\boxhdisplacement
\box\b_pack_boxes_collector}%
\fi
- \global\advance\boxvdisplacement\d_pack_layers_y_position
+ \global\advanceby\boxvdisplacement\d_pack_layers_y_position
\ifdim\boxvdisplacement<\zeropoint
\global\setbox\b_pack_boxes_collector\hpack
{\lower-\boxvdisplacement
@@ -393,8 +393,8 @@
\installsimpleframedcommandhandler \??layeredtext {layeredtext} \??layeredtext
-\newdimen\d_pack_layeredtexts_width
-\newdimen\d_pack_layeredtexts_height
+\newdimension\d_pack_layeredtexts_width
+\newdimension\d_pack_layeredtexts_height
\definelayer % private
[\??layeredtextlayer]
@@ -509,7 +509,7 @@
%
% \affiliation{drawing}{\externalfigure[hakker][width=3cm]}
-\newcount\c_pack_boxes_bleeds
+\newinteger\c_pack_boxes_bleeds
\installcorenamespace {bleeding}
@@ -553,7 +553,7 @@
\permanent\tolerant\protected\def\bleed[#1]%
{\hbox\bgroup
- \global\advance\c_pack_boxes_bleeds\plusone
+ \global\advanceby\c_pack_boxes_bleeds\plusone
%
\enforced\permanent\xdef\bleedwidth {\the\hsize}%
\enforced\permanent\xdef\bleedheight{\the\vsize}%
@@ -859,10 +859,10 @@
\pack_boxes_offset_check[#1]%
\dowithnextboxcs\pack_boxes_offsetfinish\hbox}
-\newcount\c_pack_boxes_offset_level
+\newinteger\c_pack_boxes_offset_level
\def\pack_boxes_offset_check
- {\advance\c_pack_boxes_offset_level\plusone
+ {\advanceby\c_pack_boxes_offset_level\plusone
\edef\currentoffsetbox{\the\c_pack_boxes_offset_level}%
\checkoffsetboxparent
\setupcurrentoffsetbox}
@@ -1030,8 +1030,8 @@
\ifcase\scratchcounter
% just one
\else
- \scratchdimen\scratchwidth \divide\scratchdimen\wd\nextbox\scratchnx\scratchdimen\advance\scratchnx\plusone\relax
- \scratchdimen\scratchheight\divide\scratchdimen\ht\nextbox\scratchny\scratchdimen\advance\scratchny\plusone\relax
+ \scratchdimen\scratchwidth \divideby\scratchdimen\wd\nextbox\scratchnx\scratchdimen\advanceby\scratchnx\plusone\relax
+ \scratchdimen\scratchheight\divideby\scratchdimen\ht\nextbox\scratchny\scratchdimen\advanceby\scratchny\plusone\relax
% to be considered: methods
\ifcase\scratchcounter
\or % x and y
@@ -1133,13 +1133,13 @@
[\c!xoffset=\zeropoint,
\c!yoffset=\zeropoint]
-\newcount\c_boxes_n_of_anchors
+\newinteger\c_boxes_n_of_anchors
\permanent\protected\def\defineanchorbox[#1]%
{\ifcsname\??boxanchorid#1\endcsname
\box\lastnamedcs\emptybox
\else
- \global\advance\c_boxes_n_of_anchors\plusone
+ \global\advanceby\c_boxes_n_of_anchors\plusone
\expandafter\integerdef\csname\??boxanchorid #1\endcsname\c_boxes_n_of_anchors
\expandafter\newbox \csname\??boxanchorbox#1\endcsname
\fi}
@@ -1234,18 +1234,18 @@
\permanent\def\boxanchorpresetcode#1%
{\ifcsname\??boxpreset#1\endcsname\lastnamedcs\else\halfwaytotallistanchorcode\fi}
-\newcount\registeredboxanchor
+\newinteger\registeredboxanchor
\installmacrostack\boxanchoringclass
\mutable\lettonothing\boxanchoringclass
-\newcount\c_anchor_auto_box_class
+\newinteger\c_anchor_auto_box_class
\permanent\protected\def\startboxanchoring[#1]% + == auto
{\push_macro_boxanchoringclass
\iftok{#1}{+}%
- \global\advance\c_anchor_auto_box_class\plusone
+ \global\advanceby\c_anchor_auto_box_class\plusone
\edef\boxanchoringclass{\the\c_anchor_auto_box_class::}%
\else
\edef\boxanchoringclass{#1}
@@ -1255,7 +1255,7 @@
{\pop_macro_boxanchoringclass}
\permanent\protected\def\registerboxanchor
- {\global\advance\registeredboxanchor\minusone}
+ {\global\advanceby\registeredboxanchor\minusone}
\permanent\protected\def\defineboxanchor[#1]%
{\registerboxanchor
diff --git a/tex/context/base/mkxl/pack-com.mkxl b/tex/context/base/mkxl/pack-com.mkxl
index 787fe4d96..0fff4ca1b 100644
--- a/tex/context/base/mkxl/pack-com.mkxl
+++ b/tex/context/base/mkxl/pack-com.mkxl
@@ -75,18 +75,24 @@
\globalresetsystemmode{combination}%
\to \everyinsidefloat
-\newcount\c_pack_combinations_nesting % local
-
-\newcount\c_pack_combinations_x % global
-\newcount\c_pack_combinations_y % global
-\newcount\c_pack_combinations_max % global
-
-\newdimen\d_pack_combinations_ht % global
-
-\newbox \b_pack_combinations_captions % global % can go
-\newbox \b_pack_combinations_temp % global % can go
-\newbox \b_pack_combinations_content % local
-\newbox \b_pack_combinations_caption % local
+\newinteger \c_pack_combinations_nesting % local
+
+\newinteger \c_pack_combinations_x % global
+\newinteger \c_pack_combinations_y % global
+\newinteger \c_pack_combinations_x_saved
+\newinteger \c_pack_combinations_y_saved
+\newinteger \c_pack_combinations_max % global
+\newinteger \c_pack_combinations_max_saved
+\newdimension\d_pack_combinations_ht % global
+\newdimension\d_pack_combinations_ht_saved
+\newbox \b_pack_combinations_captions % global % can go
+\newbox \b_pack_combinations_captions_saved
+\newbox \b_pack_combinations_temp % global % can go
+\newbox \b_pack_combinations_temp_saved
+\newbox \b_pack_combinations_content % local
+\newbox \b_pack_combinations_content_saved
+\newbox \b_pack_combinations_caption % local
+\newbox \b_pack_combinations_caption_saved
\installcorenamespace{combination}
@@ -95,21 +101,10 @@
\initializeboxstack{\??combination captions}
\initializeboxstack{\??combination temp}
-\newcount\c_pack_combinations_x_saved
-\newcount\c_pack_combinations_y_saved
-\newcount\c_pack_combinations_max_saved
-
-\newdimen\d_pack_combinations_ht_saved
-
-\newbox \b_pack_combinations_captions_saved
-\newbox \b_pack_combinations_temp_saved
-\newbox \b_pack_combinations_content_saved
-\newbox \b_pack_combinations_caption_saved
-
\setfalse\c_strc_constructions_define_commands
\def\pack_combinations_push
- {\advance\c_pack_combinations_nesting\plusone
+ {\advanceby\c_pack_combinations_nesting\plusone
\ifnum\c_pack_combinations_nesting>\plusone
\c_pack_combinations_x_saved \c_pack_combinations_x
\c_pack_combinations_y_saved \c_pack_combinations_y
@@ -136,7 +131,7 @@
\else
\globalresetsystemmode{combination}% why global
\fi
- \advance\c_pack_combinations_nesting\minusone}
+ \advanceby\c_pack_combinations_nesting\minusone}
\definelabel
[\v!combination] % handy for configuring
@@ -423,7 +418,7 @@
\dotagcombination
\global\setbox\b_pack_combinations_captions\emptybox
\global\c_pack_combinations_max\c_pack_combinations_x
- \multiply\c_pack_combinations_y\c_pack_combinations_x
+ \multiplyby\c_pack_combinations_y\c_pack_combinations_x
\tabskip\zeropoint
\enforced\permanent\protected\edef\combinationwidth % \immutable
{\the\dimexpr
@@ -526,8 +521,8 @@
% we need to save the caption for a next alignment line
\pack_combinations_save_caption}%
\ifnum\c_pack_combinations_y>\plusone
- \global\advance\c_pack_combinations_y\minusone
- \global\advance\c_pack_combinations_x\minusone
+ \global\advanceby\c_pack_combinations_y\minusone
+ \global\advanceby\c_pack_combinations_x\minusone
\ifcase\c_pack_combinations_x
\doubleexpandafter\pack_combinations_pickup_package_pair_a
\else
@@ -592,7 +587,7 @@
\foundbox{\??combinationcaption:\number\c_pack_combinations_nesting}{\number\c_pack_combinations_x}%
\vss
\egroup
- \global\advance\c_pack_combinations_x\minusone
+ \global\advanceby\c_pack_combinations_x\minusone
\ifnum\c_pack_combinations_x>\zerocount % \c_pack_combinations_max
\expandafter\pack_combinations_flush_captions_yes_followup
\else
@@ -812,9 +807,9 @@
% watch the hsize/vsize tricks
-\newbox \b_pack_pairedboxes_first
-\newbox \b_pack_pairedboxes_second
-\newdimen\s_pack_pairedboxes_size
+\newbox \b_pack_pairedboxes_first
+\newbox \b_pack_pairedboxes_second
+\newdimension\s_pack_pairedboxes_size
\appendtoks
\frozen\protected\instance\edefcsname\e!setup\currentpairedbox\e!endsetup\endcsname{\setuppairedbox [\currentpairedbox]}%
diff --git a/tex/context/base/mkxl/pack-cut.mkxl b/tex/context/base/mkxl/pack-cut.mkxl
index 3f4e6d0c3..772b2ba64 100644
--- a/tex/context/base/mkxl/pack-cut.mkxl
+++ b/tex/context/base/mkxl/pack-cut.mkxl
@@ -49,13 +49,13 @@
%D By setting the next macros one can influence the length of the marks as well as
%D the horizontal and vertical divisions.
-\newdimen\d_pack_cutmarks_width
-\newdimen\d_pack_cutmarks_height
-\newdimen\d_pack_cutmarks_depth
+\newdimension\d_pack_cutmarks_width
+\newdimension\d_pack_cutmarks_height
+\newdimension\d_pack_cutmarks_depth
-\newcount\horizontalcutmarks \horizontalcutmarks \plustwo
-\newcount\verticalcutmarks \verticalcutmarks \plustwo
-\newcount\cutmarkoffset \cutmarkoffset \plusone
+\newinteger \horizontalcutmarks \horizontalcutmarks \plustwo
+\newinteger \verticalcutmarks \verticalcutmarks \plustwo
+\newinteger \cutmarkoffset \cutmarkoffset \plusone
\mutable\let\cutmarksymbol \relax
\mutable\def\cutmarklength {2\bodyfontsize}
diff --git a/tex/context/base/mkxl/pack-lyr.mkxl b/tex/context/base/mkxl/pack-lyr.mkxl
index e1652273e..a3dd301c2 100644
--- a/tex/context/base/mkxl/pack-lyr.mkxl
+++ b/tex/context/base/mkxl/pack-lyr.mkxl
@@ -129,19 +129,19 @@
\newconditional\c_pack_layers_repeated
\newconditional\c_pack_layers_trace
-\newcount \c_pack_layers_current_data
+\newinteger \c_pack_layers_current_data
\newbox\b_layers \pushoverloadmode \mutable\let\b_layers\b_layers \popoverloadmode
-\newdimen\d_pack_layers_x_size
-\newdimen\d_pack_layers_y_size
-\newdimen\d_pack_layers_x_offset
-\newdimen\d_pack_layers_y_offset
-\newdimen\d_pack_layers_x_position
-\newdimen\d_pack_layers_y_position
+\newdimension\d_pack_layers_x_size
+\newdimension\d_pack_layers_y_size
+\newdimension\d_pack_layers_x_offset
+\newdimension\d_pack_layers_y_offset
+\newdimension\d_pack_layers_x_position
+\newdimension\d_pack_layers_y_position
-\newdimen\layerwidth
-\newdimen\layerheight
+\newdimension\layerwidth
+\newdimension\layerheight
\mutable\let\lastlayerxpos\!!zeropoint
\mutable\let\lastlayerypos\!!zeropoint
@@ -227,7 +227,7 @@
\def\pack_layers_set_indeed#1%
{\page_backgrounds_recalculate % brrr
- \global\advance\c_pack_layers_current_data\plusone
+ \global\advanceby\c_pack_layers_current_data\plusone
\forgetall
\dontcomplain
\edef\p_pack_layers_option{\layerparameter\c!option}%
@@ -401,11 +401,11 @@
\fi
\ifnum\p_pack_layers_line=\zerocount\else % no \ifcase, can be negative
% \ifzero\p_pack_layers_line\else % todo: test this
- \advance\d_pack_layers_y_position\dimexpr\p_pack_layers_line\lineheight+\topskip-\lineheight-\ht\nextbox\relax
+ \advanceby\d_pack_layers_y_position\dimexpr\p_pack_layers_line\lineheight+\topskip-\lineheight-\ht\nextbox\relax
\fi
\ifnum\p_pack_layers_column=\zerocount\else % no \ifcase, can be negative
% \ifzero\p_pack_layers_column\else % todo: test this
- \advance\d_pack_layers_x_position\layoutcolumnoffset\p_pack_layers_column\relax
+ \advanceby\d_pack_layers_x_position\layoutcolumnoffset\p_pack_layers_column\relax
\fi
\ifx\p_pack_layers_location\v!grid
\setbox\nextbox\hpack
@@ -416,14 +416,14 @@
\ifdim\scratchdimen<\getboxllx\b_layers_page
\gsetboxllx\b_layers_page\scratchdimen
\fi
- \advance\scratchdimen\wd\nextbox
+ \advanceby\scratchdimen\wd\nextbox
\wd\nextbox\ifdim\scratchdimen>\scratchwidth \scratchdimen \else \scratchwidth \fi
\scratchdimen\dimexpr\d_pack_layers_y_position+\d_pack_layers_y_offset\relax
\ifdim\scratchdimen<\getboxlly\b_layers_page
\gsetboxlly\b_layers_page\scratchdimen
\fi
% ll compensation
- \advance\scratchdimen\dimexpr\ht\nextbox+\dp\nextbox\relax
+ \advanceby\scratchdimen\dimexpr\ht\nextbox+\dp\nextbox\relax
\ht\nextbox\ifdim\scratchdimen>\scratchheight \scratchdimen \else \scratchheight \fi
\dp\nextbox\zeropoint
% placement
@@ -455,7 +455,7 @@
\edef\p_pack_layers_line{\the\numexpr-\p_pack_layers_line+\layoutlines+\plusone\relax}% use counter instead ?
\fi
\ifdim\d_pack_layers_y_size>\zeropoint
- \advance\d_pack_layers_y_position-\d_pack_layers_y_size
+ \advanceby\d_pack_layers_y_position-\d_pack_layers_y_size
\d_pack_layers_y_position-\d_pack_layers_y_position
\d_pack_layers_y_offset-\d_pack_layers_y_offset
\fi}
@@ -466,14 +466,14 @@
\edef\p_pack_layers_column{\the\numexpr-\layerparameter\c!column+\layoutcolumns+\plusone\relax}% use counter instead ?
\fi
\ifdim\d_pack_layers_x_size>\zeropoint
- \advance\d_pack_layers_x_position-\d_pack_layers_x_size
+ \advanceby\d_pack_layers_x_position-\d_pack_layers_x_size
\d_pack_layers_x_position-\d_pack_layers_x_position
\d_pack_layers_x_offset-\d_pack_layers_x_offset
\fi}
\def\pack_layers_set_middle_positions
- {\ifdim\d_pack_layers_x_size>\zeropoint \advance\d_pack_layers_x_position.5\d_pack_layers_x_size \fi
- \ifdim\d_pack_layers_y_size>\zeropoint \advance\d_pack_layers_y_position.5\d_pack_layers_y_size \fi}
+ {\ifdim\d_pack_layers_x_size>\zeropoint \advanceby\d_pack_layers_x_position.5\d_pack_layers_x_size \fi
+ \ifdim\d_pack_layers_y_size>\zeropoint \advanceby\d_pack_layers_y_position.5\d_pack_layers_y_size \fi}
%D Given the task to be accomplished, the previous macro is not even that
%D complicated. It mainly comes down to skipping to the right place and placing a
diff --git a/tex/context/base/mkxl/pack-mat.mkxl b/tex/context/base/mkxl/pack-mat.mkxl
index e336c195e..a810c8a47 100644
--- a/tex/context/base/mkxl/pack-mat.mkxl
+++ b/tex/context/base/mkxl/pack-mat.mkxl
@@ -21,7 +21,7 @@
% todo \v!mathframed
% todo \v!mathstrikeout
-\newconditional \c_framed_math_framed
+\newconditional\c_framed_math_framed
\installtextracker
{framed.math}
@@ -282,14 +282,14 @@
% mcframed xx\mcframed {x^2 + \frac{2}{x} + \sqrt{\frac{2}{\sqrt{\frac{2}{x}}}}} \input tufte
% mtframed xx\mtframed {x^2 + \frac{2}{x} + \sqrt{\frac{2}{\sqrt{\frac{2}{x}}}}} \input tufte
-\newcount\c_framed_mstyle
+\newinteger\c_framed_mstyle
\installcorenamespace{mathframed}
\installframedcommandhandler \??mathframed {mathframed} \??mathframed
-\newtoks \t_pack_framed_mathframed
-\newdimen\d_pack_framed_mathframed
+\newtoks \t_pack_framed_mathframed
+\newdimension\d_pack_framed_mathframed
\appendtoks
\frozen\protected\instance\edefcsname\currentmathframed\endcsname{\pack_framed_mathframed[\currentmathframed]}%
diff --git a/tex/context/base/mkxl/pack-mrl.mkxl b/tex/context/base/mkxl/pack-mrl.mkxl
index b4339b0b2..fbc51bef5 100644
--- a/tex/context/base/mkxl/pack-mrl.mkxl
+++ b/tex/context/base/mkxl/pack-mrl.mkxl
@@ -883,7 +883,7 @@
\c!width=\scratchwidth,
\c!height=\scratchheight,
\c!depth=\scratchheight]}%
- \frozen\advance\rightskip \directfillinlinesparameter\c!margin\relax
+ \frozen\advanceby\rightskip \directfillinlinesparameter\c!margin\relax
\frozen\parfillskip\zeropoint\relax
\endgroup}
diff --git a/tex/context/base/mkxl/pack-obj.mkxl b/tex/context/base/mkxl/pack-obj.mkxl
index e0cce8e08..6334c6ce9 100644
--- a/tex/context/base/mkxl/pack-obj.mkxl
+++ b/tex/context/base/mkxl/pack-obj.mkxl
@@ -39,15 +39,14 @@
\installcorenamespace {objects}
-\newif \ifinobject
-\newbox \b_pack_objects
-
\mutable\def\objectoffset{1cm} % Still public but use with care!
-\newdimen\d_pack_objects_offset \permanent\def\objectmargin{\the\d_pack_objects_offset}
-\newdimen\d_pack_objects_width \permanent\def\objectwidth {\the\d_pack_objects_width}
-\newdimen\d_pack_objects_height \permanent\def\objectheight{\the\d_pack_objects_height}
-\newdimen\d_pack_objects_depth \permanent\def\objectdepth {\the\d_pack_objects_depth}
+\newif \ifinobject
+\newbox \b_pack_objects
+\newdimension\d_pack_objects_offset \permanent\def\objectmargin{\the\d_pack_objects_offset}
+\newdimension\d_pack_objects_width \permanent\def\objectwidth {\the\d_pack_objects_width}
+\newdimension\d_pack_objects_height \permanent\def\objectheight{\the\d_pack_objects_height}
+\newdimension\d_pack_objects_depth \permanent\def\objectdepth {\the\d_pack_objects_depth}
%D If I have time I will use the unreferenced variant for e.g. mp reuse. This can be
%D rewritten in \LUA\ anyway.
diff --git a/tex/context/base/mkxl/pack-pos.mkxl b/tex/context/base/mkxl/pack-pos.mkxl
index 872d334a7..74ec38629 100644
--- a/tex/context/base/mkxl/pack-pos.mkxl
+++ b/tex/context/base/mkxl/pack-pos.mkxl
@@ -44,14 +44,14 @@
\c!xoffset=\zeropoint,
\c!yoffset=\zeropoint]
-\newdimen\d_pack_positioning_x_position
-\newdimen\d_pack_positioning_y_position
-\newdimen\d_pack_positioning_x_dimension
-\newdimen\d_pack_positioning_y_dimension
-\newdimen\d_pack_positioning_x_offset
-\newdimen\d_pack_positioning_y_offset
+\newdimension\d_pack_positioning_x_position
+\newdimension\d_pack_positioning_y_position
+\newdimension\d_pack_positioning_x_dimension
+\newdimension\d_pack_positioning_y_dimension
+\newdimension\d_pack_positioning_x_offset
+\newdimension\d_pack_positioning_y_offset
-\newbox\b_pack_positioning
+\newbox \b_pack_positioning
\permanent\tolerant\protected\def\startpositioning[#1]#*[#2]%
{\bgroup
@@ -84,8 +84,8 @@
\doifnot{\positioningparameter\c!offset}\v!yes
{\global\d_pack_positioning_x_offset\zeropoint
\global\d_pack_positioning_y_offset\zeropoint}%
- \global\advance\d_pack_positioning_x_dimension\d_pack_positioning_x_offset
- \global\advance\d_pack_positioning_y_dimension\d_pack_positioning_y_offset
+ \global\advanceby\d_pack_positioning_x_dimension\d_pack_positioning_x_offset
+ \global\advanceby\d_pack_positioning_y_dimension\d_pack_positioning_y_offset
\egroup
\vbox to \d_pack_positioning_y_dimension
{\vskip\d_pack_positioning_y_offset
@@ -100,10 +100,10 @@
{\setdimensionwithunit\scratchdimen{#1}{\positioningparameter\c!unit}%
\scratchdimen\positioningparameter#8\scratchdimen
\scratchdimen\positioningparameter#9\scratchdimen
- \advance\scratchdimen\positioningparameter#4\relax
+ \advanceby\scratchdimen\positioningparameter#4\relax
% == \scratchdimen\dimexpr#8\dimexpr#9\scratchdimen\relax+#4\relax
\doif{\positioningparameter#2}\v!relative
- {\advance\scratchdimen#3%
+ {\advanceby\scratchdimen#3%
\letpositioningparameter#4\zeropoint}%
#3\scratchdimen
\doifnot{\positioningparameter\c!state}\v!overlay
diff --git a/tex/context/base/mkxl/pack-rul.mkxl b/tex/context/base/mkxl/pack-rul.mkxl
index 3c4d77062..26b62d8b1 100644
--- a/tex/context/base/mkxl/pack-rul.mkxl
+++ b/tex/context/base/mkxl/pack-rul.mkxl
@@ -18,12 +18,12 @@
%D packaging and expansion we also keep tracing reasonable. For instance, multiple
%D stacked backgrounds can slow down a run if not optimized this way.
-\newcount\framednoflines
-\newdimen\framedfirstheight
-\newdimen\framedlastdepth
-\newdimen\framedminwidth
-\newdimen\framedmaxwidth
-\newdimen\framedaveragewidth
+\newinteger \framednoflines
+\newdimension\framedfirstheight
+\newdimension\framedlastdepth
+\newdimension\framedminwidth
+\newdimension\framedmaxwidth
+\newdimension\framedaveragewidth
\registerctxluafile{pack-rul}{autosuffix,optimize}
@@ -42,7 +42,7 @@
%D The linewidth is available in \type{\linewidth}. The preset value of .4pt equals
%D the default hard coded \TEX\ rule width.
-\newdimen\linewidth
+\newdimension\linewidth
\permanent\tolerant\protected\def\setuplinewidth[#1]%
{\assigndimension{#1}\linewidth{.2\points}{.4\points}{.6\points}}
@@ -205,10 +205,11 @@
%D We will communicate through module specific variables, current framed
%D parameters and some reserved dimension registers.
-\newdimen\d_framed_target_wd
-\newdimen\d_framed_target_ht
-\newdimen\d_framed_target_dp
-\newdimen\d_framed_linewidth \aliased\let\ruledlinewidth\d_framed_linewidth % needed at lua end
+\newdimension\d_framed_target_wd
+\newdimension\d_framed_target_ht
+\newdimension\d_framed_target_dp
+%newdimen \d_framed_linewidth \aliased\let \ruledlinewidth\d_framed_linewidth % needed at lua end
+\newdimension\d_framed_linewidth \aliasdimension\ruledlinewidth\d_framed_linewidth % needed at lua end
\lettonothing\p_framed_frame % \framedparameter\c!frame
\lettonothing\p_framed_backgroundoffset
@@ -414,11 +415,11 @@
%D
%D The resulting box is lowered to the right depth.
-\newdimen\d_overlay_width
-\newdimen\d_overlay_height
-\newdimen\d_overlay_depth
-\newdimen\d_overlay_offset
-\newdimen\d_overlay_linewidth
+\newdimension\d_overlay_width
+\newdimension\d_overlay_height
+\newdimension\d_overlay_depth
+\newdimension\d_overlay_offset
+\newdimension\d_overlay_linewidth
\lettonothing\m_overlay_region
@@ -550,10 +551,10 @@
%D Beware, a backgroundbox can be empty which is another reason why we set the
%D width to zero instead of back-skipping.
-\newdimen\framedbackgroundwidth
-\newdimen\framedbackgroundheight
-\newdimen\framedbackgrounddepth
-\newdimen\framedbackgroundoffset
+\newdimension\framedbackgroundwidth
+\newdimension\framedbackgroundheight
+\newdimension\framedbackgrounddepth
+\newdimension\framedbackgroundoffset
\aliased\let\foregroundbox\relax
@@ -631,7 +632,7 @@
\d_framed_target_ht\dimexpr\ht\b_framed_normal+ \d_framed_frameoffset\relax
\d_framed_target_dp\dimexpr\dp\b_framed_normal+ \d_framed_frameoffset+\framedparameter\c!framedepth\relax
\ifdim\d_framed_target_dp<\zeropoint
- \advance\d_framed_target_ht \d_framed_target_dp
+ \advanceby\d_framed_target_ht \d_framed_target_dp
\scratchdimen-\d_framed_target_dp
\d_framed_target_dp\zeropoint
\else
@@ -847,11 +848,11 @@
% \presetlocalframed[\??framed]
-\newcount\c_pack_framed_nesting
+\newinteger\c_pack_framed_nesting
\permanent\tolerant\protected\def\framed[#1]%
{\bgroup
- \advance\c_pack_framed_nesting\plusone
+ \advanceby\c_pack_framed_nesting\plusone
\letcsname\??framed>\the\c_pack_framed_nesting:\s!parent\endcsname\??framed
\edef\currentframed{>\the\c_pack_framed_nesting}%
\pack_framed_initialize
@@ -866,7 +867,7 @@
\bgroup
\or
\ifhastok={#1}%
- \advance\c_pack_framed_nesting\plusone
+ \advanceby\c_pack_framed_nesting\plusone
\letcsname\??framed>\the\c_pack_framed_nesting:\s!parent\endcsname\??framed
\edef\currentframed{>\the\c_pack_framed_nesting}%
\pack_framed_initialize
@@ -895,7 +896,7 @@
\permanent\protected\def\normalframedwithsettings[#1]%
{\bgroup
- \advance\c_pack_framed_nesting\plusone
+ \advanceby\c_pack_framed_nesting\plusone
\letcsname\??framed>\the\c_pack_framed_nesting:\s!parent\endcsname\??framed
\bgroup
\edef\currentframed{>\the\c_pack_framed_nesting}%
@@ -1075,11 +1076,11 @@
%D }
%D \stoptyping
-\newdimen\d_framed_width
-\newdimen\d_framed_height
-\newdimen\d_framed_frameoffset
-\newdimen\d_framed_backgroundoffset
-\newdimen\d_framed_local_offset
+\newdimension\d_framed_width
+\newdimension\d_framed_height
+\newdimension\d_framed_frameoffset
+\newdimension\d_framed_backgroundoffset
+\newdimension\d_framed_local_offset
% todo: protect local \framednames
@@ -1262,8 +1263,8 @@
% \d_framed_width\localhsize
% \fi
% i.e. disable (colsetbackgroundproblemintechniek)
- \advance\d_framed_width -2\d_framed_local_offset
- \advance\d_framed_height -2\d_framed_local_offset
+ \advanceby\d_framed_width -2\d_framed_local_offset
+ \advanceby\d_framed_height -2\d_framed_local_offset
\ifcsname\??framedstrutalternative\p_strut\endcsname
\lastnamedcs
\else
@@ -1684,7 +1685,7 @@
\d_framed_linewidth
\fi
\ifconditional\c_framed_has_offset
- \advance\d_framed_applied_offset\localoffset\relax
+ \advanceby\d_framed_applied_offset\localoffset\relax
\fi
\ifconditional\c_framed_has_extra_offset
\pack_framed_apply_extra_offsets % includes \d_framed_applied_offset
@@ -1778,10 +1779,10 @@
\def\pack_framed_locator_before#1{\begincsname\??framedlocatorbefore#1\endcsname}
\def\pack_framed_locator_after #1{\begincsname\??framedlocatorafter #1\endcsname}
-\newdimen\d_framed_locator_ht
-\newdimen\d_framed_locator_dp
-\newdimen\d_framed_locator_lo
-\newdimen\d_framed_locator_ro
+\newdimension\d_framed_locator_ht
+\newdimension\d_framed_locator_dp
+\newdimension\d_framed_locator_lo
+\newdimension\d_framed_locator_ro
\def\pack_framed_locator_set#1%
{\d_framed_locator_ht\dimexpr
@@ -1917,7 +1918,7 @@
{\pack_framed_remove_depth}
{\pack_framed_restore_depth}
-\newdimen\d_framed_formula
+\newdimension\d_framed_formula
\installframedlocator \v!formula % private, will become a more generic name
{}
@@ -1929,9 +1930,9 @@
% also used in fastlocalframed
-\newdimen\d_framed_original_wd
-\newdimen\d_framed_original_ht
-\newdimen\d_framed_original_dp
+\newdimension\d_framed_original_wd
+\newdimension\d_framed_original_ht
+\newdimension\d_framed_original_dp
\def\pack_framed_remove_depth
{\d_framed_original_wd\wd\b_framed_normal
@@ -1984,11 +1985,11 @@
%D This previous framing macros needs a lot of alternatives for putting rules around
%D boxes, inserting offsets and aligning text. Each step is handled by separate macros.
-\newdimen\d_framed_applied_offset
-\newdimen\d_framed_loffset
-\newdimen\d_framed_roffset
-\newdimen\d_framed_toffset
-\newdimen\d_framed_boffset
+\newdimension\d_framed_applied_offset
+\newdimension\d_framed_loffset
+\newdimension\d_framed_roffset
+\newdimension\d_framed_toffset
+\newdimension\d_framed_boffset
\def\pack_framed_check_extra_offsets % we could check h and v indepently
{\setfalse\c_framed_has_extra_offset
@@ -1996,17 +1997,17 @@
\d_framed_roffset\framedparameter\c!roffset\relax
\d_framed_toffset\framedparameter\c!toffset\relax
\d_framed_boffset\framedparameter\c!boffset\relax
- \ifzeropt\d_framed_loffset\else \advance\d_framed_width -\d_framed_loffset \settrue\c_framed_has_extra_offset \fi
- \ifzeropt\d_framed_roffset\else \advance\d_framed_width -\d_framed_roffset \settrue\c_framed_has_extra_offset \fi
- \ifzeropt\d_framed_toffset\else \advance\d_framed_height-\d_framed_toffset \settrue\c_framed_has_extra_offset \fi
- \ifzeropt\d_framed_boffset\else \advance\d_framed_height-\d_framed_boffset \settrue\c_framed_has_extra_offset \fi}
+ \ifzeropt\d_framed_loffset\else \advanceby\d_framed_width -\d_framed_loffset \settrue\c_framed_has_extra_offset \fi
+ \ifzeropt\d_framed_roffset\else \advanceby\d_framed_width -\d_framed_roffset \settrue\c_framed_has_extra_offset \fi
+ \ifzeropt\d_framed_toffset\else \advanceby\d_framed_height-\d_framed_toffset \settrue\c_framed_has_extra_offset \fi
+ \ifzeropt\d_framed_boffset\else \advanceby\d_framed_height-\d_framed_boffset \settrue\c_framed_has_extra_offset \fi}
\def\pack_framed_apply_extra_offsets
{\setbox\b_framed_normal\vpack\bgroup
- \advance\d_framed_toffset\d_framed_applied_offset
- \advance\d_framed_boffset\d_framed_applied_offset
- \advance\d_framed_loffset\d_framed_applied_offset
- \advance\d_framed_roffset\d_framed_applied_offset
+ \advanceby\d_framed_toffset\d_framed_applied_offset
+ \advanceby\d_framed_boffset\d_framed_applied_offset
+ \advanceby\d_framed_loffset\d_framed_applied_offset
+ \advanceby\d_framed_roffset\d_framed_applied_offset
\kern\d_framed_toffset
\hpack\bgroup
\kern\d_framed_loffset
@@ -2330,12 +2331,12 @@
%D It is possible to let the frame macro calculate the width of a centered box
%D automatically (\type {fit}). When doing so, we need to reshape the box:
-% \newcount\framednoflines
-% \newdimen\framedfirstheight
-% \newdimen\framedlastdepth
-% \newdimen\framedminwidth
-% \newdimen\framedmaxwidth
-% \newdimen\framedaveragewidth
+% \newinteger \framednoflines
+% \newdimension\framedfirstheight
+% \newdimension\framedlastdepth
+% \newdimension\framedminwidth
+% \newdimension\framedmaxwidth
+% \newdimension\framedaveragewidth
\def\pack_framed_reshape_reset
{\framednoflines \zerocount
@@ -2872,7 +2873,7 @@
\ifcsname\??regularframedlevel\currentframed\endcsname
% already defined, keeps settings
\else
- \expandafter\newcount\csname\??regularframedlevel\currentframed\endcsname
+ \expandafter\newinteger\csname\??regularframedlevel\currentframed\endcsname
\fi
\to \everypresetframed
@@ -2880,7 +2881,7 @@
\frozen\instance\setuevalue{\currentframed}{\pack_framed_defined_process[\currentframed]}%
\to \everydefineframed
-\newcount\c_temp_framed_crap
+\newinteger\c_temp_framed_crap
% \permanent\tolerant\protected\def\pack_framed_defined_process[#1]#*[#2]% official (not much checking, todo: parent)
% {\bgroup
@@ -2890,7 +2891,7 @@
% \else
% \let\c_pack_framed_temp\c_temp_framed_crap
% \fi
-% \advance\c_pack_framed_temp\plusone
+% \advanceby\c_pack_framed_temp\plusone
% \defcsname\??framed#1>\the\c_pack_framed_temp:\s!parent\endcsname{\??framed#1}% \inheritlocalframed
% \bgroup
% \edef\currentframed{#1>\the\c_pack_framed_temp}%
@@ -2906,7 +2907,7 @@
\else
\scratchcounter\c_temp_framed_crap
\fi
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\defcsname\??framed#1>\the\scratchcounter:\s!parent\endcsname{\??framed#1}% \inheritlocalframed
\bgroup
\edef\currentframed{#1>\the\scratchcounter}%
@@ -2998,8 +2999,8 @@
\scratchrightoffset \framedcontentparameter\c!rightoffset \relax
\scratchtopoffset \framedcontentparameter\c!topoffset \relax
\scratchbottomoffset\framedcontentparameter\c!bottomoffset\relax
- \advance\hsize\dimexpr-\scratchleftoffset-\scratchrightoffset \relax
- \advance\vsize\dimexpr-\scratchtopoffset -\scratchbottomoffset\relax
+ \advanceby\hsize\dimexpr-\scratchleftoffset-\scratchrightoffset \relax
+ \advanceby\vsize\dimexpr-\scratchtopoffset -\scratchbottomoffset\relax
\kern\scratchleftoffset
\vpack\bgroup
\vskip\scratchtopoffset
diff --git a/tex/context/base/mkxl/page-app.mkxl b/tex/context/base/mkxl/page-app.mkxl
index e8cc12aaa..9a800841d 100644
--- a/tex/context/base/mkxl/page-app.mkxl
+++ b/tex/context/base/mkxl/page-app.mkxl
@@ -21,9 +21,9 @@
\installframedcommandhandler \??fittingpage {fittingpage} \??fittingpage
-\newdimen\d_page_fitting_width
-\newdimen\d_page_fitting_height
-\newbox \b_page_fitting
+\newdimension\d_page_fitting_width
+\newdimension\d_page_fitting_height
+\newbox \b_page_fitting
\definepapersize
[fittingpage]
diff --git a/tex/context/base/mkxl/page-bck.mkxl b/tex/context/base/mkxl/page-bck.mkxl
index 597ab419e..bdea7b2fe 100644
--- a/tex/context/base/mkxl/page-bck.mkxl
+++ b/tex/context/base/mkxl/page-bck.mkxl
@@ -229,8 +229,8 @@
%D cached in dedicated boxes. The offsets and depth of the page are used for
%D alignment purposes.
-%newdimen\pageoffset % bleed
-%newdimen\pagedepth % built-in
+%newdimension\pageoffset % bleed
+%newdimension\pagedepth % built-in
%D We need a bit more clever mechanism in order to handle layers well. This means
%D that we cannot calculate both background at the same time since something may
@@ -291,11 +291,11 @@
\box#1}%
\fi}
-\newdimen\pagebackgroundhoffset % THESE WILL BECOME OBSOLETE
-\newdimen\pagebackgroundvoffset
-\newdimen\pagebackgroundoffset % used elsewhere
-\newdimen\pagebackgrounddepth
-\newdimen\pagebackgroundcompensation
+\newdimension\pagebackgroundhoffset % THESE WILL BECOME OBSOLETE
+\newdimension\pagebackgroundvoffset
+\newdimension\pagebackgroundoffset % used elsewhere
+\newdimension\pagebackgrounddepth
+\newdimension\pagebackgroundcompensation
\def\page_backgrounds_set_offsets % used in menus (we can use ifcsname's here)
{\ifconditional\c_page_backgrounds_some \ifconditional\c_page_backgrounds_new
@@ -485,8 +485,8 @@
\expandafter\page_backgrounds_setup_double
\fi[#1][#2][#3]}
-\newdimen\d_page_backgrounds_offset
-\newdimen\d_page_backgrounds_depth
+\newdimension\d_page_backgrounds_offset
+\newdimension\d_page_backgrounds_depth
\appendtoks
\edef\p_page_backgrounds_offset{\namedframedparameter{\??layoutbackgrounds\v!page}\c!offset}%
@@ -693,7 +693,7 @@
%
% \def\page_backgrounds_add_local_to_box_indeed#1%
% {\setbox#1\hbox{\localbackgroundframed{\??layoutbackgrounds\v!local}\v!local#1}%
-% \global\advance\localpositionnumber\plusone} % afterwards !
+% \global\advanceby\localpositionnumber\plusone} % afterwards !
%
% \let\page_backgrounds_add_local_to_box\gobbleoneargument
diff --git a/tex/context/base/mkxl/page-blk.mkxl b/tex/context/base/mkxl/page-blk.mkxl
index 5ce6dff53..9553ea643 100644
--- a/tex/context/base/mkxl/page-blk.mkxl
+++ b/tex/context/base/mkxl/page-blk.mkxl
@@ -33,7 +33,7 @@
\unprotect
-\newcount\c_pages_prerolled
+\newinteger\c_pages_prerolled
\permanent\protected\def\startpageblock[#1]%
{\page
diff --git a/tex/context/base/mkxl/page-box.mklx b/tex/context/base/mkxl/page-box.mklx
index 1cd668e95..3d78e73d8 100644
--- a/tex/context/base/mkxl/page-box.mklx
+++ b/tex/context/base/mkxl/page-box.mklx
@@ -205,8 +205,8 @@
\scratchheight\ht#box%
\scratchdepth \dp#box%
\setbox#box\hpack
- {\advance\scratchheight\dimexpr\scratchdepth+2\scratchoffset\relax
- \advance\scratchwidth \scratchoffset
+ {\advanceby\scratchheight\dimexpr\scratchdepth+2\scratchoffset\relax
+ \advanceby\scratchwidth \scratchoffset
\ifconditional#right\relax
\scratchdimen-\scratchoffset
\kern\scratchdimen
@@ -237,10 +237,10 @@
\scratchheight\ht#box%
\scratchdepth \dp#box%
\setbox#box\hpack
- {\advance\scratchheight\dimexpr\scratchdepth+2\scratchoffset\relax
- \advance\scratchwidth \scratchoffset
+ {\advanceby\scratchheight\dimexpr\scratchdepth+2\scratchoffset\relax
+ \advanceby\scratchwidth \scratchoffset
\doifbothsides
- {\advance\scratchwidth\scratchoffset
+ {\advanceby\scratchwidth\scratchoffset
\scratchdimen-\scratchoffset
\kern\scratchdimen}%
{\scratchdimen\zeropoint}
diff --git a/tex/context/base/mkxl/page-brk.mkxl b/tex/context/base/mkxl/page-brk.mkxl
index af558b591..31c7e64a4 100644
--- a/tex/context/base/mkxl/page-brk.mkxl
+++ b/tex/context/base/mkxl/page-brk.mkxl
@@ -40,7 +40,7 @@
% \definepagebreak[forsure][yes,+4]
\newconditional\c_page_breaks_enabled \settrue\c_page_breaks_enabled
-\newcount \c_page_breaks_prevpage
+\newinteger \c_page_breaks_prevpage
\newtoks\everybeforepagebreak
\newtoks\everyafterpagebreak
@@ -342,8 +342,8 @@
%D Test page breaks.
-% \newdimen \d_page_tests_test
-% \newconstant\c_page_tests_mode
+% \newdimension\d_page_tests_test
+% \newconstant \c_page_tests_mode
\newconstant\testpagemethod % old
\newconstant\testpagetrigger % old
diff --git a/tex/context/base/mkxl/page-col.mkxl b/tex/context/base/mkxl/page-col.mkxl
index 43330c9a7..c2598afc1 100644
--- a/tex/context/base/mkxl/page-col.mkxl
+++ b/tex/context/base/mkxl/page-col.mkxl
@@ -24,17 +24,15 @@
%D We reserve a counter for the number of columns as well as the current
%D column. Both are not to be changed by users!
-%newcount\nofcolumns \nofcolumns\plusone % already in core-ini.mkiv
-\newcount\mofcolumns \mofcolumns\plusone
-
-\newconstant\columndirection % 0:lr 1:rl
+%newinteger \nofcolumns \nofcolumns\plusone % already in core-ini.mkiv
+\newinteger \mofcolumns \mofcolumns\plusone
+\newdimension \columnwidth
+\newdimension \columndistance
+\newconstant \columndirection % 0:lr 1:rl
\setnewconstant\maxnofcolumns 50
\setnewconstant\allocatednofcolumns 0
-\newdimen\columnwidth
-\newdimen\columndistance
-
%D During initialization the temporary boxes are allocated. This enables us to
%D use as much columns as we want, without exhausting the pool of boxes too
%D fast. We could have packed them in one box, but we've got enough boxes.
@@ -125,7 +123,7 @@
\fi}
\protected\def\page_columns_all_next
- {\advance\mofcolumns\plusone
+ {\advanceby\mofcolumns\plusone
\edef\currentcolumn{\the\mofcolumns}%
\page_columns_action\relax
\ifnum\mofcolumns<\nofcolumns
@@ -141,7 +139,7 @@
\fi}
\protected\def\page_columns_rev_prev
- {\advance\mofcolumns\minusone
+ {\advanceby\mofcolumns\minusone
\edef\currentcolumn{\the\mofcolumns}%
\page_columns_action\relax
\ifnum\mofcolumns>\plusone
@@ -157,7 +155,7 @@
\protected\def\page_columns_mid_next
{\edef\currentcolumn{\the\mofcolumns}%
\page_columns_action\relax
- \advance\mofcolumns\plusone
+ \advanceby\mofcolumns\plusone
\ifnum\mofcolumns<\nofcolumns
\expandafter\page_columns_mid_next
\fi}
diff --git a/tex/context/base/mkxl/page-com.mkxl b/tex/context/base/mkxl/page-com.mkxl
index fbe6a0e70..525a7fd3a 100644
--- a/tex/context/base/mkxl/page-com.mkxl
+++ b/tex/context/base/mkxl/page-com.mkxl
@@ -34,12 +34,12 @@
\installcorenamespace{pagecommentlocations}
\installcorenamespace{pagecommentstates}
-\newdimen\d_page_comments_offset
-\newdimen\d_page_comments_page_width
-\newdimen\d_page_comments_page_height
-\newdimen\d_page_comments_width
-\newdimen\d_page_comments_height
-\newdimen\d_page_comments_distance
+\newdimension\d_page_comments_offset
+\newdimension\d_page_comments_page_width
+\newdimension\d_page_comments_page_height
+\newdimension\d_page_comments_width
+\newdimension\d_page_comments_height
+\newdimension\d_page_comments_distance
\newconditional\c_page_comment_enabled
diff --git a/tex/context/base/mkxl/page-cst.mkxl b/tex/context/base/mkxl/page-cst.mkxl
index d2058ec46..6e5ed2168 100644
--- a/tex/context/base/mkxl/page-cst.mkxl
+++ b/tex/context/base/mkxl/page-cst.mkxl
@@ -71,26 +71,26 @@
}%
\to \everydefinepagegrid
-\newdimen\d_page_grd_column_width
-\newdimen\d_page_grd_max_height
-\newdimen\d_page_grd_max_width
-\newdimen\d_page_grd_distance
+\newdimension\d_page_grd_column_width
+\newdimension\d_page_grd_max_height
+\newdimension\d_page_grd_max_width
+\newdimension\d_page_grd_distance
-\newdimen\d_page_grd_reserved_height
-\newdimen\d_page_grd_reserved_width
-\newcount\c_page_grd_reserved_state
+\newdimension\d_page_grd_reserved_height
+\newdimension\d_page_grd_reserved_width
+\newinteger \c_page_grd_reserved_state
-\newdimen\d_page_grd_gap_height
+\newdimension\d_page_grd_gap_height
-\newcount\c_page_grd_n_of_left
-\newcount\c_page_grd_n_of_right
-\newcount\c_page_grd_n_of_rows
-\newcount\c_page_grd_first_column
-\newcount\c_page_grd_last_column
+\newinteger \c_page_grd_n_of_left
+\newinteger \c_page_grd_n_of_right
+\newinteger \c_page_grd_n_of_rows
+\newinteger \c_page_grd_first_column
+\newinteger \c_page_grd_last_column
-\newbox \b_page_grd_collected
-\newbox \b_page_grd_column_rest
-\newbox \b_page_grd_column
+\newbox \b_page_grd_collected
+\newbox \b_page_grd_column_rest
+\newbox \b_page_grd_column
%D All the parameters are mandate!
@@ -303,7 +303,7 @@
\anch_mark_column_box\b_page_grd_column\privatescratchcounter
\page_marks_synchronize_column\c_page_grd_first_column\c_page_grd_last_column\privatescratchcounter\b_page_grd_column
\ifnum\privatescratchcounter>\c_page_grd_n_of_left
- \advance\privatescratchcounter-\c_page_grd_n_of_left
+ \advanceby\privatescratchcounter-\c_page_grd_n_of_left
\page_lines_add_numbers_to_box\b_page_grd_column\privatescratchcounter\c_page_grd_n_of_right\plustwo
\else
\page_lines_add_numbers_to_box\b_page_grd_column\privatescratchcounter\c_page_grd_n_of_left\plustwo
@@ -632,7 +632,7 @@
\c!default=\v!here,
\c!alternative=\v!a]
-\newdimen\d_page_grd_span_width
+\newdimension\d_page_grd_span_width
\let\page_grd_span_stop\relax
diff --git a/tex/context/base/mkxl/page-ffl.mkxl b/tex/context/base/mkxl/page-ffl.mkxl
index 7c04d01e1..02c56e2e9 100644
--- a/tex/context/base/mkxl/page-ffl.mkxl
+++ b/tex/context/base/mkxl/page-ffl.mkxl
@@ -75,8 +75,8 @@
%
% \stoptext
-\newdimen\d_page_adapts_preroll
-\newcount\c_page_adapts_pushed
+\newdimension\d_page_adapts_preroll
+\newinteger \c_page_adapts_pushed
% this assumes a constant textheight and no adaptations otherwise so we
% should block these for already set pages in adaptheight .. or we can
@@ -103,7 +103,7 @@
\relax
\putboxincache{\v!page:\number#1}{+}\nextbox
\normalexpanded{\adaptlayout[\number#1][\c!top=\the\scratchdimen]}%
- \global\advance\c_page_adapts_pushed\plusone
+ \global\advanceby\c_page_adapts_pushed\plusone
\endgroup}}
\def\page_otr_flush_top_content
@@ -114,7 +114,7 @@
\nointerlineskip
\par}%
\disposeboxesincache{\v!page:\number\realpageno}%
- \global\advance\c_page_adapts_pushed\minusone
+ \global\advanceby\c_page_adapts_pushed\minusone
\nointerlineskip
\fi}
@@ -156,24 +156,23 @@
%\c!color,
\c!width=\v!fit]
-\newcount\c_defining_facing_float
+\newinteger\c_defining_facing_float
\appendtoks
- \advance\c_defining_facing_float\plusone
+ \advanceby\c_defining_facing_float\plusone
\ifcase\c_defining_facing_float\or
\expanded{
\definefacingfloat[\currentfacingfloat:\v!left ][\currentfacingfloat]%
\definefacingfloat[\currentfacingfloat:\v!right][\currentfacingfloat]%
}%
\fi
- \advance\c_defining_facing_float\minusone
+ \advanceby\c_defining_facing_float\minusone
\to \everydefinefacingfloat
-\newcount\c_strc_floats_facing_saved
-\newcount\c_strc_floats_facing_flushed
-
-\newbox\b_strc_floats_facing_l
-\newbox\b_strc_floats_facing_r
+\newinteger\c_strc_floats_facing_saved
+\newinteger\c_strc_floats_facing_flushed
+\newbox \b_strc_floats_facing_l
+\newbox \b_strc_floats_facing_r
\let\m_strc_floats_state\relax
@@ -181,7 +180,7 @@
\def\strc_floats_facing_flush_indeed_step#1#2#3%
{\ifnum#2<#3\relax
- \advance#2\plusone
+ \advanceby#2\plusone
\donetrue
\writestatus
{facing}
@@ -202,10 +201,10 @@
\scratchcountersix \zerocount
% find first empty spread i.e. odd (left) and even (right) empty
\ifdim\pagetotal>\zeropoint
- \advance\scratchcounterone\plusone
+ \advanceby\scratchcounterone\plusone
\fi
\ifodd\scratchcounterone
- \advance\scratchcounterone\plusone
+ \advanceby\scratchcounterone\plusone
\fi
\writestatus
{facing}
@@ -214,15 +213,15 @@
\page_adapts_layout_preroll\scratchcounterone
\ifzeropt\d_page_adapts_preroll
% left empty
- \advance\scratchcounterone\plusone
+ \advanceby\scratchcounterone\plusone
\page_adapts_layout_preroll\scratchcounterone
\ifzeropt\d_page_adapts_preroll
% right empty
- \advance\scratchcounterone\minusone
+ \advanceby\scratchcounterone\minusone
\exitloop
\fi
\else
- \advance\scratchcounterone\plustwo
+ \advanceby\scratchcounterone\plustwo
\fi
}
\writestatus
@@ -241,7 +240,7 @@
\else
\exitloop
\fi
- \advance\scratchcounterone\plusone
+ \advanceby\scratchcounterone\plusone
}
\disposeboxesincache{\currentfacingfloat:\v!right}%
\disposeboxesincache{\currentfacingfloat:\v!left}%
@@ -304,7 +303,7 @@
\letfacingfloatparameter\c!width\v!fit
\ifx\p_width\v!frame
\setbox\scratchbox\hpack{\inheritedfacingfloatframed{}}%
- \advance\hsize-\wd\scratchbox
+ \advanceby\hsize-\wd\scratchbox
\orelse\ifx\p_width\v!fit
% whatever
\else
@@ -335,7 +334,7 @@
\doloop{%
\strc_floats_facing_flush_wrap\b_strc_floats_facing_l\v!left
\strc_floats_facing_flush_wrap\b_strc_floats_facing_r\v!right
- \global\advance\c_strc_floats_facing_saved\plusone
+ \global\advanceby\c_strc_floats_facing_saved\plusone
\ifvoid\b_strc_floats_facing_l\relax\ifvoid\b_strc_floats_facing_r\relax
\exitloop
\fi\fi}}
diff --git a/tex/context/base/mkxl/page-flt.mkxl b/tex/context/base/mkxl/page-flt.mkxl
index 32f04e6b3..8808ef00b 100644
--- a/tex/context/base/mkxl/page-flt.mkxl
+++ b/tex/context/base/mkxl/page-flt.mkxl
@@ -24,12 +24,12 @@
\defineinsertion[\s!bottomfloat]
\defineinsertion[\s!pagefloat]
-\newdimen \d_page_floats_inserted_bottom
-\newdimen \d_page_floats_inserted_top
-\newdimen \d_page_floats_inserted_page
-\newcount \c_page_floats_n_of_top \c_page_floats_n_of_top \plustwo
-\newcount \c_page_floats_n_of_bottom \c_page_floats_n_of_bottom\zerocount
-\newcount \c_page_floats_n_of_page \c_page_floats_n_of_page \plustwo
+\newdimension\d_page_floats_inserted_bottom
+\newdimension\d_page_floats_inserted_top
+\newdimension\d_page_floats_inserted_page
+\newinteger \c_page_floats_n_of_top \c_page_floats_n_of_top \plustwo
+\newinteger \c_page_floats_n_of_bottom \c_page_floats_n_of_bottom\zerocount
+\newinteger \c_page_floats_n_of_page \c_page_floats_n_of_page \plustwo
\newconstant\c_page_floats_insertions_topskip_mode % 1 = no topskip
@@ -57,24 +57,23 @@
\newconditional\c_page_floats_center_box_global
\newconditional\c_page_floats_compress_flushed \settrue\c_page_floats_compress_flushed
-\newdimen \d_page_floats_compress_distance
+\newdimension \d_page_floats_compress_distance
%D For the moment we keep this but they will become private too.
-\newcount\totalnoffloats % these will be redone ... handled at the lua end anyway
-\newcount\savednoffloats % these will be redone ... handled at the lua end anyway
-\newcount\nofcollectedfloats % communication channel
-\newdimen\maxcollectedfloatstotal % communication channel
+\newinteger \totalnoffloats % these will be redone ... handled at the lua end anyway
+\newinteger \savednoffloats % these will be redone ... handled at the lua end anyway
+\newinteger \nofcollectedfloats % communication channel
+\newdimension\maxcollectedfloatstotal % communication channel
+\newinteger \noffloatinserts % these will be redone ... handled at the lua end anyway
-\newcount\noffloatinserts % these will be redone ... handled at the lua end anyway
+\newbox \floattext
-\newbox \floattext
-
-\newdimen\floatwidth
-\newdimen\floatheight
-\newdimen\floatdepth
-\newdimen\floattextwidth
-\newdimen\floattextheight
+\newdimension\floatwidth
+\newdimension\floatheight
+\newdimension\floatdepth
+\newdimension\floattextwidth
+\newdimension\floattextheight
\newbox \floatbox
\newbox \savedfloatbox
diff --git a/tex/context/base/mkxl/page-flw.mkxl b/tex/context/base/mkxl/page-flw.mkxl
index ef92b9b52..c1d480e98 100644
--- a/tex/context/base/mkxl/page-flw.mkxl
+++ b/tex/context/base/mkxl/page-flw.mkxl
@@ -74,7 +74,7 @@
\fi
\to \everydefinetextflow
-\newcount\b_page_textflow_box
+\newinteger\b_page_textflow_box
\permanent\def\textflowcollector#1%
{\begincsname\??textflowbox#1\endcsname}
diff --git a/tex/context/base/mkxl/page-imp.mkxl b/tex/context/base/mkxl/page-imp.mkxl
index c9244224d..00a0430e6 100644
--- a/tex/context/base/mkxl/page-imp.mkxl
+++ b/tex/context/base/mkxl/page-imp.mkxl
@@ -55,8 +55,8 @@
\installcorenamespace{layoutarranger}
\installcorenamespace{layoutarrangeoption}
-\newcount \shippedoutpages
-\newcount \combinedpagescounter
+\newinteger \shippedoutpages
+\newinteger \combinedpagescounter
\newconstant \whichpagetoshipout % 0=all 1=odd 2=even
\newbox \shipoutscratchbox
\setnewconstant\shipoutfinalizemethod\plusone
@@ -124,7 +124,7 @@
% extension mechanism
-\newcount\c_page_boxes_flush_n % set at the lua end
+\newinteger\c_page_boxes_flush_n % set at the lua end
\let\page_boxes_flush_before\relax
\let\page_boxes_flush_after \relax
@@ -206,7 +206,7 @@
\clf_cleanupattributes}
\def\page_shipouts_normal#1%
- {\global\advance\shippedoutpages\plusone
+ {\global\advanceby\shippedoutpages\plusone
% this is not resource safe!
\ifempty\pagestoshipout
\ifcase\whichpagetoshipout\relax
@@ -276,17 +276,17 @@
\mutable\def\arrangedrotationO{0}
\mutable\def\arrangedrotationE{0}
-\newcount\arrangedpageN
-\newcount\arrangedpageM
+\newinteger\arrangedpageN
+\newinteger\arrangedpageM
-\newcount\arrangedpageT \arrangedpageT\plusone
-\newcount\arrangedpageX \arrangedpageX\plusone
-\newcount\arrangedpageY \arrangedpageY\plusone
+\newinteger\arrangedpageT \arrangedpageT\plusone
+\newinteger\arrangedpageX \arrangedpageX\plusone
+\newinteger\arrangedpageY \arrangedpageY\plusone
\def\page_paper_set_offsets
{\global\paperoffset\v_page_target_offset
- \global\advance\paperwidth -2\dimexpr\paperoffset/\arrangedpageX\relax
- \global\advance\paperheight-2\dimexpr\paperoffset/\arrangedpageY\relax}
+ \global\advanceby\paperwidth -2\dimexpr\paperoffset/\arrangedpageX\relax
+ \global\advanceby\paperheight-2\dimexpr\paperoffset/\arrangedpageY\relax}
\permanent\protected\def\doinstallarrangedoption#1#2%
{\gdefcsname\??layoutarrangeoption#1\endcsname{#2}}
@@ -448,7 +448,7 @@
\scratchcounter\numexpr\realpageno-\plusone\relax
\dosetmodulo\scratchcounter\arrangedpageT\scratchcounter
\ifcase\scratchcounter\else
- \advance\scratchcounter \plusone
+ \advanceby\scratchcounter \plusone
\dostepwiserecurse\scratchcounter\arrangedpageT\plusone
{\noheaderandfooterlines\page_otr_insert_dummy_page}%
\fi
@@ -466,7 +466,7 @@
\box\scratchbox\box#5\hss}}
\permanent\protected\def\gotonextarrangepage
- {\global\advance\arrangeno\plusone}
+ {\global\advanceby\arrangeno\plusone}
\permanent\protected\def\outputarrangedbox#1%
{\begingroup
@@ -512,7 +512,7 @@
{\showmessage\m!system{23}{\the\realpageno.\the\pageno\ifnum\subpageno>0 .\the\subpageno\fi,\number#1}}
\permanent\protected\def\advancearrangedpageN
- {\global\advance\arrangedpageN\plusone}
+ {\global\advanceby\arrangedpageN\plusone}
% TOP
@@ -1266,7 +1266,7 @@
\permanent\protected\protected\def\pusharrangedpageXY#1%
{\advancearrangedpageN
- \global\advance\arrangedpageM\plusone
+ \global\advanceby\arrangedpageM\plusone
\reportarrangedpage\arrangedpageN
\global\setbox\arrangedpageB\hpack \ifdim\v_page_target_width>\zeropoint to \v_page_target_width \fi
{\ifvoid\arrangedpageB\else
@@ -1372,11 +1372,10 @@
\lettonothing\page_boxes_h_shifts
\lettonothing\page_boxes_v_shifts
-\newcount\c_page_boxes_h_shifts
-\newcount\c_page_boxes_v_shifts
-
-\newdimen\d_page_boxes_h_shifts
-\newdimen\d_page_boxes_v_shifts
+\newinteger \c_page_boxes_h_shifts
+\newinteger \c_page_boxes_v_shifts
+\newdimension\d_page_boxes_h_shifts
+\newdimension\d_page_boxes_v_shifts
\let\page_boxes_apply_shift_print\gobbleoneargument
\let\page_boxes_apply_shift_paper\gobbleoneargument
@@ -1384,7 +1383,7 @@
\def\page_boxes_filter_shift#1#2#3% #1=\dimenx #2=\xpageshifts #3=\nofxpageshifts
{#1\zeropoint
\ifempty#2\else
- \global\advance#3\plusone
+ \global\advanceby#3\plusone
\getfromcommacommand[#2][#3]%
\ifempty\commalistelement
\global#3\plusone % we cycle
diff --git a/tex/context/base/mkxl/page-ini.mkxl b/tex/context/base/mkxl/page-ini.mkxl
index 92bb8167f..40cd87a42 100644
--- a/tex/context/base/mkxl/page-ini.mkxl
+++ b/tex/context/base/mkxl/page-ini.mkxl
@@ -28,10 +28,10 @@
%D Shipout control.
-\newcount\nofshipouts
+\newinteger\nofshipouts
\appendtoks
- \global\advance\nofshipouts\plusone
+ \global\advanceby\nofshipouts\plusone
\to \everyaftershipout
\newconditional\c_otr_shipout_enabled \settrue\c_otr_shipout_enabled
@@ -47,7 +47,7 @@
\protected\def\page_otr_shipout_nop
{\writestatus\m!system{ignoring shipout of real page \the\realpageno}%
- \global\advance\realpageno\minusone % else no flush of resources
+ \global\advanceby\realpageno\minusone % else no flush of resources
\dowithnextbox{\deadcycles\zerocount}}
% We don't support direct user \shipouts (weird: this does not work, bug?)
diff --git a/tex/context/base/mkxl/page-ins.mkxl b/tex/context/base/mkxl/page-ins.mkxl
index 7abcf408c..8d2dfe846 100644
--- a/tex/context/base/mkxl/page-ins.mkxl
+++ b/tex/context/base/mkxl/page-ins.mkxl
@@ -56,7 +56,7 @@
\page_inserts_check_anchoring
\to \everystarttext % or \everyjob
-\newcount\currentinsertionnumber % This is a count and not a macro !
+\newinteger\currentinsertionnumber % This is a count and not a macro !
\newtoks\t_page_inserts_list
@@ -167,7 +167,7 @@
%
% \fi
-\newcount\c_page_inserts_last_allocated
+\newinteger\c_page_inserts_last_allocated
\appendtoks
\ifempty\currentinsertionparent
@@ -175,7 +175,7 @@
% bad news
\else
%expandafter\newinsert\csname\??insertionnumber\currentinsertion\endcsname
- \global\advance\c_page_inserts_last_allocated\plusone
+ \global\advanceby\c_page_inserts_last_allocated\plusone
\global\expandafter\integerdef\csname\??insertionnumber\currentinsertion\endcsname\c_page_inserts_last_allocated
\page_inserts_synchronize_registers
\clf_defineinsertion
diff --git a/tex/context/base/mkxl/page-lay.mkxl b/tex/context/base/mkxl/page-lay.mkxl
index d030c3ff9..9fc767800 100644
--- a/tex/context/base/mkxl/page-lay.mkxl
+++ b/tex/context/base/mkxl/page-lay.mkxl
@@ -24,92 +24,92 @@
%D The dimensions related to layout areas are represented by real dimensions.
-\newdimen\paperheight \paperheight = 297mm
-\newdimen\paperwidth \paperwidth = 210mm
-\newdimen\paperoffset \paperoffset = \zeropoint
-\newdimen\paperbleed \paperbleed = \zeropoint
-\newdimen\spinewidth \spinewidth = \zeropoint
+\newdimension\paperheight \paperheight = 297mm
+\newdimension\paperwidth \paperwidth = 210mm
+\newdimension\paperoffset \paperoffset = \zeropoint
+\newdimension\paperbleed \paperbleed = \zeropoint
+\newdimension\spinewidth \spinewidth = \zeropoint
-\newdimen\printpaperheight \printpaperheight = \paperheight
-\newdimen\printpaperwidth \printpaperwidth = \paperwidth
+\newdimension\printpaperheight \printpaperheight = \paperheight
+\newdimension\printpaperwidth \printpaperwidth = \paperwidth
-\newdimen\makeupheight % calculated
-\newdimen\makeupwidth % calculated
+\newdimension\makeupheight % calculated
+\newdimension\makeupwidth % calculated
-\newdimen\textheight % calculated
-\newdimen\textwidth % calculated
+\newdimension\textheight % calculated
+\newdimension\textwidth % calculated
-\newdimen\topspace \topspace = 2cm
-\newdimen\backspace \backspace = \topspace
-\newdimen\cutspace \cutspace = \zeropoint
-\newdimen\bottomspace \bottomspace = \zeropoint
+\newdimension\topspace \topspace = 2cm
+\newdimension\backspace \backspace = \topspace
+\newdimension\cutspace \cutspace = \zeropoint
+\newdimension\bottomspace \bottomspace = \zeropoint
-\newdimen\headerheight \headerheight = 2cm
-\newdimen\footerheight \footerheight = \headerheight
+\newdimension\headerheight \headerheight = 2cm
+\newdimension\footerheight \footerheight = \headerheight
-\newdimen\topoffset \topoffset = \zeropoint
-\newdimen\backoffset \backoffset = \topoffset
+\newdimension\topoffset \topoffset = \zeropoint
+\newdimension\backoffset \backoffset = \topoffset
-\newdimen\leftmarginwidth \leftmarginwidth = 3cm
-\newdimen\rightmarginwidth \rightmarginwidth = \leftmarginwidth
+\newdimension\leftmarginwidth \leftmarginwidth = 3cm
+\newdimension\rightmarginwidth \rightmarginwidth = \leftmarginwidth
-\newdimen\leftedgewidth \leftedgewidth = 3cm
-\newdimen\rightedgewidth \rightedgewidth = \leftedgewidth
+\newdimension\leftedgewidth \leftedgewidth = 3cm
+\newdimension\rightedgewidth \rightedgewidth = \leftedgewidth
-\newdimen\topheight \topheight = \zeropoint
-\newdimen\bottomheight \bottomheight = \topheight
+\newdimension\topheight \topheight = \zeropoint
+\newdimension\bottomheight \bottomheight = \topheight
-\newcount\layoutlines \layoutlines = \zerocount
-\newcount\layoutcolumns \layoutcolumns = \zerocount
-\newdimen\layoutcolumndistance \layoutcolumndistance = \zeropoint
-\newdimen\layoutcolumnwidth \layoutcolumnwidth = \zeropoint
+\newinteger \layoutlines \layoutlines = \zerocount
+\newinteger \layoutcolumns \layoutcolumns = \zerocount
+\newdimension\layoutcolumndistance \layoutcolumndistance = \zeropoint
+\newdimension\layoutcolumnwidth \layoutcolumnwidth = \zeropoint
-\newdimen\totaltextwidth
+\newdimension\totaltextwidth
-\newdimen\textadaptive
+\newdimension\textadaptive
%D The next series of dimensions are complemented by left and rights ones.
-\newdimen\margindistance
-\newdimen\edgedistance
-\newdimen\marginwidth
-\newdimen\edgewidth
+\newdimension\margindistance
+\newdimension\edgedistance
+\newdimension\marginwidth
+\newdimension\edgewidth
%D Because a distance does not really makes sense when there is no area, we use a
%D zero distance in case there is no area.
%D The horizontal distances are:
-\newdimen\leftedgedistance
-\newdimen\rightedgedistance
-\newdimen\leftmargindistance
-\newdimen\rightmargindistance
+\newdimension\leftedgedistance
+\newdimension\rightedgedistance
+\newdimension\leftmargindistance
+\newdimension\rightmargindistance
%D The vertical distances are:
-\newdimen\topdistance
-\newdimen\headerdistance
-\newdimen\textdistance
-\newdimen\footerdistance
-\newdimen\bottomdistance
+\newdimension\topdistance
+\newdimension\headerdistance
+\newdimension\textdistance
+\newdimension\footerdistance
+\newdimension\bottomdistance
-\newdimen\textovershoot % available in pagebuilder
+\newdimension\textovershoot % available in pagebuilder
%D We need to calculate the extra distances:
-\newdimen\naturalmarginwidth
-\newdimen\naturaledgewidth
-\newdimen\naturalmargindistance
-\newdimen\naturaledgedistance
-\newdimen\naturalleftedgedistance
-\newdimen\naturalrightedgedistance
-\newdimen\naturalleftmargindistance
-\newdimen\naturalrightmargindistance
-\newdimen\naturaltopdistance
-\newdimen\naturalheaderdistance
-\newdimen\naturaltextdistance
-\newdimen\naturalfooterdistance
-\newdimen\naturalbottomdistance
+\newdimension\naturalmarginwidth
+\newdimension\naturaledgewidth
+\newdimension\naturalmargindistance
+\newdimension\naturaledgedistance
+\newdimension\naturalleftedgedistance
+\newdimension\naturalrightedgedistance
+\newdimension\naturalleftmargindistance
+\newdimension\naturalrightmargindistance
+\newdimension\naturaltopdistance
+\newdimension\naturalheaderdistance
+\newdimension\naturaltextdistance
+\newdimension\naturalfooterdistance
+\newdimension\naturalbottomdistance
%D Now we've come to the setup and definition commands.
@@ -134,7 +134,7 @@
\doifnothing{\directlayoutparameter\c!state}{\letlayoutparameter\c!state\v!start}%
\to \everydefinelayout
-\newcount\c_page_layouts_changed
+\newinteger\c_page_layouts_changed
\appendtoks
\ifcase\layoutsetupmode
@@ -561,7 +561,7 @@
\edef\currentlayouttarget{#1}%
\fi}
-\newdimen\d_page_minimum_paper_size \d_page_minimum_paper_size\luaexpr{math.pi}\onebasepoint
+\newdimension\d_page_minimum_paper_size \d_page_minimum_paper_size\luaexpr{math.pi}\onebasepoint
\protected\def\page_paper_set_current_indeed[#1][#2]%
{\edef\m_page_asked_paper{#1}% can be the restores
@@ -652,8 +652,8 @@
\def\page_paper_set_offsets % will move
{\global\paperoffset\v_page_target_offset
- \global\advance\paperwidth -2\paperoffset
- \global\advance\paperheight-2\paperoffset}
+ \global\advanceby\paperwidth -2\paperoffset
+ \global\advanceby\paperheight-2\paperoffset}
\fi
@@ -701,7 +701,7 @@
\ifdim\scratchdimen<\zeropoint
\scratchdimen\zeropoint
\fi
- \global\advance\makeupwidth\dimexpr
+ \global\advanceby\makeupwidth\dimexpr
-\rightmargindistance-\rightmarginwidth
-\rightedgedistance -\rightedgewidth
-\scratchdimen\relax
@@ -738,7 +738,7 @@
\ifdim\scratchdimen<\zeropoint
\scratchdimen\zeropoint
\fi
- \global\advance\makeupheight\dimexpr-\bottomdistance-\bottomheight-\scratchdimen\relax
+ \global\advanceby\makeupheight\dimexpr-\bottomdistance-\bottomheight-\scratchdimen\relax
\else
\global\makeupheight\layoutparameter\c!height\relax
\ifzeropt\bottomspace
@@ -801,7 +801,7 @@
\global\layoutcolumndistance\layoutparameter\c!columndistance
\global\layoutcolumnwidth\dimexpr\makeupwidth-\layoutcolumns\layoutcolumndistance+\layoutcolumndistance\relax
\ifnum\layoutcolumns>\plusone
- \global\divide\layoutcolumnwidth\layoutcolumns
+ \global\divideby\layoutcolumnwidth\layoutcolumns
\dorecurse\layoutcolumns\page_layouts_check_pseudo_column
\fi}
@@ -1078,10 +1078,10 @@
\installsetuponlycommandhandler \??adaptlayout {adaptlayout}
-\newdimen\d_page_adapts_pushed_text_height
-\newdimen\d_page_adapts_pushed_footer_height
-\newdimen\d_page_adapts_height
-\newdimen\d_page_adapts_delta
+\newdimension\d_page_adapts_pushed_text_height
+\newdimension\d_page_adapts_pushed_footer_height
+\newdimension\d_page_adapts_height
+\newdimension\d_page_adapts_delta
\appendtoks \global\d_page_adapts_delta\zeropoint \to \everyshipout
@@ -1121,8 +1121,8 @@
%
\global\d_page_adapts_delta-\dimexpr\adaptlayoutparameter\c!top\relax
%
- \global\advance\textheight \d_page_adapts_height
- \global\advance\footerheight-\d_page_adapts_height
+ \global\advanceby\textheight \d_page_adapts_height
+ \global\advanceby\footerheight-\d_page_adapts_height
\showmessage\m!layouts1{\the\dimexpr\d_page_adapts_height,\the\realpageno}%
% this will become a better one (do we need insert correction?)
\page_otr_command_set_vsize
@@ -1185,10 +1185,10 @@
\let\doifelselayoutsomeline\secondofthreearguments
\fi
-\permanent\def\compensatevsizeheader {\advance\textheight-\dimexpr\headerheight+\headerdistance\relax}
-\permanent\def\compensatevsizefooter {\advance\textheight-\dimexpr\footerheight+\footerdistance\relax}
-\permanent\def\globalcompensatevsizeheader{\global\advance\textheight-\dimexpr\headerheight+\headerdistance\relax}
-\permanent\def\globalcompensatevsizefooter{\global\advance\textheight-\dimexpr\footerheight+\footerdistance\relax}
+\permanent\def\compensatevsizeheader {\advanceby\textheight-\dimexpr\headerheight+\headerdistance\relax}
+\permanent\def\compensatevsizefooter {\advanceby\textheight-\dimexpr\footerheight+\footerdistance\relax}
+\permanent\def\globalcompensatevsizeheader{\global\advanceby\textheight-\dimexpr\headerheight+\headerdistance\relax}
+\permanent\def\globalcompensatevsizefooter{\global\advanceby\textheight-\dimexpr\footerheight+\footerdistance\relax}
\permanent\def\compensatevsizeheaderzero{\headerheight\zeropoint\page_layouts_set_distances}
\permanent\def\compensatevsizefooterzero{\footerheight\zeropoint\page_layouts_set_distances}
@@ -1225,8 +1225,8 @@
\doifelselayoutsomeline\v!header\compensatevsizeheader\compensatevsizeheaderzero
\doifelselayoutsomeline\v!footer\compensatevsizefooter\compensatevsizefooterzero}
-\newdimen\innermakeupwidth % special purpose
-\newdimen\innermakeupmargin % special purpose
+\newdimension\innermakeupwidth % special purpose
+\newdimension\innermakeupmargin % special purpose
\newconditional\innermakeupcompensation \settrue\innermakeupcompensation
@@ -1247,8 +1247,8 @@
\global\innermakeupmargin\m_currentlayout_text_margin\relax
\fi
\scratchdimen\dimexpr\innermakeupmargin+\innermakeupmargin\relax
- \global\advance\innermakeupwidth-\scratchdimen
- \advance\textwidth-\scratchdimen} % local
+ \global\advanceby\innermakeupwidth-\scratchdimen
+ \advanceby\textwidth-\scratchdimen} % local
\permanent\protected\def\calculatehsizes % name will change
{\freezetextwidth
@@ -1306,7 +1306,7 @@
\expandafter\page_layouts_if_odd_else_again
\fi}
-\newdimen\texthoffset
+\newdimension\texthoffset
\permanent\protected\def\settexthoffset % name will change
{\texthoffset\doifbothsides\backspace\backspace{\dimexpr\paperwidth-\backspace-\makeupwidth\relax}}
diff --git a/tex/context/base/mkxl/page-lin.mklx b/tex/context/base/mkxl/page-lin.mklx
index 7383ab4ca..d16d19942 100644
--- a/tex/context/base/mkxl/page-lin.mklx
+++ b/tex/context/base/mkxl/page-lin.mklx
@@ -56,7 +56,7 @@
\mutable\let\linenumber\!!zerocount
\newbox \b_page_lines_scratch
-\newcount \c_page_lines_reference
+\newinteger \c_page_lines_reference
\newconstant\c_page_lines_nesting
\newconditional\tracelinenumbering % we keep this for old times sake
@@ -133,7 +133,7 @@
\protected\def\page_lines_some_reference#1#2#3%
{\dontleavehmode\begingroup
- \global\advance\c_page_lines_reference\plusone
+ \global\advanceby\c_page_lines_reference\plusone
\c_attr_linereference\c_page_lines_reference
#3% todo: #3{#1} as there is no need to pass #1 as part of #3
% for the moment we use a simple system i.e. no prefixes etc .. todo: store as number
@@ -158,8 +158,10 @@
\setnewconstant\c_page_lines_location \plusone % 0=middle, 1=left, 2=right, 3=inner, 4=outer, 5=text, 6=begin, 7=end
\setnewconstant\c_page_lines_alignment\plusfive % 0=middle, 1=left, 2=right, 5=auto
-\newdimen\d_page_lines_width
-\newdimen\d_page_lines_distance
+\newdimension \d_page_lines_width
+\newdimension \d_page_lines_distance
+
+\newinteger \c_pages_lines_nesting
\newevery \beforeeverylinenumbering \relax
\newevery \aftereverylinenumbering \relax
@@ -196,12 +198,10 @@
% \startlinenumbering[<startvalue>|continue|settings|name]
% \startlinenumbering[name][<startvalue>|continue|settings]
-\newcount\c_pages_lines_nesting
-
\permanent\tolerant\protected\def\startlinenumbering[#1]#*[#2]%
{\begingroup
\page_postprocessors_linenumbers_check
- \advance\c_pages_lines_nesting\plusone
+ \advanceby\c_pages_lines_nesting\plusone
\ifnum\c_pages_lines_nesting>\plusone
\expandafter\gobbletwooptionals
\orelse\ifparameter#2\or
@@ -288,17 +288,17 @@
\ifhmode \else
\ifx\p_location\v!text
\ifdim\leftskip>\zeropoint \else
- \advance\leftskip\linenumberingparameter\c!margin
+ \advanceby\leftskip\linenumberingparameter\c!margin
\settrue\c_page_lines_auto_narrow
\fi
\orelse\ifx\p_location\v!begin
\ifdim\leftskip>\zeropoint \else
- \advance\leftskip\linenumberingparameter\c!margin
+ \advanceby\leftskip\linenumberingparameter\c!margin
\settrue\c_page_lines_auto_narrow
\fi
\orelse\ifx\p_location\v!end
\ifdim\leftskip>\zeropoint \else
- \advance\rightskip\linenumberingparameter\c!margin
+ \advanceby\rightskip\linenumberingparameter\c!margin
\settrue\c_page_lines_auto_narrow
\fi
\fi
diff --git a/tex/context/base/mkxl/page-mbk.mklx b/tex/context/base/mkxl/page-mbk.mklx
index 9999fb8c7..57c23abc6 100644
--- a/tex/context/base/mkxl/page-mbk.mklx
+++ b/tex/context/base/mkxl/page-mbk.mklx
@@ -152,7 +152,7 @@
\marginblockparameter\c!bottom
\egroup
\ifdim\htdp\scratchbox>\textheight
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
%\writestatus{quit}{\the\scratchcounter=>\the\htdp\scratchbox}
\quitloop
\else
diff --git a/tex/context/base/mkxl/page-mcl.mkxl b/tex/context/base/mkxl/page-mcl.mkxl
index 416d22348..3faf13db7 100644
--- a/tex/context/base/mkxl/page-mcl.mkxl
+++ b/tex/context/base/mkxl/page-mcl.mkxl
@@ -54,19 +54,19 @@
\installframedcommandhandler \??multicolumns {multicolumns} \??multicolumns
-\newdimen \d_page_mcl_available_width
-\newdimen \d_page_mcl_distance
-\newdimen \d_page_mcl_leftskip
-\newdimen \d_page_mcl_rightskip
-\newdimen \d_page_mcl_used_width
-\newdimen \d_page_mcl_temp
-\newdimen \d_page_mcl_saved_pagetotal % brrr, still needed ?
+\newdimension \d_page_mcl_available_width
+\newdimension \d_page_mcl_distance
+\newdimension \d_page_mcl_leftskip
+\newdimension \d_page_mcl_rightskip
+\newdimension \d_page_mcl_used_width
+\newdimension \d_page_mcl_temp
+\newdimension \d_page_mcl_saved_pagetotal % brrr, still needed ?
-\newcount \c_page_mcl_balance_minimum
-\newcount \c_page_mcl_n_of_lines
+\newinteger \c_page_mcl_balance_minimum
+\newinteger \c_page_mcl_n_of_lines
\newbox \b_page_mcl_preceding
-\newdimen \d_page_mcl_preceding_height
+\newdimension \d_page_mcl_preceding_height
\newconditional\c_page_mcl_preceding_present
\newbox \b_page_mcl_rest_of_page
@@ -85,10 +85,10 @@
\newbox \b_page_mcl_balance_content
\newconstant \c_page_mcl_balance_tries_max
-\newcount \c_page_mcl_balance_tries
-\newdimen \d_page_mcl_balance_target
-\newdimen \d_page_mcl_balance_natural_height
-\newdimen \d_page_mcl_balance_step
+\newinteger \c_page_mcl_balance_tries
+\newdimension \d_page_mcl_balance_target
+\newdimension \d_page_mcl_balance_natural_height
+\newdimension \d_page_mcl_balance_step
\newconditional\c_page_mcl_balance_possible
\c_page_mcl_balance_tries_max 250 % 100 is too small when floats are involved
@@ -294,7 +294,7 @@
\settrue\c_page_mcl_balance_possible
\else % check criterium to available lines
\getnoflines{\ht\b_page_mcl_balance_content}%
- \divide\noflines \nofcolumns \relax
+ \divideby\noflines \nofcolumns \relax
\ifnum\noflines<\c_page_mcl_balance_minimum \relax
\ifdim\dimexpr\ht\b_page_mcl_balance_content+\openlineheight\relax>\makeupheight
\settrue\c_page_mcl_balance_possible % column exceeding text height
@@ -326,7 +326,7 @@
\def\page_mcl_balance_try_one
{\d_page_mcl_balance_target\dimexpr\ht\b_page_mcl_balance_content+\topskip-\baselineskip\relax
- \divide\d_page_mcl_balance_target \nofcolumns
+ \divideby\d_page_mcl_balance_target \nofcolumns
\vbadness\plustenthousand
\c_page_mcl_balance_tries\zerocount
\bgroup
@@ -345,18 +345,18 @@
\egroup}
\def\page_mcl_balance_try_one_attempt
- {\advance\c_page_mcl_balance_tries \plusone
+ {\advanceby\c_page_mcl_balance_tries \plusone
\global\setbox\b_page_mcl_rest_of_page\copy\b_page_mcl_balance_content\relax
\dohandleallcolumns{\page_mcl_split_column\b_page_mcl_rest_of_page\d_page_mcl_balance_target}%
\d_page_mcl_balance_natural_height\zeropoint
\dohandleallcolumns\page_mcl_balance_try_one_attempt_step
-\advance\d_page_mcl_balance_natural_height-33\scaledpoint % some slack
+\advanceby\d_page_mcl_balance_natural_height-33\scaledpoint % some slack
\ifnum\c_page_mcl_balance_tries>\c_page_mcl_balance_tries_max\relax
\exitloop
\orelse\ifdim\ht\b_page_mcl_rest_of_page>\zeropoint
- \advance\d_page_mcl_balance_target\d_page_mcl_balance_step\relax
+ \advanceby\d_page_mcl_balance_target\d_page_mcl_balance_step\relax
\orelse\ifdim\d_page_mcl_balance_natural_height>\ht\firstcolumnbox\relax
- \advance\d_page_mcl_balance_target\d_page_mcl_balance_step\relax
+ \advanceby\d_page_mcl_balance_target\d_page_mcl_balance_step\relax
\else
\exitloop
\fi}
diff --git a/tex/context/base/mkxl/page-mix.mkxl b/tex/context/base/mkxl/page-mix.mkxl
index 0210d75b3..3d1179483 100644
--- a/tex/context/base/mkxl/page-mix.mkxl
+++ b/tex/context/base/mkxl/page-mix.mkxl
@@ -114,22 +114,22 @@
%D In order to avoid a mixup we use quite some local registers.
-\newdimen \d_page_mix_column_width
-\newdimen \d_page_mix_max_height
-\newdimen \d_page_mix_max_width
-\newdimen \d_page_mix_distance
-\newcount \c_page_mix_n_of_columns
-\newdimen \d_page_mix_threshold
-\newdimen \d_page_mix_leftskip
-\newdimen \d_page_mix_rightskip
-
-\newdimen \d_page_mix_balance_step
+\newdimension \d_page_mix_column_width
+\newdimension \d_page_mix_max_height
+\newdimension \d_page_mix_max_width
+\newdimension \d_page_mix_distance
+\newinteger \c_page_mix_n_of_columns
+\newdimension \d_page_mix_threshold
+\newdimension \d_page_mix_leftskip
+\newdimension \d_page_mix_rightskip
+
+\newdimension \d_page_mix_balance_step
\setnewconstant\c_page_mix_balance_cycles 500
\setnewconstant\c_page_mix_break_forced -123
\newbox \b_page_mix_preceding
-\newdimen \d_page_mix_preceding_height
+\newdimension \d_page_mix_preceding_height
\newbox \b_page_mix_collected
@@ -619,11 +619,11 @@
% \vskip-\struttotal % probably no longer needed
% \fi}
-\newcount\c_page_mix_otr_nesting
+\newinteger\c_page_mix_otr_nesting
% \defcsname\??mixedcolumnsbefore\s!otr\endcsname
% {\par
-% \global\advance\c_page_mix_otr_nesting\plusone
+% \global\advanceby\c_page_mix_otr_nesting\plusone
% \ifcase\c_page_mix_otr_nesting\or
% \ifzeropt\pagetotal\else
% \obeydepth % we could handle this in pre material
@@ -632,7 +632,7 @@
\defcsname\??mixedcolumnsbefore\s!otr\endcsname
{\par
- \global\advance\c_page_mix_otr_nesting\plusone
+ \global\advanceby\c_page_mix_otr_nesting\plusone
\ifcase\c_page_mix_otr_nesting\or
\ifzeropt\pagetotal\else
% make sure that whitespace and blanks are done
@@ -694,7 +694,7 @@
\page_otr_command_set_vsize
\page_otr_command_set_hsize
\fi
- \global\advance\c_page_mix_otr_nesting\minusone}
+ \global\advanceby\c_page_mix_otr_nesting\minusone}
%D The splitting and therefore balancing is done at the \LUA\ end. This gives
%D more readable code and also makes it easier to deal with insertions like
@@ -728,9 +728,9 @@
\relax
\deadcycles\zerocount}
-\newdimen\mixedcolumnseparatorheight
-\newdimen\mixedcolumnseparatordepth
-\newdimen\mixedcolumnseparatorwidth
+\newdimension\mixedcolumnseparatorheight
+\newdimension\mixedcolumnseparatordepth
+\newdimension\mixedcolumnseparatorwidth
\def\page_mix_routine_package_step
{% needs packaging anyway
@@ -999,7 +999,7 @@
% \setbox\scratchbox\vbox % tricky met objecten ?
% {\blank[\rootfloatparameter\c!spacebefore]
% \snaptogrid\vbox{\vskip\floatheight}}% copy?
-% \advance\dimen0\dimexpr\ht\scratchbox+2\openlineheight+.5\lineheight\relax\relax % needed because goal a bit higher
+% \advanceby\dimen0\dimexpr\ht\scratchbox+2\openlineheight+.5\lineheight\relax\relax % needed because goal a bit higher
% \ifdim\dimen0>\dimen2
% \global\setfalse\c_page_floats_room
% \else
diff --git a/tex/context/base/mkxl/page-mrk.mkxl b/tex/context/base/mkxl/page-mrk.mkxl
index 76b6e0745..597cff17d 100644
--- a/tex/context/base/mkxl/page-mrk.mkxl
+++ b/tex/context/base/mkxl/page-mrk.mkxl
@@ -39,9 +39,9 @@
\newconditional\c_page_marks_add_page_lines
\newconditional\c_page_marks_add_more_number
-\newcount\c_page_marks_max
-\newcount\c_page_marks_nx
-\newcount\c_page_marks_ny
+\newinteger \c_page_marks_max
+\newinteger \c_page_marks_nx
+\newinteger \c_page_marks_ny
\startuniqueMPgraphic{print:color}{w,h,l,o}
loadmodule "crop" ;
@@ -143,7 +143,7 @@
\ifconditional\c_page_marks_add_more_number
\page_marks_add_number
\fi
- \global\advance\c_page_marks_max\minusone
+ \global\advanceby\c_page_marks_max\minusone
\ifnum\c_page_marks_max>\zerocount\else
\glet\page_marks_add_more\gobbleoneargument
\glet\page_marks_add_page\gobbleoneargument
diff --git a/tex/context/base/mkxl/page-not.mkxl b/tex/context/base/mkxl/page-not.mkxl
index 82523cc66..a13e4884d 100644
--- a/tex/context/base/mkxl/page-not.mkxl
+++ b/tex/context/base/mkxl/page-not.mkxl
@@ -19,7 +19,7 @@
\unprotect
-\newdimen\totalinsertionheight
+\newdimension\totalinsertionheight
\permanent\protected\def\settotalinsertionheight
{\calculatetotalnoteheight
diff --git a/tex/context/base/mkxl/page-one.mkxl b/tex/context/base/mkxl/page-one.mkxl
index 40d7d0af0..8571c2982 100644
--- a/tex/context/base/mkxl/page-one.mkxl
+++ b/tex/context/base/mkxl/page-one.mkxl
@@ -85,7 +85,7 @@
\global\pageextragoal-\textadaptive
\fi
%
- \global\advance\vsize\d_page_adapts_delta
+ \global\advanceby\vsize\d_page_adapts_delta
% alternatively we could set it in builders.buildpage_filter
% \ifdim\pagegoal<\maxdimen .. \fi
% \writestatus{!!!!!!!!}{\the\vsize-> v:\the\pagevsize,g:\the\pagegoal,t:\the\pagetotal,i:\the\insertheights}%
@@ -142,9 +142,9 @@
% \expandafter\firstofoneargument
\fi}
-\newdimen\d_page_one_natural_depth
-\newbox \b_page_one_bottom_notes
-\newbox \b_page_one_contents
+\newdimension\d_page_one_natural_depth
+\newbox \b_page_one_bottom_notes
+\newbox \b_page_one_contents
\let\page_one_command_package_show_state\relax
@@ -235,7 +235,7 @@
%D \stoptext
%D \stoptyping
-\newcount\c_page_one_stretch % we use marked pages which actually slow down a little
+\newinteger\c_page_one_stretch % we use marked pages which actually slow down a little
\def\page_one_check_stretch_contents
{\ifdim\dimexpr\textheight-\ht\b_page_one_contents\relax<\c_page_one_stretch\lineheight
@@ -334,7 +334,7 @@
\newconditional\c_page_one_top_of_insert
\newconditional\c_page_one_correct_top_insert \settrue\c_page_one_correct_top_insert % false moves up (tight)
-\newskip \s_page_one_between_top_insert
+\newgluespec \s_page_one_between_top_insert
\def\page_one_prepare_top_float
{\ifzeropt\d_page_floats_inserted_top
@@ -343,7 +343,7 @@
\setfalse\c_page_one_top_of_insert
\fi
\s_page_one_between_top_insert\ifdim\d_strc_floats_top>\d_strc_floats_bottom\d_strc_floats_top\else\d_strc_floats_bottom\fi\relax
- \global\advance\d_page_floats_inserted_top\dimexpr\ht\floatbox+\dp\floatbox+\s_page_one_between_top_insert\relax}
+ \global\advanceby\d_page_floats_inserted_top\dimexpr\ht\floatbox+\dp\floatbox+\s_page_one_between_top_insert\relax}
\def\page_one_insert_top_float % maybe remember last beforeskip
{\floatingpenalty\zerocount
@@ -391,7 +391,7 @@
\xdef\totaltopinserted{\the\d_page_floats_inserted_top}%
\page_one_insert_top_float
\ifconditional\c_page_floats_some_waiting
- \advance\noffloatinserts \plusone
+ \advanceby\noffloatinserts \plusone
\else
\noffloatinserts\c_page_floats_n_of_top\relax
\fi
@@ -419,7 +419,7 @@
\def\page_one_command_set_bottom_insertions_indeed
{\ifnum\noffloatinserts<\c_page_floats_n_of_bottom\relax
\page_floats_get
- \global\advance\d_page_floats_inserted_bottom\dimexpr\ht\floatbox+\dp\floatbox+\d_strc_floats_top\relax
+ \global\advanceby\d_page_floats_inserted_bottom\dimexpr\ht\floatbox+\dp\floatbox+\d_strc_floats_top\relax
\ifdim\d_page_floats_inserted_bottom<\pagegoal\relax
\floatingpenalty\zerocount
\page_inserts_inject\namedinsertionnumber\s!bottomfloat\bgroup
@@ -428,7 +428,7 @@
\page_otr_command_flush_float_box
\egroup
\ifconditional\c_page_floats_some_waiting
- \advance\noffloatinserts \plusone
+ \advanceby\noffloatinserts \plusone
\else
\noffloatinserts\c_page_floats_n_of_bottom
\fi
@@ -595,10 +595,10 @@
\or
% method 1 : safe
% too fuzzy as it can change and for a high page it's a lot : \scratchdimentwo .99\pagegoal
- \advance\scratchdimentwo -\strutdp
+ \advanceby\scratchdimentwo -\strutdp
\or
% method 2 : tight
- \advance\scratchdimenone -\onepoint
+ \advanceby\scratchdimenone -\onepoint
\fi
\relax % really needed ! ! ! !
\ifdim\scratchdimenone>\scratchdimentwo
@@ -798,7 +798,7 @@
\page_floats_report_total}
\def\page_one_place_float_bottom_indeed
- {\global\advance\d_page_floats_inserted_bottom\dimexpr\ht\floatbox+\dp\floatbox+\d_strc_floats_top\relax
+ {\global\advanceby\d_page_floats_inserted_bottom\dimexpr\ht\floatbox+\dp\floatbox+\d_strc_floats_top\relax
\floatingpenalty\zerocount
\page_inserts_inject\namedinsertionnumber\s!bottomfloat\bgroup
\forgetall
diff --git a/tex/context/base/mkxl/page-otr.mklx b/tex/context/base/mkxl/page-otr.mklx
index adca25eb5..d88a16c06 100644
--- a/tex/context/base/mkxl/page-otr.mklx
+++ b/tex/context/base/mkxl/page-otr.mklx
@@ -94,9 +94,9 @@
\newconstant\c_page_otr_eject_penalty \c_page_otr_eject_penalty -\plustenthousand
\newconstant\c_page_otr_super_penalty \c_page_otr_super_penalty -\plustwentythousand
-\newcount \c_page_otr_trigger_penalty \c_page_otr_trigger_penalty -100010
+\newinteger \c_page_otr_trigger_penalty \c_page_otr_trigger_penalty -100010
-\newcount \c_page_otr_columns % we will share this one
+\newinteger \c_page_otr_columns % we will share this one
\newif \ifinotr % we keep this (name) for old times sake
@@ -135,7 +135,7 @@
\endgroup}
\permanent\protected\def\installoutputroutine#invoke#action% \invoke \action
- {\global\advance\c_page_otr_trigger_penalty\minusone
+ {\global\advanceby\c_page_otr_trigger_penalty\minusone
\frozen\protected\edef#invoke{\page_otr_trigger{\number\c_page_otr_trigger_penalty}}%
\setvalue{\??otrtriggers\number\c_page_otr_trigger_penalty}{#action}}
diff --git a/tex/context/base/mkxl/page-pcl.mkxl b/tex/context/base/mkxl/page-pcl.mkxl
index f546a6119..d6298982c 100644
--- a/tex/context/base/mkxl/page-pcl.mkxl
+++ b/tex/context/base/mkxl/page-pcl.mkxl
@@ -30,17 +30,17 @@
\definemeasure[threecolumns][\dimexpr\plusthree\columnwidth+\plustwo \columndistance\relax]
\definemeasure[fourcolumns] [\dimexpr\plusfour \columnwidth+\plusthree\columndistance\relax]
-\newcount \c_page_col_n_of_columns \c_page_col_n_of_columns\plusone
-\newcount \c_page_col_current \c_page_col_current \plusone
-\newdimen \d_page_col_distance
-\newdimen \d_page_col_max_height
-\newdimen \d_page_col_max_width
-%newdimen \d_page_col_balance_step
-\newdimen \d_page_col_column_width
-\newdimen \d_page_col_top_height
-\newdimen \d_page_col_top_width
-\newdimen \d_page_col_available
-\newdimen \d_page_col_sofar
+\newinteger \c_page_col_n_of_columns \c_page_col_n_of_columns\plusone
+\newinteger \c_page_col_current \c_page_col_current \plusone
+\newdimension \d_page_col_distance
+\newdimension \d_page_col_max_height
+\newdimension \d_page_col_max_width
+%newdimension \d_page_col_balance_step
+\newdimension \d_page_col_column_width
+\newdimension \d_page_col_top_height
+\newdimension \d_page_col_top_width
+\newdimension \d_page_col_available
+\newdimension \d_page_col_sofar
\newconditional\c_page_col_page
%D We need to step over empty columns.
@@ -70,7 +70,7 @@
\fi
\page_otr_eject_page
\scratchcounterone\c_page_col_current
- \advance\scratchcounterthree\plusone
+ \advanceby\scratchcounterthree\plusone
\fi
}%
\endgroup}
@@ -217,7 +217,7 @@
\endgroup
\fi
\fi
- \global\advance\c_page_col_current\plusone
+ \global\advanceby\c_page_col_current\plusone
\fi
%
\page_col_notes_synchronize
@@ -293,10 +293,10 @@
% % method 0 : raw
% \or
% % method 1 : safe
-% \advance\scratchdimentwo -\strutdp
+% \advanceby\scratchdimentwo -\strutdp
% \or
% % method 2 : tight
-% \advance\scratchdimenone -\onepoint
+% \advanceby\scratchdimenone -\onepoint
% \fi
% \relax % really needed ! ! ! !
% \ifdim\scratchdimenone>\scratchdimentwo
@@ -334,10 +334,10 @@
% method 0 : raw
\or
% method 1 : safe
- \advance\scratchdimentwo -\strutdp
+ \advanceby\scratchdimentwo -\strutdp
\or
% method 2 : tight
- \advance\scratchdimenone -\onepoint
+ \advanceby\scratchdimenone -\onepoint
\fi
\relax % really needed ! ! ! !
\ifdim\scratchdimenone>\scratchdimentwo
@@ -360,7 +360,7 @@
{\ifnum\c_page_col_current=\c_page_col_n_of_columns
\c_page_col_current\plusone
\else
- \advance\c_page_col_current\plusone
+ \advanceby\c_page_col_current\plusone
\fi
\page_col_command_set_hsize
\hsize\d_page_col_available}
@@ -515,7 +515,7 @@
\xdef\totaltopinserted{\the\d_page_floats_inserted_top}%
\page_one_insert_top_float
\ifconditional\c_page_floats_some_waiting
- \advance\noffloatinserts \plusone
+ \advanceby\noffloatinserts \plusone
\else
\noffloatinserts\c_page_floats_n_of_top\relax
\fi
@@ -546,9 +546,9 @@
%D The separator code is more or less the same as mixed columns but we need
%D to compensate for the top floats so we comment a bit for now.
-\newdimen\pagecolumnseparatorheight
-\newdimen\pagecolumnseparatordepth
-\newdimen\pagecolumnseparatorwidth
+\newdimension\pagecolumnseparatorheight
+\newdimension\pagecolumnseparatordepth
+\newdimension\pagecolumnseparatorwidth
% \installcorenamespace{pagecolumnsseparator}
%
diff --git a/tex/context/base/mkxl/page-pst.mkxl b/tex/context/base/mkxl/page-pst.mkxl
index 79e3be29d..45d049760 100644
--- a/tex/context/base/mkxl/page-pst.mkxl
+++ b/tex/context/base/mkxl/page-pst.mkxl
@@ -49,7 +49,7 @@
%D and we also can erase buffers easier when we keep a local cache, especially as we
%D can flush per page.
-\newcount \c_page_postponed_blocks_next_page % set at the lua end
+\newinteger \c_page_postponed_blocks_next_page % set at the lua end
\newconditional\c_page_postponed_busy
\mutable\lettonothing\currentpostponedpage
diff --git a/tex/context/base/mkxl/page-sel.mklx b/tex/context/base/mkxl/page-sel.mklx
index f6b3840a9..6344a0cc9 100644
--- a/tex/context/base/mkxl/page-sel.mklx
+++ b/tex/context/base/mkxl/page-sel.mklx
@@ -55,7 +55,7 @@
\installsetuponlycommandhandler \??withpages {withpages}
% \installdirectcommandhandler \??withpages {withpages}
-\newcount\c_page_selectors_n
+\newinteger\c_page_selectors_n
\permanent\tolerant\protected\def\insertpages[#filename]#spacer[#emptylist]#spacer[#settings]%
{\doifelseassignment{#emptylist}
@@ -153,8 +153,8 @@
\centeredbox
{\doifelse{\directwithpagesparameter\c!marking}\v!on\cuthbox\hpack % only place where cuthbox is used
{\ifdim\scratchoffset>\zeropoint\relax
- \advance\vsize -2\scratchoffset
- \advance\hsize -2\scratchoffset
+ \advanceby\vsize -2\scratchoffset
+ \advanceby\hsize -2\scratchoffset
\externalfigure[#filename][\c!page=\recurselevel,#figuresettings,\c!scale=,\c!factor=\v!max,\c!offset=\v!overlay]%
\else
\externalfigure[#filename][\c!page=\recurselevel,#figuresettings,\c!offset=\v!overlay]%
@@ -243,7 +243,7 @@
\fi
\directwithpagesparameter\c!right}%
\directwithpagesparameter\c!bottom}%
- \global\advance\combinedpagescounter\plusone
+ \global\advanceby\combinedpagescounter\plusone
\hfil}%
\hfilneg}
\vfil}%
@@ -280,7 +280,7 @@
\c!backgroundcolor=\directwithpagesparameter\c!backgroundcolor,
\c!frame=\directwithpagesparameter\c!frame]%
\fi}}
- \global\advance\combinedpagescounter\plusone
+ \global\advanceby\combinedpagescounter\plusone
\directwithpagesparameter\c!bottom}}%
\hfil}%
\hfilneg}}%
@@ -298,7 +298,7 @@
{\startbaselinecorrection
\hbox to \textwidth
{\dorecurse\scratchnx
- {\global\advance\combinedpagescounter\plusone
+ {\global\advanceby\combinedpagescounter\plusone
\ifnum\combinedpagescounter>\c_page_selectors_n \else
\normalexpanded{\externalfigure
[\directwithpagesparameter\c!name]
diff --git a/tex/context/base/mkxl/page-sid.mkxl b/tex/context/base/mkxl/page-sid.mkxl
index 614945a9d..13131fa8d 100644
--- a/tex/context/base/mkxl/page-sid.mkxl
+++ b/tex/context/base/mkxl/page-sid.mkxl
@@ -32,50 +32,50 @@
%D Earth, sophisticated Massive Attack video clips, impressive Davie504 movies
%D and so on).
-\newdimen \d_page_sides_margin
-\newdimen \d_page_sides_height % includes the topskip
-\newdimen \d_page_sides_width
-\newdimen \d_page_sides_hsize
-\newdimen \d_page_sides_vsize
-\newdimen \d_page_sides_vsize_reset
-\newdimen \d_page_sides_progress
-\newdimen \d_page_sides_page_total
-\newdimen \d_page_sides_shape_down_shift
-
-\newdimen \d_page_sides_leftoffset
-\newdimen \d_page_sides_rightoffset
+\newdimension \d_page_sides_margin
+\newdimension \d_page_sides_height % includes the topskip
+\newdimension \d_page_sides_width
+\newdimension \d_page_sides_hsize
+\newdimension \d_page_sides_vsize
+\newdimension \d_page_sides_vsize_reset
+\newdimension \d_page_sides_progress
+\newdimension \d_page_sides_page_total
+\newdimension \d_page_sides_shape_down_shift
+
+\newdimension \d_page_sides_leftoffset
+\newdimension \d_page_sides_rightoffset
%newbox \b_page_sides_bottom
\newbox \b_page_sides_spill_over
-\newcount \c_page_sides_lines_done
-\newcount \c_page_sides_checks_done
-\newcount \c_page_sides_n_of_lines
-\newcount \c_page_sides_n_of_hang
+\newinteger \c_page_sides_lines_done
+\newinteger \c_page_sides_checks_done
+\newinteger \c_page_sides_n_of_lines
+\newinteger \c_page_sides_n_of_hang
\newconstant \c_page_sides_float_type
-\newcount \c_page_sides_hangafter
+\newinteger \c_page_sides_hangafter
\newconditional \c_page_sides_short
\newconditional \c_page_sides_flag
\newconditional \c_page_sides_shape_down
\newconditional \c_page_sides_keep_together
-\newdimen \d_page_sides_shift
-\newdimen \d_page_sides_extrashift
-\newdimen \d_page_sides_leftshift
-\newdimen \d_page_sides_rightshift
-\newdimen \d_page_sides_leftskip
-\newdimen \d_page_sides_rightskip
-\newdimen \d_page_sides_maximum
-\newdimen \d_page_sides_topskip
-\newdimen \d_page_sides_bottomskip
-\newdimen \d_page_sides_midskip
-\newdimen \d_page_sides_downshift
-\newdimen \d_page_sides_pagetotal
-\newdimen \d_page_sides_topoffset
-\newdimen \d_page_sides_bottomoffset
-\newdimen \d_page_sides_toptotal
-\newdimen \d_page_sides_bottomtotal
+\newdimension \d_page_sides_shift
+\newdimension \d_page_sides_extrashift
+\newdimension \d_page_sides_leftshift
+\newdimension \d_page_sides_rightshift
+\newdimension \d_page_sides_leftskip
+\newdimension \d_page_sides_rightskip
+\newdimension \d_page_sides_maximum
+\newdimension \d_page_sides_topskip
+\newdimension \d_page_sides_bottomskip
+\newdimension \d_page_sides_midskip
+\newdimension \d_page_sides_downshift
+\newdimension \d_page_sides_pagetotal
+\newdimension \d_page_sides_topoffset
+\newdimension \d_page_sides_bottomoffset
+\newdimension \d_page_sides_toptotal
+\newdimension \d_page_sides_bottomtotal
\newconstant \c_page_sides_align
\newconstant \c_page_sides_skipmode
@@ -83,9 +83,9 @@
\newconstant \c_page_sides_method % sort of obsolete
-\newdimen \d_page_sides_progression
+\newdimension \d_page_sides_progression
-\newcount \c_page_sides_m_of_lines
+\newinteger \c_page_sides_m_of_lines
\newconditional \c_page_sides_delayed
%newconditional \c_page_sides_check_same_page
@@ -174,10 +174,10 @@
\fi
\ifzeropt\d_page_sides_shift
\ifnum\c_page_sides_float_type=\plusfour
- \global\advance\d_page_sides_shift\d_page_sides_extrashift
+ \global\advanceby\d_page_sides_shift\d_page_sides_extrashift
\global\d_page_sides_extrashift\zeropoint
\orelse\ifnum\c_page_sides_float_type=\plusfive
- \global\advance\d_page_sides_shift\d_page_sides_extrashift
+ \global\advanceby\d_page_sides_shift\d_page_sides_extrashift
\global\d_page_sides_extrashift\zeropoint
\fi
\else
@@ -232,10 +232,10 @@
\global\d_page_sides_leftoffset \d_page_sides_rightskip
\global\d_page_sides_rightoffset\d_page_sides_leftskip
\ifdim\d_page_sides_rightskip>\zeropoint
- \global\advance\d_page_sides_rightskip\rightskip
+ \global\advanceby\d_page_sides_rightskip\rightskip
\fi
\ifdim\d_page_sides_leftskip >\zeropoint
- \global\advance\d_page_sides_leftskip \leftskip
+ \global\advanceby\d_page_sides_leftskip \leftskip
\fi}
%D Shifts get applied to the float box:
@@ -331,7 +331,7 @@
\getnoflines{\ht\floatbox}%
\privatescratchdimen\dimexpr\noflines\lineheight-\strutdp\relax
\getrawnoflines\d_page_sides_toptotal
- \advance\privatescratchdimen\noflines\lineheight
+ \advanceby\privatescratchdimen\noflines\lineheight
\page_sides_force_depth
\ht\floatbox\privatescratchdimen
\dp\floatbox\zeropoint
@@ -351,17 +351,17 @@
% the top of the box is at the previous baseline
\ifcase\c_page_sides_align
% 0 normal
- \advance\privatescratchdimen\strutdp % or \openstrutdepth
+ \advanceby\privatescratchdimen\strutdp % or \openstrutdepth
\or % 1 height
- \advance\privatescratchdimen\strutdp % or \openstrutdepth
+ \advanceby\privatescratchdimen\strutdp % or \openstrutdepth
\or % 2 line
\or % 3 depth
- \advance\privatescratchdimen\lineheight % or \openlineheight
- \advance\privatescratchdimen\strutdp % or \openstrutdepth
+ \advanceby\privatescratchdimen\lineheight % or \openlineheight
+ \advanceby\privatescratchdimen\strutdp % or \openstrutdepth
\or % 4 grid
\privatescratchdimen\zeropoint
\or
- \advance\privatescratchdimen\strutht % or \openstrutheight
+ \advanceby\privatescratchdimen\strutht % or \openstrutheight
\fi
% new
\global\c_page_sides_lines_done\zerocount
@@ -371,11 +371,11 @@
+\htdp\floatbox
% -\lineheight
\relax
- \advance\privatescratchdimen\c_page_sides_n_of_lines\lineheight
-\advance\privatescratchdimen2\lineheight
+ \advanceby\privatescratchdimen\c_page_sides_n_of_lines\lineheight
+\advanceby\privatescratchdimen2\lineheight
\else
\global\d_page_sides_shape_down_shift\zeropoint
- \advance\privatescratchdimen\c_page_sides_n_of_lines\lineheight
+ \advanceby\privatescratchdimen\c_page_sides_n_of_lines\lineheight
\fi
\iftracesidefloats
\page_sides_apply_vertical_shift_traced % uses \privatescratchdimen
@@ -776,10 +776,10 @@
% \def\page_sides_analyse_progress
% {\d_page_sides_progress\d_page_sides_vsize
% \ifconditional\c_page_sides_flag
-% \advance\d_page_sides_progress-\d_page_sides_page_total
+% \advanceby\d_page_sides_progress-\d_page_sides_page_total
% \global\setfalse\c_page_sides_flag
% \else
-% \advance\d_page_sides_progress-\pagetotal
+% \advanceby\d_page_sides_progress-\pagetotal
% \fi}
% test case
@@ -800,7 +800,7 @@
{%\page_otr_command_set_vsize % this is new, otherwise topfloats are not taken into account
\d_page_sides_progress\d_page_sides_vsize
\ifconditional\c_page_sides_flag
- \advance\d_page_sides_progress-\d_page_sides_page_total
+ \advanceby\d_page_sides_progress-\d_page_sides_page_total
\global\setfalse\c_page_sides_flag
\else
\ifdim\dimexpr\d_page_sides_progress+\d_page_sides_bottomtotal\relax>\pagegoal
@@ -808,7 +808,7 @@
% everypar and we hope that it triggers a flush, see test above
\pagegoal\dimexpr\pagegoal-\d_page_sides_bottomtotal\relax
\fi
- \advance\d_page_sides_progress-\pagetotal
+ \advanceby\d_page_sides_progress-\pagetotal
\fi}
\def\page_sides_analyse_space_stage_one
@@ -837,19 +837,19 @@
% method 0 : raw
\or
% method 1 : safe (default)
- \advance\scratchdimentwo -\strutdp
+ \advanceby\scratchdimentwo -\strutdp
\or
% method 2 : tight (grid default)
- \advance\scratchdimenone -\onepoint
+ \advanceby\scratchdimenone -\onepoint
\fi
\or
% tolerant
- \advance\scratchdimentwo -.5\strutdp
+ \advanceby\scratchdimentwo -.5\strutdp
\or
% verytolerant
- % \advance\scratchdimenone -\onepoint (maybe)
+ % \advanceby\scratchdimenone -\onepoint (maybe)
\else
- \advance\scratchdimentwo -\strutdp
+ \advanceby\scratchdimentwo -\strutdp
\fi}
\def\page_sides_analyse_space_stage_two
@@ -858,11 +858,11 @@
\global\setfalse\c_page_floats_room
\else
\ifdim\dimexpr\pagegoal-\d_page_sides_vsize\relax<\d_page_sides_bottomtotal
- % just weird: \global\advance\d_page_sides_vsize \scratchdimenone
+ % just weird: \global\advanceby\d_page_sides_vsize \scratchdimenone
\global\settrue\c_page_sides_short
% why was this \global\holdinginserts\plusone
\else
- \global\advance\d_page_sides_vsize \d_page_sides_bottomtotal % wins over inbetween
+ \global\advanceby\d_page_sides_vsize \d_page_sides_bottomtotal % wins over inbetween
\global\setfalse\c_page_sides_short
\fi
\global\settrue\c_page_floats_room
@@ -1074,7 +1074,7 @@
\ifx\p_sidethreshold\v!old
\d_page_sides_progression\dimexpr\d_page_sides_progress+\strutht-\roundingeps\relax
\c_page_sides_n_of_hang\d_page_sides_progression
- \divide\c_page_sides_n_of_hang \baselineskip\relax
+ \divideby\c_page_sides_n_of_hang \baselineskip\relax
\else
\d_page_sides_progression
\ifempty\p_sidethreshold
@@ -1098,8 +1098,8 @@
\global\c_page_sides_lines_done\c_page_sides_n_of_hang
\else
\privatescratchcounter\c_page_sides_lines_done
- \advance\privatescratchcounter-\c_page_sides_n_of_hang
- \global\advance\c_page_sides_n_of_lines-\privatescratchcounter
+ \advanceby\privatescratchcounter-\c_page_sides_n_of_hang
+ \global\advanceby\c_page_sides_n_of_lines-\privatescratchcounter
\fi
\fi
\ifnum\c_page_sides_n_of_lines>\zerocount
@@ -1109,8 +1109,8 @@
\dorecurse\c_page_sides_n_of_lines
{\toksapp\privatescratchtoks{\zeropoint\hsize}}%
\ifnum\c_page_sides_n_of_hang>\c_page_sides_n_of_lines
- \advance\c_page_sides_n_of_hang -\c_page_sides_n_of_lines\relax
- \advance\privatescratchcounter\c_page_sides_n_of_hang
+ \advanceby\c_page_sides_n_of_hang -\c_page_sides_n_of_lines\relax
+ \advanceby\privatescratchcounter\c_page_sides_n_of_hang
\dorecurse\c_page_sides_n_of_hang % weird, shouldn't that be scratchcounter
{\ifnum\c_page_sides_float_type>\plusfour
\toksapp\privatescratchtoks{\zeropoint\privatescratchdimen}%
@@ -1129,7 +1129,7 @@
\global\c_page_sides_hangafter\hangafter
\fi
\fi
- \global\advance\c_page_sides_checks_done \plusone
+ \global\advanceby\c_page_sides_checks_done \plusone
\iftracesidefloats
\page_sides_check_floats_tracer
\fi}
diff --git a/tex/context/base/mkxl/page-txt.mklx b/tex/context/base/mkxl/page-txt.mklx
index f8daa0c47..7b044284f 100644
--- a/tex/context/base/mkxl/page-txt.mklx
+++ b/tex/context/base/mkxl/page-txt.mklx
@@ -270,7 +270,7 @@
%D Texts can be disabled, moved up and ignored, depending in the \type {status}
%D variable. This is handled by the next couple of macros.
-\newcount\c_page_layouts_element_state_n
+\newinteger\c_page_layouts_element_state_n
\mutable\lettonothing\textlinestatus
diff --git a/tex/context/base/mkxl/publ-ini.mkxl b/tex/context/base/mkxl/publ-ini.mkxl
index 25b436f7b..15da8ada5 100644
--- a/tex/context/base/mkxl/publ-ini.mkxl
+++ b/tex/context/base/mkxl/publ-ini.mkxl
@@ -587,10 +587,10 @@
%D Lists:
-\newdimen\d_publ_number_width
+\newdimension\d_publ_number_width
-\ifdefined\btxblock \else \newcount\btxblock \fi \btxblock\plusone
-\ifdefined\btxcitecounter \else \newcount\btxcitecounter \fi % maybe pass this to lua
+\ifdefined\btxblock \else \newinteger\btxblock \fi \btxblock\plusone
+\ifdefined\btxcitecounter \else \newinteger\btxcitecounter \fi % maybe pass this to lua
\newtoks\everysetupbtxlistplacement % name will change
\newtoks\everysetupbtxciteplacement % name will change
@@ -924,7 +924,7 @@
\ifconditional#1\relax
\stopnamedsection
\fi
- \global\advance\btxblock\plusone
+ \global\advanceby\btxblock\plusone
\endgroup}
\permanent\protected\def\placebtxrendering {\publ_place_list_indeed\conditionalfalse\conditionalfalse}
@@ -967,7 +967,7 @@
\permanent\protected\def\btxsetlisttag#1%
{\clf_btxflushlisttag{\currentbtxdataset}#1\relax}
-\newcount\c_btx_list_index
+\newinteger\c_btx_list_index
\lettonothing\m_btx_list_action
@@ -975,7 +975,7 @@
{\btxsetlisttag{\c_btx_list_index}
\expandafter\m_btx_list_action\expandafter{\currentbtxtag}%
\ifnum\c_btx_list_index<\nofbtxlistentries
- \advance\c_btx_list_index\plusone
+ \advanceby\c_btx_list_index\plusone
\expandafter\publ_flush_list_step_command
\else
\glet\m_btx_list_action\relax
@@ -985,7 +985,7 @@
{\btxsetlisttag{\c_btx_list_index}
\directsetup{\m_btx_list_action}%
\ifnum\c_btx_list_index<\nofbtxlistentries
- \advance\c_btx_list_index\plusone
+ \advanceby\c_btx_list_index\plusone
\expandafter\publ_flush_list_step_setup
\else
\glet\m_btx_list_action\relax
@@ -1048,11 +1048,11 @@
\permanent\protected\def\btxstartlistentry % maybe pass i
{\begingroup
- \global\advance\c_btx_list_reference\plusone}
+ \global\advanceby\c_btx_list_reference\plusone}
\permanent\protected\def\btxstoplistentry
{\iftrialtypesetting
- \global\advance\c_btx_list_reference\minusone
+ \global\advanceby\c_btx_list_reference\minusone
\fi
\endgroup}
@@ -1110,7 +1110,7 @@
\btx_reference_indeed
\egroup}
-\newcount\c_btx_list_reference
+\newinteger\c_btx_list_reference
\protected\def\btx_list_reference_inject
{\dontleavehmode\begingroup % no box
diff --git a/tex/context/base/mkxl/scrn-bar.mklx b/tex/context/base/mkxl/scrn-bar.mklx
index 8d2f30d03..155a3b716 100644
--- a/tex/context/base/mkxl/scrn-bar.mklx
+++ b/tex/context/base/mkxl/scrn-bar.mklx
@@ -76,10 +76,10 @@
\endgroup
\fi}
-\newdimen\d_scrn_bar_width
-\newdimen\d_scrn_bar_height
-\newdimen\d_scrn_bar_depth
-\newdimen\d_scrn_bar_distance
+\newdimension\d_scrn_bar_width
+\newdimension\d_scrn_bar_height
+\newdimension\d_scrn_bar_depth
+\newdimension\d_scrn_bar_distance
%D Interaction buttons, in fact a row of tiny buttons, are typically only used for
%D navigational purposed. The next macro builds such a row based on a specification
@@ -129,17 +129,17 @@
\scratchcounterone\zerocount % new, was 1
\processallactionsinset
[#list]
- [ \v!page=>\advance\scratchcounterone\plusfour,
- \v!subpage=>\advance\scratchcounterone\plusfour,
- \s!unknown=>\advance\scratchcounterone\plusone]%
+ [ \v!page=>\advanceby\scratchcounterone\plusfour,
+ \v!subpage=>\advanceby\scratchcounterone\plusfour,
+ \s!unknown=>\advanceby\scratchcounterone\plusone]%
\ifzeropt\d_scrn_bar_width
\scratchdimenone\dimexpr2\emwidth+\d_scrn_bar_distance\relax
\scratchdimentwo\dimexpr\scratchcounterone\scratchdimenone-\d_scrn_bar_distance\relax
\else
\scratchdimenone\d_scrn_bar_width
\scratchdimentwo\dimexpr\scratchcounterone\d_scrn_bar_distance-\d_scrn_bar_distance\relax
- \advance\scratchdimenone -\scratchdimentwo
- \divide\scratchdimenone \scratchcounterone
+ \advanceby\scratchdimenone -\scratchdimentwo
+ \divideby\scratchdimenone \scratchcounterone
\scratchdimentwo\d_scrn_bar_width
\fi
\hbox to \scratchdimentwo
@@ -306,23 +306,23 @@
\doloop
{\scratchcounterthree\numexpr(\nofsubpages/\recurselevel)+\plusone\relax % rounding
\scratchdimentwo\d_scrn_bar_distance
- \multiply\scratchdimentwo \scratchcounterthree
- \advance\scratchdimentwo -\d_scrn_bar_distance
+ \multiplyby\scratchdimentwo \scratchcounterthree
+ \advanceby\scratchdimentwo -\d_scrn_bar_distance
\scratchdimenone\d_scrn_bar_width
- \advance\scratchdimenone -\scratchdimentwo
- \divide\scratchdimenone \scratchcounterthree
+ \advanceby\scratchdimenone -\scratchdimentwo
+ \divideby\scratchdimenone \scratchcounterthree
\ifdim\scratchdimenone<\d_scrn_bar_distance\else
\scratchcountertwo\recurselevel
\exitloop
\fi}%
\ifnum\scratchcounterthree>\plusone
% this is not that well tested
- \advance\scratchcounterthree \minustwo
+ \advanceby\scratchcounterthree \minustwo
\scratchdimenone-\d_scrn_bar_distance
\scratchdimenone\scratchcounterthree\scratchdimenone
- \advance\scratchdimenone \d_scrn_bar_width
- \advance\scratchcounterthree \plusone
- \divide\scratchdimenone \scratchcounterthree
+ \advanceby\scratchdimenone \d_scrn_bar_width
+ \advanceby\scratchcounterthree \plusone
+ \divideby\scratchdimenone \scratchcounterthree
\fi
\doifelse{\interactionbarparameter\c!symbol}\v!yes
{\setupsymbolset[\interactionparameter\c!symbolset]%
@@ -334,7 +334,7 @@
\scratchcounterfive\zerocount
\dostepwiserecurse\firstsubpage\lastsubpage\plusone
{\donefalse
- \advance\scratchcounterfive \plusone
+ \advanceby\scratchcounterfive \plusone
\ifnum\recurselevel=\firstsubpage\relax \donetrue \fi
\ifnum\recurselevel=\lastsubpage \relax \donetrue \fi
\scratchcountersix\therealsubpageno\recurselevel\relax
diff --git a/tex/context/base/mkxl/scrn-but.mklx b/tex/context/base/mkxl/scrn-but.mklx
index a3715c813..db3e3af1e 100644
--- a/tex/context/base/mkxl/scrn-but.mklx
+++ b/tex/context/base/mkxl/scrn-but.mklx
@@ -418,19 +418,19 @@
%D After all, menus need some setup anyway. The offsets are added to the width or
%D height (this is different from \MKII).
-\newbox \b_scrn_menu
-
-\newdimen\d_scrn_menu_next_distance
-\newdimen\d_scrn_menu_final_width
-\newdimen\d_scrn_menu_final_height
-\newdimen\d_scrn_menu_used_width
-\newdimen\d_scrn_menu_used_height
-\newdimen\d_scrn_menu_asked_width
-\newdimen\d_scrn_menu_asked_height
-\newdimen\d_scrn_menu_offset_top
-\newdimen\d_scrn_menu_offset_bottom
-\newdimen\d_scrn_menu_offset_left
-\newdimen\d_scrn_menu_offset_right
+\newbox \b_scrn_menu
+
+\newdimension\d_scrn_menu_next_distance
+\newdimension\d_scrn_menu_final_width
+\newdimension\d_scrn_menu_final_height
+\newdimension\d_scrn_menu_used_width
+\newdimension\d_scrn_menu_used_height
+\newdimension\d_scrn_menu_asked_width
+\newdimension\d_scrn_menu_asked_height
+\newdimension\d_scrn_menu_offset_top
+\newdimension\d_scrn_menu_offset_bottom
+\newdimension\d_scrn_menu_offset_left
+\newdimension\d_scrn_menu_offset_right
\newconditional\c_scrn_menu_zerodimensions
@@ -608,7 +608,7 @@
%D positional info. The status variable is 0, 1 or~2: not found, found and found but
%D current page.
-\newcount \c_scrn_menu_position
+\newinteger \c_scrn_menu_position
\newconstant \c_scrn_menu_page_mode % 0=notfound 1=found 2=currentpage
\newconditional\c_scrn_menu_positioning
\newtoks \t_scrn_menu_meta_data
@@ -711,7 +711,7 @@
\scrn_menu_action_stop}
\def\scrn_button_make_position#currentparameter#inheritedframed#letparameter#setparameter#text#action%
- {\global\advance\c_scrn_menu_position\plusone
+ {\global\advanceby\c_scrn_menu_position\plusone
\doifelsereferencefound{#action}% 0=not found, 1=same page, >1=elsewhere
{\c_scrn_menu_page_mode\ifnum\currentreferencerealpage=\realpageno\plusone\else\plustwo\fi}%
{\c_scrn_menu_page_mode\plustwo}%
diff --git a/tex/context/base/mkxl/scrn-fld.mklx b/tex/context/base/mkxl/scrn-fld.mklx
index de448bf50..d5dadcb78 100644
--- a/tex/context/base/mkxl/scrn-fld.mklx
+++ b/tex/context/base/mkxl/scrn-fld.mklx
@@ -620,12 +620,12 @@
%D Common stuff (obsolete)
-\newcount\c_scrn_field_system_n
+\newinteger\c_scrn_field_system_n
\permanent\def\currentsystemfield{sys::\number\c_scrn_field_system_n}
\permanent\protected\def\nextsystemfield
- {\global\advance\c_scrn_field_system_n\plusone}
+ {\global\advanceby\c_scrn_field_system_n\plusone}
%D \CONTEXT\ had tooltips right from the moment that it supported fields. Due to the
%D at that moment somewhat limited \PDF\ specification, they were implemented using
@@ -640,9 +640,9 @@
%D before \tooltip[left]{inbetween}{a very nice tip} after\par
%D \stoptyping
-\newbox \b_scrn_tooltip_anchor
-\newbox \b_scrn_tooltip_text
-\newcount\c_scrn_tooltip_n
+\newbox \b_scrn_tooltip_anchor
+\newbox \b_scrn_tooltip_text
+\newinteger\c_scrn_tooltip_n
\installcorenamespace{tooltip}
@@ -675,7 +675,7 @@
\tolerant\def\scrn_tooltip_indeed[#settings]#:#anchortext#tiptext% a more modern aproach (push buttons)
{\dontleavehmode \hbox \bgroup
\dontcomplain
- \global\advance\c_scrn_tooltip_n\plusone
+ \global\advanceby\c_scrn_tooltip_n\plusone
\edef\currenttooltipname{tooltip:\number\c_scrn_tooltip_n}%
\setbox\b_scrn_tooltip_anchor\hbox
{\strut#anchortext}%
@@ -763,7 +763,7 @@
\definesymbol[\s!empty][]
\def\scrn_fieldstack_add#tag#settings#symbol%
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\edef\currentfieldstackname{#tag:\number\scratchcounter}%
\ifnum\scratchcounter=\fieldcategoryparameter\c!start\relax
\definefieldbody[\currentfieldstackname][\c!type=check,\c!values={#symbol,\s!empty},\c!default={#symbol}]%
@@ -811,13 +811,13 @@
%D \framed[background=WithTest]{toggle}
%D \stoptyping
-\newcount\c_scrn_rollbutton_n
+\newinteger\c_scrn_rollbutton_n
\permanent\tolerant\protected\def\overlayrollbutton[#1]#*[#2]#;#=#=%
{\iflocation
\bgroup
- \global\advance\c_scrn_rollbutton_n_button\plusone
- \global\advance\c_scrn_rollbutton_n_symbol\plusone
+ \global\advanceby\c_scrn_rollbutton_n_button\plusone
+ \global\advanceby\c_scrn_rollbutton_n_symbol\plusone
\definesymbol
[rollsymbol:\number\c_scrn_rollbutton_n_symbol]
[{\framed[\c!frame=\v!off,\c!width=\overlaywidth,\c!height=\overlayheight]{}}]%
@@ -866,7 +866,7 @@
% \stopTEXpage
% \stoptext
-\newcount\c_scrn_pushbutton_n
+\newinteger\c_scrn_pushbutton_n
\permanent\tolerant\protected\def\definepushbutton[#tag]#spacer[#settings]%
{\scrn_pushbutton_define_variant{#tag}{n}{push}%
@@ -881,7 +881,7 @@
\def\scrn_pushbutton_handle#tag#settings#reference%
{\bgroup
- \global\advance\c_scrn_pushbutton_n\plusone
+ \global\advanceby\c_scrn_pushbutton_n\plusone
\setupfield
[pushbutton]%
[\c!frame=\v!overlay,%
@@ -949,8 +949,8 @@
r=green,
d=blue]
-\newcount\c_scrn_rollbutton_n_button
-\newcount\c_scrn_rollbutton_n_symbol
+\newinteger\c_scrn_rollbutton_n_button
+\newinteger\c_scrn_rollbutton_n_symbol
\permanent\def\lastrollbuttonindex{\the\c_scrn_rollbutton_n_button}
@@ -978,8 +978,8 @@
\permanent\tolerant\protected\def\rollbutton[#tag]#spacer[#settings]#:#text[#reference]%
{\dontleavehmode
\bgroup
- \global\advance\c_scrn_rollbutton_n_button\plusone
- \global\advance\c_scrn_rollbutton_n_symbol\plusone
+ \global\advanceby\c_scrn_rollbutton_n_button\plusone
+ \global\advanceby\c_scrn_rollbutton_n_symbol\plusone
\ifparameter#tag\or
\ifparameter#settings\or
\edef\currentinteractionmenu{#tag}%
diff --git a/tex/context/base/mkxl/scrn-hlp.mklx b/tex/context/base/mkxl/scrn-hlp.mklx
index f8476cb8f..9f0c5dbdd 100644
--- a/tex/context/base/mkxl/scrn-hlp.mklx
+++ b/tex/context/base/mkxl/scrn-hlp.mklx
@@ -53,8 +53,8 @@
% also status
-\newbox \b_scrn_help_box
-\newcount\c_scrn_help_n
+\newbox \b_scrn_help_box
+\newinteger\c_scrn_help_n
\definesystemattribute[help][public]
@@ -79,7 +79,7 @@
\protected\def\scrn_help_argument#category%
{\def\currenthelp{#category}%
- \global\advance\c_scrn_help_n\plusone
+ \global\advanceby\c_scrn_help_n\plusone
\edef\currenthelpname{help:\number\c_scrn_help_n}%
\doifelselocation\scrn_help_argument_indeed\scrn_help_argument_ignore}
@@ -98,7 +98,7 @@
{#target}
\tolerant\protected\def\scrn_help_start#category#spacer[#reference]%
- {\global\advance\c_scrn_help_n\plusone
+ {\global\advanceby\c_scrn_help_n\plusone
\edef\currenthelp{#category}%
\edef\currenthelpreference{#reference}%
\edef\currenthelpname{help:\number\c_scrn_help_n}%
diff --git a/tex/context/base/mkxl/scrn-pag.mklx b/tex/context/base/mkxl/scrn-pag.mklx
index be1b6ad8f..312051d0c 100644
--- a/tex/context/base/mkxl/scrn-pag.mklx
+++ b/tex/context/base/mkxl/scrn-pag.mklx
@@ -24,16 +24,16 @@
\installparameterhandler \??interactionscreen {interactionscreen}
\installsetuphandler \??interactionscreen {interactionscreen}
-\newdimen\canvaswidth
-\newdimen\canvasheight
-\newdimen\canvasbackoffset
-\newdimen\canvastopoffset
-\newdimen\canvasmaxwidth
-\newdimen\canvasmaxheight
-\newdimen\canvascropoffset
-\newdimen\canvastrimoffset
-\newdimen\canvasbleedoffset
-\newdimen\canvasartoffset
+\newdimension\canvaswidth
+\newdimension\canvasheight
+\newdimension\canvasbackoffset
+\newdimension\canvastopoffset
+\newdimension\canvasmaxwidth
+\newdimension\canvasmaxheight
+\newdimension\canvascropoffset
+\newdimension\canvastrimoffset
+\newdimension\canvasbleedoffset
+\newdimension\canvasartoffset
\mutable\lettonothing\currentinteractionscreendelay
\mutable\lettonothing\currentinteractionscreenheight
@@ -65,10 +65,10 @@
\donefalse
\ifdim\backspace>\canvaswidth
\ifdim\backspace>\zeropoint\relax
- \global\advance\canvasbackoffset -\canvaswidth
+ \global\advanceby\canvasbackoffset -\canvaswidth
\fi
\fi
- \global\advance\canvaswidth\dimexpr
+ \global\advanceby\canvaswidth\dimexpr
\makeupwidth
+ \rightcombitotal
+ 2\dimexpr
@@ -100,10 +100,10 @@
\global\canvasheight\dimexpr\topheight+\topdistance\relax
\ifdim\topspace>\canvasheight
\ifdim\topspace>\zeropoint\relax
- \global\advance\canvastopoffset -\canvasheight
+ \global\advanceby\canvastopoffset -\canvasheight
\fi
\fi
- \global\advance\canvasheight\dimexpr
+ \global\advanceby\canvasheight\dimexpr
\makeupheight
+ \bottomdistance
+ \bottomheight
@@ -140,10 +140,10 @@
\fi
\endgroup}
-\newdimen\layoutcropoffset
-\newdimen\layouttrimoffset
-\newdimen\layoutbleedoffset
-\newdimen\layoutartoffset
+\newdimension\layoutcropoffset
+\newdimension\layouttrimoffset
+\newdimension\layoutbleedoffset
+\newdimension\layoutartoffset
\appendtoks
\edef\p_cropoffset{\layoutparameter\c!cropoffset}%
diff --git a/tex/context/base/mkxl/scrn-wid.mklx b/tex/context/base/mkxl/scrn-wid.mklx
index 2361bbf3e..d377d47ec 100644
--- a/tex/context/base/mkxl/scrn-wid.mklx
+++ b/tex/context/base/mkxl/scrn-wid.mklx
@@ -601,8 +601,8 @@
\permanent\def\renderingoption#tag{\clf_renderingvar{#tag}{option}}
-\newdimen\d_scrn_rendering_width \d_scrn_rendering_width 8cm
-\newdimen\d_scrn_rendering_height \d_scrn_rendering_height 6cm
+\newdimension\d_scrn_rendering_width \d_scrn_rendering_width 8cm
+\newdimension\d_scrn_rendering_height \d_scrn_rendering_height 6cm
\let\m_scrn_rendering_page\!!zerocount
diff --git a/tex/context/base/mkxl/spac-ali.mkxl b/tex/context/base/mkxl/spac-ali.mkxl
index a74136c21..141adff0a 100644
--- a/tex/context/base/mkxl/spac-ali.mkxl
+++ b/tex/context/base/mkxl/spac-ali.mkxl
@@ -297,8 +297,8 @@
\let\v_spac_align_space_amount \interwordspace
\def\v_spac_align_space_amount_x {.5\emwidth}
-\newskip\s_zero_plus_one_fil \s_zero_plus_one_fil = 0pt plus 1fil
-\newskip\s_zero_plus_zero \s_zero_plus_zero = 0pt plus 0pt
+\newgluespec\s_zero_plus_one_fil \s_zero_plus_one_fil = 0pt plus 1fil
+\newgluespec\s_zero_plus_zero \s_zero_plus_zero = 0pt plus 0pt
% \s!plus ... slower than inline
diff --git a/tex/context/base/mkxl/spac-grd.mkxl b/tex/context/base/mkxl/spac-grd.mkxl
index 65739cabe..33bf0c706 100644
--- a/tex/context/base/mkxl/spac-grd.mkxl
+++ b/tex/context/base/mkxl/spac-grd.mkxl
@@ -101,11 +101,11 @@
% \definecolor[GridLineColor][red]
% \definecolor[GridTextColor][blue]
-\newdimen\d_spac_lines_correction_before
-\newdimen\d_spac_lines_correction_after
+\newdimension\d_spac_lines_correction_before
+\newdimension\d_spac_lines_correction_after
-\newbox \b_spac_lines_correction_before
-\newbox \b_spac_lines_correction_after
+\newbox \b_spac_lines_correction_before
+\newbox \b_spac_lines_correction_after
\def\spac_lines_initialize_corrections
{\setbox\b_spac_lines_correction_before\hpack{\setstrut\strut}%
@@ -176,7 +176,7 @@
{\ifdim\pagegoal<\maxdimen
\ifdim\pagetotal>\lineheight % or \topskip
\scratchdimen\pagetotal
- \advance\scratchdimen\lineheight
+ \advanceby\scratchdimen\lineheight
\ifdim\scratchdimen<\pagegoal
\baselinecorrection
\fi
diff --git a/tex/context/base/mkxl/spac-hor.mkxl b/tex/context/base/mkxl/spac-hor.mkxl
index ea43b2635..75ac2e454 100644
--- a/tex/context/base/mkxl/spac-hor.mkxl
+++ b/tex/context/base/mkxl/spac-hor.mkxl
@@ -31,8 +31,8 @@
\lettonothing\v_spac_indentation_current % amount/keyword
-\newdimen \d_spac_indentation_par
-\parindent\d_spac_indentation_par % for the show
+\newdimension\d_spac_indentation_par
+\parindent \d_spac_indentation_par % for the show
\newconditional\c_spac_indentation_indent_first \settrue\c_spac_indentation_indent_first
\newconstant \c_spac_indentation_toggle_state
@@ -643,13 +643,13 @@
% Bovendien definieren we enkele extra \fill's:
-\newskip\s_spac_fil \s_spac_fil = \zeropoint \s!plus 1\s!fil \relax
-\newskip\s_spac_fill \s_spac_fill = \zeropoint \s!plus 1\s!fill \relax
-\newskip\s_spac_filll \s_spac_filll = \zeropoint \s!plus 1\s!filll\relax
+\newgluespec\s_spac_fil \s_spac_fil \zeropoint \s!plus 1\s!fil \relax
+\newgluespec\s_spac_fill \s_spac_fill \zeropoint \s!plus 1\s!fill \relax
+\newgluespec\s_spac_filll \s_spac_filll \zeropoint \s!plus 1\s!filll\relax
-\newskip\s_spac_neg_fil \s_spac_neg_fil = \zeropoint \s!plus-1\s!fil \relax
-\newskip\s_spac_neg_fill \s_spac_neg_fill = \zeropoint \s!plus-1\s!fill \relax
-\newskip\s_spac_neg_filll \s_spac_neg_filll = \zeropoint \s!plus-1\s!filll\relax
+\newgluespec\s_spac_neg_fil \s_spac_neg_fil \zeropoint \s!plus-1\s!fil \relax
+\newgluespec\s_spac_neg_fill \s_spac_neg_fill \zeropoint \s!plus-1\s!fill \relax
+\newgluespec\s_spac_neg_filll \s_spac_neg_filll \zeropoint \s!plus-1\s!filll\relax
\permanent\protected\def\hfilll {\hskip\s_spac_filll\relax}
\permanent\protected\def\vfilll {\vskip\s_spac_filll\relax}
@@ -667,9 +667,9 @@
\installcorenamespace{narrower}
\installcorenamespace{narrowermethod}
-\newskip\s_spac_narrower_left
-\newskip\s_spac_narrower_right
-\newskip\s_spac_narrower_middle
+\newgluespec\s_spac_narrower_left
+\newgluespec\s_spac_narrower_right
+\newgluespec\s_spac_narrower_middle
\installcommandhandler \??narrower {narrower} \??narrower
@@ -693,18 +693,18 @@
{\ifcsname\??narrowermethod#1\endcsname
\lastnamedcs
\else
- \global\advance\s_spac_narrower_middle#1\relax
+ \global\advanceby\s_spac_narrower_middle#1\relax
\fi}
\def\spac_narrower_initialize[#1]% hm, can be dorepeat directly
{\dorepeatwithcommand[#1]\spac_narrower_method_analyze}
-\installnarrowermethod \v!left {\global\advance\s_spac_narrower_left \narrowerparameter\c!left \relax}
-\installnarrowermethod \v!middle {\global\advance\s_spac_narrower_middle \narrowerparameter\c!middle\relax}
-\installnarrowermethod \v!right {\global\advance\s_spac_narrower_right \narrowerparameter\c!right \relax}
-\installnarrowermethod{-\v!left }{\global\advance\s_spac_narrower_left -\narrowerparameter\c!left \relax}
-\installnarrowermethod{-\v!middle}{\global\advance\s_spac_narrower_middle-\narrowerparameter\c!middle\relax}
-\installnarrowermethod{-\v!right }{\global\advance\s_spac_narrower_right -\narrowerparameter\c!right \relax}
+\installnarrowermethod \v!left {\global\advanceby\s_spac_narrower_left \narrowerparameter\c!left \relax}
+\installnarrowermethod \v!middle {\global\advanceby\s_spac_narrower_middle \narrowerparameter\c!middle\relax}
+\installnarrowermethod \v!right {\global\advanceby\s_spac_narrower_right \narrowerparameter\c!right \relax}
+\installnarrowermethod{-\v!left }{\global\advanceby\s_spac_narrower_left -\narrowerparameter\c!left \relax}
+\installnarrowermethod{-\v!middle}{\global\advanceby\s_spac_narrower_middle-\narrowerparameter\c!middle\relax}
+\installnarrowermethod{-\v!right }{\global\advanceby\s_spac_narrower_right -\narrowerparameter\c!right \relax}
\installnarrowermethod \v!reset {\global \s_spac_narrower_left \zeropoint
\global \s_spac_narrower_middle \zeropoint
\global \s_spac_narrower_right \zeropoint\relax}
@@ -720,8 +720,8 @@
\spac_narrower_start_apply{\narrowerparameter\v!default}%
\fi}
-\newskip \s_spac_narrower_left_last
-\newskip \s_spac_narrower_right_last
+\newgluespec \s_spac_narrower_left_last
+\newgluespec \s_spac_narrower_right_last
\newconditional\s_spac_narrower_last_swap
\def\spac_narrower_start_apply#1%
@@ -742,8 +742,8 @@
\fi
\else
\normalexpanded{\processcommalistwithparameters[\scratchstringone]}\spac_narrower_initialize
- \frozen\advance\leftskip \dimexpr\s_spac_narrower_left +\s_spac_narrower_middle\relax
- \frozen\advance\rightskip\dimexpr\s_spac_narrower_right+\s_spac_narrower_middle\relax
+ \frozen\advanceby\leftskip \dimexpr\s_spac_narrower_left +\s_spac_narrower_middle\relax
+ \frozen\advanceby\rightskip\dimexpr\s_spac_narrower_right+\s_spac_narrower_middle\relax
\fi
\seteffectivehsize}
@@ -811,9 +811,9 @@
\aliased\let\stopnarrow\spac_narrower_stop
-\newdimen\d_spac_effective_hsize \permanent\protected\def\effectivehsize {\hsize}
-\newdimen\d_spac_effective_leftskip \permanent\protected\def\effectiveleftskip {\dimexpr\leftskip \relax}
-\newdimen\d_spac_effective_rightskip \permanent\protected\def\effectiverightskip{\dimexpr\rightskip\relax}
+\newdimension\d_spac_effective_hsize \permanent\protected\def\effectivehsize {\hsize}
+\newdimension\d_spac_effective_leftskip \permanent\protected\def\effectiveleftskip {\dimexpr\leftskip \relax}
+\newdimension\d_spac_effective_rightskip \permanent\protected\def\effectiverightskip{\dimexpr\rightskip\relax}
\permanent\protected\def\seteffectivehsize
{\setlocalhsize
@@ -827,8 +827,8 @@
\installcorenamespace{skipadaptionleft}
\installcorenamespace{skipadaptionright}
-\newskip\leftskipadaption
-\newskip\rightskipadaption
+\newgluespec\leftskipadaption
+\newgluespec\rightskipadaption
\defcsname\??skipadaptionleft \v!yes\endcsname{\ifzeropt\d_spac_indentation_par\narrowerparameter\c!left\else\d_spac_indentation_par\fi}
\letcsname\??skipadaptionleft \v!no \endcsname\zeropoint
@@ -843,8 +843,8 @@
\permanent\protected\def\dosetleftskipadaption #1{\leftskipadaption \ifcsname\??skipadaptionleft #1\endcsname\lastnamedcs\else#1\fi\relax}
\permanent\protected\def\dosetrightskipadaption#1{\rightskipadaption\ifcsname\??skipadaptionright#1\endcsname\lastnamedcs\else#1\fi\relax}
-\permanent\protected\def\doadaptleftskip #1{\normalexpanded{\dosetleftskipadaption {#1}}\frozen\advance\leftskip \leftskipadaption }
-\permanent\protected\def\doadaptrightskip#1{\normalexpanded{\dosetrightskipadaption{#1}}\frozen\advance\rightskip\rightskipadaption}
+\permanent\protected\def\doadaptleftskip #1{\normalexpanded{\dosetleftskipadaption {#1}}\frozen\advanceby\leftskip \leftskipadaption }
+\permanent\protected\def\doadaptrightskip#1{\normalexpanded{\dosetrightskipadaption{#1}}\frozen\advanceby\rightskip\rightskipadaption}
\permanent\protected\def\forgetbothskips
{\leftskip\zeropoint
@@ -1211,11 +1211,11 @@
%D \oeps}
%D \stoptyping
-% \newsignal\d_spac_ignore_spaces_signal
-% \newcount \c_spac_ignore_spaces
+% \newsignal \d_spac_ignore_spaces_signal
+% \newinteger\c_spac_ignore_spaces
%
% \permanent\protected\def\startignorespaces
-% {\advance\c_spac_ignore_spaces\plusone
+% {\advanceby\c_spac_ignore_spaces\plusone
% \ifcase\c_spac_ignore_spaces\or \ifhmode
% \hskip\d_spac_ignore_spaces_signal
% \fi \fi
@@ -1227,7 +1227,7 @@
% \doloop\spac_ignore_spaces_body
% \fi
% \fi
-% \advance\c_spac_ignore_spaces\minusone}
+% \advanceby\c_spac_ignore_spaces\minusone}
%
% \def\spac_ignore_spaces_body
% {\ifzeropt\lastskip
diff --git a/tex/context/base/mkxl/spac-lin.mkxl b/tex/context/base/mkxl/spac-lin.mkxl
index f4473d2ea..d462caeaa 100644
--- a/tex/context/base/mkxl/spac-lin.mkxl
+++ b/tex/context/base/mkxl/spac-lin.mkxl
@@ -80,15 +80,15 @@
%D \setuplines[indentlist={0pt,1em,*}]
%D \starttyping
-\newcount\c_spac_lines_indent_cnt
-\newcount\c_spac_lines_indent_max
-\newdimen\d_spac_lines_indent
+\newinteger \c_spac_lines_indent_cnt
+\newinteger \c_spac_lines_indent_max
+\newdimension\d_spac_lines_indent
\def\spac_lines_indent_indeed
{\ifnum\c_spac_lines_indent_cnt=\c_spac_lines_indent_max
\c_spac_lines_indent_cnt\plusone
\else
- \advance\c_spac_lines_indent_cnt\plusone
+ \advanceby\c_spac_lines_indent_cnt\plusone
\fi
\getfromcommacommand[\m_spac_lines_indentlist][\c_spac_lines_indent_cnt]%
\ifx\commalistelement\wildcardsymbol
diff --git a/tex/context/base/mkxl/spac-pag.mkxl b/tex/context/base/mkxl/spac-pag.mkxl
index ff85007b8..d61ddcbe6 100644
--- a/tex/context/base/mkxl/spac-pag.mkxl
+++ b/tex/context/base/mkxl/spac-pag.mkxl
@@ -16,7 +16,7 @@
\unprotect
\newif \ifpagestatemismatch
-\newcount \realpagestateno
+\newinteger \realpagestateno
\newconstant\frozenpagestate
\permanent\protected\def\dotrackpagestate#1#2%
@@ -26,7 +26,7 @@
\permanent\protected\def\doforcedtrackpagestate#1#2%
{\ifcase\frozenpagestate
- \global\advance#2\plusone
+ \global\advanceby#2\plusone
\setpagestate[#1][\number#2]%
\fi}
@@ -133,7 +133,7 @@
% \dorecurse{500}{\dontleavehmode\signalrightpage\doifrightpageelse{right}{left}\par} % given doublesided
-\newcount\nofraggedparagraphs
+\newinteger\nofraggedparagraphs
\definepagestate[\s!paragraph]
diff --git a/tex/context/base/mkxl/spac-par.mkxl b/tex/context/base/mkxl/spac-par.mkxl
index 654f195f6..f92416587 100644
--- a/tex/context/base/mkxl/spac-par.mkxl
+++ b/tex/context/base/mkxl/spac-par.mkxl
@@ -111,7 +111,7 @@
\lettonothing\spac_paragraph_wrap
-\newcount\c_spac_paragraph_group_level
+\newinteger\c_spac_paragraph_group_level
\protected\def\spac_paragraph_update
{\c_spac_paragraph_group_level\currentgrouplevel\relax
@@ -130,7 +130,7 @@
\expandafter\newtoks\csname\??eparwrap\the\currentgrouplevel\endcsname}
\def\spac_paragraph_install_count#1%
- {\expandafter\newcount\csname\??parwrapcount#1\endcsname}
+ {\expandafter\newinteger\csname\??parwrapcount#1\endcsname}
\def\spac_paragraph_install_pair#1#2#3%
{\expandafter\newtoks\csname\??parwrapbefore#3\endcsname
@@ -148,7 +148,7 @@
\ifcsname\??parwrapbefore#3\endcsname \else
\spac_paragraph_install_pair#1#2{#3}%
\fi
- #1\csname\??parwrapbefore#3\endcsname{\global\advance\csname\??parwrapcount#3\endcsname\plusone\relax % global, see (!)
+ #1\csname\??parwrapbefore#3\endcsname{\global\advanceby\csname\??parwrapcount#3\endcsname\plusone\relax % global, see (!)
\clf_setparwrapper{#3}#4}%
#2\csname\??parwrapafter #3\endcsname{#5}%
\clf_newparwrapper{#3}%
@@ -390,20 +390,20 @@
\lettonothing\flushpostponednodedata % hook into everypar
-\newbox \b_spac_postponed_data
-%newcount\c_spac_postponed_data
+\newbox \b_spac_postponed_data
+%newinteger\c_spac_postponed_data
% \installcorenamespace {postponednodesstack}
%
% \initializeboxstack\??postponednodesstack
%
% \protected\def\pushpostponednodedata
-% {\global\advance\c_spac_postponed_data\plusone
+% {\global\advanceby\c_spac_postponed_data\plusone
% \savebox\??postponednodesstack{\the\c_spac_postponed_data}{\box\b_spac_postponed_data}}
%
% \protected\def\poppostponednodedata
% {\global\setbox\b_spac_postponed_data\hbox{\foundbox\??postponednodesstack{\the\c_spac_postponed_data}}%
-% \global\advance\c_spac_postponed_data\minusone
+% \global\advanceby\c_spac_postponed_data\minusone
% \ifvoid\b_spac_postponed_data\else
% \enforced\glet\flushpostponednodedata\spac_postponed_data_flush
% \fi}
diff --git a/tex/context/base/mkxl/spac-ver.lmt b/tex/context/base/mkxl/spac-ver.lmt
index 127dd0bf9..c9faf3873 100644
--- a/tex/context/base/mkxl/spac-ver.lmt
+++ b/tex/context/base/mkxl/spac-ver.lmt
@@ -972,7 +972,8 @@ do
-- local cmd = token.create("vspacingfromtempstring")
-- local cmd = token.create("vspacingpredefinedvalue") -- not yet known
- local s_scratchskip = tex.isskip("scratchskip")
+ ----- s_predefined = "s_spac_vspacing_predefined"
+ local s_predefined = tex.isskip("s_spac_vspacing_predefined")
local function handler(multiplier, keyword, detail)
if not keyword then
@@ -1028,7 +1029,7 @@ do
-- setmacro("tempstring",keyword)
-- runlocal(ctx_vspacingfromtempstring)
--
- amount, stretch, shrink = texgetglue(s_scratchskip)
+ amount, stretch, shrink = texgetglue(s_predefined)
if not stretch then
stretch = 0
end
diff --git a/tex/context/base/mkxl/spac-ver.mkxl b/tex/context/base/mkxl/spac-ver.mkxl
index bb12b5f5d..99756a147 100644
--- a/tex/context/base/mkxl/spac-ver.mkxl
+++ b/tex/context/base/mkxl/spac-ver.mkxl
@@ -15,13 +15,19 @@
\unprotect
-\newskip \bodyfontlineheight % why a skip
-\newdimen \bodyfontstrutheight
-\newdimen \bodyfontstrutdepth
+\newgluespec\bodyfontlineheight % why a skip
+\newdimen \bodyfontstrutheight
+\newdimen \bodyfontstrutdepth
-\newskip \globalbodyfontlineheight % why a skip
-\newdimen \globalbodyfontstrutheight
-\newdimen \globalbodyfontstrutdepth
+\newgluespec\globalbodyfontlineheight % why a skip
+\newdimen \globalbodyfontstrutheight
+\newdimen \globalbodyfontstrutdepth
+
+\newgluespec\s_spac_vspacing_predefined
+
+% \overloaded\let\strutht \undefined \newdimen\strutht % already defined
+% \overloaded\let\strutdp \undefined \newdimen\strutdp
+% \overloaded\let\struthtdp\undefined \newdimen\struthtdp
\registerctxluafile{spac-ver}{autosuffix,optimize}
@@ -67,7 +73,7 @@
\newif\iflocalinterlinespace
-\newskip \s_spac_vspacing_temp \s_spac_vspacing_temp\bigskipamount
+\newgluespec\s_spac_vspacing_temp \s_spac_vspacing_temp\bigskipamount
\mutable\def\skipfactor {.75}
\mutable\def\skipgluefactor{.25}
@@ -240,10 +246,10 @@
%D Helpers
-\newskip \s_spac_lastskip
-\newdimen\d_spac_prevdepth
-\newcount\c_spac_spacefactor
-\newdimen\d_spac_prevcontent % set by lua
+\newgluespec \s_spac_lastskip
+\newdimension\d_spac_prevdepth
+\newinteger \c_spac_spacefactor
+%newdimension\d_spac_prevcontent % set by lua (no longer it seems)
% \permanent\overloaded\protected\def\removelastskip
% {\ifvmode\ifzeropt\lastskip\else\vskip-\lastskip\fi\fi}
@@ -349,7 +355,7 @@
\installcorenamespace{whitespacemethod}
-\newskip \s_spac_whitespace_parskip \s_spac_whitespace_parskip\zeropoint
+\newgluespec \s_spac_whitespace_parskip \s_spac_whitespace_parskip\zeropoint
\newconditional\c_spac_whitespace_flexible \settrue\c_spac_whitespace_flexible
\newconstant \c_spac_whitespace_grid_mode % option in layout / 1=permit_half_lines
@@ -457,10 +463,10 @@
% todo: when packed blocks blank, we need to enable forced
\newconditional\c_spac_packed_blank \settrue\c_spac_packed_blank
-\newcount \c_spac_packed_level
+\newinteger \c_spac_packed_level
\permanent\tolerant\protected\def\startpacked[#1]%
- {\global\advance\c_spac_packed_level\plusone
+ {\global\advanceby\c_spac_packed_level\plusone
\par
\ifnum\c_spac_packed_level=\plusone \ifvmode
\begingroup
@@ -475,7 +481,7 @@
\ifnum\c_spac_packed_level=\plusone \ifvmode
\endgroup
\fi \fi
- \global\advance\c_spac_packed_level\minusone}
+ \global\advanceby\c_spac_packed_level\minusone}
\permanent\protected\def\startunpacked
{\directdefaultvspacing % \blank
@@ -650,17 +656,17 @@
%D that can be prevented with \type {\dontleavehmode}. Never use \type
%D {\leavevmode}!
-\newdimen\strutdimen
-\newdimen\lineheight
-\newdimen\openlineheight
-\newdimen\openstrutheight
-\newdimen\openstrutdepth
-\newdimen\topskipgap
+\newdimension\strutdimen % not used
+\newdimension\lineheight
+\newdimension\openlineheight
+\newdimension\openstrutheight
+\newdimension\openstrutdepth
+\newdimension\topskipgap
-\newdimen\strutheight
-\newdimen\strutdepth
-\newdimen\struttotal
-\newdimen\strutwidth
+\newdimension\strutheight
+\newdimension\strutdepth
+\newdimension\struttotal
+\newdimension\strutwidth
\let\m_spac_vertical_baseline_stretch_factor \zerocount
\let\m_spac_vertical_baseline_shrink_factor \zerocount
@@ -684,7 +690,7 @@
\mutable\def\systemmaxdepthfactor{\maxdepthfactor}
\ifdefined\globalbodyfontsize \else
- \newdimen\globalbodyfontsize
+ \newdimension\globalbodyfontsize
\globalbodyfontsize=12pt
\fi
@@ -721,7 +727,7 @@
\fi
%\relax
\topskipgap\topskip
- \advance\topskipgap -\openstrutheight\relax
+ \advanceby\topskipgap -\openstrutheight\relax
\ifdim\minimumstrutheight>\zeropoint
\ifdim\topskip<\minimumstrutheight
\topskip\minimumstrutheight\relax
@@ -735,9 +741,9 @@
\permanent\protected\def\setmaxdepth
{\maxdepth\systemmaxdepthfactor\globalbodyfontsize}
-\newskip \usedbaselineskip % These used to be \normal... but that isn't pretty
-\newskip \usedlineskip % in the token interface, so these few now have new
-\newdimen\usedlineskiplimit % names. They are public but not really user commands.
+\newgluespec \usedbaselineskip % These used to be \normal... but that isn't pretty
+\newgluespec \usedlineskip % in the token interface, so these few now have new
+\newdimension\usedlineskiplimit % names. They are public but not really user commands.
\permanent\protected\def\normalbaselines
{\baselineskip \usedbaselineskip
@@ -848,9 +854,9 @@
%D The double \type {\hbox} construction enables us to backtrack boxes.
-\overloaded\let\strutht \undefined \newdimen\strutht
-\overloaded\let\strutdp \undefined \newdimen\strutdp
-\overloaded\let\struthtdp\undefined \newdimen\struthtdp
+% \overloaded\let\strutht \undefined \newdimension\strutht % see above
+% \overloaded\let\strutdp \undefined \newdimension\strutdp
+% \overloaded\let\struthtdp\undefined \newdimension\struthtdp
\permanent\protected\def\setstrut
{\ifgridsnapping
@@ -1286,7 +1292,7 @@
% just before margintexts ... will eventually be done differently in mkiv using
% attributes
-\newcount\c_spac_keep_lines_together
+\newinteger\c_spac_keep_lines_together
\permanent\protected\lettonothing\restoreinterlinepenalty
@@ -1407,13 +1413,13 @@
\installcorenamespace{gridsnapperattributes}
\installcorenamespace{gridsnappersets}
-% \newskip \bodyfontlineheight % see top
-% \newdimen \bodyfontstrutheight % see top
-% \newdimen \bodyfontstrutdepth % see top
+% \newgluespec \bodyfontlineheight % see top
+% \newdimension\bodyfontstrutheight % see top
+% \newdimension\bodyfontstrutdepth % see top
-% \newskip \globalbodyfontlineheight % see top
-% \newdimen \globalbodyfontstrutheight % see top
-% \newdimen \globalbodyfontstrutdepth % see top
+% \newgluespec \globalbodyfontlineheight % see top
+% \newdimension\globalbodyfontstrutheight % see top
+% \newdimension\globalbodyfontstrutdepth % see top
\permanent\def\snappedvboxattribute{\ifgridsnapping attr\snapvboxattribute\c_attr_snapmethod\fi}
\permanent\def\setlocalgridsnapping{\ifgridsnapping \c_attr_snapvbox \c_attr_snapmethod\fi}
@@ -1587,8 +1593,8 @@
\s!plus\skipgluefactor\baselineskip
\s!minus\skipgluefactor\baselineskip
\relax
- \medskipamount \bigskipamount \divide\medskipamount \plustwo
- \smallskipamount\bigskipamount \divide\smallskipamount\plusfour}
+ \medskipamount \bigskipamount \divideby\medskipamount \plustwo
+ \smallskipamount\bigskipamount \divideby\smallskipamount\plusfour}
%D Snapping.
@@ -1855,7 +1861,7 @@
{\c_attr_skipcategory\pluseleven}
%permanent\def\vspacingfromscratchtoks {\scratchdimen\dimexpr\csname\??vspacingamount\the\scratchtoks\endcsname\relax}
-\permanent\def\vspacingpredefinedvalue#1{\scratchskip\glueexpr\csname\??vspacingamount#1\endcsname\relax}
+\permanent\def\vspacingpredefinedvalue#1{\s_spac_vspacing_predefined\glueexpr\csname\??vspacingamount#1\endcsname\relax}
%permanent\def\vspacingfromtempstring {\scratchdimen\dimexpr\csname\??vspacingamount\tempstring\endcsname\relax}
% \installcorenamespace{vspacingamountnormal}
@@ -2014,7 +2020,7 @@
%D used in itemize \unknown\ always test this:
-\newdimen\d_spac_overlay
+\newdimension\d_spac_overlay
\def\spac_overlay_lines
{\directcheckedvspacing{\v!back,\v!overlay}% \blank[\v!back,\v!overlay]%
@@ -2059,9 +2065,9 @@
\definevspacing[\s!default] [\v!white] % was big for a while
-\newcount\c_spac_vspacing_special_base \c_spac_vspacing_special_base = 32250 % 4000
-\newcount\c_spac_vspacing_special_step \c_spac_vspacing_special_step = 10 % 250
-\newcount\c_spac_vspacing_special_done
+\newinteger\c_spac_vspacing_special_base \c_spac_vspacing_special_base = 32250 % 4000
+\newinteger\c_spac_vspacing_special_step \c_spac_vspacing_special_step = 10 % 250
+\newinteger\c_spac_vspacing_special_done
% 2019-05-31 : upgraded a bit to more distinctive samepage-[level]-[0|1|2] names
@@ -2332,7 +2338,7 @@
% \prerollblank[2*line] \the\prerolledblank
% \prerollblank[-2*line] \the\prerolledblank
-\newskip\prerolledblank
+\newgluespec\prerolledblank
\permanent\protected\def\prerollblank[#1]%
{\begingroup
@@ -2349,12 +2355,12 @@
\kern\zeropoint
\blank[\p_blank]}%
% \dimexpr doesn't work well with skips
- \advance\scratchskip-\ht\scratchbox
+ \advanceby\scratchskip-\ht\scratchbox
\global\prerolledblank-\scratchskip
\fi
\endgroup}
-\newcount\c_spac_vspacing_ignore_parskip
+\newinteger\c_spac_vspacing_ignore_parskip
% \setupwhitespace[line]
% \setuphead[subject][after={\blank[packed]},style=\bfb]
@@ -2396,4 +2402,66 @@
\permanent\tolerant\protected\def\blankbefore[#1]{\vadjust pre {\ifcstok{#1}\emptytoks\blank\else\blank[#1]\fi}}
\permanent\tolerant\protected\def\blankafter [#1]{\vadjust post{\ifcstok{#1}\emptytoks\blank\else\blank[#1]\fi}}
+%D Experimental:
+
+\installcorenamespace{textdisplay}
+
+\installcommandhandler \??textdisplay {textdisplay} \??textdisplay
+
+\appendtoks
+ \frozen\protected\edefcsname\e!start\currenttextdisplay\endcsname{\spac_textdisplay_start{\currenttextdisplay}}%
+ \frozen\protected\edefcsname\e!stop \currenttextdisplay\endcsname{\spac_textdisplay_stop}%
+\to \everydefinetextdisplay
+
+\setuptextdisplay
+ [\c!factor=.5,
+ \c!after=\textdisplayparameter\c!before]
+
+\tolerant\protected\def\spac_textdisplay_start#1#:[#2]%
+ {\par
+ \begingroup
+ \edef\currenttextdisplay{#1}%
+ \setupcurrenttextdisplay[#2]%
+ \textdisplayparameter\c!before
+ \dbox
+ \bgroup
+ \strut
+ \vskip-\lineheight
+ \vbox
+ \s!yoffset -\textdisplayparameter\c!factor\strutdp
+ \bgroup}
+
+\protected\def\spac_textdisplay_stop
+ {\egroup
+ \vskip-\lineheight\strut
+ \egroup
+ \textdisplayparameter\c!after
+ \endgroup
+ \par}
+
+\definetextdisplay[\v!textdisplay]
+
+% \useMPlibrary[dum]
+%
+% \definetextdisplay[steppedbystep][before={\blank[halfline]}]
+%
+% \starttext \showmakeup[line]
+% \dostepwiserecurse{10}{25}{1}{
+% xxxxxxxxxxxxxxxx\par
+% \starttextdisplay
+% \externalfigure[dummydummy][height=#1mm,text=no]%
+% \stoptextdisplay
+% xxxxxxxxxxxxxxxx\par
+% \starttextdisplay[before=\blank,after=\blank] % factor=.5
+% \externalfigure[dummydummy][height=#1mm,text=no]%
+% \stoptextdisplay
+% xxxxxxxxxxxxxxxx\par
+% \startsteppedbystep
+% \externalfigure[dummydummy][height=#1mm,text=no]%
+% \stopsteppedbystep
+% xxxxxxxxxxxxxxxx\par
+% \page
+% }
+% \stoptext
+
\protect \endinput
diff --git a/tex/context/base/mkxl/strc-con.mklx b/tex/context/base/mkxl/strc-con.mklx
index d931bc779..0f7750bfe 100644
--- a/tex/context/base/mkxl/strc-con.mklx
+++ b/tex/context/base/mkxl/strc-con.mklx
@@ -552,11 +552,11 @@
[\c!renderingsetup=\??constructionrenderings:\v!label,
\c!width=]
-\newbox \constructionheadbox
-\newskip \leftconstructionskip
-\newskip \rightconstructionskip
-\newdimen \constructionsheadwidth
-\newdimen \constructionsheaddistance
+\newbox \constructionheadbox
+\newgluespec \leftconstructionskip
+\newgluespec \rightconstructionskip
+\newdimension\constructionsheadwidth
+\newdimension\constructionsheaddistance
\def\strc_constructions_set_hang_box#1% messy left/rightskip
{\setbox\constructionheadbox\vtop % \vbox gaat fout in hang
@@ -569,7 +569,7 @@
\setupalign[\p_strc_constructions_headalign]% use fast one
\fi
\ifconditional\c_strc_constructions_distance_none \else
- \advance\ifx#1\v!flushleft\rightskip\else\leftskip\fi\constructionsheaddistance % only difference and wrong anyway
+ \advanceby\ifx#1\v!flushleft\rightskip\else\leftskip\fi\constructionsheaddistance % only difference and wrong anyway
\fi
\flushconstructionheadbox}%
\setbox\constructionheadbox\hpack{\box\constructionheadbox}% needed in case of e.g. a real big head font, see descriptions-006.tex
@@ -676,7 +676,7 @@
\hskip\rightconstructionskip
}
\nobreak
- \advance\rightskip \constructionsheaddistance
+ \advanceby\rightskip \constructionsheaddistance
\useconstructionstyleandcolor\c!style\c!color
\ignorespaces
\stopsetups
@@ -722,7 +722,7 @@
\startsetups[\??constructionrenderings:\v!left:\v!hanging]%
\enforced\let\\\crlf
\dontcomplain
- \advance\constructionsheadwidth \constructionsheaddistance
+ \advanceby\constructionsheadwidth \constructionsheaddistance
\strc_constructions_set_hang_box\v!flushleft
\strc_constructions_set_hang\v!left
\noindent
@@ -739,7 +739,7 @@
\startsetups[\??constructionrenderings:\v!right:\v!hanging]%
\enforced\let\\\crlf
\dontcomplain
- \advance\constructionsheadwidth \constructionsheaddistance
+ \advanceby\constructionsheadwidth \constructionsheaddistance
\strc_constructions_set_hang_box\v!flushright
\strc_constructions_set_hang\v!right
\noindent
@@ -883,7 +883,7 @@
% tricky: leftskipadaption is somewhat unpredictable
\enforced\let\\\crlf
\noindent
- \advance\leftskip-\leftskipadaption\relax
+ \advanceby\leftskip-\leftskipadaption\relax
\ifdim\leftskipadaption=\zeropoint
\leftskipadaption1.5\emwidth\relax % just some default
\ifnum\c_strc_constructions_nested_state=\plusone
@@ -893,7 +893,7 @@
\fi
\fi
\ifnum\c_strc_constructions_nested_state>\zerocount % was \ifnum\c_strc_constructions_nested_state=\plusone
- \advance\leftskip\leftskipadaption % but we're already further on
+ \advanceby\leftskip\leftskipadaption % but we're already further on
\fi
\hskip-\leftskipadaption\relax
\ifhbox\constructionheadbox \unhbox\else\box\fi\constructionheadbox
diff --git a/tex/context/base/mkxl/strc-flt.mklx b/tex/context/base/mkxl/strc-flt.mklx
index f444a9b1c..68d97593b 100644
--- a/tex/context/base/mkxl/strc-flt.mklx
+++ b/tex/context/base/mkxl/strc-flt.mklx
@@ -414,10 +414,10 @@
\egroup
\fi}
-\newbox \b_strc_floats_caption
-\newbox \b_strc_floats_content
-\newdimen\d_strc_floats_caption_height
-\newdimen\d_strc_floats_caption_depth
+\newbox \b_strc_floats_caption
+\newbox \b_strc_floats_content
+\newdimension\d_strc_floats_caption_height
+\newdimension\d_strc_floats_caption_depth
\lettonothing\m_strc_floats_last_caption_tag
@@ -530,7 +530,7 @@
%D We can do this ...
%D
%D \starttyping
-%D \newcount\c_strc_floats_n
+%D \newinteger\c_strc_floats_n
%D
%D \definedataset[\s!float][\c!delay=\v!yes]
%D
@@ -540,7 +540,7 @@
%D {\setdataset[\s!float][\number\c_strc_floats_n][]}
%D
%D \def\strc_float_load_data % precedes save !
-%D {\global\advance\c_strc_floats_n\plusone
+%D {\global\advanceby\c_strc_floats_n\plusone
%D \xdef\strc_float_realpage{\datasetvariable\s!float{\number\c_strc_floats_n}\s!page}%
%D \ifempty\strc_float_realpage
%D \glet\strc_float_realpage\realpageno % \realfolio
@@ -551,7 +551,7 @@
\definepagestate[\s!float][\c!delay=\v!yes]
-\newcount\c_strc_floats_n
+\newinteger\c_strc_floats_n
\let\strc_float_realpage\realpageno
@@ -559,7 +559,7 @@
{\setpagestate[\s!float][\number\c_strc_floats_n]}
\def\strc_float_load_data % precedes save !
- {\global\advance\c_strc_floats_n\plusone
+ {\global\advanceby\c_strc_floats_n\plusone
\xdef\strc_float_realpage{\pagestaterealpage\s!float{\number\c_strc_floats_n}}%
\ifempty\strc_float_realpage
\glet\strc_float_realpage\realpageno % \realfolio
@@ -888,9 +888,9 @@
% nicer is a bunch of states and one loop that sets those states
-\newdimen\d_strc_floats_top
-\newdimen\d_strc_floats_bottom
-\newdimen\d_strc_floats_overflow
+\newdimension\d_strc_floats_top
+\newdimension\d_strc_floats_bottom
+\newdimension\d_strc_floats_overflow
% \def\strc_floats_calculate_skip#target#skip%
% {\begingroup
@@ -1031,13 +1031,13 @@
\permanent\def\floatcaptionwidth {\the\floatcaptionht}
\permanent\def\floatcaptiondepth {\the\floatcaptiondp}
-\newdimen\naturalfloatwd
-\newdimen\naturalfloatht
-\newdimen\naturalfloatdp
+\newdimension\naturalfloatwd
+\newdimension\naturalfloatht
+\newdimension\naturalfloatdp
-\newdimen\floatcaptionwd
-\newdimen\floatcaptionht
-\newdimen\floatcaptiondp
+\newdimension\floatcaptionwd
+\newdimension\floatcaptionht
+\newdimension\floatcaptiondp
\def\strc_floats_set_natural_dimensions#box%
{\global\naturalfloatwd\wd#box\relax
@@ -1215,8 +1215,8 @@
\strc_floats_get_box
\global\insidefloatfalse}
-\newdimen\availablefloatwidth
-\newdimen\availablefloatheight
+\newdimension\availablefloatwidth
+\newdimension\availablefloatheight
\def\strc_floats_set_local_hsize
{\ifconditional\c_page_floats_center_box_local
@@ -1310,14 +1310,14 @@
\global\d_page_sides_downshift\zeropoint
\scratchconditiononetrue
\fi
- \global\advance\d_page_sides_downshift#sign\lineheight}
+ \global\advanceby\d_page_sides_downshift#sign\lineheight}
\def\strc_floats_move_down_hang#lines%
{\ifscratchconditiontwo \else
\global\c_page_sides_n_of_lines\zerocount
\scratchconditiontwotrue
\fi
- \global\advance\c_page_sides_n_of_lines#lines\relax}
+ \global\advanceby\c_page_sides_n_of_lines#lines\relax}
\permanent\protected\def\movedownsidefloat[#settings]% already in core
{\unless\ifhastok:{#settings}%
@@ -1618,16 +1618,16 @@
\let\strc_floats_align_indeed_local\firstofoneargument
-\newdimen\d_strc_floats_content
-\newdimen\d_strc_float_temp_height
-\newdimen\d_strc_float_temp_width
+\newdimension\d_strc_floats_content
+\newdimension\d_strc_float_temp_height
+\newdimension\d_strc_float_temp_width
\newconditional\c_floats_adapt_to_caption_width
\newconditional\c_floats_store_minimal_package
-\newdimen\d_strc_floats_caption_hsize
-\newdimen\d_strc_floats_caption_min_width
-\newdimen\d_strc_floats_caption_overshoot
+\newdimension\d_strc_floats_caption_hsize
+\newdimension\d_strc_floats_caption_min_width
+\newdimension\d_strc_floats_caption_overshoot
% These are expandable, for diagnostic purposes only, but might eventually go away:
@@ -2461,7 +2461,7 @@
\strc_floats_set_page_variant
\fi
\strc_floats_set_local_dimensions
- \global\advance\totalnoffloats\plusone
+ \global\advanceby\totalnoffloats\plusone
\ifconditional\c_floats_store_minimal_package \else
\setbox\floatbox\hpack{\strc_float_save_data\box\floatbox}% still needed? we will do renumbering differently
\fi
@@ -2626,14 +2626,15 @@
\initializeboxstack\??localfloatstack
-\newcount\c_strc_localfloats_n \aliased\let\noflocalfloats\c_strc_localfloats_n
+%newcount \c_strc_localfloats_n \aliased\let \noflocalfloats\c_strc_localfloats_n
+\newinteger\c_strc_localfloats_n \aliasinteger\noflocalfloats\c_strc_localfloats_n
\permanent\protected\def\resetlocalfloats
{\global\c_strc_localfloats_n\zerocount
\initializeboxstack\??localfloatstack}
\permanent\protected\def\somelocalfloat
- {\global\advance\c_strc_localfloats_n\plusone
+ {\global\advanceby\c_strc_localfloats_n\plusone
\savebox\??localfloatstack{\number\c_strc_localfloats_n}{\box\floatbox}}
\permanent\protected\def\getlocalfloats
diff --git a/tex/context/base/mkxl/strc-ind.mkxl b/tex/context/base/mkxl/strc-ind.mkxl
index 1ba64bbd3..10bd7f468 100644
--- a/tex/context/base/mkxl/strc-ind.mkxl
+++ b/tex/context/base/mkxl/strc-ind.mkxl
@@ -55,9 +55,9 @@
%D
%D \typebuffer \getbuffer
-\newcount\c_strc_indentedtexts_nesting
-\newdimen\d_strc_indentedtexts_width
-\newdimen\d_strc_indentedtexts_distance
+\newinteger \c_strc_indentedtexts_nesting
+\newdimension\d_strc_indentedtexts_width
+\newdimension\d_strc_indentedtexts_distance
\appendtoks
\frozen\instance\setuevalue {\e!start\currentindentedtext}{\strc_indentedtexts_start{\currentindentedtext}\c_strc_indentedtexts_nesting}%
@@ -84,7 +84,7 @@
\indentedtextparameter\c!sample
\spr{\indentedtextparameter\c!separator}}
{\d_strc_indentedtexts_distance}%
- \advance\d_strc_indentedtexts_width \d_strc_indentedtexts_distance
+ \advanceby\d_strc_indentedtexts_width \d_strc_indentedtexts_distance
\setbox\scratchbox\hbox to \d_strc_indentedtexts_width
{\useindentedtextstyleandcolor\c!headstyle\c!headcolor
\strut
@@ -94,7 +94,7 @@
\hskip\d_strc_indentedtexts_distance}%
\parindent\zeropoint
\hskip\c_strc_indentedtexts_nesting\d_strc_indentedtexts_width
- \advance\c_strc_indentedtexts_nesting\plusone
+ \advanceby\c_strc_indentedtexts_nesting\plusone
\dontleavehmode\box\scratchbox
\hangindent\c_strc_indentedtexts_nesting\d_strc_indentedtexts_width
\useindentedtextstyleandcolor\c!style\c!color}
diff --git a/tex/context/base/mkxl/strc-itm.mklx b/tex/context/base/mkxl/strc-itm.mklx
index a4a0b283a..fd07208c6 100644
--- a/tex/context/base/mkxl/strc-itm.mklx
+++ b/tex/context/base/mkxl/strc-itm.mklx
@@ -213,15 +213,15 @@
\newbox \b_strc_itemgroups
-\newdimen \d_strc_itemgroups_list_width
-\newdimen \d_strc_itemgroups_asked_width
+\newdimension \d_strc_itemgroups_list_width
+\newdimension \d_strc_itemgroups_asked_width
-\newdimen \d_strc_itemgroups_max_width % multipass
-\newcount \c_strc_itemgroups_max_items % multipass
+\newdimension \d_strc_itemgroups_max_width % multipass
+\newinteger \c_strc_itemgroups_max_items % multipass
-\newcount \c_strc_itemgroups_n_of_items
-\newcount \c_strc_itemgroups_nesting
-\newcount \c_strc_itemgroups_column_depth
+\newinteger \c_strc_itemgroups_n_of_items
+\newinteger \c_strc_itemgroups_nesting
+\newinteger \c_strc_itemgroups_column_depth
\def \v_strc_itemgroups_counter {itemgroup:\currentparentitemgroup}
\lettonothing \m_strc_itemgroups_repeat_start
@@ -801,12 +801,12 @@
\orelse\ifnum\itemgroupparameter\c!factor>\zerocount
\d_strc_itemgroups_list_width\itemgroupparameter\c!step\relax
\ifzeropt\d_strc_itemgroups_list_width \d_strc_itemgroups_list_width=.5em\fi
- \multiply\d_strc_itemgroups_list_width \itemgroupparameter\c!factor
- \advance\d_strc_itemgroups_list_width\itemgroupparameter\c!width\relax
+ \multiplyby\d_strc_itemgroups_list_width \itemgroupparameter\c!factor
+ \advanceby\d_strc_itemgroups_list_width\itemgroupparameter\c!width\relax
\else
\d_strc_itemgroups_list_width\itemgroupparameter\c!width\relax
\fi
- \advance\d_strc_itemgroups_list_width\itemgroupparameter\c!distance\relax
+ \advanceby\d_strc_itemgroups_list_width\itemgroupparameter\c!distance\relax
\let\currentitemgroup\m_strc_itemgroups_saved}
\lettonothing\p_itemgroups_options
@@ -817,7 +817,7 @@
\nofarguments\lastarguments
\def\currentitemgroup{#category}% no nested mixing of itemgroups
\let\currentparentitemgroup\currentitemgroup
- \global\advance\c_strc_itemgroups_nesting\plusone
+ \global\advanceby\c_strc_itemgroups_nesting\plusone
\def\currentitemlevel{\number\c_strc_itemgroups_nesting}%
\normalexpanded{\chaintocurrentitemgroup{\currentparentitemgroup:\currentitemlevel}}%
\edef\currentitemgroup{\currentparentitemgroup:\currentitemlevel}%
@@ -966,7 +966,7 @@
\strc_itemgroups_calculate_list_width\c_strc_itemgroups_nesting
\ifdim\d_strc_itemgroups_list_width>\zeropoint\relax
\ifconditional\c_strc_itemgroups_inline\else
- \frozen\advance\leftskip\d_strc_itemgroups_list_width\relax
+ \frozen\advanceby\leftskip\d_strc_itemgroups_list_width\relax
\fi
\fi
\ifempty\m_strc_itemgroups_repeat_start
@@ -1086,7 +1086,7 @@
\iftrialtypesetting
\strc_counters_restore\v_strc_itemgroups_counter % could happen in LUA
\fi
- \global\advance\c_strc_itemgroups_nesting\minusone
+ \global\advanceby\c_strc_itemgroups_nesting\minusone
\xdef\currentitemlevel{\number\c_strc_itemgroups_nesting}%
%\ifconditional\c_strc_itemgroups_text
\endgroup % (2)
@@ -1119,7 +1119,7 @@
\ifconditional\c_strc_itemgroups_intro\strc_itemgroups_insert_breakno\fi
\fi}
-\newcount\c_strc_itemgroups_prev_level
+\newinteger\c_strc_itemgroups_prev_level
\def\strc_itemgroups_inbetween_command
{\nameditemgroupparameter{\currentparentitemgroup:\number\c_strc_itemgroups_prev_level}\c!inbetween}
@@ -1279,7 +1279,7 @@
\protected\def\strc_itemgroups_start_no_item
{\lettonothing\currentitemreference
\strc_itemgroups_increment_item_counter
- %\advance\c_strc_itemgroups_n_of_items\plusone
+ %\advanceby\c_strc_itemgroups_n_of_items\plusone
\setbox\b_strc_itemgroups\emptyhbox
\strc_itemgroups_check_for_repeated
\ignorepars} % \ignorespaces
@@ -1387,9 +1387,9 @@
\def\strc_itemgroups_handle_text_item
{\scratchdimen\wd\b_strc_itemgroups
- \advance \scratchdimen \itemgroupparameter\c!distance\relax
+ \advanceby \scratchdimen \itemgroupparameter\c!distance\relax
\ifdim\scratchdimen>\d_strc_itemgroups_list_width
- \advance\scratchdimen -\d_strc_itemgroups_list_width
+ \advanceby\scratchdimen -\d_strc_itemgroups_list_width
\else
\scratchdimen\zeropoint
\fi
@@ -1520,7 +1520,7 @@
\else
\par % done twice?
\fi
- \advance\c_strc_itemgroups_n_of_items\plusone
+ \advanceby\c_strc_itemgroups_n_of_items\plusone
\strc_itemgroups_optimize_breaks
\strc_itemgroups_check_indenting
\dontleavehmode
@@ -1566,7 +1566,7 @@
\def\strc_itemgroups_start_item_nop
{\lettonothing\currentitemreference
\strc_itemgroups_increment_item_counter
- \advance\c_strc_itemgroups_n_of_items\plusone
+ \advanceby\c_strc_itemgroups_n_of_items\plusone
\setbox\b_strc_itemgroups\hbox
{\useitemgroupstyleandcolor\c!style\c!color
\strc_itemgroups_used_symbol}%
@@ -1714,16 +1714,16 @@
% better collectitems als conditional and a real plugin mechanism (some day)
-\newcount\c_strc_itemgroups_collected_stored
-\newcount\c_strc_itemgroups_collected_done
-\newcount\c_strc_itemgroups_collected_current
+\newinteger\c_strc_itemgroups_collected_stored
+\newinteger\c_strc_itemgroups_collected_done
+\newinteger\c_strc_itemgroups_collected_current
\let\strc_itemgroups_collected_store\relax
\lettonothing\m_strc_itemgroups_collected
\normalexpanded{\def\strc_itemgroups_collected_store#1\csname\e!stop\v!item\endcsname}%
- {\advance\c_strc_itemgroups_collected_stored\plusone
+ {\advanceby\c_strc_itemgroups_collected_stored\plusone
\setvalue{\??itemgroupstack\number\c_strc_itemgroups_collected_stored}{\startitemgroupitem#1\stopitemgroupitem}}
\def\strc_itemgroups_collected_flush_randomize
@@ -1751,7 +1751,7 @@
{\ifconditional\c_strc_itemgroups_randomize
\getrandomcount\c_strc_itemgroups_collected_current\plusone\c_strc_itemgroups_collected_stored
\else
- \advance\c_strc_itemgroups_collected_current\plusone
+ \advanceby\c_strc_itemgroups_collected_current\plusone
\fi
\ifcsname\??itemgroupstack\number\c_strc_itemgroups_collected_current\endcsname
\edef\m_strc_itemgroups_collected{\lastnamedcs}%
@@ -1760,7 +1760,7 @@
\else
\strc_itemgroups_collected_flush_indeed
\fi
- \advance\c_strc_itemgroups_collected_done\plusone
+ \advanceby\c_strc_itemgroups_collected_done\plusone
\fi
\ifnum\c_strc_itemgroups_collected_done<\c_strc_itemgroups_collected_stored
\expandafter\strc_itemgroups_collected_flush
diff --git a/tex/context/base/mkxl/strc-lnt.mklx b/tex/context/base/mkxl/strc-lnt.mklx
index 31a558a06..331be8737 100644
--- a/tex/context/base/mkxl/strc-lnt.mklx
+++ b/tex/context/base/mkxl/strc-lnt.mklx
@@ -23,8 +23,8 @@
\aliased\let\setuplinenote\setupnote
-\newcount\c_strc_linenotes
-\newtoks\everydefinelinenote
+\newinteger\c_strc_linenotes
+\newtoks \everydefinelinenote
\permanent\tolerant\protected\def\definelinenote[#1]#*[#2]#*[#3]%
{\ifarguments
@@ -55,13 +55,13 @@
\fi}
\protected\def\strc_linenotes_direct#1#2%
- {\global\advance\c_strc_linenotes\plusone
+ {\global\advanceby\c_strc_linenotes\plusone
\strc_linenotes_indeed{#1}{\the\c_strc_linenotes}{#2}%
\strc_linenotes_traced\empty
\normalexpanded{\someline[\the\c_strc_linenotes]}}
\protected\def\strc_linenotes_start#1[#2]#3%
- {\global\advance\c_strc_linenotes\plusone
+ {\global\advanceby\c_strc_linenotes\plusone
\keepunwantedspaces
\strc_linenotes_indeed{#1}{#2}{#3}%
\strc_linenotes_traced{#2}%
diff --git a/tex/context/base/mkxl/strc-lst.mklx b/tex/context/base/mkxl/strc-lst.mklx
index e14f0c735..652a40c89 100644
--- a/tex/context/base/mkxl/strc-lst.mklx
+++ b/tex/context/base/mkxl/strc-lst.mklx
@@ -1033,7 +1033,7 @@
\startsetups[\??listrenderings:abc]
\endgraf % are we grouped?
\typo_injectors_check_list
- % \advance % yes or no ... \rightskip is also honored
+ % \advanceby % yes or no ... \rightskip is also honored
\leftskip\listparameter\c!margin % after \endgraf !
\listparameter\c!before
\endgraf
@@ -1178,7 +1178,7 @@
\startsetups[\??listrenderings:d]
\ifvmode
- \advance\leftskip\listparameter\c!margin
+ \advanceby\leftskip\listparameter\c!margin
\fi
\begingroup
\ifvmode
diff --git a/tex/context/base/mkxl/strc-mat.mkxl b/tex/context/base/mkxl/strc-mat.mkxl
index bac25c520..0d2f85239 100644
--- a/tex/context/base/mkxl/strc-mat.mkxl
+++ b/tex/context/base/mkxl/strc-mat.mkxl
@@ -670,7 +670,7 @@
\abovedisplayshortskip\zeropoint
\belowdisplayshortskip\zeropoint
-\newdimen\d_strc_formulas_display_width
+\newdimension\d_strc_formulas_display_width
%D In \LMTX\ we have three ways of rendering formulas:
%D
@@ -693,8 +693,7 @@
\newconditional\c_strc_formulas_tight
\newconditional\c_strc_formulas_packed
\newconditional\c_strc_formulas_depth
-
-\newbox\b_strc_formulas_number
+\newbox \b_strc_formulas_number
\def\strc_formulas_display_space_before_normal
{% not ok, try \stopformula\par\startformula vs \stopformula\startformula
@@ -830,8 +829,8 @@
\let\setdisplaydimensions\relax % this one will be defined in math-ali
\fi
-% \newskip\formulastrutht
-% \newskip\formulastrutdp
+% \newgluespec\formulastrutht
+% \newgluespec\formulastrutdp
%D \startbuffer
%D \startformula[9pt] x = 1 \stopformula
@@ -1007,7 +1006,7 @@
\defineboundary[mathalign] % this one is also used at the lua end
\newconditional\c_strc_math_trace_hang
-\newdimen \d_strc_math_hang_state
+\newdimension \d_strc_math_hang_state
\installtextracker
{math.autohang}
@@ -1041,9 +1040,9 @@
\orelse\ifchknum#1\or
\d_strc_math_hang_state#1\scratchdimen
\orelse\iftok{#1}{+}%
- \advance\d_strc_math_hang_state\scratchdimen
+ \advanceby\d_strc_math_hang_state\scratchdimen
\orelse\iftok{#1}{-}%
- \advance\d_strc_math_hang_state-\scratchdimen
+ \advanceby\d_strc_math_hang_state-\scratchdimen
\else
\d_strc_math_hang_state\scratchdimen
\fi
@@ -1352,12 +1351,12 @@
% a limitation is that this only works in a regular setting, so no shapes
-\newcount\c_strc_math_n_of_lines
-\newdimen\d_strc_math_max_width
-\newdimen\d_strc_math_first_width
-\newdimen\d_strc_math_last_width
-\newdimen\d_strc_math_first_height
-\newdimen\d_strc_math_last_depth
+\newinteger \c_strc_math_n_of_lines
+\newdimension\d_strc_math_max_width
+\newdimension\d_strc_math_first_width
+\newdimension\d_strc_math_last_width
+\newdimension\d_strc_math_first_height
+\newdimension\d_strc_math_last_depth
\appendtoks
\global\d_strc_math_indent \zeropoint
@@ -1371,8 +1370,8 @@
\newbox\b_strc_math_display % most code is in math-ali (for historical reasons)
-\newskip\s_strc_formulas_margin_left
-\newskip\s_strc_formulas_margin_right
+\newgluespec\s_strc_formulas_margin_left
+\newgluespec\s_strc_formulas_margin_right
\def\strc_formulas_set_paragraph
{%\setlocalhsize
@@ -1460,7 +1459,7 @@
% \hangindent\d_strc_math_indent
% \else
% this might become the default anyway:
- \advance\leftskip\d_strc_math_indent
+ \advanceby\leftskip\d_strc_math_indent
\hskip-\d_strc_math_indent
% \fi
\fi
@@ -1556,7 +1555,7 @@
\fi
\bgroup % HERE
\iftrialtypesetting\else
- \global\advance\c_strc_formulas_n\plusone
+ \global\advanceby\c_strc_formulas_n\plusone
\fi
\def\currentformula{#1}%
\dostarttaggedchained\t!formula\currentformula\??formula
@@ -1589,7 +1588,7 @@
% tagging of formulanumbers is not ok (we get two display maths blobs)
-\newcount\c_strc_formulas_n
+\newinteger\c_strc_formulas_n
\ifdefined\dotagregisterformula \else \aliased\let\dotagregisterformula\gobbleoneargument \fi
@@ -1761,13 +1760,13 @@
\lettonothing\currentformula
% \strc_formulas_forget_display_skips
\enforced\protected\def\startformula
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\expandafter\gobbleuntil\csname\e!stop\v!formula\endcsname}%
\scratchcounter\zerocount
#2% preroll
\hbox to \d_strc_formulas_display_width \bgroup
\ifcase\scratchcounter\else
- \divide\d_strc_formulas_display_width\scratchcounter
+ \divideby\d_strc_formulas_display_width\scratchcounter
\fi
\hss
\enforced\let\startformula\strc_formulas_nested_formula_start
diff --git a/tex/context/base/mkxl/strc-not.mklx b/tex/context/base/mkxl/strc-not.mklx
index 76c95ab18..3bddc7126 100644
--- a/tex/context/base/mkxl/strc-not.mklx
+++ b/tex/context/base/mkxl/strc-not.mklx
@@ -1041,11 +1041,10 @@
\strc_notes_set_delayed
\to \everysynchronizenote
-\newskip \s_strc_notes_distance % we need to implement stretch
-\newcount\c_strc_notes_columns
-
-\newskip \s_strc_notes_before
-\newskip \s_strc_notes_inbetween
+\newgluespec \s_strc_notes_distance % we need to implement stretch
+\newinteger \c_strc_notes_columns
+\newgluespec \s_strc_notes_before
+\newgluespec \s_strc_notes_inbetween
\newconditional\c_strc_notes_first_flushed
% we can store them per insert so so real need to redo it
@@ -1858,16 +1857,16 @@
\permanent\def\docalculatetotalnoteheight
{\ifcase\c_strc_notes_page_location % tricky here ! ! ! to be sorted out ! ! !
- \advance\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}%
+ \advanceby\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}%
\fi}
\permanent\def\docalculatetotalclevernoteheight
{\ifcase\c_strc_notes_page_location \else % tricky here ! ! ! to be sorted out ! ! !
- \advance\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}%
+ \advanceby\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}%
\fi}
\permanent\def\docalculatetotalpagenoteheight
- {\advance\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}}
+ {\advanceby\totalnoteheight\normalexpanded{\additionaltotalnoteheight\currentnoteinsertionnumber}}
\permanent\def\calculatetotalnoteheight {\totalnoteheight\zeropoint\strc_notes_process\docalculatetotalnoteheight}
\permanent\def\calculatetotalclevernoteheight{\totalnoteheight\zeropoint\strc_notes_process\docalculatetotalclevernoteheight}
diff --git a/tex/context/base/mkxl/strc-pag.mkxl b/tex/context/base/mkxl/strc-pag.mkxl
index 19fd573dd..ffdd7772b 100644
--- a/tex/context/base/mkxl/strc-pag.mkxl
+++ b/tex/context/base/mkxl/strc-pag.mkxl
@@ -237,7 +237,7 @@
\strc_pagenumbers_decrement_counters
\to \everygoodbye
-\newcount\c_strc_subpage_first_real \c_strc_subpage_first_real\plusone
+\newinteger\c_strc_subpage_first_real \c_strc_subpage_first_real\plusone
\appendtoks
\ifcase\subpageno\relax
diff --git a/tex/context/base/mkxl/strc-ref.mklx b/tex/context/base/mkxl/strc-ref.mklx
index c55509f54..de8cd29e1 100644
--- a/tex/context/base/mkxl/strc-ref.mklx
+++ b/tex/context/base/mkxl/strc-ref.mklx
@@ -27,13 +27,13 @@
\writestatus{loading}{ConTeXt Structure Macros / Cross Referencing}
-\newif \iflocation
-\newcount\locationcount
-\newcount\locationorder
-\newbox \locationbox
-
-\newcount\lastreferenceattribute
-\newcount\lastdestinationattribute
+\newif \iflocation
+\newinteger\locationcount
+\newinteger\locationorder
+\newbox \locationbox
+\newinteger\lastreferenceattribute
+\newinteger\lastdestinationattribute
+\newinteger\prefixcounter
\registerctxluafile{strc-rsc}{autosuffix}
\registerctxluafile{strc-ref}{autosuffix}
@@ -145,8 +145,8 @@
%D Actually there is not much difference between a text and a full reference, but
%D it's the concept that counts. The low level implementation is:
-% sett top : \newcount\lastreferenceattribute
-% sett top : \newcount\lastdestinationattribute
+% sett top : \newinteger\lastreferenceattribute
+% sett top : \newinteger\lastdestinationattribute
\def\strc_references_finish#prefix#reference#internal% gets expanded anyway
{\normalexpanded{\clf_deferredenhancereference{#prefix}{#reference}}}
@@ -798,8 +798,8 @@
%D
%D The flag \type {\iflocation} signals if we're in interactive mode.
-\ifdefined\buttonheight \else \newdimen\buttonheight \fi
-\ifdefined\buttonwidth \else \newdimen\buttonwidth \fi
+\ifdefined\buttonheight \else \newdimension\buttonheight \fi
+\ifdefined\buttonwidth \else \newdimension\buttonwidth \fi
%D Internal references can best be set using the next few macros. Setting such
%D references to unique values is completely up to the macros that call them.
@@ -811,10 +811,10 @@
%D
%D We could do this in \LUA\ \unknown
-% seet top: \newif \iflocation
-% seet top: \newcount\locationcount
-% seet top: \newcount\locationorder
-% seet top: \newbox \locationbox
+% seet top: \newif \iflocation
+% seet top: \newinteger\locationcount
+% seet top: \newinteger\locationorder
+% seet top: \newbox \locationbox
\appendtoks
\locationfalse
@@ -824,7 +824,7 @@
\permanent\def\nextinternalorderreference{\the\locationorder}
\permanent\def\setnextinternalreference
- {\global\advance\locationcount\plusone}
+ {\global\advanceby\locationcount\plusone}
% defined at the lua end
%
@@ -882,7 +882,7 @@
%D \type {\prefix} variable to \type {+}, the prefix is incremented, when set to
%D \type {-} or empty, the prefix is reset. Other values become the prefix.
-\newcount\prefixcounter
+% \see top: newinteger\prefixcounter
\newconditional\autocrossfilereferences
@@ -926,7 +926,7 @@
\lettonothing\referenceprefix
\orelse\ifx\p_prefix\m_strc_references_prefix_yes
\letreferencingparameter\c!prefix\s!unknown
- \global\advance\prefixcounter\plusone
+ \global\advanceby\prefixcounter\plusone
\edef\referenceprefix{\the\prefixcounter}%
\orelse\ifx\p_prefix\m_strc_references_prefix_nop
\letreferencingparameter\c!prefix\s!unknown
@@ -1076,7 +1076,7 @@
% }
% }
-\newcount \nofreferencestates
+\newinteger \nofreferencestates
\newconditional\pagestatespread
\appendtoks
@@ -1125,7 +1125,7 @@
% issue warning that not stable
\else
% needs checking ... but probably never in trialmode
- \global\advance\nofreferencestates\plusone
+ \global\advanceby\nofreferencestates\plusone
\xypos{rst::\number\nofreferencestates}%
% \tracedpagestate
\fi
@@ -1479,7 +1479,7 @@
% The unbox trick is needed in order to permit \par inside a reference. Otherwise
% the reference attribute migrates to the outer boxes.
-\newcount\lastsavedreferenceattribute
+\newinteger\lastsavedreferenceattribute
\newbox\referencebox
diff --git a/tex/context/base/mkxl/strc-reg.mkxl b/tex/context/base/mkxl/strc-reg.mkxl
index 3af07f0a4..485b68b74 100644
--- a/tex/context/base/mkxl/strc-reg.mkxl
+++ b/tex/context/base/mkxl/strc-reg.mkxl
@@ -847,9 +847,9 @@
%D placeindex as then flushing takes place inside the index. Took me hours
%D to notice that.
-\newconstant\c_strc_registers_page_state % 0=nothing 1=page 2=see
-\newdimen \d_strc_registers_distance
-\newcount \c_strc_register_level
+\newconstant \c_strc_registers_page_state % 0=nothing 1=page 2=see
+\newdimension\d_strc_registers_distance
+\newinteger \c_strc_register_level
\def\strc_registers_update_text_properties
{\ifx\m_current_register\currentregister\else
@@ -875,8 +875,8 @@
\dostoptagged
\endgroup}
-\newdimen\d_strc_registers_hangindent
-\newcount\c_strc_registers_hangafter
+\newdimension\d_strc_registers_hangindent
+\newinteger \c_strc_registers_hangafter
% \permanent\protected\def\usenestedregisterstyleandcolor#1#2% will change
% {\useregisterstyleandcolor#1#2%
@@ -898,7 +898,7 @@
% \edef\currentregister{\currentregister:\number\c_strc_register_level}%
% \usenestedregisterstyleandcolor\c!textstyle\c!textcolor
% \ifnum\c_strc_register_level>\plusone
-% \advance\leftskip\d_strc_registers_distance\relax
+% \advanceby\leftskip\d_strc_registers_distance\relax
% \fi
% \d_strc_registers_hangindent\registerparameter\c!distance\relax
% \c_strc_registers_hangafter \plusone
@@ -962,7 +962,7 @@
\let\currentnestedregister\currentregister
\usenestedregisterstyleandcolor\c!textstyle\c!textcolor
\ifnum\c_strc_register_level>\plusone
- \advance\leftskip\d_strc_registers_distance\relax
+ \advanceby\leftskip\d_strc_registers_distance\relax
\fi
\d_strc_registers_hangindent\registerparameter\c!distance\relax
\c_strc_registers_hangafter \plusone
diff --git a/tex/context/base/mkxl/strc-ren.mkxl b/tex/context/base/mkxl/strc-ren.mkxl
index 1c9c23ac0..b78155d21 100644
--- a/tex/context/base/mkxl/strc-ren.mkxl
+++ b/tex/context/base/mkxl/strc-ren.mkxl
@@ -15,10 +15,9 @@
\unprotect
-\newbox\b_strc_rendering_head
-
-\newdimen\d_strc_rendering_local_leftoffset
-\newdimen\d_strc_rendering_local_rightoffset
+\newbox \b_strc_rendering_head
+\newdimension\d_strc_rendering_local_leftoffset
+\newdimension\d_strc_rendering_local_rightoffset
% Martin Kolarik's problem:
%
@@ -246,12 +245,11 @@
% \subsubsection {Test\\Test} \input tufte \page
% \subsubsubsection{Test\\Test} \input tufte \page
-\newdimen\d_strc_rendering_hang_height
-\newcount\n_strc_rendering_hang_lines
-
-\newdimen\d_strc_rendering_local_height
-\newdimen\d_strc_rendering_local_depth
-\newdimen\d_strc_rendering_local_lineheight
+\newdimension\d_strc_rendering_hang_height
+\newinteger \n_strc_rendering_hang_lines
+\newdimension\d_strc_rendering_local_height
+\newdimension\d_strc_rendering_local_depth
+\newdimension\d_strc_rendering_local_lineheight
\def\strc_rendering_initialize_line_state
{\global\d_strc_rendering_local_height\strutht
@@ -469,11 +467,11 @@
\lettonothing\headnumbercontent
\lettonothing\headtextcontent
-\newdimen\headwidth
-\newdimen\headtextwidth
-\newskip \headtextdistance
-\newdimen\headnumberdistance
-\newdimen\headnumberwidth
+\newdimension\headwidth
+\newdimension\headtextwidth
+\newgluespec \headtextdistance
+\newdimension\headnumberdistance
+\newdimension\headnumberwidth
% \newconditional\headshownumber % defined already
% \newconditional\headisdisplay % defined already
@@ -778,7 +776,7 @@
}
\setbox\scratchboxtwo\vbox {
\headsetupspacing
- \advance\hsize-\wd\scratchboxone\relax
+ \advanceby\hsize-\wd\scratchboxone\relax
\headtextcontent
}
\hpack {
@@ -807,7 +805,7 @@
}
\setbox\scratchboxtwo\vtop {
\headsetupspacing
- \advance\hsize-\wd\scratchboxone\relax
+ \advanceby\hsize-\wd\scratchboxone\relax
\headtextcontent
}
\hpack {
diff --git a/tex/context/base/mkxl/strc-sec.mkxl b/tex/context/base/mkxl/strc-sec.mkxl
index 9ac35ee15..3ea3a990b 100644
--- a/tex/context/base/mkxl/strc-sec.mkxl
+++ b/tex/context/base/mkxl/strc-sec.mkxl
@@ -65,7 +65,7 @@
% nothing
\orelse\ifx\currentstructurereferenceprefix\m_strc_references_prefix_yes
\ifempty\currentstructurereference
- \global\advance\prefixcounter \plusone % temp here
+ \global\advanceby\prefixcounter \plusone % temp here
\setupglobalreferenceprefix[\the\prefixcounter]%
\else
\setupglobalreferenceprefix[\currentstructurereference]%
@@ -529,7 +529,7 @@
% 0 = block
% +1 = structurelevel 1 .. n
-\newcount\maxstructuredepth
+\newinteger\maxstructuredepth
\permanent\def\sectionlevel#1%
{\csname\??headlevel\ifcsname\??headlevel#1\endcsname#1\else\v!none\fi\endcsname}
@@ -561,7 +561,7 @@
{\ifcsname\??headlevel#1\endcsname \else
\edef\currenthead{#1}%
\let\currentsection\currenthead % just an alias
- \global\advance\maxstructuredepth\plusone
+ \global\advanceby\maxstructuredepth\plusone
\edefcsname\??headlevel#1\endcsname{\the\maxstructuredepth}%
\setstructurelevel{#1}{\sectionlevel{#1}}%
\normalexpanded{\setheadparameter{\s!parent}{\??head\lastsectionname}}% TO BE CHECKED, WE HAVE A HELPER
@@ -1150,7 +1150,7 @@
\doifelselayouttextline\v!footer{\normalexpanded{\setuplayouttext[\v!footer][\c!state=\p_footer]}}\donothing
\fi}
-\newcount \c_strc_sectioning_preceding_level \c_strc_sectioning_preceding_level\plusone
+\newinteger \c_strc_sectioning_preceding_level \c_strc_sectioning_preceding_level\plusone
\newconditional\c_strc_sectioning_auto_break \settrue\c_strc_sectioning_auto_break
\newconditional\c_strc_sectioning_ignore_page
\newboundary \c_strc_sectioning_boundary
diff --git a/tex/context/base/mkxl/supp-box.mkxl b/tex/context/base/mkxl/supp-box.mkxl
index cc934fe04..8a2a90a1a 100644
--- a/tex/context/base/mkxl/supp-box.mkxl
+++ b/tex/context/base/mkxl/supp-box.mkxl
@@ -24,9 +24,13 @@
%D And some dimensions:
-\newdimen\givenwidth
-\newdimen\givenheight
-\newdimen\givendepth
+\newdimension\strutht % see above
+\newdimension\strutdp
+\newdimension\struthtdp
+
+\newdimension\givenwidth
+\newdimension\givenheight
+\newdimension\givendepth
% \fixupboxesmode\plusone % gone: is now the default
@@ -40,11 +44,14 @@
%D not, you're in trouble). These shortcuts can be used like a dimension, opposite
%D to the core macros \type {\strutdepth} and alike, which are values.
- \def\strutdp {\dp\strutbox} % overloaded in spac-ver
- \def\strutht {\ht\strutbox} % overloaded in spac-ver
-\permanent\protected\def\strutwd {\wd\strutbox}
- \def\struthtdp{\htdp\strutbox} % overloaded in spac-ver
-\permanent\protected\def\strutgap {\dimexpr\strutht-\strutdp\relax}
+\iffalse
+ \def\strutdp {\dp\strutbox} % overloaded in spac-ver
+ \def\strutht {\ht\strutbox} % overloaded in spac-ver
+ \def\struthtdp{\htdp\strutbox} % overloaded in spac-ver
+\fi
+
+\permanent\protected\def\strutwd {\wd\strutbox}
+\permanent\protected\def\strutgap{\dimexpr\strutht-\strutdp\relax}
%D \macros
%D {voidbox,nextbox}
@@ -62,7 +69,7 @@
%D \DIMENSION\ \type{\prevdepth} and append it later on. The name \type {\nextdepth}
%D suits this purpose well.
-\newdimen\nextdepth
+\newdimension\nextdepth
%D \macros
%D {smashbox, smashboxed, smashedbox}
@@ -96,7 +103,7 @@
%D The next implementation is less sensitive for spurious spaces.
-\newcount\c_boxes_register
+\newinteger\c_boxes_register
\permanent\protected\def\smashbox
{\afterassignment\syst_boxes_smash_boxes_register\c_boxes_register}
@@ -185,7 +192,7 @@
%D \stopTEXpage
%D \stoptyping
-% \newcount\c_boxes_math_style
+% \newinteger\c_boxes_math_style
%
% \protected\def\syst_boxes_math_set_nextbox#1%
% {\c_boxes_math_style\normalmathstyle
@@ -373,7 +380,7 @@
%D
%D \starttyping
%D \def\getboxheight#1\of#2\box#3%
-%D {#1\ht#3\advance#1\dp#3\relax}
+%D {#1\ht#3\advanceby#1\dp#3\relax}
%D \stoptyping
%D
%D The next alternative is slightly more clever, since it accepts \type {{12}} as
@@ -400,25 +407,25 @@
%D met 0~regels. The raw alternative does not round. See the \MKII\ and \MKIV\ files
%D for historic variants.
-\ifdefined\roundingeps \else \newdimen\roundingeps \roundingeps=10sp \fi
+\ifdefined\roundingeps \else \newdimension\roundingeps \roundingeps=10sp \fi
-\newcount\noflines
-\newdimen\noflinesheight
+\newinteger \noflines
+\newdimension\noflinesheight
\permanent\protected\def\getnoflines#1%
{\noflinesheight#1\relax
\ifzeropt\noflinesheight
\noflines\zerocount
\orelse\ifdim\noflinesheight>\zeropoint
- \advance\noflinesheight-\roundingeps
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight-\roundingeps
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
- \advance\noflines\plusone
+ \advanceby\noflines\plusone
\else
- \advance\noflinesheight\roundingeps
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight\roundingeps
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
- \advance\noflines\minusone
+ \advanceby\noflines\minusone
\fi}
\permanent\protected\def\getroundednoflines#1%
@@ -426,12 +433,12 @@
\ifzeropt\noflinesheight
\noflines\zerocount
\orelse\ifdim\noflinesheight>\zeropoint
- \advance\noflinesheight\roundingeps
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight\roundingeps
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
\else
- \advance\noflinesheight-\roundingeps
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight-\roundingeps
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
\fi}
@@ -440,14 +447,14 @@
\ifzeropt\noflinesheight
\noflines\zerocount
\orelse\ifdim\noflinesheight>\zeropoint
- \advance\noflinesheight\roundingeps
- \advance\noflinesheight.5\openlineheight
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight\roundingeps
+ \advanceby\noflinesheight.5\openlineheight
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
\else
- \advance\noflinesheight-\roundingeps
- \advance\noflinesheight-.5\openlineheight
- \divide\noflinesheight\openlineheight
+ \advanceby\noflinesheight-\roundingeps
+ \advanceby\noflinesheight-.5\openlineheight
+ \divideby\noflinesheight\openlineheight
\noflines\noflinesheight
\fi}
@@ -493,7 +500,7 @@
% \unvbox\nextbox
% \endofshapebox
% \globalscratchcounter\zerocount
-% \reshapebox{\global\advance\globalscratchcounter\plusone}%
+% \reshapebox{\global\advanceby\globalscratchcounter\plusone}%
% \expandafter\egroup\expandafter\noflines\the\globalscratchcounter\relax}
\def\syst_boxes_determine_noflines
@@ -842,18 +849,15 @@
\newif \ifreshapingbox
\newif \ifreshapingfailed % may save redundant runs
-\newbox \shapebox
-\newcount \shapepenalty
-\newdimen \shapekern
-\newskip \shapeskip
-
-\newbox \newshapebox
-\newbox \oldshapebox
-\newbox \tmpshapebox
-
-\newcount \shapecounter
-
-\newevery \everyshapebox \relax
+\newbox \shapebox
+\newinteger \shapepenalty
+\newdimension\shapekern
+\newgluespec \shapeskip
+\newbox \newshapebox
+\newbox \oldshapebox
+\newbox \tmpshapebox
+\newinteger \shapecounter
+\newevery \everyshapebox \relax
\permanent\dimensiondef\shapesignal.12345678pt % or 12345sp
@@ -917,7 +921,7 @@
\restoreshapebox
\exitloop
\else
- \advance\shapecounter \plusone
+ \advanceby\shapecounter \plusone
\fi}
\permanent\protected\def\beginofshapebox
@@ -1146,7 +1150,7 @@
\def\syst_boxes_boundtext#1%
{\setbox\scratchboxone\hbox{#1}%
- \advance\scratchdimen -\wd\scratchboxone
+ \advanceby\scratchdimen -\wd\scratchboxone
\ifdim\scratchdimen>\zeropoint\relax#1\fi}
\permanent\protected\def\doboundtext#1#2#3% still used?
@@ -1155,7 +1159,7 @@
\scratchdimen#2\relax
\ifdim\wd\scratchbox>\scratchdimen
\setbox\scratchbox\hbox{#3}%
- \advance\scratchdimen -\wd\scratchbox
+ \advanceby\scratchdimen -\wd\scratchbox
\handletokens#1\with\syst_boxes_boundtext
\fi
\box\scratchbox}}
@@ -1210,7 +1214,7 @@
\ifdim\wd\scratchbox>#2\relax
\setbox\scratchbox\hbox{#3}%
\hsize#2\relax
- \advance\hsize-\wd\scratchbox
+ \advanceby\hsize-\wd\scratchbox
\setbox\scratchbox\vbox{\forgetall\veryraggedright#1}%
\setbox\scratchbox\vsplit\scratchbox to \lineheight
\vbox
@@ -1478,8 +1482,8 @@
\dontcomplain
\forgetall
\scangivendimensions#1\relax
- \advance\vsize\givenheight
- \advance\hsize\givenwidth
+ \advanceby\vsize\givenheight
+ \advanceby\hsize\givenwidth
\dowithnextboxcs\syst_boxes_centered_finish
\hbox}
@@ -1563,19 +1567,19 @@
\mutable\let\rigidcolumnlines\!!zerocount
-\newbox \rigidcolumnbox
-\newdimen\rigidhsize
-\newcount\rigidcolumns
+\newbox \rigidcolumnbox
+\newdimension\rigidhsize
+\newinteger \rigidcolumns
\permanent\protected\def\setrigidcolumnhsize#1#2#3% todo: \dimexpr
{\global\rigidhsize\hsize
\global\rigidcolumns#3\relax
\hsize#1\relax
\scratchdimen -#2\relax
- \multiply\scratchdimen #3\relax
- \advance\scratchdimen #2\relax
- \advance\hsize \scratchdimen
- \divide\hsize #3\relax}
+ \multiplyby\scratchdimen #3\relax
+ \advanceby\scratchdimen #2\relax
+ \advanceby\hsize \scratchdimen
+ \divideby\hsize #3\relax}
% ==
%
@@ -1600,15 +1604,15 @@
% \iffalse
% % maybe some day an option
% \scratchskip\ht\rigidcolumnbox
- % \advance\scratchskip\dp\rigidcolumnbox
+ % \advanceby\scratchskip\dp\rigidcolumnbox
% \getnoflines\scratchskip
% \ifodd\noflines
- % \advance\noflines\plusone
+ % \advanceby\noflines\plusone
% \fi
- % \divide\noflines\rigidcolumns
+ % \divideby\noflines\rigidcolumns
%\else
\scratchdimen\ht\rigidcolumnbox
- \divide\scratchdimen \rigidcolumns
+ \divideby\scratchdimen \rigidcolumns
\getnoflines\scratchdimen
%\fi
\else
@@ -1635,11 +1639,11 @@
\box\scratchbox
\hfill}%
\hfillneg}%
- \ifvoid\rigidcolumnbox\exitloop\else\advance\scratchdimen\lineheight\fi}%
+ \ifvoid\rigidcolumnbox\exitloop\else\advanceby\scratchdimen\lineheight\fi}%
\iftightrigidcolumns
\setbox\scratchbox\hpack{\raise\dp\scratchbox\box\scratchbox}%
\else
- \advance\scratchdimen -\openstrutdepth
+ \advanceby\scratchdimen -\openstrutdepth
\setbox\scratchbox\hpack{\raise\scratchdimen\box\scratchbox}%
\dp\scratchbox\openstrutdepth
\ht\scratchbox\scratchdimen
@@ -1671,8 +1675,8 @@
%D These macros are used in reformatting footnotes, so they do what they're meant
%D for.
-\newdimen\vboxtohboxslack
-\newdimen\hboxestohboxslack
+\newdimension\vboxtohboxslack
+\newdimension\hboxestohboxslack
%D Create line and fake height of paragraph by messign with heights: a nice hack by
%D DEK himself.
@@ -1681,13 +1685,13 @@
% {\bgroup
% \ifdim\baselineskip<16pt \relax
% \scratchdimen\baselineskip
-% \multiply\scratchdimen 1024
+% \multiplyby\scratchdimen 1024
% \else
% \message{cropping \baselineskip to 16pt}%
% \scratchdimen\maxdimen
% \fi
-% \divide\scratchdimen \hsize
-% \multiply\scratchdimen 64
+% \divideby\scratchdimen \hsize
+% \multiplyby\scratchdimen 64
% \xdef\vboxtohboxfactor{\toscaled\scratchdimen}%
% \egroup}
%
@@ -1774,10 +1778,10 @@
%D The next macro is used in typesetting inline headings. Let's first look at the
%D macro and then show an example.
-\newbox \unhhedbox
-\newbox \hhbox
-\newdimen \lasthhboxwidth
-\newskip \hhboxindent
+\newbox \unhhedbox
+\newbox \hhbox
+\newdimension\lasthhboxwidth
+\newgluespec \hhboxindent
\permanent\protected\def\unhhbox#1\with#2%
{\bgroup
@@ -1826,7 +1830,7 @@
%D \unhhbox0\with{\ruledhbox{\box\hhbox}}
%D \hskip1em plus 1em minus 1em
%D \hhboxindent=\lasthhboxwidth
-%D \advance\hhboxindent by \lastskip
+%D \advanceby\hhboxindent by \lastskip
%D \unhhbox2\with{\ruledhbox{\box\hhbox}}
%D \stopbuffer
%D
@@ -2103,14 +2107,14 @@
%D This example demonstrates that one can use positive and negative values.
%D Dimension registers are also accepted.
-\newdimen\sizeofbox
+\newdimension\sizeofbox
\permanent\protected\def\boxofsize#1%
{\bgroup
\sizeofbox\zeropoint
\scratchdimen\zeropoint
\def\docommand
- {\advance\sizeofbox\scratchdimen
+ {\advanceby\sizeofbox\scratchdimen
\futurelet\nexttoken\dodocommand}%
\def\dodocommand
{\ifx\nexttoken\bgroup
@@ -2132,7 +2136,7 @@
{\scratchdimen#1\hsize
\ifdim\wd\nextbox>\scratchdimen
\setbox\nextbox\hbox
- {\advance\scratchdimen -.1\hsize
+ {\advanceby\scratchdimen -.1\hsize
\limitatetext{\unhbox\nextbox}{\scratchdimen}{\nobreak#2}}%
\fi
\unhbox\nextbox}
@@ -2148,7 +2152,7 @@
\hpack{\box\nextbox}
\prevdepth\strutdp
\doloop
- {\advance\scratchdimen -\lineheight
+ {\advanceby\scratchdimen -\lineheight
\ifdim\scratchdimen<\zeropoint
\exitloop
\else
@@ -2187,9 +2191,9 @@
\permanent\protected\def\placedbox
{\iftraceboxplacement\ruledhbox\else\hbox\fi}
-\newdimen\boxoffset
-\newdimen\boxhdisplacement
-\newdimen\boxvdisplacement
+\newdimension\boxoffset
+\newdimension\boxhdisplacement
+\newdimension\boxvdisplacement
\permanent\protected\def\rightbox {\hpack\bgroup\dowithnextboxcs\syst_boxes_rightbox_finish \placedbox}
\permanent\protected\def\leftbox {\hpack\bgroup\dowithnextboxcs\syst_boxes_leftbox_finish \placedbox}
@@ -2326,8 +2330,8 @@
\permanent\protected\def\lrtbbox#1#2#3#4% l r t b
{\bgroup
\dowithnextboxcontent
- {\advance\hsize-#1\advance\hsize-#2\relax
- \advance\vsize-#3\advance\vsize-#4\relax}
+ {\advanceby\hsize-#1\advanceby\hsize-#2\relax
+ \advanceby\vsize-#3\advanceby\vsize-#4\relax}
{\forgetall\vpack to \vsize{\vskip#3\hpack to \hsize{\hskip#1\box\nextbox\hss}\vss}\egroup}
\vbox}
@@ -2342,7 +2346,7 @@
\def\syst_boxes_toplinebox_finish
{\ifdim\dp\nextbox>\strutdepth
\scratchdimen\dp\nextbox
- \advance\scratchdimen-\strutdepth
+ \advanceby\scratchdimen-\strutdepth
\getnoflines\scratchdimen
\struttedbox{\box\nextbox}%
\dorecurse\noflines\verticalstrut
@@ -2432,7 +2436,7 @@
\installcorenamespace {boxstack}
-\newcount\c_syst_boxes_stack
+\newinteger\c_syst_boxes_stack
\mutable\let\b_syst_boxes_stack\relax
@@ -2441,7 +2445,7 @@
\letcsname\??boxstack\number\c_syst_boxes_stack\endcsname\b_syst_boxes_stack}
\protected\def\syst_boxes_push#1#2%
- {\global\advance\c_syst_boxes_stack\plusone
+ {\global\advanceby\c_syst_boxes_stack\plusone
\expandafter\let\expandafter\b_syst_boxes_stack\csname\??boxstack\number\c_syst_boxes_stack\endcsname
\ifrelax\b_syst_boxes_stack % cheaper then csname check as in most cases it's defined
\syst_boxes_stack_allocate
@@ -2450,7 +2454,7 @@
\protected\def\syst_boxes_pop#1#2%
{#1\setbox#2\box\csname\??boxstack\number\c_syst_boxes_stack\endcsname
- \global\advance\c_syst_boxes_stack\minusone}
+ \global\advanceby\c_syst_boxes_stack\minusone}
\permanent\protected\def\localpushbox {\syst_boxes_push\relax}
\permanent\protected\def\localpopbox {\syst_boxes_pop \relax}
@@ -2757,9 +2761,9 @@
%D \setbox0\hbox to 10cm{foo} \the\naturalwd0
%D \stoptyping
-\newdimen\lastnaturalboxwd
-\newdimen\lastnaturalboxht
-\newdimen\lastnaturalboxdp
+\newdimension\lastnaturalboxwd
+\newdimension\lastnaturalboxht
+\newdimension\lastnaturalboxdp
%D We can define these public in lua:
diff --git a/tex/context/base/mkxl/syst-aux.mkxl b/tex/context/base/mkxl/syst-aux.mkxl
index 410d959bf..f968cba97 100644
--- a/tex/context/base/mkxl/syst-aux.mkxl
+++ b/tex/context/base/mkxl/syst-aux.mkxl
@@ -80,7 +80,7 @@
\else
- \newcount\c_syst_helpers_n_of_namespaces \c_syst_helpers_n_of_namespaces\pluseight % 1-8 reserved for catcodes
+ \newinteger\c_syst_helpers_n_of_namespaces \c_syst_helpers_n_of_namespaces\pluseight % 1-8 reserved for catcodes
\def\v_interfaces_prefix_template_system{\number \c_syst_helpers_n_of_namespaces>>}
%def\v_interfaces_prefix_template_system{\characters\c_syst_helpers_n_of_namespaces>>} % no \characters yet
@@ -91,7 +91,7 @@
{\ifcsname ??#1\endcsname
\writestatus\m!system{duplicate system namespace '#1'}\wait
\else
- \global\advance\c_syst_helpers_n_of_namespaces\plusone
+ \global\advanceby\c_syst_helpers_n_of_namespaces\plusone
\immutable\edefcsname ??#1\endcsname{\v_interfaces_prefix_template_system}%
\fi}
@@ -1781,13 +1781,13 @@
%D Afterwards, the length is available in the macro \type {\commalistsize}
%D (not a \COUNTER).
-\newcount\commalistcounter
+\newinteger\commalistcounter
\mutable\def\commalistsize{0}
\def\syst_helpers_get_comma_list_size#0,% no #- as we need to count
{\ifarguments\or
- \advance\commalistcounter\plusone
+ \advanceby\commalistcounter\plusone
\expandafter\syst_helpers_get_comma_list_size
\fi}
@@ -1826,7 +1826,7 @@
\def\syst_helpers_get_from_comma_list#1,%
{\ifarguments \or
- \advance\commalistcounter \minusone
+ \advanceby\commalistcounter \minusone
\ifcase\commalistcounter
\def\commalistelement{#1}%
\expandafter\expandafter\expandafter\syst_helpers_gobble_comma_list
@@ -1945,7 +1945,7 @@
%D We use some signals for telling the calling macros if all wanted arguments are
%D indeed supplied by the user.
-\newcount\nofarguments
+\newinteger\nofarguments
\newif\iffirstargument
\newif\ifsecondargument
@@ -3120,11 +3120,11 @@
%D Signals old dimensions and can be used in skips, kerns and tests like \type
%D {\ifdim}.
-\newdimen\d_syst_maximum_signal % step is about 0.00025pt
+\newdimension\d_syst_maximum_signal % step is about 0.00025pt
\permanent\protected\def\newsignal#1%
{\ifdefined#1\else
- \advance\d_syst_maximum_signal2\scaledpoint % to be save in rounding
+ \advanceby\d_syst_maximum_signal2\scaledpoint % to be save in rounding
\immutable\dimensiondef#1\d_syst_maximum_signal
\fi}
@@ -3189,8 +3189,8 @@
%D We now use the macro stack which is somewhat leaner and meaner and a little
%D faster too.
-\newcount\outerrecurse
-\newcount\innerrecurse
+\newinteger\outerrecurse
+\newinteger\innerrecurse
\mutable\def\recursedepth{\the\outerrecurse}
\mutable\def\recurselevel{0}
@@ -3217,7 +3217,7 @@
%% \else
%% \def\recurselevel{#1}%
%% \innerrecurse#1\relax
-%% \advance\innerrecurse#3\relax
+%% \advanceby\innerrecurse#3\relax
%% \doubleexpandafter\syst_helpers_stepwise_reverse_yes
%% \fi\expandafter{\the\numexpr\recurselevel+#3\relax}{#2}{#3}}
%%
@@ -3287,7 +3287,7 @@
%% \expandafter\syst_helpers_recurse_indeed_nop
%% \else
%% \def\recurselevel{#1}%
-%% \innerrecurse#1\advance\innerrecurse\plusone
+%% \innerrecurse#1\advanceby\innerrecurse\plusone
%% \doubleexpandafter\syst_helpers_recurse_indeed_yes
%% \fi\expandafter{\the\innerrecurse}{#2}}
%%
@@ -3332,7 +3332,7 @@
\aliased\let\endofloop\donothing % maybe \syst_helpers_loop_end
\permanent\protected\def\doloop#1%
- {\global\advance\outerrecurse \plusone
+ {\global\advanceby\outerrecurse \plusone
\globalpushmacro\recurseaction
\globalpushmacro\recurselevel
\protected\gdef\recurseaction##1##2{#1}%
@@ -3355,7 +3355,7 @@
{\enforced\let\endofloop\syst_helpers_loop
\globalpopmacro\recurselevel
\globalpopmacro\recurseaction
- \global\advance\outerrecurse\minusone}
+ \global\advanceby\outerrecurse\minusone}
\permanent\protected\def\exitloop % \exitloop quits at end
{\enforced\let\endofloop\syst_helpers_loop_nop}
@@ -3402,17 +3402,17 @@
%% {\normalexpanded{\recurseaction{\recurselevel}{\the\outerrecurse}}}
%%
%% \protected\def\syst_helpers_recurse_x#1#2%
-%% {\global\advance\outerrecurse\plusone
+%% {\global\advanceby\outerrecurse\plusone
%% \globalpushmacro\recurseaction
%% \globalpushmacro\recurselevel
%% \protected\gdef\recurseaction##1##2{#2}%
%% \expandafter\syst_helpers_recurse_indeed\expandafter1\expandafter{\number#1}%
%% \globalpopmacro\recurselevel
%% \globalpopmacro\recurseaction
-%% \global\advance\outerrecurse\minusone}
+%% \global\advanceby\outerrecurse\minusone}
%%
%% \protected\def\syst_helpers_recurse_y#1#2%
-%% {\global\advance\outerrecurse\plusone
+%% {\global\advanceby\outerrecurse\plusone
%% \globalpushmacro\recurseaction
%% \globalpushmacro\recurselevel
%% \let\recurselevel\!!plusone
@@ -3420,10 +3420,10 @@
%% \syst_helpers_recurse_content
%% \globalpopmacro\recurselevel
%% \globalpopmacro\recurseaction
-%% \global\advance\outerrecurse\minusone}
+%% \global\advanceby\outerrecurse\minusone}
%%
%% \permanent\protected\def\dostepwiserecurse#1#2#3#4% can be made faster by postponing #4 ... todo: remove unused helpers
-%% {\global\advance\outerrecurse \plusone
+%% {\global\advanceby\outerrecurse \plusone
%% \globalpushmacro\recurseaction
%% \globalpushmacro\recurselevel
%% \protected\gdef\recurseaction##1##2{#4}%
@@ -3442,10 +3442,10 @@
%% \fi\normalexpanded{{\number#1}{\number#2}{\number#3}}}%
%% \globalpopmacro\recurselevel
%% \globalpopmacro\recurseaction
-%% \global\advance\outerrecurse\minusone}
+%% \global\advanceby\outerrecurse\minusone}
-\newcount\fastloopindex
-\newcount\fastloopfinal
+\newinteger\fastloopindex
+\newinteger\fastloopfinal
\let\m_syst_helpers_fast_loop_cs\relax
@@ -3467,7 +3467,7 @@
\let\m_syst_helpers_fast_loop_cs\relax
\else
\m_syst_helpers_fast_loop_cs
- \advance\fastloopindex\plusone
+ \advanceby\fastloopindex\plusone
\expandafter\syst_helpers_fast_loop_cs_step
\fi}
@@ -3564,14 +3564,14 @@
%D \stoptyping
\permanent\protected\def\doloopoverlist#1#2%
- {\global\advance\outerrecurse\plusone
+ {\global\advanceby\outerrecurse\plusone
\globalpushmacro\recurseaction
\globalpushmacro\recursestring
\protected\gdef\recurseaction##1{\edef\recursestring{##1}#2}%
\processcommacommand[#1]\recurseaction
\globalpopmacro\recursestring
\globalpopmacro\recurseaction
- \global\advance\outerrecurse\minusone}
+ \global\advanceby\outerrecurse\minusone}
%D This is some \LMTX\ experiment:
%D
@@ -4905,7 +4905,7 @@
%D
%D This macro was used in the bibtex code (and is probably no longer needed).
-\newcount\c_syst_helpers_comma_list_index
+\newinteger\c_syst_helpers_comma_list_index
\lettonothing\m_syst_helpers_comma_list_target
@@ -4938,7 +4938,7 @@
\fi
\fi
\fi
- \advance\commalistcounter\plusone}
+ \advanceby\commalistcounter\plusone}
\permanent\protected\def\replaceincommalist#1#2% #1 = commalistelement #2 = position starts at 1
{\c_syst_helpers_comma_list_index#2\relax
@@ -5029,10 +5029,10 @@
%D Simple but effective are the next two macros. There name exactly states their
%D purpose.
-\newdimen\d_syst_helpers_swapped
-\newskip \s_syst_helpers_swapped
-\newcount\c_syst_helpers_swapped
-\let \m_syst_helpers_swapped\relax
+\newdimension\d_syst_helpers_swapped
+\newgluespec \s_syst_helpers_swapped
+\newinteger \c_syst_helpers_swapped
+\let \m_syst_helpers_swapped\relax
% \protected\def\swapdimens#1#2{\d_syst_helpers_swapped#1#1#2#2\d_syst_helpers_swapped}
% \protected\def\swapskips #1#2{\s_syst_helpers_swapped#1#1#2#2\s_syst_helpers_swapped}
@@ -5083,7 +5083,7 @@
%D These examples show us that an optional can be used. The value provided is added
%D to \type {\localhsize}.
-\newdimen\localhsize
+\newdimension\localhsize
\permanent\protected\def\setlocalhsize % don't change !
{\doifelsenextoptional
@@ -5095,7 +5095,7 @@
\def\syst_helpers_set_local_hsize_yes[#1]%
{\syst_helpers_set_local_hsize_nop
- \advance\localhsize#1\relax}
+ \advanceby\localhsize#1\relax}
\permanent\def\availablehsize
{\dimexpr
@@ -5756,7 +5756,7 @@
{\def\m_syst_string_three{#1}%
\ifx\m_syst_string_two\m_syst_string_three \else
\ifx\m_syst_string_one\m_syst_string_three
- \advance\privatescratchcounter\plusone
+ \advanceby\privatescratchcounter\plusone
\fi
\expandafter\syst_helpers_count_token
\fi}
@@ -5770,7 +5770,7 @@
\permanent\protected\def\counttokens#1\to#2%
{\privatescratchcounter\zerocount
- \def\syst_helpers_count_token##1{\advance\privatescratchcounter\plusone}%
+ \def\syst_helpers_count_token##1{\advanceby\privatescratchcounter\plusone}%
\handletokens#1\with\syst_helpers_count_token
\dodoglobal#2\privatescratchcounter}
@@ -5787,7 +5787,7 @@
\privatescratchcounter#1\relax
\def\syst_helpers_split_off_tokens##1%
{\ifnum\privatescratchcounter>\zerocount
- \advance\privatescratchcounter \minusone
+ \advanceby\privatescratchcounter \minusone
\edef#3{#3##1}%
\fi}%
% \lettonothing#3% #3 can be #2, so:
@@ -6095,7 +6095,7 @@
% can be sped up with ignored arguments
\def\syst_filter_from_next_yes#1%
- {\advance\scratchcounterone\plusone
+ {\advanceby\scratchcounterone\plusone
\ifnum\scratchcounterone=\scratchcountertwo
\scratchtoks{#1}%
\fi
@@ -6181,10 +6181,10 @@
%D This one can be used inside a measure (used in m4all):
%D
%D \starttyping
-%D \definemeasure[columnwidth][\dividedsize\textwidth{1em}{3}]
+%D \definemeasure[columnwidth][\dividebydsize\textwidth{1em}{3}]
%D \stoptyping
-\permanent\def\dividedsize#1#2#3% size gap n
+\permanent\def\dividebydsize#1#2#3% size gap n
{\dimexpr
\ifnum\dimexpr#1\relax>\plusone
(\dimexpr#1\relax-\numexpr#3-\plusone\relax\dimexpr#2\relax)/#3\else#1%
@@ -6230,8 +6230,8 @@
%D
%D We no longer use the \MKIV\ dirty trick. These are obsolete anyway.
-\newdimen \roundingeps \roundingeps=10sp
-\newconstant\compresult
+\newdimension\roundingeps \roundingeps=10sp
+\newconstant \compresult
\permanent\protected\def\comparedimension#1#2%
{\compresult
@@ -6372,14 +6372,14 @@
%D Sort of obsolete:
-\newcount\c_syst_helpers_mod
+\newinteger\c_syst_helpers_mod
\permanent\protected\def\dosetmodulo#1#2#3%
- {\c_syst_helpers_mod#1\divide\c_syst_helpers_mod#2\multiply\c_syst_helpers_mod#2%
- #3#1\advance#3-\c_syst_helpers_mod}
+ {\c_syst_helpers_mod#1\divideby\c_syst_helpers_mod#2\multiplyby\c_syst_helpers_mod#2%
+ #3#1\advanceby#3-\c_syst_helpers_mod}
\permanent\protected\def\dosetdivision#1#2#3%
- {#3#1\divide#3 #2\relax}
+ {#3#1\divideby#3 #2\relax}
\permanent\protected\def\DoMod#1by#2to#3{\dosetmodulo {#1}{#2}{#3}}
\permanent\protected\def\DoDiv#1by#2to#3{\dosetdivision{#1}{#2}{#3}}
@@ -6402,8 +6402,8 @@
\permanent\protected\def\elapsedsteptime % unexpanded ! a bit useless but who knows ...
{\clf_elapsedsteptime\elapsedsteps\relax}
-\newcount\c_syst_helpers_test_feature_n
-\newcount\c_syst_helpers_test_feature_m
+\newinteger\c_syst_helpers_test_feature_n
+\newinteger\c_syst_helpers_test_feature_m
\let\syst_helpers_test_feature_yes\relax
\let\syst_helpers_test_feature_nop\relax
@@ -6411,15 +6411,15 @@
\permanent\def\currentfeaturetest{\number\c_syst_helpers_test_feature_n}
\permanent\protected\def\testfeature#1#2%
- {\c_syst_helpers_test_feature_m#1\relax
+ {\c_syst_helpers_test_feature_m\ifparameter#1\or#1\else\maxiterator\fi\relax
\enforced\xdef\elapsedsteps{\number\c_syst_helpers_test_feature_m}%
\def\syst_helpers_test_feature_yes
- {\advance\c_syst_helpers_test_feature_n\plusone
+ {\advanceby\c_syst_helpers_test_feature_n\plusone
\ifnum\c_syst_helpers_test_feature_n>\c_syst_helpers_test_feature_m\else
#2\expandafter\syst_helpers_test_feature_yes
\fi}%
\def\syst_helpers_test_feature_nop
- {\advance\c_syst_helpers_test_feature_n\plusone
+ {\advanceby\c_syst_helpers_test_feature_n\plusone
\ifnum\c_syst_helpers_test_feature_n>\c_syst_helpers_test_feature_m\else
\expandafter\syst_helpers_test_feature_nop
\fi}%
diff --git a/tex/context/base/mkxl/syst-ini.mkxl b/tex/context/base/mkxl/syst-ini.mkxl
index b529c04bc..241b83ae4 100644
--- a/tex/context/base/mkxl/syst-ini.mkxl
+++ b/tex/context/base/mkxl/syst-ini.mkxl
@@ -343,6 +343,29 @@
\immutable\integerdef\statuswrite \minusone
+\immutable\dimensiondef\zeropoint 0pt
+
+%D These alternatives avoid the indirect references. Don't use these for generic
+%D code because one never knows what happens elsewhere.
+
+% \permanent\protected\def\newinteger #1{\ifdefined#1\else\integerdef #1\fi\zerocount} % can be relax
+% \permanent\protected\def\newdimension #1{\ifdefined#1\else\dimensiondef #1\fi\zeropoint}
+% \permanent\protected\def\newgluespec #1{\ifdefined#1\else\gluespecdef #1\fi\zeropoint}
+% \permanent\protected\def\newmugluespec#1{\ifdefined#1\else\mugluespecdef#1\fi\zeropoint}
+
+\permanent\protected\def\newinteger #1{\integerdef #1\zerocount}
+\permanent\protected\def\newdimension #1{\dimensiondef #1\zeropoint}
+\permanent\protected\def\newgluespec #1{\gluespecdef #1\zeropoint}
+\permanent\protected\def\newmugluespec#1{\mugluespecdef#1\zeropoint}
+
+%D The aliasing here is tricky: we need to make sure the alias is not let to the
+%D current value but behaves dynamic. Instead we can use just \newcount, unless of
+%D course I introduce a reference in the engine which is not more efficient so then
+%D one can as well use registers.
+
+\protected\def\aliasinteger #1#2{\untraced\protected\def#1{#2}}% name parent
+\protected\def\aliasdimension#1#2{\untraced\protected\def#1{#2}}% name parent
+
%D So, effectively we start allocating from 256 and upwards. The inserts sit in the
%D range 128 upto 254. Page numbers use the counters 0 upto 9 and the pagebox is
%D 255. Users can use the scratch registers upto 31 without problem but all others
@@ -375,11 +398,13 @@
{\ifrelax#1%
%\writestatus{!!!!!!!!!!}{\string #1 => RELAX}%
\unletfrozen#1%
- \newcount#1%
+ % \newcount#1%
+ \newinteger#1%
\orelse\ifdefined#1%
%\writestatus{!!!!!!!!!!}{\string #1 => DEFINED}%
\else
- \newcount#1%
+ % \newcount#1%
+ \newinteger#1%
\fi}
\permanent\protected\def\setnewconstant#1{\newconstant#1#1}
@@ -416,7 +441,7 @@
\def\syst_basics_allocate_yes#1#2#3#4#5% last class method max name
{\ifnum#1<#4\relax
- \global\advance#1\plusone
+ \global\advanceby#1\plusone
\permanent\global#3#5=#1\relax
\else
\writestatus{warning}{no room for \string#2\space \string#5\space (max: \number#4)}%
@@ -462,30 +487,30 @@
%D some available. The private ones are used in cases where we don't want to
%D intrude on normal scratch ones.
-\newcount \scratchcounter \newcount \globalscratchcounter \newcount \privatescratchcounter
-\newdimen \scratchdimen \newdimen \globalscratchdimen \newdimen \privatescratchdimen
-\newskip \scratchskip \newskip \globalscratchskip \newskip \privatescratchskip
-\newmuskip\scratchmuskip \newmuskip\globalscratchmuskip \newmuskip\privatescratchmuskip
-\newtoks \scratchtoks \newtoks \globalscratchtoks \newtoks \privatescratchtoks
-\newbox \scratchbox \newbox \globalscratchbox \newbox \privatescratchbox
-
-\newcount \scratchcounterone \newcount \scratchcountertwo \newcount \scratchcounterthree
-\newdimen \scratchdimenone \newdimen \scratchdimentwo \newdimen \scratchdimenthree
-\newskip \scratchskipone \newskip \scratchskiptwo \newskip \scratchskipthree
-\newmuskip \scratchmuskipone \newmuskip \scratchmuskiptwo \newmuskip \scratchmuskipthree
-\newtoks \scratchtoksone \newtoks \scratchtokstwo \newtoks \scratchtoksthree
-\newbox \scratchboxone \newbox \scratchboxtwo \newbox \scratchboxthree
-
-\newcount \scratchcounterfour \newcount \scratchcounterfive \newcount \scratchcountersix
-\newdimen \scratchdimenfour \newdimen \scratchdimenfive \newdimen \scratchdimensix
-\newskip \scratchskipfour \newskip \scratchskipfive \newskip \scratchskipsix
-\newmuskip \scratchmuskipfour \newmuskip \scratchmuskipfive \newmuskip \scratchmuskipsix
-\newtoks \scratchtoksfour \newtoks \scratchtoksfive \newtoks \scratchtokssix
-\newbox \scratchboxfour \newbox \scratchboxfive \newbox \scratchboxsix
-
-\newcount\globalscratchcounterone
-\newcount\globalscratchcountertwo
-\newcount\globalscratchcounterthree
+\newinteger \scratchcounter \newinteger \globalscratchcounter \newinteger \privatescratchcounter
+\newdimension\scratchdimen \newdimension\globalscratchdimen \newdimension\privatescratchdimen
+\newgluespec \scratchskip \newgluespec \globalscratchskip \newgluespec \privatescratchskip
+\newmuskip \scratchmuskip \newmuskip \globalscratchmuskip \newmuskip \privatescratchmuskip
+\newtoks \scratchtoks \newtoks \globalscratchtoks \newtoks \privatescratchtoks
+\newbox \scratchbox \newbox \globalscratchbox \newbox \privatescratchbox
+
+\newinteger \scratchcounterone \newinteger \scratchcountertwo \newinteger \scratchcounterthree
+\newdimension\scratchdimenone \newdimension\scratchdimentwo \newdimension\scratchdimenthree
+\newgluespec \scratchskipone \newgluespec \scratchskiptwo \newgluespec \scratchskipthree
+\newmuskip \scratchmuskipone \newmuskip \scratchmuskiptwo \newmuskip \scratchmuskipthree
+\newtoks \scratchtoksone \newtoks \scratchtokstwo \newtoks \scratchtoksthree
+\newbox \scratchboxone \newbox \scratchboxtwo \newbox \scratchboxthree
+
+\newinteger \scratchcounterfour\newinteger \scratchcounterfive \newinteger \scratchcountersix
+\newdimension\scratchdimenfour \newdimension\scratchdimenfive \newdimension\scratchdimensix
+\newgluespec \scratchskipfour \newgluespec \scratchskipfive \newgluespec \scratchskipsix
+\newmuskip \scratchmuskipfour \newmuskip \scratchmuskipfive \newmuskip \scratchmuskipsix
+\newtoks \scratchtoksfour \newtoks \scratchtoksfive \newtoks \scratchtokssix
+\newbox \scratchboxfour \newbox \scratchboxfive \newbox \scratchboxsix
+
+\newinteger\globalscratchcounterone
+\newinteger\globalscratchcountertwo
+\newinteger\globalscratchcounterthree
\mutable\let\scratchmacro \relax
\mutable\let\scratchmacroone\relax
@@ -505,46 +530,46 @@
%D
%D A few more scratch dimensions:
-\newdimen\scratchwidth
-\newdimen\scratchheight
-\newdimen\scratchdepth
-\newdimen\scratchitalic
-\newdimen\scratchtotal
+\newdimension\scratchwidth
+\newdimension\scratchheight
+\newdimension\scratchdepth
+\newdimension\scratchitalic
+\newdimension\scratchtotal
-\newdimen\scratchoffset
-\newdimen\scratchleftoffset
-\newdimen\scratchrightoffset
-\newdimen\scratchtopoffset
-\newdimen\scratchbottomoffset
+\newdimension\scratchoffset
+\newdimension\scratchleftoffset
+\newdimension\scratchrightoffset
+\newdimension\scratchtopoffset
+\newdimension\scratchbottomoffset
-\newdimen\scratchdistance
+\newdimension\scratchdistance
-\newdimen\scratchhsize
-\newdimen\scratchvsize
+\newdimension\scratchhsize
+\newdimension\scratchvsize
-\newdimen\scratchxoffset
-\newdimen\scratchyoffset
-\newdimen\scratchhoffset
-\newdimen\scratchvoffset
+\newdimension\scratchxoffset
+\newdimension\scratchyoffset
+\newdimension\scratchhoffset
+\newdimension\scratchvoffset
-\newdimen\scratchxposition
-\newdimen\scratchyposition
+\newdimension\scratchxposition
+\newdimension\scratchyposition
-\newcount\scratchnx
-\newcount\scratchny
+\newinteger\scratchnx
+\newinteger\scratchny
-\newcount\scratchmx
-\newcount\scratchmy
+\newinteger\scratchmx
+\newinteger\scratchmy
-\newcount\scratchmin
-\newcount\scratchmax
+\newinteger\scratchmin
+\newinteger\scratchmax
-\newcount\scratchunicode
+\newinteger\scratchunicode
-\newdimen\scratchleftskip
-\newdimen\scratchrightskip
-\newdimen\scratchtopskip
-\newdimen\scratchbottomskip
+\newdimension\scratchleftskip
+\newdimension\scratchrightskip
+\newdimension\scratchtopskip
+\newdimension\scratchbottomskip
%D More allocations:
@@ -560,7 +585,7 @@
\immutable\integerdef \maxcount 2147483647
-\immutable\dimensiondef \zeropoint 0pt
+%immutable\dimensiondef \zeropoint 0pt
\immutable\dimensiondef \onepoint 1pt
\immutable\dimensiondef \halfapoint 0.5pt
\immutable\dimensiondef \maxdimen 16383.99999pt % 1073741823sp
@@ -620,6 +645,7 @@
\immutable\integerdef\medcard 32768
\immutable\integerdef\maxcard 65536 % pdftex has less mathchars
\immutable\integerdef\maxcardminusone 65535
+\immutable\integerdef\maxiterator "FFFFF
\immutable\integerdef\binaryshiftedten 1024
\immutable\integerdef\binaryshiftedtwenty 1048576
@@ -1137,9 +1163,9 @@
%D The following registers are kind of standard and (for the moment) we define
%D them here. This might change.
-\newskip \bigskipamount \bigskipamount = 12pt plus 4pt minus 4pt
-\newskip \medskipamount \medskipamount = 6pt plus 2pt minus 2pt
-\newskip \smallskipamount \smallskipamount = 3pt plus 1pt minus 1pt
+\newgluespec \bigskipamount \bigskipamount = 12pt plus 4pt minus 4pt
+\newgluespec \medskipamount \medskipamount = 6pt plus 2pt minus 2pt
+\newgluespec \smallskipamount \smallskipamount = 3pt plus 1pt minus 1pt
\baselineskip = 12pt
\lineskip = 1pt
@@ -1156,8 +1182,8 @@
%D Again a few kind-of-extensions the core. These come from plain \TEX\ but are
%D probably not used in \CONTEXT.
-\newskip \hideskip \hideskip = -1000pt plus 1fill % obsolete
-\newskip \centering \centering = 0pt plus 1000pt minus 1000pt % obsolete
+\newgluespec \hideskip \hideskip = -1000pt plus 1fill % obsolete
+\newgluespec \centering \centering = 0pt plus 1000pt minus 1000pt % obsolete
% \permanent\def\hidewidth % for alignment entries that can stick out
% {\hskip\hideskip}
@@ -1176,7 +1202,7 @@
\mscount#1\relax
\loop
\ifnum\mscount>\plusone
- \spanomit \advance\mscount\minusone
+ \spanomit \advanceby\mscount\minusone
\repeat}
\let\nopdfcompression \relax % later
@@ -1233,7 +1259,7 @@
{\ifcsname ??#1\endcsname
\immediate\write\statuswrite{fatal error: duplicate system namespace '#1'}%
\else
- \global\advance\c_syst_helpers_n_of_namespaces\plusone
+ \global\advanceby\c_syst_helpers_n_of_namespaces\plusone
\immutable\cdefcsname ??#1\endcsname{\v_interfaces_prefix_template_system}%
\fi}
@@ -1337,6 +1363,8 @@
%D
%D There is a little extra overhead in the overload protection but not that much.
+% integerdef is local
+
\permanent\countdef\c_syst_local_count = 231 \c_syst_local_count = \c_syst_max_allocated_count
\permanent\countdef\c_syst_local_dimen = 232 \c_syst_local_dimen = \c_syst_max_allocated_dimen
\permanent\countdef\c_syst_local_skip = 233 \c_syst_local_skip = \c_syst_max_allocated_skip
@@ -1359,7 +1387,7 @@
\permanent\protected\def\setnewlocalcount#1%
{\ifnum\c_syst_local_count>\c_syst_max_allocated_count
- \advance\c_syst_local_count\minusone
+ \advanceby\c_syst_local_count\minusone
\overloaded\frozen\countdef#1\c_syst_local_count
\else
\syst_local_overflow_count#1%
@@ -1368,7 +1396,7 @@
\permanent\protected\def\setnewlocaldimen#1%
{\ifnum\c_syst_local_dimen>\c_syst_max_allocated_dimen
- \advance\c_syst_local_dimen\minusone\dimendef#1\c_syst_local_dimen
+ \advanceby\c_syst_local_dimen\minusone\dimendef#1\c_syst_local_dimen
\else
\syst_local_overflow_dimen#1%
\fi
@@ -1376,7 +1404,7 @@
\permanent\protected\def\setnewlocalskip#1%
{\ifnum\c_syst_local_skip>\c_syst_max_allocated_skip
- \advance\c_syst_local_skip\minusone
+ \advanceby\c_syst_local_skip\minusone
\overloaded\frozen\skipdef#1\c_syst_local_skip
\else
\syst_local_overflow_skip#1%
@@ -1385,7 +1413,7 @@
\permanent\protected\def\setnewlocalmuskip#1%
{\ifnum\c_syst_local_muskip>\c_syst_max_allocated_muskip
- \advance\c_syst_local_muskip\minusone
+ \advanceby\c_syst_local_muskip\minusone
\overloaded\frozen\muskipdef#1\c_syst_local_muskip
\else
\syst_local_overflow_muskip#1%
@@ -1394,7 +1422,7 @@
\permanent\protected\def\setnewlocaltoks#1%
{\ifnum\c_syst_local_toks>\c_syst_max_allocated_toks
- \advance\c_syst_local_toks\minusone
+ \advanceby\c_syst_local_toks\minusone
\overloaded\frozen\toksdef#1\c_syst_local_toks
\else
\syst_local_overflow_toks#1%
@@ -1403,7 +1431,7 @@
\permanent\protected\def\setnewlocalbox#1%
{\ifnum\c_syst_local_box>\c_syst_max_allocated_box
- \advance\c_syst_local_box\minusone
+ \advanceby\c_syst_local_box\minusone
\overloaded\frozen\integerdef#1\c_syst_local_box
\else
\syst_local_overflow_box#1%
@@ -1412,7 +1440,7 @@
\permanent\protected\def\newlocalread#1% so no set
{\ifnum\c_syst_local_read>\c_syst_max_allocated_read
- \advance\c_syst_local_read\minusone
+ \advanceby\c_syst_local_read\minusone
\overloaded\frozen\integerdef#1\c_syst_local_read
\else
\syst_local_overflow_read#1%
@@ -1420,7 +1448,7 @@
\permanent\protected\def\newlocalwrite#1% so no set
{\ifnum\c_syst_local_write>\c_syst_max_allocated_write
- \advance\c_syst_local_write\minusone
+ \advanceby\c_syst_local_write\minusone
\overloaded\frozen\integerdef#1\c_syst_local_write
\else
\syst_local_overflow_write#1%
diff --git a/tex/context/base/mkxl/tabl-frm.mkxl b/tex/context/base/mkxl/tabl-frm.mkxl
index d3112d9c2..7f9189c61 100644
--- a/tex/context/base/mkxl/tabl-frm.mkxl
+++ b/tex/context/base/mkxl/tabl-frm.mkxl
@@ -21,11 +21,11 @@
\installcorenamespace{framedtablerow}
\installcorenamespace{framedtablecolumn}
-\newcount\c_tabl_framed_c
-\newcount\c_tabl_framed_r
-\newdimen\d_tabl_framed_h
-\newdimen\d_tabl_framed_d
-\newdimen\b_tabl_framed
+\newinteger \c_tabl_framed_c
+\newinteger \c_tabl_framed_r
+\newdimension\d_tabl_framed_h
+\newdimension\d_tabl_framed_d
+\newdimension\b_tabl_framed
\initializeboxstack\??framedtable
@@ -135,7 +135,7 @@
\ignorespaces}
% \permanent\protected\def\startframedrow
-% {\advance\c_tabl_framed_r\plusone
+% {\advanceby\c_tabl_framed_r\plusone
% \c_tabl_framed_c\zerocount
% \d_tabl_framed_h\zeropoint
% \bgroup
@@ -160,12 +160,12 @@
{\vpack to \d_tabl_framed_h{\flushbox\??framedtable{\number\fastloopindex}\vfill}%
\ifzeropt\d_tabl_framed_d\else\kern\d_tabl_framed_d\fi}
-\newcount\c_tabl_framed_pass
+\newinteger\c_tabl_framed_pass
\permanent\let\stopframedrow\relax
\permanent\protected\def\startframedrow#1\stopframedrow
- {\advance\c_tabl_framed_r\plusone
+ {\advanceby\c_tabl_framed_r\plusone
\startframedrow_one#1\stopframedrow_one
\startframedrow_two#1\stopframedrow_two}
@@ -205,7 +205,7 @@
\ifzeropt\d_tabl_framed_d\else\kern\d_tabl_framed_d\fi}
\permanent\protected\def\startframedcell
- {\advance\c_tabl_framed_c\plusone
+ {\advanceby\c_tabl_framed_c\plusone
\setbox\b_tabl_framed\hpack\bgroup
%\bgroup
\edef\currentframed{\number\c_tabl_framed_c}%
diff --git a/tex/context/base/mkxl/tabl-ltb.mkxl b/tex/context/base/mkxl/tabl-ltb.mkxl
index 54bce7d94..7fcdba6f2 100644
--- a/tex/context/base/mkxl/tabl-ltb.mkxl
+++ b/tex/context/base/mkxl/tabl-ltb.mkxl
@@ -70,23 +70,23 @@
\newconditional \c_tabl_lines_preroll
\newconditional \c_tabl_lines_in_table
-\newdimen \d_tabl_lines_width
-\newdimen \d_tabl_lines_height
-%newdimen \d_tabl_lines_depth
+\newdimension \d_tabl_lines_width
+\newdimension \d_tabl_lines_height
+%newdimension \d_tabl_lines_depth
\newbox \b_tabl_lines_cell
-\newcount \c_tabl_lines_n_of_columns
-\newcount \c_tabl_lines_n_of_rows
-\newcount \c_tabl_lines_n_of_lines
-\newcount \c_tabl_lines_n_of_parts
-\newcount \c_tabl_lines_part \c_tabl_lines_part\plusone
-\newcount \c_tabl_lines_step \c_tabl_lines_step\plusone
-\newcount \c_tabl_lines_line
-\newcount \c_tabl_lines_row
-\newcount \c_tabl_lines_rows
-\newcount \c_tabl_lines_column
-\newcount \c_tabl_lines_subcol
+\newinteger \c_tabl_lines_n_of_columns
+\newinteger \c_tabl_lines_n_of_rows
+\newinteger \c_tabl_lines_n_of_lines
+\newinteger \c_tabl_lines_n_of_parts
+\newinteger \c_tabl_lines_part \c_tabl_lines_part\plusone
+\newinteger \c_tabl_lines_step \c_tabl_lines_step\plusone
+\newinteger \c_tabl_lines_line
+\newinteger \c_tabl_lines_row
+\newinteger \c_tabl_lines_rows
+\newinteger \c_tabl_lines_column
+\newinteger \c_tabl_lines_subcol
\newconstant \c_tabl_lines_hmode
\newconstant \c_tabl_lines_page
@@ -182,9 +182,9 @@
\fi}
\def\tabl_lines_step_cell
- {\advance\scratchdimen\linetablecparameter\c!width
- \global\advance \c_tabl_lines_column\plusone
- \advance\scratchskip \linetablecparameter\c!distance}
+ {\advanceby\scratchdimen\linetablecparameter\c!width
+ \global\advanceby \c_tabl_lines_column\plusone
+ \advanceby\scratchskip \linetablecparameter\c!distance}
\permanent\tolerant\protected\def\startlinetablecell[#1]%
{\global\setbox\b_tabl_lines_cell\hbox\bgroup
@@ -227,8 +227,8 @@
% 1 = width, fixed height
% 2 = no width, auto hsize
\ifnum\c_tabl_lines_mode<\plustwo
- \advance\scratchdimen-\linetablecparameter\c!leftoffset
- \advance\scratchdimen-\linetablecparameter\c!rightoffset
+ \advanceby\scratchdimen-\linetablecparameter\c!leftoffset
+ \advanceby\scratchdimen-\linetablecparameter\c!rightoffset
\fi
\ifcase\c_tabl_lines_mode
\dosetraggedcommand{\linetablecparameter\c!align}%
@@ -337,7 +337,7 @@
\fi}
\def\tabl_lines_flush_parts
- {\global\advance\c_tabl_lines_line\plusone
+ {\global\advanceby\c_tabl_lines_line\plusone
\ifnum\c_tabl_lines_line<\c_tabl_lines_n_of_lines
% keep collecting
\else
@@ -401,9 +401,9 @@
\fi}
\def\tabl_lines_check_part
- {\global\advance\d_tabl_lines_width\wd\b_tabl_lines_cell
- \global\advance\c_tabl_lines_column\c_tabl_lines_step
- \global\advance\c_tabl_lines_subcol\c_tabl_lines_step
+ {\global\advanceby\d_tabl_lines_width\wd\b_tabl_lines_cell
+ \global\advanceby\c_tabl_lines_column\c_tabl_lines_step
+ \global\advanceby\c_tabl_lines_subcol\c_tabl_lines_step
\relax
%\message{\the\c_tabl_lines_column,\the\c_tabl_lines_subcol}\wait
% from now on the column counter is already incremented
@@ -436,7 +436,7 @@
\else
\global\c_tabl_lines_page \plusone
\fi
- \global\advance\c_tabl_lines_part\plusone
+ \global\advanceby\c_tabl_lines_part\plusone
\global\d_tabl_lines_width\wd\b_tabl_lines_current\zerocount
\tabl_lines_start_part
\fi
@@ -455,7 +455,7 @@
\orelse\ifdim\d_tabl_lines_width>\hsize
\donetrue
\else
- \global\advance\d_tabl_lines_width\scratchskip
+ \global\advanceby\d_tabl_lines_width\scratchskip
\ifdim\d_tabl_lines_width>\hsize % ?
\donetrue
\fi
@@ -468,7 +468,7 @@
\else
\global\c_tabl_lines_page \plusone
\fi
- \global\advance\c_tabl_lines_part\plusone
+ \global\advanceby\c_tabl_lines_part\plusone
\ifnum\c_tabl_lines_part>\c_tabl_lines_n_of_parts
\global\c_tabl_lines_n_of_parts\c_tabl_lines_part
\tabl_lines_initialize_box\c_tabl_lines_part
@@ -480,7 +480,7 @@
\ifcase\c_tabl_lines_page\donetrue\or\donetrue\or\donefalse\fi
\ifdone
% insert repeater
- \global\advance\d_tabl_lines_width\wd\b_tabl_lines_current\zerocount
+ \global\advanceby\d_tabl_lines_width\wd\b_tabl_lines_current\zerocount
\ifconditional\c_tabl_lines_preroll\kern\wd\else\unhcopy\fi\b_tabl_lines_current\zerocount
\fi
\fi
@@ -521,8 +521,8 @@
\global\c_tabl_lines_n_of_parts\zerocount
\scratchcounter\zerocount
\def\docommand##1%
- {\global\advance\c_tabl_lines_n_of_parts\plusone
- \advance\scratchcounter##1%
+ {\global\advanceby\c_tabl_lines_n_of_parts\plusone
+ \advanceby\scratchcounter##1%
\xdefcsname\??linetablepart\number\c_tabl_lines_n_of_parts\endcsname{\the\scratchcounter}}%
\processcommacommand[\linetableparameter\c!n]\docommand
\tabl_lines_initialize_boxes\c_tabl_lines_n_of_parts
@@ -575,8 +575,8 @@
\permanent\tolerant\protected\def\tabl_lines_BR[#1]% #1 not yet implemented
{\ifnum\c_tabl_lines_head_state=1\else
- \global\advance\c_tabl_lines_row\plusone
- \global\advance\c_tabl_lines_rows\plusone
+ \global\advanceby\c_tabl_lines_row\plusone
+ \global\advanceby\c_tabl_lines_rows\plusone
\fi
\global\c_tabl_lines_column\plusone
\global\c_tabl_lines_subcol\plusone
@@ -610,7 +610,7 @@
% no \box\b_tabl_lines_cell, i.e. dummy columnn, last \NC \NR
\tabl_lines_stop_part
\tabl_lines_save_part
- \advance\c_tabl_lines_column \minusone
+ \advanceby\c_tabl_lines_column \minusone
\ifnum\c_tabl_lines_column>\c_tabl_lines_n_of_columns
\global\c_tabl_lines_n_of_columns\c_tabl_lines_column
\fi
diff --git a/tex/context/base/mkxl/tabl-mis.mkxl b/tex/context/base/mkxl/tabl-mis.mkxl
index 7b6f0ffac..e65c97e0d 100644
--- a/tex/context/base/mkxl/tabl-mis.mkxl
+++ b/tex/context/base/mkxl/tabl-mis.mkxl
@@ -153,10 +153,10 @@
\typo_paragraphs_setup_saved[\currentparagraphs:1][\c!distance=\zeropoint]%
\to \everydefineparagraphs
-\newcount\c_typo_paragraphs_n
-\newcount\c_typo_paragraphs_max
-\newdimen\d_typo_paragraphs_width
-\newdimen\d_typo_paragraphs_auto
+\newinteger \c_typo_paragraphs_n
+\newinteger \c_typo_paragraphs_max
+\newdimension\d_typo_paragraphs_width
+\newdimension\d_typo_paragraphs_auto
\let\typo_paragraphs_start_cell\relax
\let\typo_paragraphs_stop_cell \relax
@@ -171,22 +171,22 @@
\else
\d_typo_paragraphs_width\p_width\relax
\fi
- \advance\d_typo_paragraphs_width-2\dimexpr\paragraphsparameter\c!offset\relax
+ \advanceby\d_typo_paragraphs_width-2\dimexpr\paragraphsparameter\c!offset\relax
\c_typo_paragraphs_max\paragraphsparameter\c!n\relax
\d_typo_paragraphs_auto\d_typo_paragraphs_width\relax
\scratchcounter\zerocount
\dorecurse\c_typo_paragraphs_max
{\edef\p_width{\namedparagraphsparameter{\currentparagraphs:\recurselevel}\c!width}%
\ifempty\p_width
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\else
- \advance\d_typo_paragraphs_auto-\p_width\relax
+ \advanceby\d_typo_paragraphs_auto-\p_width\relax
\fi
\ifnum\recurselevel>\plusone
- \advance\d_typo_paragraphs_auto-\namedparagraphsparameter{\currentparagraphs:\recurselevel}\c!distance\relax
+ \advanceby\d_typo_paragraphs_auto-\namedparagraphsparameter{\currentparagraphs:\recurselevel}\c!distance\relax
\fi}%
\ifnum\scratchcounter>\zerocount
- \divide\d_typo_paragraphs_auto\scratchcounter
+ \divideby\d_typo_paragraphs_auto\scratchcounter
\else
\d_typo_paragraphs_auto\zeropoint
\fi
@@ -200,7 +200,7 @@
\setbox\scratchbox\hpack
\bgroup % (2)
\forgetall
- \advance\hsize-2\scratchoffset
+ \advanceby\hsize-2\scratchoffset
\let\typo_paragraphs_start_cell\typo_paragraphs_start_cell_indeed
\let\typo_paragraphs_stop_cell \typo_paragraphs_stop_cell_indeed
\typo_paragraphs_start_cell_indeed}
@@ -223,7 +223,7 @@
\def\typo_paragraphs_start_cell_indeed
{\removeunwantedspaces
- \advance\c_typo_paragraphs_n\plusone
+ \advanceby\c_typo_paragraphs_n\plusone
\ifnum\c_typo_paragraphs_n>\c_typo_paragraphs_max
\expandafter\typo_paragraphs_start_cell_nop
\else
diff --git a/tex/context/base/mkxl/tabl-ntb.mkxl b/tex/context/base/mkxl/tabl-ntb.mkxl
index 59777fb9b..147cb30f5 100644
--- a/tex/context/base/mkxl/tabl-ntb.mkxl
+++ b/tex/context/base/mkxl/tabl-ntb.mkxl
@@ -139,64 +139,64 @@
% \fi
% \fi}
-\newcount\c_tabl_ntb_row
-\newcount\c_tabl_ntb_col
-\newcount\c_tabl_ntb_spn
+\newinteger \c_tabl_ntb_row
+\newinteger \c_tabl_ntb_col
+\newinteger \c_tabl_ntb_spn
-\newcount\c_tabl_ntb_nx
-\newcount\c_tabl_ntb_ny
+\newinteger \c_tabl_ntb_nx
+\newinteger \c_tabl_ntb_ny
\setnewconstant\c_tabl_ntb_cell \plusone
\setnewconstant\c_tabl_ntb_none \plustwo
-\newcount\c_tabl_ntb_current_row
-\newcount\c_tabl_ntb_current_col
-\newcount\c_tabl_ntb_current_row_one
-\newcount\c_tabl_ntb_current_col_one
-\newcount\c_tabl_ntb_current_row_two
-\newcount\c_tabl_ntb_current_col_two
-\newcount\c_tabl_ntb_current_row_three
-\newcount\c_tabl_ntb_current_col_three
-\newcount\c_tabl_ntb_current_row_four
-\newcount\c_tabl_ntb_current_col_four
+\newinteger \c_tabl_ntb_current_row
+\newinteger \c_tabl_ntb_current_col
+\newinteger \c_tabl_ntb_current_row_one
+\newinteger \c_tabl_ntb_current_col_one
+\newinteger \c_tabl_ntb_current_row_two
+\newinteger \c_tabl_ntb_current_col_two
+\newinteger \c_tabl_ntb_current_row_three
+\newinteger \c_tabl_ntb_current_col_three
+\newinteger \c_tabl_ntb_current_row_four
+\newinteger \c_tabl_ntb_current_col_four
-\newcount\c_tabl_ntb_running_col
-\newcount\c_tabl_ntb_maximum_row
-\newcount\c_tabl_ntb_maximum_col
-\newcount\c_tabl_ntb_maximum_row_span
-\newcount\c_tabl_ntb_maximum_col_span
+\newinteger \c_tabl_ntb_running_col
+\newinteger \c_tabl_ntb_maximum_row
+\newinteger \c_tabl_ntb_maximum_col
+\newinteger \c_tabl_ntb_maximum_row_span
+\newinteger \c_tabl_ntb_maximum_col_span
-\newcount\c_tabl_ntb_encountered_col
-\newcount\c_tabl_ntb_encountered_max
+\newinteger \c_tabl_ntb_encountered_col
+\newinteger \c_tabl_ntb_encountered_max
-\newtoks\t_tabl_ntb
-\newtoks\t_tabl_ntb_row
+\newtoks \t_tabl_ntb
+\newtoks \t_tabl_ntb_row
-\newconstant\c_tabl_tbl_pass
+\newconstant \c_tabl_tbl_pass
-\newtoks\t_tabl_ntb_head
-\newtoks\t_tabl_ntb_next
-\newtoks\t_tabl_ntb_body
-\newtoks\t_tabl_ntb_foot
+\newtoks \t_tabl_ntb_head
+\newtoks \t_tabl_ntb_next
+\newtoks \t_tabl_ntb_body
+\newtoks \t_tabl_ntb_foot
-\newcount\c_tabl_ntb_n_of_head_lines
-\newcount\c_tabl_ntb_n_of_next_lines
-\newcount\c_tabl_ntb_n_of_hdnx_lines
+\newinteger \c_tabl_ntb_n_of_head_lines
+\newinteger \c_tabl_ntb_n_of_next_lines
+\newinteger \c_tabl_ntb_n_of_hdnx_lines
-\newdimen\d_tabl_ntb_height
-\newdimen\d_tabl_ntb_width
+\newdimension \d_tabl_ntb_height
+\newdimension \d_tabl_ntb_width
-\newdimen\d_tabl_ntb_leftmargindistance
-\newdimen\d_tabl_ntb_rightmargindistance
-\newdimen\d_tabl_ntb_columndistance
-\newdimen\d_tabl_ntb_maxwidth
+\newdimension \d_tabl_ntb_leftmargindistance
+\newdimension \d_tabl_ntb_rightmargindistance
+\newdimension \d_tabl_ntb_columndistance
+\newdimension \d_tabl_ntb_maxwidth
-\newtoks\everyTABLEpass % public
+\newtoks \everyTABLEpass % public
-\newcount\tablecellrows % public (needs checking)
-\newcount\tablecellcolumns % public (needs checking)
+\newinteger \tablecellrows % public (needs checking)
+\newinteger \tablecellcolumns % public (needs checking)
-\newbox\b_tabl_ntb_final
+\newbox \b_tabl_ntb_final
%D For tagging and export:
@@ -256,7 +256,7 @@
%D We have already prepared the previous macros for nesting, so we only have to pop
%D in the right ones:
-\newcount\c_tabl_level
+\newinteger\c_tabl_level
\installglobalmacrostack\m_tabl_ntb_saved_row
\installglobalmacrostack\m_tabl_ntb_saved_col
@@ -280,11 +280,11 @@
\fi}
\protected\def\tabl_ntb_next_level
- {\advance\c_tabl_level\plusone
+ {\advanceby\c_tabl_level\plusone
\edef\m_tabl_tbl_level{\the\c_tabl_level}}
\protected\def\tabl_ntb_prev_level
- {\advance\c_tabl_level\minusone
+ {\advanceby\c_tabl_level\minusone
\edef\m_tabl_tbl_level{\the\c_tabl_level}}
\tabl_ntb_next_level % go to level 1
@@ -736,7 +736,7 @@
\tolerant\protected\def\tabl_ntb_tr[#1]%
{\c_tabl_ntb_running_col\zerocount
\c_tabl_ntb_encountered_col\zerocount
- \advance\c_tabl_ntb_maximum_row\plusone
+ \advanceby\c_tabl_ntb_maximum_row\plusone
\ifparameter#1\or
\expandafter\tabl_ntb_tr_yes
\else
@@ -750,7 +750,7 @@
\def\m_tabl_ntb_default_nc{\naturaltableparameter\c!nc}
\tolerant\protected\def\tabl_ntb_td[#1]%
- {\advance\c_tabl_ntb_encountered_col\plusone
+ {\advanceby\c_tabl_ntb_encountered_col\plusone
\ifparameter#1\or
\expandafter\tabl_ntb_td_yes
\else
@@ -774,7 +774,7 @@
\edef\m_tabl_ntb_m{\naturaltableparameter\c!m}%
%
\ifempty\m_tabl_ntb_n
- \global\advance\c_tabl_ntb_spn\c_tabl_ntb_nx\relax
+ \global\advanceby\c_tabl_ntb_spn\c_tabl_ntb_nx\relax
\orelse\ifnum\m_tabl_ntb_n=\c_tabl_ntb_running_col
\else
\tabl_ntb_td_pass_n{#1}%
@@ -785,7 +785,7 @@
\tabl_ntb_td_pass_m{#1}%
\fi
\localcontrolledloop\plusone\maxcard\plusone % skip over columns that result from earlier span
- {\advance\c_tabl_ntb_running_col\plusone
+ {\advanceby\c_tabl_ntb_running_col\plusone
\ifcsname\tabl_ntb_tag_pattern\c_tabl_ntb_maximum_row\c_tabl_ntb_running_col\endcsname \else
\quitloop
\fi}%
@@ -818,9 +818,9 @@
\fi}
\def\tabl_ntb_td_nop[#1]#2\eTD
- {\global\advance\c_tabl_ntb_spn\plusone\relax
+ {\global\advanceby\c_tabl_ntb_spn\plusone\relax
\localcontrolledloop\plusone\maxcard\plusone
- {\advance\c_tabl_ntb_running_col\plusone
+ {\advanceby\c_tabl_ntb_running_col\plusone
\ifcsname\tabl_ntb_tag_pattern\c_tabl_ntb_maximum_row\c_tabl_ntb_running_col\endcsname \else
\quitloop
\fi}%
@@ -870,7 +870,7 @@
\c_tabl_ntb_current_col\c_tabl_ntb_running_col
\localcontrolledloop\plusone\c_tabl_ntb_ny\plusone{\tabl_ntb_cell_preset_rows}%
% check max column
- \advance\c_tabl_ntb_current_col\minusone
+ \advanceby\c_tabl_ntb_current_col\minusone
\ifnum\c_tabl_ntb_current_col>\c_tabl_ntb_maximum_col\relax
\c_tabl_ntb_maximum_col\c_tabl_ntb_current_col
\fi}
@@ -882,11 +882,11 @@
\c_tabl_ntb_maximum_row_span\c_tabl_ntb_nx
\fi
\localcontrolledloop\plusone\c_tabl_ntb_nx\plusone{\tabl_ntb_cell_preset_cells}%
- \advance\c_tabl_ntb_current_row\plusone}
+ \advanceby\c_tabl_ntb_current_row\plusone}
\def\tabl_ntb_cell_preset_cells
{\tabl_ntb_let_tag\c_tabl_ntb_current_row\c_tabl_ntb_current_col\c_tabl_ntb_none
- \advance\c_tabl_ntb_current_col\plusone}
+ \advanceby\c_tabl_ntb_current_col\plusone}
%D The usage of n and m:
%D
@@ -1171,7 +1171,7 @@
{\ifcsname\tabl_ntb_tag_pattern\c_tabl_ntb_current_row_one\c_tabl_ntb_current_col_one\endcsname
\quitloop
\else
- \advance\c_tabl_ntb_current_col_one\plusone
+ \advanceby\c_tabl_ntb_current_col_one\plusone
\ifnum\c_tabl_ntb_current_col_one>\c_tabl_ntb_maximum_col\relax
\quitloop
\fi
@@ -1181,7 +1181,7 @@
\else
\c_tabl_ntb_current_row_two\c_tabl_ntb_current_row_one
\c_tabl_ntb_current_col_two\c_tabl_ntb_current_col_one
- \advance\c_tabl_ntb_current_row_one\plusone
+ \advanceby\c_tabl_ntb_current_row_one\plusone
\ifnum\c_tabl_ntb_current_row_one>\c_tabl_ntb_maximum_row
\quitloop
\fi
@@ -1196,8 +1196,8 @@
\tabl_ntb_set_col\c_tabl_ntb_current_row_one\c_tabl_ntb_current_col_one\c_tabl_ntb_current_col_two
\localcontrolledloop\plusone\c_tabl_ntb_current_col_two\plusone
{\tabl_ntb_let_tag\c_tabl_ntb_current_row_one\c_tabl_ntb_current_col_one\c_tabl_ntb_none
- \advance\c_tabl_ntb_current_col_one\plusone}%
- \advance\c_tabl_ntb_current_row_one\plusone}%
+ \advanceby\c_tabl_ntb_current_col_one\plusone}%
+ \advanceby\c_tabl_ntb_current_row_one\plusone}%
\tabl_ntb_let_tag\c_tabl_ntb_current_row\c_tabl_ntb_current_col\c_tabl_ntb_cell
\tabl_ntb_set_col\c_tabl_ntb_current_row\c_tabl_ntb_current_col\c_tabl_ntb_current_col_two
\tabl_ntb_set_row\c_tabl_ntb_current_row\c_tabl_ntb_current_col\c_tabl_ntb_current_row_two%
@@ -1235,7 +1235,7 @@
\mutable\let\startTBLprocessing\relax % public
\mutable\let\stopTBLprocessing \relax % public
-\newcount\c_tabl_prelocated_rows % \prelocateTBLrows{1000} may speed up large tables
+\newinteger\c_tabl_prelocated_rows % \prelocateTBLrows{1000} may speed up large tables
% \def\tabl_ntb_row_start{\t_tabl_ntb_row\emptytoks}
% \def\tabl_ntb_row_stop {\normalexpanded{\t_tabl_ntb{\the\t_tabl_ntb\noexpand\tabl_ntb_row_align_start\the\t_tabl_ntb_row\tabl_ntb_row_align_stop}}}
@@ -1368,7 +1368,7 @@
\fi}
\protected\def\tabl_ntb_row_align_start
- {\global\advance\c_tabl_ntb_row\plusone
+ {\global\advanceby\c_tabl_ntb_row\plusone
\global\c_tabl_ntb_col\plusone
\global\c_tabl_ntb_spn\zerocount
\tabl_ntb_row_align_start_inject
@@ -1451,7 +1451,7 @@
\global\c_tabl_ntb_spn\zerocount
\global\c_tabl_ntb_col\zerocount
\global\c_tabl_ntb_row\zerocount
- \global\advance\c_tabl_ntb_row\minusone
+ \global\advanceby\c_tabl_ntb_row\minusone
\dostarttaggedchained\t!table\empty\??naturaltable
%\registerparoptions % (*) triggers max hsize
\the\t_tabl_ntb
@@ -1461,13 +1461,13 @@
{\hskip\tabl_ntb_get_dis\c_tabl_ntb_col
\localcontrolledloop\plusone#1\plusone
{\hskip\tabl_ntb_get_wid\c_tabl_ntb_col\relax
- \global\advance\c_tabl_ntb_col\plusone}}
+ \global\advanceby\c_tabl_ntb_col\plusone}}
\protected\def\tabl_ntb_skip#1%
- {\global\advance\c_tabl_ntb_col#1\relax}
+ {\global\advanceby\c_tabl_ntb_col#1\relax}
\protected\def\tabl_ntb_plus
- {\global\advance\c_tabl_ntb_col\plusone
+ {\global\advanceby\c_tabl_ntb_col\plusone
\kern\d_tabl_ntb_columndistance}
\defcsname\??naturaltablecell\the\c_tabl_ntb_none\endcsname#1#2%
@@ -1507,20 +1507,20 @@
\scratchcounter\c_tabl_ntb_col
\scratchcounterone\tabl_ntb_get_col{#1}{#2}\relax
\ifcase\scratchcounterone\or
- \advance\d_tabl_ntb_width\dimexpr % no need for dimexpr
+ \advanceby\d_tabl_ntb_width\dimexpr % no need for dimexpr
\tabl_ntb_get_wid\scratchcounter
\relax
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\else
\localcontrolledloop\plusone\scratchcounterone\plusone
- {\advance\d_tabl_ntb_width\dimexpr
+ {\advanceby\d_tabl_ntb_width\dimexpr
\tabl_ntb_get_wid\scratchcounter
\ifnum\currentloopiterator<\scratchcounterone
+\d_tabl_ntb_columndistance
+\tabl_ntb_get_dis\scratchcounter
\fi
\relax
- \advance\scratchcounter\plusone}%
+ \advanceby\scratchcounter\plusone}%
\fi
\setbox\scratchbox\hbox{\tabl_ntb_get_txt{#1}{#2}}%
\tabl_ntb_set_ht{#1}{#2}\ht\scratchbox
@@ -1543,8 +1543,8 @@
\else
\scratchcounter#1\relax
\localcontrolledloop\plusone\scratchcountertwo\plusone
- {\advance\d_tabl_ntb_height\tabl_ntb_get_hei\scratchcounter
- \advance\scratchcounter\plusone}%
+ {\advanceby\d_tabl_ntb_height\tabl_ntb_get_hei\scratchcounter
+ \advanceby\scratchcounter\plusone}%
\ifdim\d_tabl_ntb_height<\scratchheight\relax
\d_tabl_ntb_height\scratchheight
\fi
@@ -1553,20 +1553,20 @@
\d_tabl_ntb_width\zeropoint
\scratchcounter\c_tabl_ntb_col
\ifcase\scratchcounterone\or
- \advance\d_tabl_ntb_width\dimexpr
+ \advanceby\d_tabl_ntb_width\dimexpr
\tabl_ntb_get_wid\scratchcounter
\relax
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\else
\localcontrolledloop\plusone\scratchcounterone\plusone
- {\advance\d_tabl_ntb_width\dimexpr
+ {\advanceby\d_tabl_ntb_width\dimexpr
\tabl_ntb_get_wid\scratchcounter
\ifnum\currentloopiterator<\scratchcounterone
+\d_tabl_ntb_columndistance
+\tabl_ntb_get_dis\scratchcounter
\fi
\relax
- \advance\scratchcounter\plusone}%
+ \advanceby\scratchcounter\plusone}%
\fi
% cell
\setbox\scratchbox\hbox attr \taggedattribute \c_attr_tagged \bgroup
@@ -1615,8 +1615,8 @@
% enabled per 2018-02-22
\def\tabl_ntb_table_get_max_width_step
- {\advance\scratchdimen\tabl_ntb_get_wid\fastloopindex
- \advance\scratchdimen\tabl_ntb_get_dis\fastloopindex}
+ {\advanceby\scratchdimen\tabl_ntb_get_wid\fastloopindex
+ \advanceby\scratchdimen\tabl_ntb_get_dis\fastloopindex}
\def\tabl_ntb_table_get_max_width
{\scratchdimen\zeropoint
@@ -1625,7 +1625,7 @@
\scratchdimen\wd\scratchbox\relax
\fi}
-\newdimen\d_tabl_ntb_saved_hsize
+\newdimension\d_tabl_ntb_saved_hsize
\let\tabl_ntb_pass\relax
@@ -1725,18 +1725,18 @@
+\d_tabl_ntb_columndistance
\relax
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
- {\advance\scratchdimenfour\dimexpr
+ {\advanceby\scratchdimenfour\dimexpr
\tabl_ntb_get_wid\currentloopiterator
\relax
- \advance\scratchdimenfive\dimexpr
+ \advanceby\scratchdimenfive\dimexpr
-\tabl_ntb_get_dis\currentloopiterator
-\d_tabl_ntb_columndistance
\relax}%
\relax
% distribute width (stretch)
\ifdim\scratchdimenfour<\scratchdimenfive
- \advance\scratchdimenfour-\scratchdimenfive
- \divide\scratchdimenfour\c_tabl_ntb_maximum_col
+ \advanceby\scratchdimenfour-\scratchdimenfive
+ \divideby\scratchdimenfour\c_tabl_ntb_maximum_col
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
{\scratchdimen\dimexpr\tabl_ntb_get_wid\currentloopiterator-\scratchdimenfour\relax
\tabl_ntb_set_wid\currentloopiterator\scratchdimen}%
@@ -1837,27 +1837,27 @@
\relax
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
{\scratchdimen\tabl_ntb_get_aut\currentloopiterator
- \advance\scratchdimenone\dimexpr
+ \advanceby\scratchdimenone\dimexpr
-\tabl_ntb_get_dis\currentloopiterator
-\d_tabl_ntb_columndistance
\relax
\ifdim\scratchdimen>\zeropoint\relax
- \advance\scratchdimenone -\scratchdimen
+ \advanceby\scratchdimenone -\scratchdimen
\else
\scratchdimen\tabl_ntb_get_wid\currentloopiterator\relax
\ifdim\scratchdimen>\d_tabl_ntb_maxwidth\relax
\ifcase#1\else\tabl_ntb_let_wid\currentloopiterator\zeropoint\fi
- \advance\scratchcounterone \plusone
+ \advanceby\scratchcounterone \plusone
\orelse\ifdim\scratchdimen>\zeropoint\relax
- \advance\scratchdimenone -\scratchdimen
+ \advanceby\scratchdimenone -\scratchdimen
\orelse\ifnum\c_tabl_ntb_encountered_max=\c_tabl_ntb_maximum_col % *nx* bah
% eigenlijk moet dit alleen als de kolom wordt overspannen door een
% vorige, maw extra dubbele loop en status var
- \advance\scratchcounterone \plusone % setting maxwidth to a large value also works
+ \advanceby\scratchcounterone \plusone % setting maxwidth to a large value also works
\fi
\fi}%
\ifconditional\c_tabl_ntb_trace_widths\tabl_ntb_show_widths M#1\fi
- \ifcase\scratchcounterone \else \divide\scratchdimenone \scratchcounterone \fi
+ \ifcase\scratchcounterone \else \divideby\scratchdimenone \scratchcounterone \fi
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
{\scratchdimen\tabl_ntb_get_wid\currentloopiterator
\ifcase#1\relax
@@ -1871,62 +1871,59 @@
\fi}%
\ifconditional\c_tabl_ntb_trace_widths\tabl_ntb_show_widths E#1\fi}
-% todo: use scratchcounters, not !! ones
-
\def\tabl_ntb_check_heights_one_indeed
{\scratchcountertwo\tabl_ntb_get_row\c_tabl_ntb_current_row_three\c_tabl_ntb_current_col_three\relax
% check row span
\ifnum\scratchcountertwo>\plusone
% current height in row
- \dimen0=\tabl_ntb_get_ht\c_tabl_ntb_current_row_three\c_tabl_ntb_current_col_three
+ \scratchdimenone\tabl_ntb_get_ht\c_tabl_ntb_current_row_three\c_tabl_ntb_current_col_three
% find nearest height in row
- \dimen2=\zeropoint
+ \scratchdimentwo\zeropoint
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
- {\ifnum\currentloopiterator=\c_tabl_ntb_current_col_three\else
- \ifcsname\tabl_ntb_row_pattern\c_tabl_ntb_current_row_three\the\currentloopiterator\endcsname
- \scratchcounterthree\tabl_ntb_get_row\c_tabl_ntb_current_row_three\currentloopiterator\relax
- \ifnum\scratchcounterthree=\plusone
- \dimen4=\tabl_ntb_get_ht\c_tabl_ntb_current_row_three\currentloopiterator\relax
- \ifdim\dimen2<\dimen4
- \dimen2=\dimen4
- \fi
+ {\ifnum\currentloopiterator=\c_tabl_ntb_current_col_three
+ \orelse\ifcsname\tabl_ntb_row_pattern\c_tabl_ntb_current_row_three\the\currentloopiterator\endcsname
+ \scratchcounterthree\tabl_ntb_get_row\c_tabl_ntb_current_row_three\currentloopiterator\relax
+ \ifnum\scratchcounterthree=\plusone
+ \scratchdimenthree\tabl_ntb_get_ht\c_tabl_ntb_current_row_three\currentloopiterator\relax
+ \ifdim\scratchdimentwo<\scratchdimenthree
+ \scratchdimentwo\scratchdimenthree
\fi
\fi
\fi}%
\c_tabl_ntb_current_row_four\c_tabl_ntb_current_row_three
% calculate cummulative height
- \dimen4=\dimen2
+ \scratchdimenthree\scratchdimentwo
\scratchcounterthree\c_tabl_ntb_current_row_three
- \advance\scratchcounterthree\minusone
+ \advanceby\scratchcounterthree\minusone
\localcontrolledloop\plusone\scratchcountertwo\plusone
{\ifnum\c_tabl_ntb_current_row_four=\c_tabl_ntb_current_row_three\else
- \advance\dimen4 \tabl_ntb_get_hei\c_tabl_ntb_current_row_four
+ \advanceby\scratchdimenthree\tabl_ntb_get_hei\c_tabl_ntb_current_row_four
\fi
\ifnum\currentloopiterator=\scratchcountertwo\else
\tabl_ntb_set_nob\scratchcounterthree
- \advance\scratchcounterthree\plusone
- \fi
- \advance\c_tabl_ntb_current_row_four\plusone}%
+ \advanceby\scratchcounterthree\plusone
+ \fi
+ \advanceby\c_tabl_ntb_current_row_four\plusone}%
% distribute overshoot equally
- \ifdim\dimen2>\zeropoint % new: test on natural-003
- \ifdim\dimen4<\dimen0
- \advance\dimen0 -\dimen4
- \divide\dimen0 \scratchcountertwo
+ \ifdim\scratchdimentwo>\zeropoint % new: test on natural-003
+ \ifdim\scratchdimenthree<\scratchdimenone
+ \advanceby\scratchdimenone -\scratchdimenthree
+ \divideby\scratchdimenone \scratchcountertwo
\c_tabl_ntb_current_row_four\c_tabl_ntb_current_row_three
- \tabl_ntb_set_hei\c_tabl_ntb_current_row_three\dimen2\relax
+ \tabl_ntb_set_hei\c_tabl_ntb_current_row_three\scratchdimentwo\relax
\localcontrolledloop\plusone\scratchcountertwo\plusone
{\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
{\ifnum\currentloopiterator=\c_tabl_ntb_current_col_three\else
- \scratchdimen\dimexpr\tabl_ntb_get_ht\c_tabl_ntb_current_row_four\currentloopiterator+\dimen0\relax
+ \scratchdimen\dimexpr\tabl_ntb_get_ht\c_tabl_ntb_current_row_four\currentloopiterator+\scratchdimenone\relax
\tabl_ntb_set_ht\c_tabl_ntb_current_row_four\currentloopiterator\scratchdimen
\ifdim\tabl_ntb_get_hei\c_tabl_ntb_current_row_four<\scratchdimen
\tabl_ntb_set_hei\c_tabl_ntb_current_row_four\scratchdimen
\fi
\fi}%
- \advance\c_tabl_ntb_current_row_four\plusone}%
- \orelse\ifdim\dimen4>\dimen0
+ \advanceby\c_tabl_ntb_current_row_four\plusone}%
+ \orelse\ifdim\scratchdimenthree>\scratchdimenone
\iftightTBLrowspan
- \tabl_ntb_set_hei\c_tabl_ntb_current_row_three\dimen2\relax
+ \tabl_ntb_set_hei\c_tabl_ntb_current_row_three\scratchdimentwo\relax
\fi
\fi
\fi
@@ -1948,7 +1945,7 @@
{\begingroup
\scratchdimen\zeropoint
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
- {\advance\scratchdimen\tabl_ntb_get_wid\currentloopiterator\relax}%
+ {\advanceby\scratchdimen\tabl_ntb_get_wid\currentloopiterator\relax}%
\writestatus\m!TABLE{#1 \ifcase#2trial\else real\fi: hsize: \the\hsize, total: \the\scratchdimen}%
\localcontrolledloop\plusone\c_tabl_ntb_maximum_col\plusone
{\writestatus\m!TABLE{\space\space\the\currentloopiterator: \the\dimexpr\tabl_ntb_get_wid\currentloopiterator}}%
diff --git a/tex/context/base/mkxl/tabl-tab.mkxl b/tex/context/base/mkxl/tabl-tab.mkxl
index 8bd1d052a..8c872cd47 100644
--- a/tex/context/base/mkxl/tabl-tab.mkxl
+++ b/tex/context/base/mkxl/tabl-tab.mkxl
@@ -34,11 +34,11 @@
\newconditional\c_tabl_table_spacing_left
\newconditional\c_tabl_table_spacing_right
-\newdimen \d_tabl_table_line_thickness_unit
-\newdimen \d_tabl_table_strut_unit
-\newskip \s_tabl_table_inter_column_space_unit
-\newdimen \d_tabl_table_column_width_unit
-\newdimen \d_tabl_table_kern_unit
+\newdimension \d_tabl_table_line_thickness_unit
+\newdimension \d_tabl_table_strut_unit
+\newgluespec \s_tabl_table_inter_column_space_unit
+\newdimension \d_tabl_table_column_width_unit
+\newdimension \d_tabl_table_kern_unit
\mutable\def\tablestrutheightfactor {8}
\mutable\def\tablestrutdepthfactor {3}
@@ -85,26 +85,26 @@
\rightskip\zeropoint \s!plus 4em \relax
\to \everytableparbox
-\newskip \tablelefttabskip
-\newskip \tablerighttabskip
+\newgluespec \tablelefttabskip
+\newgluespec \tablerighttabskip
-\newcount\!taColumnNumber
-\newcount\!taRecursionLevel % (Initially 0)
+\newinteger \!taColumnNumber
+\newinteger \!taRecursionLevel % (Initially 0)
-\newdimen\!taDimenA % used by \Enlarge
-\newdimen\!taDimenB % used by \Enlarge
-\newdimen\!taDimenC % used by numeric.tex
-\newdimen\!taMinimumColumnWidth
+\newdimension\!taDimenA % used by \Enlarge
+\newdimension\!taDimenB % used by \Enlarge
+\newdimension\!taDimenC % used by numeric.tex
+\newdimension\!taMinimumColumnWidth
-\newtoks \!taTableSpread
-\newtoks \!taPreamble
-\newtoks \!taDataColumnTemplate
-\newtoks \!taRuleColumnTemplate
-\newtoks \!taOldRuleColumnTemplate
-\newtoks \!taLeftGlue
-\newtoks \!taRightGlue
+\newtoks \!taTableSpread
+\newtoks \!taPreamble
+\newtoks \!taDataColumnTemplate
+\newtoks \!taRuleColumnTemplate
+\newtoks \!taOldRuleColumnTemplate
+\newtoks \!taLeftGlue
+\newtoks \!taRightGlue
-\newskip \!taLastRegularTabskip
+\newgluespec \!taLastRegularTabskip
\newif \if!taBeginFormat
\newif \if!taOnceOnlyTabskip
@@ -123,8 +123,8 @@
{\!taPreamble\emptytoks
\!taColumnNumber\zerocount
\scratchskip\s_tabl_table_inter_column_space_unit
- \multiply\scratchskip\tableintercolumnspacefactor
- \divide\scratchskip\plustwo
+ \multiplyby\scratchskip\tableintercolumnspacefactor
+ \divideby\scratchskip\plustwo
\!taRuleColumnTemplate\expandafter{\expandafter\tabskip\the\scratchskip}%
\!taLastRegularTabskip\scratchskip
\!taOnceOnlyTabskipfalse
@@ -144,7 +144,7 @@
\aftergroup\omit
\!thLoop
\ifnum \scratchcounter<\!taColumnNumber
- \advance\scratchcounter\plusone
+ \advanceby\scratchcounter\plusone
\aftergroup\!tfAOAO
\repeat
\aftergroup}%
@@ -176,11 +176,11 @@
\def\!tfSetTabskip
{\ifnum\!tgCode=\plusone
\scratchskip\s_tabl_table_inter_column_space_unit
- \multiply\scratchskip \ifempty\!tgValue\tableintercolumnspacefactor\else\!tgValue\fi
+ \multiplyby\scratchskip \ifempty\!tgValue\tableintercolumnspacefactor\else\!tgValue\fi
\else
\scratchskip\!tgValue
\fi
- \divide\scratchskip\plustwo
+ \divideby\scratchskip\plustwo
\ifzero\!taColumnNumber
%\!thToksEdef\!taRuleColumnTemplate{\the\!taRuleColumnTemplate\tabskip\the\scratchskip}%
\normalexpanded{\!taRuleColumnTemplate{\the\!taRuleColumnTemplate\tabskip\the\scratchskip}}%
@@ -230,7 +230,7 @@
\!thToksEdef\!taDataColumnTemplate{\the\!taLeftGlue\the\!taDataColumnTemplate\the\!taRightGlue}%
\!thToksEdef\!taPreamble{\the\!taPreamble\aligntab\the\!taDataColumnTemplate\aligntab\the\!taRuleColumnTemplate}%
\fi
- \advance\!taColumnNumber\plusone
+ \advanceby\!taColumnNumber\plusone
\if!taOnceOnlyTabskip
\!thToksEdef\!taDataColumnTemplate{\aligncontent\tabskip\the\!taLastRegularTabskip}%
\else
@@ -426,7 +426,7 @@
\!thLoop
\ifnum\scratchcounter>\zerocount
\toksapp\scratchtoks{#2}%
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\repeat
\expandafter\doreadtableformatkeys\the\scratchtoks}
@@ -631,7 +631,7 @@
\scratchcounter#1\relax
\!thLoop
\ifnum \scratchcounter>\zerocount
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\aftergroup0
\repeat
\def\tempstring{#3}%
@@ -640,7 +640,7 @@
\scratchcounter#2\relax
\!thLoop
\ifnum \scratchcounter>\zerocount
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\aftergroup0
\repeat
\fi
@@ -708,7 +708,7 @@
\scratchcounter#1\relax
\!thLoop
\ifnum \scratchcounter>\zerocount
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\aftergroup0
\repeat
\def\tempstring{#3}%
@@ -717,7 +717,7 @@
\scratchcounter#2\relax
\!thLoop
\ifnum\scratchcounter>\zerocount
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\aftergroup0
\repeat
\fi
@@ -826,7 +826,7 @@
\fi
\bgroup % for the \vtop, \vbox, or \vcenter
\fi
- \advance\!taRecursionLevel\plusone
+ \advanceby\!taRecursionLevel\plusone
\let\!ttRightGlue\relax
\everycr\emptytoks
\ifnum\!taRecursionLevel=\plusone
@@ -894,7 +894,7 @@
% INSERT VRULE
-\newcount\c_tabl_table_n_of_vrules \c_tabl_table_n_of_vrules\plusone
+\newinteger\c_tabl_table_n_of_vrules \c_tabl_table_n_of_vrules\plusone
\lettonothing\m_tabl_table_vrule_color
\lettonothing\m_tabl_table_hrule_color
@@ -950,22 +950,22 @@
\omit
\global\setfalse\c_tabl_table_is_division % added
\scratchcounter\currenttablecolumn % added
- \advance\scratchcounter #1% % added
- \advance\scratchcounter \minusone % added
+ \advanceby\scratchcounter #1% % added
+ \advanceby\scratchcounter \minusone % added
\def\next % added
- {\global\advance\currenttablecolumn #1% % added
- \global\advance\currenttablecolumn \minusone % added
+ {\global\advanceby\currenttablecolumn #1% % added
+ \global\advanceby\currenttablecolumn \minusone % added
\scratchcounter#1%
- \advance\scratchcounter \minusone
- \advance\scratchcounter \scratchcounter
+ \advanceby\scratchcounter \minusone
+ \advanceby\scratchcounter \scratchcounter
\!thLoop
\ifnum\scratchcounter>\plusone
- \spanomit \advance\scratchcounter\minusone
+ \spanomit \advanceby\scratchcounter\minusone
\repeat
\span}%
\else % added
\def\next % conflicts with possible next \omit % added
- {\global\advance\currenttablecolumn \plusone}%% added
+ {\global\advanceby\currenttablecolumn \plusone}%% added
\fi
\next} % added
@@ -1019,7 +1019,7 @@
\else
\!tgValue % user-specified dimension
\fi
- \divide\scratchdimen\plustwo}
+ \divideby\scratchdimen\plustwo}
% \emptyhbox prevents \unskip
@@ -1074,8 +1074,8 @@
{\ifnum\!tgCode=\plusone
\ifempty\!tgValue
\!taDimenA\tablestrutheightfactor\d_tabl_table_strut_unit
- \advance\!taDimenA\tablestrutdepthfactor\d_tabl_table_strut_unit
- \divide\!taDimenA\plustwo
+ \advanceby\!taDimenA\tablestrutdepthfactor\d_tabl_table_strut_unit
+ \divideby\!taDimenA\plustwo
\else
\!taDimenA\!tgValue\d_tabl_table_strut_unit
\fi
@@ -1874,7 +1874,7 @@
%D the number of \type{|}'s and \type{\VL}'s or alike is always one more than the
%D number of columns.
-\newcount\currenttablecolumn
+\newinteger\currenttablecolumn
%D While defining this macro we change the \CATCODE\ of \type{|}. When counting the
%D bars, we use a non active representation of the bar, simply because we cannot be
@@ -1904,9 +1904,9 @@
%D \sym{\type{\HC}} a horizontal colored line
%D \stopitemize
-\newcount\c_tabl_table_vrule_thickness_factor
-\newcount\c_tabl_table_hrule_thickness_factor
-\newcount\c_tabl_table_drule_span
+\newinteger\c_tabl_table_vrule_thickness_factor
+\newinteger\c_tabl_table_hrule_thickness_factor
+\newinteger\c_tabl_table_drule_span
\lettonothing\m_tabl_table_vrule_color
\lettonothing\m_tabl_table_hrule_color
@@ -1928,12 +1928,12 @@
\def\tabl_table_vrulecommand#1% global assignments
{\doifelsenumber{#1}
{\global\c_tabl_table_vrule_thickness_factor#1\relax
- \global\multiply\c_tabl_table_vrule_thickness_factor\m_tabl_table_VLwidth\relax}
+ \global\multiplyby\c_tabl_table_vrule_thickness_factor\m_tabl_table_VLwidth\relax}
{\xdef\m_tabl_table_vrule_color{#1}}}
\permanent\tolerant\protected\def\tabl_table_VL[#1]%
{\tabl_tables_check_auto_row
- \global\advance\currenttablecolumn\plusone
+ \global\advanceby\currenttablecolumn\plusone
\glettonothing\m_tabl_table_vrule_color
\global\c_tabl_table_vrule_thickness_factor\m_tabl_table_VLwidth\relax
\iftok{#1}\emptytoks\else
@@ -1959,7 +1959,7 @@
\def\tabl_table_hrulecommand#1% global assignments
{\doifelsenumber{#1}
{\global\c_tabl_table_hrule_thickness_factor#1\relax
- \global\multiply\c_tabl_table_hrule_thickness_factor\m_tabl_table_HLheight\relax}
+ \global\multiplyby\c_tabl_table_hrule_thickness_factor\m_tabl_table_HLheight\relax}
{\xdef\m_tabl_table_hrule_color{#1}}}
\permanent\tolerant\protected\def\tabl_table_HL[#1]%
@@ -2043,7 +2043,7 @@
\protected\def\tabl_table_NC
{\tabl_tables_check_auto_row
- \global\advance\currenttablecolumn \plusone
+ \global\advanceby\currenttablecolumn \plusone
\tabl_table_normal_no_bar}
%D \startitemize[3*broad]
@@ -2076,7 +2076,7 @@
\global\c_tabl_table_drule_span#1\relax
\else
\global\c_tabl_table_hrule_thickness_factor#1\relax
- \global\multiply\c_tabl_table_hrule_thickness_factor\m_tabl_table_VLwidth\relax
+ \global\multiplyby\c_tabl_table_hrule_thickness_factor\m_tabl_table_VLwidth\relax
\fi}
{\xdef\m_tabl_table_hrule_color{#1}}}
@@ -2101,13 +2101,13 @@
% \fi
\fi
\ifcase\c_tabl_table_drule_span
- \global\advance\currenttablecolumn \plusone
+ \global\advanceby\currenttablecolumn \plusone
\tabl_table_normal_single_rule
\or
- \global\advance\currenttablecolumn \plustwo
+ \global\advanceby\currenttablecolumn \plustwo
\tabl_table_normal_single_rule
\else
- \global\advance\currenttablecolumn \plusone
+ \global\advanceby\currenttablecolumn \plusone
\tabl_table_normal_multi_rule
\fi
\fi}
@@ -2121,7 +2121,7 @@
\permanent\protected\def\tabl_table_DCV#1%
{\tabl_table_check_division
\tabl_tables_check_auto_row
- \global\advance\currenttablecolumn \plusone
+ \global\advanceby\currenttablecolumn \plusone
#1}
\permanent\protected\def\tabl_table_DR
diff --git a/tex/context/base/mkxl/tabl-tbl.mkxl b/tex/context/base/mkxl/tabl-tbl.mkxl
index ad18daef4..960138a14 100644
--- a/tex/context/base/mkxl/tabl-tbl.mkxl
+++ b/tex/context/base/mkxl/tabl-tbl.mkxl
@@ -161,24 +161,24 @@
\newtoks \t_tabl_tabulate_initializers_first
\newtoks \t_tabl_tabulate_initializers_second
-\newcount \c_tabl_tabulate_nofauto
-\newcount \c_tabl_tabulate_columns
-\newcount \c_tabl_tabulate_column
-\newcount \c_tabl_tabulate_plines_min
-\newcount \c_tabl_tabulate_plines_max
-\newcount \c_tabl_tabulate_max_colorcolumn
-\newcount \c_tabl_tabulate_max_vrulecolumn
-\newcount \c_tabl_tabulate_repeathead
-\newcount \c_tabl_tabulate_noflines
-\newcount \c_tabl_tabulate_totalnoflines
-\newcount \c_tabl_tabulate_minusnoflines
-\newcount \c_tabl_tabulate_align
-\newcount \c_tabl_tabulate_nofrealrows
-\newcount \c_tabl_tabulate_autocolor
-
-\newcount \c_tabl_tabulate_nofcolumns % set at the lua end by parser
-\newcount \c_tabl_tabulate_has_rule_spec_first % set at the lua end by parser (for the moment a count)
-\newcount \c_tabl_tabulate_has_rule_spec_last % set at the lua end by parser (for the moment a count)
+\newinteger \c_tabl_tabulate_nofauto
+\newinteger \c_tabl_tabulate_columns
+\newinteger \c_tabl_tabulate_column
+\newinteger \c_tabl_tabulate_plines_min
+\newinteger \c_tabl_tabulate_plines_max
+\newinteger \c_tabl_tabulate_max_colorcolumn
+\newinteger \c_tabl_tabulate_max_vrulecolumn
+\newinteger \c_tabl_tabulate_repeathead
+\newinteger \c_tabl_tabulate_noflines
+\newinteger \c_tabl_tabulate_totalnoflines
+\newinteger \c_tabl_tabulate_minusnoflines
+\newinteger \c_tabl_tabulate_align
+\newinteger \c_tabl_tabulate_nofrealrows
+\newinteger \c_tabl_tabulate_autocolor
+
+\newinteger \c_tabl_tabulate_nofcolumns % set at the lua end by parser
+\newinteger \c_tabl_tabulate_has_rule_spec_first % set at the lua end by parser (for the moment a count)
+\newinteger \c_tabl_tabulate_has_rule_spec_last % set at the lua end by parser (for the moment a count)
\newconditional \c_tabl_tabulate_nopbreak
\newconditional \c_tabl_tabulate_firstflushed
@@ -194,31 +194,31 @@
\newconditional \c_tabl_tabulate_reshape
\newconditional \c_tabl_tabulate_no_blank_in_paragraphs % can become always on
-\settrue\c_tabl_tabulate_split
-\settrue\c_tabl_tabulate_handlepbreak
-\settrue\c_tabl_tabulate_autorulespacing
-\settrue\c_tabl_tabulate_no_blank_in_paragraphs
-
-\newdimen \d_tabl_tabulate_width_p
-\newdimen \d_tabl_tabulate_width_w
-\newdimen \d_tabl_tabulate_width
-\newdimen \d_tabl_tabulate_unit
-\newdimen \d_tabl_tabulate_height_p_max
-\newdimen \d_tabl_tabulate_vrulethickness_default
-\newdimen \d_tabl_tabulate_hrulethickness_default
-\newdimen \d_tabl_tabulate_vrulethickness
-\newdimen \d_tabl_tabulate_hrulethickness % not used
-\newdimen \d_tabl_tabulate_vrulethickness_local
-\newdimen \d_tabl_tabulate_hrulethickness_local
-\newdimen \d_tabl_tabulate_indent
-\newdimen \d_tabl_tabulate_splitoff_betweenskip
-\newdimen \d_tabl_tabulate_margin
-
-\newskip \s_tabl_tabulate_pre
-\newskip \s_tabl_tabulate_post
-\newskip \s_tabl_tabulate_first
-\newskip \s_tabl_tabulate_last
-\newskip \s_tabl_tabulate_separator
+\settrue \c_tabl_tabulate_split
+\settrue \c_tabl_tabulate_handlepbreak
+\settrue \c_tabl_tabulate_autorulespacing
+\settrue \c_tabl_tabulate_no_blank_in_paragraphs
+
+\newdimension \d_tabl_tabulate_width_p
+\newdimension \d_tabl_tabulate_width_w
+\newdimension \d_tabl_tabulate_width
+\newdimension \d_tabl_tabulate_unit
+\newdimension \d_tabl_tabulate_height_p_max
+\newdimension \d_tabl_tabulate_vrulethickness_default
+\newdimension \d_tabl_tabulate_hrulethickness_default
+\newdimension \d_tabl_tabulate_vrulethickness
+\newdimension \d_tabl_tabulate_hrulethickness % not used
+\newdimension \d_tabl_tabulate_vrulethickness_local
+\newdimension \d_tabl_tabulate_hrulethickness_local
+\newdimension \d_tabl_tabulate_indent
+\newdimension \d_tabl_tabulate_splitoff_betweenskip
+\newdimension \d_tabl_tabulate_margin
+
+\newgluespec \s_tabl_tabulate_pre
+\newgluespec \s_tabl_tabulate_post
+\newgluespec \s_tabl_tabulate_first
+\newgluespec \s_tabl_tabulate_last
+\newgluespec \s_tabl_tabulate_separator
\newbox \b_tabl_tabulate
@@ -268,7 +268,7 @@
\to \t_tabl_tabulate_initializers_second
\prependtoks
- \global\advance\c_tabl_tabulate_nofrealrows\plusone
+ \global\advanceby\c_tabl_tabulate_nofrealrows\plusone
\to \t_tabl_tabulate_every_real_row
\permanent\def\b_tabl_tabulate_current#1%
@@ -281,7 +281,7 @@
\def\tabl_tabulate_initialize_boxes_step
{\ifnum\scratchcounter>\zerocount
\tabl_tabulate_initialize_box\scratchcounter
- \advance\scratchcounter\minusone
+ \advanceby\scratchcounter\minusone
\expandafter\tabl_tabulate_initialize_boxes_step
\fi}
@@ -745,7 +745,7 @@
\settrue\c_tabl_tabulate_reshape,
\s!unknown=>\d_tabl_tabulate_width#1\relax]%
\ifconditional\c_tabl_tabulate_pwidth_set
- \global\advance\d_tabl_tabulate_width_p\d_tabl_tabulate_width % accumulated parwidth
+ \global\advanceby\d_tabl_tabulate_width_p\d_tabl_tabulate_width % accumulated parwidth
\fi
\tabl_tabulate_set_preamble}
@@ -767,7 +767,7 @@
% \def\tabl_tabulate_set_width_indeed(#1)%
% {\rawprocesscommacommand[#1]\tabl_tabulate_set_width_step
% \ifconditional\c_tabl_tabulate_pwidth_set
-% \global\advance\d_tabl_tabulate_width_p\d_tabl_tabulate_width % accumulated parwidth
+% \global\advanceby\d_tabl_tabulate_width_p\d_tabl_tabulate_width % accumulated parwidth
% \fi
% \tabl_tabulate_set_preamble}
@@ -796,7 +796,7 @@
\tabl_tabulate_set_preamble_step\tabl_tabulate_bskip_raggedcenter\tabl_tabulate_eskip \fi}
\def\tabl_tabulate_set_width_auto
- {\global\advance\c_tabl_tabulate_nofauto\plusone
+ {\global\advanceby\c_tabl_tabulate_nofauto\plusone
\ifcase\c_tabl_tabulate_align\relax
\tabl_tabulate_set_preamble_step\tabl_tabulate_bskip \tabl_tabulate_eskip \or
\tabl_tabulate_set_preamble_step\tabl_tabulate_bskip_raggedright \tabl_tabulate_eskip \or
@@ -850,7 +850,7 @@
\global\setfalse\c_tabl_auto_align_mode_new
\resetalignmentcharacter
% \attribute\aligncharacterattribute\attributeunsetvalue
- \global\advance\c_tabl_tabulate_columns\plusone
+ \global\advanceby\c_tabl_tabulate_columns\plusone
\letcsname\??tabulatesetup\the\c_tabl_tabulate_columns\endcsname\donothing % here ?
\iftok{#1}\emptytoks
\global\d_tabl_tabulate_vrulethickness\zeropoint
@@ -969,7 +969,7 @@
\ifnum\c_tabl_tabulate_plines_min=\plusone
\tabl_tabulate_nobreak_inject
\fi
- \global\advance\c_tabl_tabulate_plines_min\plusone
+ \global\advanceby\c_tabl_tabulate_plines_min\plusone
\ifnum\c_tabl_tabulate_plines_min=\c_tabl_tabulate_plines_max\relax
\tabl_tabulate_nobreak_inject
\fi
@@ -1799,7 +1799,7 @@
{% we now have a local hsize, and since we want to
% register positional info (i.e. real hsizes) we
% need to reconstitute the original hsize
- \advance\hsize\d_tabl_tabulate_indent
+ \advanceby\hsize\d_tabl_tabulate_indent
% this is indeed rather messy and took a few hours
% to dis/uncover
\the\t_tabl_tabulate_every_row
@@ -1956,7 +1956,7 @@
\to \t_tabl_tabulate_initializers_first
% \permanent\protected\def\tabl_tabulate_NR_common#1#2%
-% {\global\advance\c_tabl_tabulate_noflines\plusone
+% {\global\advanceby\c_tabl_tabulate_noflines\plusone
% \global\setfalse\c_tabl_tabulate_firstflushed
% \global\setfalse\c_tabl_tabulate_equal
% \global\c_tabl_tabulate_column\zerocount
@@ -1969,7 +1969,7 @@
% \noalign{\the\t_tabl_tabulate_every_after_row#2}}
\permanent\tolerant\protected\def\tabl_tabulate_NR_common#1#2#.#3% #. gobbles pars and spaces
- {\global\advance\c_tabl_tabulate_noflines\plusone
+ {\global\advanceby\c_tabl_tabulate_noflines\plusone
\global\setfalse\c_tabl_tabulate_firstflushed
\global\setfalse\c_tabl_tabulate_equal
\global\c_tabl_tabulate_column\zerocount
@@ -2223,7 +2223,7 @@
{\ifdefined\page_sides_check_floats_indeed
\page_sides_check_floats_indeed
\ifdim\hangindent>\zeropoint
- \advance\d_tabl_tabulate_indent\hangindent
+ \advanceby\d_tabl_tabulate_indent\hangindent
\fi
\fi}
@@ -2324,7 +2324,7 @@
\t_tabl_tabulate_preamble
{\aligntab
\tabl_tabulate_flush_indent
-% \global\advance\c_tabl_tabulate_noflines\plusone
+% \global\advanceby\c_tabl_tabulate_noflines\plusone
\strut
\aligncontent % \alignmark\alignmark
\tabskip\d_tabl_tabulate_margin
@@ -2336,7 +2336,7 @@
\t_tabl_tabulate_preamble
{\aligntab
\tabl_tabulate_flush_indent
-% \global\advance\c_tabl_tabulate_noflines\plusone
+% \global\advanceby\c_tabl_tabulate_noflines\plusone
\strut
\aligncontent % \alignmark\alignmark
\aligntab
@@ -2356,7 +2356,7 @@
\toksapp\t_tabl_tabulate_preamble{%
\aligntab
\aligncontent % \alignmark\alignmark
- \global\advance\c_tabl_tabulate_column\plusone % maybe just set it already
+ \global\advanceby\c_tabl_tabulate_column\plusone % maybe just set it already
}%
\toksapp\t_tabl_tabulate_dummy{%
\NC\unskip\unskip\crcr\tabl_tabulate_flush_collected % no count
@@ -2393,7 +2393,7 @@
% so, even if the natural size is larger, in the final run, we force the calculated width
\d_tabl_tabulate_width\dimexpr\hsize-\wd\scratchbox-\d_tabl_tabulate_width_p-\d_tabl_tabulate_width_w\relax
\ifnum\c_tabl_tabulate_nofauto>\zerocount
- \divide\d_tabl_tabulate_width \c_tabl_tabulate_nofauto\relax
+ \divideby\d_tabl_tabulate_width \c_tabl_tabulate_nofauto\relax
\fi
\fi
\setbox\scratchbox\emptybox % free memory
@@ -2997,7 +2997,7 @@
\popoverloadmode
\permanent\protected\def\tabl_tabulate_A_first
- {\global\advance\c_tabl_tabulate_autocolor\plusone
+ {\global\advanceby\c_tabl_tabulate_autocolor\plusone
\edef\m_table_current_row_background_auto{\tabulateparameter{\c!backgroundcolor:\number\c_tabl_tabulate_autocolor}}%
\ifempty\m_table_current_row_background_auto
\global\c_tabl_tabulate_autocolor\plusone
diff --git a/tex/context/base/mkxl/tabl-tsp.mkxl b/tex/context/base/mkxl/tabl-tsp.mkxl
index 51069b75f..a2a147654 100644
--- a/tex/context/base/mkxl/tabl-tsp.mkxl
+++ b/tex/context/base/mkxl/tabl-tsp.mkxl
@@ -130,7 +130,7 @@
\dontcomplain
\global\settrue\splitfloatdone
% \nodelocationmode\zerocount % bypass auto-renumbering
- \global\advance\noffloatssplits\plusone
+ \global\advanceby\noffloatssplits\plusone
\ifcase\noffloatssplits\relax \or
\ifconditional\onlyonesplitofffloat
\lettonothing\floatcaptionsuffix
@@ -190,7 +190,7 @@
\setbox\scratchbox\vbox{\flushlocalfloats}% \vpack ?
\getnoflines{\ht\scratchbox}%
\resetlocalfloats
- \advance\noflines\minusone % compensate dummy line
+ \advanceby\noflines\minusone % compensate dummy line
\normalexpanded{\egroup\noexpand\edef\noexpand\extrasplitfloatlines{\the\noflines}}%
\global\settrue\usesamefloatnumber
\else
@@ -206,25 +206,24 @@
% todo: keep tail to rest, so we need a lookahead
-\newbox\b_split_content
-\newbox\b_split_result
-\newbox\b_split_head
-\newbox\b_split_next
-\newbox\b_split_tail
+\newbox \b_split_content
+\newbox \b_split_result
+\newbox \b_split_head
+\newbox \b_split_next
+\newbox \b_split_tail
-\newtoks\t_split_before_result
-\newtoks\t_split_after_result
-\newtoks\t_split_before
-\newtoks\t_split_inbetween
-\newtoks\t_split_after
+\newtoks \t_split_before_result
+\newtoks \t_split_after_result
+\newtoks \t_split_before
+\newtoks \t_split_inbetween
+\newtoks \t_split_after
+\newtoks \everyresettsplit
-\newtoks\everyresettsplit
+\newinteger \c_split_minimum_free_lines
-\newcount\c_split_minimum_free_lines
-
-\newdimen\d_split_minimum_free_space
-\newdimen\d_split_available_height
-\newdimen\d_split_inbetween_height
+\newdimension \d_split_minimum_free_space
+\newdimension \d_split_available_height
+\newdimension \d_split_inbetween_height
\newconditional\c_tabl_split_done
\newconditional\c_tabl_split_head
@@ -295,7 +294,7 @@
-\extrasplitfloatlines\lineheight
\relax
\ifdim\htdp\b_split_tail>\zeropoint
- \advance\d_split_available_height-\htdp\b_split_tail
+ \advanceby\d_split_available_height-\htdp\b_split_tail
\fi
\setbox\b_split_result\vbox
{\ifdim\ht\b_split_head>\zeropoint
diff --git a/tex/context/base/mkxl/tabl-xtb.mklx b/tex/context/base/mkxl/tabl-xtb.mklx
index 4f3d1683c..57685bbcd 100644
--- a/tex/context/base/mkxl/tabl-xtb.mklx
+++ b/tex/context/base/mkxl/tabl-xtb.mklx
@@ -82,21 +82,21 @@
{\signalcharacter}% not used
\to \everyenableelements
-\newdimen\d_tabl_x_width
-\newdimen\d_tabl_x_height
-\newdimen\d_tabl_x_depth % not used
-\newdimen\d_tabl_x_distance
-\newcount\c_tabl_x_nx
-\newcount\c_tabl_x_ny
-\newcount\c_tabl_x_mode
-\newbox \b_tabl_x
-\newcount\c_tabl_x_state % 0=empty 1=content 3=splitleft
-\newdimen\d_tabl_x_final_width
-\newcount\c_tabl_x_nesting
-\newcount\c_tabl_x_skip_mode % 1 = skip
-\newdimen\d_tabl_x_textwidth
-\newcount\c_tabl_x_swapped
-\newcount\c_tabl_x_swapped_max
+\newdimension\d_tabl_x_width
+\newdimension\d_tabl_x_height
+\newdimension\d_tabl_x_depth % not used
+\newdimension\d_tabl_x_distance
+\newinteger \c_tabl_x_nx
+\newinteger \c_tabl_x_ny
+\newinteger \c_tabl_x_mode
+\newbox \b_tabl_x
+\newinteger \c_tabl_x_state % 0=empty 1=content 3=splitleft
+\newdimension\d_tabl_x_final_width
+\newinteger \c_tabl_x_nesting
+\newinteger \c_tabl_x_skip_mode % 1 = skip
+\newdimension\d_tabl_x_textwidth
+\newinteger \c_tabl_x_swapped
+\newinteger \c_tabl_x_swapped_max
\lettonothing\m_tabl_x_swapped_settings
@@ -216,7 +216,7 @@
\protected\def\tabl_x_start_named[#tag]#spacer[#settings]%
{\bgroup
\edef\currentxtable{#tag}%
- \advance\c_tabl_x_nesting\plusone
+ \advanceby\c_tabl_x_nesting\plusone
\dostarttaggedchained\t!table\empty\??xtable
\setupcurrentxtable[#settings]%
\tabl_x_check_textwidth
@@ -240,7 +240,7 @@
\newtoks\everypreparextable
\protected\def\tabl_x_prepare#settings%
- {\advance\c_tabl_x_nesting\plusone
+ {\advanceby\c_tabl_x_nesting\plusone
\dostarttaggedchained\t!table\empty\??xtable
\tabl_x_set_checked{#settings}%
\tabl_x_check_textwidth
@@ -899,7 +899,7 @@
\expandafter\let\expandafter\t_tabl_x_swapped\csname\??xtableswap\number\c_tabl_x_swapped\endcsname}
\def\tabl_x_collect_advance
- {\global\advance\c_tabl_x_swapped\plusone
+ {\global\advanceby\c_tabl_x_swapped\plusone
\ifnum\c_tabl_x_swapped>\c_tabl_x_swapped_max
\global\c_tabl_x_swapped_max\c_tabl_x_swapped
\fi
diff --git a/tex/context/base/mkxl/trac-tex.mkxl b/tex/context/base/mkxl/trac-tex.mkxl
index 5e1c9e5bc..cf46bed26 100644
--- a/tex/context/base/mkxl/trac-tex.mkxl
+++ b/tex/context/base/mkxl/trac-tex.mkxl
@@ -56,14 +56,14 @@
\permanent\protected\def\profilemacro#1% an oldie, but modernized a bit
{\edef\p_name{\csstring#1}%
\ifcsname\??profilemacrocount\p_name\endcsname \else
- \expandafter\newcount\csname\??profilemacrocount\p_name\endcsname
+ \expandafter\newinteger\csname\??profilemacrocount\p_name\endcsname
\letcsname\??profilemacromacro\p_name\endcsname#1%
\xtoksapp\t_syst_profile
{\writestatus
{profile}%
{\string#1: \noexpand\the\csname\??profilemacrocount\p_name\endcsname}}%
\enforced\protected\xdef#1%
- {\global\advance\csname\??profilemacrocount\p_name\endcsname\plusone
+ {\global\advanceby\csname\??profilemacrocount\p_name\endcsname\plusone
\expandafter\noexpand\csname\??profilemacromacro\p_name\endcsname}%
\fi}
diff --git a/tex/context/base/mkxl/trac-vis.lmt b/tex/context/base/mkxl/trac-vis.lmt
index 91d3bfc3f..df59f83c0 100644
--- a/tex/context/base/mkxl/trac-vis.lmt
+++ b/tex/context/base/mkxl/trac-vis.lmt
@@ -797,6 +797,7 @@ local ruledbox do
local getshift = nuts.getshift
local getorientation = nuts.getorientation
+ local getheight = nuts.getheight
setmetatableindex(o_cache,function(t,size)
local rule = new_rule(2*size,size,size)
@@ -812,105 +813,138 @@ local ruledbox do
local wd, ht, dp = getwhd(current)
-- todo local wd, ht, dh, shift = getlistdimensions(current)
local force_origin = wd == 0 or (dp + ht) == 0
- local shift = getshift(current)
- local orientation, xoffset, yoffset = getorientation(current)
- local next = getnext(current)
- local prev = previous
- setboth(current)
- local linewidth = emwidth/fraction
- local size = 2*linewidth
- local this
- if not simple then
- this = b_cache[what]
- if not this then
- local text = hpack_string(what,usedfont)
- this = setlink(new_kern(-getwidth(text)),text)
- setlisttransparency(this,"trace:s")
- this = new_hlist(this)
- b_cache[what] = this
- end
+ local shift = getshift(current)
+ local orientation, xoffset, yoffset = getorientation(current)
+ local next = getnext(current)
+ local prev = previous
+ setboth(current)
+ local linewidth = emwidth/fraction
+ local size = 2*linewidth
+ local this
+ if not simple then
+ this = b_cache[what]
+ if not this then
+ local text = hpack_string(what,usedfont)
+ this = setlink(new_kern(-getwidth(text)),text)
+ setlisttransparency(this,"trace:s")
+ this = new_hlist(this)
+ b_cache[what] = this
end
- -- we need to trigger the right mode (else sometimes no whatits)
- local info = setlink(
- this and copylist(this) or nil,
- (force_origin and emptyrule(wd,ht,dp)) -- we accept some overhead
- or dp == 0 and userrule {
- width = wd,
- height = ht,
- line = linewidth,
- type = "box",
- baseline = false,
-
- }
- or userrule {
- width = wd,
- height = ht,
- depth = dp,
- line = linewidth,
- type = "box",
- dashed = 3*size,
-
- }
- )
- --
- setlisttransparency(info,"trace:s")
- info = new_hlist(info) -- important
- --
- setattr(info,a_layer,layer)
- if vertical then
- if not force_origin and shift == 0 then
- info = setlink(current,dp ~= 0 and new_kern(-dp) or nil,info)
- elseif trace_origin or force_origin then
- local size = 2*size
- local origin = o_cache[size]
- origin = copylist(origin)
- if getid(parent) == vlist_code then
- setshift(origin,-shift)
- info = setlink(current,new_kern(-size),origin,new_kern(-size-dp),info)
- else
- -- todo .. i need an example
- info = setlink(current,dp ~= 0 and new_kern(-dp) or nil,info)
- end
- setshift(current,0)
+ end
+ -- we need to trigger the right mode (else sometimes no whatits)
+-- local info = setlink(
+-- this and copylist(this) or nil,
+-- (force_origin and emptyrule(wd,ht,dp)) -- we accept some overhead
+-- or dp == 0 and userrule {
+-- width = wd,
+-- height = ht,
+-- line = linewidth,
+-- type = "box",
+-- baseline = false,
+-- }
+-- or userrule {
+-- width = wd,
+-- height = ht,
+-- depth = dp,
+-- line = linewidth,
+-- type = "box",
+-- dashed = 3*size,
+-- }
+-- )
+ local rest, more
+ if force_origin then
+ rest = emptyrule(wd,ht,dp) -- we accept some overhead
+ elseif what == "_D_" then
+ -- also the other line
+ local up = nil
+ local list = getlist(current)
+ if list then
+ up = getheight(list)
+ end
+ rest = userrule {
+ width = wd,
+ height = ht,
+ depth = dp,
+ line = linewidth,
+ type = "box",
+ dashed = 3*size,
+ double = ht - up,
+ }
+ elseif dp == 0 then
+ rest = userrule {
+ width = wd,
+ height = ht,
+ line = linewidth,
+ type = "box",
+ baseline = false,
+ }
+ else
+ rest = userrule {
+ width = wd,
+ height = ht,
+ depth = dp,
+ line = linewidth,
+ type = "box",
+ dashed = 3*size,
+ }
+ end
+ local info = setlink(this and copylist(this) or nil,rest,more)
+ --
+ setlisttransparency(info,"trace:s")
+ info = new_hlist(info) -- important
+ --
+ setattr(info,a_layer,layer)
+ if vertical then
+ if not force_origin and shift == 0 then
+ info = setlink(current,dp ~= 0 and new_kern(-dp) or nil,info)
+ elseif trace_origin or force_origin then
+ local size = 2*size
+ local origin = o_cache[size]
+ origin = copylist(origin)
+ if getid(parent) == vlist_code then
+ setshift(origin,-shift)
+ info = setlink(current,new_kern(-size),origin,new_kern(-size-dp),info)
else
- info = setlink(current,new_dp ~= 0 and new_kern(-dp) or nil,info)
- setshift(current,0)
+ -- todo .. i need an example
+ info = setlink(current,dp ~= 0 and new_kern(-dp) or nil,info)
end
- info = new_vlist(info,wd,ht,dp,shift)
+ setshift(current,0)
else
- if not force_origin and shift == 0 then
- info = setlink(current,new_kern(-wd),info)
- elseif trace_origin or force_origin then
- local size = 2*size
- local origin = o_cache[size]
- origin = copylist(origin)
- if getid(parent) == vlist_code then
- info = setlink(current,new_kern(-wd-size-shift),origin,new_kern(-size+shift),info)
- else
- setshift(origin,-shift)
- info = setlink(current,new_kern(-wd-size),origin,new_kern(-size),info)
- end
- setshift(current,0)
+ info = setlink(current,new_dp ~= 0 and new_kern(-dp) or nil,info)
+ setshift(current,0)
+ end
+ info = new_vlist(info,wd,ht,dp,shift)
+ else
+ if not force_origin and shift == 0 then
+ info = setlink(current,new_kern(-wd),info)
+ elseif trace_origin or force_origin then
+ local size = 2*size
+ local origin = o_cache[size]
+ origin = copylist(origin)
+ if getid(parent) == vlist_code then
+ info = setlink(current,new_kern(-wd-size-shift),origin,new_kern(-size+shift),info)
else
- info = setlink(current,new_kern(-wd),info)
- setshift(current,0)
+ setshift(origin,-shift)
+ info = setlink(current,new_kern(-wd-size),origin,new_kern(-size),info)
end
- info = new_hlist(info,wd,ht,dp,shift)
- end
- if next then
- setlink(info,next)
- end
- if prev and prev > 0 then
- setlink(prev,info)
- end
- if head == current then
- return info, info
+ setshift(current,0)
else
- return head, info
+ info = setlink(current,new_kern(-wd),info)
+ setshift(current,0)
end
- -- else
- -- return head, current
- -- end
+ info = new_hlist(info,wd,ht,dp,shift)
+ end
+ if next then
+ setlink(info,next)
+ end
+ if prev and prev > 0 then
+ setlink(prev,info)
+ end
+ if head == current then
+ return info, info
+ else
+ return head, info
+ end
end
end
@@ -942,13 +976,13 @@ local ruledglyph do
-- ht = linewidth/2
-- dp = ht
-- end
-local info = (dp == 0 and outlinerule and outlinerule(wd,ht,dp,linewidth)) or userrule {
- width = wd,
- height = ht,
- depth = dp,
- line = linewidth,
- type = "box",
-}
+ local info = (dp == 0 and outlinerule and outlinerule(wd,ht,dp,linewidth)) or userrule {
+ width = wd,
+ height = ht,
+ depth = dp,
+ line = linewidth,
+ type = "box",
+ }
local c, f = isglyph(current)
local char = chardata[f][c]
if char and type(char.unicode) == "table" then -- hackery test
@@ -1599,6 +1633,7 @@ do
local rowlist_code = listcodes.alignment
local vtop_package_state = 3 -- todo: symbolic
+ local dbox_package_state = 4 -- todo: symbolic
local getleader = nuts.getleader
local getdisc = nuts.getdisc
@@ -1876,14 +1911,19 @@ do
end
elseif id == vlist_code then
local content = getlist(current)
- local isvtop = getstate(current) == vtop_package_state
+ local state = getstate(current)
+ local isvtop = state == vtop_package_state
+ local isdbox = state == dbox_package_state
local tag = nil
local layer = nil
if content then
setlist(current,visualize(content,true,nil,current))
end
if trace_vtop then
- if isvtop then
+ if isdbox then
+ tag = "_D_"
+ layer = l_vtop
+ elseif isvtop then
tag = "_T_"
layer = l_vtop
elseif trace_vbox then
@@ -1891,7 +1931,10 @@ do
layer = l_vbox
end
elseif trace_vbox then
- if not isvtop then
+ if isdbox then
+ tag = "_D_"
+ layer = l_vtop
+ elseif not isvtop then
tag = "__V"
layer = l_vbox
end
diff --git a/tex/context/base/mkxl/trac-vis.mkxl b/tex/context/base/mkxl/trac-vis.mkxl
index 655374abb..73ebc7cd4 100644
--- a/tex/context/base/mkxl/trac-vis.mkxl
+++ b/tex/context/base/mkxl/trac-vis.mkxl
@@ -53,10 +53,12 @@
\aliased\let\syst_visualizers_hbox \hbox
\aliased\let\syst_visualizers_vbox \vbox
\aliased\let\syst_visualizers_vtop \vtop
+\aliased\let\syst_visualizers_dbox \dbox
\aliased\let\syst_visualizers_vcenter\vcenter
\aliased\let\syst_visualizers_hpack \hpack
\aliased\let\syst_visualizers_vpack \vpack
\aliased\let\syst_visualizers_tpack \tpack
+\aliased\let\syst_visualizers_dpack \dpack
\permanent\protected\def\ruledhbox {\syst_visualizers_hbox attr \visualattribute \clf_getvisual{simplehbox} }
\permanent\protected\def\ruledhpack {\syst_visualizers_hpack attr \visualattribute \clf_getvisual{simplehbox} }
@@ -64,6 +66,8 @@
\permanent\protected\def\ruledvpack {\syst_visualizers_vpack attr \visualattribute \clf_getvisual{simplevbox} }
\permanent\protected\def\ruledvtop {\syst_visualizers_vtop attr \visualattribute \clf_getvisual{simplevtop} }
\permanent\protected\def\ruledtpack {\syst_visualizers_tpack attr \visualattribute \clf_getvisual{simplevtop} }
+\permanent\protected\def\ruleddbox {\syst_visualizers_dbox attr \visualattribute \clf_getvisual{simplevtop} }
+\permanent\protected\def\ruleddpack {\syst_visualizers_dpack attr \visualattribute \clf_getvisual{simplevtop} }
\permanent\protected\def\ruledvcenter{\syst_visualizers_vcenter attr \visualattribute \clf_getvisual{simplevbox} }
\permanent\protected\def\ruledmbox #1{\ruledhbox{\startimath#1\stopimath}}
diff --git a/tex/context/base/mkxl/type-ini.mklx b/tex/context/base/mkxl/type-ini.mklx
index d750260e2..4842451e7 100644
--- a/tex/context/base/mkxl/type-ini.mklx
+++ b/tex/context/base/mkxl/type-ini.mklx
@@ -27,7 +27,7 @@
\unprotect
-\newcount \c_font_typescripts_n_of_preloaded
+\newinteger \c_font_typescripts_n_of_preloaded
\newconditional\c_font_typescripts_quit
\newtoks \c_font_typescripts_document
\newconditional\c_font_typescripts_preload
@@ -195,14 +195,14 @@
{\settrue\c_font_typescripts_quit} % public
\permanent\protected\def\font_typescripts_start_store#definitions\stoptypescript
- {\global\advance\c_font_typescripts_n_of_preloaded\plusone
+ {\global\advanceby\c_font_typescripts_n_of_preloaded\plusone
\gdefcsname\??typescriptcache\the\c_font_typescripts_n_of_preloaded\endcsname
{\starttypescript#definitions\stoptypescript}%
\gtoksapp\t_font_typescripts\expandafter
{\csname\??typescriptcache\the\c_font_typescripts_n_of_preloaded\endcsname}}
\permanent\protected\def\font_typescripts_collection_start_store#definitions\stoptypescriptcollection
- {\global\advance\c_font_typescripts_n_of_preloaded\plusone
+ {\global\advanceby\c_font_typescripts_n_of_preloaded\plusone
\gdefcsname\??typescriptcache\the\c_font_typescripts_n_of_preloaded\endcsname
{\starttypescriptcollection#definitions\stoptypescriptcollection}%
\gtoksapp\t_font_typescripts\expandafter
diff --git a/tex/context/base/mkxl/typo-ada.mkxl b/tex/context/base/mkxl/typo-ada.mkxl
index beb03e264..8da36f5e4 100644
--- a/tex/context/base/mkxl/typo-ada.mkxl
+++ b/tex/context/base/mkxl/typo-ada.mkxl
@@ -21,22 +21,15 @@
\unprotect
-\newdimen\d_adaptive_width
-\newdimen\d_adaptive_height
-\newdimen\d_adaptive_depth
-\newdimen\d_adaptive_line
-\newdimen\d_adaptive_hsize
+\newdimension\d_adaptive_width \aliasdimension\usedadaptivewidth \d_adaptive_width
+\newdimension\d_adaptive_height \aliasdimension\usedadaptiveheight\d_adaptive_height
+\newdimension\d_adaptive_depth \aliasdimension\usedadaptivedepth \d_adaptive_depth
+\newdimension\d_adaptive_line \aliasdimension\usedadaptiveline \d_adaptive_line
+\newdimension\d_adaptive_hsize \aliasdimension\usedadaptivehsize \d_adaptive_hsize
-\mutable\lettonothing\m_adaptive_color
-
-\newbox\b_adaptive_box
+\newbox \b_adaptive_box \aliased\let\usedadaptivebox\b_adaptive_box
-\aliased\let\usedadaptivewidth \d_adaptive_width
-\aliased\let\usedadaptiveheight\d_adaptive_height
-\aliased\let\usedadaptivedepth \d_adaptive_depth
-\aliased\let\usedadaptiveline \d_adaptive_line
-\aliased\let\usedadaptivehsize \d_adaptive_hsize
-\aliased\let\usedadaptivebox \b_adaptive_box
+\mutable\lettonothing\m_adaptive_color
\protected\untraced\def\usedadaptivetotal{\dimexpr\usedadaptiveheight+\usedadaptivedepth\relax}
diff --git a/tex/context/base/mkxl/typo-chr.mkxl b/tex/context/base/mkxl/typo-chr.mkxl
index 1c459cfcf..e59be1e29 100644
--- a/tex/context/base/mkxl/typo-chr.mkxl
+++ b/tex/context/base/mkxl/typo-chr.mkxl
@@ -78,7 +78,7 @@
%D test test\number\lastnodeid test
%D \stoptyping
-\newcount\c_syst_last_node_id
+\newinteger\c_syst_last_node_id
\permanent\protected\def\doifelselastnode {\clf_lastnodeequals} % can be public implementors
\permanent\protected\def\doifelseatwordboundary{\clf_atwordboundary} % can be public implementors
diff --git a/tex/context/base/mkxl/typo-del.mkxl b/tex/context/base/mkxl/typo-del.mkxl
index f790f9907..08d0a9b09 100644
--- a/tex/context/base/mkxl/typo-del.mkxl
+++ b/tex/context/base/mkxl/typo-del.mkxl
@@ -142,7 +142,7 @@
[\c!rightsubsentence]
[\rightboundarycharacter\c!rightsubsentence{sentence}]
-\newcount \c_typo_subsentence_nesting
+\newinteger\c_typo_subsentence_nesting
\mutable\let\beforesubsentence\donothing % maybe just a parameter
\mutable\let\aftersubsentence \donothing % maybe just a parameter
@@ -178,7 +178,7 @@
\unboundary
\kern\hspaceamount\currentusedlanguage{intersentence}%
\fi
- \global\advance\c_typo_subsentence_nesting\plusone
+ \global\advanceby\c_typo_subsentence_nesting\plusone
\ifnum\c_typo_subsentence_nesting=\plusone
\dontleavehmode
\fi
@@ -198,7 +198,7 @@
\symbol[\ifodd\c_typo_subsentence_nesting\c!rightsentence\else\c!rightsubsentence\fi]%
\dostoptagged
\dostoptagged
- \global\advance\c_typo_subsentence_nesting\minusone
+ \global\advanceby\c_typo_subsentence_nesting\minusone
\unskip
\boundary\c_typo_subsentence_boundary
\aftersubsentence}
@@ -361,13 +361,13 @@
\typo_delimited_set_language_yes
\fi
\let\currentparentdelimitedtext\currentdelimitedtext
- \global\advance\c_typo_delimited_nesting\plusone
+ \global\advanceby\c_typo_delimited_nesting\plusone
\edef\delimitedtextlevel{\number\c_typo_delimited_nesting}%
\normalexpanded{\chaintocurrentdelimitedtext{\currentparentdelimitedtext:\delimitedtextlevel}}%
\edef\currentdelimitedtext{\currentparentdelimitedtext:\delimitedtextlevel}}
\def\typo_delimited_pop
- {\global\advance\c_typo_delimited_nesting\minusone
+ {\global\advanceby\c_typo_delimited_nesting\minusone
\pop_macro_currentdelimitedlanguage
\pop_macro_currentdelimitedtext}
@@ -377,7 +377,7 @@
\installcommandhandler \??delimitedtext {delimitedtext} \??delimitedtext
\appendtoks
- \expandafter\newcount\csname\??delimitedtextlevel\currentdelimitedtext\endcsname
+ \expandafter\newinteger\csname\??delimitedtextlevel\currentdelimitedtext\endcsname
\frozen\instance\protected\edefcsname\currentdelimitedtext \endcsname{\delimitedtext[\currentdelimitedtext]}%
\frozen\instance\protected\edefcsname\e!start\currentdelimitedtext\endcsname{\startdelimitedtext[\currentdelimitedtext]}%
\frozen\instance\protected\edefcsname\e!stop \currentdelimitedtext\endcsname{\stopdelimitedtext}%
diff --git a/tex/context/base/mkxl/typo-drp.mkxl b/tex/context/base/mkxl/typo-drp.mkxl
index 963edac18..0a128b0d6 100644
--- a/tex/context/base/mkxl/typo-drp.mkxl
+++ b/tex/context/base/mkxl/typo-drp.mkxl
@@ -141,7 +141,7 @@
\permanent\protected\def\forgetinitial
{\ifcase\c_initial_lines\else
\begingroup
- \advance\c_initial_lines-\prevgraf\relax
+ \advanceby\c_initial_lines-\prevgraf\relax
\ifcase\c_initial_lines\else
\obeydepth
\forgetall
diff --git a/tex/context/base/mkxl/typo-hid.mkxl b/tex/context/base/mkxl/typo-hid.mkxl
index 8ee953cc1..13d8f14ca 100644
--- a/tex/context/base/mkxl/typo-hid.mkxl
+++ b/tex/context/base/mkxl/typo-hid.mkxl
@@ -19,7 +19,7 @@
\unprotect
-\newcount\c_typo_hidden_level
+\newinteger\c_typo_hidden_level
\permanent\protected\def\starthiddencontent
{\ifcase\c_typo_hidden_level
@@ -27,10 +27,10 @@
\let\clf_enablehidecontent\relax
\attribute\hidecontentattribute\plusone
\fi
- \advance\c_typo_hidden_level\plusone}
+ \advanceby\c_typo_hidden_level\plusone}
\permanent\protected\def\stophiddencontent
- {\advance\c_typo_hidden_level\minusone
+ {\advanceby\c_typo_hidden_level\minusone
\ifcase\c_typo_hidden_level
\attribute\hidecontentattribute\attributeunsetvalue
\fi}
diff --git a/tex/context/base/mkxl/typo-itm.mkxl b/tex/context/base/mkxl/typo-itm.mkxl
index 1622866ce..acc12c8ae 100644
--- a/tex/context/base/mkxl/typo-itm.mkxl
+++ b/tex/context/base/mkxl/typo-itm.mkxl
@@ -60,13 +60,13 @@
\c!inbetween={\blank[\v!medium]},
\c!after=\blank]
-\newcount\c_typo_items_n
-\newcount\c_typo_items_m
-\newdimen\d_typo_items_text_width
-\newdimen\d_typo_items_symbol_width
-\newdimen\d_typo_items_distance
-\newbox \b_typo_items_symbols
-\newbox \b_typo_items_texts
+\newinteger \c_typo_items_n
+\newinteger \c_typo_items_m
+\newdimension\d_typo_items_text_width
+\newdimension\d_typo_items_symbol_width
+\newdimension\d_typo_items_distance
+\newbox \b_typo_items_symbols
+\newbox \b_typo_items_texts
\permanent\tolerant\protected\def\items[#1]#:#2%
{\bgroup
@@ -138,7 +138,7 @@
\let\typo_items_make\relax
\def\typo_items_item_horizontal
- {\advance\c_typo_items_m\plusone
+ {\advanceby\c_typo_items_m\plusone
\csname\??itemshorizontal
\ifcsname\??itemshorizontal\p_typo_items_align\endcsname
\p_typo_items_align
@@ -148,7 +148,7 @@
\endcsname}
\def\typo_items_item_vertical
- {\advance\c_typo_items_m\plusone
+ {\advanceby\c_typo_items_m\plusone
\csname\??itemsvertical
\ifcsname\??itemsvertical\p_typo_items_align\endcsname
\p_typo_items_align
@@ -169,7 +169,7 @@
{\simplealignedbox\scratchwidth\m_typo_items_align}
\def\typo_items_make_horizontal#1%
- {\divide\scratchwidth\c_typo_items_n
+ {\divideby\scratchwidth\c_typo_items_n
\hbox{#1}}
\def\typo_items_make_vertical#1%
@@ -245,7 +245,7 @@
\setvalue{\??itemsalternatives\v!left}#1%
{\let\typo_items_make\typo_items_make_vertical
\let\typo_items_item\typo_items_item_vertical
- \advance\d_typo_items_text_width-\dimexpr\d_typo_items_symbol_width+\d_typo_items_distance\relax
+ \advanceby\d_typo_items_text_width-\dimexpr\d_typo_items_symbol_width+\d_typo_items_distance\relax
\typo_items_construct_items_boxes{#1}%
\noindent\hbox\bgroup
\ifvoid\b_typo_items_symbols \else
@@ -260,7 +260,7 @@
\setvalue{\??itemsalternatives\v!right}#1%
{\let\typo_items_make\typo_items_make_vertical
\let\typo_items_item\typo_items_item_vertical
- \advance\d_typo_items_text_width-\dimexpr\d_typo_items_symbol_width+\d_typo_items_distance\relax
+ \advanceby\d_typo_items_text_width-\dimexpr\d_typo_items_symbol_width+\d_typo_items_distance\relax
\typo_items_construct_items_boxes{#1}%
\noindent\hbox\bgroup
\box\b_typo_items_texts
diff --git a/tex/context/base/mkxl/typo-lbx.mkxl b/tex/context/base/mkxl/typo-lbx.mkxl
index a57564f61..93a2fc86f 100644
--- a/tex/context/base/mkxl/typo-lbx.mkxl
+++ b/tex/context/base/mkxl/typo-lbx.mkxl
@@ -59,11 +59,11 @@
\c!location=\v!left,
\c!distance=\zeropoint]
-\newcount\c_typo_localboxes
-\newcount\c_typo_localboxes_index
+\newinteger\c_typo_localboxes
+\newinteger\c_typo_localboxes_index
\appendtoks
- \global\advance\c_typo_localboxes\plusone
+ \global\advanceby\c_typo_localboxes\plusone
\global\expandafter\integerdef\csname\??localboxesattribute\currentlocalboxes\endcsname\c_typo_localboxes
\gletcsname\??localboxesnamespace\number\c_typo_localboxes\endcsname\currentlocalboxes
\to \everydefinelocalboxes
@@ -337,10 +337,10 @@
%D % \def\LineNumberL{\the\localboxlinenumber}
%D % \def\LineNumberR{\the\localboxlinenumber}
%D
-%D % \newcount\MyLineNumberL
-%D % \newcount\MyLineNumberR
-%D % \def\LineNumberL{\global\advance\MyLineNumberL\plusone\the\MyLineNumberL}
-%D % \def\LineNumberR{\global\advance\MyLineNumberR\plusone\the\MyLineNumberR}
+%D % \newinteger\MyLineNumberL
+%D % \newinteger\MyLineNumberR
+%D % \def\LineNumberL{\global\advanceby\MyLineNumberL\plusone\the\MyLineNumberL}
+%D % \def\LineNumberR{\global\advanceby\MyLineNumberR\plusone\the\MyLineNumberR}
%D
%D \definecounter[MyLineNumberL]
%D \definecounter[MyLineNumberR]
diff --git a/tex/context/base/mkxl/typo-mar.mkxl b/tex/context/base/mkxl/typo-mar.mkxl
index c49f8824f..be43e667d 100644
--- a/tex/context/base/mkxl/typo-mar.mkxl
+++ b/tex/context/base/mkxl/typo-mar.mkxl
@@ -161,8 +161,8 @@
% trialtypesetting: no need for margin stuff while trialing as
% is has no dimensions
-\newcount\nofmargintexts
-\newcount\c_typo_margins_n
+\newinteger\nofmargintexts
+\newinteger\c_typo_margins_n
\ifdefined\dotagmarginanchor \else \aliased\let\dotagmarginanchor\gobbleoneargument \fi
\ifdefined\dotagmargintext \else \aliased\let\dotagmargintext \gobbleoneargument \fi
@@ -198,7 +198,7 @@
% \doifelsenothing{#content}\donefalse\donetrue
% \doifelsetext{#content}\donetrue\donefalse
\ifparameter#content\donefalse\or\donetrue\else\donefalse\fi
- \global\advance\c_typo_margins_n\plusone
+ \global\advanceby\c_typo_margins_n\plusone
\ifdone
\edef\currentmarginreference{\margindataparameter\c!reference}%
\ifempty\currentmarginreference \else
diff --git a/tex/context/base/mkxl/typo-ovl.mkxl b/tex/context/base/mkxl/typo-ovl.mkxl
index b3ba2e783..d4a0db0f1 100644
--- a/tex/context/base/mkxl/typo-ovl.mkxl
+++ b/tex/context/base/mkxl/typo-ovl.mkxl
@@ -30,7 +30,7 @@
%D Watch how we abuse highlights.
-\newcount\c_typo_overload_font_id
+\newinteger\c_typo_overload_font_id
\protected\def\typo_overloads_define#1%
{\begingroup
diff --git a/tex/context/base/mkxl/typo-shp.mkxl b/tex/context/base/mkxl/typo-shp.mkxl
index 64cacef09..e6bc143c1 100644
--- a/tex/context/base/mkxl/typo-shp.mkxl
+++ b/tex/context/base/mkxl/typo-shp.mkxl
@@ -178,8 +178,8 @@
%D As it is not much code we now put it here:
-\newbox \shapetextbox
-\newcount\shapetextindex
+\newbox \shapetextbox
+\newinteger\shapetextindex
\permanent\protected\def\startshapetext[#1]%
{\begingroup
@@ -201,7 +201,7 @@
% {\vbox\bgroup
% \forgetall
% \dontcomplain
-% \global\advance\shapetextindex\plusone
+% \global\advanceby\shapetextindex\plusone
% \scratchcounter\getshapeparameter{lines}\relax
% \ifnum\scratchcounter>\zerocount
% \scratchwidth \getshapeparameter{width}\scaledpoint\relax
@@ -227,7 +227,7 @@
{\vbox\bgroup
\forgetall
\dontcomplain
- \global\advance\shapetextindex\plusone
+ \global\advanceby\shapetextindex\plusone
\scratchcounter\getshapeparameter{lines}\relax
\ifnum\scratchcounter>\zerocount
\scratchwidth \getshapeparameter{width}\scaledpoint\relax
diff --git a/tex/context/base/mkxl/typo-syn.mkxl b/tex/context/base/mkxl/typo-syn.mkxl
index c89d485e2..053f65922 100644
--- a/tex/context/base/mkxl/typo-syn.mkxl
+++ b/tex/context/base/mkxl/typo-syn.mkxl
@@ -164,7 +164,7 @@
\endstrut
\egroup
\scratchdimentwo\wd\scratchboxtwo
- \advance\scratchdimentwo\scratchdistance
+ \advanceby\scratchdimentwo\scratchdistance
\clf_registersynchronize
\strutht
\strutdp
@@ -176,7 +176,7 @@
\egroup
\scratchdimenone\wd\scratchboxone
\unhbox\scratchboxone
- \advance\scratchdimentwo-\scratchdimenone
+ \advanceby\scratchdimentwo-\scratchdimenone
\ifdim\scratchdimentwo>\zeropoint
\wordboundary
\typo_sync_rule
@@ -202,7 +202,7 @@
\synchronizecontentparameter\c!right
\egroup
\scratchdimentwo\wd\scratchboxtwo
- \advance\scratchdimentwo\scratchdistance
+ \advanceby\scratchdimentwo\scratchdistance
\clf_registersynchronize
\strutht
\strutdp
@@ -219,7 +219,7 @@
\egroup
\scratchdimenone\wd\scratchboxone
\unhbox\scratchboxone
- \advance\scratchdimentwo-\scratchdimenone
+ \advanceby\scratchdimentwo-\scratchdimenone
\ifdim\scratchdimentwo>\zeropoint
\wordboundary
\typo_sync_rule
diff --git a/tex/context/base/mkxl/typo-tal.mkxl b/tex/context/base/mkxl/typo-tal.mkxl
index 6ab888ce7..f3d9e54e0 100644
--- a/tex/context/base/mkxl/typo-tal.mkxl
+++ b/tex/context/base/mkxl/typo-tal.mkxl
@@ -123,11 +123,11 @@
\c!character =\alignmentcharacter]
\permanent\protected\def\typo_charalign_pass_one
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\setbox\scratchbox\typo_charalign_pass}
\permanent\protected\def\typo_charalign_pass_two
- {\advance\scratchcounter\plusone
+ {\advanceby\scratchcounter\plusone
\typo_charalign_pass}
\def\typo_charalign_pass
diff --git a/tex/context/interface/mkii/keys-ro.xml b/tex/context/interface/mkii/keys-ro.xml
index 1348116c6..9cd8c0431 100644
--- a/tex/context/interface/mkii/keys-ro.xml
+++ b/tex/context/interface/mkii/keys-ro.xml
@@ -594,6 +594,7 @@
<cd:variable name='temporary' value='temporar'/>
<cd:variable name='test' value='test'/>
<cd:variable name='text' value='text'/>
+ <cd:variable name='textdisplay' value='textdisplay'/>
<cd:variable name='textnote' value='textnote'/>
<cd:variable name='three' value='trei'/>
<cd:variable name='thursday' value='joi'/>
diff --git a/tex/context/modules/mkxl/m-crappyspec.mkxl b/tex/context/modules/mkxl/m-crappyspec.mkxl
index 483141141..0dd7903b9 100644
--- a/tex/context/modules/mkxl/m-crappyspec.mkxl
+++ b/tex/context/modules/mkxl/m-crappyspec.mkxl
@@ -128,9 +128,9 @@ function builders.paragraphs.constructors.methods.crappyspec(head)
end
\stopluacode
-\newcount\crappyspeccount
-\newdimen\crappyspecstep \crappyspecstep \onepoint
-\newdimen\crappyspecdimen
+\newinteger \crappyspeccount
+\newdimension\crappyspecstep \crappyspecstep \onepoint
+\newdimension\crappyspecdimen
\defineparbuilder [crappyspec] % implemented in the builder namespace
\defineparbuilder [default] % implemented in the builder namespace
diff --git a/tex/context/modules/mkxl/m-oldmath.mkxl b/tex/context/modules/mkxl/m-oldmath.mkxl
index 3594385ff..2132d773e 100644
--- a/tex/context/modules/mkxl/m-oldmath.mkxl
+++ b/tex/context/modules/mkxl/m-oldmath.mkxl
@@ -81,9 +81,9 @@
\baselineskip \the\baselineskip
\lineskiplimit\the\lineskiplimit
\relax}%
- \advance\lineskip \scratchdimen
- \advance\baselineskip \scratchdimen
- \advance\lineskiplimit\scratchdimen}
+ \advanceby\lineskip \scratchdimen
+ \advanceby\baselineskip \scratchdimen
+ \advanceby\lineskiplimit\scratchdimen}
\permanent\protected\def\openup {\math_openup } % the low level ones are used elsewhere
\permanent\protected\def\closeup{\math_closeup} % the low level ones are used elsewhere
diff --git a/tex/context/modules/mkxl/s-colors-show.mkxl b/tex/context/modules/mkxl/s-colors-show.mkxl
index aa0e3227e..3f1692f98 100644
--- a/tex/context/modules/mkxl/s-colors-show.mkxl
+++ b/tex/context/modules/mkxl/s-colors-show.mkxl
@@ -84,7 +84,7 @@
\scratchwidth\wd\scratchbox
\fi}%
\colo_palets_process[#1]\colo_palets_show_palet}%
- \advance\scratchwidth\emwidth
+ \advanceby\scratchwidth\emwidth
\ifdim\scratchwidth<5\emwidth
\scratchwidth5\emwidth
\fi
@@ -219,7 +219,7 @@
\setlocalhsize
\hsize\localhsize
\scratchcounter\zerocount
- \dorecurse{15}{\doifcolor{#2:\recurselevel}{\advance\scratchcounter\plusone}}
+ \dorecurse{15}{\doifcolor{#2:\recurselevel}{\advanceby\scratchcounter\plusone}}
\scratchwidth2\emwidth\relax
\hsize\scratchcounter\scratchwidth
\dorecurse\scratchcounter{\colo_groups_compare_step{#1}{#2}\recurselevel}}}
diff --git a/tex/context/modules/mkxl/s-fonts-show.mkxl b/tex/context/modules/mkxl/s-fonts-show.mkxl
index 42b5af125..32f50c484 100644
--- a/tex/context/modules/mkxl/s-fonts-show.mkxl
+++ b/tex/context/modules/mkxl/s-fonts-show.mkxl
@@ -111,7 +111,7 @@
\orelse\ifnum\scratchcountertwo=\scratchcounterthree
\exitloop
\else
- \advance\scratchcountertwo\plusone
+ \advanceby\scratchcountertwo\plusone
\fi}}}
{\processcommalist[#2]{\module_fonts_show_font_indeed{#1}}}}%
\egroup}
@@ -418,7 +418,7 @@
\protected\gdef\showotfsteps_n
{\blank
\begingroup
- \advance\leftskip6\emwidth
+ \advanceby\leftskip6\emwidth
\showotfstepmessages\recurselevel
\par
\endgroup
diff --git a/tex/context/modules/mkxl/x-mathml.mkxl b/tex/context/modules/mkxl/x-mathml.mkxl
index ea3052d2d..adabf777c 100644
--- a/tex/context/modules/mkxl/x-mathml.mkxl
+++ b/tex/context/modules/mkxl/x-mathml.mkxl
@@ -281,14 +281,14 @@
% simple version
-\newcount\@MMLlevel \def\MMLcreset{\@MMLlevel\zerocount}
+\newinteger\@MMLlevel \def\MMLcreset{\@MMLlevel\zerocount}
\lettonothing\MMLctempresetlist \def\setMMLcreset{\edef\MMLctempresetlist}
\let\MMLdoL\donothing
\let\MMLdoR\donothing
-\newcount\mmlapplydepth \def\MMLcreset{\mmlapplydepth\zerocount}
+\newinteger\mmlapplydepth \def\MMLcreset{\mmlapplydepth\zerocount}
\startxmlsetups mml:apply
\MMLmathinner {
@@ -302,7 +302,7 @@
\def\mmlapplyopentoken {(}
\def\mmlapplyclosetoken{)}
\fi
- \advance\mmlapplydepth\plusone
+ \advanceby\mmlapplydepth\plusone
\begingroup
\ifempty\mmlapplyopentoken
\let\MMLdoL\donothing
@@ -339,7 +339,7 @@
}
% }
\endgroup
- \advance\mmlapplydepth\minusone
+ \advanceby\mmlapplydepth\minusone
}
\stopxmlsetups
@@ -850,10 +850,10 @@
\setupMMLappearance [divide] [\c!level=\!!maxcard,\c!alternative=\v!a]
-\newcount\mmldividelevel
+\newinteger\mmldividelevel
\startxmlsetups mml:divide
- \advance\mmldividelevel\plusone
+ \advanceby\mmldividelevel\plusone
\doifelse \MMLdividealternative \v!b {
\mmlsecond{#1}/\mmlthird{#1}
} {
@@ -864,7 +864,7 @@
\mmlfrac{\MMLcreset\mmlsecond{#1}}{\MMLcreset\mmlthird{#1}}
\fi
}
- \advance\mmldividelevel\minusone
+ \advanceby\mmldividelevel\minusone
\stopxmlsetups
% min max
@@ -894,7 +894,7 @@
% reset check in case of (-x) + 37
% reset check in case of (-x) + 37
-\newcount\mmlpluscounter
+\newinteger\mmlpluscounter
\startxmlsetups mml:plus
\doifelse \MMLsignreduction \v!yes {
@@ -918,7 +918,7 @@
\stopxmlsetups
\startxmlsetups mml:plus:body
- \advance\mmlpluscounter\plusone
+ \advanceby\mmlpluscounter\plusone
\ifnum\mmlpluscounter>\plusone
\xmldoifelse{#1}{/mml:minus} {
\ifnum\xmlcount{#1}{/!mml:minus}>\plusone
@@ -935,7 +935,7 @@
\xmldirect{#1}
\stopxmlsetups
-\newcount\mmlminuscounter
+\newinteger\mmlminuscounter
\startsetups mml:minus
\doifelse \MMLsignreduction \v!yes {
@@ -965,7 +965,7 @@
\startxmlsetups mml:minus:body
% we can also use concat here
- \advance\mmlminuscounter\plusone
+ \advanceby\mmlminuscounter\plusone
\ifnum\mmlminuscounter>\plusone
-
\fi
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index d3fd3dbfe..460a6816f 100644
--- a/tex/generic/context/luatex/luatex-fonts-merged.lua
+++ b/tex/generic/context/luatex/luatex-fonts-merged.lua
@@ -1,6 +1,6 @@
-- merged file : c:/data/develop/context/sources/luatex-fonts-merged.lua
-- parent file : c:/data/develop/context/sources/luatex-fonts.lua
--- merge date : 2022-12-15 17:49
+-- merge date : 2022-12-21 17:10
do -- begin closure to overcome local limits and interference
@@ -16964,7 +16964,6 @@ local function getaxisscale(segments,minimum,default,maximum,user)
for i=1,#segments do
local s=segments[i]
if type(s)~="number" then
- report("using default axis scale")
return default
elseif s[1]>=default then
if s[2]==default then
@@ -19897,7 +19896,6 @@ function readers.hvar(f,fontdata,specification)
end
local tableoffset=gotodatatable(f,fontdata,"hvar",specification.variable)
if not tableoffset then
- report("no hvar table, expect problems due to messy widths")
return
end
local version=readulong(f)