summaryrefslogtreecommitdiff
path: root/tests/font_patch.tex
blob: d41ff4801dda3a408245d7c2d2c2407b9b9fd2ae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
\input{luaotfload.sty}
\directlua {
  local function patch(fontdata)
    local mc = fontdata.MathConstants
    local em = fontdata.parameters.units
    local sz = fontdata.parameters.size
    if fontdata.psname == "CambriaMath" and mc then
      mc.DisplayOperatorMinHeight = 2800 / em * sz
    end
  end
  luatexbase.add_to_callback("luaotfload.patch_font", patch, "cambria.domh")
}

\font\4={name:Cambria Math:mode=base;script=math} at 10pt
\font\5={name:Cambria Math:mode=base;script=math;ssty=1} at 7pt
\font\6={name:Cambria Math:mode=node;script=math;ssty=2} at 5pt
\textfont4=\4 \scriptfont4=\5 \scriptscriptfont4=\6

$$
\Umathchar"1"4`∫
\Umathchar"1"4`∑
$$
\bye