diff options
21 files changed, 431 insertions, 157 deletions
diff --git a/context/data/scite/lexers/data/scite-context-data-context.lua b/context/data/scite/lexers/data/scite-context-data-context.lua index a6d97627f..0d577c8da 100644 --- a/context/data/scite/lexers/data/scite-context-data-context.lua +++ b/context/data/scite/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", "plussixteen", "plushundred", "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxdimen", "scaledpoint", "thousandpoint", "points", "halfpoint", "zeroskip", "zeromuskip", "onemuskip", "pluscxxvii", "pluscxxviii", "pluscclv", "pluscclvi", "normalpagebox", "endoflinetoken", "outputnewlinechar", "emptytoks", "empty", "undefined", "voidbox", "emptybox", "emptyvbox", "emptyhbox", "bigskipamount", "medskipamount", "smallskipamount", "fmtname", "fmtversion", "texengine", "texenginename", "texengineversion", "luatexengine", "pdftexengine", "xetexengine", "unknownengine", "etexversion", "pdftexversion", "xetexversion", "xetexrevision", "activecatcode", "bgroup", "egroup", "endline", "conditionaltrue", "conditionalfalse", "attributeunsetvalue", "uprotationangle", "rightrotationangle", "downrotationangle", "leftrotationangle", "inicatcodes", "ctxcatcodes", "texcatcodes", "notcatcodes", "txtcatcodes", "vrbcatcodes", "prtcatcodes", "nilcatcodes", "luacatcodes", "tpacatcodes", "tpbcatcodes", "xmlcatcodes", "escapecatcode", "begingroupcatcode", "endgroupcatcode", "mathshiftcatcode", "alignmentcatcode", "endoflinecatcode", "parametercatcode", "superscriptcatcode", "subscriptcatcode", "ignorecatcode", "spacecatcode", "lettercatcode", "othercatcode", "activecatcode", "commentcatcode", "invalidcatcode", "tabasciicode", "newlineasciicode", "formfeedasciicode", "endoflineasciicode", "endoffileasciicode", "spaceasciicode", "hashasciicode", "dollarasciicode", "commentasciicode", "ampersandasciicode", "colonasciicode", "backslashasciicode", "circumflexasciicode", "underscoreasciicode", "leftbraceasciicode", "barasciicode", "rightbraceasciicode", "tildeasciicode", "delasciicode", "lessthanasciicode", "morethanasciicode", "doublecommentsignal", "atsignasciicode", "exclamationmarkasciicode", "questionmarkasciicode", "doublequoteasciicode", "singlequoteasciicode", "forwardslashasciicode", "primeasciicode", "activemathcharcode", "activetabtoken", "activeformfeedtoken", "activeendoflinetoken", "batchmodecode", "nonstopmodecode", "scrollmodecode", "errorstopmodecode", "bottomlevelgroupcode", "simplegroupcode", "hboxgroupcode", "adjustedhboxgroupcode", "vboxgroupcode", "vtopgroupcode", "aligngroupcode", "noaligngroupcode", "outputgroupcode", "mathgroupcode", "discretionarygroupcode", "insertgroupcode", "vcentergroupcode", "mathchoicegroupcode", "semisimplegroupcode", "mathshiftgroupcode", "mathleftgroupcode", "vadjustgroupcode", "charnodecode", "hlistnodecode", "vlistnodecode", "rulenodecode", "insertnodecode", "marknodecode", "adjustnodecode", "ligaturenodecode", "discretionarynodecode", "whatsitnodecode", "mathnodecode", "gluenodecode", "kernnodecode", "penaltynodecode", "unsetnodecode", "mathsnodecode", "charifcode", "catifcode", "numifcode", "dimifcode", "oddifcode", "vmodeifcode", "hmodeifcode", "mmodeifcode", "innerifcode", "voidifcode", "hboxifcode", "vboxifcode", "xifcode", "eofifcode", "trueifcode", "falseifcode", "caseifcode", "definedifcode", "csnameifcode", "fontcharifcode", "fontslantperpoint", "fontinterwordspace", "fontinterwordstretch", "fontinterwordshrink", "fontexheight", "fontemwidth", "fontextraspace", "slantperpoint", "interwordspace", "interwordstretch", "interwordshrink", "exheight", "emwidth", "extraspace", "mathsupdisplay", "mathsupnormal", "mathsupcramped", "mathsubnormal", "mathsubcombined", "mathaxisheight", "startmode", "stopmode", "startnotmode", "stopnotmode", "startmodeset", "stopmodeset", "doifmode", "doifmodeelse", "doifnotmode", "startallmodes", "stopallmodes", "startnotallmodes", "stopnotallmodes", "doifallmodes", "doifallmodeselse", "doifnotallmodes", "startenvironment", "stopenvironment", "environment", "startcomponent", "stopcomponent", "component", "startproduct", "stopproduct", "product", "startproject", "stopproject", "project", "starttext", "stoptext", "startnotext", "stopnotext", "startdocument", "stopdocument", "documentvariable", "setupdocument", "startmodule", "stopmodule", "usemodule", "usetexmodule", "useluamodule", "setupmodule", "currentmoduleparameter", "moduleparameter", "startTEXpage", "stopTEXpage", "enablemode", "disablemode", "preventmode", "globalenablemode", "globaldisablemode", "globalpreventmode", "pushmode", "popmode", "typescriptone", "typescripttwo", "typescriptthree", "mathsizesuffix", "mathordcode", "mathopcode", "mathbincode", "mathrelcode", "mathopencode", "mathclosecode", "mathpunctcode", "mathalphacode", "mathinnercode", "mathnothingcode", "mathlimopcode", "mathnolopcode", "mathboxcode", "mathchoicecode", "mathaccentcode", "mathradicalcode", "constantnumber", "constantnumberargument", "constantdimen", "constantdimenargument", "constantemptyargument", "continueifinputfile", "luastringsep", "!!bs", "!!es", "lefttorightmark", "righttoleftmark", "breakablethinspace", "nobreakspace", "narrownobreakspace", "zerowidthnobreakspace", "ideographicspace", "ideographichalffillspace", "twoperemspace", "threeperemspace", "fourperemspace", "fiveperemspace", "sixperemspace", "figurespace", "punctuationspace", "hairspace", "zerowidthspace", "zerowidthnonjoiner", "zerowidthjoiner", "zwnj", "zwj" }, - ["helpers"]={ "startsetups", "stopsetups", "startxmlsetups", "stopxmlsetups", "startluasetups", "stopluasetups", "starttexsetups", "stoptexsetups", "startrawsetups", "stoprawsetups", "startlocalsetups", "stoplocalsetups", "starttexdefinition", "stoptexdefinition", "starttexcode", "stoptexcode", "startcontextcode", "stopcontextcode", "doifsetupselse", "doifsetups", "doifnotsetups", "setup", "setups", "texsetup", "xmlsetup", "luasetup", "directsetup", "doifelsecommandhandler", "doifnotcommandhandler", "doifcommandhandler", "newmode", "setmode", "resetmode", "newsystemmode", "setsystemmode", "resetsystemmode", "pushsystemmode", "popsystemmode", "booleanmodevalue", "newcount", "newdimen", "newskip", "newmuskip", "newbox", "newtoks", "newread", "newwrite", "newmarks", "newinsert", "newattribute", "newif", "newlanguage", "newfamily", "newfam", "newhelp", "then", "begcsname", "strippedcsname", "firstargumentfalse", "firstargumenttrue", "secondargumentfalse", "secondargumenttrue", "thirdargumentfalse", "thirdargumenttrue", "fourthargumentfalse", "fourthargumenttrue", "fifthargumentfalse", "fifthsargumenttrue", "sixthargumentfalse", "sixtsargumenttrue", "doglobal", "dodoglobal", "redoglobal", "resetglobal", "donothing", "dontcomplain", "forgetall", "donetrue", "donefalse", "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", "ruledhfilneg", "ruledhfillneg", "normalhfillneg", "ruledvss", "ruledvfil", "ruledvfill", "ruledvfilneg", "ruledvfillneg", "normalvfillneg", "ruledhbox", "ruledvbox", "ruledvtop", "ruledvcenter", "ruledmbox", "ruledhskip", "ruledvskip", "ruledkern", "ruledmskip", "ruledmkern", "ruledhglue", "ruledvglue", "normalhglue", "normalvglue", "ruledpenalty", "filledhboxb", "filledhboxr", "filledhboxg", "filledhboxc", "filledhboxm", "filledhboxy", "filledhboxk", "scratchcounter", "globalscratchcounter", "scratchdimen", "globalscratchdimen", "scratchskip", "globalscratchskip", "scratchmuskip", "globalscratchmuskip", "scratchtoks", "globalscratchtoks", "scratchbox", "globalscratchbox", "normalbaselineskip", "normallineskip", "normallineskiplimit", "availablehsize", "localhsize", "setlocalhsize", "nextbox", "dowithnextbox", "dowithnextboxcs", "dowithnextboxcontent", "dowithnextboxcontentcs", "scratchwidth", "scratchheight", "scratchdepth", "scratchoffset", "scratchdistance", "scratchhsize", "scratchvsize", "scratchxoffset", "scratchyoffset", "scratchhoffset", "scratchvoffset", "scratchxposition", "scratchyposition", "scratchtopoffset", "scratchbottomoffset", "scratchleftoffset", "scratchrightoffset", "scratchcounterone", "scratchcountertwo", "scratchcounterthree", "scratchdimenone", "scratchdimentwo", "scratchdimenthree", "scratchskipone", "scratchskiptwo", "scratchskipthree", "scratchmuskipone", "scratchmuskiptwo", "scratchmuskipthree", "scratchtoksone", "scratchtokstwo", "scratchtoksthree", "scratchboxone", "scratchboxtwo", "scratchboxthree", "scratchnx", "scratchny", "scratchmx", "scratchmy", "scratchunicode", "scratchleftskip", "scratchrightskip", "scratchtopskip", "scratchbottomskip", "doif", "doifnot", "doifelse", "doifinset", "doifnotinset", "doifinsetelse", "doifnextcharelse", "doifnextoptionalelse", "doifnextbgroupelse", "doifnextparenthesiselse", "doiffastoptionalcheckelse", "doifundefinedelse", "doifdefinedelse", "doifundefined", "doifdefined", "doifelsevalue", "doifvalue", "doifnotvalue", "doifnothing", "doifsomething", "doifelsenothing", "doifsomethingelse", "doifvaluenothing", "doifvaluesomething", "doifelsevaluenothing", "doifdimensionelse", "doifnumberelse", "doifnumber", "doifnotnumber", "doifcommonelse", "doifcommon", "doifnotcommon", "doifinstring", "doifnotinstring", "doifinstringelse", "doifassignmentelse", "docheckassignment", "tracingall", "tracingnone", "loggingall", "removetoks", "appendtoks", "prependtoks", "appendtotoks", "prependtotoks", "to", "endgraf", "endpar", "everyendpar", "reseteverypar", "finishpar", "empty", "null", "space", "quad", "enspace", "obeyspaces", "obeylines", "obeyedspace", "obeyedline", "normalspace", "executeifdefined", "singleexpandafter", "doubleexpandafter", "tripleexpandafter", "dontleavehmode", "removelastspace", "removeunwantedspaces", "keepunwantedspaces", "wait", "writestatus", "define", "defineexpandable", "redefine", "setmeasure", "setemeasure", "setgmeasure", "setxmeasure", "definemeasure", "freezemeasure", "measure", "measured", "installcorenamespace", "getvalue", "getuvalue", "setvalue", "setevalue", "setgvalue", "setxvalue", "letvalue", "letgvalue", "resetvalue", "undefinevalue", "ignorevalue", "setuvalue", "setuevalue", "setugvalue", "setuxvalue", "globallet", "glet", "udef", "ugdef", "uedef", "uxdef", "checked", "unique", "getparameters", "geteparameters", "getgparameters", "getxparameters", "forgetparameters", "copyparameters", "getdummyparameters", "dummyparameter", "directdummyparameter", "setdummyparameter", "letdummyparameter", "usedummystyleandcolor", "usedummystyleparameter", "usedummycolorparameter", "processcommalist", "processcommacommand", "quitcommalist", "quitprevcommalist", "processaction", "processallactions", "processfirstactioninset", "processallactionsinset", "unexpanded", "expanded", "startexpanded", "stopexpanded", "protected", "protect", "unprotect", "firstofoneargument", "firstoftwoarguments", "secondoftwoarguments", "firstofthreearguments", "secondofthreearguments", "thirdofthreearguments", "firstoffourarguments", "secondoffourarguments", "thirdoffourarguments", "fourthoffourarguments", "firstoffivearguments", "secondoffivearguments", "thirdoffivearguments", "fourthoffivearguments", "fifthoffivearguments", "firstofsixarguments", "secondofsixarguments", "thirdofsixarguments", "fourthofsixarguments", "fifthofsixarguments", "sixthofsixarguments", "firstofoneunexpanded", "gobbleoneargument", "gobbletwoarguments", "gobblethreearguments", "gobblefourarguments", "gobblefivearguments", "gobblesixarguments", "gobblesevenarguments", "gobbleeightarguments", "gobbleninearguments", "gobbletenarguments", "gobbleoneoptional", "gobbletwooptionals", "gobblethreeoptionals", "gobblefouroptionals", "gobblefiveoptionals", "dorecurse", "doloop", "exitloop", "dostepwiserecurse", "recurselevel", "recursedepth", "dofastloopcs", "dowith", "newconstant", "setnewconstant", "newconditional", "settrue", "setfalse", "setconstant", "newmacro", "setnewmacro", "newfraction", "newsignal", "dosingleempty", "dodoubleempty", "dotripleempty", "doquadrupleempty", "doquintupleempty", "dosixtupleempty", "doseventupleempty", "dosingleargument", "dodoubleargument", "dotripleargument", "doquadrupleargument", "doquintupleargument", "dosixtupleargument", "doseventupleargument", "dosinglegroupempty", "dodoublegroupempty", "dotriplegroupempty", "doquadruplegroupempty", "doquintuplegroupempty", "permitspacesbetweengroups", "dontpermitspacesbetweengroups", "nopdfcompression", "maximumpdfcompression", "normalpdfcompression", "modulonumber", "dividenumber", "getfirstcharacter", "doiffirstcharelse", "startnointerference", "stopnointerference", "twodigits", "threedigits", "leftorright", "strut", "setstrut", "strutbox", "strutht", "strutdp", "strutwd", "struthtdp", "begstrut", "endstrut", "lineheight", "ordordspacing", "ordopspacing", "ordbinspacing", "ordrelspacing", "ordopenspacing", "ordclosespacing", "ordpunctspacing", "ordinnerspacing", "opordspacing", "opopspacing", "opbinspacing", "oprelspacing", "opopenspacing", "opclosespacing", "oppunctspacing", "opinnerspacing", "binordspacing", "binopspacing", "binbinspacing", "binrelspacing", "binopenspacing", "binclosespacing", "binpunctspacing", "bininnerspacing", "relordspacing", "relopspacing", "relbinspacing", "relrelspacing", "relopenspacing", "relclosespacing", "relpunctspacing", "relinnerspacing", "openordspacing", "openopspacing", "openbinspacing", "openrelspacing", "openopenspacing", "openclosespacing", "openpunctspacing", "openinnerspacing", "closeordspacing", "closeopspacing", "closebinspacing", "closerelspacing", "closeopenspacing", "closeclosespacing", "closepunctspacing", "closeinnerspacing", "punctordspacing", "punctopspacing", "punctbinspacing", "punctrelspacing", "punctopenspacing", "punctclosespacing", "punctpunctspacing", "punctinnerspacing", "innerordspacing", "inneropspacing", "innerbinspacing", "innerrelspacing", "inneropenspacing", "innerclosespacing", "innerpunctspacing", "innerinnerspacing", "normalreqno", "startimath", "stopimath", "normalstartimath", "normalstopimath", "startdmath", "stopdmath", "normalstartdmath", "normalstopdmath", "uncramped", "cramped", "triggermathstyle", "mathstylefont", "mathsmallstylefont", "mathstyleface", "mathsmallstyleface", "mathstylecommand", "mathpalette", "mathstylehbox", "mathstylevbox", "mathstylevcenter", "mathstylevcenteredhbox", "mathstylevcenteredvbox", "mathtext", "setmathsmalltextbox", "setmathtextbox", "triggerdisplaystyle", "triggertextstyle", "triggerscriptstyle", "triggerscriptscriptstyle", "triggeruncrampedstyle", "triggercrampedstyle", "triggersmallstyle", "triggeruncrampedsmallstyle", "triggercrampedsmallstyle", "triggerbigstyle", "triggeruncrampedbigstyle", "triggercrampedbigstyle", "luaexpr", "expdoifelse", "expdoif", "expdoifnot", "expdoifcommonelse", "expdoifinsetelse", "ctxdirectlua", "ctxlatelua", "ctxsprint", "ctxwrite", "ctxcommand", "ctxdirectcommand", "ctxlatecommand", "ctxreport", "ctxlua", "luacode", "lateluacode", "directluacode", "registerctxluafile", "ctxloadluafile", "luaversion", "luamajorversion", "luaminorversion", "ctxluacode", "luaconditional", "luaexpanded", "startluaparameterset", "stopluaparameterset", "luaparameterset", "definenamedlua", "obeylualines", "obeyluatokens", "startluacode", "stopluacode", "startlua", "stoplua", "carryoverpar", "assumelongusagecs", "Umathbotaccent", "righttolefthbox", "lefttorighthbox", "righttoleftvbox", "lefttorightvbox", "righttoleftvtop", "lefttorightvtop", "rtlhbox", "ltrhbox", "rtlvbox", "ltrvbox", "rtlvtop", "ltrvtop", "autodirhbox", "autodirvbox", "autodirvtop", "lefttoright", "righttoleft", "synchronizelayoutdirection", "synchronizedisplaydirection", "synchronizeinlinedirection", "lesshyphens", "morehyphens", "nohyphens", "dohyphens", "Ucheckedstartdisplaymath", "Ucheckedstopdisplaymath" }, + ["helpers"]={ "startsetups", "stopsetups", "startxmlsetups", "stopxmlsetups", "startluasetups", "stopluasetups", "starttexsetups", "stoptexsetups", "startrawsetups", "stoprawsetups", "startlocalsetups", "stoplocalsetups", "starttexdefinition", "stoptexdefinition", "starttexcode", "stoptexcode", "startcontextcode", "stopcontextcode", "doifsetupselse", "doifsetups", "doifnotsetups", "setup", "setups", "texsetup", "xmlsetup", "luasetup", "directsetup", "doifelsecommandhandler", "doifnotcommandhandler", "doifcommandhandler", "newmode", "setmode", "resetmode", "newsystemmode", "setsystemmode", "resetsystemmode", "pushsystemmode", "popsystemmode", "booleanmodevalue", "newcount", "newdimen", "newskip", "newmuskip", "newbox", "newtoks", "newread", "newwrite", "newmarks", "newinsert", "newattribute", "newif", "newlanguage", "newfamily", "newfam", "newhelp", "then", "begcsname", "strippedcsname", "firstargumentfalse", "firstargumenttrue", "secondargumentfalse", "secondargumenttrue", "thirdargumentfalse", "thirdargumenttrue", "fourthargumentfalse", "fourthargumenttrue", "fifthargumentfalse", "fifthsargumenttrue", "sixthargumentfalse", "sixtsargumenttrue", "doglobal", "dodoglobal", "redoglobal", "resetglobal", "donothing", "dontcomplain", "forgetall", "donetrue", "donefalse", "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", "ruledhfilneg", "ruledhfillneg", "normalhfillneg", "ruledvss", "ruledvfil", "ruledvfill", "ruledvfilneg", "ruledvfillneg", "normalvfillneg", "ruledhbox", "ruledvbox", "ruledvtop", "ruledvcenter", "ruledmbox", "ruledhskip", "ruledvskip", "ruledkern", "ruledmskip", "ruledmkern", "ruledhglue", "ruledvglue", "normalhglue", "normalvglue", "ruledpenalty", "filledhboxb", "filledhboxr", "filledhboxg", "filledhboxc", "filledhboxm", "filledhboxy", "filledhboxk", "scratchcounter", "globalscratchcounter", "scratchdimen", "globalscratchdimen", "scratchskip", "globalscratchskip", "scratchmuskip", "globalscratchmuskip", "scratchtoks", "globalscratchtoks", "scratchbox", "globalscratchbox", "normalbaselineskip", "normallineskip", "normallineskiplimit", "availablehsize", "localhsize", "setlocalhsize", "nextbox", "dowithnextbox", "dowithnextboxcs", "dowithnextboxcontent", "dowithnextboxcontentcs", "scratchwidth", "scratchheight", "scratchdepth", "scratchoffset", "scratchdistance", "scratchhsize", "scratchvsize", "scratchxoffset", "scratchyoffset", "scratchhoffset", "scratchvoffset", "scratchxposition", "scratchyposition", "scratchtopoffset", "scratchbottomoffset", "scratchleftoffset", "scratchrightoffset", "scratchcounterone", "scratchcountertwo", "scratchcounterthree", "scratchdimenone", "scratchdimentwo", "scratchdimenthree", "scratchskipone", "scratchskiptwo", "scratchskipthree", "scratchmuskipone", "scratchmuskiptwo", "scratchmuskipthree", "scratchtoksone", "scratchtokstwo", "scratchtoksthree", "scratchboxone", "scratchboxtwo", "scratchboxthree", "scratchnx", "scratchny", "scratchmx", "scratchmy", "scratchunicode", "scratchleftskip", "scratchrightskip", "scratchtopskip", "scratchbottomskip", "doif", "doifnot", "doifelse", "doifinset", "doifnotinset", "doifinsetelse", "doifnextcharelse", "doifnextoptionalelse", "doifnextbgroupelse", "doifnextparenthesiselse", "doiffastoptionalcheckelse", "doifundefinedelse", "doifdefinedelse", "doifundefined", "doifdefined", "doifelsevalue", "doifvalue", "doifnotvalue", "doifnothing", "doifsomething", "doifelsenothing", "doifsomethingelse", "doifvaluenothing", "doifvaluesomething", "doifelsevaluenothing", "doifdimensionelse", "doifnumberelse", "doifnumber", "doifnotnumber", "doifcommonelse", "doifcommon", "doifnotcommon", "doifinstring", "doifnotinstring", "doifinstringelse", "doifassignmentelse", "docheckassignment", "tracingall", "tracingnone", "loggingall", "removetoks", "appendtoks", "prependtoks", "appendtotoks", "prependtotoks", "to", "endgraf", "endpar", "everyendpar", "reseteverypar", "finishpar", "empty", "null", "space", "quad", "enspace", "obeyspaces", "obeylines", "obeyedspace", "obeyedline", "normalspace", "executeifdefined", "singleexpandafter", "doubleexpandafter", "tripleexpandafter", "dontleavehmode", "removelastspace", "removeunwantedspaces", "keepunwantedspaces", "wait", "writestatus", "define", "defineexpandable", "redefine", "setmeasure", "setemeasure", "setgmeasure", "setxmeasure", "definemeasure", "freezemeasure", "measure", "measured", "installcorenamespace", "getvalue", "getuvalue", "setvalue", "setevalue", "setgvalue", "setxvalue", "letvalue", "letgvalue", "resetvalue", "undefinevalue", "ignorevalue", "setuvalue", "setuevalue", "setugvalue", "setuxvalue", "globallet", "glet", "udef", "ugdef", "uedef", "uxdef", "checked", "unique", "getparameters", "geteparameters", "getgparameters", "getxparameters", "forgetparameters", "copyparameters", "getdummyparameters", "dummyparameter", "directdummyparameter", "setdummyparameter", "letdummyparameter", "usedummystyleandcolor", "usedummystyleparameter", "usedummycolorparameter", "processcommalist", "processcommacommand", "quitcommalist", "quitprevcommalist", "processaction", "processallactions", "processfirstactioninset", "processallactionsinset", "unexpanded", "expanded", "startexpanded", "stopexpanded", "protected", "protect", "unprotect", "firstofoneargument", "firstoftwoarguments", "secondoftwoarguments", "firstofthreearguments", "secondofthreearguments", "thirdofthreearguments", "firstoffourarguments", "secondoffourarguments", "thirdoffourarguments", "fourthoffourarguments", "firstoffivearguments", "secondoffivearguments", "thirdoffivearguments", "fourthoffivearguments", "fifthoffivearguments", "firstofsixarguments", "secondofsixarguments", "thirdofsixarguments", "fourthofsixarguments", "fifthofsixarguments", "sixthofsixarguments", "firstofoneunexpanded", "gobbleoneargument", "gobbletwoarguments", "gobblethreearguments", "gobblefourarguments", "gobblefivearguments", "gobblesixarguments", "gobblesevenarguments", "gobbleeightarguments", "gobbleninearguments", "gobbletenarguments", "gobbleoneoptional", "gobbletwooptionals", "gobblethreeoptionals", "gobblefouroptionals", "gobblefiveoptionals", "dorecurse", "doloop", "exitloop", "dostepwiserecurse", "recurselevel", "recursedepth", "dofastloopcs", "dowith", "newconstant", "setnewconstant", "setconstant", "setconstantvalue", "newconditional", "settrue", "setfalse", "settruevalue", "setfalsevalue", "newmacro", "setnewmacro", "newfraction", "newsignal", "dosingleempty", "dodoubleempty", "dotripleempty", "doquadrupleempty", "doquintupleempty", "dosixtupleempty", "doseventupleempty", "dosingleargument", "dodoubleargument", "dotripleargument", "doquadrupleargument", "doquintupleargument", "dosixtupleargument", "doseventupleargument", "dosinglegroupempty", "dodoublegroupempty", "dotriplegroupempty", "doquadruplegroupempty", "doquintuplegroupempty", "permitspacesbetweengroups", "dontpermitspacesbetweengroups", "nopdfcompression", "maximumpdfcompression", "normalpdfcompression", "modulonumber", "dividenumber", "getfirstcharacter", "doiffirstcharelse", "startnointerference", "stopnointerference", "twodigits", "threedigits", "leftorright", "strut", "setstrut", "strutbox", "strutht", "strutdp", "strutwd", "struthtdp", "begstrut", "endstrut", "lineheight", "ordordspacing", "ordopspacing", "ordbinspacing", "ordrelspacing", "ordopenspacing", "ordclosespacing", "ordpunctspacing", "ordinnerspacing", "opordspacing", "opopspacing", "opbinspacing", "oprelspacing", "opopenspacing", "opclosespacing", "oppunctspacing", "opinnerspacing", "binordspacing", "binopspacing", "binbinspacing", "binrelspacing", "binopenspacing", "binclosespacing", "binpunctspacing", "bininnerspacing", "relordspacing", "relopspacing", "relbinspacing", "relrelspacing", "relopenspacing", "relclosespacing", "relpunctspacing", "relinnerspacing", "openordspacing", "openopspacing", "openbinspacing", "openrelspacing", "openopenspacing", "openclosespacing", "openpunctspacing", "openinnerspacing", "closeordspacing", "closeopspacing", "closebinspacing", "closerelspacing", "closeopenspacing", "closeclosespacing", "closepunctspacing", "closeinnerspacing", "punctordspacing", "punctopspacing", "punctbinspacing", "punctrelspacing", "punctopenspacing", "punctclosespacing", "punctpunctspacing", "punctinnerspacing", "innerordspacing", "inneropspacing", "innerbinspacing", "innerrelspacing", "inneropenspacing", "innerclosespacing", "innerpunctspacing", "innerinnerspacing", "normalreqno", "startimath", "stopimath", "normalstartimath", "normalstopimath", "startdmath", "stopdmath", "normalstartdmath", "normalstopdmath", "uncramped", "cramped", "triggermathstyle", "mathstylefont", "mathsmallstylefont", "mathstyleface", "mathsmallstyleface", "mathstylecommand", "mathpalette", "mathstylehbox", "mathstylevbox", "mathstylevcenter", "mathstylevcenteredhbox", "mathstylevcenteredvbox", "mathtext", "setmathsmalltextbox", "setmathtextbox", "triggerdisplaystyle", "triggertextstyle", "triggerscriptstyle", "triggerscriptscriptstyle", "triggeruncrampedstyle", "triggercrampedstyle", "triggersmallstyle", "triggeruncrampedsmallstyle", "triggercrampedsmallstyle", "triggerbigstyle", "triggeruncrampedbigstyle", "triggercrampedbigstyle", "luaexpr", "expdoifelse", "expdoif", "expdoifnot", "expdoifcommonelse", "expdoifinsetelse", "ctxdirectlua", "ctxlatelua", "ctxsprint", "ctxwrite", "ctxcommand", "ctxdirectcommand", "ctxlatecommand", "ctxreport", "ctxlua", "luacode", "lateluacode", "directluacode", "registerctxluafile", "ctxloadluafile", "luaversion", "luamajorversion", "luaminorversion", "ctxluacode", "luaconditional", "luaexpanded", "startluaparameterset", "stopluaparameterset", "luaparameterset", "definenamedlua", "obeylualines", "obeyluatokens", "startluacode", "stopluacode", "startlua", "stoplua", "carryoverpar", "assumelongusagecs", "Umathbotaccent", "righttolefthbox", "lefttorighthbox", "righttoleftvbox", "lefttorightvbox", "righttoleftvtop", "lefttorightvtop", "rtlhbox", "ltrhbox", "rtlvbox", "ltrvbox", "rtlvtop", "ltrvtop", "autodirhbox", "autodirvbox", "autodirvtop", "lefttoright", "righttoleft", "synchronizelayoutdirection", "synchronizedisplaydirection", "synchronizeinlinedirection", "lesshyphens", "morehyphens", "nohyphens", "dohyphens", "Ucheckedstartdisplaymath", "Ucheckedstopdisplaymath" }, }
\ No newline at end of file diff --git a/context/data/scite/scite-context-data-context.properties b/context/data/scite/scite-context-data-context.properties index a34390dd5..fbd958f8a 100644 --- a/context/data/scite/scite-context-data-context.properties +++ b/context/data/scite/scite-context-data-context.properties @@ -143,49 +143,49 @@ gobblethreearguments gobblefourarguments gobblefivearguments gobblesixarguments gobbleeightarguments gobbleninearguments gobbletenarguments gobbleoneoptional gobbletwooptionals \ gobblethreeoptionals gobblefouroptionals gobblefiveoptionals dorecurse doloop \ exitloop dostepwiserecurse recurselevel recursedepth dofastloopcs \ -dowith newconstant setnewconstant newconditional settrue \ -setfalse setconstant newmacro setnewmacro newfraction \ -newsignal dosingleempty dodoubleempty dotripleempty doquadrupleempty \ -doquintupleempty dosixtupleempty doseventupleempty dosingleargument dodoubleargument \ -dotripleargument doquadrupleargument doquintupleargument dosixtupleargument doseventupleargument \ -dosinglegroupempty dodoublegroupempty dotriplegroupempty doquadruplegroupempty doquintuplegroupempty \ -permitspacesbetweengroups dontpermitspacesbetweengroups nopdfcompression maximumpdfcompression normalpdfcompression \ -modulonumber dividenumber getfirstcharacter doiffirstcharelse startnointerference \ -stopnointerference twodigits threedigits leftorright strut \ -setstrut strutbox strutht strutdp strutwd \ -struthtdp begstrut endstrut lineheight ordordspacing \ -ordopspacing ordbinspacing ordrelspacing ordopenspacing ordclosespacing \ -ordpunctspacing ordinnerspacing opordspacing opopspacing opbinspacing \ -oprelspacing opopenspacing opclosespacing oppunctspacing opinnerspacing \ -binordspacing binopspacing binbinspacing binrelspacing binopenspacing \ -binclosespacing binpunctspacing bininnerspacing relordspacing relopspacing \ -relbinspacing relrelspacing relopenspacing relclosespacing relpunctspacing \ -relinnerspacing openordspacing openopspacing openbinspacing openrelspacing \ -openopenspacing openclosespacing openpunctspacing openinnerspacing closeordspacing \ -closeopspacing closebinspacing closerelspacing closeopenspacing closeclosespacing \ -closepunctspacing closeinnerspacing punctordspacing punctopspacing punctbinspacing \ -punctrelspacing punctopenspacing punctclosespacing punctpunctspacing punctinnerspacing \ -innerordspacing inneropspacing innerbinspacing innerrelspacing inneropenspacing \ -innerclosespacing innerpunctspacing innerinnerspacing normalreqno startimath \ -stopimath normalstartimath normalstopimath startdmath stopdmath \ -normalstartdmath normalstopdmath uncramped cramped triggermathstyle \ -mathstylefont mathsmallstylefont mathstyleface mathsmallstyleface mathstylecommand \ -mathpalette mathstylehbox mathstylevbox mathstylevcenter mathstylevcenteredhbox \ -mathstylevcenteredvbox mathtext setmathsmalltextbox setmathtextbox triggerdisplaystyle \ -triggertextstyle triggerscriptstyle triggerscriptscriptstyle triggeruncrampedstyle triggercrampedstyle \ -triggersmallstyle triggeruncrampedsmallstyle triggercrampedsmallstyle triggerbigstyle triggeruncrampedbigstyle \ -triggercrampedbigstyle luaexpr expdoifelse expdoif expdoifnot \ -expdoifcommonelse expdoifinsetelse ctxdirectlua ctxlatelua ctxsprint \ -ctxwrite ctxcommand ctxdirectcommand ctxlatecommand ctxreport \ -ctxlua luacode lateluacode directluacode registerctxluafile \ -ctxloadluafile luaversion luamajorversion luaminorversion ctxluacode \ -luaconditional luaexpanded startluaparameterset stopluaparameterset luaparameterset \ -definenamedlua obeylualines obeyluatokens startluacode stopluacode \ -startlua stoplua carryoverpar assumelongusagecs Umathbotaccent \ -righttolefthbox lefttorighthbox righttoleftvbox lefttorightvbox righttoleftvtop \ -lefttorightvtop rtlhbox ltrhbox rtlvbox ltrvbox \ -rtlvtop ltrvtop autodirhbox autodirvbox autodirvtop \ -lefttoright righttoleft synchronizelayoutdirection synchronizedisplaydirection synchronizeinlinedirection \ -lesshyphens morehyphens nohyphens dohyphens Ucheckedstartdisplaymath \ -Ucheckedstopdisplaymath +dowith newconstant setnewconstant setconstant setconstantvalue \ +newconditional settrue setfalse settruevalue setfalsevalue \ +newmacro setnewmacro newfraction newsignal dosingleempty \ +dodoubleempty dotripleempty doquadrupleempty doquintupleempty dosixtupleempty \ +doseventupleempty dosingleargument dodoubleargument dotripleargument doquadrupleargument \ +doquintupleargument dosixtupleargument doseventupleargument dosinglegroupempty dodoublegroupempty \ +dotriplegroupempty doquadruplegroupempty doquintuplegroupempty permitspacesbetweengroups dontpermitspacesbetweengroups \ +nopdfcompression maximumpdfcompression normalpdfcompression modulonumber dividenumber \ +getfirstcharacter doiffirstcharelse startnointerference stopnointerference twodigits \ +threedigits leftorright strut setstrut strutbox \ +strutht strutdp strutwd struthtdp begstrut \ +endstrut lineheight ordordspacing ordopspacing ordbinspacing \ +ordrelspacing ordopenspacing ordclosespacing ordpunctspacing ordinnerspacing \ +opordspacing opopspacing opbinspacing oprelspacing opopenspacing \ +opclosespacing oppunctspacing opinnerspacing binordspacing binopspacing \ +binbinspacing binrelspacing binopenspacing binclosespacing binpunctspacing \ +bininnerspacing relordspacing relopspacing relbinspacing relrelspacing \ +relopenspacing relclosespacing relpunctspacing relinnerspacing openordspacing \ +openopspacing openbinspacing openrelspacing openopenspacing openclosespacing \ +openpunctspacing openinnerspacing closeordspacing closeopspacing closebinspacing \ +closerelspacing closeopenspacing closeclosespacing closepunctspacing closeinnerspacing \ +punctordspacing punctopspacing punctbinspacing punctrelspacing punctopenspacing \ +punctclosespacing punctpunctspacing punctinnerspacing innerordspacing inneropspacing \ +innerbinspacing innerrelspacing inneropenspacing innerclosespacing innerpunctspacing \ +innerinnerspacing normalreqno startimath stopimath normalstartimath \ +normalstopimath startdmath stopdmath normalstartdmath normalstopdmath \ +uncramped cramped triggermathstyle mathstylefont mathsmallstylefont \ +mathstyleface mathsmallstyleface mathstylecommand mathpalette mathstylehbox \ +mathstylevbox mathstylevcenter mathstylevcenteredhbox mathstylevcenteredvbox mathtext \ +setmathsmalltextbox setmathtextbox triggerdisplaystyle triggertextstyle triggerscriptstyle \ +triggerscriptscriptstyle triggeruncrampedstyle triggercrampedstyle triggersmallstyle triggeruncrampedsmallstyle \ +triggercrampedsmallstyle triggerbigstyle triggeruncrampedbigstyle triggercrampedbigstyle luaexpr \ +expdoifelse expdoif expdoifnot expdoifcommonelse expdoifinsetelse \ +ctxdirectlua ctxlatelua ctxsprint ctxwrite ctxcommand \ +ctxdirectcommand ctxlatecommand ctxreport ctxlua luacode \ +lateluacode directluacode registerctxluafile ctxloadluafile luaversion \ +luamajorversion luaminorversion ctxluacode luaconditional luaexpanded \ +startluaparameterset stopluaparameterset luaparameterset definenamedlua obeylualines \ +obeyluatokens startluacode stopluacode startlua stoplua \ +carryoverpar assumelongusagecs Umathbotaccent righttolefthbox lefttorighthbox \ +righttoleftvbox lefttorightvbox righttoleftvtop lefttorightvtop rtlhbox \ +ltrhbox rtlvbox ltrvbox rtlvtop ltrvtop \ +autodirhbox autodirvbox autodirvtop lefttoright righttoleft \ +synchronizelayoutdirection synchronizedisplaydirection synchronizeinlinedirection lesshyphens morehyphens \ +nohyphens dohyphens Ucheckedstartdisplaymath Ucheckedstopdisplaymath diff --git a/scripts/context/lua/mtx-context.lua b/scripts/context/lua/mtx-context.lua index 9b620603e..90efb5225 100644 --- a/scripts/context/lua/mtx-context.lua +++ b/scripts/context/lua/mtx-context.lua @@ -256,8 +256,9 @@ end -- multipass control -local multipass_suffixes = { ".tuc" } -local multipass_nofruns = 8 -- or 7 to test oscillation +local multipass_suffixes = { ".tuc" } +local multipass_nofruns = 8 -- or 7 to test oscillation +local multipass_forcedruns = false local function multipass_hashfiles(jobname) local hash = { } @@ -693,6 +694,7 @@ function scripts.context.run(ctxdata,filename) c_flags.final = false c_flags.kindofrun = (a_once and 3) or (currentrun==1 and 1) or (currentrun==maxnofruns and 4) or 2 c_flags.maxnofruns = maxnofruns + c_flags.forcedruns = multipass_forcedruns and multipass_forcedruns > 0 and multipass_forcedruns or nil c_flags.currentrun = currentrun c_flags.noarrange = a_noarrange or a_arrange or nil -- @@ -710,10 +712,15 @@ function scripts.context.run(ctxdata,filename) break elseif returncode == 0 then multipass_copyluafile(jobname) - newhash = multipass_hashfiles(jobname) - if multipass_changed(oldhash,newhash) then - oldhash = newhash - else + if not multipass_forcedruns then + newhash = multipass_hashfiles(jobname) + if multipass_changed(oldhash,newhash) then + oldhash = newhash + else + break + end + elseif currentrun == multipass_forcedruns then + report("quitting after force %i runs",multipass_forcedruns) break end else @@ -1481,9 +1488,12 @@ do end if getargument("once") then - multipass_nofruns = 1 -elseif getargument("runs") then - multipass_nofruns = tonumber(getargument("runs")) or nil + multipass_nofruns = 1 +else + if getargument("runs") then + multipass_nofruns = tonumber(getargument("runs")) or nil + end + multipass_forcedruns = tonumber(getargument("forcedruns")) or nil end if getargument("run") then diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv index d20324a2b..e01596804 100644 --- a/tex/context/base/cont-new.mkiv +++ b/tex/context/base/cont-new.mkiv @@ -11,7 +11,7 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\newcontextversion{2014.01.30 12:15} +\newcontextversion{2014.01.30 22:19} %D This file is loaded at runtime, thereby providing an excellent place for %D hacks, patches, extensions and new features. diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf Binary files differindex 79cb94d0e..337e02978 100644 --- a/tex/context/base/context-version.pdf +++ b/tex/context/base/context-version.pdf diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv index 888d78583..db52afdf5 100644 --- a/tex/context/base/context.mkiv +++ b/tex/context/base/context.mkiv @@ -28,7 +28,7 @@ %D up and the dependencies are more consistent. \edef\contextformat {\jobname} -\edef\contextversion{2014.01.30 12:15} +\edef\contextversion{2014.01.30 22:19} \edef\contextkind {beta} %D For those who want to use this: diff --git a/tex/context/base/core-env.lua b/tex/context/base/core-env.lua index a4d1fdd92..8cbc93038 100644 --- a/tex/context/base/core-env.lua +++ b/tex/context/base/core-env.lua @@ -78,6 +78,15 @@ setmetatableindex(tex.ifs, function(t,k) return csname_id(k) ~= undefined and create(k)[2] == iftrue -- inefficient, this create, we need a helper end) +function context.setconditional(name,value) + if value then + context.settruevalue(name) + else + context.setfalsevalue(name) + end +end + + -- todo : global -- not possible as we let at the tex end to zerocount and plusone diff --git a/tex/context/base/core-sys.mkiv b/tex/context/base/core-sys.mkiv index 8f56b6f16..c07722f56 100644 --- a/tex/context/base/core-sys.mkiv +++ b/tex/context/base/core-sys.mkiv @@ -89,6 +89,8 @@ % \ctxcommand{updatefilenames("\jobame","\inputfilename","\outputfilename")}% % \to \everysetupsystem +\newconditional\prerollrun % when true it means that we have a forced number of runs + % Some mechanisms (see x-res-01) use either \jobfilename or % \jobfilename.somesuffix, in which case we need to use the % full name if given or a default (like \jobfilename.xml); diff --git a/tex/context/base/file-job.lua b/tex/context/base/file-job.lua index 288a690d2..c88eb7e9d 100644 --- a/tex/context/base/file-job.lua +++ b/tex/context/base/file-job.lua @@ -801,23 +801,45 @@ function commands.getcommandline() -- has to happen at the tex end in order to e inputfile = basename(inputfile) end + local forcedruns = arguments.forcedruns local kindofrun = arguments.kindofrun - local currentrun = arguments.maxnofruns - local maxnofruns = arguments.currentrun + local currentrun = arguments.currentrun + local maxnofruns = arguments.maxnofruns or arguments.runs + + -- context.setupsystem { + -- [constants.directory] = validstring(arguments.setuppath), + -- [constants.inputfile] = inputfile, + -- [constants.file] = validstring(arguments.result), + -- [constants.random] = validstring(arguments.randomseed), + -- -- old: + -- [constants.n] = validstring(kindofrun), + -- [constants.m] = validstring(currentrun), + -- } context.setupsystem { - [constants.directory] = validstring(arguments.setuppath), - [constants.inputfile] = inputfile, - [constants.file] = validstring(arguments.result), - [constants.random] = validstring(arguments.randomseed), + directory = validstring(arguments.setuppath), + inputfile = inputfile, + file = validstring(arguments.result), + random = validstring(arguments.randomseed), -- old: - [constants.n] = validstring(kindofrun), - [constants.m] = validstring(currentrun), + n = validstring(kindofrun), + m = validstring(currentrun), } - environment.kindofrun = tonumber(kindofrun) or 0 - environment.maxnofruns = tonumber(maxnofruns) or 0 - environment.currentrun = tonumber(currentrun) or 0 + forcedruns = tonumber(forcedruns) or 0 + kindofrun = tonumber(kindofrun) or 0 + maxnofruns = tonumber(maxnofruns) or 0 + currentrun = tonumber(currentrun) or 0 + + local prerollrun = forcedruns > 0 and currentrun > 0 and currentrun < forcedruns + + environment.forcedruns = forcedruns + environment.kindofrun = kindofrun + environment.maxnofruns = maxnofruns + environment.currentrun = currentrun + environment.prerollrun = prerollrun + + context.setconditional("prerollrun",prerollrun) if validstring(arguments.arguments) then context.setupenv { arguments.arguments } diff --git a/tex/context/base/mult-low.lua b/tex/context/base/mult-low.lua index 1e4fef212..250b20c22 100644 --- a/tex/context/base/mult-low.lua +++ b/tex/context/base/mult-low.lua @@ -279,7 +279,9 @@ return { -- "dorecurse", "doloop", "exitloop", "dostepwiserecurse", "recurselevel", "recursedepth", "dofastloopcs", "dowith", -- - "newconstant", "setnewconstant", "newconditional", "settrue", "setfalse", "setconstant", + "newconstant", "setnewconstant", "setconstant", "setconstantvalue", + "newconditional", "settrue", "setfalse", "settruevalue", "setfalsevalue", + -- "newmacro", "setnewmacro", "newfraction", "newsignal", -- diff --git a/tex/context/base/page-brk.mkiv b/tex/context/base/page-brk.mkiv index cc9a9b4d2..2b89f5b4f 100644 --- a/tex/context/base/page-brk.mkiv +++ b/tex/context/base/page-brk.mkiv @@ -316,75 +316,204 @@ %D Test page breaks. -\newdimen \d_page_tests_test -\newconstant\c_page_tests_mode +% \newdimen \d_page_tests_test +% \newconstant\c_page_tests_mode -\newconstant\testpagemethod % todo: \testnewpage[method=,lines=,voffset=] -\newconstant\testpagetrigger +\newconstant\testpagemethod % old +\newconstant\testpagetrigger % old -\unexpanded\def\testpage {\c_page_tests_mode\plusone \dodoubleempty\page_tests_test} % -\unexpanded\def\testpageonly{\c_page_tests_mode\plustwo \dodoubleempty\page_tests_test} % no penalties added to the mvl -\unexpanded\def\testpagesync{\c_page_tests_mode\plusthree\dodoubleempty\page_tests_test} % force sync - -\def\page_tests_test[#1][#2]% don't change, only add more methods +% \unexpanded\def\testpage {\c_page_tests_mode\plusone \dodoubleempty\page_tests_test} % +% \unexpanded\def\testpageonly{\c_page_tests_mode\plustwo \dodoubleempty\page_tests_test} % no penalties added to the mvl +% \unexpanded\def\testpagesync{\c_page_tests_mode\plusthree\dodoubleempty\page_tests_test} % force sync +% +% \def\page_tests_test[#1][#2]% don't change, only add more methods +% {\relax % needed before \if +% \ifconditional\c_page_breaks_enabled +% % new from here +% \ifcase\testpagetrigger +% \endgraf +% \or\ifvmode +% \dosomebreak\allowbreak +% \else % indeed? +% \vadjust{\allowbreak}% +% \endgraf +% \fi\fi +% % till here +% \ifdim\pagegoal<\maxdimen \relax +% \ifdim\pagetotal<\pagegoal \relax +% \d_page_tests_test\dimexpr +% #1\lineheight +% +\pagetotal +% \ifdim\lastskip<\parskip+\parskip\fi +% \ifsecondargument+#2\fi +% \relax +% \ifcase\testpagemethod +% \ifdim\d_page_tests_test>.99\pagegoal +% \penalty-\plustenthousand +% \fi +% \or +% \ifdim\dimexpr\d_page_tests_test-\pagegoal\relax>-\lineheight +% \penalty-\plustenthousand +% \fi +% \or +% \getnoflines\pagegoal +% \ifdim\dimexpr\d_page_tests_test-\noflines\lineheight\relax>-\lineheight +% \penalty-\plustenthousand +% \fi +% \or % same as 0 but more accurate +% \ifdim\dimexpr\d_page_tests_test-10\scaledpoint\relax>\pagegoal +% \penalty-\plustenthousand +% \fi +% \fi +% \else\ifnum\c_page_tests_mode=\plusthree +% \page_tests_flush_so_far +% \fi\fi +% \else\ifnum\c_page_tests_mode=\plusone +% \goodbreak +% \fi\fi +% \else +% \endgraf +% \fi} +% +% \def\page_tests_flush_so_far +% {\endgraf +% \ifdim\pagetotal>\pagegoal +% \ifdim\dimexpr\pagetotal-\pageshrink\relax>\pagegoal +% \goodbreak +% \else +% \page +% \fi +% \fi} + +\installcorenamespace {pagechecker} +\installcorenamespace {pagecheckermethod} + +\installcommandhandler \??pagechecker {pagechecker} \??pagechecker + +\setuppagechecker + [\c!method=1, + \c!before=, + \c!after=, + \c!inbetween=, + \c!lines=\plusthree, + \c!offset=\zeropoint] + +\def\page_check_amount + {\dimexpr + \pagecheckerparameter\c!lines\lineheight + +\pagetotal + \ifdim\lastskip<\parskip+\parskip\fi + \ifsecondargument+\pagecheckerparameter\v!offset\fi + \relax} + +\unexpanded\def\checkpage + {\dodoubleempty\page_check} + +\def\page_check[#1][#2]% {\relax % needed before \if + \endgraf \ifconditional\c_page_breaks_enabled - % new from here - \ifcase\testpagetrigger - \endgraf - \or\ifvmode - \dosomebreak\allowbreak - \else % indeed? - \vadjust{\allowbreak}% - \endgraf - \fi\fi - % till here - \ifdim\pagegoal<\maxdimen \relax - \ifdim\pagetotal<\pagegoal \relax - \d_page_tests_test\dimexpr - #1\lineheight - +\pagetotal - \ifdim\lastskip<\parskip+\parskip\fi - \ifsecondargument+#2\fi - \relax - \ifcase\testpagemethod - \ifdim\d_page_tests_test>.99\pagegoal - \penalty-\plustenthousand - \fi - \or - \ifdim\dimexpr\d_page_tests_test-\pagegoal\relax>-\lineheight - \penalty-\plustenthousand - \fi - \or - \getnoflines\pagegoal - \ifdim\dimexpr\d_page_tests_test-\noflines\lineheight\relax>-\lineheight - \penalty-\plustenthousand - \fi - \or % same as 0 but more accurate - \ifdim\dimexpr\d_page_tests_test-10\scaledpoint\relax>\pagegoal - \penalty-\plustenthousand - \fi - \fi - \else\ifnum\c_page_tests_mode=\plusthree - \page_tests_flush_so_far - \fi\fi - \else\ifnum\c_page_tests_mode=\plusone - \goodbreak - \fi\fi + \begingroup + \edef\currentpagechecker{#1}% + \ifsecondargument\setupcurrentpagechecker[#2]\fi + \csname\??pagecheckermethod\pagecheckerparameter\c!method\endcsname + \endgroup + \fi} + +\setvalue{\??pagecheckermethod 0}% + {\ifdim\pagegoal<\maxdimen \relax + \ifdim\pagetotal<\pagegoal \relax + \ifdim\page_check_amount>.99\pagegoal + \pagecheckerparameter\c!before + \penalty-\plustenthousand + \pagecheckerparameter\c!after + \else + \pagecheckerparameter\c!inbetween + \fi + \else + \pagecheckerparameter\c!inbetween + \fi \else - \endgraf + \pagecheckerparameter\c!inbetween \fi} -\def\page_tests_flush_so_far - {\endgraf - \ifdim\pagetotal>\pagegoal - \ifdim\dimexpr\pagetotal-\pageshrink\relax>\pagegoal - \goodbreak +\setvalue{\??pagecheckermethod 1}% + {\ifdim\pagegoal<\maxdimen \relax + \ifdim\pagetotal<\pagegoal \relax + \ifdim\dimexpr\page_check_amount-\pagegoal\relax>-\lineheight + \pagecheckerparameter\c!before + \penalty-\plustenthousand + \pagecheckerparameter\c!after + \else + \pagecheckerparameter\c!inbetween + \fi \else - \page + \pagecheckerparameter\c!inbetween \fi + \else + \goodbreak + \pagecheckerparameter\c!inbetween \fi} +\setvalue{\??pagecheckermethod 2}% + {\ifdim\pagegoal<\maxdimen \relax + \ifdim\pagetotal<\pagegoal \relax + \getnoflines\pagegoal + \ifdim\dimexpr\page_check_amount-\noflines\lineheight\relax>-\lineheight + \pagecheckparameter\c!before + \penalty-\plustenthousand + \pagecheckerparameter\c!after + \else + \pagecheckerparameter\c!inbetween + \fi + \else + \pagecheckerparameter\c!inbetween + \fi + \else + \pagecheckerparameter\c!inbetween + \fi} + +\setvalue{\??pagecheckermethod 3}% + {\ifdim\pagegoal<\maxdimen \relax + \ifdim\pagetotal<\pagegoal \relax + \ifdim\dimexpr\page_check_amount-10\scaledpoint\relax>\pagegoal + \pagecheckerparameter\c!before + \penalty-\plustenthousand + \pagecheckerparameter\c!after + \else + \pagecheckerparameter\c!inbetween + \fi + \else + \ifdim\pagetotal>\pagegoal + \ifdim\dimexpr\pagetotal-\pageshrink\relax>\pagegoal + \goodbreak + \pagecheckerparameter\c!inbetween + \else + \pagecheckerparameter\c!before + \page + \pagecheckerparameter\c!after + \fi + \else + \pagecheckerparameter\c!inbetween + \fi + \fi + \else + \pagecheckerparameter\c!inbetween + \fi} + +\definepagechecker[\s!unknown:0] [\c!method=0,\c!before=,\c!after=,\c!inbetween=] +\definepagechecker[\s!unknown:1][]\s!unknown:0][\c!method=1] +\definepagechecker[\s!unknown:2][]\s!unknown:0][\c!method=2] +\definepagechecker[\s!unknown:3][]\s!unknown:0][\c!method=3] + +\def\page_tests_test_a[#1][#2]{\checkpage[\s!unknown:1][\c!lines=#1,\c!voffset=\ifsecondargument#2\else\zeropoint\fi]} +\def\page_tests_test_b[#1][#2]{\checkpage[\s!unknown:2][\c!lines=#1,\c!voffset=\ifsecondargument#2\else\zeropoint\fi]} +\def\page_tests_test_c[#1][#2]{\checkpage[\s!unknown:3][\c!lines=#1,\c!voffset=\ifsecondargument#2\else\zeropoint\fi]} + +\unexpanded\def\testpage {\dodoubleempty\page_tests_test_a} % +\unexpanded\def\testpageonly{\dodoubleempty\page_tests_test_b} % no penalties added to the mvl +\unexpanded\def\testpagesync{\dodoubleempty\page_tests_test_c} % force sync + %D Test column breaks. \unexpanded\def\testcolumn diff --git a/tex/context/base/publ-aut.lua b/tex/context/base/publ-aut.lua index 9fe286abf..ba492a93b 100644 --- a/tex/context/base/publ-aut.lua +++ b/tex/context/base/publ-aut.lua @@ -455,7 +455,6 @@ end local compare = sorters.comparers.basic -- (a,b) local strip = sorters.strip local splitter = sorters.splitters.utf -local sort = sorters.sort function authors.preparedsort(dataset,list,sorttype_a,sorttype_b,sorttype_c) local luadata = datasets[dataset].luadata diff --git a/tex/context/base/publ-dat.lua b/tex/context/base/publ-dat.lua index 20fada411..8fce94822 100644 --- a/tex/context/base/publ-dat.lua +++ b/tex/context/base/publ-dat.lua @@ -446,7 +446,7 @@ function publications.load(dataset,filename,kind) if dataset.loaded[fullname] then -- will become better -- skip elseif fullname == "" then - report("no file %a",fullname) + report("no file %a",filename) else loaders[filetype](dataset,fullname) end diff --git a/tex/context/base/publ-imp-apa.mkiv b/tex/context/base/publ-imp-apa.mkiv index 2db044cbf..3f7b119af 100644 --- a/tex/context/base/publ-imp-apa.mkiv +++ b/tex/context/base/publ-imp-apa.mkiv @@ -12,7 +12,7 @@ % common -\loadbtxdefinitionfile[def] +% \loadbtxdefinitionfile[def] \startsetups btx:apa:common:wherefrom \btxdoifelse {address} { diff --git a/tex/context/base/publ-ini.lua b/tex/context/base/publ-ini.lua index 534bca72e..7c3670208 100644 --- a/tex/context/base/publ-ini.lua +++ b/tex/context/base/publ-ini.lua @@ -56,7 +56,6 @@ local basiccompare = sorters.basicsorter -- (a,b) local compare = sorters.comparers.basic -- (a,b) local strip = sorters.strip local splitter = sorters.splitters.utf -local sort = sorters.sort local context = context @@ -803,7 +802,7 @@ lists.sorters = { -- nothing to sort else -- if needed we can wrap compare and use the list directly but this is cleaner - sort(valid,compare) + sorters.sort(valid,compare) for i=1,#valid do local v = valid[i] valid[i] = list[v.index] @@ -1049,7 +1048,7 @@ local function sortedtags(dataset,list,sorttype) if #valid == 0 or #valid ~= #list then return list else - sort(valid,basiccompare) + sorters.sort(valid,basiccompare) for i=1,#valid do valid[i] = valid[i].tag end diff --git a/tex/context/base/s-inf-03.pdf b/tex/context/base/s-inf-03.pdf Binary files differindex 56e5500ef..ed1d6e12a 100644 --- a/tex/context/base/s-inf-03.pdf +++ b/tex/context/base/s-inf-03.pdf diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf Binary files differindex 31e92ca46..2752ed563 100644 --- a/tex/context/base/status-files.pdf +++ b/tex/context/base/status-files.pdf diff --git a/tex/context/base/status-lua.log b/tex/context/base/status-lua.log index 3739a8ad0..e9ce12329 100644 --- a/tex/context/base/status-lua.log +++ b/tex/context/base/status-lua.log @@ -1,6 +1,6 @@ (cont-yes.mkiv -ConTeXt ver: 2014.01.30 12:15 MKIV beta fmt: 2014.1.30 int: english/english +ConTeXt ver: 2014.01.30 22:19 MKIV beta fmt: 2014.1.30 int: english/english system > 'cont-new.mkiv' loaded (cont-new.mkiv) diff --git a/tex/context/base/syst-ini.mkiv b/tex/context/base/syst-ini.mkiv index ab1c53131..38c34556a 100644 --- a/tex/context/base/syst-ini.mkiv +++ b/tex/context/base/syst-ini.mkiv @@ -246,9 +246,10 @@ % Watch out, for the moment we disable the check for already being defined % later we will revert this but first all chardefs must be replaced. -\normalprotected\def\newconstant #1{\ifdefined#1\let#1\undefined\fi\newcount#1} -\normalprotected\def\setnewconstant#1{\ifdefined#1\let#1\undefined\fi\newcount#1#1} % just a number -\normalprotected\def\setconstant {} % dummy, no checking, so it warns +\normalprotected\def\newconstant #1{\ifdefined#1\let#1\undefined\fi\newcount#1} +\normalprotected\def\setnewconstant #1{\ifdefined#1\let#1\undefined\fi\newcount#1#1} % just a number +\normalprotected\def\setconstant {} % dummy, no checking, so it warns +\normalprotected\def\setconstantvalue#1#2{\csname#1\endcsname\numexpr#2\relax} % maybe setconstant with check @@ -744,6 +745,9 @@ \normalprotected\def\settrue #1{\let#1\conditionaltrue } \normalprotected\def\setfalse#1{\let#1\conditionalfalse} +\normalprotected\def\settruevalue #1{\expandafter\let\csname#1\endcsname\conditionaltrue } +\normalprotected\def\setfalsevalue#1{\expandafter\let\csname#1\endcsname\conditionalfalse} + \let\newconditional\setfalse \let\ifconditional \ifcase diff --git a/tex/context/base/type-imp-buy.mkiv b/tex/context/base/type-imp-buy.mkiv index 9815cc44b..dbfffe57c 100644 --- a/tex/context/base/type-imp-buy.mkiv +++ b/tex/context/base/type-imp-buy.mkiv @@ -11,27 +11,125 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. +% monotype sabon + \starttypescriptcollection[sabon] -\starttypescript [serif] [sabon] [name] - - \definefontsynonym [Serif] [SabonMT] - \definefontsynonym [SerifItalic] [SabonMT-Italic] - \definefontsynonym [SerifSlanted] [SabonMT-Italic] - \definefontsynonym [SerifBold] [SabonMT-SemiBold] - \definefontsynonym [SerifBoldItalic] [SabonMT-SemiBoldItalic] - \definefontsynonym [SerifBoldSlanted] [SabonMT-SemiBoldItalic] - \definefontsynonym [SerifCaps] [SabonMT-RegularSC] - - \definefontsynonym[SabonMT] [sab_____] - \definefontsynonym[SabonMT-Italic] [sabi____] - \definefontsynonym[SabonMT-ItalicOsF] [saboi___] - \definefontsynonym[SabonMT-SemiBoldOsF] [sabos___] - \definefontsynonym[SabonMT-SemiBold] [sabs____] - \definefontsynonym[SabonMT-RegularSC] [sabsc___] - \definefontsynonym[SabonMT-SemiBoldItalic] [sabsi___] - \definefontsynonym[SabonMT-SemiBoldItalicOsF][sasio___] -\stoptypescript + \starttypescript [serif] [sabon] [name] + % + \definefontsynonym [Serif] [SabonMT] + \definefontsynonym [SerifItalic] [SabonMT-Italic] + \definefontsynonym [SerifSlanted] [SabonMT-Italic] + \definefontsynonym [SerifBold] [SabonMT-SemiBold] + \definefontsynonym [SerifBoldItalic] [SabonMT-SemiBoldItalic] + \definefontsynonym [SerifBoldSlanted][SabonMT-SemiBoldItalic] + \definefontsynonym [SerifCaps] [SabonMT-RegularSC] + % + \definefontsynonym[SabonMT] [sab_____] + \definefontsynonym[SabonMT-Italic] [sabi____] + \definefontsynonym[SabonMT-ItalicOsF] [saboi___] + \definefontsynonym[SabonMT-SemiBoldOsF] [sabos___] + \definefontsynonym[SabonMT-SemiBold] [sabs____] + \definefontsynonym[SabonMT-RegularSC] [sabsc___] + \definefontsynonym[SabonMT-SemiBoldItalic] [sabsi___] + \definefontsynonym[SabonMT-SemiBoldItalicOsF][sasio___] + % + \stoptypescript \stoptypescriptcollection +% itc stone + +\starttypescriptcollection[stone] + + \starttypescript [sans] [stone] [name] + % + \definefontsynonym [Sans] [StoneSansITC-Medium] + \definefontsynonym [SansItalic] [StoneSansITC-MediumItalic] + \definefontsynonym [SansSlanted] [StoneSansITC-MediumItalic] + \definefontsynonym [SansBold] [StoneSansITC-Bold] + \definefontsynonym [SansBoldItalic] [StoneSansITC-BoldItalic] + \definefontsynonym [SansBoldSlanted][StoneSansITC-BoldItalic] + \definefontsynonym [SansCaps] [StoneSansSCITC-Medium] + % + \definefontsynonym[StoneSansITC-Bold] [stosnb] + \definefontsynonym[StoneSansITC-BoldItalic] [stosnbi] + \definefontsynonym[StoneSansITC-Medium] [stosnm] + \definefontsynonym[StoneSansITC-MediumItalic][stosnmi] + \definefontsynonym[StoneSansSemITC-Semi] [stosns] + \definefontsynonym[StoneSansSemITC-SemiIta] [stosnsi] + \definefontsynonym[StoneSansSCITC-Medium] [stosnscm] + \definefontsynonym[StoneSansSemSCITC-Semi] [stosnscs] + % + \stoptypescript + + \starttypescript [serif] [stone] [name] + % + \definefontsynonym [Serif] [StoneSerifITC-Medium] + \definefontsynonym [SerifItalic] [StoneSerifITC-MediumItalic] + \definefontsynonym [SerifSlanted] [StoneSerifITC-MediumItalic] + \definefontsynonym [SerifBold] [StoneSerifITC-Bold] + \definefontsynonym [SerifBoldItalic] [StoneSerifITC-BoldItalic] + \definefontsynonym [SerifBoldSlanted][StoneSerifITC-BoldItalic] + \definefontsynonym [SerifCaps] [StoneSerifSCITC-Medium] + % + \definefontsynonym[StoneSerifITC-Bold] [stosfb] + \definefontsynonym[StoneSerifITC-BoldItalic] [stosfbi] + \definefontsynonym[StoneSerifITC-Medium] [stosfm] + \definefontsynonym[StoneSerifITC-MediumItalic][stosfmi] + \definefontsynonym[StoneSerifSemITC-Semi] [stosfs] + \definefontsynonym[StoneSerifSemITC-SemiIta] [stosfsi] + \definefontsynonym[StoneSerifSCITC-Medium] [stosfscm] + \definefontsynonym[StoneSerifSemSCITC-Semi] [stosfscs] + % + \stoptypescript + + \starttypescript [sans] [stone-oldstyle] [name] + % + \definefontsynonym [Sans] [StoneSansOSITC-Medium] + \definefontsynonym [SansItalic] [StoneSansOSITC-MediumItalic] + \definefontsynonym [SansSlanted] [StoneSansOSITC-MediumItalic] + \definefontsynonym [SansBold] [StoneSansOSITC-Bold] + \definefontsynonym [SansBoldItalic] [StoneSansOSITC-BoldItalic] + \definefontsynonym [SansBoldSlanted][StoneSansOSITC-BoldItalic] + \definefontsynonym [SansCaps] [StoneSansSCITC-Medium] + % + \definefontsynonym[StoneSansOSITC-Bold] [stosnob] + \definefontsynonym[StoneSansOSITC-BoldItalic] [stosnobi] + \definefontsynonym[StoneSansOSITC-Medium] [stosnom] + \definefontsynonym[StoneSansOSITC-MediumItalic][stosnomi] + \definefontsynonym[StoneSansSemOSITC-Semi] [stosnos] + \definefontsynonym[StoneSansSemOSITC-SemiIta] [stosnosi] + % + \stoptypescript + + \starttypescript [serif] [stone-oldstyle] [name] + % + \definefontsynonym [Serif] [StoneSerifOSITC-Medium] + \definefontsynonym [SerifItalic] [StoneSerifOSITC-MediumItalic] + \definefontsynonym [SerifSlanted] [StoneSerifOSITC-MediumItalic] + \definefontsynonym [SerifBold] [StoneSerifOSITC-Bold] + \definefontsynonym [SerifBoldItalic] [StoneSerifOSITC-BoldItalic] + \definefontsynonym [SerifBoldSlanted] [StoneSerifOSITC-BoldItalic] + \definefontsynonym [SerifCaps] [StoneSerifSCITC-Medium] + % + \definefontsynonym[StoneSerifOSITC-Bold] [stosfob] + \definefontsynonym[StoneSerifOSITC-BoldItalic] [stosfobi] + \definefontsynonym[StoneSerifOSITC-Medium] [stosfom] + \definefontsynonym[StoneSerifOSITC-MediumItalic][stosfomi] + \definefontsynonym[StoneSerifSemOSITC-Semi] [stosfos] + \definefontsynonym[StoneSerifSemOSITC-SemiIta] [stosfosi] + % + \stoptypescript + +\stoptypescriptcollection + +% linotype industria + +\starttypescriptcollection[industria] + + \starttypescript [sans] [industria] [name] + \definefontsynonym[Industria-Solid][lt_50545] + \stoptypescript + +\stoptypescriptcollection diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua index 46b528289..2c3daf4be 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 : luatex-fonts-merged.lua -- parent file : luatex-fonts.lua --- merge date : 01/30/14 12:15:34 +-- merge date : 01/30/14 22:19:30 do -- begin closure to overcome local limits and interference |