John Hunter <jdhunter@...4...> writes:

What you need to do is find out which cm* font file contains the

Omega you want, and what the glyph index of Omega is.

The simple way to do this is to write a TeX file like

\documentclass{article}

\pagestyle{empty}

\begin{document}

$\Gamma \Delta \Theta \Lambda \Xi \Pi \Sigma \Upsilon \Phi \Psi \Omega$

\end{document}

run it through LaTeX and then do dvitype -output-level=2 foo.dvi,

which reveals the font and the codes:

114: fntdef1 7: cmr10---loaded at size 655360 DVI units

135: fntnum7

136: setchar0

137: setchar1

138: setchar2

139: setchar3

140: setchar4

141: setchar5

142: setchar6

143: setchar7

144: setchar8

145: setchar9

146: setchar10

So the upper-case non-slanted Greek letters occupy the first 11

positions of cmr10. For the letters not listed, I guess you are

supposed to use the similar-looking Latin letters.

## ···

--

Jouni

Jouni K Seppanen wrote:

John Hunter <jdhunter@...4...> writes:

What you need to do is find out which cm* font file contains the

Omega you want, and what the glyph index of Omega is.

The simple way to do this is to write a TeX file like

\documentclass{article}

\pagestyle{empty}

\begin{document}

$\Gamma \Delta \Theta \Lambda \Xi \Pi \Sigma \Upsilon \Phi \Psi \Omega$

\end{document}

run it through LaTeX and then do dvitype -output-level=2 foo.dvi,

which reveals the font and the codes:

114: fntdef1 7: cmr10---loaded at size 655360 DVI units

135: fntnum7

136: setchar0

137: setchar1

138: setchar2

139: setchar3

140: setchar4

141: setchar5

142: setchar6

143: setchar7

144: setchar8

145: setchar9

146: setchar10

So the upper-case non-slanted Greek letters occupy the first 11

positions of cmr10.

Not exactly I think. Although I'm not at all familiar with font libs stuff & friends I found that the correct mappings aren't the 1st 10 positions in cmr10 (assuming that <number> in a dict entry like

r'\Sigma' : ('cmr10', <number>)

is the position). Anyway, one has to take the

characters from cmr10, not cmmi10. Attached is the _mathtext_data.py that selects the non-slanted uppercase greek letters. I removed \Upsilon since it's an ordinary "Y" (just like e.g. "X" for \Chi).

cheers,

steve

_mathtext_data.py (30.2 KB)

## ···

--

Random number generation is the art of producing pure gibberish as quickly as possible.