Hi Alan,
calm down.
On Wed, Jul 16, 2008 at 9:18 PM, Alan Stone
(1) \definefont[myChapterFont][myHeadingsFont sa 1.728] You could either use a real font name like 'Arial' or a symbolic name defined with \definefontsynonym like 'Serif', 'SerifBold', 'Sans', 'Dummy-Regular' etc. in the second argument of \definefont but not the name for a font collection defined with \definetype, in your case \definefont[myChapterFont][Sans sa 1.728] or \definefont[myChapterFont][DummyRegular sa 1.728]
So ( and considering the example at http://wiki.contextgarden.net/Chapters_headers ) I tried...
\setuppapersize [A4][A4]
\starttypescript [serif] [myBodyFont] \definefontsynonym [myBodyFontRegular] [name:Times New Roman] [features=default] \definefontsynonym [myBodyFontItalic] [name:Times New Roman Italic] [features=default] \definefontsynonym [myBodyFontBold] [name:Times New Roman Bold] [features=default] \definefontsynonym [myBodyFontBoldItalic] [name:Times New Roman Bold Italic] [features=default] \stoptypescript \starttypescript [serif] [myBodyFont] \setups[font:fallback:serif] \definefontsynonym [Serif] [myBodyFontRegular] \definefontsynonym [SerifItalic] [myBodyFontItalic] \definefontsynonym [SerifBold] [myBodyFontBold] \definefontsynonym [SerifBoldItalic] [myBodyFontBoldItalic] \stoptypescript \starttypescript [myBodyFont] \definetypeface [myBodyFont] [rm] [serif] [myBodyFont] [default] \stoptypescript
\starttypescript [sans] [myHeadingsFont] \definefontsynonym [myHeadingsFontRegular] [name:Arial] [features=default] \definefontsynonym [myHeadingsFontItalic] [name:Arial Italic] [features=default] \definefontsynonym [myHeadingsFontBold] [name:Arial Bold] [features=default] \definefontsynonym [myHeadingsFontBoldItalic] [name:Arial Bold Italic] [features=default] \stoptypescript \starttypescript [sans] [myHeadingsFont] \setups[font:fallback:sans] \definefontsynonym [Sans] [myHeadingsFontRegular] \definefontsynonym [SansItalic] [myHeadingsFontItalic] \definefontsynonym [SansBold] [myHeadingsFontBold] \definefontsynonym [SansBoldItalic] [myHeadingsFontBoldItalic] \stoptypescript \starttypescript [myHeadingsFont] \definetypeface [myHeadingsFont] [ss] [sans] [myHeadingsFont] [default] \stoptypescript
\usetypescript[myBodyFont] \usetypescript[myHeadingsFont]
\setupbodyfont[myBodyFont,12pt] % this works: body font displays in the correct font
%\definefont[myChapterFont][myHeadingsFontRegular sa 1.728] % compile error at line 51: WHY ? \definefont[myChapterFont][Arial sa 1.728] % only this works: WHY ? %\definefont[myChapterFont][Sans sa 1.728] % defaults to default LM font for line 51: WHY ?
%\setuphead[chapter][style=myChapterFont] \setuphead[chapter][style=\myChapterFont]
\setuphead[chapter][style=\myHeadingsFont\myChapterFont] You have to load 'myHeadingsfont' typescript before you can use them because they are not available on outer level, only fonts used as bodyfont can be accesed without this selection.
\starttext
\chapter{chapter test} % line 51
\section{section test}
text test
\stoptext
Many thanks in advance for your enlightening help.
I found the information to solve your problem in the fonts manual and you should read it if you need more information. http://pragma-ade.com/general/manuals/mfonts.pdf Regards, Wolfgang