ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Adam Lindsay" <atl@comp.lancs.ac.uk>
Subject: Re: re-using ConTeXt typescripts ?
Date: Mon, 11 Jul 2005 17:33:27 +0100	[thread overview]
Message-ID: <20050711163327.13159@mail.comp.lancs.ac.uk> (raw)
In-Reply-To: <a06210200bef839974b46@[213.20.142.130]>

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
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

      reply	other threads:[~2005-07-11 16:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-11 15:37 Steffen Wolfrum
2005-07-11 16:33 ` Adam Lindsay [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050711163327.13159@mail.comp.lancs.ac.uk \
    --to=atl@comp.lancs.ac.uk \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).