ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* re-using ConTeXt typescripts ?
@ 2005-07-11 15:37 Steffen Wolfrum
  2005-07-11 16:33 ` Adam Lindsay
  0 siblings, 1 reply; 2+ messages in thread
From: Steffen Wolfrum @ 2005-07-11 15:37 UTC (permalink / raw)


Hi Adam,

the simplicity of XeTeX's font handling is amazing -- when starting 
from scratch.
But I am wondering how can I continue to use the typescripts (and 
virtual files) that I used to use with ConTeXt?!

texexec --xtx --example.file

ends in an error log containing:

This is METAFONT, Version 2.71828 (Web2C 7.5.4)
kpathsea: Running mktexmf AGaramond-Regular

! I can't find file `AGaramond-Regular'.



As I do not have *any* idea where to start searching for my mistake 
(resp. the place where changes have to be made) I dare to send you a 
complete minimal example (that worked with pure texexec --pdf 
--example.file)

Any feedback might probably help me...

Thank you,

Steffen




I have an example-file, a typescript-file and a map-file.


The example-file goes like this:

\def\typescriptfiles{type-GMTHKopie.tex}
\usetypescript[AGaramondOldStyle]

\setupbodyfont[normaltype,rm,10.2pt]%klein:10 - mittel:10.2 - gross:10.5pt

\starttext
Test WQ916
\stoptext



The type-GMTHKopie.tex:
\loadmapfile[padKopie.map]
\starttypescript [serif] [agaramond] [ec]
   \definefontsynonym [AGaramond-Regular]        [padr9e] 
[encoding=uc] % was encoding=ec before xetex
   \definefontsynonym [AGaramond-Italic]         [padri9e] [encoding=uc] % =ec
   \definefontsynonym [AGaramond-Bold]           [padb9e]  [encoding=uc] % =ec
   \definefontsynonym [AGaramond-BoldItalic]     [padbi9e] [encoding=uc] % =ec
   \definefontsynonym [AGaramond-Semibold]       [pads9e]  [encoding=uc] % =ec
   \definefontsynonym [AGaramond-SemiboldItalic] [padsi9e] [encoding=uc] % =ec
\stoptypescript
\starttypescript [serif] [agaramond] [name]
   \definefontsynonym [Serif]             [AGaramond-Regular]
   \definefontsynonym [SerifBold] 
[AGaramond-Semibold]%[AGaramond-Bold-OSF]
   \definefontsynonym [SemiBold]          [AGaramond-Semibold]
   \definefontsynonym [SerifItalic]       [AGaramond-Italic]
   \definefontsynonym [SerifBoldItalic] 
[AGaramond-SemiboldItalic]%[AGaramond-BoldItalic-OSF]
   \definefontsynonym [SemiBoldItalic]    [AGaramond-SemiboldItalic]
\stoptypescript
\starttypescript      [serif][allbold][all]
    \definefontsynonym [Serif]          [SerifBold]
    \definefontsynonym [SerifItalic]    [SerifBoldItalic]
\stoptypescript

\starttypescript [AGaramondOldStyle]
   \definetypeface [normaltype] [rm] [serif]  [agaramond] 
[default] [encoding=uc] % =ec
   \definetypeface [boldtype]   [rm] [serif]  [agaramond,allbold] 
[default] [encoding=uc] % =ec
\stoptypescript



The padKopie.map:
% Adobe Garamond
padr8r  AGaramond-Regular        "TeXBase1Encoding ReEncodeFont" 
<8r.enc <padr8a.pfb
padri8r AGaramond-Italic         "TeXBase1Encoding ReEncodeFont" 
<8r.enc <padri8a.pfb
pads8r  AGaramond-Semibold       "TeXBase1Encoding ReEncodeFont" 
<8r.enc <pads8a.pfb
padsi8r AGaramond-SemiboldItalic "TeXBase1Encoding ReEncodeFont" 
<8r.enc <padsi8a.pfb
padb8r  AGaramond-Bold           "TeXBase1Encoding ReEncodeFont" 
<8r.enc <padb8a.pfb
padbi8r AGaramond-BoldItalic     "TeXBase1Encoding ReEncodeFont" 
<8r.enc <padbi8a.pfb

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: re-using ConTeXt typescripts ?
  2005-07-11 15:37 re-using ConTeXt typescripts ? Steffen Wolfrum
