[tex-eplain] boldface greek symbols
Gérald Tenenbaum
gerald.tenenbaum at univ-lorraine.fr
Sun Aug 27 19:57:20 CEST 2023
Thanks.
However it does not seem to work with \vartheta :
\input eplain
\font\tengp=cmmib10
\newfam\gpfam
\textfont\gpfam=\tengp
\def\gp{\fam\gpfam\textfont1=\tengp}
\def\gth{\hbox{$\gp\vartheta$}}
%$\gth\neq\vartheta$
\bigskip
\newfam\gbfam
\font\gbten=cmmib10
\font\gbeight=cmmib10 scaled 800
\font\gbseven=cmmib10 scaled 700
\textfont\gbfam=\gbten
\scriptfont\gbfam=\gbeight
\scriptscriptfont\gbfam=\gbseven
\def\gb{\fam\gbfam\gbten}
\def\grth{{\gb\vartheta}}
$\grth\neq\gth$
Laurence.Finston at gmx.net a écrit le 27/8/23 à 18:09 :
> > This is wrong. You're resetting \textfont1. You need to set
> \textfont\gpfam.
> Like I said, \gbfam and \gbifam (in this case) are numbers:
> \tracingonline=1
> \showthe\gbifam
> \showthe\gbfam
> -->
> This is TeX, Version 3.141592653 (TeX Live 2022/dev/Debian) (preloaded
> format=tex)
> (./ttemp.tex
> > 8.
> l.32 \showthe\gbifam
>
> ?
> > 9.
> l.34 \showthe\gbfam
> They are thus family 8 and 9, respectively and \textfont\gbifam and
> \textfont\gbfam are equivalent to \textfont8 and \textfont9, respectively.
> *Gesendet:* Sonntag, 27. August 2023 um 17:48 Uhr
> *Von:* Laurence.Finston at gmx.net
> *An:* "Gérald Tenenbaum" <gerald.tenenbaum at univ-lorraine.fr>
> *Cc:* "Eplain" <tex-eplain at tug.org>
> *Betreff:* Aw: Re: [tex-eplain] boldface greek symbols
> %% Normal italic:
> \newfam\gbifam
> \font\gbiten=cmmi10
> \font\gbieight=cmmi10 scaled 800
> \font\gbiseven=cmmi10 scaled 700
> \def\gbi{\fam\gbifam\gbiten}
> \textfont\gbifam=\gbiten
> \scriptfont\gbifam=\gbieight
> \scriptscriptfont\gbifam=\gbiseven
> %% Bold italic:
> \newfam\gbfam
> \font\gbten=cmmib10
> \font\gbeight=cmmib10 scaled 800
> \font\gbseven=cmmib10 scaled 700
> \textfont\gbfam=\gbten
> \scriptfont\gbfam=\gbeight
> \scriptscriptfont\gbfam=\gbseven
> \def\gb{\fam\gbfam\gbten}
> Normal Italic: $\gbi{\Delta_\Omega}$
> Bold Italic: $\gb{\Delta_\Omega}$
> \bye
> See ttemp.dvi (attached)
> *Gesendet:* Sonntag, 27. August 2023 um 17:19 Uhr
> *Von:* Laurence.Finston at gmx.net
> *An:* "Gérald Tenenbaum" <gerald.tenenbaum at univ-lorraine.fr>
> *Betreff:* Aw: Re: [tex-eplain] boldface greek symbols
> > \def\gp{\fam\gpfam\textfont1=\tengp}
> This is wrong. You're resetting \textfont1. You need to set
> \textfont\gpfam.
> If you create a new family, you shouldn't need to write macros for the
> individual characters. They should be in the proper positions in the
> font, if the font is encoded using the conventions of plain TeX.
> *Gesendet:* Sonntag, 27. August 2023 um 15:44 Uhr
> *Von:* "Gérald Tenenbaum" <gerald.tenenbaum at univ-lorraine.fr>
> *An:* Laurence.Finston at gmx.net
> *Cc:* "Eplain" <tex-eplain at tug.org>
> *Betreff:* Re: [tex-eplain] boldface greek symbols
> Thank you.
>
> Here is indeed a working example
> \input eplain
> \font\tengp=cmmib10
> \newfam\gpfam
> \textfont\gpfam=\tengp
> \def\gp{\fam\gpfam\textfont1=\tengp}
> \def\gth{\hbox{$\gp\vartheta$}}
> $\gth\neq\vartheta$
> \end
>
> However this would require distinct definitions for the same letter in
> distinct sizes.
> The behavior therefore radically departs from standard use in which
> you can do, for instance,
>
> \font\tenscaln=eusm10
> \font\sevenscaln=eusm10 scaled 700
> \newfam\scalnfam\textfont\scalnfam=\tenscaln\scriptfont\scalnfam=\sevenscaln
> \def\scaln{\fam\scalnfam\tenscaln}%
> \def\scal{\scaln}
> \def\A{{\scaln A}}
> \def\B{{\scaln B}}
> $\A_\B$
>
> Regards,
>
> Gérald
>
> Laurence.Finston at gmx.net a écrit le 27/8/23 à 15:13 :
>
> First, you define a new family using \newfam. This takes care of
> the problem that Philip brought up, because your new \boldgreek or
> \bg or whatever macro will change the family within its scope. I
> think you can have 11 families or so and plain tex only uses 7 or
> something. I don't remember the details. It would be like this:
> \newfam\boldgreekfam
> \def\boldgreek{\fam\boldgreekfam\tenboldgreek}
> \newfam just assigns a number. If you know the number, you could
> use it instead of \boldgreekfam, but it's better not to.
> Then you set \textfont, \scriptfont and \scriptscriptfont. You
> might need to use scaling if this font isn't available in the
> sizes you need.
> For example, \font\fiveboldgreek=cmboldgreek10 scaled 700.
> I haven't tested this, so you may have to fiddle with it and/or
> refer to _The TeXbook_ (never a bad idea).
> That is my attempt to answer your question. My opinion is that it
> might be difficult to distinguish bold Greek characters in
> subscripts from ordinary Greek characters and that \bf and \rm are
> meant to be the exceptions rather than the rule. However, to each
> his/her own.
> If you have any problems, I'll be happy to try to make a working
> example.
> *Gesendet:* Sonntag, 27. August 2023 um 12:44 Uhr
> *Von:* "Gérald Tenenbaum" <gerald.tenenbaum at univ-lorraine.fr>
> *An:* Laurence.Finston at gmx.net
> *Cc:* "Eplain" <tex-eplain at tug.org>
> *Betreff:* Re: Aw: Re: [tex-eplain] boldface greek symbols
> So how would it work with bold greek?
> When I tried this I get an error until I insert \hboxes
>
> Laurence.Finston at gmx.net a écrit le 27/8/23 à 12:12 :
>
> > Can't one design a setting working like \bf or \it ?
> Sure. This is how \bf is defined in plain.tex:
> \newfam\bffam \def\bf{\fam\bffam\tenbf} % \bf is family 6
> \textfont\bffam=\tenbf \scriptfont\bffam=\sevenbf
> \scriptscriptfont\bffam=\fivebf
> *Gesendet:* Sonntag, 27. August 2023 um 11:41 Uhr
> *Von:* "Gérald Tenenbaum" <gerald.tenenbaum at univ-lorraine.fr>
> *An:* "Philip Taylor (Hellenic Institute)"
> <P.Taylor at Hellenic-Institute.Uk>
> *Cc:* "Eplain" <tex-eplain at tug.org>
> *Betreff:* Re: [tex-eplain] boldface greek symbols
> Thanks.
> Yes it suffices, but I also need these boldface letters in
> subscripts.
> I am puzzled by the necessity of using \hbox. Can't one design
> a setting working like \bf or \it ?
> Regards,
>
> Gérald
>
> Philip Taylor (Hellenic Institute) a écrit le 27/8/23 à 11:21 :
>
> You don't appear to be using \gpfam, Gérald — will not the
> following suffice ?
>
>
> \font \tengp = cmmib10
> \def \gp {\textfont 1 = \tengp}
> \def \gth {\hbox {$\gp \vartheta $}}
> $\gth \neq \vartheta $
> \end
>
> --
> /Philip Taylor/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/tex-eplain/attachments/20230827/59c34166/attachment-0001.htm>
More information about the tex-eplain
mailing list.