Why can not rm or rmtf fonts be set up by \definebodyfont macro?
These days I have been reading "co-fonts.pdf" because I plan to write a document about ConTeXt MkIV for our Chinese users. When I reached the part of "Defining body fonts", for testing bodyfont model, I made an example as following: %%%% \definefontsynonym[Song][AdobeSongStd-Light] \definefontsynonym[Hei][AdobeHeitiStd-Regular] \definefontsynonym[FangSong][AdobeFangsongStd-Regular] \definefontsynonym[Kai][AdobeKaitiStd-Regular] \definebodyfont[12pt][rm] [tf=Song, bf=Hei sa 1, it=Kai sa 1, sl=FangSong sa 1] \setscript[hanzi] \setupbodyfont[rm,12pt] \starttext 今时之人不然也,以酒为浆,以妄为常, {\bf 醉以入房,以欲竭其精,以耗散其真}, {\it 不知持满,不时御神}, {\sl 务快其心,逆于生乐,起居无节,故半百而衰也}。 \stoptext %%%% I found that "rmtf" font is not "AdobeSongStd-Light", which is always "LMRoman12-Regular". However, "bf", "it" and "sl" fonts all are right. I looked over the log file and saw some messages as following: fonts : preloading latin modern fonts bodyfont : 12pt rm is loaded I want to know why I can not override the preloading rm font. Thanks. -- Best wishes, Li Yanrui * Gentoo Linux (~x86) * ConTeXt Minimals Beta (2009.03.30 18:28)
Am 05.04.2009 um 15:07 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition. \definefontsynonym [Song] [file:AdobeSongStd-Light] \definefontsynonym [Hei] [file:AdobeHeitiStd-Regular] \definefontsynonym [FangSong] [file:AdobeFangsongStd-Regular] \definefontsynonym [Kai] [file:AdobeKaitiStd-Regular] \starttypescript [serif] [default] [size] \definebodyfont [12pt] [rm] [tf=Song sa 1, bf=Hei sa 1, it=Kai sa 1, sl=FangSong sa 1] \stoptypescript \starttypescript [serif] [chinese] \definefontsynonym [Serif] [Song] \stoptypescript \definetypeface [chinese] [rm] [serif] [chinese] [default] \setscript[hanzi] \setupbodyfont[chinese,rm,12pt] \starttext \startlines \tf 今时之人不然也,以酒为浆,以妄为常, \bf 醉以入房,以欲竭其精,以耗散其真, \it 不知持满,不时御神, \sl 务快其心,逆于生乐,起居无节,故半百而衰也。 \stoplines \stoptext Wolfgang
2009/4/5 Wolfgang Schuster
Am 05.04.2009 um 15:07 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition.
If I use other font size, it can work, such as: \definebodyfont[11pt][rm] [tf=Song, bf=Hei sa 1, it=Kai sa 1, sl=FangSong sa 1] \setscript[hanzi] \setupbodyfont[rm,11pt] -- Best wishes, Li Yanrui * Gentoo Linux (~x86) * ConTeXt Minimals Beta (2009.03.29 13:28)
Am 05.04.2009 um 17:16 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition.
If I use other font size, it can work, such as:
It has to do with the default setting which is 12pt roman. \appendtoks\letcsnamecs\csname*modern12ptrmtfrm*\endcsname\undefined\to \everystarttext Wolfgang
Wolfgang Schuster wrote:
Am 05.04.2009 um 17:16 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition.
If I use other font size, it can work, such as:
It has to do with the default setting which is 12pt roman.
\appendtoks\letcsnamecs\csname*modern12ptrmtfrm*\endcsname\undefined\to\everystarttext
brrrr, better try \setupbodyfont[reset] \setupbodyfont[mymodern] ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 05.04.2009 um 22:04 schrieb Hans Hagen:
Wolfgang Schuster wrote:
Am 05.04.2009 um 17:16 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition.
If I use other font size, it can work, such as: It has to do with the default setting which is 12pt roman. \appendtoks\letcsnamecs\csname*modern12ptrmtfrm*\endcsname\undefined \to\everystarttext
brrrr, better try
\setupbodyfont[reset] \setupbodyfont[mymodern]
Did not work because reset alone use the roman style also for italic and bold and he don't use his own typeface, your dummy mymodern lead us back to the start. Wolfgang
Wolfgang Schuster wrote:
Am 05.04.2009 um 22:04 schrieb Hans Hagen:
Wolfgang Schuster wrote:
Am 05.04.2009 um 17:16 schrieb Yanrui Li:
I want to know why I can not override the preloading rm font.
Dunno but it works for a complete definition.
If I use other font size, it can work, such as: It has to do with the default setting which is 12pt roman. \appendtoks\letcsnamecs\csname*modern12ptrmtfrm*\endcsname\undefined\to\everystarttext
brrrr, better try
\setupbodyfont[reset] \setupbodyfont[mymodern]
Did not work because reset alone use the roman style also for italic and bold and he don't use his own typeface, your dummy mymodern lead us back to the start.
tricky ... --mode=*nofonts ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 05.04.2009 um 23:14 schrieb Hans Hagen:
\setupbodyfont[reset] \setupbodyfont[mymodern]
Did not work because reset alone use the roman style also for italic and bold and he don't use his own typeface, your dummy mymodern lead us back to the start.
tricky ...
--mode=*nofonts
Not really, font switch but regular style only. Wolfgang
Wolfgang Schuster wrote:
Am 05.04.2009 um 23:14 schrieb Hans Hagen:
\setupbodyfont[reset] \setupbodyfont[mymodern]
Did not work because reset alone use the roman style also for italic and bold and he don't use his own typeface, your dummy mymodern lead us back to the start.
tricky ...
--mode=*nofonts
Not really, font switch but regular style only.
sure, but i'm not too eager to add that kind of hackery so loading a new typeface then makes more sense Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 05.04.2009 um 23:25 schrieb Hans Hagen:
sure, but i'm not too eager to add that kind of hackery so loading a new typeface then makes more sense
My hack can be done in a cleaner way with \appendtoks\letcsnamecs \csname\newfontidentifier\endcsname\undefined\to\everystarttext but a new typeface makes more sense in Li Yanrui's example as I can see. Wolfgang
2009/4/6 Wolfgang Schuster
Am 05.04.2009 um 23:25 schrieb Hans Hagen:
sure, but i'm not too eager to add that kind of hackery so loading a new typeface then makes more sense
My hack can be done in a cleaner way with \appendtoks\letcsnamecs\csname\newfontidentifier\endcsname\undefined\to\everystarttext but a new typeface makes more sense in Li Yanrui's example as I can see.
Thanks very much for your hints and Hans' tricky. -- Best wishes, Li Yanrui * Gentoo Linux (~x86) * ConTeXt Minimals Beta (2009.03.29 13:28)
participants (3)
-
Hans Hagen
-
Wolfgang Schuster
-
Yanrui Li