@ 2005-07-11 16:33 ` Adam Lindsay
  0 siblings, 0 replies; 2+ messages in thread
From: Adam Lindsay @ 2005-07-11 16:33 UTC (permalink / raw)


Hi Steffen,

You're pretty close. It's best not to rewrite your old scripts, rather,
to make a new type-enc style script to replace your existing [serif]
[agaramond][ec] script. This way, when changing engines, it's a simple
step of changing the (default, perhaps?) encoding...

\starttypescript [serif] [agaramond] [uc] % XeTeX and Unicode is a happy
combination
   \definefontsynonym [AGaramond-Regular]        
      ['AGaramondPro-Regular:mapping=tex-text;+onum']        [encoding=uc] 
   \definefontsynonym [AGaramond-Italic]         
      ['AGaramondPro-Italic:mapping=tex-text;+onum']         [encoding=uc] 
   \definefontsynonym [AGaramond-Bold]           
      ['AGaramondPro-Bold:mapping=tex-text;+onum']           [encoding=uc]
   \definefontsynonym [AGaramond-BoldItalic]     
      ['AGaramondPro-BoldItalic:mapping=tex-text;+onum']     [encoding=uc]
   \definefontsynonym [AGaramond-Semibold]       
      ['AGaramondPro-Semibold:mapping=tex-text;+onum']       [encoding=uc]
   \definefontsynonym [AGaramond-SemiboldItalic] 
      ['AGaramondPro-SemiboldItalic:mapping=tex-text;+onum'] [encoding=uc]
\stoptypescript

So, as you will know from the XeTeX documentation :), the way of naming
a font is enclosed within quotes. The first element is the postscript
font name (otfinfo -p <fontname> or look in FontBook.app), then
(optionally) a /I, /B, /BI, or /S for within-family selection, any
mapping features, and then other OpenType features.

Here I selected the tex-text mapping (to stay consistent with `` --- ''
ligatures), and the +onum opentype feature (guessing from the name of
your typescripts, you like Oldstyle NUMerals).

If you wanted to go further, you could define an \sc alternative in your
typescripts by inserting it into your other typescripts and turning on
the +smcp feature in AGaramondPro-Regular for the appropriate synonym to
fit above. I leave that as an exercise for the reader...

adam

Steffen Wolfrum said this at Mon, 11 Jul 2005 17:37:24 +0200:

>\starttypescript [serif] [agaramond] [ec]
>   \definefontsynonym [AGaramond-Regular]        [padr9e] 
>[encoding=uc] % was encoding=ec before xetex
>   \definefontsynonym [AGaramond-Italic]         [padri9e]
[encoding=uc] % =ec
>   \definefontsynonym [AGaramond-Bold]           [padb9e] 
[encoding=uc] % =ec
>   \definefontsynonym [AGaramond-BoldItalic]     [padbi9e]
[encoding=uc] % =ec
>   \definefontsynonym [AGaramond-Semibold]       [pads9e] 
[encoding=uc] % =ec
>   \definefontsynonym [AGaramond-SemiboldItalic] [padsi9e]
[encoding=uc] % =ec
>\stoptypescript
>\starttypescript [serif] [agaramond] [name]
>   \definefontsynonym [Serif]             [AGaramond-Regular]
>   \definefontsynonym [SerifBold] 
>[AGaramond-Semibold]%[AGaramond-Bold-OSF]
>   \definefontsynonym [SemiBold]          [AGaramond-Semibold]
>   \definefontsynonym [SerifItalic]       [AGaramond-Italic]
>   \definefontsynonym [SerifBoldItalic] 
>[AGaramond-SemiboldItalic]%[AGaramond-BoldItalic-OSF]
>   \definefontsynonym [SemiBoldItalic]    [AGaramond-SemiboldItalic]
>\stoptypescript
>\starttypescript      [serif][allbold][all]
>    \definefontsynonym [Serif]          [SerifBold]
>    \definefontsynonym [SerifItalic]    [SerifBoldItalic]
>\stoptypescript
>
>\starttypescript [AGaramondOldStyle]
>   \definetypeface [normaltype] [rm] [serif]  [agaramond] 
>[default] [encoding=uc] % =ec
>   \definetypeface [boldtype]   [rm] [serif]  [agaramond,allbold] 
>[default] [encoding=uc] % =ec
>\stoptypescript

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Adam T. Lindsay, Computing Dept.     atl@comp.lancs.ac.uk
 Lancaster University, InfoLab21        +44(0)1524/510.514
 Lancaster, LA1 4WA, UK             Fax:+44(0)1524/510.492
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-07-11 16:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-11 15:37 re-using ConTeXt typescripts ? Steffen Wolfrum
2005-07-11 16:33 ` Adam Lindsay

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).