From: Idris Samawi Hamid <ishamid@attbi.com>
Subject: typescripts faq-in-progress
Date: Fri, 12 Apr 2002 14:34:02 -0600 [thread overview]
Message-ID: <3XYP5354KEKFXTOI82RNNL6E9UQB0.3cb744ba@c1909372-a> (raw)
Dear ConTeXtnicians:
I'm making progress understanding the typescripts model, though I have still not fully solved my problem. Please help set me straight and to complete and generalize what follows. I'm hoping the
following can serve as a template for a ConTeXt font how-to/faq, something which seems to be desperately needed. mfonts.pdf is really obscure for beginners, unfortunately.
Given a set of 2 raw fonts, one activates them in ConTeXt through the following 6-part procedure:
1. Determine the style, family, and encoding and write a typescript with a more user-friendly, pretty name for the raw font:
\starttypescript [style] [family] [encoding]
\definefontsynonym [Pretty] [original] [encoding=theencoding]
\definefontsynonym [Pretty-Bold] [originalb] [encoding=theencodingenc]
\stoptypescript
The [encoding=theencoding] position may be left blank if the encoding is OT1 or 7-bit ascii. Is this correct?
2. There may be other fonts using the same style, so a more generic abstract style name is associated with the font:
\starttypescript [style] [family] [name]
\definefontsynonym [Style] [Pretty sa 1.6]
\definefontsynonym [Style-Bold] [Pretty-Bold sa 1.6]
\stoptypescript
3. Set up the appropriate sizes for the fonts with respect to one of the default style parameters,
rm, ss, tt, mm, cg, or hw.
\starttypescript [style] [default] [size]
\definebodyfont [20.7pt, 17.3pt, 14.4pt, 12pt, 11pt, 10pt, 9pt, 8pt, 7pt] [rm] [default]
\stoptypescript
For what does the `default' option in the 2nd arg. to \starttypescript stand?
For what does the `default' option in the 3rd arg. to \definebodyfont stand?
Can one associate any style one pleases with, say, [rm], or is there more involved?
4. Combine the generic abstract style and size typescripts into a single font collection:
\starttypescript [collect]
\usetypescript [style] [family] [name]
\usetypescript [style] [default] [size]
\stoptypescript
5. Use the collection in a typeface which takes 6 parameters:
collection name
style parameter
style
family
!not sure what this is!
encoding/rscale options
\starttypescript [mycollect]
\definetypeface [collect] [rm] [style] [family] [default] [encoding=theencoding, rscale=thescalefactor]
\stoptypescript
What does `rscale' mean? What is the purpose of the style parameter here? This is an importan question because I think the crux of my problem is here as I will explain
below.
6. Place the above code into a file type-fam.To use the font issue the following:
\usetypescriptfile[type-fam]
\usetypescript[mycollect
\setupbodyfont[collect]
The font should work now. But see below!
========================================================
Now I tried this but it's not working. I have discovered something which may be the source of the bug.
0. My two raw fonts are omarab and omarabb, located in \texmf\fonts\ovf\public\omega of any tex distribution.
% type-arabic.tex
%1. style, family, and encoding
\starttypescript [naskh] [omega] [default]
\definefontsynonym [OmegaArabic] [omarab]
\definefontsynonym [OmegaArabic-Bold] [omarabb]
\stoptypescript
%2. abstract style synonyms
\starttypescript [naskh] [omega] [name]
\definefontsynonym [Naskh] [OmegaArabic sa 1.6]
\definefontsynonym [NaskhBold] [OmegaArabic-Bold sa 1.6]
\stoptypescript
%3. sizes
\starttypescript [naskh] [default] [size]
\definebodyfont
[20.7pt, 17.3pt, 14.4pt, 12pt, 11pt, 10pt, 9pt, 8pt, 7pt] [rm] [default]
\stoptypescript
%4. final collection
\starttypescript [omarab]
\usetypescript [naskh] [omega] [name]
\usetypescript [naskh] [default] [size]
\stoptypescript
%5. typeface
\starttypescript [arabtest]
\definetypeface [omartest] [rm]
[naskh] [omega] [default] [rscale=1] % [encoding=default]
\stoptypescript
%6. invocation
\usetypescriptfile[type-arabic]
\usetypescript[arabtest]
\setupbodyfont[omartest]
==========================
When I follow the above steps, this is what happens:
====================
(./om-test4.tuo) (./om-test4.tuo)
systems : begin file om-test4 at line 19
typescript : [arabtest] [] []
(c:/TeXLive/texmf/tex/context/base/type-syn.tex)
(c:/TeXLive/texmf/tex/context/base/type-enc.tex)
(c:/TeXLive/texmf/tex/context/base/type-siz.tex)
(c:/TeXLive/texmf/tex/context/base/type-map.tex)
(c:/TeXLive/texmf/tex/context/base/type-spe.tex)
(c:/TeXLive/texmf/tex/context/base/type-exa.tex) (./type-arabic.tex
typeface : [omartest] [rm] [naskh] [omega]
typescript : [naskh] [omega] [name,default,default,special]
(c:/TeXLive/texmf/tex/context/base/type-syn.tex)
(c:/TeXLive/texmf/tex/context/base/type-enc.tex)
(c:/TeXLive/texmf/tex/context/base/type-siz.tex)
(c:/TeXLive/texmf/tex/context/base/type-map.tex)
(c:/TeXLive/texmf/tex/context/base/type-spe.tex)
(c:/TeXLive/texmf/tex/context/base/type-exa.tex) (./type-arabic.tex)
typescript : [naskh] [default] [size]
(c:/TeXLive/texmf/tex/context/base/type-syn.tex)
(c:/TeXLive/texmf/tex/context/base/type-enc.tex)
(c:/TeXLive/texmf/tex/context/base/type-siz.tex)
(c:/TeXLive/texmf/tex/context/base/type-map.tex)
(c:/TeXLive/texmf/tex/context/base/type-spe.tex)
(c:/TeXLive/texmf/tex/context/base/type-exa.tex) (./type-arabic.tex))
Missing character: There is no ^^^^0242 in font cmr10!
:
:
======================
cmr10 is being called instead of omarab. But here is a clue:
If I replace `[rm]' with `[ss]' in step 3 alone, I get cmr12 called;
If I replace `[rm]' with `[ss]' in step 3 and step5, I get cmss10 called;
If I replace `[rm]' with `[ss]' in step 5 alone, I get cmr10 called;
This all makes me think that I am missing at least one important step above. Can anyone tell us what that is?
I am getting really desperate here...
Again, I hope some of you will help me to develop this into a more general font faq.
Best wishes
Idris
Dr. Idris Samawi Hamid
Depatment of Philosophy
Colorado State University
Fort Collins, CO 80526
next reply other threads:[~2002-04-12 20:34 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-04-12 20:34 Idris Samawi Hamid [this message]
2002-04-13 18:52 ` Eureka! [was Re: typescripts faq-in-progress] Idris Samawi Hamid
2002-04-13 22:17 ` Hans Hagen
2002-04-14 0:14 ` Idris Samawi Hamid
2002-04-14 0:31 ` \definefontstyle Idris Samawi Hamid
2002-04-14 5:58 ` small sizes Idris Samawi Hamid
2002-04-14 21:28 ` ConTeXt bug (size-changing)? Idris Samawi Hamid
2002-04-15 8:44 ` Hans Hagen
2002-04-16 1:36 ` Idris Samawi Hamid
2002-04-16 1:50 ` small feature request Idris Samawi Hamid
2002-04-16 11:26 ` Hans Hagen
2002-04-16 20:53 ` Idris Samawi Hamid
2002-04-15 9:18 ` ConTeXt bug (size-changing)? Hans Hagen
2002-04-15 15:48 ` Idris Samawi Hamid
2002-04-15 21:34 ` One last thing:-) Idris Samawi Hamid
2002-04-16 11:13 ` Hans Hagen
2002-04-16 20:44 ` Idris Samawi Hamid
2002-04-17 7:53 ` Hans Hagen
2002-04-17 14:32 ` Let's try again:-> [was Re: One last thing:-)] Idris Samawi Hamid
2002-04-17 17:50 ` Hans Hagen
[not found] ` <BARL64B0NJ6ZPMVQ3OKNJDB3HF0LI.3cbe21da@c1909372-a>
2002-04-18 7:32 ` Hans Hagen
2002-04-18 21:35 ` Idris Samawi Hamid
[not found] ` <3CBE43E9.7565CE19@gcmail.maricopa.edu>
2002-04-18 7:36 ` Lucida Bright fonts Hans Hagen
[not found] ` <3CC0CC3C.7218C29C@gcmail.maricopa.edu>
2002-04-20 23:24 ` Hans Hagen
2002-04-18 21:59 ` \definefontstyle Idris Samawi Hamid
2002-04-13 22:31 ` Eureka! [was Re: typescripts faq-in-progress] Henning Hraban Ramm
2002-04-14 9:56 ` Hans Hagen
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=3XYP5354KEKFXTOI82RNNL6E9UQB0.3cb744ba@c1909372-a \
--to=ishamid@attbi.com \
/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).