Am 16.12.2011 um 00:13 schrieb Philipp A.:

2011/12/15 Wolfgang Schuster <schuster.wolfgang@googlemail.com>
There is no way for me to fix this because it’s a context bug.  You can see the effect with the following example, when you load LM before Pagella the heading use LM Math but when you load Pagella before LM Palatino math is used for the heading.

\setupbodyfont[modern]
\setupbodyfont[pagella]

\setuphead[section][style={\ss\bfb}]

\starttext
\section{Wat? $y=x^2$} $y=x^2$
\stoptext

Wolfgang


umm, so this happens because this bug exists and simplefonts sets the fonts on module load?

Yes.

is there a way to fix it or is an official fix on the way?

Wait for Hans to fix it and use in the meantime

\usemodule[simplefonts]

\definesimplefonttypeface[mainface][Cambria]
\definesimplefonttypeface[mainface][Ubuntu] [style=sans]
\definesimplefonttypeface[mainface][cambria][style=math]

\setupbodyfont[mainface]

\setuphead[section][style={\ss\bfb}]

\starttext
\section{Wat? $y=x^2$} $y=x^2$
\stoptext

or

\definetypeface[mainface][rm][specserif][Cambria]
\definetypeface[mainface][ss][specsans] [Ubuntu]
\definetypeface[mainface][mm][math]     [cambria]

\setupbodyfont[mainface]

\setuphead[section][style={\ss\bfb}]

\starttext
\section{Wat? $y=x^2$} $y=x^2$
\stoptext

Wolfgang