ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Idris Samawi Hamid <ishamid@lamar.colostate.edu>
Subject: How to cook Garamond
Date: Sat, 2 Apr 2005 17:15:40 -0700	[thread overview]
Message-ID: <42AC552A@webmail.colostate.edu> (raw)

Dear syndicate,

[Garamond is a nice font. Now that there is a free version, this would be a 
nice default font to add to the next ConTeXt distribution. In the meantime:]

How to cook Garamond (my apologies to the experts for the verbosity):

1. Download

ftp://dante.ctan.org/tex-archive/fonts/urw/garamond.zip (actually, you only 
need the pfb and afm files, unless your texfont does not work);

2. place ONLY the afm and pfb files in an empty temporary directory;

3. from /temp>, run

texfont --ma --in --ve=urw --co=garamond --show

you may verify the installation of your font by examining 
texnansi-urw-garamond.pdf.

4. If texfont does not work, you will have to do more work-> the zip package 
contains tfms etc, and here is a map file you will need:

=============texnansi-urw-garamond.map==============
% You need to add the following line to pdftex.cfg:
%
%   map +texnansi-urw-garamond.map
%
% Alternatively in your TeX source you can say:
%
%   \pdf    {+texnansi-urw-garamond.map}
%
% In ConTeXt you can best use:
%
%   \loadmapfile[texnansi-urw-garamond.map]

texnansi-raw-ugmm8a GaramondNo8-Med 4 < ugmm8a.pfb texnansi.enc
texnansi-raw-ugmmi8a GaramondNo8-MedIta 4 < ugmmi8a.pfb texnansi.enc
texnansi-raw-ugmr8a GaramondNo8-Reg 4 < ugmr8a.pfb texnansi.enc
texnansi-raw-ugmri8a GaramondNo8-Ita 4 < ugmri8a.pfb texnansi.enc
=========================================================

If texfont works, ignore step 4;

5. Now write to file the following typescript:

==========================type-ugm.tex======================
% raw fonts

\starttypescript[serif]               [garamond] [texnansi]

\definefontsynonym[Garamond]          [ugmr8a]   [encoding=texnansi]
\definefontsynonym[GaramondItalic]    [ugmri8a]  [encoding=texnansi]
\definefontsynonym[GaramondBold]      [ugmm8a]   [encoding=texnansi]
\definefontsynonym[GaramondBoldItalic][ugmmi8a]  [encoding=texnansi]

\stoptypescript

%Names

\starttypescript [serif] [garamond] [name]

\setups[font:fallback:serif]

\definefontsynonym[Serif]          [Garamond]
\definefontsynonym[SerifBold]      [Garamond-Bold]
\definefontsynonym[SerifItalic]    [Garamond-Italic]
\definefontsynonym[SerifBoldItalic][Garamond-BoldItalic]

\stoptypescript

%Synonyms

\starttypescript [serif] [garamond] [texnansi]

\definefontsynonym [Garamond]
[\typescriptthree-ugmr8a]
[encoding=\typescriptthree]

\definefontsynonym [Garamond-Bold]
[\typescriptthree-ugmri8a]
[encoding=\typescriptthree]

\definefontsynonym [Garamond-Italic]
[\typescriptthree-ugmm8a]
[encoding=\typescriptthree]

\definefontsynonym [Garamond-BoldItalic]
[\typescriptthree-ugmmi8a]
[encoding=\typescriptthree]

\stoptypescript

% maps

\starttypescript [map] [garamond] [texnansi]

\loadmapfile[texnansi-urw-garamond.map]

\stoptypescript%

% typefaces

\starttypescript [URWGaramond]

\definebodyfontenvironment
  [urwgaramond]
  [default]
  [interlinespace=2.8ex]

\definetypeface [urwgaramond]
[rm] [serif] [garamond] [default]
[encoding=texnansi]

\definetypeface [urwgaramond]
[ss] [sans] [helvetica] [default]
[encoding=texnansi]

\definetypeface [urwgaramond]
[mm] [math] [palatino] [default]
[encoding=texnansi]

\definetypeface [urwgaramond]
[tt] [mono] [modern] [default]
[encoding=texnansi]

\stoptypescript

===========================

If there are better/more aesthetic choices for sans and math, let me know-)

6. Test it out:

===========================
% output=pdf interface=en

\starttext

\usetypescriptfile[type-ugm]
\usetypescript[URWGaramond]
%\setupbodyfont[urwgaramond,12pt]

\definetypeface  [garamond][rm][serif][garamond][default][encoding=texnansi]
\switchtotypeface[garamond]

\input knuth

\stoptext
===========================

You try \setupbodyfont instead of \definetypeface.

Have fun with Garamond!

Best
Idris

============================
Professor Idris Samawi Hamid
Department of Philosophy
Colorado State University
Fort Collins, CO 80523

             reply	other threads:[~2005-04-03  0:15 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-03  0:15 Idris Samawi Hamid [this message]
2005-04-03  3:13 ` Ciro Soto
2005-04-03  3:14   ` Ciro Soto
2005-04-03  4:29 ` Ciro Soto
2005-04-03  8:12 ` Peter Münster
2005-04-03 20:07 ` h h extern
2005-04-03 20:57 ` Willi Egger
2005-04-03 15:58 Idris Samawi Hamid
2005-04-03 18:32 ` Peter Münster
2005-04-03 16:18 Idris Samawi Hamid
2005-04-03 20:23 Idris Samawi Hamid
2005-04-04 17:16 ` Peter Münster
2005-04-04 19:41   ` Hans Hagen
2005-04-05  6:05     ` Peter Münster
2005-04-03 21:13 Idris Samawi Hamid
2005-04-05 14:54 Idris Samawi Hamid
2005-04-05 17:19 ` Peter Münster

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=42AC552A@webmail.colostate.edu \
    --to=ishamid@lamar.colostate.edu \
    --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).