diff options
author | Mojca Miklavec <mojca.miklavec@gmail.com> | 2012-05-22 21:04:25 +0000 |
---|---|---|
committer | Mojca Miklavec <mojca.miklavec@gmail.com> | 2012-05-22 21:04:25 +0000 |
commit | a115fb4ebf3890ee3cabdf98f3f945a349860752 (patch) | |
tree | e4d25217d24f4c1b6d863007725f538169379e87 /Master/texmf-dist/tex/context/base/font-mat.mkvi | |
parent | d36378879c10c7378bc52d9fe7d1ce9c3677d98b (diff) |
ConTeXt 2012.05.22 16:12
git-svn-id: svn://tug.org/texlive/trunk@26572 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/context/base/font-mat.mkvi')
-rw-r--r-- | Master/texmf-dist/tex/context/base/font-mat.mkvi | 34 |
1 files changed, 31 insertions, 3 deletions
diff --git a/Master/texmf-dist/tex/context/base/font-mat.mkvi b/Master/texmf-dist/tex/context/base/font-mat.mkvi index 7ef0f2b777a..c8ab45b7582 100644 --- a/Master/texmf-dist/tex/context/base/font-mat.mkvi +++ b/Master/texmf-dist/tex/context/base/font-mat.mkvi @@ -167,10 +167,38 @@ \font_helpers_set_math_family_bold_indeed#mbfam#familytag#mrfam% \fi} +%D It can happen that we use a bodyfont with no math in which case +%D we have a problem with setting the global bodyfont size in the +%D page builder. For instance in: +%D +%D \starttext +%D \definetypeface[test][rm][serif][pagella][default] +%D \setupbodyfont[test] +%D test +%D \stoptext +%D +%D This is why we need the check: + +% \def\font_helpers_preset_math_family_indeed#fam#familytag% +% {\expandafter\ifx\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-1\endcsname\relax +% \writestatus{fonts}{math: unset for global bodyfont \fontclass\space at \fontbody}% +% \else +% \scriptscriptfont#fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-3\endcsname +% \scriptfont #fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-2\endcsname +% \textfont #fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-1\endcsname +% \fi} +% +% Uglier but more efficient (esp in tracing): + \def\font_helpers_preset_math_family_indeed#fam#familytag% - {\scriptscriptfont#fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-3\endcsname - \scriptfont #fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-2\endcsname - \textfont #fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-1\endcsname} + {\expandafter\let\expandafter\v_font_math_one\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-1\endcsname + \ifx\v_font_math_one\relax + \writestatus{fonts}{math: unset for global bodyfont \fontclass\space at \fontbody}% + \else + \scriptscriptfont#fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-3\endcsname + \scriptfont #fam\csname\??fontinstanceclass\fontclass-\fontbody-\s!mm-#familytag-\fontsize-2\endcsname + \textfont #fam\v_font_math_one + \fi} \let\font_helpers_reset_fontclass_math_families\gobbleoneargument |