From 1964c078d21c5f1d19a84fa6ef5c038f8ee80652 Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Wed, 12 Oct 2016 20:30:59 +0200 Subject: 2016-10-12 17:32:00 --- tex/context/base/mkii/cont-new.mkii | 2 +- tex/context/base/mkii/context.mkii | 2 +- tex/context/base/mkii/mult-cs.mkii | 2 + tex/context/base/mkii/mult-de.mkii | 2 + tex/context/base/mkii/mult-en.mkii | 2 + tex/context/base/mkii/mult-fr.mkii | 2 + tex/context/base/mkii/mult-it.mkii | 2 + tex/context/base/mkii/mult-nl.mkii | 2 + tex/context/base/mkii/mult-pe.mkii | 2 + tex/context/base/mkii/mult-ro.mkii | 2 + tex/context/base/mkii/page-mul.mkii | 6 +- tex/context/base/mkiv/buff-par.lua | 21 +- tex/context/base/mkiv/buff-par.mkvi | 29 +- tex/context/base/mkiv/char-def.lua | 11 + tex/context/base/mkiv/chem-str.lua | 4 +- tex/context/base/mkiv/cont-new.mkiv | 2 +- tex/context/base/mkiv/context.mkiv | 4 +- tex/context/base/mkiv/font-afm.lua | 2 +- tex/context/base/mkiv/font-con.lua | 31 +- tex/context/base/mkiv/font-ctx.lua | 2 +- tex/context/base/mkiv/font-ext.lua | 36 ++ tex/context/base/mkiv/font-fil.mkvi | 115 +++--- tex/context/base/mkiv/font-odv.lua | 38 +- tex/context/base/mkiv/font-oti.lua | 4 +- tex/context/base/mkiv/font-otl.lua | 2 +- tex/context/base/mkiv/font-otr.lua | 130 ++++++- tex/context/base/mkiv/font-ots.lua | 108 ++++-- tex/context/base/mkiv/font-pre.mkiv | 8 +- tex/context/base/mkiv/grph-inc.lua | 54 ++- tex/context/base/mkiv/grph-inc.mkiv | 4 + tex/context/base/mkiv/lang-dis.lua | 21 +- tex/context/base/mkiv/lpdf-mis.lua | 3 +- tex/context/base/mkiv/lpdf-xmp.lua | 10 +- tex/context/base/mkiv/math-del.mkiv | 32 +- tex/context/base/mkiv/mult-def.lua | 19 +- tex/context/base/mkiv/mult-low.lua | 2 +- tex/context/base/mkiv/mult-prm.lua | 1 + tex/context/base/mkiv/page-flw.mkiv | 2 +- tex/context/base/mkiv/page-mrk.mkiv | 28 +- tex/context/base/mkiv/page-mul.mkiv | 31 +- tex/context/base/mkiv/publ-imp-apa.mkvi | 1 + tex/context/base/mkiv/publ-imp-aps.mkvi | 3 +- tex/context/base/mkiv/publ-imp-default.mkvi | 4 + tex/context/base/mkiv/scrn-ini.mkvi | 4 +- tex/context/base/mkiv/status-files.pdf | Bin 21281 -> 21183 bytes tex/context/base/mkiv/status-lua.pdf | Bin 368082 -> 368310 bytes tex/context/base/mkiv/strc-itm.mkvi | 141 +++---- tex/context/base/mkiv/syst-ini.mkiv | 1 + tex/context/base/mkiv/tabl-tbl.mkiv | 13 +- tex/context/base/mkiv/task-ini.lua | 9 +- tex/context/base/mkiv/trac-vis.lua | 18 +- tex/context/base/mkiv/typo-fkr.lua | 123 +++++++ tex/context/base/mkiv/typo-fkr.mkiv | 38 ++ tex/context/base/mkiv/typo-rub.lua | 405 +++++++++++++++++++++ tex/context/base/mkiv/typo-rub.mkiv | 170 +++++++++ tex/context/base/mkiv/util-fil.lua | 42 +++ tex/context/fonts/mkiv/type-imp-ipaex.mkiv | 2 +- .../fonts/mkiv/type-imp-koeielettersot.mkiv | 50 ++- tex/context/interface/mkii/keys-cs.xml | 2 + tex/context/interface/mkii/keys-de.xml | 2 + tex/context/interface/mkii/keys-en.xml | 2 + tex/context/interface/mkii/keys-fr.xml | 2 + tex/context/interface/mkii/keys-it.xml | 2 + tex/context/interface/mkii/keys-nl.xml | 2 + tex/context/interface/mkii/keys-pe.xml | 2 + tex/context/interface/mkii/keys-ro.xml | 2 + tex/context/interface/mkiv/i-attachment.xml | 10 +- tex/context/interface/mkiv/i-attribute.xml | 2 +- tex/context/interface/mkiv/i-background.xml | 16 +- tex/context/interface/mkiv/i-bar.xml | 22 +- tex/context/interface/mkiv/i-bleed.xml | 2 +- tex/context/interface/mkiv/i-block.xml | 4 +- tex/context/interface/mkiv/i-bookmark.xml | 2 +- tex/context/interface/mkiv/i-boxes.xml | 70 +++- tex/context/interface/mkiv/i-buffer.xml | 15 +- tex/context/interface/mkiv/i-button.xml | 71 ++-- tex/context/interface/mkiv/i-capitals.xml | 2 +- tex/context/interface/mkiv/i-catcodes.xml | 2 +- tex/context/interface/mkiv/i-character.xml | 2 +- tex/context/interface/mkiv/i-characteralign.xml | 2 +- tex/context/interface/mkiv/i-chart.xml | 4 + tex/context/interface/mkiv/i-cleaning.xml | 2 +- tex/context/interface/mkiv/i-collector.xml | 2 +- tex/context/interface/mkiv/i-color.xml | 26 +- tex/context/interface/mkiv/i-combination.xml | 14 +- tex/context/interface/mkiv/i-commandhandler.xml | 2 +- tex/context/interface/mkiv/i-comment.xml | 10 +- tex/context/interface/mkiv/i-common-argument.xml | 43 ++- tex/context/interface/mkiv/i-common-assignment.xml | 2 - .../interface/mkiv/i-common-definitions.xml | 2 - tex/context/interface/mkiv/i-common-keyword.xml | 53 ++- tex/context/interface/mkiv/i-common-string.xml | 2 - tex/context/interface/mkiv/i-common-value.xml | 25 +- tex/context/interface/mkiv/i-context.pdf | Bin 780132 -> 839469 bytes tex/context/interface/mkiv/i-conversion.xml | 23 +- tex/context/interface/mkiv/i-counter.xml | 2 +- tex/context/interface/mkiv/i-define.xml | 2 +- tex/context/interface/mkiv/i-delimitedtext.xml | 56 ++- tex/context/interface/mkiv/i-description.xml | 8 +- tex/context/interface/mkiv/i-digits.xml | 2 +- tex/context/interface/mkiv/i-dimension.xml | 2 +- tex/context/interface/mkiv/i-direction.xml | 2 +- tex/context/interface/mkiv/i-document.xml | 32 +- tex/context/interface/mkiv/i-dummy.xml | 2 +- tex/context/interface/mkiv/i-effect.xml | 2 +- tex/context/interface/mkiv/i-enumeration.xml | 8 +- tex/context/interface/mkiv/i-export.xml | 2 +- tex/context/interface/mkiv/i-field.xml | 2 +- tex/context/interface/mkiv/i-figure.xml | 2 +- tex/context/interface/mkiv/i-file.xml | 24 +- tex/context/interface/mkiv/i-filler.xml | 94 +++++ tex/context/interface/mkiv/i-firstline.xml | 2 +- tex/context/interface/mkiv/i-fittingpage.xml | 6 +- tex/context/interface/mkiv/i-floats.xml | 30 +- tex/context/interface/mkiv/i-fontfamily.xml | 12 +- tex/context/interface/mkiv/i-fonts.xml | 50 +-- tex/context/interface/mkiv/i-form.xml | 2 +- tex/context/interface/mkiv/i-formula.xml | 79 ++-- tex/context/interface/mkiv/i-fraction.xml | 12 +- tex/context/interface/mkiv/i-framed.xml | 45 ++- tex/context/interface/mkiv/i-graphics.xml | 2 +- tex/context/interface/mkiv/i-grid.xml | 12 +- tex/context/interface/mkiv/i-help.xml | 10 +- tex/context/interface/mkiv/i-highlight.xml | 4 +- tex/context/interface/mkiv/i-hspace.xml | 2 +- tex/context/interface/mkiv/i-hyphenation.xml | 6 +- tex/context/interface/mkiv/i-indent.xml | 2 +- tex/context/interface/mkiv/i-indentedtext.xml | 4 +- tex/context/interface/mkiv/i-initial.xml | 2 +- tex/context/interface/mkiv/i-injector.xml | 2 +- tex/context/interface/mkiv/i-interaction.xml | 6 +- tex/context/interface/mkiv/i-interactionmenu.xml | 136 +++---- tex/context/interface/mkiv/i-interface.xml | 2 +- tex/context/interface/mkiv/i-interlinespace.xml | 26 +- tex/context/interface/mkiv/i-itemgroup.xml | 176 ++++++--- tex/context/interface/mkiv/i-javascript.xml | 2 +- tex/context/interface/mkiv/i-kerning.xml | 4 +- tex/context/interface/mkiv/i-label.xml | 6 +- tex/context/interface/mkiv/i-labeltext.xml | 105 +++++- tex/context/interface/mkiv/i-language.xml | 18 +- tex/context/interface/mkiv/i-layer.xml | 10 +- tex/context/interface/mkiv/i-layout.xml | 9 +- tex/context/interface/mkiv/i-linenumber.xml | 4 +- tex/context/interface/mkiv/i-lines.xml | 5 +- tex/context/interface/mkiv/i-linetable.xml | 2 +- tex/context/interface/mkiv/i-list.xml | 17 +- tex/context/interface/mkiv/i-lohi.xml | 16 +- tex/context/interface/mkiv/i-lua.xml | 6 +- tex/context/interface/mkiv/i-makeup.xml | 9 +- tex/context/interface/mkiv/i-margindata.xml | 132 ++++--- tex/context/interface/mkiv/i-marker.xml | 2 +- tex/context/interface/mkiv/i-marking.xml | 2 +- tex/context/interface/mkiv/i-math.xml | 42 ++- tex/context/interface/mkiv/i-mathalignment.xml | 6 +- tex/context/interface/mkiv/i-mathcases.xml | 6 +- tex/context/interface/mkiv/i-mathfence.xml | 4 +- tex/context/interface/mkiv/i-mathmatrix.xml | 8 +- tex/context/interface/mkiv/i-mathornament.xml | 4 +- tex/context/interface/mkiv/i-mathradical.xml | 4 +- tex/context/interface/mkiv/i-mathstackers.xml | 18 +- tex/context/interface/mkiv/i-metapost.xml | 4 +- tex/context/interface/mkiv/i-mixedcolumns.xml | 8 +- tex/context/interface/mkiv/i-modes.xml | 2 +- tex/context/interface/mkiv/i-modules.xml | 6 +- tex/context/interface/mkiv/i-narrow.xml | 10 +- tex/context/interface/mkiv/i-naturaltable.xml | 3 + tex/context/interface/mkiv/i-note.xml | 69 ++-- tex/context/interface/mkiv/i-object.xml | 2 +- tex/context/interface/mkiv/i-offset.xml | 2 +- tex/context/interface/mkiv/i-ornament.xml | 14 +- tex/context/interface/mkiv/i-output.xml | 6 +- tex/context/interface/mkiv/i-overlay.xml | 2 +- tex/context/interface/mkiv/i-pagebreak.xml | 2 +- tex/context/interface/mkiv/i-pagegrid.xml | 4 +- tex/context/interface/mkiv/i-pageinjection.xml | 4 +- tex/context/interface/mkiv/i-pageselection.xml | 9 +- tex/context/interface/mkiv/i-pairedbox.xml | 17 +- tex/context/interface/mkiv/i-papersize.xml | 10 +- tex/context/interface/mkiv/i-paragraph.xml | 2 +- tex/context/interface/mkiv/i-paragraphs.xml | 10 +- tex/context/interface/mkiv/i-parallel.xml | 4 +- tex/context/interface/mkiv/i-pdf.xml | 2 +- tex/context/interface/mkiv/i-penalty.xml | 2 +- tex/context/interface/mkiv/i-periods.xml | 4 +- tex/context/interface/mkiv/i-placement.xml | 2 +- tex/context/interface/mkiv/i-positionbar.xml | 2 +- tex/context/interface/mkiv/i-processor.xml | 2 +- tex/context/interface/mkiv/i-profile.xml | 2 +- tex/context/interface/mkiv/i-publication.xml | 108 +++--- tex/context/interface/mkiv/i-random.xml | 2 +- tex/context/interface/mkiv/i-readme.pdf | Bin 60791 -> 60762 bytes tex/context/interface/mkiv/i-references.xml | 4 +- tex/context/interface/mkiv/i-regime.xml | 2 +- tex/context/interface/mkiv/i-register.xml | 46 ++- tex/context/interface/mkiv/i-rotatation.xml | 2 +- tex/context/interface/mkiv/i-script.xml | 11 +- tex/context/interface/mkiv/i-section.xml | 85 ++++- tex/context/interface/mkiv/i-sectionblock.xml | 8 +- tex/context/interface/mkiv/i-setups.xml | 30 +- tex/context/interface/mkiv/i-shift.xml | 8 +- tex/context/interface/mkiv/i-sidebar.xml | 6 +- tex/context/interface/mkiv/i-sort.xml | 15 +- tex/context/interface/mkiv/i-startstop.xml | 4 +- tex/context/interface/mkiv/i-stream.xml | 2 +- tex/context/interface/mkiv/i-string.xml | 2 +- tex/context/interface/mkiv/i-symbol.xml | 6 +- tex/context/interface/mkiv/i-synonym.xml | 17 +- tex/context/interface/mkiv/i-system.xml | 49 +-- tex/context/interface/mkiv/i-systemlog.xml | 2 +- tex/context/interface/mkiv/i-table.xml | 26 +- tex/context/interface/mkiv/i-tabulation.xml | 8 +- tex/context/interface/mkiv/i-textbackground.xml | 6 +- tex/context/interface/mkiv/i-tolerance.xml | 2 +- tex/context/interface/mkiv/i-tooltip.xml | 14 +- tex/context/interface/mkiv/i-tracker.xml | 2 +- tex/context/interface/mkiv/i-twopassdata.xml | 2 +- tex/context/interface/mkiv/i-typography.xml | 2 +- tex/context/interface/mkiv/i-unit.xml | 11 +- tex/context/interface/mkiv/i-variables.xml | 19 +- tex/context/interface/mkiv/i-verbatim.xml | 58 +-- tex/context/interface/mkiv/i-version.xml | 2 +- tex/context/interface/mkiv/i-viewerlayer.xml | 4 +- tex/context/interface/mkiv/i-visualizer.xml | 2 +- tex/context/interface/mkiv/i-whitespace.xml | 2 +- tex/context/interface/mkiv/i-xtable.xml | 26 +- tex/context/modules/mkiv/m-educat.mkiv | 2 + tex/context/modules/mkiv/x-setups-basics.mkiv | 16 +- tex/generic/context/luatex/luatex-fonts-merged.lua | 260 +++++++++++-- 228 files changed, 3453 insertions(+), 1191 deletions(-) create mode 100644 tex/context/base/mkiv/typo-fkr.lua create mode 100644 tex/context/base/mkiv/typo-fkr.mkiv create mode 100644 tex/context/base/mkiv/typo-rub.lua create mode 100644 tex/context/base/mkiv/typo-rub.mkiv (limited to 'tex') diff --git a/tex/context/base/mkii/cont-new.mkii b/tex/context/base/mkii/cont-new.mkii index c1ec3f967..d387d4ca9 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{2016.09.24 12:40} +\newcontextversion{2016.10.12 17:26} %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 4f166f39e..40904a978 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{2016.09.24 12:40} +\edef\contextversion{2016.10.12 17:26} %D For those who want to use this: diff --git a/tex/context/base/mkii/mult-cs.mkii b/tex/context/base/mkii/mult-cs.mkii index f55cde7e6..947e9bbd8 100644 --- a/tex/context/base/mkii/mult-cs.mkii +++ b/tex/context/base/mkii/mult-cs.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nothanging} \setinterfacevariable{nothyphenated}{nothyphenated} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{listopad} \setinterfacevariable{nowhere}{nikde} \setinterfacevariable{nowhite}{zadnabila} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{svrchnimezera} \setinterfaceconstant{topstate}{statusvrsku} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{typ} diff --git a/tex/context/base/mkii/mult-de.mkii b/tex/context/base/mkii/mult-de.mkii index 5fba2fd3c..d579244e7 100644 --- a/tex/context/base/mkii/mult-de.mkii +++ b/tex/context/base/mkii/mult-de.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nothanging} \setinterfacevariable{nothyphenated}{nothyphenated} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{november} \setinterfacevariable{nowhere}{nirgens} \setinterfacevariable{nowhite}{keinweiss} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{kopfspatium} \setinterfaceconstant{topstate}{statusoben} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{typ} diff --git a/tex/context/base/mkii/mult-en.mkii b/tex/context/base/mkii/mult-en.mkii index 15d8637e0..96d1500a8 100644 --- a/tex/context/base/mkii/mult-en.mkii +++ b/tex/context/base/mkii/mult-en.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nothanging} \setinterfacevariable{nothyphenated}{nothyphenated} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{november} \setinterfacevariable{nowhere}{nowhere} \setinterfacevariable{nowhite}{nowhite} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{topspace} \setinterfaceconstant{topstate}{topstate} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{type} diff --git a/tex/context/base/mkii/mult-fr.mkii b/tex/context/base/mkii/mult-fr.mkii index 18ebdc3db..c8a06bb0d 100644 --- a/tex/context/base/mkii/mult-fr.mkii +++ b/tex/context/base/mkii/mult-fr.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nonsuspendu} \setinterfacevariable{nothyphenated}{nothyphenated} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{novembre} \setinterfacevariable{nowhere}{nulpart} \setinterfacevariable{nowhite}{sansblanc} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{espacesup} \setinterfaceconstant{topstate}{etatsup} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{type} diff --git a/tex/context/base/mkii/mult-it.mkii b/tex/context/base/mkii/mult-it.mkii index 779d32256..a6c0606a4 100644 --- a/tex/context/base/mkii/mult-it.mkii +++ b/tex/context/base/mkii/mult-it.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nonsospeso} \setinterfacevariable{nothyphenated}{nonsillabato} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{novembre} \setinterfacevariable{nowhere}{danessunaparte} \setinterfacevariable{nowhite}{nobianco} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{spaziocima} \setinterfaceconstant{topstate}{statocima} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{type} diff --git a/tex/context/base/mkii/mult-nl.mkii b/tex/context/base/mkii/mult-nl.mkii index dabf77b27..563afb912 100644 --- a/tex/context/base/mkii/mult-nl.mkii +++ b/tex/context/base/mkii/mult-nl.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{niethangend} \setinterfacevariable{nothyphenated}{nietafgebroken} +\setinterfacevariable{notjoinedup}{nietaansluitend} \setinterfacevariable{november}{november} \setinterfacevariable{nowhere}{nergens} \setinterfacevariable{nowhite}{geenwit} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{kopwit} \setinterfaceconstant{topstate}{bovenstatus} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transformatie} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{type} diff --git a/tex/context/base/mkii/mult-pe.mkii b/tex/context/base/mkii/mult-pe.mkii index f66194edf..a4cbb6b38 100644 --- a/tex/context/base/mkii/mult-pe.mkii +++ b/tex/context/base/mkii/mult-pe.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{بدون‌آویزان‌کردن} \setinterfacevariable{nothyphenated}{بدون‌شکست} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{نوامبر} \setinterfacevariable{nowhere}{هیچ‌حا} \setinterfacevariable{nowhite}{سفید‌نه} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{فضای‌بالا} \setinterfaceconstant{topstate}{وضعیت‌بالا} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{تایپ} diff --git a/tex/context/base/mkii/mult-ro.mkii b/tex/context/base/mkii/mult-ro.mkii index d6e6d8362..a8c5e59f0 100644 --- a/tex/context/base/mkii/mult-ro.mkii +++ b/tex/context/base/mkii/mult-ro.mkii @@ -379,6 +379,7 @@ \setinterfacevariable{note}{note} \setinterfacevariable{nothanging}{nothanging} \setinterfacevariable{nothyphenated}{nedespsilabe} +\setinterfacevariable{notjoinedup}{notjoinedup} \setinterfacevariable{november}{noiembrie} \setinterfacevariable{nowhere}{niciunde} \setinterfacevariable{nowhite}{faraalb} @@ -1232,6 +1233,7 @@ \setinterfaceconstant{topspace}{spatiusus} \setinterfaceconstant{topstate}{staresus} \setinterfaceconstant{totalnumber}{totalnumber} +\setinterfaceconstant{transform}{transform} \setinterfaceconstant{translate}{translate} \setinterfaceconstant{trimoffset}{trimoffset} \setinterfaceconstant{type}{type} diff --git a/tex/context/base/mkii/page-mul.mkii b/tex/context/base/mkii/page-mul.mkii index decf784f0..bf258abed 100644 --- a/tex/context/base/mkii/page-mul.mkii +++ b/tex/context/base/mkii/page-mul.mkii @@ -1656,9 +1656,9 @@ {\goodbreak} \installcolumnbreakhandler {MUL} \v!yes - {\par % todo: since - {\testrulewidth\zeropoint\ruledvskip\textheight} % we misuse a - \penalty-200 % side effect + {\par % todo: since + {\testrulewidth\zeropoint\ruledvskip\textheight}% we misuse a + \penalty-200 % side effect \vskip-\textheight }% bugged : \prevdepth-\thousandpoint} % signals top of column to \blank diff --git a/tex/context/base/mkiv/buff-par.lua b/tex/context/base/mkiv/buff-par.lua index 58ea9ab9d..9c75b90e7 100644 --- a/tex/context/base/mkiv/buff-par.lua +++ b/tex/context/base/mkiv/buff-par.lua @@ -6,7 +6,7 @@ if not modules then modules = { } end modules ['buff-par'] = { license = "see context related readme files" } -local insert, remove, find, gmatch = table.insert, table.remove, string.find, string.gmatch +local insert, remove, find, gmatch, match = table.insert, table.remove, string.find, string.gmatch, string.match local fullstrip, formatters = string.fullstrip, string.formatters local trace_parallel = false trackers.register("buffers.parallel", function(v) trace_parallel = v end) @@ -90,18 +90,31 @@ function parallel.save(category,tag,content,frombuffer) -- use lpeg if find(content,"%s*%[") then local done = false - for label, content in gmatch(content,"%s*%[(.-)%]%s*([^%[]+)") do + + local function flush(content,label) if done then line = { } insert(lines,line) else done = true end + line.content = fullstrip(content) + line.label = label + end + + + local leading, rest = match(content,"^%s*([^%[]+)(.*)$") + if leading then + if leading ~= "" then + flush(leading) + end + content = rest + end + for label, content in gmatch(content,"%s*%[(.-)%]%s*([^%[]+)") do if trace_parallel and label ~= "" then report_parallel("reference found of category %a, tag %a, label %a",category,tag,label) end - line.content = fullstrip(content) - line.label = label + flush(content,label) end else line.content = fullstrip(content) diff --git a/tex/context/base/mkiv/buff-par.mkvi b/tex/context/base/mkiv/buff-par.mkvi index b17edb173..189e68eec 100644 --- a/tex/context/base/mkiv/buff-par.mkvi +++ b/tex/context/base/mkiv/buff-par.mkvi @@ -15,24 +15,40 @@ \registerctxluafile{buff-par}{1.001} -%D This module is developped for Thomas Schmitz as part of a project. There is -%D no documentation yet. +%D This module is made for Thomas Schmitz as part of a project. There is +%D no documentation yet. Also, this code is unfinished and not tested well. %D %D \starttyping %D \defineparallel[main][one,two] %D %D \startmain %D \startone -%D first 1 -%D [reference] first 2 +%D first 0 +%D [reference] first 1 +%D first 2 %D first 3 %D \stopone %D \starttwo %D second 1 +%D second 2 %D \stoptwo %D \stopmain %D -%D \placeparallel[main][one,two][criterium=all] +%D \startmain +%D \startone +%D first 4 +%D first 4 +%D \stopone +%D \starttwo +%D second 3 +%D second 4 +%D \stoptwo +%D \stopmain +%D +%D \placeparallel[main][one][criterium=all] +%D +%D \placeparallel[main][two][criterium=all] +%D \stoptyping %D criterium=all start= n= @@ -134,7 +150,8 @@ {} \def\buff_parallel_flush_yes - {\directsetup{\namedparallelparameter{\currentparallel:\currentparallelinstance}\c!setups}} + %{\directsetup{\namedparallelparameter{\currentparallel:\currentparallelinstance}\c!setups}} + {\directsetup{\namedparallelparameter{\currentparallelinstance}\c!setups}} \unexpanded\def\doifelseparallel#name#instance% {\clf_doifelseparallel{#name}{#instance}} diff --git a/tex/context/base/mkiv/char-def.lua b/tex/context/base/mkiv/char-def.lua index 38fe57c19..74748a642 100644 --- a/tex/context/base/mkiv/char-def.lua +++ b/tex/context/base/mkiv/char-def.lua @@ -79531,6 +79531,17 @@ characters.data={ description="QUADRUPLE INTEGRAL OPERATOR", direction="on", linebreak="al", + mathclass="limop", + mathspec={ + { + class="limop", + name="iiiint", + }, + { + class="nothing", + name="iiiintop", + }, + }, specials={ "compat", 0x222B, 0x222B, 0x222B, 0x222B }, unicodeslot=0x2A0C, }, diff --git a/tex/context/base/mkiv/chem-str.lua b/tex/context/base/mkiv/chem-str.lua index 445b779a1..a40ca76b0 100644 --- a/tex/context/base/mkiv/chem-str.lua +++ b/tex/context/base/mkiv/chem-str.lua @@ -287,6 +287,8 @@ end local remapper = { ["+"] = "p", ["-"] = "m", + ["--"] = "mm", + ["++"] = "pp", } local dchrs = R("09") @@ -299,7 +301,7 @@ local set = Ct(digit^2) local colon = P(":") local equal = P("=") local other = 1 - digit - colon - equal -local remapped = sign / remapper +local remapped = (sign * sign + sign) / remapper local operation = Cs(other^1) local special = (colon * C(other^1)) + Cc("") local text = (equal * C(P(1)^0)) + Cc(false) diff --git a/tex/context/base/mkiv/cont-new.mkiv b/tex/context/base/mkiv/cont-new.mkiv index 506cf489f..33fbbcd9d 100644 --- a/tex/context/base/mkiv/cont-new.mkiv +++ b/tex/context/base/mkiv/cont-new.mkiv @@ -11,7 +11,7 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\newcontextversion{2016.09.24 12:40} +\newcontextversion{2016.10.12 17:26} %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/mkiv/context.mkiv b/tex/context/base/mkiv/context.mkiv index 64587d1b2..4442f266c 100644 --- a/tex/context/base/mkiv/context.mkiv +++ b/tex/context/base/mkiv/context.mkiv @@ -39,7 +39,7 @@ %D up and the dependencies are more consistent. \edef\contextformat {\jobname} -\edef\contextversion{2016.09.24 12:40} +\edef\contextversion{2016.10.12 17:26} \edef\contextkind {beta} %D For those who want to use this: @@ -434,6 +434,8 @@ \loadmarkfile{typo-sus} \loadmarkfile{typo-lig} \loadmarkfile{typo-chr} +\loadmarkfile{typo-rub} +\loadmkivfile{typo-fkr} \loadmkvifile{type-ini} \loadmarkfile{type-set} diff --git a/tex/context/base/mkiv/font-afm.lua b/tex/context/base/mkiv/font-afm.lua index fe14059cb..a9fbe89f1 100644 --- a/tex/context/base/mkiv/font-afm.lua +++ b/tex/context/base/mkiv/font-afm.lua @@ -32,7 +32,7 @@ local match, gmatch, lower, gsub, strip, find = string.match, string.gmatch, str local char, byte, sub = string.char, string.byte, string.sub local abs = math.abs local bxor, rshift = bit32.bxor, bit32.rshift -local P, S, R, Cmt, C, Ct, Cs, lpegmatch, patterns = lpeg.P, lpeg.S, lpeg.R, lpeg.Cmt, lpeg.C, lpeg.Ct, lpeg.Cs, lpeg.match, lpeg.patterns +local P, S, R, Cmt, C, Ct, Cs, Cg, Cf, lpegmatch, patterns = lpeg.P, lpeg.S, lpeg.R, lpeg.Cmt, lpeg.C, lpeg.Ct, lpeg.Cs, lpeg.Cg, lpeg.Cf, lpeg.match, lpeg.patterns local derivetable = table.derive local trace_features = false trackers.register("afm.features", function(v) trace_features = v end) diff --git a/tex/context/base/mkiv/font-con.lua b/tex/context/base/mkiv/font-con.lua index b3e506b34..18f221710 100644 --- a/tex/context/base/mkiv/font-con.lua +++ b/tex/context/base/mkiv/font-con.lua @@ -447,12 +447,16 @@ function constructors.scale(tfmdata,specification) local haskerns = properties.haskerns or properties.mode == "base" -- we can have afm in node mode local hasligatures = properties.hasligatures or properties.mode == "base" -- we can have afm in node mode local realdimensions = properties.realdimensions + local writingmode = properties.writingmode or "horizontal" + local identity = properties.identity or "horizontal" -- if changed and not next(changed) then changed = false end -- - target.type = isvirtual and "virtual" or "real" + target.type = isvirtual and "virtual" or "real" + target.writingmode = writingmode == "vertical" and "vertical" or "horizontal" + target.identity = identity == "vertical" and "vertical" or "horizontal" -- target.postprocessors = tfmdata.postprocessors -- @@ -894,6 +898,8 @@ function constructors.finalize(tfmdata) cidinfo = tfmdata.cidinfo or nil, format = tfmdata.format or "type1", direction = tfmdata.direction or 0, + writingmode = tfmdata.writingmode or "horizontal", + identity = tfmdata.identity or "horizontal", } end if not tfmdata.resources then @@ -1091,7 +1097,11 @@ end) do - local function setindeed(mode,target,group,name,action,position) + local function setindeed(mode,source,target,group,name,position) + local action = source[mode] + if not action then + return + end local t = target[mode] if not t then report_defining("fatal error in setting feature %a, group %a, mode %a",name,group,mode) @@ -1122,15 +1132,10 @@ do report_defining("fatal source error in setting feature %a, group %a",name,group) os.exit() end - local node = source.node - local base = source.base local position = source.position - if node then - setindeed("node",target,group,name,node,position) - end - if base then - setindeed("base",target,group,name,base,position) - end + setindeed("node",source,target,group,name,position) + setindeed("base",source,target,group,name,position) + setindeed("plug",source,target,group,name,position) end local function register(where,specification) @@ -1197,9 +1202,9 @@ do defaults = { }, descriptions = tables and tables.features or { }, used = statistics and statistics.usedfeatures or { }, - initializers = { base = { }, node = { } }, - processors = { base = { }, node = { } }, - manipulators = { base = { }, node = { } }, + initializers = { base = { }, node = { }, plug = { } }, + processors = { base = { }, node = { }, plug = { } }, + manipulators = { base = { }, node = { }, plug = { } }, } features.register = function(specification) return register(features,specification) end handler.features = features -- will also become hidden diff --git a/tex/context/base/mkiv/font-ctx.lua b/tex/context/base/mkiv/font-ctx.lua index eacfe5fa9..0eb6955d0 100644 --- a/tex/context/base/mkiv/font-ctx.lua +++ b/tex/context/base/mkiv/font-ctx.lua @@ -2640,7 +2640,7 @@ end do - local pattern = C((1-S("* "))^1) + local pattern = C((1-S("* "))^1) -- strips all after * or ' at' implement { name = "truefontname", diff --git a/tex/context/base/mkiv/font-ext.lua b/tex/context/base/mkiv/font-ext.lua index e57c4e56c..eb263d316 100644 --- a/tex/context/base/mkiv/font-ext.lua +++ b/tex/context/base/mkiv/font-ext.lua @@ -1206,3 +1206,39 @@ do } end + +do + + local function initialize(tfmdata,value) + local properties = tfmdata.properties + if properties then + properties.identity = value == "vertical" and "vertical" or "horizontal" + end + end + + registerotffeature { + name = "identity", + description = "set font identity", + initializers = { + base = initialize, + node = initialize, + } + } + + local function initialize(tfmdata,value) + local properties = tfmdata.properties + if properties then + properties.writingmode = value == "vertical" and "vertical" or "horizontal" + end + end + + registerotffeature { + name = "writingmode", + description = "set font direction", + initializers = { + base = initialize, + node = initialize, + } + } + +end diff --git a/tex/context/base/mkiv/font-fil.mkvi b/tex/context/base/mkiv/font-fil.mkvi index 26751531b..fbe4b8442 100644 --- a/tex/context/base/mkiv/font-fil.mkvi +++ b/tex/context/base/mkiv/font-fil.mkvi @@ -185,70 +185,73 @@ % todo: replace * by ... less messy with features -% \def\truefontname#name% -% {\expandafter\font_helpers_true_fontname#name*\empty*\relax} -% -% \def\font_helpers_true_fontname#name*#first#rest*#crap\relax -% {\ifcsname\??fontfile\fontclass#name\endcsname -% \ifx#first\empty -% %\expandafter\truefontname\csname\??fontfile\fontclass#name\endcsname -% \expandafter\truefontname\lastnamedcs -% \else -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\fontclass#name\endcsname*#first#rest% -% \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% -% \fi -% \else\ifcsname\??fontfile\defaultfontclass#name\endcsname -% \ifx#first\empty -% %\expandafter\truefontname\csname\??fontfile\defaultfontclass#name\endcsname -% \expandafter\truefontname\lastnamedcs -% \else -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\defaultfontclass#name\endcsname*#first#rest% -% \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% -% \fi -% \else\ifcsname\??fontfile#name\endcsname -% \ifx#first\empty -% %\expandafter\truefontname\csname\??fontfile#name\endcsname -% \expandafter\truefontname\lastnamedcs -% \else -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile#name\endcsname*#first#rest% -% \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% -% \fi -% \else -% #name\ifx#first\empty\else*#first#rest\fi -% \fi\fi\fi} -% -% \def\font_helpers_true_fontname_check#name% -% {\expandafter\font_helpers_true_fontname_check_indeed#name*\relax} -% -% \def\font_helpers_true_fontname_check_indeed#name*#crap\relax -% {\ifcsname\??fontfile\fontclass#name\endcsname -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\fontclass#name\endcsname -% \expandafter\font_helpers_true_fontname_check\lastnamedcs -% \else\ifcsname\??fontfile\defaultfontclass#name\endcsname -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\defaultfontclass#name\endcsname -% \expandafter\font_helpers_true_fontname_check\lastnamedcs -% \else\ifcsname\??fontfile#name\endcsname -% %\expandafter\font_helpers_true_fontname_check\csname\??fontfile#name\endcsname -% \expandafter\font_helpers_true_fontname_check\lastnamedcs -% \else -% #name% -% \fi\fi\fi} - \def\truefontname#name% - %{\normalexpanded{\noexpand\font_helpers_true_fontname{\clf_truefontname{#name}}}} - {\expandafter\expandafter\expandafter\font_helpers_true_fontname\expandafter\expandafter\expandafter{\clf_truefontname{#name}}} + {\expandafter\font_helpers_true_fontname#name*\empty*\relax} -\def\font_helpers_true_fontname#name% +\def\font_helpers_true_fontname#name*#first#rest*#crap\relax {\ifcsname\??fontfile\fontclass#name\endcsname - \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% + \ifx#first\empty + %\expandafter\truefontname\csname\??fontfile\fontclass#name\endcsname + \expandafter\truefontname\lastnamedcs + \else + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\fontclass#name\endcsname*#first#rest% + \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% + \fi \else\ifcsname\??fontfile\defaultfontclass#name\endcsname - \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% + \ifx#first\empty + %\expandafter\truefontname\csname\??fontfile\defaultfontclass#name\endcsname + \expandafter\truefontname\lastnamedcs + \else + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\defaultfontclass#name\endcsname*#first#rest% + \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% + \fi \else\ifcsname\??fontfile#name\endcsname - \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% + \ifx#first\empty + %\expandafter\truefontname\csname\??fontfile#name\endcsname + \expandafter\truefontname\lastnamedcs + \else + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile#name\endcsname*#first#rest% + \expandafter\font_helpers_true_fontname_check\lastnamedcs*#first#rest% + \fi \else - \clf_truefontname{#name}% + #name\ifx#first\empty\else*#first#rest\fi \fi\fi\fi} +\def\font_helpers_true_fontname_check#name% + {\expandafter\font_helpers_true_fontname_check_indeed#name*\relax} + +\def\font_helpers_true_fontname_check_indeed#name*#crap\relax + {\ifcsname\??fontfile\fontclass#name\endcsname + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\fontclass#name\endcsname + \expandafter\font_helpers_true_fontname_check\lastnamedcs + \else\ifcsname\??fontfile\defaultfontclass#name\endcsname + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile\defaultfontclass#name\endcsname + \expandafter\font_helpers_true_fontname_check\lastnamedcs + \else\ifcsname\??fontfile#name\endcsname + %\expandafter\font_helpers_true_fontname_check\csname\??fontfile#name\endcsname + \expandafter\font_helpers_true_fontname_check\lastnamedcs + \else + #name% + \fi\fi\fi} + +% ok when the last lookup is not stripped .. we ned to be able to define synonyms for symbols +% +% \def\truefontname#name% +% %{\normalexpanded{\noexpand\font_helpers_true_fontname{\clf_truefontname{#name}}}} +% {\expandafter\expandafter\expandafter\font_helpers_true_fontname\expandafter\expandafter\expandafter{\clf_truefontname{#name}}} +% +% \def\font_helpers_true_fontname#name% +% {\ifcsname\??fontfile\fontclass#name\endcsname +% \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% +% \else\ifcsname\??fontfile\defaultfontclass#name\endcsname +% \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% +% \else\ifcsname\??fontfile#name\endcsname +% \expandafter\font_helpers_true_fontname\expandafter{\lastnamedcs}% +% \else +% % \clf_truefontname{#name}% +% #name% so the last one can have features ! +% \fi\fi\fi} + \def\expandfontsynonym#command#name% one level expansion {\ifcsname\??fontfile\fontclass#name\endcsname %\expandafter\normaldef\expandafter#command\expandafter{\csname\??fontfile\fontclass#name\endcsname}% diff --git a/tex/context/base/mkiv/font-odv.lua b/tex/context/base/mkiv/font-odv.lua index 2e27fefbc..345b17a52 100644 --- a/tex/context/base/mkiv/font-odv.lua +++ b/tex/context/base/mkiv/font-odv.lua @@ -714,9 +714,9 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces) local tmp = next and getnext(next) or nil -- needs checking local changestop = next == stop local tempcurrent = copy_node(next) - copyinjection(tempcurrent,next) + copyinjection(tempcurrent,next) local nextcurrent = copy_node(current) - copyinjection(nextcurrent,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set + copyinjection(nextcurrent,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set setnext(tempcurrent,nextcurrent) setprev(nextcurrent,tempcurrent) setprop(tempcurrent,a_state,s_blwf) @@ -725,7 +725,7 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces) if getchar(next) == getchar(tempcurrent) then flush_list(tempcurrent) local n = copy_node(current) - copyinjection(n,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set + copyinjection(n,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set setchar(current,dotted_circle) head = insert_node_after(head, current, n) else @@ -1269,7 +1269,7 @@ function handlers.devanagari_remove_joiners(head,start,kind,lookupname,replaceme setnext(prev,stop) end if head == start then - head = stop + head = stop end flush_list(start) return head, stop, true @@ -1578,7 +1578,7 @@ local function dev2_reorder(head,start,stop,font,attr,nbspaces) -- maybe do a pa if halant[getchar(current)] then setnext(getnext(current),tmp) local nc = copy_node(current) - copyinjection(nc,current) + copyinjection(nc,current) setchar(current,dotted_circle) head = insert_node_after(head,current,nc) else @@ -1642,17 +1642,17 @@ local function dev2_reorder(head,start,stop,font,attr,nbspaces) -- maybe do a pa local last = getnext(stop) while current ~= last do local char, target, cn = locl[current] or getchar(current), nil, getnext(current) --- not so efficient (needed for malayalam) -local tpm = twopart_mark[char] -if tpm then - local extra = copy_node(current) - copyinjection(extra,current) - char = tpm[1] - setchar(current,char) - setchar(extra,tpm[2]) - head = insert_node_after(head,current,extra) -end --- + -- not so efficient (needed for malayalam) + local tpm = twopart_mark[char] + if tpm then + local extra = copy_node(current) + copyinjection(extra,current) + char = tpm[1] + setchar(current,char) + setchar(extra,tpm[2]) + head = insert_node_after(head,current,extra) + end + -- if not moved[current] and dependent_vowel[char] then if pre_mark[char] then -- Before first half form in the syllable moved[current] = true @@ -2081,7 +2081,7 @@ end local function inject_syntax_error(head,current,mark) local signal = copy_node(current) - copyinjection(signal,current) + copyinjection(signal,current) if mark == pre_mark then setchar(signal,dotted_circle) else @@ -2127,8 +2127,8 @@ function methods.deva(head,font,attr) end if standalone then -- stand alone cluster (at the start of the word only): #[Ra+H]+NBSP+[N]+[<[]+H+C>]+[{M}+[N]+[H]]+[SM]+[(VD)] - local syllableend = analyze_next_chars_one(c,font,2) - current = getnext(syllableend) + local syllableend = analyze_next_chars_one(c,font,2) + current = getnext(syllableend) if syllablestart ~= syllableend then head, current, nbspaces = deva_reorder(head,syllablestart,syllableend,font,attr,nbspaces) current = getnext(current) diff --git a/tex/context/base/mkiv/font-oti.lua b/tex/context/base/mkiv/font-oti.lua index 5e812bb9e..e10a261cd 100644 --- a/tex/context/base/mkiv/font-oti.lua +++ b/tex/context/base/mkiv/font-oti.lua @@ -72,6 +72,7 @@ registerotffeature { initializers = { base = setmode, node = setmode, + plug = setmode, } } @@ -81,6 +82,7 @@ registerotffeature { initializers = { base = setlanguage, node = setlanguage, + plug = setlanguage, } } @@ -90,6 +92,7 @@ registerotffeature { initializers = { base = setscript, node = setscript, + plug = setscript, } } @@ -157,4 +160,3 @@ function otffeatures.checkeddefaultlanguage(featuretype,autolanguage,languages) end end end - diff --git a/tex/context/base/mkiv/font-otl.lua b/tex/context/base/mkiv/font-otl.lua index cf6603fc7..d4eaed763 100644 --- a/tex/context/base/mkiv/font-otl.lua +++ b/tex/context/base/mkiv/font-otl.lua @@ -675,7 +675,7 @@ local function getgsub(tfmdata,k,kind,value) local properties = tfmdata.properties local validlookups, lookuplist = otf.collectlookups(rawdata,kind,properties.script,properties.language) if validlookups then - local choice = tonumber(value) or 1 -- no random here (yet) + -- local choice = tonumber(value) or 1 -- no random here (yet) for i=1,#lookuplist do local lookup = lookuplist[i] local steps = lookup.steps diff --git a/tex/context/base/mkiv/font-otr.lua b/tex/context/base/mkiv/font-otr.lua index 9cdbc3df0..2b18c1e0e 100644 --- a/tex/context/base/mkiv/font-otr.lua +++ b/tex/context/base/mkiv/font-otr.lua @@ -975,7 +975,7 @@ readers.head = function(f,fontdata) end -- This table is a rather simple one. No treatment of values is needed here. Most --- variables are not used but nofhmetrics is quite important. +-- variables are not used but nofmetrics is quite important. readers.hhea = function(f,fontdata,specification) if specification.details then @@ -983,7 +983,7 @@ readers.hhea = function(f,fontdata,specification) if datatable then setposition(f,datatable.offset) fontdata.horizontalheader = { - version = readfixed(f), + version = readfixed(f), -- two ushorts: major minor ascender = readfword(f), descender = readfword(f), linegap = readfword(f), @@ -999,11 +999,45 @@ readers.hhea = function(f,fontdata,specification) reserved_3 = readshort(f), reserved_4 = readshort(f), metricdataformat = readshort(f), - nofhmetrics = readushort(f), + nofmetrics = readushort(f), } else fontdata.horizontalheader = { - nofhmetrics = 0, + nofmetrics = 0, + } + end + end +end + +readers.vhea = function(f,fontdata,specification) + if specification.details then + local datatable = fontdata.tables.vhea + if datatable then + setposition(f,datatable.offset) + local version = readfixed(f) + fontdata.verticalheader = { + version = version, + ascender = readfword(f), + descender = readfword(f), + linegap = readfword(f), + maxadvanceheight = readufword(f), + mintopsidebearing = readfword(f), + minbottomsidebearing = readfword(f), + maxextent = readfword(f), + caretsloperise = readshort(f), + caretsloperun = readshort(f), + caretoffset = readshort(f), + reserved_1 = readshort(f), + reserved_2 = readshort(f), + reserved_3 = readshort(f), + reserved_4 = readshort(f), + metricdataformat = readshort(f), + nofmetrics = readushort(f), + } +-- inspect(fontdata.verticalheader) + else + fontdata.verticalheader = { + nofmetrics = 0, } end end @@ -1064,11 +1098,12 @@ readers.hmtx = function(f,fontdata,specification) local datatable = fontdata.tables.hmtx if datatable then setposition(f,datatable.offset) - local nofmetrics = fontdata.horizontalheader.nofhmetrics - local glyphs = fontdata.glyphs - local nofglyphs = fontdata.nofglyphs - local width = 0 -- advance - local leftsidebearing = 0 + local horizontalheader = fontdata.horizontalheader + local nofmetrics = horizontalheader.nofmetrics + local glyphs = fontdata.glyphs + local nofglyphs = fontdata.nofglyphs + local width = 0 -- advance + local leftsidebearing = 0 for i=0,nofmetrics-1 do local glyph = glyphs[i] width = readshort(f) @@ -1095,6 +1130,53 @@ readers.hmtx = function(f,fontdata,specification) end end +readers.vmtx = function(f,fontdata,specification) + if specification.glyphs then + local datatable = fontdata.tables.vmtx + if datatable then + setposition(f,datatable.offset) + local verticalheader = fontdata.verticalheader + local nofmetrics = verticalheader.nofmetrics + local glyphs = fontdata.glyphs + local nofglyphs = fontdata.nofglyphs + local vheight = 0 + local vdefault = verticalheader.ascender + verticalheader.descender + local topsidebearing = 0 + for i=0,nofmetrics-1 do + local glyph = glyphs[i] + vheight = readshort(f) + topsidebearing = readshort(f) + if vheight ~= 0 and vheight ~= vdefault then + glyph.vheight = vheight + end + -- if topsidebearing ~= 0 then + -- glyph.tsb = topsidebearing + -- end + end + -- The next can happen in for instance a monospace font or in a cjk font + -- with fixed heights. + for i=nofmetrics,nofglyphs-1 do + local glyph = glyphs[i] + if vheight ~= 0 and vheight ~= vdefault then + glyph.vheight = vheight + end + -- if topsidebearing ~= 0 then + -- glyph.tsb = topsidebearing + -- end + end + end + end +end + +readers.vorg = function(f,fontdata,specification) + if specification.glyphs then + local datatable = fontdata.tables.vorg + if datatable then + report("todo: %s","vorg") + end + end +end + -- The post table relates to postscript (printing) but has some relevant properties for other -- usage as well. We just use the names from the microsoft specification. The version 2.0 -- description is somewhat fuzzy but it is a hybrid with overloads. @@ -1751,7 +1833,7 @@ end -- some properties in order to read following tables. When details is true we also -- initialize the glyphs data. -local function getinfo(maindata,sub,platformnames,rawfamilynames) +local function getinfo(maindata,sub,platformnames,rawfamilynames,metricstoo) local fontdata = sub and maindata.subfonts and maindata.subfonts[sub] or maindata local names = fontdata.names local info = nil @@ -1808,6 +1890,29 @@ local function getinfo(maindata,sub,platformnames,rawfamilynames) descender = metrics.typodescender, platformnames = platformnames and fontdata.platformnames or nil, } + if metricstoo then + local keys = { + "version", + "ascender", "descender", "linegap", + -- "caretoffset", "caretsloperise", "caretsloperun", + "maxadvancewidth", "maxadvanceheight", "maxextent", + -- "metricdataformat", + "minbottomsidebearing", "mintopsidebearing", + } + local h = fontdata.horizontalheader or { } + local v = fontdata.verticalheader or { } + if h then + local th = { } + local tv = { } + for i=1,#keys do + local key = keys[i] + th[key] = h[key] or 0 + tv[key] = v[key] or 0 + end + info.horizontalmetrics = th + info.verticalmetrics = tv + end + end elseif n then info = { filename = fontdata.filename, @@ -1900,7 +2005,10 @@ local function readdata(f,offset,specification) readers["head"](f,fontdata,specification) readers["maxp"](f,fontdata,specification) readers["hhea"](f,fontdata,specification) + readers["vhea"](f,fontdata,specification) readers["hmtx"](f,fontdata,specification) + readers["vmtx"](f,fontdata,specification) + readers["vorg"](f,fontdata,specification) readers["post"](f,fontdata,specification) readers["cff" ](f,fontdata,specification) readers["cmap"](f,fontdata,specification) @@ -2084,7 +2192,7 @@ function readers.loadfont(filename,n) descriptions = fontdata.descriptions, format = fontdata.format, goodies = { }, - metadata = getinfo(fontdata,n), -- no platformnames here ! + metadata = getinfo(fontdata,n,false,false,true), -- no platformnames here ! properties = { hasitalics = fontdata.hasitalics or false, maxcolorclass = fontdata.maxcolorclass, diff --git a/tex/context/base/mkiv/font-ots.lua b/tex/context/base/mkiv/font-ots.lua index 1c6472027..17e1a3c30 100644 --- a/tex/context/base/mkiv/font-ots.lua +++ b/tex/context/base/mkiv/font-ots.lua @@ -128,6 +128,7 @@ local trace_details = false registertracker("otf.details", function(v local trace_steps = false registertracker("otf.steps", function(v) trace_steps = v end) local trace_skips = false registertracker("otf.skips", function(v) trace_skips = v end) local trace_directions = false registertracker("otf.directions", function(v) trace_directions = v end) +local trace_plugins = false registertracker("otf.plugins", function(v) trace_plugins = v end) local trace_kernruns = false registertracker("otf.kernruns", function(v) trace_kernruns = v end) local trace_discruns = false registertracker("otf.discruns", function(v) trace_discruns = v end) @@ -136,6 +137,7 @@ local trace_testruns = false registertracker("otf.testruns", function(v ----- zwnjruns = true registerdirective("otf.zwnjruns", function(v) zwnjruns = v end) local optimizekerns = true +local alwaysdisc = true registerdirective("otf.alwaysdisc", function(v) alwaysdisc = v end) local report_direct = logs.reporter("fonts","otf direct") local report_subchain = logs.reporter("fonts","otf subchain") @@ -599,7 +601,7 @@ local function toligature(head,start,stop,char,dataset,sequence,markflag,discfou setlink(discfound,next) setboth(base) setfield(base,"components",copied) - setdisc(discfound,pre,post,base,discretionary_code) + setdisc(discfound,pre,post,base) -- was discretionary_code base = prev -- restart end end @@ -3047,7 +3049,11 @@ end -- -- local a = getattr(start,0) -- -- if not a or (a == attr) then -- --- and even that one is probably not needed. +-- and even that one is probably not needed. However, we can handle interesting +-- cases now: +-- +-- 1{2{\oldstyle\discretionary{3}{4}{5}}6}7\par +-- 1{2\discretionary{3{\oldstyle3}}{{\oldstyle4}4}{5{\oldstyle5}5}6}7\par local nesting = 0 @@ -3077,6 +3083,7 @@ local function c_run_single(head,font,attr,lookupcache,step,dataset,sequence,rlm start = getnext(start) end else + -- go on can be a mixed one start = getnext(start) end elseif char == false then @@ -3122,6 +3129,8 @@ local function t_run_single(start,stop,font,attr,lookupcache) return true, d > 1 end end + else + -- go on can be a mixed one end start = getnext(start) else @@ -3207,6 +3216,7 @@ local function c_run_multiple(head,font,attr,steps,nofsteps,dataset,sequence,rlm start = getnext(start) end else + -- go on can be a mixed one start = getnext(start) end elseif char == false then @@ -3261,6 +3271,8 @@ local function t_run_multiple(start,stop,font,attr,steps,nofsteps) report_missing_coverage(dataset,sequence) end end + else + -- go on can be a mixed one end start = getnext(start) else @@ -3324,7 +3336,7 @@ local function k_run_multiple(sub,injection,last,font,attr,steps,nofsteps,datase end end --- to be checkedL nowadays we probably can assume properly matched directions +-- to be checked, nowadays we probably can assume properly matched directions -- so maybe we no longer need a stack local function txtdirstate(start,stack,top,rlparmode) @@ -3365,6 +3377,10 @@ local function pardirstate(start) return getnext(start), new, new end +otf.helpers = otf.helpers or { } +otf.helpers.txtdirstate = txtdirstate +otf.helpers.pardirstate = pardirstate + local function featuresprocessor(head,font,attr) local sequences = sequencelists[font] -- temp hack @@ -3413,6 +3429,8 @@ local function featuresprocessor(head,font,attr) local done = false local datasets = otf.dataset(tfmdata,font,attr) + local forcedisc = alwaysdisc or not attr + local dirstack = { } -- could move outside function but we can have local runs sweephead = { } @@ -3425,7 +3443,7 @@ local function featuresprocessor(head,font,attr) -- Keeping track of the headnode is needed for devanagari (I generalized it a bit -- so that multiple cases are also covered.) - -- We don't goto the next node of a disc node is created so that we can then treat + -- We don't goto the next node when a disc node is created so that we can then treat -- the pre, post and replace. It's a bit of a hack but works out ok for most cases. for s=1,#datasets do @@ -3527,16 +3545,26 @@ local function featuresprocessor(head,font,attr) -- whatever glyph start = getnext(start) elseif id == disc_code then - local ok - if gpossing then - start, ok = kernrun(start,k_run_single, font,attr,lookupcache,step,dataset,sequence,rlmode,handler) - elseif typ == "gsub_ligature" then - start, ok = testrun(start,t_run_single,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + -- ctx: we could assume the same attr as the surrounding glyphs but then we loose + -- the option to have interesting disc nodes (we gain upto 10% on extreme tests); + -- if a disc would have a font field we could even be more strict (see oldstyle test + -- case) + local a = forcedisc or getsubtype(start) == discretionary_code or getattr(start,0) == attr + if a then + -- local attr = false + local ok + if gpossing then + start, ok = kernrun(start,k_run_single, font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + elseif typ == "gsub_ligature" then + start, ok = testrun(start,t_run_single,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + else + start, ok = comprun(start,c_run_single, font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + end + if ok then + success = true + end else - start, ok = comprun(start,c_run_single, font,attr,lookupcache,step,dataset,sequence,rlmode,handler) - end - if ok then - success = true + start = getnext(start) end elseif id == math_code then start = getnext(end_of_math(start)) @@ -3596,16 +3624,22 @@ local function featuresprocessor(head,font,attr) elseif char == false then start = getnext(start) elseif id == disc_code then - local ok - if gpossing then - start, ok = kernrun(start,k_run_multiple, font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) - elseif typ == "gsub_ligature" then - start, ok = testrun(start,t_run_multiple,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + -- see comment above + local a = forcedisc or getsubtype(start) == discretionary_code or getattr(start,0) == attr + if a then + local ok + if gpossing then + start, ok = kernrun(start,k_run_multiple, font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + elseif typ == "gsub_ligature" then + start, ok = testrun(start,t_run_multiple,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + else + start, ok = comprun(start,c_run_multiple, font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + end + if ok then + success = true + end else - start, ok = comprun(start,c_run_multiple, font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) - end - if ok then - success = true + start = getnext(start) end elseif id == math_code then start = getnext(end_of_math(start)) @@ -3637,6 +3671,34 @@ end -- so far +local plugins = { } +otf.plugins = plugins + +function otf.registerplugin(name,f) + if type(name) == "string" and type(f) == "function" then + plugins[name] = { name, f } + end +end + +local function plugininitializer(tfmdata,value) + if type(value) == "string" then + tfmdata.shared.plugin = plugins[value] + end +end + +local function pluginprocessor(head,font) + local s = fontdata[font].shared + local p = s and s.plugin + if p then + if trace_plugins then + report_process("applying plugin %a",p[1]) + end + return p[2](head,font) + else + return head, false + end +end + local function featuresinitializer(tfmdata,value) -- nothing done here any more end @@ -3648,9 +3710,11 @@ registerotffeature { initializers = { position = 1, node = featuresinitializer, + plug = plugininitializer, }, processors = { node = featuresprocessor, + plug = pluginprocessor, } } diff --git a/tex/context/base/mkiv/font-pre.mkiv b/tex/context/base/mkiv/font-pre.mkiv index f12625c46..732a9e6fb 100644 --- a/tex/context/base/mkiv/font-pre.mkiv +++ b/tex/context/base/mkiv/font-pre.mkiv @@ -667,6 +667,8 @@ \definefontfeature[f:oldstyle] [onum=yes] \definefontfeature[f:tabular] [tnum=yes] \definefontfeature[f:superiors][sups=yes] +\definefontfeature[f:kern] [kern=yes] +\definefontfeature[f:kerns] [kern=yes] \definealternativestyle [\v!smallcaps] [\setsmallcaps] [\setsmallcaps] \definealternativestyle [\v!oldstyle] [\setoldstyle ] [\setoldstyle ] @@ -687,7 +689,7 @@ %D %D For tracing purposes we define: -\definefont[tinyfont][dejavusansmono at 1ex] +\definefont[tinyfont][file:dejavusansmono at 1ex] %D \macros %D {infofont} @@ -700,8 +702,8 @@ \let\infofont \relax % satisfy dep checker \let\infofontbold\relax % satisfy dep checker -\definefont[infofont] [dejavusansmono at 6pt] % todo \the\everybodyfont -\definefont[infofontbold][dejavusansmonobold at 6pt] % todo \the\everybodyfont +\definefont[infofont] [file:dejavusansmono at 6pt] % todo \the\everybodyfont +\definefont[infofontbold][file:dejavusansmono-bold at 6pt] % todo \the\everybodyfont %D Optimization (later we overload in math): diff --git a/tex/context/base/mkiv/grph-inc.lua b/tex/context/base/mkiv/grph-inc.lua index aa4d56805..a58e1bbce 100644 --- a/tex/context/base/mkiv/grph-inc.lua +++ b/tex/context/base/mkiv/grph-inc.lua @@ -87,7 +87,12 @@ local trace_conversion = false trackers.register ("graphics.conversion", func local trace_inclusion = false trackers.register ("graphics.inclusion", function(v) trace_inclusion = v end) local trace_usage = false trackers.register ("graphics.usage", function(v) trace_usage = v end) -local extra_check = false directives.register("graphics.extracheck", function(v) extra_check = v end) +local extra_check = false directives.register("graphics.extracheck", function(v) extra_check = v end) +local auto_transform = true directives.register("graphics.autotransform", function(v) auto_transform = v end) + +if LUATEXVERSION <= 1 then + auto_transform = false +end local report_inclusion = logs.reporter("graphics","inclusion") local report_figures = logs.reporter("system","graphics") @@ -1287,6 +1292,44 @@ function existers.generic(askedname,resolve) return result end +-- pdf : 0-3: 0 90 180 270 +-- jpeg: 0 unset 1-4: 0 90 180 270 5-8: flipped r/c + +local transforms = setmetatableindex ( + { + ["orientation-1"] = 0, ["R0"] = 0, + ["orientation-2"] = 4, ["R0MH"] = 4, + ["orientation-3"] = 2, ["R180"] = 2, + ["orientation-4"] = 6, ["R0MV"] = 6, + ["orientation-5"] = 5, ["R270MH"] = 5, + ["orientation-6"] = 3, ["R90"] = 3, + ["orientation-7"] = 7, ["R90MH"] = 7, + ["orientation-8"] = 1, ["R270"] = 1, + }, + function(t,k) -- transforms are 0 .. 7 + local v = tonumber(k) or 0 + if v < 0 or v > 7 then + v = 0 + end + t[k] = v + return v + end +) + +local function checktransform(figure,forced) + if auto_transform then + local orientation = (forced ~= "" and forced ~= v_auto and forced) or figure.orientation or 0 + local transform = transforms["orientation-"..orientation] + print(orientation,figure.orientation,transform) + figure.transform = transform + if math.odd(transform) then + return figure.height, figure.width + else + return figure.width, figure.height + end + end +end + function checkers.generic(data) local dr, du, ds = data.request, data.used, data.status local name = du.fullname or "unknown generic" @@ -1348,8 +1391,10 @@ function checkers.generic(data) end end if figure then - du.width = figure.width - du.height = figure.height + local width, height = checktransform(figure,dr.transform) + -- + du.width = width + du.height = height du.pages = figure.pages du.depth = figure.depth or 0 du.colordepth = figure.colordepth or 0 @@ -1357,6 +1402,8 @@ function checkers.generic(data) du.yresolution = figure.yres or 0 du.xsize = figure.xsize or 0 du.ysize = figure.ysize or 0 + du.rotation = figure.rotation or 0 -- in pdf multiples or 90% in jpeg 1 + du.orientation = figure.orientation or 0 -- jpeg 1 2 3 4 (0=unset) ds.private = figure ds.hash = hash end @@ -1840,6 +1887,7 @@ implement { { "color" }, { "arguments" }, { "repeat" }, + { "transform" }, { "width", "dimen" }, { "height", "dimen" }, } diff --git a/tex/context/base/mkiv/grph-inc.mkiv b/tex/context/base/mkiv/grph-inc.mkiv index d7eb77262..90453b8ed 100644 --- a/tex/context/base/mkiv/grph-inc.mkiv +++ b/tex/context/base/mkiv/grph-inc.mkiv @@ -103,6 +103,7 @@ \c!xmax =, \c!align =\v!none, % New, for Tacos extremely large graphics. \c!crossreference =\v!no, + \c!transform =\v!auto, ] %D Defining figures. @@ -335,6 +336,7 @@ color {\externalfigureparameter\c!color}% unprocessed raw key arguments {\externalfigureparameter\c!arguments}% used for converters repeat {\externalfigureparameter\c!repeat}% + transform {\externalfigureparameter\c!transform}% \ifx\p_width\empty \else width \dimexpr\p_width\relax \fi @@ -541,6 +543,8 @@ \def\figurenaturalheight {\clf_figureused{height}{\number\dimexpr\defaultfigureheight\relax}sp} \def\figurexresolution {\clf_figureused{xresolution}{0}} \def\figureyresolution {\clf_figureused{yresolution}{0}} +\def\figureorientation {\clf_figureused{orientation}{1}} +\def\figurerotation {\clf_figureused{rotation}{0}} \def\figurexsize {\clf_figureused{xsize}{0}} \def\figureysize {\clf_figureused{ysize}{0}} \def\figurecolordepth {\clf_figureused{colordepth}{0}} diff --git a/tex/context/base/mkiv/lang-dis.lua b/tex/context/base/mkiv/lang-dis.lua index 7fd5a6afb..e6ea180b0 100644 --- a/tex/context/base/mkiv/lang-dis.lua +++ b/tex/context/base/mkiv/lang-dis.lua @@ -43,6 +43,9 @@ local disc_code = nodecodes.disc local glyph_code = nodecodes.glyph local discretionary_code = disccodes.discretionary +local explicit_code = disccodes.explicit +local automatic_code = disccodes.automatic +local regular_code = disccodes.regular local a_visualize = attributes.private("visualizediscretionary") local setattribute = tex.setattribute @@ -56,7 +59,7 @@ local expanders = { -- \discretionary return template end, - [disccodes.explicit] = function(d,template) + [explicit_code] = function(d,template) -- \- local pre, post, replace = getdisc(d) local done = false @@ -78,13 +81,13 @@ local expanders = { end if done then -- todo: take existing penalty - setdisc(d,pre,post,replace,discretionary_code,tex.exhyphenpenalty) + setdisc(d,pre,post,replace,explicit_code,tex.exhyphenpenalty) else - setfield(d,"subtype",discretionary_code) + setfield(d,"subtype",explicit_code) end return template end, - [disccodes.automatic] = function(d,template) + [automatic_code] = function(d,template) -- following a - : the pre and post chars are already appended and set -- so we have pre=preex and post=postex .. however, the previous -- hyphen is already injected ... downside: the font handler sees this @@ -115,16 +118,16 @@ local expanders = { else -- can't happen end - setdisc(d,pre,post,replace,discretionary_code,tex.hyphenpenalty) + setdisc(d,pre,post,replace,automatic_code,tex.hyphenpenalty) else -- print("lone regular discretionary ignored") end else - setdisc(d,pre,post,replace,discretionary_code,tex.hyphenpenalty) + setdisc(d,pre,post,replace,automatic_code,tex.hyphenpenalty) end return template end, - [disccodes.regular] = function(d,template) + [regular_code] = function(d,template) if check_regular then -- simple if not template then @@ -155,7 +158,7 @@ local expanders = { setchar(post,postchar) end if done then - setdisc(d,pre,post,replace,discretionary_code,tex.hyphenpenalty) + setdisc(d,pre,post,replace,regular_code,tex.hyphenpenalty) end else -- print("lone regular discretionary ignored") @@ -163,7 +166,7 @@ local expanders = { return template else -- maybe also set penalty here - setsubtype(d,discretionary_code) + setsubtype(d,regular_code) end end, [disccodes.first] = function() diff --git a/tex/context/base/mkiv/lpdf-mis.lua b/tex/context/base/mkiv/lpdf-mis.lua index 5bd0aa29d..8d2e85ad2 100644 --- a/tex/context/base/mkiv/lpdf-mis.lua +++ b/tex/context/base/mkiv/lpdf-mis.lua @@ -197,7 +197,8 @@ local function setupidentity() if author ~= "" then addtoinfo("Author", pdfunicode(author), author) -- '/Author' in /Info, 'Creator' in XMP end - local creator = identity.creator or "" + -- local creator = identity.creator or "" + local creator = "LuaTeX + ConTeXt MkIV" -- has to be the same in CreatorTool if creator ~= "" then addtoinfo("Creator", pdfunicode(creator), creator) -- '/Creator' in /Info, 'CreatorTool' in XMP end diff --git a/tex/context/base/mkiv/lpdf-xmp.lua b/tex/context/base/mkiv/lpdf-xmp.lua index 4dd2e72f2..e63dfa2e0 100644 --- a/tex/context/base/mkiv/lpdf-xmp.lua +++ b/tex/context/base/mkiv/lpdf-xmp.lua @@ -253,18 +253,22 @@ local function flushxmpinfo() commands.pushrandomseed() commands.setrandomseed(os.time()) + + local version = status.luatex_version + local revision = status.luatex_revision + local packetid = "no unique packet id here" -- 24 chars local documentid = "no unique document id here" local instanceid = "no unique instance id here" - local producer = format("LuaTeX-%0.2f.%s",status.luatex_version/100,status.luatex_revision) + local producer = format("LuaTeX-%i.%i.%s",math.div(version,100),math.mod(version,100),revision) local creator = "LuaTeX + ConTeXt MkIV" local time = lpdf.timestamp() local fullbanner = status.banner if included.id ~= "fake" then packetid = randomstring(24) - documentid = "uuid:%s" .. os.uuid() - instanceid = "uuid:%s" .. os.uuid() + documentid = "uuid:" .. os.uuid() + instanceid = "uuid:" .. os.uuid() end pdfaddxmpinfo("DocumentID", documentid) diff --git a/tex/context/base/mkiv/math-del.mkiv b/tex/context/base/mkiv/math-del.mkiv index be78b581f..41dd40a99 100644 --- a/tex/context/base/mkiv/math-del.mkiv +++ b/tex/context/base/mkiv/math-del.mkiv @@ -98,8 +98,11 @@ \edef\p_factor{\mathextensibleparameter\c!factor}% \ifsecondargument \doifassignmentelse{#2} - {\setupcurrentmathextensible[#2]}% + {\setupcurrentmathextensible[#2]% + \edef\p_factor{\mathextensibleparameter\c!factor}}% {\edef\p_factor{#2}}% + \else + \edef\p_factor{\mathextensibleparameter\c!factor}% \fi \Uvextensible axis % can be an option @@ -118,4 +121,31 @@ \definemathextensible[integral][\c!symbol="222B] +\unexpanded\def\autointegral#1#2#3% + {\ifmmode + \setbox\nextbox\mathstylehbox{#3}% + \scratchdimen\ifdim\nextboxht>\nextboxdp\nextboxht\else\nextboxdp\fi + \mathlimop{% + \Uvextensible + height \scratchdimen + depth \scratchdimen + exact% + axis% + \Udelimiter \plusfour \zerocount "222B% + }% + \limits % nolimits needs more work: kerning and so + \normalsuperscript{#1}% + \normalsubscript{#2}% + \box\nextbox + \else + \char"222B\relax + \fi} + +% \startformula +% a = +% \autointegral{t}{b}1 + +% \autointegral{t}{b}{\frac{\frac{3}{4}}{\frac{1}{2}}} + +% \autointegral{t}{b}{\frac{\frac{\frac{\frac{1}{2}}{2}}{2}}{2}} +% \stopformula + \protect \endinput diff --git a/tex/context/base/mkiv/mult-def.lua b/tex/context/base/mkiv/mult-def.lua index 3a244fa4e..7df4ec1ca 100644 --- a/tex/context/base/mkiv/mult-def.lua +++ b/tex/context/base/mkiv/mult-def.lua @@ -11137,6 +11137,10 @@ return { ["totalnumber"]={ ["en"]="totalnumber", }, + ["transform"]={ + ["en"]="transform", + ["nl"]="transformatie", + }, ["translate"]={ ["en"]="translate", }, @@ -14194,6 +14198,10 @@ return { ["pe"]="متصل‌بالا", ["ro"]="unit", }, + ["notjoinedup"]={ + ["en"]="notjoinedup", + ["nl"]="nietaansluitend", + }, ["july"]={ ["cs"]="cervenec", ["de"]="juli", @@ -17655,16 +17663,15 @@ return { ["cd:csname-l"] = { en = "\\..." }, ["cd:noargument-s"] = { en = "\\..." }, ["cd:noargument-l"] = { en = "\\..." }, - ["cd:oneargument-s"] = { en = "\\...#1" }, - ["cd:oneargument-l"] = { en = "\\...#1" }, - ["cd:twoarguments-s"] = { en = "\\...#1#2" }, - ["cd:twoarguments-l"] = { en = "\\...#1#2" }, - ["cd:threearguments-s"] = { en = "\\...#1#2#3" }, - ["cd:threearguments-l"] = { en = "\\...#1#2#3" }, + ["cd:oneargument"] = { en = "\\...#1" }, + ["cd:twoarguments"] = { en = "\\...#1#2" }, + ["cd:threearguments"] = { en = "\\...#1#2#3" }, ["cd:braces-s"] = { en = "{...}", lua = '"..."' }, ["cd:braces-l"] = { en = "{...,...}", lua = '".. ... .."' }, ["cd:brackets-s"] = { en = "[...]", lua = "{ ... }" }, ["cd:brackets-l"] = { en = "[...,...]", lua = "{..., ...}" }, + ["cd:parenthesis-s"] = { en = "(...)" }, + ["cd:parenthesis-l"] = { en = "(...,...)" }, ["cd:index-s"] = { en = "[...]" }, ["cd:index-l"] = { en = "[..+...+..]" }, ["cd:math-s"] = { en = "$...$" }, diff --git a/tex/context/base/mkiv/mult-low.lua b/tex/context/base/mkiv/mult-low.lua index ed0e672d4..3ecb78941 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", "plussixteen", "plushundred", "plustwohundred", "plusthousand", "plustenthousand", "plustwentythousand", "medcard", "maxcard", "maxcardminusone", - "zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxdimen", "scaledpoint", "thousandpoint", + "zeropoint", "onepoint", "halfapoint", "onebasepoint", "maxcount", "maxdimen", "scaledpoint", "thousandpoint", "points", "halfpoint", "zeroskip", "zeromuskip", "onemuskip", diff --git a/tex/context/base/mkiv/mult-prm.lua b/tex/context/base/mkiv/mult-prm.lua index fa6634f66..d0116d263 100644 --- a/tex/context/base/mkiv/mult-prm.lua +++ b/tex/context/base/mkiv/mult-prm.lua @@ -1214,6 +1214,7 @@ return { "suppressifcsnameerror", "suppresslongerror", "suppressoutererror", + "suppressmathparerror", "synctex", "tabskip", "tagcode", diff --git a/tex/context/base/mkiv/page-flw.mkiv b/tex/context/base/mkiv/page-flw.mkiv index 56fe32e5b..afedc3ee2 100644 --- a/tex/context/base/mkiv/page-flw.mkiv +++ b/tex/context/base/mkiv/page-flw.mkiv @@ -75,7 +75,7 @@ \fi \to \everydefinetextflow -\let\b_page_textflow_box\zerocount +\newcount\b_page_textflow_box \def\textflowcollector#1% {\csname\??textflowbox#1\endcsname} diff --git a/tex/context/base/mkiv/page-mrk.mkiv b/tex/context/base/mkiv/page-mrk.mkiv index d84e9c60e..43116e84d 100644 --- a/tex/context/base/mkiv/page-mrk.mkiv +++ b/tex/context/base/mkiv/page-mrk.mkiv @@ -25,12 +25,15 @@ \def\pagecutmarkoffset {3mm} % slightly larger than before, and now a fixed size \def\pagecutmarkmargin{10cm} +% maybe all these should be global + \newconditional\c_page_marks_add_more_color \newconditional\c_page_marks_add_more_marking \newconditional\c_page_marks_add_more_lines \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 @@ -135,6 +138,11 @@ \ifconditional\c_page_marks_add_more_number \page_marks_add_number \fi + \global\advance\c_page_marks_max\minusone + \ifnum\c_page_marks_max>\zerocount\else + \glet\page_marks_add_more\gobbleoneargument + \glet\page_marks_add_page\gobbleoneargument + \fi \egroup} \let\page_marks_add_page\gobbleoneargument @@ -174,13 +182,31 @@ \settrue\c_page_marks_add_more_marking \settrue\c_page_marks_add_more_number} +\installpagecutmark\v!one {\global\c_page_marks_max\plusone} +\installpagecutmark\v!two {\global\c_page_marks_max\plustwo} +\installpagecutmark\v!four{\global\c_page_marks_max\plusfour} + +\unexpanded\def\page_marks_set#1% + {\begincsname\??layoutmarking#1\endcsname} + \appendtoks \setfalse\c_page_marks_add_page_lines \setfalse\c_page_marks_add_more_color \setfalse\c_page_marks_add_more_marking \setfalse\c_page_marks_add_more_lines \setfalse\c_page_marks_add_more_number - \begincsname\??layoutmarking\layoutparameter\c!marking\endcsname + \global\c_page_marks_max\maxcount + \rawprocesscommacommand[\layoutparameter\c!marking]\page_marks_set + \ifnum\c_page_marks_max<\maxcount + \ifconditional\c_page_marks_add_page_lines \else + \ifconditional\c_page_marks_add_more_color \else + \ifconditional\c_page_marks_add_more_marking\else + \ifconditional\c_page_marks_add_more_lines \else + \ifconditional\c_page_marks_add_more_number \else + \settrue\c_page_marks_add_page_lines + \settrue\c_page_marks_add_more_number + \fi\fi\fi\fi\fi + \fi \ifconditional\c_page_marks_add_page_lines \let\page_marks_add_page\page_marks_add_page_indeed \else diff --git a/tex/context/base/mkiv/page-mul.mkiv b/tex/context/base/mkiv/page-mul.mkiv index 5cc60d9ed..fcad2c4c6 100644 --- a/tex/context/base/mkiv/page-mul.mkiv +++ b/tex/context/base/mkiv/page-mul.mkiv @@ -59,7 +59,7 @@ \installcorenamespace {columns} -\installcommandhandler \??columns {columns} \??columns +\installframedcommandhandler \??columns {columns} \??columns %D Going to a new columns is done by means of a \type {\ejectcolumn}. The %D following definition does not always work. @@ -104,7 +104,7 @@ %D A hook: - \let\finishcolumnbox\relax +\let\finishcolumnbox\relax % todo in mkiv %D This will change to a local one: @@ -1457,21 +1457,12 @@ % 3 \input tufte \par \placefigure{}{\framed[width=\hsize,height=3cm]{3}} % \stopcolumns - % \def\backgroundfinishcolumnbox - % {\doifelseinset\@@kloffset{\v!none,\v!overlay} - % {\let\@@kloffset\!!zeropoint} - % {\scratchdimen\@@kloffset - % \advance\scratchdimen -\@@klrulethickness - % \edef\@@kloffset{\the\scratchdimen}}% - % \localframed - % [\??kl] - % [\c!strut=\v!no, - % \c!width=\v!fit, - % \c!height=\v!fit, - % \c!align=]} - - \def\backgroundfinishcolumnbox - {} +\def\backgroundfinishcolumnbox + {\inheritedcolumnsframed} + % [\c!strut=\v!no, + % \c!width=\v!fit, + % \c!height=\v!fit, + % \c!align=]} % to be reconsidered ... (in any case they need to be unexpandable sinze 2011.12.30) @@ -1607,8 +1598,12 @@ \edef\p_option{\columnsparameter\c!option}% \ifx\p_option\v!background \let\finishcolumnbox\backgroundfinishcolumnbox + \doifelseinset{\columnsparameter\c!offset}{\v!none,\v!overlay} + {\d_page_mul_offset\zeropoint}% + {\d_page_mul_offset\dimexpr\columnsparameter\c!offset-\columnsparameter\c!rulethickness\relax}% + \else + \d_page_mul_offset\zeropoint \fi - \d_page_mul_offset\columnsparameter\c!offset\relax \edef\p_command{\columnsparameter\c!command}% \ifx\p_command\empty \else \let\postprocesscolumnline\p_command diff --git a/tex/context/base/mkiv/publ-imp-apa.mkvi b/tex/context/base/mkiv/publ-imp-apa.mkvi index 6aa589478..6470bb089 100644 --- a/tex/context/base/mkiv/publ-imp-apa.mkvi +++ b/tex/context/base/mkiv/publ-imp-apa.mkvi @@ -54,6 +54,7 @@ \setupbtxlist [apa] [\c!alternative=\v!paragraph, + \c!align={normal,verytolerant,stretch}, %\c!width=\v!fit, %\c!distance=.5\emwidth, \c!margin=3.5\emwidth] diff --git a/tex/context/base/mkiv/publ-imp-aps.mkvi b/tex/context/base/mkiv/publ-imp-aps.mkvi index 89e12b3e0..e9cbd7aaf 100644 --- a/tex/context/base/mkiv/publ-imp-aps.mkvi +++ b/tex/context/base/mkiv/publ-imp-aps.mkvi @@ -53,7 +53,8 @@ \setupbtxlist [aps] - [\c!alternative=b] % spaces + [\c!alternative=b, % spaces + \c!align={normal,verytolerant,stretch}] \definebtx [aps:\s!list] diff --git a/tex/context/base/mkiv/publ-imp-default.mkvi b/tex/context/base/mkiv/publ-imp-default.mkvi index 3a88d28ff..564bfcf4e 100644 --- a/tex/context/base/mkiv/publ-imp-default.mkvi +++ b/tex/context/base/mkiv/publ-imp-default.mkvi @@ -23,6 +23,10 @@ \c!sorttype=\v!default, \c!numbering=num] +\setupbtxlist + [default] + [\c!align={normal,verytolerant,stretch}] + \definebtx [\s!default] [\c!default=, % we do not want to fall|-|back on ourself. diff --git a/tex/context/base/mkiv/scrn-ini.mkvi b/tex/context/base/mkiv/scrn-ini.mkvi index 6a4967961..7111e837f 100644 --- a/tex/context/base/mkiv/scrn-ini.mkvi +++ b/tex/context/base/mkiv/scrn-ini.mkvi @@ -182,7 +182,7 @@ % title {\interactionparameter\c!title}% % subtitle {\interactionparameter\c!subtitle}% % author {\interactionparameter\c!author}% -% creator {ConTeXt - \contextversion}% +% % creator {ConTeXt - \contextversion}% % date {\interactionparameter\c!date}% % keywords {\interactionparameter\c!keyword}% % \relax} @@ -218,7 +218,7 @@ title {\interactionparameter\c!title}% subtitle {\interactionparameter\c!subtitle}% author {\interactionparameter\c!author}% - creator {ConTeXt - \contextversion}% + % creator {ConTeXt - \contextversion}% date {\interactionparameter\c!date}% keywords {\interactionparameter\c!keyword}% \relax diff --git a/tex/context/base/mkiv/status-files.pdf b/tex/context/base/mkiv/status-files.pdf index 6013ab1b8..258056fb2 100644 Binary files a/tex/context/base/mkiv/status-files.pdf and b/tex/context/base/mkiv/status-files.pdf differ diff --git a/tex/context/base/mkiv/status-lua.pdf b/tex/context/base/mkiv/status-lua.pdf index c2c701ecc..b7c59e744 100644 Binary files a/tex/context/base/mkiv/status-lua.pdf and b/tex/context/base/mkiv/status-lua.pdf differ diff --git a/tex/context/base/mkiv/strc-itm.mkvi b/tex/context/base/mkiv/strc-itm.mkvi index 33b8aee1d..eaae6a7c7 100644 --- a/tex/context/base/mkiv/strc-itm.mkvi +++ b/tex/context/base/mkiv/strc-itm.mkvi @@ -23,6 +23,10 @@ %D no surprise that I had that cd running several times when updating this %D code. One of the highlights of 2011. +%D This module needs to be rewritten but that is tricky with respect to +%D compatibilitity. Basically each major variant (regular, text, columns, +%D horizontal, etc) needs to be on its own. + % todo: check breaks % todo: check grouping % todo: fixedconversion @@ -406,70 +410,70 @@ \settrue\c_strc_itemgroups_pack \fi} -\setvalue{\??itemgroupkeyword\!!zerocount}{} % ignore 0 -\setvalue{\??itemgroupkeyword\v!packed }{\strc_itemgroups_process_set_option_pack} -\setvalue{\??itemgroupkeyword\v!intro }{\settrue\c_strc_itemgroups_intro} % here? not set to false -\setvalue{\??itemgroupkeyword\v!autointro}{\settrue\c_strc_itemgroups_auto_intro} -\setvalue{\??itemgroupkeyword\v!broad }{\ifx\itemgroupfirst\empty - \let\itemgroupfirst\!!plusone - \fi - \letitemgroupparameter\c!factor\itemgroupfirst} -\setvalue{\??itemgroupkeyword\v!text }{\settrue\c_strc_itemgroups_text - \settrue\c_strc_itemgroups_inline - \settrue\c_strc_itemgroups_joined - \strc_itemgroups_process_set_option_pack} -\setvalue{\??itemgroupkeyword\v!before }{\settrue\c_strc_itemgroups_before} -\setvalue{\??itemgroupkeyword\v!after }{\settrue\c_strc_itemgroups_after} -\setvalue{\??itemgroupkeyword\v!nowhite }{\settrue\c_strc_itemgroups_nowhite} -\setvalue{\??itemgroupkeyword\v!margin }{\setitemgroupparameter\c!width{-2em}} % signal -\setvalue{\??itemgroupkeyword\v!inmargin }{\setitemgroupparameter\c!width{-2em}} % signal -\setvalue{\??itemgroupkeyword\v!atmargin }{\ifnum\c_strc_itemgroups_nesting>\plusone - \setitemgroupparameter\c!width{0em}% - \fi} % signal -\setvalue{\??itemgroupkeyword\v!intext }{\settrue\c_strc_itemgroups_inline} -\setvalue{\??itemgroupkeyword\v!loose }{\setfalse\c_strc_itemgroups_optimize} -\setvalue{\??itemgroupkeyword\v!fit }{\settrue\c_strc_itemgroups_fitting} -\setvalue{\??itemgroupkeyword\v!nofit }{\setfalse\c_strc_itemgroups_fitting} -\setvalue{\??itemgroupkeyword\v!paragraph}{\settrue\c_strc_itemgroups_paragraph - \strc_itemgroups_process_set_option_pack} -\setvalue{\??itemgroupkeyword\v!joinedup }{\settrue\c_strc_itemgroups_joined - \strc_itemgroups_process_set_option_pack} -\setvalue{\??itemgroupkeyword\v!serried }{\edef\itemgroupfirst{-\ifx\itemgroupfirst\empty1\else\itemgroupfirst\fi}% - \letitemgroupparameter\c!factor\itemgroupfirst} -\setvalue{\??itemgroupkeyword\v!stopper }{\letitemgroupparameter\c!placestopper\v!yes} % keep {} -\setvalue{\??itemgroupkeyword\v!unpacked }{\setfalse\c_strc_itemgroups_pack} -\setvalue{\??itemgroupkeyword\v!repeat }{\settrue\c_strc_itemgroups_repeat} -\setvalue{\??itemgroupkeyword\v!norepeat }{\setfalse\c_strc_itemgroups_repeat} -\setvalue{\??itemgroupkeyword\v!reverse }{\settrue\c_strc_itemgroups_reverse} -\setvalue{\??itemgroupkeyword\v!columns }{\settrue\c_strc_itemgroups_columns} -\setvalue{\??itemgroupkeyword\v!one }{\letitemgroupparameter\c!n\plusone} -\setvalue{\??itemgroupkeyword\v!two }{\letitemgroupparameter\c!n\plustwo} -\setvalue{\??itemgroupkeyword\v!three }{\letitemgroupparameter\c!n\plusthree} -\setvalue{\??itemgroupkeyword\v!four }{\letitemgroupparameter\c!n\plusfour} -\setvalue{\??itemgroupkeyword\v!five }{\letitemgroupparameter\c!n\plusfive} -\setvalue{\??itemgroupkeyword\v!six }{\letitemgroupparameter\c!n\plussix} -\setvalue{\??itemgroupkeyword\v!seven }{\letitemgroupparameter\c!n\plusseven} -\setvalue{\??itemgroupkeyword\v!eight }{\letitemgroupparameter\c!n\pluseight} -\setvalue{\??itemgroupkeyword\v!nine }{\letitemgroupparameter\c!n\plusnine} -%setvalue{\??itemgroupkeyword\v!standard }{\setupcurrentitemgroup -% [\c!width =1.5\emwidth,% -% \c!distance =.5\emwidth,% -% \c!factor =0,% -% \c!inner =,% -% \c!beforehead=,% -% \c!afterhead =\blank,% -% \c!before =\blank,% -% \c!inbetween =\blank,% -% \c!after =\blank]} -\setvalue{\??itemgroupkeyword\v!standard }{\setitemgroupparameter\c!width {1.5\emwidth}% - \setitemgroupparameter\c!distance {.5\emwidth}% - \letitemgroupparameter\c!factor \!!zerocount - \letitemgroupparameter\c!inner \empty - \letitemgroupparameter\c!beforehead\empty - \letitemgroupparameter\c!afterhead \blank - \letitemgroupparameter\c!before \blank - \letitemgroupparameter\c!inbetween \blank - \letitemgroupparameter\c!after \blank} +\setvalue{\??itemgroupkeyword\!!zerocount }{} % ignore 0 +\setvalue{\??itemgroupkeyword\v!packed }{\strc_itemgroups_process_set_option_pack} +\setvalue{\??itemgroupkeyword\v!intro }{\settrue\c_strc_itemgroups_intro} % here? not set to false +\setvalue{\??itemgroupkeyword\v!autointro }{\settrue\c_strc_itemgroups_auto_intro} +\setvalue{\??itemgroupkeyword\v!broad }{\ifx\itemgroupfirst\empty + \let\itemgroupfirst\!!plusone + \fi + \letitemgroupparameter\c!factor\itemgroupfirst} +\setvalue{\??itemgroupkeyword\v!text }{\settrue\c_strc_itemgroups_text + \settrue\c_strc_itemgroups_inline + \settrue\c_strc_itemgroups_joined + \strc_itemgroups_process_set_option_pack} +\setvalue{\??itemgroupkeyword\v!before }{\settrue\c_strc_itemgroups_before} +\setvalue{\??itemgroupkeyword\v!after }{\settrue\c_strc_itemgroups_after} +\setvalue{\??itemgroupkeyword\v!nowhite }{\settrue\c_strc_itemgroups_nowhite} +\setvalue{\??itemgroupkeyword\v!margin }{\setitemgroupparameter\c!width{-2em}} % signal +\setvalue{\??itemgroupkeyword\v!inmargin }{\setitemgroupparameter\c!width{-2em}} % signal +\setvalue{\??itemgroupkeyword\v!atmargin }{\ifnum\c_strc_itemgroups_nesting>\plusone + \setitemgroupparameter\c!width{0em}% + \fi} % signal +\setvalue{\??itemgroupkeyword\v!intext }{\settrue\c_strc_itemgroups_inline} +\setvalue{\??itemgroupkeyword\v!loose }{\setfalse\c_strc_itemgroups_optimize} +\setvalue{\??itemgroupkeyword\v!fit }{\settrue\c_strc_itemgroups_fitting} +\setvalue{\??itemgroupkeyword\v!nofit }{\setfalse\c_strc_itemgroups_fitting} +\setvalue{\??itemgroupkeyword\v!paragraph }{\settrue\c_strc_itemgroups_paragraph + \strc_itemgroups_process_set_option_pack} +\setvalue{\??itemgroupkeyword\v!joinedup }{\settrue\c_strc_itemgroups_joined + \strc_itemgroups_process_set_option_pack} +\setvalue{\??itemgroupkeyword\v!notjoinedup}{\setfalse\c_strc_itemgroups_joined} +\setvalue{\??itemgroupkeyword\v!serried }{\edef\itemgroupfirst{-\ifx\itemgroupfirst\empty1\else\itemgroupfirst\fi}% + \letitemgroupparameter\c!factor\itemgroupfirst} +\setvalue{\??itemgroupkeyword\v!stopper }{\letitemgroupparameter\c!placestopper\v!yes} % keep {} +\setvalue{\??itemgroupkeyword\v!repeat }{\settrue\c_strc_itemgroups_repeat} +\setvalue{\??itemgroupkeyword\v!norepeat }{\setfalse\c_strc_itemgroups_repeat} +\setvalue{\??itemgroupkeyword\v!reverse }{\settrue\c_strc_itemgroups_reverse} +\setvalue{\??itemgroupkeyword\v!columns }{\settrue\c_strc_itemgroups_columns} +\setvalue{\??itemgroupkeyword\v!one }{\letitemgroupparameter\c!n\plusone} +\setvalue{\??itemgroupkeyword\v!two }{\letitemgroupparameter\c!n\plustwo} +\setvalue{\??itemgroupkeyword\v!three }{\letitemgroupparameter\c!n\plusthree} +\setvalue{\??itemgroupkeyword\v!four }{\letitemgroupparameter\c!n\plusfour} +\setvalue{\??itemgroupkeyword\v!five }{\letitemgroupparameter\c!n\plusfive} +\setvalue{\??itemgroupkeyword\v!six }{\letitemgroupparameter\c!n\plussix} +\setvalue{\??itemgroupkeyword\v!seven }{\letitemgroupparameter\c!n\plusseven} +\setvalue{\??itemgroupkeyword\v!eight }{\letitemgroupparameter\c!n\pluseight} +\setvalue{\??itemgroupkeyword\v!nine }{\letitemgroupparameter\c!n\plusnine} +%setvalue{\??itemgroupkeyword\v!standard }{\setupcurrentitemgroup +% [\c!width =1.5\emwidth,% +% \c!distance =.5\emwidth,% +% \c!factor =0,% +% \c!inner =,% +% \c!beforehead=,% +% \c!afterhead =\blank,% +% \c!before =\blank,% +% \c!inbetween =\blank,% +% \c!after =\blank]} +\setvalue{\??itemgroupkeyword\v!standard }{\setitemgroupparameter\c!width {1.5\emwidth}% + \setitemgroupparameter\c!distance {.5\emwidth}% + \letitemgroupparameter\c!factor \!!zerocount + \letitemgroupparameter\c!inner \empty + \letitemgroupparameter\c!beforehead\empty + \letitemgroupparameter\c!afterhead \blank + \letitemgroupparameter\c!before \blank + \letitemgroupparameter\c!inbetween \blank + \letitemgroupparameter\c!after \blank} \def\strc_itemgroups_initialize_local @@ -1664,7 +1668,14 @@ \c_strc_itemgroups_collected_done \zerocount \c_strc_itemgroups_collected_current\zerocount \ifnum\c_strc_itemgroups_collected_stored>\zerocount - \doubleexpandafter\strc_itemgroups_collected_flush + \ifconditional\c_strc_itemgroups_horizontal + \strc_itemgroups_before_command + \setfalse\c_strc_itemgroups_first + \strc_itemgroups_collected_flush + %\strc_itemgroups_after_command % triggered elsewhere + \else + \strc_itemgroups_collected_flush + \fi \fi \fi} diff --git a/tex/context/base/mkiv/syst-ini.mkiv b/tex/context/base/mkiv/syst-ini.mkiv index 02f0d89f6..808aa820c 100644 --- a/tex/context/base/mkiv/syst-ini.mkiv +++ b/tex/context/base/mkiv/syst-ini.mkiv @@ -394,6 +394,7 @@ \newdimen \onepoint \onepoint = 1pt \newdimen \halfapoint \halfapoint = 0.5pt \newdimen \maxdimen \maxdimen = 16383.99999pt +\newcount \maxcount \maxcount = 2147483647 \newdimen \onebasepoint \onebasepoint = 1bp \newdimen \scaledpoint \scaledpoint = 1sp \newdimen \thousandpoint \thousandpoint = 1000pt diff --git a/tex/context/base/mkiv/tabl-tbl.mkiv b/tex/context/base/mkiv/tabl-tbl.mkiv index a9ba36087..81d2b3c4e 100644 --- a/tex/context/base/mkiv/tabl-tbl.mkiv +++ b/tex/context/base/mkiv/tabl-tbl.mkiv @@ -1241,10 +1241,12 @@ % {\starttabulate[|||] \NC test \NC test \NC \NR \stoptabulate} {} % \stopcombination -\let\tabl_tabulate_inside_after \relax -\let\tabl_tabulate_outside_after\relax +\let\tabl_tabulate_inside_after \relax +\let\tabl_tabulate_outside_after \relax +\let\tabl_tabulate_inside_inbetween \relax +\let\tabl_tabulate_outside_inbetween\relax -\def\tabl_tabulate_inside_before +\unexpanded\def\tabl_tabulate_inside_before {\ifhmode\par\fi \ifhmode \ifinsidesplitfloat @@ -1257,7 +1259,7 @@ \let\tabl_tabulate_inside_after\relax \fi} -\def\tabl_tabulate_outside_before +\unexpanded\def\tabl_tabulate_outside_before {\ifhmode\par\fi \ifhmode \vbox\bgroup @@ -1269,6 +1271,7 @@ \else \whitespace \tabulationparameter\c!before + \relax \let\tabl_tabulate_outside_after \tabl_tabulate_outside_after_indeed \let\tabl_tabulate_outside_inbetween\tabl_tabulate_outside_inbetween_indeed \fi\fi} @@ -1282,7 +1285,7 @@ \verticalstrut \vskip-\struttotal}} -\def\tabl_tabulate_outside_inbetween +\def\tabl_tabulate_inside_inbetween % needs checking {\doifempty{\tabulationparameter\c!after} {\vskip\strutdp \verticalstrut diff --git a/tex/context/base/mkiv/task-ini.lua b/tex/context/base/mkiv/task-ini.lua index 3f13ce0d7..59500c9b6 100644 --- a/tex/context/base/mkiv/task-ini.lua +++ b/tex/context/base/mkiv/task-ini.lua @@ -49,13 +49,15 @@ appendaction("processors", "words", "typesetters.firstlines.handler") appendaction("processors", "fonts", "builders.paragraphs.solutions.splitters.split") -- experimental appendaction("processors", "fonts", "nodes.handlers.characters") -- maybe todo -appendaction("processors", "fonts", "nodes.injections.handler") -- maybe todo +appendaction("processors", "fonts", "nodes.injections.handler") +appendaction("processors", "fonts", "typesetters.fontkerns.handler") appendaction("processors", "fonts", "nodes.handlers.protectglyphs", nil, "nohead") -- maybe todo appendaction("processors", "fonts", "builders.kernel.ligaturing") -- always on (could be selective: if only node mode) appendaction("processors", "fonts", "builders.kernel.kerning") -- always on (could be selective: if only node mode) appendaction("processors", "fonts", "nodes.handlers.stripping") -- disabled (might move) ------------("processors", "fonts", "typesetters.italics.handler") -- disabled (after otf/kern handling) +appendaction("processors", "lists", "typesetters.rubies.check") -- disabled (maybe someplace else) appendaction("processors", "lists", "typesetters.characteralign.handler") -- disabled (we need to to this after otf appliance) appendaction("processors", "lists", "typesetters.spacings.handler") -- disabled appendaction("processors", "lists", "typesetters.kerns.handler") -- disabled @@ -78,6 +80,7 @@ appendaction("shipouts", "normalizers", "nodes.handlers.accessibility") appendaction("shipouts", "normalizers", "nodes.handlers.backgrounds") -- disabled appendaction("shipouts", "normalizers", "nodes.handlers.alignbackgrounds") -- disabled ------------("shipouts", "normalizers", "nodes.handlers.export") -- disabled +appendaction("shipouts", "normalizers", "typesetters.rubies.attach") -- disabled appendaction("shipouts", "finishers", "nodes.visualizers.handler") -- disabled appendaction("shipouts", "finishers", "attributes.colors.handler") -- disabled @@ -167,6 +170,8 @@ disableaction("processors", "typesetters.italics.handler") disableaction("processors", "languages.visualizediscretionaries") disableaction("processors", "nodes.handlers.stripping") disableaction("processors", "builders.paragraphs.solutions.splitters.split") +disableaction("processors", "nodes.rubies.check") +disableaction("processors", "typesetters.fontkerns.handler") disableaction("shipouts", "typesetters.margins.finalhandler") disableaction("shipouts", "builders.paragraphs.expansion.trace") @@ -187,6 +192,8 @@ disableaction("shipouts", "nodes.handlers.alignbackgrounds") disableaction("shipouts", "nodes.references.handler") disableaction("shipouts", "nodes.destinations.handler") -------------("shipouts", "nodes.handlers.export") +disableaction("shipouts","nodes.rubies.attach") + disableaction("finalizers", "typesetters.margins.localhandler") disableaction("finalizers", "builders.paragraphs.keeptogether") diff --git a/tex/context/base/mkiv/trac-vis.lua b/tex/context/base/mkiv/trac-vis.lua index ef73d2182..27ec38f42 100644 --- a/tex/context/base/mkiv/trac-vis.lua +++ b/tex/context/base/mkiv/trac-vis.lua @@ -508,9 +508,13 @@ end) local function ruledbox(head,current,vertical,layer,what,simple,previous,trace_origin,parent) local wd = getfield(current,"width") if wd ~= 0 then - local ht = getfield(current,"height") - local dp = getfield(current,"depth") + local ht = getfield(current,"height") + local dp = getfield(current,"depth") local shift = getfield(current,"shift") + local dir = getfield(current,"dir") +-- if dir == "LTL" or dir == "RRT" then +-- wd, ht, dp = ht + dp, wd, 0 +-- end local next = getnext(current) local prev = previous -- local prev = getprev(current) -- prev can be wrong in math mode < 0.78.3 @@ -635,12 +639,16 @@ local function ruledbox(head,current,vertical,layer,what,simple,previous,trace_o end end -local function ruledglyph(head,current,previous) +local function ruledglyph(head,current,previous) -- wrong for vertical glyphs local wd = getfield(current,"width") -- local wd = chardata[getfont(current)][getchar(current)].width if wd ~= 0 then - local ht = getfield(current,"height") - local dp = getfield(current,"depth") + local ht = getfield(current,"height") + local dp = getfield(current,"depth") +-- local dir = getfield(current,"dir") +-- if dir == "LTL" or dir = "RTT" then +-- wd, ht, dp = ht + dp, wd, 0 +-- end local next = getnext(current) local prev = previous setboth(current) diff --git a/tex/context/base/mkiv/typo-fkr.lua b/tex/context/base/mkiv/typo-fkr.lua new file mode 100644 index 000000000..1de554b57 --- /dev/null +++ b/tex/context/base/mkiv/typo-fkr.lua @@ -0,0 +1,123 @@ +if not modules then modules = { } end modules ['typo-fkr'] = { + version = 1.001, + comment = "companion to typo-fkr.mkiv", + author = "Hans Hagen, PRAGMA-ADE, Hasselt NL", + copyright = "PRAGMA ADE / ConTeXt Development Team", + license = "see context related readme files" +} + +local nuts = nodes.nuts +local tonut = nuts.tonut +local getid = nuts.getid +local getnext = nuts.getnext +local getchar = nuts.getchar +local getfont = nuts.getfont +local getattr = nuts.getattr + +local nodecodes = nodes.nodecodes +local glyph_code = nodecodes.glyph + +local fontdata = fonts.hashes.identifiers +local getkernpair = fonts.handlers.otf.getkern + +local insert_before = nuts.insert_before +local new_kern = nuts.pool.fontkern + +local a_extrakern = attributes.private("extrafontkern") + +-- 0=none 1=min 2=max 3=mixed + +typesetters.fontkerns = { } + +function typesetters.fontkerns.handler(head) + local kepthead = head + local head = tonut(head) + local current = head + local lastfont = nil + local lastchar = nil + local lastdata = nil + local done = false + while current do + local id = getid(current) + if id == glyph_code then + local a = getattr(current,a_extrakern) + if a then + local char = getchar(current) + local font = getfont(current) + if font ~= lastfont then + if a > 0 and lastchar then + if not lastdata then + lastdata = fontdata[lastfont] + end + local kern = nil + local data = fontdata[font] + local kern1 = getkernpair(lastdata,lastchar,char) + local kern2 = getkernpair(data,lastchar,char) + if a == 1 then + kern = kern1 > kern2 and kern2 or kern1 -- min + elseif a == 2 then + kern = kern1 > kern2 and kern1 or kern2 -- max + else -- 3 + kern = (kern1 + kern2)/2 -- mixed + end + if kern ~= 0 then + head, current = insert_before(head,current,new_kern(kern)) + done = true + end + lastdata = data + else + lastdata = nil + end + elseif lastchar then + if not lastdata then + lastdata = fontdata[lastfont] + end + local kern = getkernpair(lastdata,lastchar,char) + if kern ~= 0 then + head, current = insert_before(head,current,new_kern(kern)) + done = true + end + end + lastchar = char + lastfont = font + elseif lastfont then + lastfont = nil + lastchar = nil + lastdata = nil + end + elseif lastfont then + lastfont = nil + lastchar = nil + lastdata = nil + end + current = getnext(current) + end + return kepthead, done +end + +local variables = interfaces.variables +local unsetvalue = attributes.unsetvalue +local enabled = false +local setattribute = tex.setattribute + +local values = { + [variables.none ] = 0, + [variables.min ] = 1, + [variables.max ] = 2, + [variables.mixed] = 3, + [variables.reset] = unsetvalue, +} + +local function setextrafontkerns(str) + if not enabled then + nodes.tasks.enableaction("processors","typesetters.fontkerns.handler") + enabled = true + end + setattribute(a_extrakern,values[str] or unsetvalue) +end + +interfaces.implement { + name = "setextrafontkerns", + arguments = "string", + actions = setextrafontkerns, +} diff --git a/tex/context/base/mkiv/typo-fkr.mkiv b/tex/context/base/mkiv/typo-fkr.mkiv new file mode 100644 index 000000000..684d831bc --- /dev/null +++ b/tex/context/base/mkiv/typo-fkr.mkiv @@ -0,0 +1,38 @@ +%D \module +%D [ file=typo-fkr, +%D version=2016.10.10, +%D title=\CONTEXT\ Typesetting Macros, +%D subtitle=Additional Font Kerning, +%D author=Hans Hagen, +%D date=\currentdate, +%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}] +%C +%C This module is part of the \CONTEXT\ macro||package and is +%C therefore copyrighted by \PRAGMA. See mreadme.pdf for +%C details. + +\writestatus{loading}{ConTeXt Typesetting Macros / Additional Font Kerning} + +\registerctxluafile{typo-fkr}{1.001} + +\definesystemattribute[extrafontkern][public] + +\unprotect + +% none : not across fonts (but still within) +% min : min value across fonts +% max : max value across fonts +% mixed : mean value across fonts +% reset : disable + +\unexpanded\def\setextrafontkerns[#1]% + {\clf_setextrafontkerns{#1}} + +\unexpanded\def\resetextrafontkerns + {\attribute\extrafontkernattribute\attributeunsetvalue} + +\appendtoks + \resetextrafontkerns +\to \everyresettypesetting + +\protect diff --git a/tex/context/base/mkiv/typo-rub.lua b/tex/context/base/mkiv/typo-rub.lua new file mode 100644 index 000000000..f101668b6 --- /dev/null +++ b/tex/context/base/mkiv/typo-rub.lua @@ -0,0 +1,405 @@ +if not modules then modules = { } end modules ['typo-rub'] = { + version = 1.001, + comment = "companion to typo-rub.mkiv", + author = "Hans Hagen, PRAGMA-ADE, Hasselt NL", + copyright = "PRAGMA ADE / ConTeXt Development Team", + license = "see context related readme files" +} + +-- todo: recycle slots better +-- todo: hoffset +-- todo: auto-increase line height +-- todo: only hpack when start <> stop + +-- A typical bit of afternoon hackery ... with some breaks for watching +-- Ghost-Note on youtube (Robert Searight and Nate Werth) ... which expands +-- my to-be-had cd/dvd list again. + +local lpegmatch = lpeg.match +local utfcharacters = utf.characters +local setmetatableindex = table.setmetatableindex + +local variables = interfaces.variables +local implement = interfaces.implement + +local texsetattribute = tex.setattribute + +local v_flushleft = variables.flushleft +local v_middle = variables.middle +local v_flushright = variables.flushright +local v_yes = variables.yes +local v_no = variables.no +local v_auto = variables.auto + +local nuts = nodes.nuts + +local tonut = nodes.tonut +local tonode = nodes.tonode +local getid = nuts.getid +local getsubtype = nuts.getsubtype +local getattr = nuts.getattr +local setattr = nuts.setattr +local getfield = nuts.getfield +local setfield = nuts.setfield +local getnext = nuts.getnext +local setnext = nuts.setnext +local getprev = nuts.getprev +local setprev = nuts.setprev +local setlink = nuts.setlink +local getlist = nuts.getlist +local setlist = nuts.setlist +local hpack = nuts.hpack +local insert_after = nuts.insert_after +local takebox = nuts.takebox + +local nodecodes = nodes.nodecodes +local glyph_code = nodecodes.glyph +local disc_code = nodecodes.disc +local kern_code = nodecodes.kern +local glue_code = nodecodes.glue +local penalty_code = nodecodes.penalty +local hlist_code = nodecodes.hlist +local vlist_code = nodecodes.vlist +local whatsit_code = nodecodes.whatsit +local localpar_code = nodecodes.localpar + +local whatsitcodes = nodes.whatsitcodes +----- late_luacode = whatsitcodes.latelua + +local kerncodes = nodes.kerncodes +local font_code = kerncodes.font + +local nodepool = nuts.pool +local new_hlist = nodepool.hlist +local new_kern = nodepool.kern + +local setprop = nuts.setprop +local getprop = nuts.getprop + +local nofrubies = 0 +local rubylist = { } + +local a_ruby = attributes.private("ruby") + +local rubies = { } +typesetters.rubies = rubies + +local trace_rubies = false trackers.register("typesetters.rubies",function(v) trace_rubies = v end) +local report_rubies = logs.reporter("rubies") + +do + + local shared = nil + local splitter = lpeg.tsplitat("|") + + local function enable() + nodes.tasks.enableaction("processors","typesetters.rubies.check") + nodes.tasks.enableaction("shipouts", "typesetters.rubies.attach") + enable = false + end + + local ctx_setruby = context.core.setruby + + local function ruby(settings) + local base = settings.base + local comment = settings.comment + shared = settings + local c = lpegmatch(splitter,comment) + if #c == 1 then + ctx_setruby(base,comment) + if trace_rubies then + report_rubies("- %s -> %s",base,comment) + end + else + local i = 0 + for b in utfcharacters(base) do + i = i + 1 + local r = c[i] + if r then + ctx_setruby(b,r) + if trace_rubies then + report_rubies("%i: %s -> %s",i,b,r) + end + else + ctx_setruby(b,"") + if trace_rubies then + report_rubies("%i: %s",i,b) + end + end + end + end + if enable then + enable() + end + end + + local function startruby(settings) + shared = settings + if enable then + enable() + end + end + + implement { + name = "ruby", + actions = ruby, + arguments = { + { + { "align" }, + { "stretch" }, + { "hoffset", "dimension" }, + { "voffset", "dimension" }, + { "comment" }, + { "base" }, + } + }, + } + + implement { + name = "startruby", + actions = startruby, + arguments = { + { + { "align" }, + { "stretch" }, + { "hoffset", "dimension" }, + { "voffset", "dimension" }, + } + }, + } + + local function setruby(n,m) + nofrubies = nofrubies + 1 + local r = takebox(n) + rubylist[nofrubies] = setmetatableindex({ + text = r, + width = getfield(r,"width"), + basewidth = 0, + start = false, + stop = false, + }, shared) + texsetattribute(a_ruby,nofrubies) + end + + implement { + name = "setruby", + actions = setruby, + arguments = "integer", + } + +end + +function rubies.check(head) + local head = tonut(head) + local current = head + local start = nil + local stop = nil + local found = nil + + local function flush(where) + local r = rubylist[found] + if r then + local prev = getprev(start) + local next = getnext(stop) + setprev(start) + setnext(stop) + local h = hpack(start) + if prev == head then + head = h + else + setlink(prev,h) + end + setlink(h,next) + local bwidth = getfield(h,"width") + local rwidth = r.width + r.basewidth = bwidth + r.start = start + r.stop = stop + setprop(h,"ruby",found) + if rwidth > bwidth then + -- ruby is wider + setfield(h,"width",rwidth) + end + end + end + + while current do + local nx = getnext(current) + local id = getid(current) + if id == glyph_code then + local a = getattr(current,a_ruby) + if not a then + if found then + flush("flush 1") + found = nil + end + elseif a == found then + stop = current + else + if found then + flush("flush 2") + end + found = a + start = current + stop = current + end + elseif id == kern_code and getsubtype(current,font_code) then + -- go on + elseif found and id == disc_code then + -- go on (todo: look into disc) + elseif found then + flush("flush 4") + found = nil + end + current = nx + end + if found then + flush("flush 5") + end + return tonode(head), true +end + +local function attach(head,parent) + local current = head + while current do + local id = getid(current) + if id == hlist_code then + local a = getprop(current,"ruby") + if a then + local ruby = rubylist[a] + local align = ruby.align or v_middle + local stretch = ruby.stretch or v_no + local hoffset = ruby.hoffset or 0 + local voffset = ruby.voffset or 0 + local start = ruby.start + local stop = ruby.stop + local text = ruby.text + local rwidth = ruby.width + local bwidth = ruby.basewidth + local delta = rwidth - bwidth + setfield(text,"width",0) + if voffset ~= 0 then + setfield(text,"shift",voffset) + end + -- center them + if delta > 0 then + -- ruby is wider + if stretch == v_yes then + setlink(text,start) + while start and start ~= stop do + local s = nodepool.stretch() + local n = getnext(start) + setlink(start,s) + setlink(s,n) + start = n + end + text = hpack(text,rwidth,"exactly") + else + local left = new_kern(delta/2) + local right = new_kern(delta/2) + setlink(left,start) + setlink(stop,right) + setlink(text,left) + end + setlist(current,text) + elseif delta < 0 then + -- ruby is narrower + if align == v_auto then + local l = true + local c = getprev(current) + while c do + local id = getid(c) + if id == glue_code or id == penalty_code or id == kern_code or (id == whatsit_code and getsubtype(current,localpar_code)) then + -- go on + elseif id == hlist_code and getfield(c,"width") == 0 then + -- go on + elseif id == whatsit_code or id == localpar_code then + -- go on + else + l = false + break + end + c = getprev(c) + end + local r = true + local c = getnext(current) + while c do + local id = getid(c) + if id == glue_code or id == penalty_code or id == kern_code then + -- go on + elseif id == hlist_code and getfield(c,"width") == 0 then + -- go on + else + r = false + break + end + c = getnext(c) + end + if l and not r then + align = v_flushleft + elseif r and not l then + align = v_flushright + else + align = v_middle + end + end + if align == v_flushleft then + setlink(text,start) + setlist(current,text) + elseif align == v_flushright then + local left = new_kern(-delta) + local right = new_kern(delta) + setlink(left,text) + setlink(text,right) + setlink(right,start) + setlist(current,left) + else + local left = new_kern(-delta/2) + local right = new_kern(delta/2) + setlink(left,text) + setlink(text,right) + setlink(right,start) + setlist(current,left) + end + else + setlink(text,start) + setlist(current,text) + end + setprop(current,"ruby",false) + rubylist[a] = nil + else + attach(getlist(current),current) + end + elseif id == vlist_code then + attach(getlist(current),current) + end + current = getnext(current) + end + return head, true +end + +function rubies.attach(head) + local h, d = attach(tonut(head)) + return tonode(h), d +end + +-- for now there is no need to be compact + +-- local data = { } +-- rubies.data = data +-- +-- function rubies.define(settings) +-- data[#data+1] = settings +-- return #data +-- end +-- +-- implement { +-- name = "defineruby", +-- actions = { rubies.define, context }, +-- arguments = { +-- { +-- { "align" }, +-- { "stretch" }, +-- } +-- } +-- } diff --git a/tex/context/base/mkiv/typo-rub.mkiv b/tex/context/base/mkiv/typo-rub.mkiv new file mode 100644 index 000000000..0ebc1d4a4 --- /dev/null +++ b/tex/context/base/mkiv/typo-rub.mkiv @@ -0,0 +1,170 @@ +%D \module +%D [ file=typo-rub, +%D version=2016.10.10, +%D title=\CONTEXT\ Typesetting Macros, +%D subtitle=Rubies, +%D author=Hans Hagen, +%D date=\currentdate, +%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}] +%C +%C This module is part of the \CONTEXT\ macro||package and is +%C therefore copyrighted by \PRAGMA. See mreadme.pdf for +%C details. + +%D Experimental and unfinished. + +% todo: distance + +\writestatus{loading}{ConTeXt Typesetting Macros / Rubies} + +\unprotect + +\registerctxluafile{typo-rub}{1.001} + +\definesystemattribute[ruby] + +\installcorenamespace {ruby} +\installcorenamespace {rubyanalyze} +\installcorenamespace {rubyplacement} + +\installcommandhandler \??ruby {ruby} \??ruby + +% \appendtoks +% \clf_defineruby +% align {\rubyparameter\c!align} +% stretch {\rubyparameter\c!stretch} +% hoffset \rubyparameter\c!hoffset +% voffset \rubyparameter\c!voffset +% \relax +% \to \everydefineruby + +\unexpanded\def\ruby + {\dosingleempty\typo_ruby_yes} + +\unexpanded\def\typo_ruby_yes[#1]#2#3% + {\dontleavehmode + \begingroup + \let\typo_ruby_yes\typo_ruby_nop % no nesting + \edef\currentruby{#1}% + \edef\p_location{\rubyparameter\c!location}% + \let|\relax + \ifcsname\??rubyanalyze\p_location\endcsname + \expandafter\lastnamedcs\else\expandafter\typo_ruby_analyze + \fi{#2}{#3}% + \endgroup} + +\unexpanded\def\typo_ruby_nop[#1]#2#3% + {#2} + +\def\typo_ruby_analyze#1#2% + {\clf_ruby + base {#1}% + comment {#2} + \relax} + +\setvalue{\??rubyanalyze\v!top}#1#2% + {\clf_ruby + align {\rubyparameter\c!align}% + stretch {\rubyparameter\c!stretch}% + hoffset \rubyparameter\c!hoffset + voffset \rubyparameter\c!voffset + base {#1}% + comment {#2} + \relax} + +\setvalue{\??rubyplacement\v!top}#1#2% + {\setbox\scratchbox\hbox\bgroup + \userubystyleandcolor\c!style\c!color + #2% + \egroup + \clf_setruby \scratchbox + \relax + #1} + +\setvalue{\??rubyplacement\v!right}#1#2% + {#1% + \edef\p_distance{\rubyparameter\c!distance}% + \ifx\p_distance\empty\else\ifx\p_distance\v!none\else\hskip\p_distance\fi\fi + \begingroup + \userubystyleandcolor\c!style\c!color + \rubyparameter\c!left#2\rubyparameter\c!right + \endgroup} + +\setvalue{\??rubyplacement\v!left}#1#2% + {\begingroup + \userubystyleandcolor\c!style\c!color + \rubyparameter\c!left#2\rubyparameter\c!right + \endgroup + \edef\p_distance{\rubyparameter\c!distance}% + \ifx\p_distance\empty\else\ifx\p_distance\v!none\else\hskip\p_distance\fi\fi + #1} + +\unexpanded\def\setruby#1#2% + {\begingroup + \ifcsname\??rubyplacement\p_location\endcsname + \lastnamedcs{#1}{#2}% + \else + #1% + \fi + \endgroup} + +\unexpanded\def\startruby + {\dosingleempty\typo_ruby_start_yes} + +\unexpanded\def\typo_ruby_start_yes[#1]% + {\dontleavehmode + \begingroup + \let\typo_ruby_start_yes\begingroup + \edef\currentruby{#1}% + \clf_startruby + align {\rubyparameter\c!align}% + stretch {\rubyparameter\c!stretch}% + hoffset \rubyparameter\c!hoffset + voffset \rubyparameter\c!voffset + \relax} + +\unexpanded\def\stopruby + {\endgroup} + +\setupruby + [\c!style=\txx, + \c!location=\v!top, + \c!left=(, + \c!right=), + \c!distance=\zeropoint, % \v!none means no skip at all so no break either + \c!hoffset=\zeropoint, + \c!voffset=-2\exheight] + +\protect \endinput + +% \usemodule[art-01]\setupbodyfont[dejavu,12pt] +% +% \defineruby[auto] [align=auto,color=darkred] +% \defineruby[left] [align=flushleft,color=darkred] +% \defineruby[right] [align=flushright,color=darkred] +% \defineruby[spread][stretch=yes] +% +% \showframe \showglyphs \showfontkerns \setupinterlinespace[22pt] +% +% \starttext +% +% \startbuffer +% \dorecurse{20}{\ruby{XYZ}{a|bc|d} }\par +% \dorecurse{20}{\ruby{PQR}{p|q|r} }\par +% \dorecurse{20}{\ruby{XYZ}{1|22|333} }\par +% \dorecurse{20}{\ruby{XYZ}{111|222|333} }\par +% \dorecurse{20}{\ruby{XYZ}{foobar} }\par +% \dorecurse{20}{\ruby{XYZ}{fooledbar} }\par +% \dorecurse{20}{\ruby[spread]{XYZ}{fooledbar} }\par +% \dorecurse{20}{\ruby{extremely}{wide} }\par +% \dorecurse{20}{\ruby{wide}{extremely} }\par +% stopbuffer +% +% \testfeatureonce{1}{\start \setupinterlinespace[16pt] \setupruby[location=none] \getbuffer \stop \page} +% \testfeatureonce{1}{\start \setupinterlinespace[16pt] \setupruby[location=right] \getbuffer \stop \page} +% \testfeatureonce{1}{\start \setupinterlinespace[28pt] \setupruby[align=auto,color=darkred] \getbuffer \stop \page} +% \testfeatureonce{1}{\start \setupinterlinespace[28pt] \setupruby[align=flushleft,color=darkgreen] \getbuffer \stop \page} +% \testfeatureonce{1}{\start \setupinterlinespace[28pt] \setupruby[align=flushright,color=darkblue] \getbuffer \stop \page} +% \testfeatureonce{1}{\start \setupinterlinespace[28pt] \setupruby[align=middle,color=darkyellow] \getbuffer \stop \page} +% +% \stoptext diff --git a/tex/context/base/mkiv/util-fil.lua b/tex/context/base/mkiv/util-fil.lua index eeb6856c6..eb054a5fd 100644 --- a/tex/context/base/mkiv/util-fil.lua +++ b/tex/context/base/mkiv/util-fil.lua @@ -109,6 +109,10 @@ function files.readcardinal2(f) local a, b = byte(f:read(2),1,2) return 0x100 * a + b end +function files.readcardinal2le(f) + local b, a = byte(f:read(2),1,2) + return 0x100 * a + b +end function files.readinteger2(f) local a, b = byte(f:read(2),1,2) @@ -120,11 +124,25 @@ function files.readinteger2(f) return n end end +function files.readinteger2le(f) + local b, a = byte(f:read(2),1,2) + local n = 0x100 * a + b + if n >= 0x8000 then + -- return n - 0xFFFF - 1 + return n - 0x10000 + else + return n + end +end function files.readcardinal3(f) local a, b, c = byte(f:read(3),1,3) return 0x10000 * a + 0x100 * b + c end +function files.readcardinal3le(f) + local c, b, a = byte(f:read(3),1,3) + return 0x10000 * a + 0x100 * b + c +end function files.readinteger3(f) local a, b, c = byte(f:read(3),1,3) @@ -136,11 +154,25 @@ function files.readinteger3(f) return n end end +function files.readinteger3le(f) + local c, b, a = byte(f:read(3),1,3) + local n = 0x10000 * a + 0x100 * b + c + if n >= 0x80000 then + -- return n - 0xFFFFFF - 1 + return n - 0x1000000 + else + return n + end +end function files.readcardinal4(f) local a, b, c, d = byte(f:read(4),1,4) return 0x1000000 * a + 0x10000 * b + 0x100 * c + d end +function files.readcardinal4le(f) + local d, c, b, a = byte(f:read(4),1,4) + return 0x1000000 * a + 0x10000 * b + 0x100 * c + d +end function files.readinteger4(f) local a, b, c, d = byte(f:read(4),1,4) @@ -152,6 +184,16 @@ function files.readinteger4(f) return n end end +function files.readinteger4le(f) + local d, c, b, a = byte(f:read(4),1,4) + local n = 0x1000000 * a + 0x10000 * b + 0x100 * c + d + if n >= 0x8000000 then + -- return n - 0xFFFFFFFF - 1 + return n - 0x100000000 + else + return n + end +end function files.readfixed4(f) local a, b, c, d = byte(f:read(4),1,4) diff --git a/tex/context/fonts/mkiv/type-imp-ipaex.mkiv b/tex/context/fonts/mkiv/type-imp-ipaex.mkiv index b11f96878..9a071ed3c 100644 --- a/tex/context/fonts/mkiv/type-imp-ipaex.mkiv +++ b/tex/context/fonts/mkiv/type-imp-ipaex.mkiv @@ -94,7 +94,7 @@ \definefontsynonym[ipaexgmonoboldslanted] [\s!file:ipaexg][\s!features=jp-slanted,\s!fallbacks=jp-monoboldslanted] \definefontsynonym[ipaexgmonocaps] [\s!file:ipaexg][\s!features=jp-default,\s!fallbacks=jp-monocaps] \stoptypescript - + \starttypescript [\s!serif] [ipaexm] [\s!name] \definefontsynonym[\s!Serif] [ipaexm] \definefontsynonym[\s!SerifBold] [ipaexmbold] diff --git a/tex/context/fonts/mkiv/type-imp-koeielettersot.mkiv b/tex/context/fonts/mkiv/type-imp-koeielettersot.mkiv index fc6640532..44176b67c 100644 --- a/tex/context/fonts/mkiv/type-imp-koeielettersot.mkiv +++ b/tex/context/fonts/mkiv/type-imp-koeielettersot.mkiv @@ -22,6 +22,11 @@ script=latn, ss01=yes] +\definefontfeature + [mathsheepdigits] + [sheepdigits] + [mode=base] + \definefontfeature [cowslogos] [mode=node, @@ -37,7 +42,8 @@ \definefontfeature [cowscolors] - [colr=yes, + [mode=node, + colr=yes, ss02=yes, dlig=yes] @@ -72,7 +78,7 @@ \starttypescript [\s!all] [koeielettersotf,sheepotf] \definefontsynonym [Sheep] [koeielettersot][\s!features=sheepdefault] \definefontsynonym [SheepLogo] [koeielettersot][\s!features=cowslogos] - \definefontsynonym [SheepMathRoman][koeielettersot][\s!features=sheepdigits,\s!goodies=koeielettersot] + \definefontsynonym [SheepMathRoman][koeielettersot][\s!features=mathsheepdigits,\s!goodies=koeielettersot] \stoptypescript % \definefontsynonym[\s!MathRoman][file:texgyredejavu-math][\s!features=\s!math\mathsizesuffix,\s!goodies=dejavu-math] @@ -86,7 +92,7 @@ \starttypescript [\s!all] [coloredsheepotf] \definefontsynonym [Sheep] [koeielettersot][\s!features=sheepcolored] \definefontsynonym [SheepLogo] [koeielettersot][\s!features=cowslogos] - \definefontsynonym [SheepMathRoman][koeielettersot][\s!features=sheepdigits,\s!goodies=koeielettersot] + \definefontsynonym [SheepMathRoman][koeielettersot][\s!features=mathsheepdigits,\s!goodies=koeielettersot] \stoptypescript \starttypescript [\s!serif] [cowsotf,coloredcowsotf] @@ -126,21 +132,29 @@ \starttext -% \loadtypescriptfile[cowotf] +\setupbodyfont[sheep] + +$1^1$ + +\stoptext + +\starttext + +\loadtypescriptfile[cowotf] \definecolor[cowred] [r=.50] \definecolor[cowgreen] [g=.50] \definecolor[cowblue] [b=.50] \definecolor[cowyellow][y=.25] -% \startluacode -% fonts.handlers.otf.registerpalette("demo", { -% { g = .50 }, -% { y = .25 }, -% { b = .50 }, -% { r = .50 }, -% }) -% \stopluacode +\startluacode + fonts.handlers.otf.registerpalette("demo", { + { g = .50 }, + { y = .25 }, + { b = .50 }, + { r = .50 }, + }) +\stopluacode \definefontcolorpalette[cows][cowgreen,cowyellow,cowblue,cowred] @@ -150,4 +164,16 @@ \input zapf +\definefontsynonym + [CowsColored] + [koeielettersot] + +\showotfcomposition + {koeielettersot*default,cowscolors} + {1} + {context} + +\scale[width=\textwidth]{\getnamedglyphdirect{CowsColored*default,cowscolors}{contextlogo}} +\scale[width=\textwidth]{\definedfont[CowsColored*default,cowscolors]context} + \stoptext diff --git a/tex/context/interface/mkii/keys-cs.xml b/tex/context/interface/mkii/keys-cs.xml index 93e998e58..9389f61ec 100644 --- a/tex/context/interface/mkii/keys-cs.xml +++ b/tex/context/interface/mkii/keys-cs.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-de.xml b/tex/context/interface/mkii/keys-de.xml index b45cc3442..685193fd7 100644 --- a/tex/context/interface/mkii/keys-de.xml +++ b/tex/context/interface/mkii/keys-de.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-en.xml b/tex/context/interface/mkii/keys-en.xml index 483b8345f..825a0eea2 100644 --- a/tex/context/interface/mkii/keys-en.xml +++ b/tex/context/interface/mkii/keys-en.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-fr.xml b/tex/context/interface/mkii/keys-fr.xml index 7a6f99a13..17d564397 100644 --- a/tex/context/interface/mkii/keys-fr.xml +++ b/tex/context/interface/mkii/keys-fr.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-it.xml b/tex/context/interface/mkii/keys-it.xml index 28b7649d1..5e771719d 100644 --- a/tex/context/interface/mkii/keys-it.xml +++ b/tex/context/interface/mkii/keys-it.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-nl.xml b/tex/context/interface/mkii/keys-nl.xml index 1016b7697..c3b3b5d78 100644 --- a/tex/context/interface/mkii/keys-nl.xml +++ b/tex/context/interface/mkii/keys-nl.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-pe.xml b/tex/context/interface/mkii/keys-pe.xml index 8dcd35c3d..9d86aa689 100644 --- a/tex/context/interface/mkii/keys-pe.xml +++ b/tex/context/interface/mkii/keys-pe.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkii/keys-ro.xml b/tex/context/interface/mkii/keys-ro.xml index f4e833bb4..f810eaf57 100644 --- a/tex/context/interface/mkii/keys-ro.xml +++ b/tex/context/interface/mkii/keys-ro.xml @@ -382,6 +382,7 @@ + @@ -1238,6 +1239,7 @@ + diff --git a/tex/context/interface/mkiv/i-attachment.xml b/tex/context/interface/mkiv/i-attachment.xml index 6aadc0304..82056a0ad 100644 --- a/tex/context/interface/mkiv/i-attachment.xml +++ b/tex/context/interface/mkiv/i-attachment.xml @@ -107,7 +107,7 @@ - + @@ -117,9 +117,12 @@ + + + - + @@ -129,6 +132,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-attribute.xml b/tex/context/interface/mkiv/i-attribute.xml index eb699b99e..cd1e807d2 100644 --- a/tex/context/interface/mkiv/i-attribute.xml +++ b/tex/context/interface/mkiv/i-attribute.xml @@ -93,4 +93,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-background.xml b/tex/context/interface/mkiv/i-background.xml index 400e01454..f51a0247c 100644 --- a/tex/context/interface/mkiv/i-background.xml +++ b/tex/context/interface/mkiv/i-background.xml @@ -45,7 +45,7 @@ - + @@ -54,6 +54,9 @@ + + + @@ -64,13 +67,16 @@ - + + + + @@ -86,7 +92,7 @@ - + @@ -108,7 +114,7 @@ - + @@ -158,4 +164,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-bar.xml b/tex/context/interface/mkiv/i-bar.xml index 428c1eea4..951448249 100644 --- a/tex/context/interface/mkiv/i-bar.xml +++ b/tex/context/interface/mkiv/i-bar.xml @@ -95,13 +95,31 @@ --> - + + + + + + + + + + + + + + + + + + + @@ -224,6 +242,6 @@ - + diff --git a/tex/context/interface/mkiv/i-bleed.xml b/tex/context/interface/mkiv/i-bleed.xml index 15a2fe5f7..301f7d066 100644 --- a/tex/context/interface/mkiv/i-bleed.xml +++ b/tex/context/interface/mkiv/i-bleed.xml @@ -61,4 +61,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-block.xml b/tex/context/interface/mkiv/i-block.xml index 980b5b435..837b2133d 100644 --- a/tex/context/interface/mkiv/i-block.xml +++ b/tex/context/interface/mkiv/i-block.xml @@ -37,7 +37,7 @@ - + @@ -117,4 +117,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-bookmark.xml b/tex/context/interface/mkiv/i-bookmark.xml index 5b7aec9a8..68d893609 100644 --- a/tex/context/interface/mkiv/i-bookmark.xml +++ b/tex/context/interface/mkiv/i-bookmark.xml @@ -76,4 +76,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-boxes.xml b/tex/context/interface/mkiv/i-boxes.xml index 3114bd100..fda2600e5 100644 --- a/tex/context/interface/mkiv/i-boxes.xml +++ b/tex/context/interface/mkiv/i-boxes.xml @@ -142,7 +142,7 @@ - + @@ -152,7 +152,7 @@ - + @@ -444,7 +444,7 @@ - + @@ -866,6 +866,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -969,7 +1026,7 @@ - + @@ -979,9 +1036,4 @@ - - - - - diff --git a/tex/context/interface/mkiv/i-buffer.xml b/tex/context/interface/mkiv/i-buffer.xml index ad1ffd519..38571fcd4 100644 --- a/tex/context/interface/mkiv/i-buffer.xml +++ b/tex/context/interface/mkiv/i-buffer.xml @@ -97,13 +97,16 @@ - + + + + - + @@ -121,14 +124,14 @@ - + - + @@ -172,7 +175,7 @@ - + @@ -193,4 +196,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-button.xml b/tex/context/interface/mkiv/i-button.xml index 1f6dfd5bf..0ccb2d28d 100644 --- a/tex/context/interface/mkiv/i-button.xml +++ b/tex/context/interface/mkiv/i-button.xml @@ -60,7 +60,7 @@ --> - + @@ -71,6 +71,9 @@ + + + @@ -83,13 +86,13 @@ - + - + @@ -135,21 +138,25 @@ - - - - - - - + - + @@ -160,7 +167,7 @@ - + @@ -170,18 +177,22 @@ - - - - - - - + - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-capitals.xml b/tex/context/interface/mkiv/i-capitals.xml index bfbb6bb2b..154a1a040 100644 --- a/tex/context/interface/mkiv/i-capitals.xml +++ b/tex/context/interface/mkiv/i-capitals.xml @@ -205,4 +205,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-catcodes.xml b/tex/context/interface/mkiv/i-catcodes.xml index 7c3f649d5..b8636ceee 100644 --- a/tex/context/interface/mkiv/i-catcodes.xml +++ b/tex/context/interface/mkiv/i-catcodes.xml @@ -120,4 +120,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-character.xml b/tex/context/interface/mkiv/i-character.xml index 47bc714fa..f7f0e08db 100644 --- a/tex/context/interface/mkiv/i-character.xml +++ b/tex/context/interface/mkiv/i-character.xml @@ -133,4 +133,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-characteralign.xml b/tex/context/interface/mkiv/i-characteralign.xml index 2ee8d0cd9..a515ba1e9 100644 --- a/tex/context/interface/mkiv/i-characteralign.xml +++ b/tex/context/interface/mkiv/i-characteralign.xml @@ -42,4 +42,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-chart.xml b/tex/context/interface/mkiv/i-chart.xml index 66aa9e45f..06c356041 100644 --- a/tex/context/interface/mkiv/i-chart.xml +++ b/tex/context/interface/mkiv/i-chart.xml @@ -66,6 +66,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-cleaning.xml b/tex/context/interface/mkiv/i-cleaning.xml index d982a5dd5..e37eb7999 100644 --- a/tex/context/interface/mkiv/i-cleaning.xml +++ b/tex/context/interface/mkiv/i-cleaning.xml @@ -44,4 +44,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-collector.xml b/tex/context/interface/mkiv/i-collector.xml index dab49f14c..a75f3534e 100644 --- a/tex/context/interface/mkiv/i-collector.xml +++ b/tex/context/interface/mkiv/i-collector.xml @@ -111,4 +111,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-color.xml b/tex/context/interface/mkiv/i-color.xml index ffc9d338b..4168216a9 100644 --- a/tex/context/interface/mkiv/i-color.xml +++ b/tex/context/interface/mkiv/i-color.xml @@ -39,7 +39,7 @@ - + @@ -86,14 +86,14 @@ - + - + @@ -102,14 +102,14 @@ - + - + @@ -118,7 +118,7 @@ - + @@ -235,14 +235,14 @@ - + - + @@ -275,13 +275,13 @@ - + - + @@ -366,7 +366,7 @@ - + @@ -377,7 +377,7 @@ - + @@ -398,7 +398,7 @@ - + diff --git a/tex/context/interface/mkiv/i-combination.xml b/tex/context/interface/mkiv/i-combination.xml index 4e7ea2d52..492edadd0 100644 --- a/tex/context/interface/mkiv/i-combination.xml +++ b/tex/context/interface/mkiv/i-combination.xml @@ -85,7 +85,7 @@ --> - + @@ -94,7 +94,7 @@ - + @@ -105,13 +105,13 @@ - + @@ -120,7 +120,7 @@ - + @@ -128,4 +128,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-commandhandler.xml b/tex/context/interface/mkiv/i-commandhandler.xml index 210690d3e..6550898b6 100644 --- a/tex/context/interface/mkiv/i-commandhandler.xml +++ b/tex/context/interface/mkiv/i-commandhandler.xml @@ -311,4 +311,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-comment.xml b/tex/context/interface/mkiv/i-comment.xml index 52d54398b..e7f18fb0e 100644 --- a/tex/context/interface/mkiv/i-comment.xml +++ b/tex/context/interface/mkiv/i-comment.xml @@ -91,7 +91,7 @@ - + @@ -102,9 +102,12 @@ + + + - + @@ -114,6 +117,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-common-argument.xml b/tex/context/interface/mkiv/i-common-argument.xml index 305b93e90..0110d89ad 100644 --- a/tex/context/interface/mkiv/i-common-argument.xml +++ b/tex/context/interface/mkiv/i-common-argument.xml @@ -1,7 +1,5 @@ - - @@ -120,6 +118,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -494,16 +521,4 @@ - - - - - - - - - - - - diff --git a/tex/context/interface/mkiv/i-common-assignment.xml b/tex/context/interface/mkiv/i-common-assignment.xml index 0f11d0137..900a75452 100644 --- a/tex/context/interface/mkiv/i-common-assignment.xml +++ b/tex/context/interface/mkiv/i-common-assignment.xml @@ -1,7 +1,5 @@ - - diff --git a/tex/context/interface/mkiv/i-common-definitions.xml b/tex/context/interface/mkiv/i-common-definitions.xml index 1bb84efdc..5ca20c016 100644 --- a/tex/context/interface/mkiv/i-common-definitions.xml +++ b/tex/context/interface/mkiv/i-common-definitions.xml @@ -1,7 +1,5 @@ - - diff --git a/tex/context/interface/mkiv/i-common-keyword.xml b/tex/context/interface/mkiv/i-common-keyword.xml index 15eed8628..e087ea5ac 100644 --- a/tex/context/interface/mkiv/i-common-keyword.xml +++ b/tex/context/interface/mkiv/i-common-keyword.xml @@ -1,7 +1,5 @@ - - @@ -468,6 +466,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -701,4 +728,26 @@ + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/tex/context/interface/mkiv/i-common-string.xml b/tex/context/interface/mkiv/i-common-string.xml index 8e940e6f3..68bde02ed 100644 --- a/tex/context/interface/mkiv/i-common-string.xml +++ b/tex/context/interface/mkiv/i-common-string.xml @@ -1,7 +1,5 @@ - - diff --git a/tex/context/interface/mkiv/i-common-value.xml b/tex/context/interface/mkiv/i-common-value.xml index 5b068570b..f0196341f 100644 --- a/tex/context/interface/mkiv/i-common-value.xml +++ b/tex/context/interface/mkiv/i-common-value.xml @@ -1,13 +1,10 @@ - - - + - @@ -20,6 +17,8 @@ + + @@ -574,4 +573,22 @@ + + + + + + + + + + + + + + + + + + diff --git a/tex/context/interface/mkiv/i-context.pdf b/tex/context/interface/mkiv/i-context.pdf index 34f77b0b3..6caf60cc2 100644 Binary files a/tex/context/interface/mkiv/i-context.pdf and b/tex/context/interface/mkiv/i-context.pdf differ diff --git a/tex/context/interface/mkiv/i-conversion.xml b/tex/context/interface/mkiv/i-conversion.xml index b4755c27c..47440ddac 100644 --- a/tex/context/interface/mkiv/i-conversion.xml +++ b/tex/context/interface/mkiv/i-conversion.xml @@ -317,8 +317,8 @@ - - + + @@ -341,6 +341,19 @@ + + + + + + + + + + + + + @@ -399,7 +412,7 @@ - + @@ -407,7 +420,7 @@ - + @@ -629,4 +642,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-counter.xml b/tex/context/interface/mkiv/i-counter.xml index 7701d40cd..55630b511 100644 --- a/tex/context/interface/mkiv/i-counter.xml +++ b/tex/context/interface/mkiv/i-counter.xml @@ -514,4 +514,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-define.xml b/tex/context/interface/mkiv/i-define.xml index 0d0398e5d..2db8614c0 100644 --- a/tex/context/interface/mkiv/i-define.xml +++ b/tex/context/interface/mkiv/i-define.xml @@ -20,4 +20,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-delimitedtext.xml b/tex/context/interface/mkiv/i-delimitedtext.xml index 24fa581fd..d75fb957e 100644 --- a/tex/context/interface/mkiv/i-delimitedtext.xml +++ b/tex/context/interface/mkiv/i-delimitedtext.xml @@ -25,6 +25,8 @@ + + @@ -88,29 +90,46 @@ - + + + + + + + + + - + + + + + + + + + + @@ -118,6 +137,7 @@ + @@ -127,6 +147,7 @@ + @@ -134,6 +155,7 @@ + @@ -142,12 +164,14 @@ + + @@ -156,20 +180,27 @@ + - + + + + + + + @@ -178,6 +209,23 @@ + + + + + + + + + + + + + + + + + @@ -214,4 +262,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-description.xml b/tex/context/interface/mkiv/i-description.xml index 0204b3466..13b056d71 100644 --- a/tex/context/interface/mkiv/i-description.xml +++ b/tex/context/interface/mkiv/i-description.xml @@ -138,7 +138,7 @@ --> - + @@ -147,7 +147,7 @@ - + @@ -157,7 +157,7 @@ - + @@ -169,4 +169,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-digits.xml b/tex/context/interface/mkiv/i-digits.xml index 325febab3..d9a4b9d2d 100644 --- a/tex/context/interface/mkiv/i-digits.xml +++ b/tex/context/interface/mkiv/i-digits.xml @@ -23,4 +23,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-dimension.xml b/tex/context/interface/mkiv/i-dimension.xml index 2962a3aef..7bf59467b 100644 --- a/tex/context/interface/mkiv/i-dimension.xml +++ b/tex/context/interface/mkiv/i-dimension.xml @@ -64,4 +64,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-direction.xml b/tex/context/interface/mkiv/i-direction.xml index 725e215a3..630f07cb7 100644 --- a/tex/context/interface/mkiv/i-direction.xml +++ b/tex/context/interface/mkiv/i-direction.xml @@ -66,4 +66,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-document.xml b/tex/context/interface/mkiv/i-document.xml index a2ed222d0..e2417ec63 100644 --- a/tex/context/interface/mkiv/i-document.xml +++ b/tex/context/interface/mkiv/i-document.xml @@ -10,7 +10,7 @@ - + @@ -19,7 +19,7 @@ - + @@ -28,13 +28,13 @@ - + - + @@ -48,7 +48,7 @@ - + @@ -57,7 +57,7 @@ - + @@ -66,13 +66,13 @@ - + - + @@ -86,7 +86,7 @@ - + @@ -95,7 +95,7 @@ - + @@ -104,13 +104,13 @@ - + - + @@ -124,7 +124,7 @@ - + @@ -133,7 +133,7 @@ - + @@ -142,13 +142,13 @@ - + - + diff --git a/tex/context/interface/mkiv/i-dummy.xml b/tex/context/interface/mkiv/i-dummy.xml index 452ac311e..6c7d4288f 100644 --- a/tex/context/interface/mkiv/i-dummy.xml +++ b/tex/context/interface/mkiv/i-dummy.xml @@ -55,4 +55,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-effect.xml b/tex/context/interface/mkiv/i-effect.xml index c46c689e2..f6fd3e042 100644 --- a/tex/context/interface/mkiv/i-effect.xml +++ b/tex/context/interface/mkiv/i-effect.xml @@ -46,7 +46,7 @@ - + diff --git a/tex/context/interface/mkiv/i-enumeration.xml b/tex/context/interface/mkiv/i-enumeration.xml index abd1da232..9ff9ed0e4 100644 --- a/tex/context/interface/mkiv/i-enumeration.xml +++ b/tex/context/interface/mkiv/i-enumeration.xml @@ -185,7 +185,7 @@ --> - + @@ -194,7 +194,7 @@ - + @@ -204,7 +204,7 @@ - + @@ -216,4 +216,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-export.xml b/tex/context/interface/mkiv/i-export.xml index 40c73ee51..067649402 100644 --- a/tex/context/interface/mkiv/i-export.xml +++ b/tex/context/interface/mkiv/i-export.xml @@ -74,4 +74,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-field.xml b/tex/context/interface/mkiv/i-field.xml index 67ff40ccf..828ab204f 100644 --- a/tex/context/interface/mkiv/i-field.xml +++ b/tex/context/interface/mkiv/i-field.xml @@ -380,4 +380,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-figure.xml b/tex/context/interface/mkiv/i-figure.xml index a53678e89..4b1439f41 100644 --- a/tex/context/interface/mkiv/i-figure.xml +++ b/tex/context/interface/mkiv/i-figure.xml @@ -47,4 +47,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-file.xml b/tex/context/interface/mkiv/i-file.xml index 4805c0faf..a5ed9daa3 100644 --- a/tex/context/interface/mkiv/i-file.xml +++ b/tex/context/interface/mkiv/i-file.xml @@ -4,13 +4,13 @@ - + - + @@ -74,7 +74,7 @@ - + @@ -82,7 +82,7 @@ - + @@ -106,7 +106,7 @@ - + @@ -114,7 +114,7 @@ - + @@ -180,19 +180,19 @@ - + - + - + @@ -313,7 +313,7 @@ - + @@ -322,7 +322,7 @@ - + @@ -401,4 +401,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-filler.xml b/tex/context/interface/mkiv/i-filler.xml index 919267b30..894780063 100644 --- a/tex/context/interface/mkiv/i-filler.xml +++ b/tex/context/interface/mkiv/i-filler.xml @@ -113,4 +113,98 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/tex/context/interface/mkiv/i-firstline.xml b/tex/context/interface/mkiv/i-firstline.xml index ffa706e3d..59579a18c 100644 --- a/tex/context/interface/mkiv/i-firstline.xml +++ b/tex/context/interface/mkiv/i-firstline.xml @@ -49,4 +49,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-fittingpage.xml b/tex/context/interface/mkiv/i-fittingpage.xml index 3489c55e2..29816601f 100644 --- a/tex/context/interface/mkiv/i-fittingpage.xml +++ b/tex/context/interface/mkiv/i-fittingpage.xml @@ -50,7 +50,7 @@ - + @@ -59,6 +59,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-floats.xml b/tex/context/interface/mkiv/i-floats.xml index d786769fc..54d78adab 100644 --- a/tex/context/interface/mkiv/i-floats.xml +++ b/tex/context/interface/mkiv/i-floats.xml @@ -4,7 +4,7 @@ - + @@ -14,7 +14,7 @@ - + @@ -325,7 +325,7 @@ --> - + @@ -336,6 +336,13 @@ + + + + + + + @@ -348,7 +355,7 @@ - + @@ -357,6 +364,13 @@ + + + + + + + @@ -367,7 +381,7 @@ - + @@ -379,7 +393,7 @@ - + @@ -391,7 +405,7 @@ - + @@ -733,4 +747,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-fontfamily.xml b/tex/context/interface/mkiv/i-fontfamily.xml index 648bef6a2..2cf2fb403 100644 --- a/tex/context/interface/mkiv/i-fontfamily.xml +++ b/tex/context/interface/mkiv/i-fontfamily.xml @@ -4,7 +4,7 @@ - + @@ -68,7 +68,7 @@ - + @@ -97,7 +97,7 @@ - + @@ -177,7 +177,7 @@ - + @@ -206,7 +206,7 @@ - + @@ -215,7 +215,7 @@ - + diff --git a/tex/context/interface/mkiv/i-fonts.xml b/tex/context/interface/mkiv/i-fonts.xml index 9c4fc3d5e..37542e1c9 100644 --- a/tex/context/interface/mkiv/i-fonts.xml +++ b/tex/context/interface/mkiv/i-fonts.xml @@ -259,11 +259,15 @@ + + + + - + @@ -286,49 +290,49 @@ - + - + - + - + - + - + - + - + @@ -344,7 +348,7 @@ - + @@ -365,7 +369,7 @@ - + @@ -595,7 +599,7 @@ - + @@ -605,7 +609,7 @@ - + @@ -728,7 +732,7 @@ - + @@ -789,7 +793,7 @@ - + @@ -907,7 +911,7 @@ - + @@ -930,7 +934,7 @@ - + @@ -1251,13 +1255,13 @@ - + - + @@ -1266,7 +1270,7 @@ - + @@ -1275,7 +1279,7 @@ - + @@ -1283,7 +1287,7 @@ - + @@ -1293,7 +1297,7 @@ - + diff --git a/tex/context/interface/mkiv/i-form.xml b/tex/context/interface/mkiv/i-form.xml index 0f02d0670..13e669427 100644 --- a/tex/context/interface/mkiv/i-form.xml +++ b/tex/context/interface/mkiv/i-form.xml @@ -20,4 +20,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-formula.xml b/tex/context/interface/mkiv/i-formula.xml index f288e4f8a..f6522fca4 100644 --- a/tex/context/interface/mkiv/i-formula.xml +++ b/tex/context/interface/mkiv/i-formula.xml @@ -63,7 +63,7 @@ - + @@ -83,6 +83,9 @@ + + + @@ -135,45 +138,49 @@ --> - - - + - + + + + + + + - + - + - + - + - + @@ -187,7 +194,7 @@ - + @@ -196,46 +203,30 @@ - - - - - + - - - - - + - - - - - + - - - - - + - + @@ -245,42 +236,28 @@ - - - + - + - - - - - + - - - - - + - - - - - + diff --git a/tex/context/interface/mkiv/i-fraction.xml b/tex/context/interface/mkiv/i-fraction.xml index 444784dfa..2624b8a5c 100644 --- a/tex/context/interface/mkiv/i-fraction.xml +++ b/tex/context/interface/mkiv/i-fraction.xml @@ -80,7 +80,7 @@ --> - + @@ -88,6 +88,16 @@ + + + + + + + + + + diff --git a/tex/context/interface/mkiv/i-framed.xml b/tex/context/interface/mkiv/i-framed.xml index b87e498e5..c7633aa91 100644 --- a/tex/context/interface/mkiv/i-framed.xml +++ b/tex/context/interface/mkiv/i-framed.xml @@ -4,8 +4,6 @@ - - @@ -160,6 +158,7 @@ + @@ -242,7 +241,7 @@ - + @@ -252,6 +251,10 @@ + + + + @@ -356,7 +359,7 @@ - + @@ -366,6 +369,11 @@ + + + + + @@ -395,6 +403,25 @@ + + + + + + + + + + + + + + + + + + + @@ -459,7 +486,7 @@ --> - + @@ -469,9 +496,12 @@ + + + - + @@ -486,6 +516,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-graphics.xml b/tex/context/interface/mkiv/i-graphics.xml index c2b339eb0..e66a039dc 100644 --- a/tex/context/interface/mkiv/i-graphics.xml +++ b/tex/context/interface/mkiv/i-graphics.xml @@ -86,7 +86,7 @@ - + diff --git a/tex/context/interface/mkiv/i-grid.xml b/tex/context/interface/mkiv/i-grid.xml index d98a1a544..ac678e544 100644 --- a/tex/context/interface/mkiv/i-grid.xml +++ b/tex/context/interface/mkiv/i-grid.xml @@ -59,7 +59,7 @@ - + @@ -69,7 +69,7 @@ - + @@ -79,7 +79,7 @@ - + @@ -88,7 +88,7 @@ - + @@ -97,7 +97,7 @@ - + @@ -105,7 +105,7 @@ - + diff --git a/tex/context/interface/mkiv/i-help.xml b/tex/context/interface/mkiv/i-help.xml index db2128d53..d0c0aa103 100644 --- a/tex/context/interface/mkiv/i-help.xml +++ b/tex/context/interface/mkiv/i-help.xml @@ -23,7 +23,7 @@ - + @@ -32,15 +32,21 @@ + + + - + + + + diff --git a/tex/context/interface/mkiv/i-highlight.xml b/tex/context/interface/mkiv/i-highlight.xml index 1cc4ed4ca..7a990b13b 100644 --- a/tex/context/interface/mkiv/i-highlight.xml +++ b/tex/context/interface/mkiv/i-highlight.xml @@ -32,7 +32,7 @@ - + @@ -61,4 +61,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-hspace.xml b/tex/context/interface/mkiv/i-hspace.xml index 9e683542e..9b9c777a5 100644 --- a/tex/context/interface/mkiv/i-hspace.xml +++ b/tex/context/interface/mkiv/i-hspace.xml @@ -156,7 +156,7 @@ - + diff --git a/tex/context/interface/mkiv/i-hyphenation.xml b/tex/context/interface/mkiv/i-hyphenation.xml index 934751712..36cbc67e4 100644 --- a/tex/context/interface/mkiv/i-hyphenation.xml +++ b/tex/context/interface/mkiv/i-hyphenation.xml @@ -173,6 +173,10 @@ + + + + @@ -257,4 +261,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-indent.xml b/tex/context/interface/mkiv/i-indent.xml index 666388b6a..0ad0b9a45 100644 --- a/tex/context/interface/mkiv/i-indent.xml +++ b/tex/context/interface/mkiv/i-indent.xml @@ -88,4 +88,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-indentedtext.xml b/tex/context/interface/mkiv/i-indentedtext.xml index c70fb5ba0..98812d5e0 100644 --- a/tex/context/interface/mkiv/i-indentedtext.xml +++ b/tex/context/interface/mkiv/i-indentedtext.xml @@ -57,7 +57,7 @@ - + @@ -69,4 +69,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-initial.xml b/tex/context/interface/mkiv/i-initial.xml index 170a5e1ba..d50a7bc61 100644 --- a/tex/context/interface/mkiv/i-initial.xml +++ b/tex/context/interface/mkiv/i-initial.xml @@ -78,4 +78,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-injector.xml b/tex/context/interface/mkiv/i-injector.xml index c13e544db..321aa75c8 100644 --- a/tex/context/interface/mkiv/i-injector.xml +++ b/tex/context/interface/mkiv/i-injector.xml @@ -70,4 +70,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-interaction.xml b/tex/context/interface/mkiv/i-interaction.xml index 06b104f4c..1c3285b84 100644 --- a/tex/context/interface/mkiv/i-interaction.xml +++ b/tex/context/interface/mkiv/i-interaction.xml @@ -14,7 +14,7 @@ - + @@ -119,7 +119,7 @@ - + @@ -157,4 +157,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-interactionmenu.xml b/tex/context/interface/mkiv/i-interactionmenu.xml index 6bf2f9674..22b928a5a 100644 --- a/tex/context/interface/mkiv/i-interactionmenu.xml +++ b/tex/context/interface/mkiv/i-interactionmenu.xml @@ -148,83 +148,87 @@ - - - - - - - + @@ -241,7 +245,7 @@ - + @@ -254,7 +258,7 @@ - + diff --git a/tex/context/interface/mkiv/i-interface.xml b/tex/context/interface/mkiv/i-interface.xml index c8c93b72b..a9b35bbe5 100644 --- a/tex/context/interface/mkiv/i-interface.xml +++ b/tex/context/interface/mkiv/i-interface.xml @@ -199,4 +199,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-interlinespace.xml b/tex/context/interface/mkiv/i-interlinespace.xml index 99f5e11af..b93bac7f5 100644 --- a/tex/context/interface/mkiv/i-interlinespace.xml +++ b/tex/context/interface/mkiv/i-interlinespace.xml @@ -14,7 +14,7 @@ - + @@ -53,7 +53,7 @@ - + @@ -69,13 +69,13 @@ - + - + @@ -84,7 +84,7 @@ - + @@ -100,13 +100,13 @@ - + - + @@ -115,7 +115,7 @@ - + @@ -131,13 +131,13 @@ - + - + @@ -145,7 +145,7 @@ - + @@ -161,7 +161,7 @@ - + @@ -173,4 +173,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-itemgroup.xml b/tex/context/interface/mkiv/i-itemgroup.xml index 69e817efd..eb3412c3d 100644 --- a/tex/context/interface/mkiv/i-itemgroup.xml +++ b/tex/context/interface/mkiv/i-itemgroup.xml @@ -14,7 +14,7 @@ - + @@ -116,7 +116,7 @@ - + @@ -198,7 +198,7 @@ - + @@ -299,7 +299,7 @@ - + @@ -381,11 +381,28 @@ - + + + + + + + + + + + + + + + + + + @@ -393,11 +410,16 @@ + + + - + + + + - @@ -405,93 +427,114 @@ + + + - + - + + + + + + + - + - - - - - + - + - - + - + - + - + @@ -500,7 +543,7 @@ - + @@ -511,7 +554,7 @@ - + @@ -531,4 +574,19 @@ + + + + + + + + + + + + + + + diff --git a/tex/context/interface/mkiv/i-javascript.xml b/tex/context/interface/mkiv/i-javascript.xml index 790d13523..965ed5388 100644 --- a/tex/context/interface/mkiv/i-javascript.xml +++ b/tex/context/interface/mkiv/i-javascript.xml @@ -48,4 +48,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-kerning.xml b/tex/context/interface/mkiv/i-kerning.xml index 167bfc4f8..aacb4a6ea 100644 --- a/tex/context/interface/mkiv/i-kerning.xml +++ b/tex/context/interface/mkiv/i-kerning.xml @@ -49,7 +49,7 @@ - + @@ -90,4 +90,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-label.xml b/tex/context/interface/mkiv/i-label.xml index 320c105f9..592193c35 100644 --- a/tex/context/interface/mkiv/i-label.xml +++ b/tex/context/interface/mkiv/i-label.xml @@ -186,7 +186,7 @@ --> - + @@ -196,7 +196,7 @@ - + @@ -207,4 +207,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-labeltext.xml b/tex/context/interface/mkiv/i-labeltext.xml index 247783762..a5a0a5706 100644 --- a/tex/context/interface/mkiv/i-labeltext.xml +++ b/tex/context/interface/mkiv/i-labeltext.xml @@ -11,7 +11,7 @@ - + @@ -21,9 +21,20 @@ + + + + + + + + + + + - + @@ -33,9 +44,20 @@ + + + + + + + + + + + - + @@ -45,9 +67,20 @@ + + + + + + + + + + + - + @@ -56,16 +89,38 @@ + + + + + + + + + + + - + - - - + + + + + + + + + + + + + + @@ -73,9 +128,20 @@ + + + + + + + + + + + - + @@ -84,9 +150,14 @@ + + + + + - + @@ -95,9 +166,14 @@ + + + + + - + @@ -106,6 +182,11 @@ + + + + + @@ -493,4 +574,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-language.xml b/tex/context/interface/mkiv/i-language.xml index 2339d925a..395e08c34 100644 --- a/tex/context/interface/mkiv/i-language.xml +++ b/tex/context/interface/mkiv/i-language.xml @@ -4,7 +4,7 @@ - + @@ -13,7 +13,7 @@ - + @@ -40,10 +40,6 @@ - - - - @@ -120,6 +116,10 @@ + + + + @@ -131,7 +131,7 @@ - + @@ -147,7 +147,7 @@ - + @@ -156,7 +156,7 @@ - + diff --git a/tex/context/interface/mkiv/i-layer.xml b/tex/context/interface/mkiv/i-layer.xml index 6be7cccc9..9157ecdbf 100644 --- a/tex/context/interface/mkiv/i-layer.xml +++ b/tex/context/interface/mkiv/i-layer.xml @@ -46,7 +46,7 @@ - + @@ -59,7 +59,7 @@ - + @@ -267,7 +267,7 @@ - + @@ -276,7 +276,7 @@ - + @@ -324,4 +324,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-layout.xml b/tex/context/interface/mkiv/i-layout.xml index 984995f10..f3e42515e 100644 --- a/tex/context/interface/mkiv/i-layout.xml +++ b/tex/context/interface/mkiv/i-layout.xml @@ -14,7 +14,7 @@ - + @@ -174,6 +174,9 @@ + + + @@ -208,7 +211,7 @@ - + @@ -364,4 +367,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-linenumber.xml b/tex/context/interface/mkiv/i-linenumber.xml index 623595140..12d069535 100644 --- a/tex/context/interface/mkiv/i-linenumber.xml +++ b/tex/context/interface/mkiv/i-linenumber.xml @@ -89,7 +89,7 @@ - + @@ -98,7 +98,7 @@ - + diff --git a/tex/context/interface/mkiv/i-lines.xml b/tex/context/interface/mkiv/i-lines.xml index fc8032448..2d6f56eaf 100644 --- a/tex/context/interface/mkiv/i-lines.xml +++ b/tex/context/interface/mkiv/i-lines.xml @@ -88,7 +88,7 @@ - + @@ -97,6 +97,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-linetable.xml b/tex/context/interface/mkiv/i-linetable.xml index a10479161..9b4cae16a 100644 --- a/tex/context/interface/mkiv/i-linetable.xml +++ b/tex/context/interface/mkiv/i-linetable.xml @@ -162,4 +162,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-list.xml b/tex/context/interface/mkiv/i-list.xml index 38e534252..da0a4438a 100644 --- a/tex/context/interface/mkiv/i-list.xml +++ b/tex/context/interface/mkiv/i-list.xml @@ -88,7 +88,7 @@ - + @@ -409,7 +409,7 @@ - + @@ -419,9 +419,12 @@ + + + - + @@ -431,9 +434,12 @@ + + + - + @@ -443,6 +449,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-lohi.xml b/tex/context/interface/mkiv/i-lohi.xml index 7cfd489eb..878f1deff 100644 --- a/tex/context/interface/mkiv/i-lohi.xml +++ b/tex/context/interface/mkiv/i-lohi.xml @@ -34,13 +34,16 @@ - + + + + @@ -79,13 +82,16 @@ - + + + + @@ -127,7 +133,7 @@ - + @@ -193,7 +199,7 @@ - + @@ -220,4 +226,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-lua.xml b/tex/context/interface/mkiv/i-lua.xml index 525753723..ef970609b 100644 --- a/tex/context/interface/mkiv/i-lua.xml +++ b/tex/context/interface/mkiv/i-lua.xml @@ -166,7 +166,7 @@ - + @@ -184,10 +184,10 @@ - + - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-makeup.xml b/tex/context/interface/mkiv/i-makeup.xml index 2128464ef..4424f9fde 100644 --- a/tex/context/interface/mkiv/i-makeup.xml +++ b/tex/context/interface/mkiv/i-makeup.xml @@ -113,7 +113,7 @@ - + @@ -122,7 +122,7 @@ - + @@ -140,9 +140,6 @@ - - - diff --git a/tex/context/interface/mkiv/i-margindata.xml b/tex/context/interface/mkiv/i-margindata.xml index 5a2b014ea..1085daa1e 100644 --- a/tex/context/interface/mkiv/i-margindata.xml +++ b/tex/context/interface/mkiv/i-margindata.xml @@ -128,7 +128,7 @@ - + @@ -144,6 +144,30 @@ + + + + + + + + + + + + + + + + + + + + @@ -170,9 +194,11 @@ - - - + @@ -185,9 +211,11 @@ - - - + @@ -200,9 +228,11 @@ - - - + @@ -215,9 +245,11 @@ - - - + @@ -230,9 +262,11 @@ - - - + @@ -245,9 +279,11 @@ - - - + @@ -260,9 +296,11 @@ - - - + @@ -275,9 +313,11 @@ - - - + @@ -290,9 +330,11 @@ - - - + @@ -305,9 +347,11 @@ - - - + @@ -410,9 +454,11 @@ - - - + @@ -425,9 +471,11 @@ - - - + @@ -440,9 +488,11 @@ - - - + @@ -466,4 +516,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-marker.xml b/tex/context/interface/mkiv/i-marker.xml index 103fc5e55..fe491650e 100644 --- a/tex/context/interface/mkiv/i-marker.xml +++ b/tex/context/interface/mkiv/i-marker.xml @@ -30,4 +30,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-marking.xml b/tex/context/interface/mkiv/i-marking.xml index a556f1007..644f0ac5b 100644 --- a/tex/context/interface/mkiv/i-marking.xml +++ b/tex/context/interface/mkiv/i-marking.xml @@ -171,4 +171,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-math.xml b/tex/context/interface/mkiv/i-math.xml index ab05c6259..58890d6ea 100644 --- a/tex/context/interface/mkiv/i-math.xml +++ b/tex/context/interface/mkiv/i-math.xml @@ -4,7 +4,7 @@ - + @@ -14,7 +14,7 @@ - + @@ -82,7 +82,7 @@ - + @@ -92,45 +92,49 @@ - + + + + + - + - + - + - + - + @@ -160,7 +164,7 @@ - + @@ -194,13 +198,13 @@ - + - + @@ -278,84 +282,98 @@ + + + + + + + + + + + + + + diff --git a/tex/context/interface/mkiv/i-mathalignment.xml b/tex/context/interface/mkiv/i-mathalignment.xml index cc0ff6fa7..55e68ba7f 100644 --- a/tex/context/interface/mkiv/i-mathalignment.xml +++ b/tex/context/interface/mkiv/i-mathalignment.xml @@ -37,7 +37,7 @@ - + @@ -46,6 +46,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-mathcases.xml b/tex/context/interface/mkiv/i-mathcases.xml index 9744fa9e5..945565651 100644 --- a/tex/context/interface/mkiv/i-mathcases.xml +++ b/tex/context/interface/mkiv/i-mathcases.xml @@ -41,7 +41,7 @@ - + @@ -50,6 +50,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-mathfence.xml b/tex/context/interface/mkiv/i-mathfence.xml index b23f8558e..a6fa72b23 100644 --- a/tex/context/interface/mkiv/i-mathfence.xml +++ b/tex/context/interface/mkiv/i-mathfence.xml @@ -44,7 +44,7 @@ - + @@ -196,4 +196,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-mathmatrix.xml b/tex/context/interface/mkiv/i-mathmatrix.xml index a934d2b31..3007cf555 100644 --- a/tex/context/interface/mkiv/i-mathmatrix.xml +++ b/tex/context/interface/mkiv/i-mathmatrix.xml @@ -53,7 +53,7 @@ - + @@ -62,6 +62,10 @@ + + + + @@ -112,4 +116,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-mathornament.xml b/tex/context/interface/mkiv/i-mathornament.xml index 6009b7921..cfa7b0d18 100644 --- a/tex/context/interface/mkiv/i-mathornament.xml +++ b/tex/context/interface/mkiv/i-mathornament.xml @@ -34,7 +34,7 @@ - + @@ -43,4 +43,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-mathradical.xml b/tex/context/interface/mkiv/i-mathradical.xml index cedbb4200..e3ab9a6aa 100644 --- a/tex/context/interface/mkiv/i-mathradical.xml +++ b/tex/context/interface/mkiv/i-mathradical.xml @@ -36,7 +36,7 @@ - + @@ -53,4 +53,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-mathstackers.xml b/tex/context/interface/mkiv/i-mathstackers.xml index 37b5737ff..ef8d9d5e3 100644 --- a/tex/context/interface/mkiv/i-mathstackers.xml +++ b/tex/context/interface/mkiv/i-mathstackers.xml @@ -120,7 +120,7 @@ - + @@ -147,7 +147,7 @@ - + @@ -167,7 +167,7 @@ - + @@ -188,7 +188,7 @@ - + @@ -207,7 +207,7 @@ - + @@ -227,7 +227,7 @@ - + @@ -245,7 +245,7 @@ - + @@ -1772,7 +1772,7 @@ - + @@ -1786,4 +1786,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-metapost.xml b/tex/context/interface/mkiv/i-metapost.xml index ca15ebb9d..00250f787 100644 --- a/tex/context/interface/mkiv/i-metapost.xml +++ b/tex/context/interface/mkiv/i-metapost.xml @@ -389,7 +389,7 @@ - + @@ -403,4 +403,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-mixedcolumns.xml b/tex/context/interface/mkiv/i-mixedcolumns.xml index 09e0f3b34..031347401 100644 --- a/tex/context/interface/mkiv/i-mixedcolumns.xml +++ b/tex/context/interface/mkiv/i-mixedcolumns.xml @@ -19,7 +19,7 @@ - + @@ -105,7 +105,7 @@ - + @@ -114,6 +114,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-modes.xml b/tex/context/interface/mkiv/i-modes.xml index 8df4c27f6..0a0abc7c7 100644 --- a/tex/context/interface/mkiv/i-modes.xml +++ b/tex/context/interface/mkiv/i-modes.xml @@ -213,4 +213,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-modules.xml b/tex/context/interface/mkiv/i-modules.xml index 9567cb9af..d8eda7fba 100644 --- a/tex/context/interface/mkiv/i-modules.xml +++ b/tex/context/interface/mkiv/i-modules.xml @@ -62,13 +62,13 @@ - + - + @@ -123,4 +123,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-narrow.xml b/tex/context/interface/mkiv/i-narrow.xml index 1fa8699e1..25e40fd08 100644 --- a/tex/context/interface/mkiv/i-narrow.xml +++ b/tex/context/interface/mkiv/i-narrow.xml @@ -60,7 +60,7 @@ - + @@ -77,7 +77,7 @@ - + @@ -86,7 +86,7 @@ - + @@ -101,7 +101,7 @@ - + @@ -118,4 +118,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-naturaltable.xml b/tex/context/interface/mkiv/i-naturaltable.xml index d7ba1aac8..e18be1b79 100644 --- a/tex/context/interface/mkiv/i-naturaltable.xml +++ b/tex/context/interface/mkiv/i-naturaltable.xml @@ -105,6 +105,8 @@ + + @@ -113,6 +115,7 @@ + diff --git a/tex/context/interface/mkiv/i-note.xml b/tex/context/interface/mkiv/i-note.xml index dacdfeb0b..bcb9f7507 100644 --- a/tex/context/interface/mkiv/i-note.xml +++ b/tex/context/interface/mkiv/i-note.xml @@ -193,25 +193,33 @@ --> - + + + + + - + + + + + - + @@ -219,15 +227,23 @@ + + + + - + + + + + @@ -330,7 +346,7 @@ - + @@ -388,7 +404,7 @@ --> - + @@ -396,14 +412,14 @@ - + - + @@ -411,7 +427,7 @@ - + @@ -483,39 +499,39 @@ - + - + - + - + - + - + @@ -539,26 +555,26 @@ - + - + - + - + @@ -598,16 +614,19 @@ - + + + + - + @@ -616,9 +635,12 @@ + + + - + @@ -626,6 +648,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-object.xml b/tex/context/interface/mkiv/i-object.xml index 804d17af8..6e105b377 100644 --- a/tex/context/interface/mkiv/i-object.xml +++ b/tex/context/interface/mkiv/i-object.xml @@ -129,4 +129,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-offset.xml b/tex/context/interface/mkiv/i-offset.xml index 8e68a3bef..fc759673d 100644 --- a/tex/context/interface/mkiv/i-offset.xml +++ b/tex/context/interface/mkiv/i-offset.xml @@ -71,4 +71,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-ornament.xml b/tex/context/interface/mkiv/i-ornament.xml index 8ad0b7cfb..f4ae43a6d 100644 --- a/tex/context/interface/mkiv/i-ornament.xml +++ b/tex/context/interface/mkiv/i-ornament.xml @@ -4,7 +4,7 @@ - + @@ -27,7 +27,7 @@ - + @@ -44,7 +44,7 @@ - + @@ -52,7 +52,7 @@ - + @@ -74,7 +74,7 @@ - + @@ -90,7 +90,7 @@ - + @@ -100,4 +100,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-output.xml b/tex/context/interface/mkiv/i-output.xml index 1f59284ff..bf719ca6a 100644 --- a/tex/context/interface/mkiv/i-output.xml +++ b/tex/context/interface/mkiv/i-output.xml @@ -14,7 +14,7 @@ - + @@ -25,7 +25,7 @@ - + @@ -46,4 +46,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-overlay.xml b/tex/context/interface/mkiv/i-overlay.xml index dd2d43363..91e9f4873 100644 --- a/tex/context/interface/mkiv/i-overlay.xml +++ b/tex/context/interface/mkiv/i-overlay.xml @@ -42,4 +42,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-pagebreak.xml b/tex/context/interface/mkiv/i-pagebreak.xml index abc586ea6..917e4a718 100644 --- a/tex/context/interface/mkiv/i-pagebreak.xml +++ b/tex/context/interface/mkiv/i-pagebreak.xml @@ -132,4 +132,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-pagegrid.xml b/tex/context/interface/mkiv/i-pagegrid.xml index 29810d7db..21f906a0c 100644 --- a/tex/context/interface/mkiv/i-pagegrid.xml +++ b/tex/context/interface/mkiv/i-pagegrid.xml @@ -55,7 +55,7 @@ - + @@ -217,4 +217,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-pageinjection.xml b/tex/context/interface/mkiv/i-pageinjection.xml index 64becc385..c069dbc8b 100644 --- a/tex/context/interface/mkiv/i-pageinjection.xml +++ b/tex/context/interface/mkiv/i-pageinjection.xml @@ -49,14 +49,14 @@ - + - + diff --git a/tex/context/interface/mkiv/i-pageselection.xml b/tex/context/interface/mkiv/i-pageselection.xml index d8d144216..99d55bb8a 100644 --- a/tex/context/interface/mkiv/i-pageselection.xml +++ b/tex/context/interface/mkiv/i-pageselection.xml @@ -15,6 +15,9 @@ + + + @@ -32,12 +35,12 @@ - - - + + + diff --git a/tex/context/interface/mkiv/i-pairedbox.xml b/tex/context/interface/mkiv/i-pairedbox.xml index fbf190257..aa492b2a5 100644 --- a/tex/context/interface/mkiv/i-pairedbox.xml +++ b/tex/context/interface/mkiv/i-pairedbox.xml @@ -90,7 +90,7 @@ - + @@ -100,9 +100,12 @@ + + + - + @@ -114,9 +117,12 @@ + + + - + @@ -126,6 +132,9 @@ + + + @@ -168,4 +177,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-papersize.xml b/tex/context/interface/mkiv/i-papersize.xml index 99d6b9d9d..dab5e03bd 100644 --- a/tex/context/interface/mkiv/i-papersize.xml +++ b/tex/context/interface/mkiv/i-papersize.xml @@ -102,7 +102,7 @@ --> - + @@ -137,7 +137,7 @@ - + @@ -149,7 +149,7 @@ - + @@ -178,7 +178,7 @@ - + diff --git a/tex/context/interface/mkiv/i-paragraph.xml b/tex/context/interface/mkiv/i-paragraph.xml index 63ddab64f..8a88f72fc 100644 --- a/tex/context/interface/mkiv/i-paragraph.xml +++ b/tex/context/interface/mkiv/i-paragraph.xml @@ -68,4 +68,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-paragraphs.xml b/tex/context/interface/mkiv/i-paragraphs.xml index 6c1dae0db..99092f668 100644 --- a/tex/context/interface/mkiv/i-paragraphs.xml +++ b/tex/context/interface/mkiv/i-paragraphs.xml @@ -14,7 +14,7 @@ - + @@ -76,7 +76,7 @@ - + @@ -144,19 +144,19 @@ - + - + - + diff --git a/tex/context/interface/mkiv/i-parallel.xml b/tex/context/interface/mkiv/i-parallel.xml index ef2c55f3f..ed1c50c86 100644 --- a/tex/context/interface/mkiv/i-parallel.xml +++ b/tex/context/interface/mkiv/i-parallel.xml @@ -76,10 +76,10 @@ - + - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-pdf.xml b/tex/context/interface/mkiv/i-pdf.xml index 9d75ddfd3..5b4eab2c3 100644 --- a/tex/context/interface/mkiv/i-pdf.xml +++ b/tex/context/interface/mkiv/i-pdf.xml @@ -128,4 +128,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-penalty.xml b/tex/context/interface/mkiv/i-penalty.xml index 8cadf672b..ee241b9ff 100644 --- a/tex/context/interface/mkiv/i-penalty.xml +++ b/tex/context/interface/mkiv/i-penalty.xml @@ -26,4 +26,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-periods.xml b/tex/context/interface/mkiv/i-periods.xml index e72152c38..9114ae550 100644 --- a/tex/context/interface/mkiv/i-periods.xml +++ b/tex/context/interface/mkiv/i-periods.xml @@ -24,13 +24,13 @@ - + - + diff --git a/tex/context/interface/mkiv/i-placement.xml b/tex/context/interface/mkiv/i-placement.xml index 4db307957..958ffaa6f 100644 --- a/tex/context/interface/mkiv/i-placement.xml +++ b/tex/context/interface/mkiv/i-placement.xml @@ -60,7 +60,7 @@ - + diff --git a/tex/context/interface/mkiv/i-positionbar.xml b/tex/context/interface/mkiv/i-positionbar.xml index e6dadf8c5..481540691 100644 --- a/tex/context/interface/mkiv/i-positionbar.xml +++ b/tex/context/interface/mkiv/i-positionbar.xml @@ -70,4 +70,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-processor.xml b/tex/context/interface/mkiv/i-processor.xml index a43037754..0c313c77a 100644 --- a/tex/context/interface/mkiv/i-processor.xml +++ b/tex/context/interface/mkiv/i-processor.xml @@ -48,4 +48,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-profile.xml b/tex/context/interface/mkiv/i-profile.xml index 2df175cdf..a3fe7ea6e 100644 --- a/tex/context/interface/mkiv/i-profile.xml +++ b/tex/context/interface/mkiv/i-profile.xml @@ -97,4 +97,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-publication.xml b/tex/context/interface/mkiv/i-publication.xml index 4d3583e7e..83cb6c2c8 100644 --- a/tex/context/interface/mkiv/i-publication.xml +++ b/tex/context/interface/mkiv/i-publication.xml @@ -32,7 +32,7 @@ - + @@ -114,7 +114,7 @@ - + @@ -370,90 +370,90 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -466,126 +466,126 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -604,79 +604,79 @@ - + - + - + - + - + - + - + - + - + - + - + - + @@ -1024,7 +1024,7 @@ - + @@ -1040,13 +1040,13 @@ - + - + @@ -1062,13 +1062,13 @@ - + - + @@ -1084,7 +1084,7 @@ - + @@ -1096,7 +1096,7 @@ - + @@ -1109,7 +1109,7 @@ - + @@ -1121,4 +1121,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-random.xml b/tex/context/interface/mkiv/i-random.xml index 969cef05f..54dc66c5f 100644 --- a/tex/context/interface/mkiv/i-random.xml +++ b/tex/context/interface/mkiv/i-random.xml @@ -61,4 +61,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-readme.pdf b/tex/context/interface/mkiv/i-readme.pdf index 85ee4bfd5..878a42111 100644 Binary files a/tex/context/interface/mkiv/i-readme.pdf and b/tex/context/interface/mkiv/i-readme.pdf differ diff --git a/tex/context/interface/mkiv/i-references.xml b/tex/context/interface/mkiv/i-references.xml index 7b117e4f7..e7a713796 100644 --- a/tex/context/interface/mkiv/i-references.xml +++ b/tex/context/interface/mkiv/i-references.xml @@ -346,7 +346,7 @@ - + @@ -563,4 +563,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-regime.xml b/tex/context/interface/mkiv/i-regime.xml index 6c9e5b356..cd0374023 100644 --- a/tex/context/interface/mkiv/i-regime.xml +++ b/tex/context/interface/mkiv/i-regime.xml @@ -85,4 +85,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-register.xml b/tex/context/interface/mkiv/i-register.xml index 561912f6a..564fb1340 100644 --- a/tex/context/interface/mkiv/i-register.xml +++ b/tex/context/interface/mkiv/i-register.xml @@ -14,7 +14,7 @@ - + @@ -178,9 +178,10 @@ - + + @@ -345,7 +346,7 @@ - + @@ -379,9 +381,12 @@ + + + - + @@ -393,9 +398,12 @@ + + + - + @@ -411,9 +419,12 @@ + + + - + @@ -423,9 +434,12 @@ + + + - + @@ -435,9 +449,12 @@ + + + - + @@ -448,9 +465,12 @@ + + + - + @@ -460,7 +480,7 @@ - + @@ -643,4 +663,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-rotatation.xml b/tex/context/interface/mkiv/i-rotatation.xml index 95a5815e9..3e8eb6699 100644 --- a/tex/context/interface/mkiv/i-rotatation.xml +++ b/tex/context/interface/mkiv/i-rotatation.xml @@ -51,4 +51,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-script.xml b/tex/context/interface/mkiv/i-script.xml index f1aee232a..e4c100538 100644 --- a/tex/context/interface/mkiv/i-script.xml +++ b/tex/context/interface/mkiv/i-script.xml @@ -83,6 +83,15 @@ + + + + + + + + + @@ -103,4 +112,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-section.xml b/tex/context/interface/mkiv/i-section.xml index 32b79323d..6ef89895b 100644 --- a/tex/context/interface/mkiv/i-section.xml +++ b/tex/context/interface/mkiv/i-section.xml @@ -124,9 +124,6 @@ - - - @@ -252,7 +249,7 @@ --> - + @@ -260,9 +257,24 @@ - - - + + + + + + + + + + + + + + + + + + @@ -271,18 +283,48 @@ - - - + + + + + + + + + + + + + + + + + + - - - + + + + + + + + + + + + + + + + + + @@ -290,6 +332,21 @@ + + + + + + + + + + + + + + + @@ -676,4 +733,6 @@ + + diff --git a/tex/context/interface/mkiv/i-sectionblock.xml b/tex/context/interface/mkiv/i-sectionblock.xml index fc6d87cff..594fecd15 100644 --- a/tex/context/interface/mkiv/i-sectionblock.xml +++ b/tex/context/interface/mkiv/i-sectionblock.xml @@ -58,7 +58,7 @@ - + @@ -70,6 +70,12 @@ + + + + + + diff --git a/tex/context/interface/mkiv/i-setups.xml b/tex/context/interface/mkiv/i-setups.xml index fec773f2e..d6b7b4d5a 100644 --- a/tex/context/interface/mkiv/i-setups.xml +++ b/tex/context/interface/mkiv/i-setups.xml @@ -4,25 +4,25 @@ - + - + - + - + @@ -146,7 +146,7 @@ - + @@ -155,13 +155,13 @@ - + - + @@ -170,13 +170,13 @@ - + - + @@ -185,13 +185,13 @@ - + - + @@ -200,13 +200,13 @@ - + - + @@ -215,10 +215,10 @@ - + - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-shift.xml b/tex/context/interface/mkiv/i-shift.xml index d9b8bf7e4..cd3c6650e 100644 --- a/tex/context/interface/mkiv/i-shift.xml +++ b/tex/context/interface/mkiv/i-shift.xml @@ -55,13 +55,17 @@ - + + + + + @@ -82,4 +86,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-sidebar.xml b/tex/context/interface/mkiv/i-sidebar.xml index 8c00ce1ff..25a7ed306 100644 --- a/tex/context/interface/mkiv/i-sidebar.xml +++ b/tex/context/interface/mkiv/i-sidebar.xml @@ -86,13 +86,13 @@ - + - + @@ -100,4 +100,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-sort.xml b/tex/context/interface/mkiv/i-sort.xml index 5ecc83f18..817dd9c97 100644 --- a/tex/context/interface/mkiv/i-sort.xml +++ b/tex/context/interface/mkiv/i-sort.xml @@ -78,7 +78,7 @@ - + @@ -86,6 +86,9 @@ + + + @@ -100,7 +103,7 @@ - + @@ -110,9 +113,12 @@ + + + - + @@ -122,6 +128,9 @@ + + + diff --git a/tex/context/interface/mkiv/i-startstop.xml b/tex/context/interface/mkiv/i-startstop.xml index e23485fd6..2a6be1393 100644 --- a/tex/context/interface/mkiv/i-startstop.xml +++ b/tex/context/interface/mkiv/i-startstop.xml @@ -51,7 +51,7 @@ - + @@ -66,7 +66,7 @@ - + diff --git a/tex/context/interface/mkiv/i-stream.xml b/tex/context/interface/mkiv/i-stream.xml index 40ddc89de..97be35774 100644 --- a/tex/context/interface/mkiv/i-stream.xml +++ b/tex/context/interface/mkiv/i-stream.xml @@ -71,4 +71,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-string.xml b/tex/context/interface/mkiv/i-string.xml index b3efe552b..7a7eb1c98 100644 --- a/tex/context/interface/mkiv/i-string.xml +++ b/tex/context/interface/mkiv/i-string.xml @@ -66,4 +66,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-symbol.xml b/tex/context/interface/mkiv/i-symbol.xml index 33d5b4707..7797a3bee 100644 --- a/tex/context/interface/mkiv/i-symbol.xml +++ b/tex/context/interface/mkiv/i-symbol.xml @@ -55,14 +55,14 @@ - + - + @@ -142,4 +142,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-synonym.xml b/tex/context/interface/mkiv/i-synonym.xml index c64c1c759..07c69e4dd 100644 --- a/tex/context/interface/mkiv/i-synonym.xml +++ b/tex/context/interface/mkiv/i-synonym.xml @@ -80,7 +80,7 @@ - + @@ -89,6 +89,9 @@ + + + @@ -104,7 +107,7 @@ - + @@ -114,9 +117,12 @@ + + + - + @@ -126,6 +132,9 @@ + + + @@ -209,4 +218,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-system.xml b/tex/context/interface/mkiv/i-system.xml index e1404754e..85c6a25d7 100644 --- a/tex/context/interface/mkiv/i-system.xml +++ b/tex/context/interface/mkiv/i-system.xml @@ -1157,13 +1157,13 @@ - + - + @@ -1171,13 +1171,13 @@ - + - + @@ -1186,13 +1186,13 @@ - + - + @@ -1201,13 +1201,13 @@ - + - + @@ -1216,13 +1216,13 @@ - + - + @@ -1619,13 +1619,13 @@ - + - + @@ -1634,28 +1634,13 @@ - + - - - - - - - - - - - - - - - - + @@ -1682,13 +1667,13 @@ - + - + @@ -3531,4 +3516,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-systemlog.xml b/tex/context/interface/mkiv/i-systemlog.xml index 3f2967912..02c4bece9 100644 --- a/tex/context/interface/mkiv/i-systemlog.xml +++ b/tex/context/interface/mkiv/i-systemlog.xml @@ -28,4 +28,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-table.xml b/tex/context/interface/mkiv/i-table.xml index 649b198ae..9aeceec8c 100644 --- a/tex/context/interface/mkiv/i-table.xml +++ b/tex/context/interface/mkiv/i-table.xml @@ -4,7 +4,7 @@ - + @@ -13,7 +13,7 @@ - + @@ -31,13 +31,13 @@ - + - + @@ -170,7 +170,7 @@ - + @@ -179,14 +179,14 @@ - + - + @@ -195,14 +195,14 @@ - + - + @@ -210,13 +210,13 @@ - + - + @@ -224,7 +224,7 @@ - + @@ -404,4 +404,4 @@ --> - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-tabulation.xml b/tex/context/interface/mkiv/i-tabulation.xml index e6686e5ac..62ad41d17 100644 --- a/tex/context/interface/mkiv/i-tabulation.xml +++ b/tex/context/interface/mkiv/i-tabulation.xml @@ -99,7 +99,7 @@ - + @@ -138,7 +138,7 @@ - + @@ -148,6 +148,10 @@ + + + + diff --git a/tex/context/interface/mkiv/i-textbackground.xml b/tex/context/interface/mkiv/i-textbackground.xml index 3b17e0efd..bc16ffa8d 100644 --- a/tex/context/interface/mkiv/i-textbackground.xml +++ b/tex/context/interface/mkiv/i-textbackground.xml @@ -122,7 +122,7 @@ - + @@ -133,7 +133,7 @@ - + @@ -144,4 +144,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-tolerance.xml b/tex/context/interface/mkiv/i-tolerance.xml index 26b554132..b33fef05d 100644 --- a/tex/context/interface/mkiv/i-tolerance.xml +++ b/tex/context/interface/mkiv/i-tolerance.xml @@ -19,4 +19,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-tooltip.xml b/tex/context/interface/mkiv/i-tooltip.xml index 775d0abcf..1504d70e1 100644 --- a/tex/context/interface/mkiv/i-tooltip.xml +++ b/tex/context/interface/mkiv/i-tooltip.xml @@ -28,7 +28,7 @@ - + @@ -39,9 +39,12 @@ + + + - + @@ -54,9 +57,12 @@ + + + - + @@ -66,7 +72,7 @@ - + diff --git a/tex/context/interface/mkiv/i-tracker.xml b/tex/context/interface/mkiv/i-tracker.xml index e2b48ade2..4dbc31886 100644 --- a/tex/context/interface/mkiv/i-tracker.xml +++ b/tex/context/interface/mkiv/i-tracker.xml @@ -72,4 +72,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-twopassdata.xml b/tex/context/interface/mkiv/i-twopassdata.xml index f30b8bb23..508294f08 100644 --- a/tex/context/interface/mkiv/i-twopassdata.xml +++ b/tex/context/interface/mkiv/i-twopassdata.xml @@ -121,4 +121,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-typography.xml b/tex/context/interface/mkiv/i-typography.xml index ffb80c211..6c2aa7389 100644 --- a/tex/context/interface/mkiv/i-typography.xml +++ b/tex/context/interface/mkiv/i-typography.xml @@ -170,4 +170,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-unit.xml b/tex/context/interface/mkiv/i-unit.xml index 3502b544a..551ff533f 100644 --- a/tex/context/interface/mkiv/i-unit.xml +++ b/tex/context/interface/mkiv/i-unit.xml @@ -4,13 +4,13 @@ - + - + @@ -75,13 +75,16 @@ - + + + + @@ -118,4 +121,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-variables.xml b/tex/context/interface/mkiv/i-variables.xml index 28aaa6df4..63b34329c 100644 --- a/tex/context/interface/mkiv/i-variables.xml +++ b/tex/context/interface/mkiv/i-variables.xml @@ -72,6 +72,23 @@ + + + + + + + + + + + + + + + + + @@ -353,4 +370,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-verbatim.xml b/tex/context/interface/mkiv/i-verbatim.xml index 7026d2b10..6a6d725df 100644 --- a/tex/context/interface/mkiv/i-verbatim.xml +++ b/tex/context/interface/mkiv/i-verbatim.xml @@ -77,7 +77,7 @@ - + @@ -86,7 +86,7 @@ - + @@ -95,7 +95,7 @@ - + @@ -104,7 +104,7 @@ - + @@ -113,7 +113,7 @@ - + @@ -125,7 +125,7 @@ - + @@ -251,7 +251,7 @@ - + @@ -259,7 +259,7 @@ - + @@ -267,7 +267,7 @@ - + @@ -276,9 +276,17 @@ + + + + + + + + - + @@ -287,6 +295,14 @@ + + + + + + + + @@ -363,7 +379,7 @@ - + @@ -371,7 +387,7 @@ - + @@ -382,7 +398,7 @@ - + @@ -390,7 +406,7 @@ - + @@ -398,7 +414,7 @@ - + @@ -406,7 +422,7 @@ - + @@ -414,7 +430,7 @@ - + @@ -422,7 +438,7 @@ - + @@ -430,7 +446,7 @@ - + @@ -438,7 +454,7 @@ - + @@ -446,4 +462,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-version.xml b/tex/context/interface/mkiv/i-version.xml index d01659815..9f7864e8a 100644 --- a/tex/context/interface/mkiv/i-version.xml +++ b/tex/context/interface/mkiv/i-version.xml @@ -75,4 +75,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-viewerlayer.xml b/tex/context/interface/mkiv/i-viewerlayer.xml index 3de29b1fd..8e321971e 100644 --- a/tex/context/interface/mkiv/i-viewerlayer.xml +++ b/tex/context/interface/mkiv/i-viewerlayer.xml @@ -50,7 +50,7 @@ - + @@ -65,4 +65,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-visualizer.xml b/tex/context/interface/mkiv/i-visualizer.xml index fd7198f9d..3d30b7f4d 100644 --- a/tex/context/interface/mkiv/i-visualizer.xml +++ b/tex/context/interface/mkiv/i-visualizer.xml @@ -153,4 +153,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-whitespace.xml b/tex/context/interface/mkiv/i-whitespace.xml index 8f9fa0823..06e1997c5 100644 --- a/tex/context/interface/mkiv/i-whitespace.xml +++ b/tex/context/interface/mkiv/i-whitespace.xml @@ -59,4 +59,4 @@ - \ No newline at end of file + diff --git a/tex/context/interface/mkiv/i-xtable.xml b/tex/context/interface/mkiv/i-xtable.xml index 31b4a6842..7500ff47f 100644 --- a/tex/context/interface/mkiv/i-xtable.xml +++ b/tex/context/interface/mkiv/i-xtable.xml @@ -82,7 +82,7 @@ - + @@ -90,13 +90,13 @@ - + - + @@ -104,13 +104,13 @@ - + - + @@ -157,7 +157,7 @@ - + @@ -165,13 +165,13 @@ - + - + @@ -179,13 +179,13 @@ - + - + @@ -193,13 +193,13 @@ - + - + @@ -207,7 +207,7 @@ - + diff --git a/tex/context/modules/mkiv/m-educat.mkiv b/tex/context/modules/mkiv/m-educat.mkiv index 93b1a6c5d..87a282327 100644 --- a/tex/context/modules/mkiv/m-educat.mkiv +++ b/tex/context/modules/mkiv/m-educat.mkiv @@ -48,6 +48,7 @@ \dontcomplain \setupanswerarea [\c!n=0,\c!m=,#1,\c!location=\v!text]% + \let\currenttextbackground\v!answerarea \doifelsenothing{\textbackgroundparameter\c!m} {\expandafter\donoanswerspace} {\expandafter\dodoanswerspace}% @@ -110,6 +111,7 @@ \dontcomplain \setupanswerarea [\c!n=0,\c!m=,#1,\c!location=\v!text]% + \let\currenttextbackground\v!answerarea \doifnot{\textbackgroundparameter\c!option}\v!joinedup\softbreak \doifelsenothing{\textbackgroundparameter\c!m} {\expandafter\donostartanswerlines} diff --git a/tex/context/modules/mkiv/x-setups-basics.mkiv b/tex/context/modules/mkiv/x-setups-basics.mkiv index 28e1a577b..b7004c51c 100644 --- a/tex/context/modules/mkiv/x-setups-basics.mkiv +++ b/tex/context/modules/mkiv/x-setups-basics.mkiv @@ -167,11 +167,11 @@ local commands = interfaces.complete.commands local elements = interfaces.complete.elements - local function replace(pattern,attribute,one,two) + local function replace(pattern,attribute,one,two,three) for e in xml.collected(x,pattern) do local t = e.at[attribute] if t then - local c = one[t] or (two and two[t]) + local c = one[t] or (two and two[t]) or (three and three[t]) if c then local v = c[interface] if v then @@ -182,7 +182,7 @@ end end - replace('cd:command', 'name', commands, elements) + replace('cd:command', 'name', commands, elements, variables) replace('cd:string', 'value', commands, elements) replace('cd:variable' , 'value', variables) @@ -192,6 +192,7 @@ replace('cd:variable', 'type', variables) replace('cd:inherit', 'name', commands, elements) + replace('cd:instances/cd:constant', 'value', variables) end if tex.modes["setups:save"] and environment.currentrun == 1 then @@ -362,7 +363,7 @@ \stopxmlsetups \startxmlsetups xml:setups:make:variable - \xmlatt{#1}{value} + \setupintfont{\xmlatt{#1}{value}} \stopxmlsetups \let\m_cmd_current_hash\empty @@ -477,7 +478,7 @@ \stopxmlsetups \startxmlsetups xml:setups:instance - \xmlatt{#1}{value}\enspace + \xmlatt{#1}{value}\enskip % we need a break \stopxmlsetups \startxmlsetups xml:setups:typeset:instances @@ -745,7 +746,7 @@ \unexpanded\def\show_setup_any#1#2% {\bgroup \global\advance\c_cmd_current_argument\plusone - \doif{\xmlatt{#1}{optional}}{yes}\donetrue\donefalse + \doifelse{\xmlatt{#1}{optional}}{yes}\donetrue\donefalse \setbox0=\hbox {\ifdone\sl\fi \doifelse{\xmlatt{#1}{list}}{yes} @@ -883,9 +884,10 @@ } \blank[\v!big,\v!samepage] \starttabulate[|l|p|] + % no /interface here \xmlall {#1} - {/interface/command[@name=='\currentsetupparametercommand' or @handler=='\currentsetupparametercommand']/arguments/assignments/parameter/command(xml:setups:parameters:value)} + {interface/command[@name=='\currentsetupparametercommand' or @handler=='\currentsetupparametercommand']/arguments/assignments/parameter/command(xml:setups:parameters:value)} \ifnum\noftabulaterows = \zerocount \NC \parameterkey{no specific settings} \NC \NC \NR \fi diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua index c93d2b104..39a574121 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 : 09/24/16 12:40:11 +-- merge date : 10/12/16 17:26:31 do -- begin closure to overcome local limits and interference @@ -4245,6 +4245,10 @@ function files.readcardinal2(f) local a,b=byte(f:read(2),1,2) return 0x100*a+b end +function files.readcardinal2le(f) + local b,a=byte(f:read(2),1,2) + return 0x100*a+b +end function files.readinteger2(f) local a,b=byte(f:read(2),1,2) local n=0x100*a+b @@ -4254,10 +4258,23 @@ function files.readinteger2(f) return n end end +function files.readinteger2le(f) + local b,a=byte(f:read(2),1,2) + local n=0x100*a+b + if n>=0x8000 then + return n-0x10000 + else + return n + end +end function files.readcardinal3(f) local a,b,c=byte(f:read(3),1,3) return 0x10000*a+0x100*b+c end +function files.readcardinal3le(f) + local c,b,a=byte(f:read(3),1,3) + return 0x10000*a+0x100*b+c +end function files.readinteger3(f) local a,b,c=byte(f:read(3),1,3) local n=0x10000*a+0x100*b+c @@ -4267,10 +4284,23 @@ function files.readinteger3(f) return n end end +function files.readinteger3le(f) + local c,b,a=byte(f:read(3),1,3) + local n=0x10000*a+0x100*b+c + if n>=0x80000 then + return n-0x1000000 + else + return n + end +end function files.readcardinal4(f) local a,b,c,d=byte(f:read(4),1,4) return 0x1000000*a+0x10000*b+0x100*c+d end +function files.readcardinal4le(f) + local d,c,b,a=byte(f:read(4),1,4) + return 0x1000000*a+0x10000*b+0x100*c+d +end function files.readinteger4(f) local a,b,c,d=byte(f:read(4),1,4) local n=0x1000000*a+0x10000*b+0x100*c+d @@ -4280,6 +4310,15 @@ function files.readinteger4(f) return n end end +function files.readinteger4le(f) + local d,c,b,a=byte(f:read(4),1,4) + local n=0x1000000*a+0x10000*b+0x100*c+d + if n>=0x8000000 then + return n-0x100000000 + else + return n + end +end function files.readfixed4(f) local a,b,c,d=byte(f:read(4),1,4) local n=0x100*a+b @@ -6084,10 +6123,14 @@ function constructors.scale(tfmdata,specification) local haskerns=properties.haskerns or properties.mode=="base" local hasligatures=properties.hasligatures or properties.mode=="base" local realdimensions=properties.realdimensions + local writingmode=properties.writingmode or "horizontal" + local identity=properties.identity or "horizontal" if changed and not next(changed) then changed=false end target.type=isvirtual and "virtual" or "real" + target.writingmode=writingmode=="vertical" and "vertical" or "horizontal" + target.identity=identity=="vertical" and "vertical" or "horizontal" target.postprocessors=tfmdata.postprocessors local targetslant=(parameters.slant or parameters[1] or 0)*factors.pt local targetspace=(parameters.space or parameters[2] or 0)*hdelta @@ -6473,6 +6516,8 @@ function constructors.finalize(tfmdata) cidinfo=tfmdata.cidinfo or nil, format=tfmdata.format or "type1", direction=tfmdata.direction or 0, + writingmode=tfmdata.writingmode or "horizontal", + identity=tfmdata.identity or "horizontal", } end if not tfmdata.resources then @@ -6611,7 +6656,11 @@ setmetatableindex(formats,function(t,k) return rawget(t,file.suffix(l)) end) do - local function setindeed(mode,target,group,name,action,position) + local function setindeed(mode,source,target,group,name,position) + local action=source[mode] + if not action then + return + end local t=target[mode] if not t then report_defining("fatal error in setting feature %a, group %a, mode %a",name,group,mode) @@ -6640,15 +6689,10 @@ do report_defining("fatal source error in setting feature %a, group %a",name,group) os.exit() end - local node=source.node - local base=source.base local position=source.position - if node then - setindeed("node",target,group,name,node,position) - end - if base then - setindeed("base",target,group,name,base,position) - end + setindeed("node",source,target,group,name,position) + setindeed("base",source,target,group,name,position) + setindeed("plug",source,target,group,name,position) end local function register(where,specification) local name=specification.name @@ -6710,9 +6754,9 @@ do defaults={}, descriptions=tables and tables.features or {}, used=statistics and statistics.usedfeatures or {}, - initializers={ base={},node={} }, - processors={ base={},node={} }, - manipulators={ base={},node={} }, + initializers={ base={},node={},plug={} }, + processors={ base={},node={},plug={} }, + manipulators={ base={},node={},plug={} }, } features.register=function(specification) return register(features,specification) end handler.features=features @@ -7706,6 +7750,7 @@ registerotffeature { initializers={ base=setmode, node=setmode, + plug=setmode, } } registerotffeature { @@ -7714,6 +7759,7 @@ registerotffeature { initializers={ base=setlanguage, node=setlanguage, + plug=setlanguage, } } registerotffeature { @@ -7722,6 +7768,7 @@ registerotffeature { initializers={ base=setscript, node=setscript, + plug=setscript, } } otftables.featuretypes=allocate { @@ -8291,11 +8338,43 @@ readers.hhea=function(f,fontdata,specification) reserved_3=readshort(f), reserved_4=readshort(f), metricdataformat=readshort(f), - nofhmetrics=readushort(f), + nofmetrics=readushort(f), } else fontdata.horizontalheader={ - nofhmetrics=0, + nofmetrics=0, + } + end + end +end +readers.vhea=function(f,fontdata,specification) + if specification.details then + local datatable=fontdata.tables.vhea + if datatable then + setposition(f,datatable.offset) + local version=readfixed(f) + fontdata.verticalheader={ + version=version, + ascender=readfword(f), + descender=readfword(f), + linegap=readfword(f), + maxadvanceheight=readufword(f), + mintopsidebearing=readfword(f), + minbottomsidebearing=readfword(f), + maxextent=readfword(f), + caretsloperise=readshort(f), + caretsloperun=readshort(f), + caretoffset=readshort(f), + reserved_1=readshort(f), + reserved_2=readshort(f), + reserved_3=readshort(f), + reserved_4=readshort(f), + metricdataformat=readshort(f), + nofmetrics=readushort(f), + } + else + fontdata.verticalheader={ + nofmetrics=0, } end end @@ -8346,7 +8425,8 @@ readers.hmtx=function(f,fontdata,specification) local datatable=fontdata.tables.hmtx if datatable then setposition(f,datatable.offset) - local nofmetrics=fontdata.horizontalheader.nofhmetrics + local horizontalheader=fontdata.horizontalheader + local nofmetrics=horizontalheader.nofmetrics local glyphs=fontdata.glyphs local nofglyphs=fontdata.nofglyphs local width=0 @@ -8368,6 +8448,43 @@ readers.hmtx=function(f,fontdata,specification) end end end +readers.vmtx=function(f,fontdata,specification) + if specification.glyphs then + local datatable=fontdata.tables.vmtx + if datatable then + setposition(f,datatable.offset) + local verticalheader=fontdata.verticalheader + local nofmetrics=verticalheader.nofmetrics + local glyphs=fontdata.glyphs + local nofglyphs=fontdata.nofglyphs + local vheight=0 + local vdefault=verticalheader.ascender+verticalheader.descender + local topsidebearing=0 + for i=0,nofmetrics-1 do + local glyph=glyphs[i] + vheight=readshort(f) + topsidebearing=readshort(f) + if vheight~=0 and vheight~=vdefault then + glyph.vheight=vheight + end + end + for i=nofmetrics,nofglyphs-1 do + local glyph=glyphs[i] + if vheight~=0 and vheight~=vdefault then + glyph.vheight=vheight + end + end + end + end +end +readers.vorg=function(f,fontdata,specification) + if specification.glyphs then + local datatable=fontdata.tables.vorg + if datatable then + report("todo: %s","vorg") + end + end +end readers.post=function(f,fontdata,specification) local datatable=fontdata.tables.post if datatable then @@ -8925,7 +9042,7 @@ function readers.math(f,fontdata,specification) reportskippedtable("math") end end -local function getinfo(maindata,sub,platformnames,rawfamilynames) +local function getinfo(maindata,sub,platformnames,rawfamilynames,metricstoo) local fontdata=sub and maindata.subfonts and maindata.subfonts[sub] or maindata local names=fontdata.names local info=nil @@ -8978,6 +9095,27 @@ local function getinfo(maindata,sub,platformnames,rawfamilynames) descender=metrics.typodescender, platformnames=platformnames and fontdata.platformnames or nil, } + if metricstoo then + local keys={ + "version", + "ascender","descender","linegap", + "maxadvancewidth","maxadvanceheight","maxextent", + "minbottomsidebearing","mintopsidebearing", + } + local h=fontdata.horizontalheader or {} + local v=fontdata.verticalheader or {} + if h then + local th={} + local tv={} + for i=1,#keys do + local key=keys[i] + th[key]=h[key] or 0 + tv[key]=v[key] or 0 + end + info.horizontalmetrics=th + info.verticalmetrics=tv + end + end elseif n then info={ filename=fontdata.filename, @@ -9061,7 +9199,10 @@ local function readdata(f,offset,specification) readers["head"](f,fontdata,specification) readers["maxp"](f,fontdata,specification) readers["hhea"](f,fontdata,specification) + readers["vhea"](f,fontdata,specification) readers["hmtx"](f,fontdata,specification) + readers["vmtx"](f,fontdata,specification) + readers["vorg"](f,fontdata,specification) readers["post"](f,fontdata,specification) readers["cff" ](f,fontdata,specification) readers["cmap"](f,fontdata,specification) @@ -9229,7 +9370,7 @@ function readers.loadfont(filename,n) descriptions=fontdata.descriptions, format=fontdata.format, goodies={}, - metadata=getinfo(fontdata,n), + metadata=getinfo(fontdata,n,false,false,true), properties={ hasitalics=fontdata.hasitalics or false, maxcolorclass=fontdata.maxcolorclass, @@ -15877,7 +16018,6 @@ local function getgsub(tfmdata,k,kind,value) local properties=tfmdata.properties local validlookups,lookuplist=otf.collectlookups(rawdata,kind,properties.script,properties.language) if validlookups then - local choice=tonumber(value) or 1 for i=1,#lookuplist do local lookup=lookuplist[i] local steps=lookup.steps @@ -18147,11 +18287,13 @@ local trace_details=false registertracker("otf.details",function(v) trace_detail local trace_steps=false registertracker("otf.steps",function(v) trace_steps=v end) local trace_skips=false registertracker("otf.skips",function(v) trace_skips=v end) local trace_directions=false registertracker("otf.directions",function(v) trace_directions=v end) +local trace_plugins=false registertracker("otf.plugins",function(v) trace_plugins=v end) local trace_kernruns=false registertracker("otf.kernruns",function(v) trace_kernruns=v end) local trace_discruns=false registertracker("otf.discruns",function(v) trace_discruns=v end) local trace_compruns=false registertracker("otf.compruns",function(v) trace_compruns=v end) local trace_testruns=false registertracker("otf.testruns",function(v) trace_testruns=v end) local optimizekerns=true +local alwaysdisc=true registerdirective("otf.alwaysdisc",function(v) alwaysdisc=v end) local report_direct=logs.reporter("fonts","otf direct") local report_subchain=logs.reporter("fonts","otf subchain") local report_chain=logs.reporter("fonts","otf chain") @@ -18533,7 +18675,7 @@ local function toligature(head,start,stop,char,dataset,sequence,markflag,discfou setlink(discfound,next) setboth(base) setfield(base,"components",copied) - setdisc(discfound,pre,post,base,discretionary_code) + setdisc(discfound,pre,post,base) base=prev end end @@ -20702,6 +20844,7 @@ local function t_run_single(start,stop,font,attr,lookupcache) return true,d>1 end end + else end start=getnext(start) else @@ -20815,6 +20958,7 @@ local function t_run_multiple(start,stop,font,attr,steps,nofsteps) report_missing_coverage(dataset,sequence) end end + else end start=getnext(start) else @@ -20886,6 +21030,9 @@ local function pardirstate(start) end return getnext(start),new,new end +otf.helpers=otf.helpers or {} +otf.helpers.txtdirstate=txtdirstate +otf.helpers.pardirstate=pardirstate local function featuresprocessor(head,font,attr) local sequences=sequencelists[font] if not sequencelists then @@ -20913,6 +21060,7 @@ local function featuresprocessor(head,font,attr) local rlmode=0 local done=false local datasets=otf.dataset(tfmdata,font,attr) + local forcedisc=alwaysdisc or not attr local dirstack={} sweephead={} for s=1,#datasets do @@ -21005,16 +21153,21 @@ local function featuresprocessor(head,font,attr) elseif char==false then start=getnext(start) elseif id==disc_code then - local ok - if gpossing then - start,ok=kernrun(start,k_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) - elseif typ=="gsub_ligature" then - start,ok=testrun(start,t_run_single,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + local a=forcedisc or getsubtype(start)==discretionary_code or getattr(start,0)==attr + if a then + local ok + if gpossing then + start,ok=kernrun(start,k_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + elseif typ=="gsub_ligature" then + start,ok=testrun(start,t_run_single,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + else + start,ok=comprun(start,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) + end + if ok then + success=true + end else - start,ok=comprun(start,c_run_single,font,attr,lookupcache,step,dataset,sequence,rlmode,handler) - end - if ok then - success=true + start=getnext(start) end elseif id==math_code then start=getnext(end_of_math(start)) @@ -21066,16 +21219,21 @@ local function featuresprocessor(head,font,attr) elseif char==false then start=getnext(start) elseif id==disc_code then - local ok - if gpossing then - start,ok=kernrun(start,k_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) - elseif typ=="gsub_ligature" then - start,ok=testrun(start,t_run_multiple,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + local a=forcedisc or getsubtype(start)==discretionary_code or getattr(start,0)==attr + if a then + local ok + if gpossing then + start,ok=kernrun(start,k_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + elseif typ=="gsub_ligature" then + start,ok=testrun(start,t_run_multiple,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + else + start,ok=comprun(start,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) + end + if ok then + success=true + end else - start,ok=comprun(start,c_run_multiple,font,attr,steps,nofsteps,dataset,sequence,rlmode,handler) - end - if ok then - success=true + start=getnext(start) end elseif id==math_code then start=getnext(end_of_math(start)) @@ -21100,6 +21258,30 @@ local function featuresprocessor(head,font,attr) head=tonode(head) return head,done end +local plugins={} +otf.plugins=plugins +function otf.registerplugin(name,f) + if type(name)=="string" and type(f)=="function" then + plugins[name]={ name,f } + end +end +local function plugininitializer(tfmdata,value) + if type(value)=="string" then + tfmdata.shared.plugin=plugins[value] + end +end +local function pluginprocessor(head,font) + local s=fontdata[font].shared + local p=s and s.plugin + if p then + if trace_plugins then + report_process("applying plugin %a",p[1]) + end + return p[2](head,font) + else + return head,false + end +end local function featuresinitializer(tfmdata,value) end registerotffeature { @@ -21109,9 +21291,11 @@ registerotffeature { initializers={ position=1, node=featuresinitializer, + plug=plugininitializer, }, processors={ node=featuresprocessor, + plug=pluginprocessor, } } otf.nodemodeinitializer=featuresinitializer -- cgit v1.2.3