Am 06.01.2014 um 19:56 schrieb Elspeth McGullicuddy 
<elspethmcgullicu...@gmail.com>:

> Hi everybody,
> (best wishes for this new year by the way).
> 
> There is this font:
> http://www.ctan.org/pkg/kpfonts
> Which is a postscript type 1 font, text and math.
> 
> I've copied the files in the right places in the ${HOME}/texmf tree.
> And a call to:
> mtxrun --script fonts --list --all --pattern=*kp*, after a
> mtxrun --script fonts --reload
> seems to indicate that it is found by context all right.
> 
> But now I haven't got the faintest idea on how to use it in a ConTEXt
> document -- text + math.
> My ConTEXt is beta not older than a fortnight.
> 
> All examples I've found that could possibly apply were at least far
> too complicate for my understanding, also likely outdated.

Using a text font in type1-format is very easy, all you need is the afm and the 
pfb-file.

The font files are put in the tex folder and to use them in your document you 
have to write a short typescript, below is a example how to use the urn 
garamond font.

\starttypescript [serif] [charter]
  \setups[font:fallback:serif]
  \definefontsynonym [Serif] [file:ugmr8a.afm] [features=complete]
\stoptypescript

\definetypeface [mainface] [rm] [serif] [charter] [default]

\setupbodyfont[mainface]

\starttext
\input knuth
\stoptext

The same has to be done for the kpfont but there is one problem, the archive on 
cyan doesn’t provide afm-files and you have to generate them yourself. Since 
the font provides only tfm-files it would be also possible to them but it’s 
better to work with afm-files.


Adding support for the math font requires more work because you have to write 
also a Lua file where you specify which file is used for symbols, operator, 
letters etc. This isn’t very complicated (you can just modify the files for 
palatino or garamond math), you have to only look which files are used for the 
math fonts.

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to