diff options
Diffstat (limited to 'tex/context/fonts/mkiv')
21 files changed, 1263 insertions, 1258 deletions
diff --git a/tex/context/fonts/mkiv/asana-math.lfg b/tex/context/fonts/mkiv/asana-math.lfg index 379dd014f..970d031ea 100644 --- a/tex/context/fonts/mkiv/asana-math.lfg +++ b/tex/context/fonts/mkiv/asana-math.lfg @@ -1,35 +1,3 @@ --- This patch code is moved from font-pat.lua to this goodies --- files as it does not belong in the core code. --- --- local patches = fonts.handlers.otf.enhancers.patches --- --- local function patch(data,filename,threshold) --- local m = data.metadata.math --- if m then --- local d = m.DisplayOperatorMinHeight or 0 --- if d < threshold then --- patches.report("DisplayOperatorMinHeight(%s -> %s)",d,threshold) --- m.DisplayOperatorMinHeight = threshold --- end --- end --- end --- --- patches.register("after","analyze math","asana",function(data,filename) patch(data,filename,1350) end) --- --- local function less(value,target,original) --- -- officially we should check the original --- return 0.25 * value --- end - --- Just don't use this font. It's not good enough for production unless we patch it --- a lot, which we will not do unless we need it. - --- When set this will bypass the italic correction hackery! - --- local integral_variants = { bottomright = -0.20 } --- local integral_top = { topright = 0.05 } --- local integral_bottom = { bottomright = -0.25 } - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -70,32 +38,40 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 1 }, - presets.mathrsfscript { rscale = 1 }, - presets.mathxitsarabic { rscale = 0.95 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 2 }, + presets.wipeitalics { }, { tweak = "dimensions", list = { -- nothing yet } }, - -- { - -- tweak = "kerns", - -- list = { - -- [0x2F] = { - -- topleft = -0.2, - -- bottomleft = 0, - -- topright = 0, - -- bottomright = -0.2, - -- }, - -- }, - -- }, - -- { - -- tweak = "fixprimes", - -- factor = 0.85, - -- scale = 0.65, - -- smaller = true, - -- }, + -- { + -- tweak = "kerns", + -- list = { + -- [0x2F] = { + -- topleft = -0.2, + -- bottomleft = 0, + -- topright = 0, + -- bottomright = -0.2, + -- }, + -- }, + -- }, + -- { + -- tweak = "fixprimes", + -- factor = 0.85, + -- scale = 0.65, + -- smaller = true, + -- }, { tweak = "checkspacing", }, @@ -115,6 +91,12 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { diff --git a/tex/context/fonts/mkiv/bonum-math.lfg b/tex/context/fonts/mkiv/bonum-math.lfg index 508293f19..e5d764aff 100644 --- a/tex/context/fonts/mkiv/bonum-math.lfg +++ b/tex/context/fonts/mkiv/bonum-math.lfg @@ -1,29 +1,10 @@ -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_V = { bottomright = { { kern = -200 } } } - local kern_W = { bottomright = { { kern = -100 } } } - local offset_f = { xoffset = "llx" } - - dimensions = { - default = { - [0x1D453] = offset_f, -- 𝑓 - }, - } - - kerns = { - [0x1D449] = kern_V, -- 𝑉 - [0x1D44A] = kern_W, -- 𝑊 - } - -end +local common = fonts.goodies.load("common-math.lfg") +local presets = common.mathematics.tweaks.presets local integral_variants = { bottomright = -0.20 } local integral_top = { topright = 0.05 } local integral_bottom = { bottomright = -0.30 } -local common = fonts.goodies.load("common-math.lfg") -local presets = common.mathematics.tweaks.presets - return { name = "bonum-math", version = "1.00", @@ -79,53 +60,29 @@ return { }, }, }, - presets.matheulercalligraphic { rscale = 0.98 }, - presets.mathrsfscript { rscale = 0.98 }, - presets.mathxitsarabic { rscale = 1 }, - presets.moveitalics { correct = true }, - { - -- For some alphabets we remove italic correction. - -- tweak = "wipeitalics", - list = { - "digitsbold", - "digitsdoublestruck", - "digitsmonospace", - "digitsnormal", - "digitssansserifbold", - "digitssansserifnormal", - "lowercasebold", - "lowercaseboldfraktur", - "lowercasedoublestruck", - "lowercasefraktur", - "lowercasemonospace", - -- "lowercasenormal", - "lowercasesansserifbold", - -- "lowercasesansserifnormal", - "lowercasegreeknormal", - "uppercasebold", - "uppercaseboldfraktur", - "uppercasedoublestruck", - "uppercasefraktur", - "uppercasegreekbold", - "uppercasegreeknormal", - "uppercasegreeksansserifbold", - "uppercasemonospace", - "uppercasesansserifbold", - "uppercasesanserifnormal", -- some remain - }, - }, - { - -- tweak = "topaccents", - list = { - [0x1D453] = 0.7, -- f - }, - }, - { - tweak = "limits", - list = { - [0x0222B] = 1.5, - }, - }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.98 }, + presets.rsfsuprighttoscript { rscale = 0.98 }, + presets.moderntocalligraphic { rscale = 0.98 }, + presets.eulertocalligraphic { rscale = 0.98 }, + presets.xitsarabic { rscale = 1 }, + presets.fallbacks { }, + presets.moveintegrals { factor = 1.5 }, + presets.moveitalics { correct = true }, + presets.wipeanchors { }, + presets.wipeitalics { }, + -- { + -- tweak = "topaccents", + -- list = { + -- [0x1D453] = 0.7, -- f + -- }, + -- }, + -- { + -- tweak = "limits", + -- list = { + -- [0x0222B] = 1.5, + -- }, + -- }, { -- We need to check these, are the tweaks necessary or not? tweak = "dimensions", @@ -199,9 +156,9 @@ return { { tweak = "dimensions", list = { - [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat - [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde - [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve + [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat + [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde + [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck }, }, @@ -233,41 +190,6 @@ return { }, -- So far for the accents. { - -- For upright alphabets, we unset the anchor. This means that accents are placed - -- centered over the character. Should be on top. - tweak = "wipeanchors", - list = { - "digitsbold", - "digitsdoublestruck", - "digitsmonospace", - "digitsnormal", - "digitssansserifbold", - "digitssansserifnormal", - "lowercasebold", - "lowercaseboldfraktur", - "lowercasedoublestruck", - "lowercasefraktur", - "lowercasegreekbold", - "lowercasegreeknormal", - "lowercasegreeksansserifbold", - "lowercasemonospace", --- "lowercasenormal", - "lowercasesansserifbold", - "lowercasesansserifnormal", - "uppercasebold", - "uppercaseboldfraktur", - "uppercasedoublestruck", - "uppercasefraktur", - "uppercasegreekbold", - "uppercasegreeknormal", - "uppercasegreeksansserifbold", - "uppercasemonospace", - "uppercasenormal", - "uppercasesansserifbold", - "uppercasesansserifnormal", - }, - }, - { -- This one fakes margins to get larger/smaller accents with for example the -- \widetilde. tweak = "margins", @@ -467,9 +389,19 @@ return { tweak = "addequals", }, { - tweak = "addfourier", + tweak = "addfourier", variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, + -- + -- { + -- tweak = "diagnose", + -- }, }, }, @@ -479,134 +411,127 @@ return { bigslots = { 1, 3, 5, 7 }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, } +-- For now we keep these commented as they show where we came from. + -- \alpha is looking like an italic a. The one from Dejavu could perhaps be an alternative? -- No hvariants in 772 - - - --- From the dimension tweak: --- [0x00393] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \Gamma --- [0x00394] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \Delta --- [0x00398] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Theta --- [0x0039B] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Lambda --- [0x0039E] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Xi --- [0x003A0] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Pi --- [0x003A3] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Sigma --- [0x003A5] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Upsilon --- [0x003A6] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Phi --- [0x003A8] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Psi --- [0x003A9] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Omega --- [0x02202] = { xoffset = -0.075, width = 0.825, italic = 0 }, -- \partial --- [0x1D43A] = { xoffset = -0.1, width = 1, italic = 0 }, -- G --- [0x1D442] = { xoffset = -0.1, width = 1, italic = 0 }, -- O --- [0x1D444] = { xoffset = -0.05, width = 1.025, italic = 0 }, -- Q --- -- [0x1D44E] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.8 }, -- a --- -- [0x1D44F] = { xoffset = -0.05, width = 1.1, italic = 0 }, -- b --- -- [0x1D450] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- c --- -- [0x1D451] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.75 }, -- d --- -- [0x1D452] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- e --- -- [0x1D453] = { xoffset = 0.45, width = 1.9, italic = 0.45, anchor = 1.1 }, -- f --- -- [0x1D454] = { xoffset = 0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- g --- -- [0x0210E] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 1.15 }, -- h --- -- [0x1D456] = { xoffset = -0.2, width = 1.1, italic = 0 }, -- i --- -- [0x1D457] = { xoffset = 0.6, width = 1.7, italic = 0.45 }, -- j --- -- [0x1D458] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 1.15 }, -- k --- -- [0x1D459] = { xoffset = -0.15, width = 1.1, italic = 0, anchor = 0.8 }, -- l --- -- [0x1D45A] = { xoffset = -0.05, width = 1, italic = 0 }, -- m --- -- [0x1D45B] = { xoffset = -0.1, width = 1, italic = 0, anchor = 0.9 }, -- n --- -- [0x1D45C] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- o --- -- [0x1D45D] = { width = 1.05, italic = 0 }, -- p --- -- [0x1D45E] = { xoffset = -0.05, width = 1.05, italic = 0, anchor = 0.9 }, -- q --- -- [0x1D45F] = { xoffset = -0.1, width = 1.15, italic = 0, anchor = 0.9 }, -- r --- -- [0x1D460] = { xoffset = -0.05, width = 1.05, italic = 0 }, -- s --- -- [0x1D461] = { xoffset = -0.15, width = 1.2, italic = 0, anchor = 0.9 }, -- t --- -- [0x1D462] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 0.85 }, -- u --- -- [0x1D463] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 0.85 }, -- v --- -- [0x1D464] = { xoffset = -0.05, width = 1.05, italic = 0, anchor = 0.95 }, -- w --- -- [0x1D465] = { width = 1.175, italic = 0, anchor = 0.9 }, -- x --- -- [0x1D466] = { xoffset = -0.05, width = 1.05, italic = 0 }, -- y --- -- [0x1D467] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- z --- [0x1D6FC] = { xoffset = -0.075, width = 0.825, italic = 0 }, -- \alpha --- [0x1D6FD] = { width = 0.9, italic = 0, anchor = 1.05 }, -- \beta --- [0x1D6FE] = { xoffset = -0.075, width = 0.85, italic = 0.05, anchor = 1.05 }, -- \gamma --- [0x1D6FF] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \delta --- [0x1D716] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \epsilon --- [0x1D700] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \varepsilon --- [0x1D701] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \zeta --- [0x1D702] = { xoffset = -0.1, width = 0.85, italic = 0, anchor = 1.05 }, -- \eta --- [0x1D703] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \theta --- [0x1D717] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \vartheta --- [0x1D704] = { xoffset = -0.1, width = 0.9, italic = 0, anchor = 1.05 }, -- \iota --- [0x1D705] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \kappa --- [0x1D706] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.05 }, -- \lambda --- [0x1D707] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \mu --- [0x1D708] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \nu --- [0x1D709] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \xi --- [0x1D70A] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \omicron --- [0x1D70B] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \pi --- [0x1D71B] = { xoffset = -0.07, width = 0.85, italic = 0 }, -- \varpi --- [0x1D70C] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \rho --- [0x1D71A] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \varrho --- [0x1D70D] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.02 }, -- \varsigma --- [0x1D70E] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \sigma --- [0x1D70F] = { xoffset = -0.08, width = 0.85, italic = 0, anchor = 1.05 }, -- \tau --- [0x1D710] = { xoffset = -0.08, width = 0.85, italic = 0, anchor = 1.03 }, -- \upsilon --- [0x1D719] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \phi --- [0x1D711] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.02 }, -- \varphi --- [0x1D712] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \chi --- [0x1D713] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \psi --- [0x1D714] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \omega --- -- [0x1D718] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \varkappa --- [0x1D719] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \phi --- [0x1D41B] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright b --- [0x1D41D] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase upright d --- [0x1D41F] = { width = 1.25, italic = 0, anchor = 0.8 }, -- bold lowercase upright f --- [0x1D420] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase upright g --- [0x1D421] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright h --- [0x1D424] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright k --- [0x1D425] = { width = 1, italic = 0, anchor = 0.75 }, -- bold lowercase upright l --- [0x1D42A] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright q --- [0x1D42B] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright r --- [0x1D42C] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright s --- -- [0x1D482] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic a --- -- [0x1D483] = { width = 1, italic = 0, anchor = 1.1 }, -- bold lowercase italic b --- -- [0x1D484] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic c --- -- [0x1D485] = { width = 1, italic = 0, anchor = 0.75 }, -- bold lowercase italic d --- -- [0x1D486] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic e --- -- [0x1D487] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic f --- -- [0x1D488] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic g --- -- [0x1D489] = { width = 1, italic = 0, anchor = 1.2 }, -- bold lowercase italic h --- -- [0x1D48A] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase italic i --- -- [0x1D48B] = { width = 1, italic = 0, anchor = 0.8 }, -- bold lowercase italic j --- -- [0x1D48C] = { width = 1, italic = 0, anchor = 1.2 }, -- bold lowercase italic k --- -- [0x1D48D] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic l --- -- [0x1D492] = { width = 1, italic = 0, anchor = 0.85 }, -- bold lowercase italic q --- -- [0x1D493] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic r --- -- [0x1D497] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic v --- -- [0x1D499] = { width = 1.1, italic = 0, anchor = 0.9 }, -- bold lowercase italic x --- -- [0x1D49A] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic y --- -- [0x1D49B] = { width = 1, italic = 0, anchor = 1.1 }, -- bold lowercase italic z --- [0x1D743] = { width = 1, italic = 0, anchor = 1.7 }, -- bold lowercase italic greek xi --- -- [0x1D435] = { anchor = 1.05 }, -- italic B --- -- [0x1D436] = { xoffset = -0.1, anchor = 0.7 }, -- italic C --- -- [0x1D437] = { anchor = 1.25 }, -- italic D --- -- [0x1D43A] = { anchor = 0.8 }, -- italic G --- -- [0x1D442] = { anchor = 0.85 }, -- italic O --- -- [0x1D443] = { anchor = 1.1 }, -- italic P --- -- [0x1D444] = { anchor = 0.85 }, -- italic Q --- -- [0x1D445] = { xoffset = -0.025, width = 1.05, anchor = 1.05 }, -- italic R --- -- [0x1D446] = { xoffset = -0.05, anchor = 0.85 }, -- italic S --- -- [0x1D447] = { xoffset = -0.05, width = 1.05, italic = 0.7, anchor = 0.9, }, -- italic T --- -- [0x1D448] = { xoffset = -0.125, italic = 0.3, anchor = 0.9, }, -- italic U --- -- [0x1D449] = { xoffset = -0.125, italic = 0.3, anchor = 0.9, }, -- italic V --- -- [0x1D44A] = { xoffset = -0.075, italic = 0.3, anchor = 0.9, }, -- italic W --- -- [0x1D44C] = { xoffset = -0.075, width = 1.1, italic = 0.35, anchor = 0.9, }, -- italic Y +-- [0x00393] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \Gamma +-- [0x00394] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \Delta +-- [0x00398] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Theta +-- [0x0039B] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Lambda +-- [0x0039E] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Xi +-- [0x003A0] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Pi +-- [0x003A3] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Sigma +-- [0x003A5] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \Upsilon +-- [0x003A6] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Phi +-- [0x003A8] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Psi +-- [0x003A9] = { xoffset = -0.05, width = 0.9, italic = 0 }, -- \Omega +-- [0x02202] = { xoffset = -0.075, width = 0.825, italic = 0 }, -- \partial +-- [0x1D43A] = { xoffset = -0.1, width = 1, italic = 0 }, -- G +-- [0x1D442] = { xoffset = -0.1, width = 1, italic = 0 }, -- O +-- [0x1D444] = { xoffset = -0.05, width = 1.025, italic = 0 }, -- Q +-- [0x1D44E] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.8 }, -- a +-- [0x1D44F] = { xoffset = -0.05, width = 1.1, italic = 0 }, -- b +-- [0x1D450] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- c +-- [0x1D451] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.75 }, -- d +-- [0x1D452] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- e +-- [0x1D453] = { xoffset = 0.45, width = 1.9, italic = 0.45, anchor = 1.1 }, -- f +-- [0x1D454] = { xoffset = 0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- g +-- [0x0210E] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 1.15 }, -- h +-- [0x1D456] = { xoffset = -0.2, width = 1.1, italic = 0 }, -- i +-- [0x1D457] = { xoffset = 0.6, width = 1.7, italic = 0.45 }, -- j +-- [0x1D458] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 1.15 }, -- k +-- [0x1D459] = { xoffset = -0.15, width = 1.1, italic = 0, anchor = 0.8 }, -- l +-- [0x1D45A] = { xoffset = -0.05, width = 1, italic = 0 }, -- m +-- [0x1D45B] = { xoffset = -0.1, width = 1, italic = 0, anchor = 0.9 }, -- n +-- [0x1D45C] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- o +-- [0x1D45D] = { width = 1.05, italic = 0 }, -- p +-- [0x1D45E] = { xoffset = -0.05, width = 1.05, italic = 0, anchor = 0.9 }, -- q +-- [0x1D45F] = { xoffset = -0.1, width = 1.15, italic = 0, anchor = 0.9 }, -- r +-- [0x1D460] = { xoffset = -0.05, width = 1.05, italic = 0 }, -- s +-- [0x1D461] = { xoffset = -0.15, width = 1.2, italic = 0, anchor = 0.9 }, -- t +-- [0x1D462] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 0.85 }, -- u +-- [0x1D463] = { xoffset = -0.1, width = 1.05, italic = 0, anchor = 0.85 }, -- v +-- [0x1D464] = { xoffset = -0.05, width = 1.05, italic = 0, anchor = 0.95 }, -- w +-- [0x1D465] = { width = 1.175, italic = 0, anchor = 0.9 }, -- x +-- [0x1D466] = { xoffset = -0.05, width = 1.05, italic = 0 }, -- y +-- [0x1D467] = { xoffset = -0.05, width = 1.1, italic = 0, anchor = 0.9 }, -- z +-- [0x1D6FC] = { xoffset = -0.075, width = 0.825, italic = 0 }, -- \alpha +-- [0x1D6FD] = { width = 0.9, italic = 0, anchor = 1.05 }, -- \beta +-- [0x1D6FE] = { xoffset = -0.075, width = 0.85, italic = 0.05, anchor = 1.05 }, -- \gamma +-- [0x1D6FF] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \delta +-- [0x1D716] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \epsilon +-- [0x1D700] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \varepsilon +-- [0x1D701] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \zeta +-- [0x1D702] = { xoffset = -0.1, width = 0.85, italic = 0, anchor = 1.05 }, -- \eta +-- [0x1D703] = { xoffset = -0.1, width = 0.85, italic = 0 }, -- \theta +-- [0x1D717] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \vartheta +-- [0x1D704] = { xoffset = -0.1, width = 0.9, italic = 0, anchor = 1.05 }, -- \iota +-- [0x1D705] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \kappa +-- [0x1D706] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.05 }, -- \lambda +-- [0x1D707] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \mu +-- [0x1D708] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \nu +-- [0x1D709] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \xi +-- [0x1D70A] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \omicron +-- [0x1D70B] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \pi +-- [0x1D71B] = { xoffset = -0.07, width = 0.85, italic = 0 }, -- \varpi +-- [0x1D70C] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \rho +-- [0x1D71A] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \varrho +-- [0x1D70D] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.02 }, -- \varsigma +-- [0x1D70E] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \sigma +-- [0x1D70F] = { xoffset = -0.08, width = 0.85, italic = 0, anchor = 1.05 }, -- \tau +-- [0x1D710] = { xoffset = -0.08, width = 0.85, italic = 0, anchor = 1.03 }, -- \upsilon +-- [0x1D719] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \phi +-- [0x1D711] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.02 }, -- \varphi +-- [0x1D712] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \chi +-- [0x1D713] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \psi +-- [0x1D714] = { xoffset = -0.05, width = 0.875, italic = 0 }, -- \omega +-- -- [0x1D718] = { xoffset = -0.075, width = 0.85, italic = 0, anchor = 1.03 }, -- \varkappa +-- [0x1D719] = { xoffset = -0.075, width = 0.85, italic = 0 }, -- \phi +-- [0x1D41B] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright b +-- [0x1D41D] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase upright d +-- [0x1D41F] = { width = 1.25, italic = 0, anchor = 0.8 }, -- bold lowercase upright f +-- [0x1D420] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase upright g +-- [0x1D421] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright h +-- [0x1D424] = { width = 1, italic = 0, anchor = 1.5 }, -- bold lowercase upright k +-- [0x1D425] = { width = 1, italic = 0, anchor = 0.75 }, -- bold lowercase upright l +-- [0x1D42A] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright q +-- [0x1D42B] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright r +-- [0x1D42C] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase upright s +-- -- [0x1D482] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic a +-- -- [0x1D483] = { width = 1, italic = 0, anchor = 1.1 }, -- bold lowercase italic b +-- -- [0x1D484] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic c +-- -- [0x1D485] = { width = 1, italic = 0, anchor = 0.75 }, -- bold lowercase italic d +-- -- [0x1D486] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic e +-- -- [0x1D487] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic f +-- -- [0x1D488] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic g +-- -- [0x1D489] = { width = 1, italic = 0, anchor = 1.2 }, -- bold lowercase italic h +-- -- [0x1D48A] = { width = 1, italic = 0, anchor = 0.6 }, -- bold lowercase italic i +-- -- [0x1D48B] = { width = 1, italic = 0, anchor = 0.8 }, -- bold lowercase italic j +-- -- [0x1D48C] = { width = 1, italic = 0, anchor = 1.2 }, -- bold lowercase italic k +-- -- [0x1D48D] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic l +-- -- [0x1D492] = { width = 1, italic = 0, anchor = 0.85 }, -- bold lowercase italic q +-- -- [0x1D493] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic r +-- -- [0x1D497] = { width = 1, italic = 0, anchor = 0.9 }, -- bold lowercase italic v +-- -- [0x1D499] = { width = 1.1, italic = 0, anchor = 0.9 }, -- bold lowercase italic x +-- -- [0x1D49A] = { width = 1, italic = 0, anchor = 0.95 }, -- bold lowercase italic y +-- -- [0x1D49B] = { width = 1, italic = 0, anchor = 1.1 }, -- bold lowercase italic z +-- [0x1D743] = { width = 1, italic = 0, anchor = 1.7 }, -- bold lowercase italic greek xi +-- -- [0x1D435] = { anchor = 1.05 }, -- italic B +-- -- [0x1D436] = { xoffset = -0.1, anchor = 0.7 }, -- italic C +-- -- [0x1D437] = { anchor = 1.25 }, -- italic D +-- -- [0x1D43A] = { anchor = 0.8 }, -- italic G +-- -- [0x1D442] = { anchor = 0.85 }, -- italic O +-- -- [0x1D443] = { anchor = 1.1 }, -- italic P +-- -- [0x1D444] = { anchor = 0.85 }, -- italic Q +-- -- [0x1D445] = { xoffset = -0.025, width = 1.05, anchor = 1.05 }, -- italic R +-- -- [0x1D446] = { xoffset = -0.05, anchor = 0.85 }, -- italic S +-- -- [0x1D447] = { xoffset = -0.05, width = 1.05, italic = 0.7, anchor = 0.9, }, -- italic T +-- -- [0x1D448] = { xoffset = -0.125, italic = 0.3, anchor = 0.9, }, -- italic U +-- -- [0x1D449] = { xoffset = -0.125, italic = 0.3, anchor = 0.9, }, -- italic V +-- -- [0x1D44A] = { xoffset = -0.075, italic = 0.3, anchor = 0.9, }, -- italic W +-- -- [0x1D44C] = { xoffset = -0.075, width = 1.1, italic = 0.35, anchor = 0.9, }, -- italic Y diff --git a/tex/context/fonts/mkiv/cambria-math.lfg b/tex/context/fonts/mkiv/cambria-math.lfg index 8f9cf73b9..9cece8369 100644 --- a/tex/context/fonts/mkiv/cambria-math.lfg +++ b/tex/context/fonts/mkiv/cambria-math.lfg @@ -1,51 +1,3 @@ -local dimensions, kerns, kernpairs if CONTEXTLMTXMODE == 0 then - - kernpairs = { -- \setupmathematics[kernpairs=yes] - [0x1D44E] = { - [0x1D44F] = 1000, -- 𝑎𝑏 demo - } - } - - kerns = { - [0x1D453] = { - force = true, - topright = { - { - kern = 1000, - }, - }, - bottomright = { - { - kern = 1000, - }, - }, - }, - } - -end - --- local patches = fonts.handlers.otf.enhancers.patches --- --- local function patch(data,filename,threshold) --- local m = data.metadata.math --- if m then --- local d = m.DisplayOperatorMinHeight or 0 --- if d < threshold then --- patches.report("DisplayOperatorMinHeight(%s -> %s)",d,threshold) --- m.DisplayOperatorMinHeight = threshold --- end --- end --- end --- --- patches.register("after","analyze math","cambria", function(data,filename) patch(data,filename,2800) end) --- patches.register("after","analyze math","cambmath",function(data,filename) patch(data,filename,2800) end) - --- -- We could stick to the italic correction here --- --- local integral_variants = { bottomright = -0.20 } --- local integral_top = { topright = 0.05 } --- local integral_bottom = { bottomright = -0.30 } - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -59,9 +11,9 @@ return { parameters = { NoLimitSupFactor = 0, NoLimitSubFactor = 1000, - -- AccentTopShiftUp = 0, - -- FlattenedAccentTopShiftUp = 0, - -- AccentExtendMargin = 50, + -- AccentTopShiftUp = 0, + -- FlattenedAccentTopShiftUp = 0, + -- AccentExtendMargin = 50, AccentBaseDepth = 300, RadicalDegreeBottomRaisePercent = 65, RadicalKernAfterDegree = -900, @@ -77,15 +29,20 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.97 }, - presets.mathrsfscript { rscale = 0.97 }, - presets.mathxitsarabic { rscale = 0.95 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.97 }, + presets.rsfsuprighttoscript { rscale = 0.97 }, + presets.moderntocalligraphic { rscale = 0.97 }, + presets.eulertocalligraphic { rscale = 0.97 }, + presets.xitsarabic { rscale = 0.95 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5}, -- needs checking + presets.wipeitalics { }, { tweak = "simplifykerns", }, - presets.moveitalics { - correct = true - }, { tweak = "kerns", list = { @@ -237,48 +194,38 @@ return { bigslots = { 1, 2, 3, 4 }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, - kernpairs = kernpairs, }, } - --- Old - -- { - -- tweak = "dimensions", - -- list = { - - -- -- [0x00060] = { yoffset = -0.1 }, -- grave - -- -- [0x000B4] = { yoffset = -0.1 }, -- acute - -- -- [0x002C6] = { yoffset = -0.1 }, -- hat - -- -- [0x002DC] = { yoffset = -0.1 }, -- tilde - -- -- [0x000AF] = { yoffset = -0.1 }, -- bar - -- -- [0x002D8] = { yoffset = -0.15 }, -- breve - -- -- [0x002D9] = { yoffset = -0.15 }, -- dot - -- -- [0x000A8] = { yoffset = -0.1 }, -- ddot - -- -- [0x020DB] = { yoffset = -0.05 }, -- dddot - -- -- [0x002C7] = { yoffset = -0.1 }, -- check - -- -- [0x020D7] = { yoffset = -0.05 }, -- vec - - -- -- [0x00300] = { yoffset = -0.12, all=true }, -- widegrave - -- -- [0x00301] = { yoffset = -0.12, all=true }, -- wideacute - -- -- [0x00302] = { yoffset = -0.12, all=true }, -- widehat - -- -- [0x00303] = { yoffset = -0.12, all=true }, -- widetilde - -- -- [0x00304] = { yoffset = -0.12, all=true }, -- widebar - -- -- [0x00306] = { yoffset = -0.12, all=true }, -- widebreve - -- -- [0x00307] = { yoffset = -0.025, all=true }, -- widedot - -- -- [0x00308] = { yoffset = -0.025, all=true }, -- wideddot - -- -- [0x020DB] = { yoffset = -0.1, all=true }, -- widedddot - -- -- [0x0030A] = { yoffset = -0.12, all=true }, -- widering - -- -- [0x0030C] = { yoffset = -0.12, all=true }, -- widecheck - - -- [0x1D43D] = { xoffset = 0.25, width = 1.15, italic = 0.2 }, -- J - -- [0x1D487] = { anchor = 0.8 }, -- bold lower case italic f - -- -- [0x1D487] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- bold lower case italic f - - -- }, - -- }, +-- For now we keep these commented as they show where we came from. + +-- { +-- tweak = "dimensions", +-- list = { +-- -- [0x00060] = { yoffset = -0.1 }, -- grave +-- -- [0x000B4] = { yoffset = -0.1 }, -- acute +-- -- [0x002C6] = { yoffset = -0.1 }, -- hat +-- -- [0x002DC] = { yoffset = -0.1 }, -- tilde +-- -- [0x000AF] = { yoffset = -0.1 }, -- bar +-- -- [0x002D8] = { yoffset = -0.15 }, -- breve +-- -- [0x002D9] = { yoffset = -0.15 }, -- dot +-- -- [0x000A8] = { yoffset = -0.1 }, -- ddot +-- -- [0x020DB] = { yoffset = -0.05 }, -- dddot +-- -- [0x002C7] = { yoffset = -0.1 }, -- check +-- -- [0x020D7] = { yoffset = -0.05 }, -- vec +-- -- [0x00300] = { yoffset = -0.12, all=true }, -- widegrave +-- -- [0x00301] = { yoffset = -0.12, all=true }, -- wideacute +-- -- [0x00302] = { yoffset = -0.12, all=true }, -- widehat +-- -- [0x00303] = { yoffset = -0.12, all=true }, -- widetilde +-- -- [0x00304] = { yoffset = -0.12, all=true }, -- widebar +-- -- [0x00306] = { yoffset = -0.12, all=true }, -- widebreve +-- -- [0x00307] = { yoffset = -0.025, all=true }, -- widedot +-- -- [0x00308] = { yoffset = -0.025, all=true }, -- wideddot +-- -- [0x020DB] = { yoffset = -0.1, all=true }, -- widedddot +-- -- [0x0030A] = { yoffset = -0.12, all=true }, -- widering +-- -- [0x0030C] = { yoffset = -0.12, all=true }, -- widecheck +-- [0x1D43D] = { xoffset = 0.25, width = 1.15, italic = 0.2 }, -- J +-- [0x1D487] = { anchor = 0.8 }, -- bold lower case italic f +-- -- [0x1D487] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- bold lower case italic f +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/common-math.lfg b/tex/context/fonts/mkiv/common-math.lfg index d97511e76..c2c690bf1 100644 --- a/tex/context/fonts/mkiv/common-math.lfg +++ b/tex/context/fonts/mkiv/common-math.lfg @@ -7,10 +7,51 @@ return { mathematics = { tweaks = { presets = { - matheulercalligraphic = function(parameters) + fallbacks = function(parameters) + return { + tweak = "fallbacks", + } + end, + scripttocalligraphic = function(parameters) + return { + tweak = "replacealphabets", + feature = "scripttocalligraphic", + list = { + { + source = "uppercasescript", + target = "uppercasecalligraphic", + }, + { + source = "uppercaseboldscript", + target = "uppercaseboldcalligraphic", + }, + }, + } + end, + moderntocalligraphic = function(parameters) + return { + tweak = "replacealphabets", + feature = "moderntocalligraphic", + list = { + { + source = "uppercasescript", + target = "uppercasecalligraphic", + filename = "latinmodern-math.otf", + rscale = parameters.rscale, + }, + { + source = "uppercaseboldscript", + target = "uppercaseboldcalligraphic", + filename = "latinmodern-math.otf", + rscale = parameters.rscale, + }, + }, + } + end, + eulertocalligraphic = function(parameters) return { tweak = "replacealphabets", - feature = "matheulercalligraphic", + feature = "eulertocalligraphic", list = { { source = "uppercasescript", @@ -27,10 +68,30 @@ return { }, } end, - mathrsfscript = function(parameters) + rsfstoscript = function(parameters) return { tweak = "replacealphabets", - feature = "mathrsfscript", + feature = "rsfstoscript", + list = { + { + source = "uppercasescript", + target = "uppercasescript", + filename = "ralphsmithsformalscript-companion.otf", + rscale = parameters.rscale, + }, + { + source = "uppercaseboldscript", + target = "uppercaseboldscript", + filename = "ralphsmithsformalscript-companion.otf", + rscale = parameters.rscale, + }, + }, + } + end, + rsfsuprighttoscript = function(parameters) + return { + tweak = "replacealphabets", + feature = "rsfsuprighttoscript", list = { { source = "uppercasescript", @@ -49,10 +110,10 @@ return { }, } end, - mathxitsarabic = function(parameters) + xitsarabic = function(parameters) return { tweak = "replacealphabets", - feature = "mathxitsarabic", + feature = "xitsarabic", list = { { source = "arabicmathematicalalphabeticsymbols", @@ -79,7 +140,8 @@ return { return { tweak = "moveitalics", correct = parameters.correct, - list = { + list = (parameters.all and "all") or (parameters.letters and "letters") or { + -- "lowercasenormal", "lowercaseitalic", "lowercasebold", @@ -88,6 +150,19 @@ return { "lowercasegreekitalic", "lowercasegreekbold", "lowercasegreekbolditalic", + "lowercaseboldfraktur", + "lowercaseboldscript", + "lowercasedoublestruck", + "lowercasefraktur", + "lowercasegreeksansserifbold", + "lowercasegreeksansserifbolditalic", + "lowercasemonospace", + "lowercasesansserifbold", + "lowercasesansserifbolditalic", + "lowercasesansserifitalic", + "lowercasesansserifnormal", + "lowercasescript", + -- "uppercasenormal", "uppercaseitalic", "uppercasebold", @@ -96,10 +171,95 @@ return { "uppercasegreekitalic", "uppercasegreekbold", "uppercasegreekbolditalic", + "uppercaseboldfraktur", + "uppercasebolditalic", + "uppercaseboldscript", + "uppercasedoublestruck", + "uppercasefraktur", + "uppercasegreeksansserifbold", + "uppercasegreeksansserifbolditalic", + "uppercasemonospace", + "uppercasesansserifbold", + "uppercasesansserifbolditalic", + "uppercasesansserifitalic", + "uppercasesansserifnormal", + "uppercasescript", + -- + "digitsbold", + "digitsdoublestruck", + "digitslatin", + "digitsmonospace", + "digitsnormal", + "digitssansserifbold", + "digitssansserifnormal", + -- + -- We don't do these (one can use all=true) because now we can get + -- more details about what gets italics. + -- + -- "latinextendeda", + -- "latinextendedadditional", + -- "latinextendedb", + -- "latinextendedc", + -- "latinextendedd", + -- "latinextendede", + -- "latinextendedf", + -- "latinextendedg", + -- "latinsupplement", + -- mathematics.tweaks.subsets.dotless, } } end, + moveintegrals = function(parameters) + return { + tweak = "movelimits", + factor = parameters.factor or 1, + list = mathematics.tweaks.subsets.integrals, + } + end, + wipeitalics = function(parameters) + return { + tweak = "wipeitalics", + all = true, + } + end, + wipeanchors = function(parameters) + return { + -- For upright alphabets, we unset the anchor. This means that accents are placed + -- centered over the character. Should be on top. + tweak = "wipeanchors", + list = { + "digitsbold", + "digitsdoublestruck", + "digitsmonospace", + "digitsnormal", + "digitssansserifbold", + "digitssansserifnormal", + "lowercasebold", + "lowercaseboldfraktur", + "lowercasedoublestruck", + "lowercasefraktur", + "lowercasegreekbold", + "lowercasegreeknormal", + "lowercasegreeksansserifbold", + "lowercasemonospace", + "lowercasenormal", + "lowercasesansserifbold", + "lowercasesansserifnormal", + "uppercasebold", + "uppercaseboldfraktur", + "uppercasedoublestruck", + "uppercasefraktur", + "uppercasegreekbold", + "uppercasegreeknormal", + "uppercasegreeksansserifbold", + "uppercasemonospace", + "uppercasenormal", + "uppercasesansserifbold", + "uppercasesansserifnormal", + }, + } + end, }, }, }, diff --git a/tex/context/fonts/mkiv/concrete-math.lfg b/tex/context/fonts/mkiv/concrete-math.lfg index fd2d5caad..68d686593 100644 --- a/tex/context/fonts/mkiv/concrete-math.lfg +++ b/tex/context/fonts/mkiv/concrete-math.lfg @@ -1,5 +1,3 @@ --- this file might go away and is for experiments only - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -27,8 +25,16 @@ return { -- { -- tweak = "addmirrors", -- }, --- presets.matheulercalligraphic { rscale = 0.97 }, --- presets.mathrsfscript { rscale = 0.95 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "kerns", list = { @@ -52,13 +58,17 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { 1, 2, 3, 4 }, }, - } - diff --git a/tex/context/fonts/mkiv/dejavu-math.lfg b/tex/context/fonts/mkiv/dejavu-math.lfg index d18082b85..70eecb27e 100644 --- a/tex/context/fonts/mkiv/dejavu-math.lfg +++ b/tex/context/fonts/mkiv/dejavu-math.lfg @@ -1,21 +1,9 @@ -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_V = { bottomright = { { kern = -250 } } } - local kern_W = kern_W - - kerns = { - [0x1D449] = kern_V, -- 𝑉 - [0x1D44A] = kern_W, -- 𝑊 - } - -end +local common = fonts.goodies.load("common-math.lfg") +local presets = common.mathematics.tweaks.presets local integral_variants = { bottomright = -0.20 } local integral_bottom = { bottomright = -0.25 } -local common = fonts.goodies.load("common-math.lfg") -local presets = common.mathematics.tweaks.presets - return { name = "dejavu-math", version = "1.00", @@ -54,10 +42,17 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 1.02 }, - presets.mathrsfscript { rscale = 1.02 }, - presets.mathxitsarabic { rscale = 1.05 }, - presets.moveitalics { correct = true }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 1.02 }, + presets.rsfsuprighttoscript { rscale = 1.02 }, + presets.moderntocalligraphic { rscale = 1.02 }, + presets.eulertocalligraphic { rscale = 1.02 }, + presets.xitsarabic { rscale = 1.05 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, -- we need to check this + presets.wipeitalics { }, { tweak = "kerns", list = { @@ -71,7 +66,7 @@ return { ["0x221A.parts.top"] = { topright = 0.2, }, -- right radical top ["0x221A.parts.bottom"] = { bottomright = 0.2 }, -- right radical bottom ["0x221A.variants.*"] = { topright = 0.2, bottomright = 0.2 }, -- right radical variants - [0x27E9] = { topright = -0.1, bottomright = -0.1 }, -- angle + [0x27E9] = { topright = -0.1, bottomright = -0.1 }, -- angle ["0x27E9.variants.*"] = { topright = -0.2, bottomright = -0.2 }, [0x27EB] = { topright = -0.1, bottomright = -0.1 }, ["0x27EB.variants.*"] = { topright = -0.2, bottomright = -0.2 }, @@ -167,6 +162,12 @@ return { tweak = "addfourier", variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, alternates = { @@ -183,15 +184,14 @@ return { }, } +-- For now we keep these commented as they show where we came from. - --- Old - -- { - -- tweak = "dimensions", - -- list = { - -- [0x1D44E] = { width = 1, italic = 0, anchor = 0.9 }, -- a - -- -- [0x1D449] = { width = .8, italic = .2 }, - -- -- [0x1D44A] = { width = .8, italic = .2 }, - -- ["0x1D449:0x1D44A"] = { width = .8, italic = .2 }, - -- } - -- }, +-- { +-- tweak = "dimensions", +-- list = { +-- [0x1D44E] = { width = 1, italic = 0, anchor = 0.9 }, -- a +-- -- [0x1D449] = { width = .8, italic = .2 }, +-- -- [0x1D44A] = { width = .8, italic = .2 }, +-- ["0x1D449:0x1D44A"] = { width = .8, italic = .2 }, +-- } +-- }, diff --git a/tex/context/fonts/mkiv/erewhon-math.lfg b/tex/context/fonts/mkiv/erewhon-math.lfg index fe8bb7108..e366ee12e 100644 --- a/tex/context/fonts/mkiv/erewhon-math.lfg +++ b/tex/context/fonts/mkiv/erewhon-math.lfg @@ -1,4 +1,5 @@ --- This file might go away and is for experiments only. +-- This font is under active development so we don't want to tweek it too much +-- before all issues are sorted out. local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -32,9 +33,17 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.93 }, - presets.mathrsfscript { rscale = 0.93 }, - presets.mathxitsarabic { rscale = 0.90 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 0.90 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "kerns", list = { @@ -76,6 +85,12 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section +-- { +-- tweak = "emulatelmtx", +-- feature = "emulatelmtx", +-- comment = "this is for mkiv", +-- }, }, }, bigslots = { @@ -84,5 +99,3 @@ return { }, } - - diff --git a/tex/context/fonts/mkiv/euler-math.lfg b/tex/context/fonts/mkiv/euler-math.lfg index 9e5efa680..1c4659786 100644 --- a/tex/context/fonts/mkiv/euler-math.lfg +++ b/tex/context/fonts/mkiv/euler-math.lfg @@ -1,4 +1,5 @@ --- this file might go away and is for experiments only +local common = fonts.goodies.load("common-math.lfg") +local presets = common.mathematics.tweaks.presets return { name = "euler-math", @@ -8,26 +9,119 @@ return { copyright = "ConTeXt development team", mathematics = { parameters = { - DelimiterPercent = 901, - DelimiterShortfall = 500, + -- DelimiterPercent = 90, + -- DelimiterShortfall = 500, + -- taken from pagella: + NoLimitSupFactor = 0, + NoLimitSubFactor = 900, + AccentTopShiftUp = 10, + FlattenedAccentTopShiftUp = 10, + -- AccentExtendMargin = 50, + -- AccentBaseHeight = 0, + AccentBaseDepth = 80, + -- SpaceAfterScript = 0, + -- SpaceAfterScript = 30, + RadicalDegreeBottomRaisePercent = 60, + RadicalKernAfterDegree = -500, + RadicalRuleThickness = 60, -- 60 in font + DelimiterPercent = 90, + DelimiterShortfall = 400, + DisplayOperatorMinHeight = 1800, -- 1500 in font + PrimeRaisePercent = 75, -- 50 default + PrimeRaiseComposedPercent = 10, -- 25 default + -- RadicalKernAfterExtensible = 0, -- 0 default + -- RadicalKernBeforeExtensible = 0, -- 0 default + }, tweaks = { aftercopying = { { + tweak = "version", + expected = "Version 000.002 ", + }, + { tweak = "fixprimes", - factor = 0.9, + factor = 1.2, smaller = true, - scale = 0.60, - fake = 0.75, + scale = 0.80, + fake = 0.80, + }, + { + tweak = "replacealphabets", + feature = "pagellaovereuler", + filename = "texgyrepagella-math.otf", + list = { + -- { source = { first = 0x02100, last = 0x0210D } }, -- no 0x2210E + -- { source = { first = 0x0210F, last = 0x02BFF } }, + { source = { first = 0x02100, last = 0x02BFF } }, + { source = { first = 0x1D400, last = 0x1D7FF } }, + { source = { first = 0x1D538, last = 0x1D550 } }, + }, + }, + { + tweak = "addmirrors", + }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 1 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { }, + presets.wipeitalics { }, + { + tweak = "fixoldschool", + }, + -- add the accent fixes + -- fixslashes? + { + tweak = "checkspacing", + }, + { + tweak = "addscripts", + }, + { + tweak = "addprivates", + }, + { + tweak = "accentdimensions", + }, + { + tweak = "addrules", + }, + { + tweak = "addarrows", + }, + { + tweak = "addbars", + advance = 0.2, + }, + { + tweak = "addactuarian", + }, + { + tweak = "addequals", + }, + { + tweak = "addfourier", + variant = 1, + }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", }, }, }, bigslots = { 1, 3, 5, 7 }, + alternates = { + dotless = { feature = 'dtls', value = 1, comment = "Mathematical Dotless Forms" }, + }, }, - - } - - diff --git a/tex/context/fonts/mkiv/garamond-math.lfg b/tex/context/fonts/mkiv/garamond-math.lfg index a0a0700f5..9537f52b9 100644 --- a/tex/context/fonts/mkiv/garamond-math.lfg +++ b/tex/context/fonts/mkiv/garamond-math.lfg @@ -42,19 +42,20 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.95 }, - presets.mathrsfscript { rscale = 0.95 }, - presets.mathxitsarabic { rscale = 0.80 }, - { - tweak = "oldstylemath", - factor = 0, - }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.95 }, + presets.rsfsuprighttoscript { rscale = 0.95 }, + presets.moderntocalligraphic { rscale = 0.95 }, + presets.eulertocalligraphic { rscale = 0.95 }, + presets.xitsarabic { rscale = 0.80 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "simplifykerns", }, - presets.moveitalics { - correct = true - }, { tweak = "topanchors", list = { @@ -62,15 +63,10 @@ return { }, }, { - tweak = "limits", - factor = 1.5, - list = mathematics.tweaks.subsets.integrals, - }, - { tweak = "dimensions", list = { -- for older entries, see bottom of file - [0x1D453] = { width = 1.1, }, -- italic f + [0x1D453] = { width = 1.1 }, -- italic f }, }, { @@ -140,10 +136,10 @@ return { [mathematics.tweaks.subsets.f] = -.25, [0x1D70C] = -.25, -- italic \rho }, - -- "uppercaseitalic" = { - -- [mathematics.tweaks.subsets.f] = -.25, - -- [0x1D70C] = -.25, -- italic \rho - -- }, + -- ["uppercaseitalic"] = { + -- [mathematics.tweaks.subsets.f] = -.25, + -- [0x1D70C] = -.25, -- italic \rho + -- }, }, }, -- Accents are a mess. We migrate the extensibles from the combiners to the base accent @@ -160,10 +156,10 @@ return { { tweak = "dimensions", list = { - -- [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat - -- [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde - -- [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve - -- [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck + -- [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat + -- [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde + -- [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve + -- [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck }, }, -- Then we deal with all offsets and heights in one go. So we treat the initial accent @@ -192,39 +188,6 @@ return { { tweak = "copyaccents", }, - -- So far for the accents. - { - -- For non-italic alphabets we remove italic correction. - -- This one is/will become obsolete - -- tweak = "wipeitalics", - list = { - "digitsbold", - "digitsdoublestruck", - "digitsmonospace", - "digitsnormal", - "digitssansserifbold", - "digitssansserifnormal", - -- "lowercasebold", - "lowercaseboldfraktur", - "lowercasedoublestruck", - "lowercasefraktur", - "lowercasemonospace", - -- "lowercasenormal", - "lowercasesansserifbold", - -- "lowercasesansserifnormal", - -- "lowercasegreeknormal", - -- "uppercasebold", - "uppercaseboldfraktur", - "uppercasedoublestruck", - "uppercasefraktur", - "uppercasegreekbold", - "uppercasegreeknormal", - "uppercasegreeksansserifbold", - "uppercasemonospace", - "uppercasesansserifbold", - "uppercasesanserifnormal", -- some remain - }, - }, { tweak = "checkspacing", }, @@ -251,6 +214,12 @@ return { tweak = "addfourier", variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, { tweak = "diagnose", }, @@ -272,82 +241,78 @@ return { }, } +-- For now we keep these commented as they show where we came from. +-- { +-- tweak = "dimensions", +-- list = { +-- -- offset width italic +-- -- -- [0x00060] = { yoffset = -0.1 }, -- grave +-- -- -- [0x000B4] = { yoffset = -0.1 }, -- acute +-- -- [0x002C6] = { yoffset = -0.1 }, -- hat +-- -- [0x002DC] = { yoffset = -0.1 }, -- tilde +-- -- -- [0x000AF] = { yoffset = -0.1 }, -- bar +-- -- [0x002D8] = { yoffset = -0.15 }, -- breve +-- -- [0x002D9] = { yoffset = -0.15 }, -- dot +-- -- -- [0x000A8] = { yoffset = -0.1 }, -- ddot +-- -- [0x020DB] = { yoffset = -0.115 }, -- dddot +-- -- [0x002C7] = { yoffset = -0.1 }, -- check +-- -- [0x020D7] = { yoffset = -0.1 }, -- vec +-- -- [0x00300] = { yoffset = -0.12 , all = true }, -- widegrave +-- -- [0x00301] = { yoffset = -0.12 , all = true }, -- wideacute +-- -- [0x00302] = { yoffset = -0.12 , all = true }, -- widehat +-- -- [0x00303] = { yoffset = -0.12 , all = true }, -- widetilde +-- -- [0x00304] = { yoffset = -0.12 , all = true }, -- widebar +-- -- [0x00306] = { yoffset = -0.12 , all = true }, -- widebreve +-- -- [0x00307] = { yoffset = -0.12 , all = true }, -- widedot +-- -- [0x00308] = { yoffset = -0.12 , all = true }, -- wideddot +-- -- -- [0x020DB] = { yoffset = -0.1 , all = true }, -- widedddot +-- -- [0x0030A] = { yoffset = -0.12 , all = true }, -- widering +-- -- [0x0030C] = { yoffset = -0.12 , all = true }, -- widecheck --- Some old entries: - - -- { - -- tweak = "dimensions", - -- list = { - -- -- offset width italic - -- -- -- [0x00060] = { yoffset = -0.1 }, -- grave - -- -- -- [0x000B4] = { yoffset = -0.1 }, -- acute - -- -- [0x002C6] = { yoffset = -0.1 }, -- hat - -- -- [0x002DC] = { yoffset = -0.1 }, -- tilde - -- -- -- [0x000AF] = { yoffset = -0.1 }, -- bar - -- -- [0x002D8] = { yoffset = -0.15 }, -- breve - -- -- [0x002D9] = { yoffset = -0.15 }, -- dot - -- -- -- [0x000A8] = { yoffset = -0.1 }, -- ddot - -- -- [0x020DB] = { yoffset = -0.115 }, -- dddot - -- -- [0x002C7] = { yoffset = -0.1 }, -- check - -- -- [0x020D7] = { yoffset = -0.1 }, -- vec - - -- -- [0x00300] = { yoffset = -0.12 , all = true }, -- widegrave - -- -- [0x00301] = { yoffset = -0.12 , all = true }, -- wideacute - -- -- [0x00302] = { yoffset = -0.12 , all = true }, -- widehat - -- -- [0x00303] = { yoffset = -0.12 , all = true }, -- widetilde - -- -- [0x00304] = { yoffset = -0.12 , all = true }, -- widebar - -- -- [0x00306] = { yoffset = -0.12 , all = true }, -- widebreve - -- -- [0x00307] = { yoffset = -0.12 , all = true }, -- widedot - -- -- [0x00308] = { yoffset = -0.12 , all = true }, -- wideddot - -- -- -- [0x020DB] = { yoffset = -0.1 , all = true }, -- widedddot - -- -- [0x0030A] = { yoffset = -0.12 , all = true }, -- widering - -- -- [0x0030C] = { yoffset = -0.12 , all = true }, -- widecheck - - -- -- [0x002C6] = { scale =.85, yoffset = .1, width = .85, height = .935 }, -- hat - - -- [0x00393] = { xoffset = 0.05, width = 1.05, italic = 0.075 }, -- \Gamma - -- -- [0x003A6] = { xoffset = 0.05, width = 1.05, italic = 0 }, -- \Phi difficult! - -- [0x003A8] = { xoffset = 0.05, width = 1.05, italic = 0.075 }, -- \Psi - -- [0x02113] = { width = 1, italic = 0.075 }, -- \ell - -- [0x1D436] = { width = 1, italic = 0.05 }, -- C - -- [0x1D43D] = { xoffset = 0.3, width = 1.4, italic = 0.1 }, -- J - -- [0x1D44B] = { width = 1, italic = 0.05 }, -- X - -- [0x1D44F] = { width = 1, italic = 0, }, -- b - -- [0x1D450] = { width = 1.1, italic = 0 }, -- c - -- [0x1D451] = { width = 1, italic = 0.05, }, -- d - -- [0x1D452] = { width = 1.1, italic = 0.05 }, -- e - -- [0x00066] = { width = 1.4, italic = 0.0, }, -- f - -- [0x1D453] = { xoffset = 0.15, width = 1.15, italic = 0.1, }, -- f - -- [0x1D454] = { xoffset = 0.1, width = 1.2, italic = 0.1 }, -- g - -- [0x0210E] = { width = 1.1, italic = 0, }, -- h - -- [0x1D457] = { xoffset = 0.2, width = 1.25, italic = 0.05 }, -- j - -- [0x1D458] = { width = 1, italic = 0, }, -- k - -- [0x1D459] = { width = 1, italic = 0.05 }, -- l - -- [0x1D45D] = { xoffset = 0.15, width = 1.15, italic = 0, }, -- p - -- [0x1D45E] = { width = 1.05, italic = 0 }, -- q - -- [0x1D45F] = { width = 1.05, italic = 0 }, -- r - -- [0x1D461] = { width = 1, italic = 0.1 }, -- t - -- [0x1D465] = { xoffset = 0.05, width = 1.1, italic = 0.05 }, -- x - -- [0x1D466] = { xoffset = 0.2, width = 1.2, italic = 0, }, -- y - -- [0x1D6FD] = { xoffset = 0.05, width = 1.1, italic = 0.05 }, -- \beta - -- [0x1D6FE] = { width = 1.05, italic = 0 }, -- \gamma - -- [0x1D6FF] = { width = 1, italic = 0.1 }, -- \delta - -- [0x1D716] = { width = 1.1, italic = 0 }, -- \epsilon - -- [0x1D700] = { width = 1.1, italic = 0 }, -- \varepsilon - -- [0x1D701] = { width = 1, italic = 0.15 }, -- \zeta - -- [0x1D703] = { width = 1, italic = 0.1 }, -- \theta - -- [0x1D705] = { width = 1, italic = 0.1 }, -- \kappa - -- [0x1D706] = { xoffset = 0.05, width = 1.1, italic = 0 }, -- \lambda - -- [0x1D707] = { xoffset = 0.05, width = 1.05, italic = 0 }, -- \mu - -- [0x1D708] = { width = 1.1, italic = 0 }, -- \nu - -- [0x1D709] = { width = 1.1, italic = 0 }, -- \xi - -- [0x1D70B] = { width = 1.05, italic = 0 }, -- \pi - -- [0x1D70C] = { xoffset = 0.2, width = 1.2, italic = 0 }, -- \rho - -- [0x1D70E] = { width = 1, italic = 0.1 }, -- \sigma - -- [0x1D70F] = { xoffset = 0.05, width = 1.05, italic = 0.1 }, -- \tau - -- [0x1D712] = { xoffset = 0.15, width = 1.2, italic = 0.05 }, -- \chi - -- [0x1D713] = { xoffset = 0.05, width = 1.05, italic = 0.05 }, -- \psi - -- }, - -- }, +-- -- [0x002C6] = { scale =.85, yoffset = .1, width = .85, height = .935 }, -- hat +-- [0x00393] = { xoffset = 0.05, width = 1.05, italic = 0.075 }, -- \Gamma +-- -- [0x003A6] = { xoffset = 0.05, width = 1.05, italic = 0 }, -- \Phi difficult! +-- [0x003A8] = { xoffset = 0.05, width = 1.05, italic = 0.075 }, -- \Psi +-- [0x02113] = { width = 1, italic = 0.075 }, -- \ell +-- [0x1D436] = { width = 1, italic = 0.05 }, -- C +-- [0x1D43D] = { xoffset = 0.3, width = 1.4, italic = 0.1 }, -- J +-- [0x1D44B] = { width = 1, italic = 0.05 }, -- X +-- [0x1D44F] = { width = 1, italic = 0, }, -- b +-- [0x1D450] = { width = 1.1, italic = 0 }, -- c +-- [0x1D451] = { width = 1, italic = 0.05, }, -- d +-- [0x1D452] = { width = 1.1, italic = 0.05 }, -- e +-- [0x00066] = { width = 1.4, italic = 0.0, }, -- f +-- [0x1D453] = { xoffset = 0.15, width = 1.15, italic = 0.1, }, -- f +-- [0x1D454] = { xoffset = 0.1, width = 1.2, italic = 0.1 }, -- g +-- [0x0210E] = { width = 1.1, italic = 0, }, -- h +-- [0x1D457] = { xoffset = 0.2, width = 1.25, italic = 0.05 }, -- j +-- [0x1D458] = { width = 1, italic = 0, }, -- k +-- [0x1D459] = { width = 1, italic = 0.05 }, -- l +-- [0x1D45D] = { xoffset = 0.15, width = 1.15, italic = 0, }, -- p +-- [0x1D45E] = { width = 1.05, italic = 0 }, -- q +-- [0x1D45F] = { width = 1.05, italic = 0 }, -- r +-- [0x1D461] = { width = 1, italic = 0.1 }, -- t +-- [0x1D465] = { xoffset = 0.05, width = 1.1, italic = 0.05 }, -- x +-- [0x1D466] = { xoffset = 0.2, width = 1.2, italic = 0, }, -- y +-- [0x1D6FD] = { xoffset = 0.05, width = 1.1, italic = 0.05 }, -- \beta +-- [0x1D6FE] = { width = 1.05, italic = 0 }, -- \gamma +-- [0x1D6FF] = { width = 1, italic = 0.1 }, -- \delta +-- [0x1D716] = { width = 1.1, italic = 0 }, -- \epsilon +-- [0x1D700] = { width = 1.1, italic = 0 }, -- \varepsilon +-- [0x1D701] = { width = 1, italic = 0.15 }, -- \zeta +-- [0x1D703] = { width = 1, italic = 0.1 }, -- \theta +-- [0x1D705] = { width = 1, italic = 0.1 }, -- \kappa +-- [0x1D706] = { xoffset = 0.05, width = 1.1, italic = 0 }, -- \lambda +-- [0x1D707] = { xoffset = 0.05, width = 1.05, italic = 0 }, -- \mu +-- [0x1D708] = { width = 1.1, italic = 0 }, -- \nu +-- [0x1D709] = { width = 1.1, italic = 0 }, -- \xi +-- [0x1D70B] = { width = 1.05, italic = 0 }, -- \pi +-- [0x1D70C] = { xoffset = 0.2, width = 1.2, italic = 0 }, -- \rho +-- [0x1D70E] = { width = 1, italic = 0.1 }, -- \sigma +-- [0x1D70F] = { xoffset = 0.05, width = 1.05, italic = 0.1 }, -- \tau +-- [0x1D712] = { xoffset = 0.15, width = 1.2, italic = 0.05 }, -- \chi +-- [0x1D713] = { xoffset = 0.05, width = 1.05, italic = 0.05 }, -- \psi +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/generic-math.lfg b/tex/context/fonts/mkiv/generic-math.lfg index 214e479e0..2a55504da 100644 --- a/tex/context/fonts/mkiv/generic-math.lfg +++ b/tex/context/fonts/mkiv/generic-math.lfg @@ -36,7 +36,24 @@ return { -- whatever }, }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 1 }, + presets.rsfsuprighttoscript { rscale = 1 }, + presets.moderntocalligraphic { rscale = 1 }, + presets.eulertocalligraphic { rscale = 1 }, + presets.xitsarabic { rscale = 1 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, -- we need to check the 1.5 + presets.wipeanchors { }, + presets.wipeitalics { }, { + tweak = "simplifykerns", + }, + presets.moveitalics { + correct = true + }, { tweak = "fixprimes", factor = 0.85, -- accent base height smaller = true, -- replace multiples @@ -101,7 +118,7 @@ return { -- [0x21CB] = false, -- [0x21CC] = false, } - }, + }, -- { -- tweak = "limits", -- factor = 1.5, @@ -201,7 +218,7 @@ return { tweak = "margins", list = { }, - }, + }, -- { -- tweak = "fixanchors", -- factor = .5, @@ -222,6 +239,12 @@ return { { tweak = "wipecues", }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { diff --git a/tex/context/fonts/mkiv/kpfonts-math.lfg b/tex/context/fonts/mkiv/kpfonts-math.lfg index ed50baf3b..a4eff599f 100644 --- a/tex/context/fonts/mkiv/kpfonts-math.lfg +++ b/tex/context/fonts/mkiv/kpfonts-math.lfg @@ -1,3 +1,6 @@ +-- This font is under active development so we don't want to tweek it too much +-- before all issues are sorted out. + local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -82,9 +85,17 @@ return { }, }, }, - presets.matheulercalligraphic { rscale = 0.95 }, - presets.mathrsfscript { rscale = 0.95 }, - presets.mathxitsarabic { rscale = 0.92 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.95 }, + presets.rsfsuprighttoscript { rscale = 0.95 }, + presets.moderntocalligraphic { rscale = 0.95 }, + presets.eulertocalligraphic { rscale = 0.95 }, + presets.xitsarabic { rscale = 0.92 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.4 }, + presets.wipeitalics { }, { tweak = "checkspacing", }, @@ -112,6 +123,12 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section +-- { +-- tweak = "emulatelmtx", +-- feature = "emulatelmtx", +-- comment = "this is for mkiv", +-- }, }, }, alternates = { diff --git a/tex/context/fonts/mkiv/libertinus-math.lfg b/tex/context/fonts/mkiv/libertinus-math.lfg index ea6a27cad..5a1cbd088 100644 --- a/tex/context/fonts/mkiv/libertinus-math.lfg +++ b/tex/context/fonts/mkiv/libertinus-math.lfg @@ -47,38 +47,21 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.92 }, - presets.mathrsfscript { rscale = 0.92 }, - presets.mathxitsarabic { rscale = 0.85 }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.97 }, + presets.rsfsuprighttoscript { rscale = 0.97 }, + presets.moderntocalligraphic { rscale = 0.97 }, + presets.eulertocalligraphic { rscale = 0.97 }, + presets.xitsarabic { rscale = 0.85 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "simplifykerns", }, { - -- When it makes sense we get rid of italics. - tweak = "moveitalics", - correct = true, - list = { - "lowercasenormal", - "lowercaseitalic", - "lowercasebold", - "lowercasebolditalic", - "lowercasegreeknormal", - "lowercasegreekitalic", - "lowercasegreekbold", - "lowercasegreekbolditalic", - "uppercasenormal", - "uppercaseitalic", - "uppercasebold", - "uppercasebolditalic", - "uppercasegreeknormal", - "uppercasegreekitalic", - "uppercasegreekbold", - "uppercasegreekbolditalic", - mathematics.tweaks.subsets.dotless, - } - }, - - { tweak = "kerns", list = { [0x002F] = { topleft = -0.15, bottomright = -0.15 }, @@ -179,6 +162,12 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { @@ -187,39 +176,39 @@ return { }, } --- Old values - -- { - -- tweak = "dimensions", - -- list = { - -- -- [0x00060] = { yoffset = -0.075 }, -- grave - -- -- [0x000B4] = { yoffset = -0.075 }, -- acute - -- -- [0x002C6] = { yoffset = -0.075 }, -- hat - -- -- [0x002DC] = { yoffset = -0.075 }, -- tilde - -- -- [0x000AF] = { yoffset = -0.1 }, -- bar - -- -- [0x002D8] = { yoffset = -0.075 }, -- breve - -- -- [0x002D9] = { yoffset = -0.05 }, -- dot - -- -- [0x000A8] = { yoffset = -0.02 }, -- ddot - -- -- [0x020DB] = { yoffset = -0.02 }, -- dddot - -- -- [0x002DA] = { yoffset = -0.1 }, -- ring - -- -- [0x002C7] = { yoffset = -0.1 }, -- check - -- -- [0x020D7] = { yoffset = -0.1 }, -- vec +-- For now we keep these commented as they show where we came from. - -- -- [0x00300] = { yoffset = -0.1, all = true }, -- widegrave - -- -- [0x00301] = { yoffset = -0.1, all = true }, -- wideacute - -- -- [0x00302] = { yoffset = -0.1, all = true }, -- widehat - -- -- [0x00303] = { yoffset = -0.09, all = true }, -- widetilde - -- -- [0x00304] = { yoffset = -0.12, all = true }, -- widebar - -- -- [0x00306] = { yoffset = -0.05, all = true }, -- widebreve - -- -- [0x00307] = { yoffset = -0.02, all = true }, -- widedot - -- -- [0x00308] = { yoffset = -0.02, all = true }, -- wideddot - -- -- [0x020DB] = { yoffset = -0.1, all = true }, -- widedddot - -- -- [0x0030A] = { yoffset = -0.12, all = true }, -- widering - -- -- [0x0030C] = { yoffset = -0.04, all = true }, -- widecheck +-- { +-- tweak = "dimensions", +-- list = { +-- -- [0x00060] = { yoffset = -0.075 }, -- grave +-- -- [0x000B4] = { yoffset = -0.075 }, -- acute +-- -- [0x002C6] = { yoffset = -0.075 }, -- hat +-- -- [0x002DC] = { yoffset = -0.075 }, -- tilde +-- -- [0x000AF] = { yoffset = -0.1 }, -- bar +-- -- [0x002D8] = { yoffset = -0.075 }, -- breve +-- -- [0x002D9] = { yoffset = -0.05 }, -- dot +-- -- [0x000A8] = { yoffset = -0.02 }, -- ddot +-- -- [0x020DB] = { yoffset = -0.02 }, -- dddot +-- -- [0x002DA] = { yoffset = -0.1 }, -- ring +-- -- [0x002C7] = { yoffset = -0.1 }, -- check +-- -- [0x020D7] = { yoffset = -0.1 }, -- vec - -- -- [0x1D44F] = { width = 1, italic = 0, anchor = 1.5 }, -- b (6.8) - -- -- [0x1D451] = { width = 1, italic = 0, anchor = 1.2 }, -- d (6.8) - -- -- [0x0210E] = { width = 1, italic = 0, anchor = 1.5 }, -- h (6.8) - -- -- [0x1D458] = { width = 1, italic = 0, anchor = 1.5 }, -- k (6.8) - -- }, - -- }, +-- -- [0x00300] = { yoffset = -0.1, all = true }, -- widegrave +-- -- [0x00301] = { yoffset = -0.1, all = true }, -- wideacute +-- -- [0x00302] = { yoffset = -0.1, all = true }, -- widehat +-- -- [0x00303] = { yoffset = -0.09, all = true }, -- widetilde +-- -- [0x00304] = { yoffset = -0.12, all = true }, -- widebar +-- -- [0x00306] = { yoffset = -0.05, all = true }, -- widebreve +-- -- [0x00307] = { yoffset = -0.02, all = true }, -- widedot +-- -- [0x00308] = { yoffset = -0.02, all = true }, -- wideddot +-- -- [0x020DB] = { yoffset = -0.1, all = true }, -- widedddot +-- -- [0x0030A] = { yoffset = -0.12, all = true }, -- widering +-- -- [0x0030C] = { yoffset = -0.04, all = true }, -- widecheck +-- -- [0x1D44F] = { width = 1, italic = 0, anchor = 1.5 }, -- b (6.8) +-- -- [0x1D451] = { width = 1, italic = 0, anchor = 1.2 }, -- d (6.8) +-- -- [0x0210E] = { width = 1, italic = 0, anchor = 1.5 }, -- h (6.8) +-- -- [0x1D458] = { width = 1, italic = 0, anchor = 1.5 }, -- k (6.8) +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/lm.lfg b/tex/context/fonts/mkiv/lm.lfg index 355b583d1..984038d58 100644 --- a/tex/context/fonts/mkiv/lm.lfg +++ b/tex/context/fonts/mkiv/lm.lfg @@ -4,59 +4,6 @@ local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_150 = { bottomright = { { kern = -150 } } } - local kern_200 = { bottomright = { { kern = -200 } } } - - kerns = { - [0x1D449] = kern_150, -- - [0x1D44A] = kern_200, -- 𝑊 - - [0x1D4AB] = { - -- topleft = { { kern = -200 } }, - bottomright = { { kern = -200 } }, - }, - } - - dimensions = { - -- always applied - -- default = { - -- }, - -- driven by 'mathdimensions' feature - default = { - -- the root is quite displaced - [0x221A] = { - -- 73, -960, 853, 40 - yoffset = 960 - 40, - height = 960, - depth = 40, - }, - - -- [0xFE932] = { xoffset = 50, width = 290 }, -- used prime - -- [0x2032] = { xoffset = 50, width = 290 }, -- prime - }, - -- -- seems ok now -- - -- signs = { - -- -- [0x00B1] = { -- ± - -- -- height = 500, depth = 0, - -- -- }, - -- -- [0x2213] = { -- ∓ - -- -- height = 500, depth = 0, - -- -- }, - -- -- move in boundingbox - -- [0x00B1] = { -- ± - -- yoffset = 100, - -- }, - -- [0x2213] = { -- ∓ - -- yoffset = -100, - -- }, - -- }, - } - -end - - return { name = "latin modern", version = "1.00", @@ -70,7 +17,7 @@ return { NoLimitSubFactor = 900, AccentTopShiftUp = -60, FlattenedAccentTopShiftUp = -60, - -- AccentExtendMargin = 50, + -- AccentExtendMargin = 50, -- AccentBaseHeight = 0, -- AccentBaseDepth = 0, -- AccentTopOvershoot = 66, @@ -81,12 +28,12 @@ return { -- DisplayOperatorMinHeight = 1800, -- 1300 in font (only one) PrimeRaisePercent = 60, PrimeRaiseComposedPercent = 15, - -- SubSuperscriptGapMin = 160, -- 160 in font + -- SubSuperscriptGapMin = 160, -- 160 in font SuperscriptBaselineDropMax = 250, -- 250 in font - -- SuperscriptBottomMaxWithSubscript = 344, -- 344 in font - -- SuperscriptBottomMin = 108, -- 108 in font + -- SuperscriptBottomMaxWithSubscript = 344, -- 344 in font + -- SuperscriptBottomMin = 108, -- 108 in font SuperscriptShiftUp = 363, -- 363 in font - SuperscriptShiftUpCramped = 89, -- 289 in font + SuperscriptShiftUpCramped = 89, -- 289 in font }, tweaks = { aftercopying = { @@ -97,68 +44,22 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 1 }, - presets.mathrsfscript { rscale = 1 }, - presets.mathxitsarabic { rscale = 0.88 }, - presets.moveitalics { correct = true }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 0.80 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.4 }, + presets.wipeanchors { }, + presets.wipeitalics { }, + -- these will become moveanchors { tweak = "dimensions", list = { - -- [0x00060] = { yoffset = -0.05 }, -- grave - -- [0x000B4] = { yoffset = -0.05 }, -- acute - -- [0x002C6] = { yoffset = -0.05 }, -- hat - -- [0x002DC] = { yoffset = -0.05 }, -- tilde - -- [0x000AF] = { yoffset = -0.075 }, -- bar - -- [0x002D8] = { yoffset = -0.05 }, -- breve - -- [0x002D9] = { yoffset = -0.05 }, -- dot - -- [0x000A8] = { yoffset = -0.05 }, -- ddot - -- [0x020DB] = { yoffset = 0.2 }, -- dddot (done below!) - -- [0x002DA] = { width = 0 }, -- ring (bounding box is wrong) - -- [0x002C7] = { yoffset = -0.05 }, -- check - -- [0x020D7] = { yoffset = -0.05 }, -- vec - - -- [0x00300] = { yoffset = -0.03, all = true }, -- widegrave - -- [0x00301] = { yoffset = -0.03, all = true }, -- wideacute - -- [0x00302] = { yoffset = -0.075, all = true }, -- widehat - -- [0x00303] = { yoffset = -0.05, all = true }, -- widetilde - -- [0x00304] = { yoffset = -0.02, all = true }, -- widebar - -- [0x00306] = { yoffset = -0.05, all = true }, -- widebreve - -- [0x00307] = { yoffset = -0.027, all = true }, -- widedot - -- [0x00308] = { yoffset = -0.027, all = true }, -- wideddot - -- [0x020DB] = { yoffset = -0.065, all = true }, -- widedddot - -- [0x0030C] = { yoffset = -0.05, all = true }, -- widecheck - -- [0x0030A] = { yoffset = -0.025, all = true }, -- widering - - -- [0x0212C] = { width = 0.95, italic = 0.05 }, -- script B - -- [0x1D49E] = { width = 0.8, italic = 0.25 }, -- script C - -- [0x1D49F] = { width = 0.9, italic = 0.11 }, -- script D - -- [0x02130] = { width = 0.85, italic = 0.18 }, -- script E - -- [0x02131] = { width = 0.75, italic = 0.3 }, -- script F - -- [0x1D4A2] = { width = 0.9, italic = 0.11 }, -- script G - -- [0x0210B] = { width = 0.85, italic = 0.18 }, -- script H - -- [0x02110] = { width = 0.8, italic = 0.25 }, -- script I - -- [0x1D4A5] = { width = 0.8, italic = 0.25 }, -- script J - -- [0x1D4A6] = { width = 0.9, italic = 0.11 }, -- script K - -- [0x02112] = { width = 0.95, italic = 0.05 }, -- script L - -- [0x02133] = { width = 0.9, italic = 0.11 }, -- script M - -- [0x1D4A9] = { width = 0.85, italic = 0.18 }, -- script N - -- [0x1D4AA] = { width = 0.95, italic = 0.05 }, -- script O - -- [0x1D4AB] = { width = 0.8, italic = 0.25 }, -- script P - -- [0x1D4AB] = { width = 0.95, italic = 0.05 }, -- script Q - -- [0x0211B] = { width = 0.95, italic = 0.05 }, -- script R - -- [0x1D4AE] = { width = 0.9, italic = 0.11 }, -- script S - -- [0x1D4AF] = { width = 0.75, italic = 0.33 }, -- script T - -- [0x1D4B0] = { width = 0.9, italic = 0.11 }, -- script U - -- [0x1D4B1] = { width = 0.8, italic = 0.25 }, -- script V - -- [0x1D4B2] = { width = 0.8, italic = 0.25 }, -- script W - -- [0x1D4B3] = { width = 0.9, italic = 0.11 }, -- script X - -- [0x1D4B4] = { width = 0.85, italic = 0.18 }, -- script Y - -- [0x1D4B5] = { width = 0.95, italic = 0.05 }, -- script Z - - -- Setting anchors to shift the location of accents - -- Note: Many non-italic alphabets are wiped below - -- Todo: Check the less common italic alphabets - -- [0x1D483] = { anchor = 1.15 }, -- bold italic b -- [0x1D485] = { anchor = 0.8 }, -- bold italic d [0x1D487] = { anchor = 0.9 }, -- bold italic f @@ -290,13 +191,13 @@ return { { tweak = "dimensions", list = { - -- [0x00300] = { width = 0.8 }, -- widegrave - -- [0x00301] = { width = 0.9 }, -- wideacute + -- [0x00300] = { width = 0.8 }, -- widegrave + -- [0x00301] = { width = 0.9 }, -- wideacute [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve - -- [0x0030A] = { width = 0.9, xoffset = -.0 }, -- widering - [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck + -- [0x0030A] = { width = 0.9, xoffset = -.0 }, -- widering + [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck }, }, -- Then we deal with all offsets and heights in one go. So we treat the initial accent @@ -305,19 +206,17 @@ return { tweak = "dimensions", list = { -- here we want to apply to all - -- [0x00300] = { yoffset = -0.02, height = .95, all = true }, -- widegrave : 0x0060 - -- [0x00301] = { yoffset = -0.02, height = .95, all = true }, -- wideacute : 0x00B4 - -- [0x00302] = { yoffset = -0.03, height = .95, all = true }, -- widehat : 0x02C6 - -- [0x00303] = { yoffset = -0.02, height = .95, all = true }, -- widetilde : 0x02DC - -- [0x00306] = { yoffset = -0.03, height = .95, all = true }, -- widebre : 0x02D8 - -- [0x0030A] = { yoffset = 0.00, height = .95, all = true }, -- widering : 0x02DA - -- [0x0030C] = { yoffset = -0.03, height = .95, all = true }, -- widecheck : 0x02C7 - - -- [0x00304] = { yoffset = -0.05, height = .95, all = true }, -- widebar : 0x00AF - - -- [0x00307] = { yoffset = -0.03, height = .95, all = true }, -- widedot : 0x02D9 - -- [0x00308] = { yoffset = -0.03, height = .95, all = true }, -- wideddot : 0x00A8 - [0x020DB] = { yoffset = -0.015, height = .95, all = true }, -- widedddot : 0x20DB (self) + -- [0x00300] = { yoffset = -0.02, height = .95, all = true }, -- widegrave : 0x0060 + -- [0x00301] = { yoffset = -0.02, height = .95, all = true }, -- wideacute : 0x00B4 + -- [0x00302] = { yoffset = -0.03, height = .95, all = true }, -- widehat : 0x02C6 + -- [0x00303] = { yoffset = -0.02, height = .95, all = true }, -- widetilde : 0x02DC + -- [0x00306] = { yoffset = -0.03, height = .95, all = true }, -- widebre : 0x02D8 + -- [0x0030A] = { yoffset = 0.00, height = .95, all = true }, -- widering : 0x02DA + -- [0x0030C] = { yoffset = -0.03, height = .95, all = true }, -- widecheck : 0x02C7 + -- [0x00304] = { yoffset = -0.05, height = .95, all = true }, -- widebar : 0x00AF + -- [0x00307] = { yoffset = -0.03, height = .95, all = true }, -- widedot : 0x02D9 + -- [0x00308] = { yoffset = -0.03, height = .95, all = true }, -- wideddot : 0x00A8 + [0x020DB] = { yoffset = -0.015, height = .95, all = true }, -- widedddot : 0x20DB (self) }, }, -- We now copy these to the not wide slots so that we can set these to stretch as well, @@ -333,12 +232,8 @@ return { -- to have the 2 in x^2/5 a bit over the slash tweak = "kerns", list = { - [0x2F] = { - topleft = -0.2, - -- bottomleft = 0, - -- topright = 0, - bottomright = -0.2, - }, -- solidus + [0x0002F] = { topleft = -0.2, bottomright = -0.2 }, -- solidus + -- [0x1D49C] = { bottomright = -0.05, }, -- script A [0x1D49D] = { bottomright = -0.05, }, -- script B [0x1D49E] = { bottomright = -0.25, }, -- script C @@ -365,43 +260,20 @@ return { [0x1D4B3] = { bottomright = -0.11, }, -- script X [0x1D4B4] = { bottomright = -0.18, }, -- script Y [0x1D4B5] = { bottomright = -0.05, }, -- script Z - - ["0x7D.parts.top"] = { - topright = -0.25, - }, -- right brace top - ["0x7D.parts.bottom"] = { - bottomright = -0.25, - }, -- right brace bottom - ["0x7D.variants.*"] = { - topright = -0.25, - bottomright = -0.25, - }, -- right brace variants - ["0x29.parts.top"] = { - topright = -0.3, - }, -- right parenthesis top - ["0x29.parts.bottom"] = { - bottomright = -0.3, - }, -- right parenthesis bottom - ["0x29.variants.*"] = { - topright = -0.25, - bottomright = -0.25, - }, -- right parenthesis variants - ["0x221A.parts.top"] = { - topright = 0.2, - }, -- right radical top - ["0x221A.parts.bottom"] = { - bottomright = 0.2, - }, -- right radical bottom - ["0x221A.variants.*"] = { - topright = 0.2, - bottomright = 0.2, - }, -- right radical variants - - -- angle - [0x27E9] = { topright = -0.2, bottomright = -0.2 }, - ["0x27E9.variants.*"] = { topright = -0.3, bottomright = -0.3 }, - [0x27EB] = { topright = -0.2, bottomright = -0.2 }, - ["0x27EB.variants.*"] = { topright = -0.3, bottomright = -0.3 }, + -- + ["0x7D.parts.top"] = { topright = -0.25 }, -- right brace top + ["0x7D.parts.bottom"] = { bottomright = -0.25 }, -- right brace bottom + ["0x7D.variants.*"] = { topright = -0.25, bottomright = -0.25 }, -- right brace variants + ["0x29.parts.top"] = { topright = -0.3, }, -- right parenthesis top + ["0x29.parts.bottom"] = { bottomright = -0.3 }, -- right parenthesis bottom + ["0x29.variants.*"] = { topright = -0.25, bottomright = -0.25 }, -- right parenthesis variants + ["0x221A.parts.top"] = { topright = 0.2, }, -- right radical top + ["0x221A.parts.bottom"] = { bottomright = 0.2 }, -- right radical bottom + ["0x221A.variants.*"] = { topright = 0.2, bottomright = 0.2 }, -- right radical variants + [0x27E9] = { topright = -0.2, bottomright = -0.2 }, -- angles + ["0x27E9.variants.*"] = { topright = -0.3, bottomright = -0.3 }, + [0x27EB] = { topright = -0.2, bottomright = -0.2 }, + ["0x27EB.variants.*"] = { topright = -0.3, bottomright = -0.3 }, }, }, @@ -411,141 +283,72 @@ return { -- }, -- }, { - -- For upright alphabets, we unset the anchor. - -- This means that accents are placed - -- centered over the character - tweak = "wipeanchors", - -- list = { 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58 }, -- todo: ranges - list = { - "digitsbold", - "digitsdoublestruck", - "digitsmonospace", - "digitsnormal", - "digitssansserifbold", - "digitssansserifnormal", - "lowercasebold", - "lowercaseboldfraktur", - "lowercasedoublestruck", - "lowercasefraktur", - "lowercasegreekbold", - "lowercasegreeknormal", - "lowercasegreeksansserifbold", - "lowercasemonospace", - "lowercasenormal", - "lowercasesansserifbold", - "lowercasesansserifnormal", - "uppercasebold", - "uppercaseboldfraktur", - "uppercasedoublestruck", - "uppercasefraktur", - "uppercasegreekbold", - "uppercasegreeknormal", - "uppercasegreeksansserifbold", - "uppercasemonospace", - "uppercasenormal", -- they are italic! - "uppercasesansserifbold", - "uppercasesansserifnormal", - }, - }, - { - -- For non-italic alphabets we - -- remove italic correction. - tweak = "wipeitalics", - list = { - -- "digitsbold", - -- "digitsdoublestruck", - -- "digitsmonospace", - -- "digitsnormal", - -- "digitssansserifbold", - -- "digitssansserifnormal", - -- "lowercasebold", - -- "lowercaseboldfraktur", - -- "lowercasedoublestruck", - -- "lowercasefraktur", - "lowercasemonospace", - -- "lowercasenormal", - -- "lowercasesansserifbold", - -- "lowercasesansserifnormal", - -- "lowercasegreeknormal", - "uppercasebold", - -- "uppercaseboldfraktur", - -- "uppercasedoublestruck", - -- "uppercasefraktur", - -- "uppercasegreekbold", - -- "uppercasegreeknormal", - -- "uppercasegreeksansserifbold", - "uppercasemonospace", - "uppercasesansserifbold", - "uppercasesanserifnormal", - }, - }, - { -- This one fakes margins to get larger/smaller accents -- with for example \widetilde. tweak = "margins", list = { - [0x1D487] = { left = -.2, right = -.2 }, -- bold italic f - [0x1D489] = { left = -.2, right = -.2 }, -- bold italic h - [0x1D496] = { left = -.1, right = -.1 }, -- bold italic u - [0x1D499] = { left = -.1, right = -.1 }, -- bold italic x - - [0x1D711] = { left = -.1, right = -.1 }, -- italic varphi - [0x1D713] = { left = -.1, right = -.1 }, -- italic psi - - [0x1D659] = { left = -.1, right = -.1 }, -- sans bold italic d - [0x1D65C] = { left = -.1, right = -.1 }, -- sans bold italic g - - [0x1D409] = { left = .1, right = .1 }, -- bold upright J - [0x1D412] = { left = .1, right = .1 }, -- bold upright S - - [0x1D509] = { left = .1, right = .1 }, -- fraktur F - [0x1D50C] = { left = .1, right = .1 }, -- fraktur I - [0x1D50D] = { left = .1, right = .1 }, -- fraktur J - [0x1D51D] = { left = .1, right = .1 }, -- fraktur Z - - [0x1D538] = { left = .1, right = .1 }, -- doublestruck A - [0x1D539] = { left = .1, right = .1 }, -- doublestruck B - [0x1D53C] = { left = .1, right = .1 }, -- doublestruck E - [0x1D53D] = { left = .1, right = .1 }, -- doublestruck F - [0x1D541] = { left = .1, right = .1 }, -- doublestruck J - [0x1D542] = { left = .1, right = .1 }, -- doublestruck K - [0x1D543] = { left = .1, right = .1 }, -- doublestruck L - [0x1D547] = { left = .1, right = .1 }, -- doublestruck P - [0x1D549] = { left = .1, right = .1 }, -- doublestruck R - [0x1D54A] = { left = .1, right = .1 }, -- doublestruck S - [0x1D54B] = { left = .1, right = .1 }, -- doublestruck T - [0x1D54D] = { left = .1, right = .1 }, -- doublestruck V - [0x1D550] = { left = .1, right = .1 }, -- doublestruck Y - - [0x1D506] = { left = .1, right = .1 }, -- fraktur C - - [0x00393] = { left = .1, right = .1 }, -- upfight Gamma - [0x00396] = { left = .1, right = .1 }, -- upfight Zeta - - [0x1D5D8] = { left = .1, right = .1 }, -- sans bold E - [0x1D5D9] = { left = .1, right = .1 }, -- sans bold F - -- [0x1D5DD] = { left = .2, right = .2 }, -- sans bold J -- nope - [0x1D5DF] = { left = .1, right = .1 }, -- sans bold L - [0x1D5E6] = { left = .1, right = .1 }, -- sans bold S - - [0x1D61A] = { left = .1, right = .1 }, -- sans italic S - - [0x1D5A2] = { left = .1, right = .1 }, -- sans C - [0x1D5A4] = { left = .1, right = .1 }, -- sans E - [0x1D5A5] = { left = .1, right = .1 }, -- sans F - -- [0x1D5AB] = { left = .1, right = .1 }, -- sans L -- nope - [0x1D5AF] = { left = .1, right = .1 }, -- sans P - [0x1D5B2] = { left = .1, right = .1 }, -- sans S - [0x1D5B9] = { left = .1, right = .1 }, -- sans Z - - [0x1D4A0] = { left = .1, right = .1 }, -- script E - [0x1D4AE] = { left = .1, right = .1 }, -- script S - [0x1D4B4] = { left = .1, right = .1 }, -- script Y - - -- [0x4A] = { left = .2, right = .2 }, -- J - [0x4C] = { left = .1, right = .1 }, -- L - [0x53] = { left = .1, right = .1 }, -- S - [0x5A] = { left = .1, right = .1 }, -- Z + [0x1D487] = { left = -.2, right = -.2 }, -- bold italic f + [0x1D489] = { left = -.2, right = -.2 }, -- bold italic h + [0x1D496] = { left = -.1, right = -.1 }, -- bold italic u + [0x1D499] = { left = -.1, right = -.1 }, -- bold italic x + + [0x1D711] = { left = -.1, right = -.1 }, -- italic varphi + [0x1D713] = { left = -.1, right = -.1 }, -- italic psi + + [0x1D659] = { left = -.1, right = -.1 }, -- sans bold italic d + [0x1D65C] = { left = -.1, right = -.1 }, -- sans bold italic g + + [0x1D409] = { left = .1, right = .1 }, -- bold upright J + [0x1D412] = { left = .1, right = .1 }, -- bold upright S + + [0x1D509] = { left = .1, right = .1 }, -- fraktur F + [0x1D50C] = { left = .1, right = .1 }, -- fraktur I + [0x1D50D] = { left = .1, right = .1 }, -- fraktur J + [0x1D51D] = { left = .1, right = .1 }, -- fraktur Z + + [0x1D538] = { left = .1, right = .1 }, -- doublestruck A + [0x1D539] = { left = .1, right = .1 }, -- doublestruck B + [0x1D53C] = { left = .1, right = .1 }, -- doublestruck E + [0x1D53D] = { left = .1, right = .1 }, -- doublestruck F + [0x1D541] = { left = .1, right = .1 }, -- doublestruck J + [0x1D542] = { left = .1, right = .1 }, -- doublestruck K + [0x1D543] = { left = .1, right = .1 }, -- doublestruck L + [0x1D547] = { left = .1, right = .1 }, -- doublestruck P + [0x1D549] = { left = .1, right = .1 }, -- doublestruck R + [0x1D54A] = { left = .1, right = .1 }, -- doublestruck S + [0x1D54B] = { left = .1, right = .1 }, -- doublestruck T + [0x1D54D] = { left = .1, right = .1 }, -- doublestruck V + [0x1D550] = { left = .1, right = .1 }, -- doublestruck Y + + [0x1D506] = { left = .1, right = .1 }, -- fraktur C + + [0x00393] = { left = .1, right = .1 }, -- upfight Gamma + [0x00396] = { left = .1, right = .1 }, -- upfight Zeta + + [0x1D5D8] = { left = .1, right = .1 }, -- sans bold E + [0x1D5D9] = { left = .1, right = .1 }, -- sans bold F + -- [0x1D5DD] = { left = .2, right = .2 }, -- sans bold J -- nope + [0x1D5DF] = { left = .1, right = .1 }, -- sans bold L + [0x1D5E6] = { left = .1, right = .1 }, -- sans bold S + + [0x1D61A] = { left = .1, right = .1 }, -- sans italic S + + [0x1D5A2] = { left = .1, right = .1 }, -- sans C + [0x1D5A4] = { left = .1, right = .1 }, -- sans E + [0x1D5A5] = { left = .1, right = .1 }, -- sans F + -- [0x1D5AB] = { left = .1, right = .1 }, -- sans L -- nope + [0x1D5AF] = { left = .1, right = .1 }, -- sans P + [0x1D5B2] = { left = .1, right = .1 }, -- sans S + [0x1D5B9] = { left = .1, right = .1 }, -- sans Z + + [0x1D4A0] = { left = .1, right = .1 }, -- script E + [0x1D4AE] = { left = .1, right = .1 }, -- script S + [0x1D4B4] = { left = .1, right = .1 }, -- script Y + + -- [0x0004A] = { left = .2, right = .2 }, -- J + [0x0004C] = { left = .1, right = .1 }, -- L + [0x00053] = { left = .1, right = .1 }, -- S + [0x0005A] = { left = .1, right = .1 }, -- Z [0x1D43D] = { left = -.1, right = -.1 }, -- italic J [0x1D409] = { left = -.1, right = -.1 }, -- bold J @@ -598,16 +401,17 @@ return { -- 0x7C, -- }, -- }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { 1, 3, 5, 7 -- In fact, 6 is the last one. }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, filenames = { ["latinmodern-math-regular.otf"] = { @@ -805,3 +609,93 @@ return { }, } } + +-- For now we keep these commented as they show where we came from. + +-- [0x00060] = { yoffset = -0.05 }, -- grave +-- [0x000B4] = { yoffset = -0.05 }, -- acute +-- [0x002C6] = { yoffset = -0.05 }, -- hat +-- [0x002DC] = { yoffset = -0.05 }, -- tilde +-- [0x000AF] = { yoffset = -0.075 }, -- bar +-- [0x002D8] = { yoffset = -0.05 }, -- breve +-- [0x002D9] = { yoffset = -0.05 }, -- dot +-- [0x000A8] = { yoffset = -0.05 }, -- ddot +-- [0x020DB] = { yoffset = 0.2 }, -- dddot (done below!) +-- [0x002DA] = { width = 0 }, -- ring (bounding box is wrong) +-- [0x002C7] = { yoffset = -0.05 }, -- check +-- [0x020D7] = { yoffset = -0.05 }, -- vec + +-- [0x00300] = { yoffset = -0.03, all = true }, -- widegrave +-- [0x00301] = { yoffset = -0.03, all = true }, -- wideacute +-- [0x00302] = { yoffset = -0.075, all = true }, -- widehat +-- [0x00303] = { yoffset = -0.05, all = true }, -- widetilde +-- [0x00304] = { yoffset = -0.02, all = true }, -- widebar +-- [0x00306] = { yoffset = -0.05, all = true }, -- widebreve +-- [0x00307] = { yoffset = -0.027, all = true }, -- widedot +-- [0x00308] = { yoffset = -0.027, all = true }, -- wideddot +-- [0x020DB] = { yoffset = -0.065, all = true }, -- widedddot +-- [0x0030C] = { yoffset = -0.05, all = true }, -- widecheck +-- [0x0030A] = { yoffset = -0.025, all = true }, -- widering + +-- [0x0212C] = { width = 0.95, italic = 0.05 }, -- script B +-- [0x1D49E] = { width = 0.8, italic = 0.25 }, -- script C +-- [0x1D49F] = { width = 0.9, italic = 0.11 }, -- script D +-- [0x02130] = { width = 0.85, italic = 0.18 }, -- script E +-- [0x02131] = { width = 0.75, italic = 0.3 }, -- script F +-- [0x1D4A2] = { width = 0.9, italic = 0.11 }, -- script G +-- [0x0210B] = { width = 0.85, italic = 0.18 }, -- script H +-- [0x02110] = { width = 0.8, italic = 0.25 }, -- script I +-- [0x1D4A5] = { width = 0.8, italic = 0.25 }, -- script J +-- [0x1D4A6] = { width = 0.9, italic = 0.11 }, -- script K +-- [0x02112] = { width = 0.95, italic = 0.05 }, -- script L +-- [0x02133] = { width = 0.9, italic = 0.11 }, -- script M +-- [0x1D4A9] = { width = 0.85, italic = 0.18 }, -- script N +-- [0x1D4AA] = { width = 0.95, italic = 0.05 }, -- script O +-- [0x1D4AB] = { width = 0.8, italic = 0.25 }, -- script P +-- [0x1D4AB] = { width = 0.95, italic = 0.05 }, -- script Q +-- [0x0211B] = { width = 0.95, italic = 0.05 }, -- script R +-- [0x1D4AE] = { width = 0.9, italic = 0.11 }, -- script S +-- [0x1D4AF] = { width = 0.75, italic = 0.33 }, -- script T +-- [0x1D4B0] = { width = 0.9, italic = 0.11 }, -- script U +-- [0x1D4B1] = { width = 0.8, italic = 0.25 }, -- script V +-- [0x1D4B2] = { width = 0.8, italic = 0.25 }, -- script W +-- [0x1D4B3] = { width = 0.9, italic = 0.11 }, -- script X +-- [0x1D4B4] = { width = 0.85, italic = 0.18 }, -- script Y +-- [0x1D4B5] = { width = 0.95, italic = 0.05 }, -- script Z + +-- Setting anchors to shift the location of accents +-- Note: Many non-italic alphabets are wiped below +-- Todo: Check the less common italic alphabets + +-- { +-- -- For non-italic alphabets we +-- -- remove italic correction. +-- tweak = "wipeitalics", +-- list = { +-- -- "digitsbold", +-- -- "digitsdoublestruck", +-- -- "digitsmonospace", +-- -- "digitsnormal", +-- -- "digitssansserifbold", +-- -- "digitssansserifnormal", +-- -- "lowercasebold", +-- -- "lowercaseboldfraktur", +-- -- "lowercasedoublestruck", +-- -- "lowercasefraktur", +-- "lowercasemonospace", +-- -- "lowercasenormal", +-- -- "lowercasesansserifbold", +-- -- "lowercasesansserifnormal", +-- -- "lowercasegreeknormal", +-- "uppercasebold", +-- -- "uppercaseboldfraktur", +-- -- "uppercasedoublestruck", +-- -- "uppercasefraktur", +-- -- "uppercasegreekbold", +-- -- "uppercasegreeknormal", +-- -- "uppercasegreeksansserifbold", +-- "uppercasemonospace", +-- "uppercasesansserifbold", +-- "uppercasesanserifnormal", +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/lucida-opentype-math.lfg b/tex/context/fonts/mkiv/lucida-opentype-math.lfg index 97cf97ab1..6a5f5ab36 100644 --- a/tex/context/fonts/mkiv/lucida-opentype-math.lfg +++ b/tex/context/fonts/mkiv/lucida-opentype-math.lfg @@ -1,37 +1,10 @@ local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - -- local kern_250 = { bottomright = { { kern = -250 } }, force = true } - - -- kerns = { - -- [0x1D449] = kern_250, -- - -- [0x1D44A] = kern_250, -- 𝑊 - -- } - - dimensions = { - default = { -- experimental values - -- [0x02044] = { xoffset = 275, width = 600 }, - -- primes - [0xFE932] = { width = 200 }, - [0xFE933] = { width = 500 }, - [0xFE934] = { width = 800 }, - [0xFE935] = { width = 1100 }, - -- reverse primes - [0xFE935] = { width = 200 }, - [0xFE936] = { width = 500 }, - [0xFE937] = { width = 800 }, - }, - } - -end - --- When set this will bypass the italic correction hackery! local integral_variants = { bottomright = -0.20 } --- local integral_top = { topright = 0.05 } +----- integral_top = { topright = 0.05 } local integral_bottom = { bottomright = -0.45 } - return { name = "lucida-opentype-math", version = "1.00", @@ -57,7 +30,7 @@ return { -- DisplayOperatorMinHeight = 1800, -- 1300 in font (only one) PrimeRaisePercent = 60, -- 50 default PrimeRaiseComposedPercent = 50, -- 25 default --- AxisHeight = 325, + -- AxisHeight = 325, -- we keep the old fonts as they are (also for demos) }, tweaks = { aftercopying = { @@ -69,16 +42,24 @@ return { tweak = "fixoldschool", version = "Version 1.802", }, --- { --- tweak = "showinfo", --- version = "Version 1.803", --- }, + -- { + -- tweak = "showinfo", + -- version = "Version 1.803", + -- }, { tweak = "addmirrors", }, - presets.mathxitsarabic { - rscale = 1.05 - }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 1 }, + presets.rsfsuprighttoscript { rscale = 1 }, + presets.moderntocalligraphic { rscale = 1 }, + presets.eulertocalligraphic { rscale = 1 }, + presets.xitsarabic { rscale = 1.05 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "replacealphabets", list = { @@ -87,6 +68,17 @@ return { target = "uppercasecalligraphic", feature = "ss04", }, + { + source = "lowercasescript", + target = "lowercasecalligraphic", + feature = "ss04", + }, + { + source = "uppercaseboldscript", + target = "uppercaseboldcalligraphic", + feature = "ss04", + }, + -- No lowercase bold calligraphic/script in font }, }, { @@ -101,8 +93,9 @@ return { }, }, { - tweak = "dimensions", - list = { + tweak = "dimensions", + version = "Version 1.802", + list = { -- these we fix here. Remove when we have new version of Lucida ["0x23DC.parts.1"] = { xoffset = -0.075, height = .4, yoffset = -0.6 }, ["0x23DC.parts.2"] = { height = .4, yoffset = -0.6 }, @@ -134,34 +127,34 @@ return { }, -- First we set the dimensions of the initial accent which started out as zero but we want -- a proper width. - { - tweak = "dimensions", - list = { - -- [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat - -- [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde - -- [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve - -- [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck - }, - }, +-- { +-- tweak = "dimensions", +-- list = { +-- -- [0x00302] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widehat +-- -- [0x00303] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widetilde +-- -- [0x00306] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widebreve +-- -- [0x0030C] = { width = 1.4, anchor = 1.20, xoffset = .10 }, -- widecheck +-- }, +-- }, -- Then we deal with all offsets and heights in one go. So we treat the initial accent -- as well as the variants here. - { - tweak = "dimensions", - list = { - -- here we want to apply to all - -- [0x00300] = { yoffset = -0.02, height = .95, all = true }, -- widegrave : 0x0060 - -- [0x00301] = { yoffset = -0.02, height = .95, all = true }, -- wideacute : 0x00B4 - -- [0x00302] = { yoffset = -0.03, height = .95, all = true }, -- widehat : 0x02C6 - -- [0x00303] = { yoffset = -0.02, height = .95, all = true }, -- widetilde : 0x02DC - -- [0x00306] = { yoffset = -0.03, height = .95, all = true }, -- widebre : 0x02D8 - -- [0x0030A] = { yoffset = 0.00, height = .95, all = true }, -- widering : 0x02DA - -- [0x0030C] = { yoffset = -0.03, height = .95, all = true }, -- widecheck : 0x02C7 - -- [0x00304] = { yoffset = -0.05, height = .95, all = true }, -- widebar : 0x00AF - -- [0x00307] = { yoffset = -0.03, height = .95, all = true }, -- widedot : 0x02D9 - -- [0x00308] = { yoffset = -0.03, height = .95, all = true }, -- wideddot : 0x00A8 - -- [0x020DB] = { yoffset = -0.015, height = .95, all = true }, -- widedddot : 0x20DB (self) - }, - }, +-- { +-- tweak = "dimensions", +-- list = { +-- -- here we want to apply to all +-- -- [0x00300] = { yoffset = -0.02, height = .95, all = true }, -- widegrave : 0x0060 +-- -- [0x00301] = { yoffset = -0.02, height = .95, all = true }, -- wideacute : 0x00B4 +-- -- [0x00302] = { yoffset = -0.03, height = .95, all = true }, -- widehat : 0x02C6 +-- -- [0x00303] = { yoffset = -0.02, height = .95, all = true }, -- widetilde : 0x02DC +-- -- [0x00306] = { yoffset = -0.03, height = .95, all = true }, -- widebre : 0x02D8 +-- -- [0x0030A] = { yoffset = 0.00, height = .95, all = true }, -- widering : 0x02DA +-- -- [0x0030C] = { yoffset = -0.03, height = .95, all = true }, -- widecheck : 0x02C7 +-- -- [0x00304] = { yoffset = -0.05, height = .95, all = true }, -- widebar : 0x00AF +-- -- [0x00307] = { yoffset = -0.03, height = .95, all = true }, -- widedot : 0x02D9 +-- -- [0x00308] = { yoffset = -0.03, height = .95, all = true }, -- wideddot : 0x00A8 +-- -- [0x020DB] = { yoffset = -0.015, height = .95, all = true }, -- widedddot : 0x20DB (self) +-- }, +-- }, -- We now copy these to the not wide slots so that we can set these to stretch as well, -- if only because it is less confusing and more consistent. { @@ -252,6 +245,12 @@ return { -- [0x21CC] = false, } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, alternates = { @@ -260,6 +259,8 @@ return { operator = { feature = 'ss03', value = 1, comment = "Mathematical Alternative Smaller Operators" }, calligraphic = { feature = 'ss04', value = 1, comment = "Mathematical Alternative Calligraphic Characters" }, zero = { feature = 'ss05', value = 1, comment = "Mathematical Alternative Zero" }, + multipledots = { feature = 'ss06', value = 1, comment = "Mathematical Alternative Multiple Dots" }, + ldots = { feature = 'ss07', value = 1, comment = "Mathematical Alternative Ellipsis" }, }, bigslots = { 1, 2, 3, 4 diff --git a/tex/context/fonts/mkiv/minion-math.lfg b/tex/context/fonts/mkiv/minion-math.lfg index 5216e1289..a768c0518 100644 --- a/tex/context/fonts/mkiv/minion-math.lfg +++ b/tex/context/fonts/mkiv/minion-math.lfg @@ -2,18 +2,6 @@ -- ConTeXt (math) develoipment have official copies of all the text minion and math -- fonts without restrictions of usage in documents. -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_W = { bottomright = { { kern = -150 } } } - local kern_V = { bottomright = { { kern = -200 } } } - - kerns = { - [0x1D449] = kern_V, -- 𝑉 - [0x1D44A] = kern_W, -- 𝑊 - } - -end - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -67,24 +55,19 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.95 }, - presets.mathrsfscript { rscale = 0.95 }, - presets.mathxitsarabic { rscale = 0.88 }, + presets.rsfstoscript { rscale = 0.97 }, + presets.rsfsuprighttoscript { rscale = 0.97 }, + presets.moderntocalligraphic { rscale = 0.97 }, + presets.eulertocalligraphic { rscale = 0.97 }, + presets.xitsarabic { rscale = 0.88 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.3 }, + presets.wipeitalics { }, { tweak = "simplifykerns", }, - presets.moveitalics { - correct = true - }, - { -- Check! - tweak = "replacealphabets", - list = { - { - source = "uppercasecalligraphic", - target = "uppercasescript", - }, - }, - }, { tweak = "extendaccents", }, @@ -115,12 +98,13 @@ return { tweak = "addfourier", variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, } diff --git a/tex/context/fonts/mkiv/pagella-math.lfg b/tex/context/fonts/mkiv/pagella-math.lfg index 59eafeaaf..032450426 100644 --- a/tex/context/fonts/mkiv/pagella-math.lfg +++ b/tex/context/fonts/mkiv/pagella-math.lfg @@ -1,34 +1,3 @@ -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_V = { bottomright = { { kern = -200 } } } - local kern_W = { bottomright = { { kern = -100 } } } - - dimensions = { - default = { - -- [0x1D453] = { xoffset = 162, width = 278 + 162 },-- 𝑓 - -- [0x1D453] = offset_f, -- 𝑓 - -- ["1:0x1D453"] = offset_f, -- needed for compact - -- ["2:0x1D453"] = offset_f, -- needed for compact - -- ["*:0x1D453"] = offset_f, -- 𝑓 - }, - } - - kerns = { - -- [0x1D449] = kern_V, -- 𝑉 - -- ["1:0x1D449"] = kern_V, -- needed for compact - -- ["2:0x1D449"] = kern_V, -- needed for compact - -- [0x1D44A] = kern_W, -- 𝑊 - -- ["1:0x1D44A"] = kern_W, -- needed for compact - -- ["2:0x1D44A"] = kern_W, -- needed for compact - -- ["*:0x1D453"] = kern_f, - ["*:0x1D449"] = kern_V, -- 𝑉 - ["*:0x1D44A"] = kern_W, -- 𝑊 - } - -end - --- When set this will bypass the italic correction hackery! - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets @@ -78,33 +47,42 @@ return { -- fake = 0.65, }, { + tweak = "replacealphabets", + feature = "euleroverpagella", + filename = "euler.otf", + list = { + -- { source = { first = 0x02100, last = 0x0210D } }, -- no 0x2210E + -- { source = { first = 0x0210F, last = 0x02BFF } }, + { source = { first = 0x02100, last = 0x02BFF } }, + { source = { first = 0x1D400, last = 0x1D7FF } }, + { source = { first = 0x1D538, last = 0x1D550 } }, + }, + }, + { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.97 }, - presets.mathrsfscript { rscale = 0.97 }, - presets.mathxitsarabic { rscale = 0.95 }, { - -- When it makes sense we get rid of italics. - tweak = "moveitalics", - correct = true, + tweak = "fixoldschool", + feature = "euleroverpagella", + }, + + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 0.95 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, -- we need to check the 1.5 + presets.wipeanchors { }, + presets.wipeitalics { }, + { + tweak = "parameters", + feature = "euleroverpagella", list = { - "lowercasenormal", - "lowercaseitalic", - "lowercasebold", - "lowercasebolditalic", - "lowercasegreeknormal", - "lowercasegreekitalic", - "lowercasegreekbold", - "lowercasegreekbolditalic", - "uppercasenormal", - "uppercaseitalic", - "uppercasebold", - "uppercasebolditalic", - "uppercasegreeknormal", - "uppercasegreekitalic", - "uppercasegreekbold", - "uppercasegreekbolditalic", - mathematics.tweaks.subsets.dotless, + RadicalRuleThickness = 54, } }, { @@ -249,6 +227,20 @@ return { }, }, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, + { + tweak = "parameters", + feature = "emulatelmtx", + comment = "this is for mkiv", + list = { + AccentBaseHeight = 400, + } + }, }, }, bigslots = { @@ -257,45 +249,36 @@ return { alternates = { dotless = { feature = 'dtls', value = 1, comment = "Mathematical Dotless Forms" }, }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, } +-- For now we keep these commented as they show where we came from. - - - --- Old values - - -- { - -- tweak = "dimensions", - -- list = { -- offset width italic - -- [0x020D7] = { yoffset = -0.05 }, -- vec - -- [0x1D44E] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- a - -- [0x1D44F] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- b - -- [0x1D450] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- c - -- [0x1D451] = { xoffset = 0, width = 1, italic = 0, anchor = 0.7 }, -- d - -- [0x1D452] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- e - -- [0x1D453] = { xoffset = 0.50, width = 1.70, italic = 0.6, anchor = 1.2 }, -- f - -- [0x1D454] = { xoffset = 0.10, width = 1.15, italic = 0.2 }, -- g - -- [0x0210E] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- h - -- [0x1D458] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- k - -- [0x1D459] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- l - -- [0x1D45E] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- q - -- [0x1D463] = { xoffset = 0, width = 1, italic = 0, anchor = 1.25 }, -- v - -- [0x1D464] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- w - -- [0x1D6FE] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \gamma - -- [0x1D706] = { xoffset = 0, width = 1, italic = 0, anchor = 1.05 }, -- \lambda - -- [0x1D70A] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \omicron - -- [0x1D70D] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \varsigma - -- [0x1D70E] = { xoffset = 0, width = 1, italic = 0, anchor = 1.1 }, -- \sigma - -- [0x1D70F] = { xoffset = -.10, width = 1, italic = 0, anchor = 0.95 }, -- \tau - -- [0x1D712] = { xoffset = 0.1, width = 1.2, italic = 0.1 }, -- \chi - -- [0x1D713] = { xoffset = -0.05, width = 0.95, italic = 0.1 }, -- \psi - -- [0x1D71D] = { xoffset = 0, width = 1, italic = 0, anchor = 0.7 }, -- \varpi - -- }, - -- }, +-- { +-- tweak = "dimensions", +-- list = { -- offset width italic +-- [0x020D7] = { yoffset = -0.05 }, -- vec +-- [0x1D44E] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- a +-- [0x1D44F] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- b +-- [0x1D450] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- c +-- [0x1D451] = { xoffset = 0, width = 1, italic = 0, anchor = 0.7 }, -- d +-- [0x1D452] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- e +-- [0x1D453] = { xoffset = 0.50, width = 1.70, italic = 0.6, anchor = 1.2 }, -- f +-- [0x1D454] = { xoffset = 0.10, width = 1.15, italic = 0.2 }, -- g +-- [0x0210E] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- h +-- [0x1D458] = { xoffset = 0, width = 1, italic = 0, anchor = 1.3 }, -- k +-- [0x1D459] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- l +-- [0x1D45E] = { xoffset = 0, width = 1, italic = 0, anchor = 0.9 }, -- q +-- [0x1D463] = { xoffset = 0, width = 1, italic = 0, anchor = 1.25 }, -- v +-- [0x1D464] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- w +-- [0x1D6FE] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \gamma +-- [0x1D706] = { xoffset = 0, width = 1, italic = 0, anchor = 1.05 }, -- \lambda +-- [0x1D70A] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \omicron +-- [0x1D70D] = { xoffset = 0, width = 1, italic = 0, anchor = 1.2 }, -- \varsigma +-- [0x1D70E] = { xoffset = 0, width = 1, italic = 0, anchor = 1.1 }, -- \sigma +-- [0x1D70F] = { xoffset = -.10, width = 1, italic = 0, anchor = 0.95 }, -- \tau +-- [0x1D712] = { xoffset = 0.1, width = 1.2, italic = 0.1 }, -- \chi +-- [0x1D713] = { xoffset = -0.05, width = 0.95, italic = 0.1 }, -- \psi +-- [0x1D71D] = { xoffset = 0, width = 1, italic = 0, anchor = 0.7 }, -- \varpi +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/schola-math.lfg b/tex/context/fonts/mkiv/schola-math.lfg index 54d24ffa3..9a7b3dca6 100644 --- a/tex/context/fonts/mkiv/schola-math.lfg +++ b/tex/context/fonts/mkiv/schola-math.lfg @@ -1,21 +1,9 @@ -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - local kern_V = { bottomright = { { kern = -200 } }, topright = { { kern = 50 } } } - local kern_W = { bottomright = { { kern = -100 } }, topright = { { kern = 50 } } } - - kerns = { - [0x1D449] = kern_V, -- 𝑉 - [0x1D44A] = kern_W, -- 𝑊 - } - -end +local common = fonts.goodies.load("common-math.lfg") +local presets = common.mathematics.tweaks.presets local integral_variants = { bottomright = -0.20 } local integral_bottom = { bottomright = -0.20 } -local common = fonts.goodies.load("common-math.lfg") -local presets = common.mathematics.tweaks.presets - return { name = "schola-math", version = "1.00", @@ -55,10 +43,17 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 1 }, - presets.mathrsfscript { rscale = 1 }, - presets.mathxitsarabic { rscale = 0.93 }, - presets.moveitalics { correct = true }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 0.93 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { }, + presets.wipeitalics { }, { tweak = "kerns", list = { @@ -161,6 +156,12 @@ return { -- scale = 1.25, variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { @@ -169,10 +170,5 @@ return { alternates = { dotless = { feature = 'dtls', value = 1, comment = "Mathematical Dotless Forms" }, }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, } diff --git a/tex/context/fonts/mkiv/stix-two-math.lfg b/tex/context/fonts/mkiv/stix-two-math.lfg index 8b03a7730..1f370359f 100644 --- a/tex/context/fonts/mkiv/stix-two-math.lfg +++ b/tex/context/fonts/mkiv/stix-two-math.lfg @@ -1,11 +1,10 @@ --- When set this will bypass the italic correction hackery! -local integral_variants = { bottomright = -0.4 } --- local integral_top = { topright = 0.05 } -local integral_bottom = { bottomright = -0.35 } - local common = fonts.goodies.load("common-math.lfg") local presets = common.mathematics.tweaks.presets +local integral_variants = { bottomright = -0.4 } +----- integral_top = { topright = 0.05 } +local integral_bottom = { bottomright = -0.35 } + return { name = "stix-two-math", version = "1.00", @@ -61,12 +60,35 @@ return { { tweak = "addmirrors", }, - presets.mathxitsarabic { rscale = 0.95 }, + -- MS: we need to check this, I moved it up { - tweak = "simplifykerns", + tweak = "replacealphabets", + list = { + { + source = "uppercasescript", + target = "uppercasecalligraphic", + }, + { + source = "uppercasescript", + target = "uppercasescript", + feature = "ss01", + }, + }, }, - presets.moveitalics { - correct = true + -- + presets.scripttocalligraphic { }, + presets.rsfstoscript { }, + presets.rsfsuprighttoscript { }, + presets.moderntocalligraphic { }, + presets.eulertocalligraphic { }, + presets.xitsarabic { rscale = 0.95 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { }, + presets.wipeitalics { }, + { + tweak = "simplifykerns", }, { tweak = "kerns", @@ -97,20 +119,6 @@ return { ["0x2233.variants.*"] = integral_variants, ["0x2233.parts.top"] = integral_top, ["0x2233.parts.bottom"] = integral_bottom, }, }, - { - tweak = "replacealphabets", - list = { - { - source = "uppercasescript", - target = "uppercasecalligraphic", - }, - { - source = "uppercasescript", - target = "uppercasescript", - feature = "ss01", - }, - }, - }, -- Accents are a mess. We migrate the extensibles from the combiners to the base accent -- and then need to tweak the width (which is auto set because it was zero with a large -- accent anchor offset). First we copy and fix. @@ -197,6 +205,12 @@ return { } } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { diff --git a/tex/context/fonts/mkiv/termes-math.lfg b/tex/context/fonts/mkiv/termes-math.lfg index 6a54535df..6e3eb9306 100644 --- a/tex/context/fonts/mkiv/termes-math.lfg +++ b/tex/context/fonts/mkiv/termes-math.lfg @@ -1,28 +1,9 @@ -local dimensions, kerns if CONTEXTLMTXMODE == 0 then - - -- local kern_V = { bottomright = { { kern = -200 } } } - -- local kern_W = { bottomright = { { kern = -100 } } } - -- local offset_f = { xoffset = "llx" } - -- - -- dimensions = { - -- default = { - -- [0x1D453] = offset_f, -- 𝑓 - -- }, - -- } - -- - -- kerns = { - -- [0x1D449] = kern_V, -- 𝑉 - -- [0x1D44A] = kern_W, -- 𝑊 - -- } - -end +local common = fonts.goodies.load("common-math.lfg") +local presets = common.mathematics.tweaks.presets local integral_variants = { bottomright = -0.20 } local integral_bottom = { bottomright = -0.30 } -local common = fonts.goodies.load("common-math.lfg") -local presets = common.mathematics.tweaks.presets - return { name = "termes-math", version = "1.00", @@ -61,10 +42,17 @@ return { { tweak = "addmirrors", }, - presets.matheulercalligraphic { rscale = 0.95 }, - presets.mathrsfscript { rscale = 0.95 }, - presets.mathxitsarabic { rscale = 0.88 }, - presets.moveitalics { correct = true }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.97 }, + presets.rsfsuprighttoscript { rscale = 0.97 }, + presets.moderntocalligraphic { rscale = 0.97 }, + presets.eulertocalligraphic { rscale = 0.97 }, + presets.xitsarabic { rscale = 0.88 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.5 }, + presets.wipeitalics { }, { tweak = "kerns", list = { @@ -165,6 +153,12 @@ return { tweak = "addfourier", variant = 1, }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, bigslots = { @@ -173,32 +167,29 @@ return { alternates = { dotless = { feature = 'dtls', value = 1, comment = "Mathematical Dotless Forms" }, }, - -- - -- experimental fixes for mkiv: - -- - dimensions = dimensions, - kerns = kerns, }, } +-- For now we keep these commented as they show where we came from. - -- Do a testrun with hats on these: - -- { - -- tweak = "dimensions", - -- list = { - -- [0x1D44F] = { width = 1, italic = 0, anchor = 1.3 }, -- b - -- [0x1D451] = { width = 1, italic = 0, anchor = 0.8 }, -- d - -- [0x1D452] = { width = 1, italic = 0, anchor = 0.9 }, -- e - -- [0x0210E] = { width = 1, italic = 0, anchor = 1.3 }, -- h - -- [0x1D458] = { width = 1, italic = 0, anchor = 1.3 }, -- k - -- [0x1D453] = { xoffset = 0.6, width = 1.4, italic = 1.2, anchor = 1.5 }, -- f - -- [0x1D457] = { xoffset = 0.5, width = 1.3, italic = 1.7 }, -- j - -- [0x1D45D] = { xoffset = 0.15, width = 1.15, italic = 0, anchor = 1.4 }, -- p - -- [0x1D45E] = { width = 1, italic = 0, anchor = 0.9 }, -- q - -- [0x1D464] = { width = 1, italic = 0, anchor = 1.1 }, -- w - -- [0x1D6FE] = { width = 1, italic = 0, anchor = 1.1 }, -- \gamma - -- [0x1D706] = { width = 1, italic = 0, anchor = 1.05 }, -- \lambda - -- [0x1D70A] = { width = 1, italic = 0, anchor = 1.2 }, -- \omicron - -- [0x1D70F] = { width = 1, italic = 0, anchor = 1.05 }, -- \tau - -- }, - -- }, +-- Do a testrun with hats on these: +-- +-- { +-- tweak = "dimensions", +-- list = { +-- [0x1D44F] = { width = 1, italic = 0, anchor = 1.3 }, -- b +-- [0x1D451] = { width = 1, italic = 0, anchor = 0.8 }, -- d +-- [0x1D452] = { width = 1, italic = 0, anchor = 0.9 }, -- e +-- [0x0210E] = { width = 1, italic = 0, anchor = 1.3 }, -- h +-- [0x1D458] = { width = 1, italic = 0, anchor = 1.3 }, -- k +-- [0x1D453] = { xoffset = 0.6, width = 1.4, italic = 1.2, anchor = 1.5 }, -- f +-- [0x1D457] = { xoffset = 0.5, width = 1.3, italic = 1.7 }, -- j +-- [0x1D45D] = { xoffset = 0.15, width = 1.15, italic = 0, anchor = 1.4 }, -- p +-- [0x1D45E] = { width = 1, italic = 0, anchor = 0.9 }, -- q +-- [0x1D464] = { width = 1, italic = 0, anchor = 1.1 }, -- w +-- [0x1D6FE] = { width = 1, italic = 0, anchor = 1.1 }, -- \gamma +-- [0x1D706] = { width = 1, italic = 0, anchor = 1.05 }, -- \lambda +-- [0x1D70A] = { width = 1, italic = 0, anchor = 1.2 }, -- \omicron +-- [0x1D70F] = { width = 1, italic = 0, anchor = 1.05 }, -- \tau +-- }, +-- }, diff --git a/tex/context/fonts/mkiv/type-imp-minion.mkiv b/tex/context/fonts/mkiv/type-imp-minion.mkiv index b158deddf..aa953623c 100644 --- a/tex/context/fonts/mkiv/type-imp-minion.mkiv +++ b/tex/context/fonts/mkiv/type-imp-minion.mkiv @@ -11,8 +11,8 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\definefontfallback[MinionMathFallback] [file:latinmodern-math.otf][uppercasescript] -\definefontfallback[MinionBoldMathFallback][file:latinmodern-math.otf][uppercasescript] +% \definefontfallback[MinionMathFallback] [file:latinmodern-math.otf][uppercasescript] +% \definefontfallback[MinionBoldMathFallback][file:latinmodern-math.otf][uppercasescript] \starttypescriptcollection[minion] @@ -34,14 +34,14 @@ \starttypescript [\s!math][minion][\s!all] \loadfontgoodies[minion-math] - \definefontsynonym[\s!MathRoman] [Minion-Math] [\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math,\s!fallbacks=MinionMathFallback] - \definefontsynonym[\s!MathRomanBold][Minion-BoldMath][\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math,\s!fallbacks=MinionBoldMathFallback] + \definefontsynonym[\s!MathRoman] [Minion-Math] [\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math] % ,\s!fallbacks=MinionMathFallback] + \definefontsynonym[\s!MathRomanBold][Minion-BoldMath][\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math] % ,\s!fallbacks=MinionBoldMathFallback] \stoptypescript \starttypescript [\s!math][minion-medium][\s!all] \loadfontgoodies[minion-math] - \definefontsynonym[\s!MathRoman] [Minion-Math] [\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math,\s!fallbacks=MinionMathFallback] - \definefontsynonym[\s!MathRomanBold][Minion-MediumMath][\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math,\s!fallbacks=MinionBoldMathFallback] + \definefontsynonym[\s!MathRoman] [Minion-Math] [\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math] % ,\s!fallbacks=MinionMathFallback] + \definefontsynonym[\s!MathRomanBold][Minion-MediumMath][\s!features={\s!math\mathsizesuffix,mathextra},\s!designsize=\s!auto,\s!goodies=minion-math] % ,\s!fallbacks=MinionBoldMathFallback] \stoptypescript \starttypescript [minion,minion-medium] diff --git a/tex/context/fonts/mkiv/xits-math.lfg b/tex/context/fonts/mkiv/xits-math.lfg index 374f03a0e..9eb1a1200 100644 --- a/tex/context/fonts/mkiv/xits-math.lfg +++ b/tex/context/fonts/mkiv/xits-math.lfg @@ -45,6 +45,31 @@ return { expected = "Version 1.302", }, { + tweak = "replacealphabets", + list = { + { + source = "uppercasescript", + target = "uppercasecalligraphic", + }, + { + source = "uppercasescript", + target = "uppercasescript", + feature = "ss01", + }, + }, + }, + presets.scripttocalligraphic { }, + presets.rsfstoscript { rscale = 0.95 }, + presets.rsfsuprighttoscript { rscale = 0.95 }, + presets.moderntocalligraphic { rscale = 0.95 }, + presets.eulertocalligraphic { rscale = 0.95 }, + presets.xitsarabic { rscale = 0.88 }, + presets.fallbacks { }, + presets.moveitalics { correct = true }, + presets.moveitalics { correct = true, letters = true }, + presets.moveintegrals { factor = 1.4 }, + presets.wipeitalics { }, + { tweak = "kerns", list = { [0x2F] = { @@ -55,20 +80,6 @@ return { }, }, }, - -- 0xFEOO should be chancery style, if present - { - tweak = "variants", - kind = "script", - feature = "ss01",-- this changes to chancery style for xits - -- feature = false, -- use the saved ones (see typescript) - selector = 0xFE00, - }, - -- 0xFEO1 should be roundhand style, if present - { - tweak = "variants", - kind = "script", - selector = 0xFE01, - }, { tweak = "dimensions", list = { @@ -96,6 +107,12 @@ return { tweak = "setoptions", set = { "ignorekerndimensions" } }, + -- this is the mkiv section + { + tweak = "emulatelmtx", + feature = "emulatelmtx", + comment = "this is for mkiv", + }, }, }, alternates = { |