ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Setting up lbr fonts
@ 2002-01-22 11:45 Randall Skelton
  2002-01-22 12:28 ` Hans Hagen
  0 siblings, 1 reply; 8+ messages in thread
From: Randall Skelton @ 2002-01-22 11:45 UTC (permalink / raw)


Hi all,

I have been reading the font queries of the past week with great
interest!  While I am quite capable at hacking plain TeX/LaTeX, I am
relatively new to ConTeXt and I too have struggled to sort out fonts in
the latest stable release.  This may seem trivial to some, but is there
documentation somewhere that describes (step-by-step) instructions on how
to install the Lucdia Bright fonts?  I repeatedly get to the stage where
I get errors saying I am missing the type 1 fonts?

Any and all help is appreciated.

Randall

PS: I have also noticed that when putting equations into the presentation
styles, the line following an equation is indented one level deeper than
expexted... has anyone else observed this?


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

* Re: Setting up lbr fonts
  2002-01-22 11:45 Setting up lbr fonts Randall Skelton
@ 2002-01-22 12:28 ` Hans Hagen
  2002-01-23  1:44   ` Jens-Uwe Morawski
  0 siblings, 1 reply; 8+ messages in thread
From: Hans Hagen @ 2002-01-22 12:28 UTC (permalink / raw)
  Cc: ntg-context

At 11:45 AM 1/22/2002 +0000, Randall Skelton wrote:

>I have been reading the font queries of the past week with great
>interest!  While I am quite capable at hacking plain TeX/LaTeX, I am
>relatively new to ConTeXt and I too have struggled to sort out fonts in
>the latest stable release.  This may seem trivial to some, but is there
>documentation somewhere that describes (step-by-step) instructions on how
>to install the Lucdia Bright fonts?  I repeatedly get to the stage where
>I get errors saying I am missing the type 1 fonts?

did you pick up the two font manuals?

>Any and all help is appreciated.
>
>Randall
>
>PS: I have also noticed that when putting equations into the presentation
>styles, the line following an equation is indented one level deeper than
>expexted... has anyone else observed this?

hm, i need a minimal example then

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-pod.nl
-------------------------------------------------------------------------


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

* Re: Setting up lbr fonts
  2002-01-22 12:28 ` Hans Hagen
@ 2002-01-23  1:44   ` Jens-Uwe Morawski
  2002-01-23  8:54     ` Hans Hagen
  0 siblings, 1 reply; 8+ messages in thread
From: Jens-Uwe Morawski @ 2002-01-23  1:44 UTC (permalink / raw)


On Tue, 22 Jan 2002 13:28:54 +0100
Hans Hagen <pragma@wxs.nl> wrote:

> At 11:45 AM 1/22/2002 +0000, Randall Skelton wrote:
> 
> >I have been reading the font queries of the past week with great
> >interest!  While I am quite capable at hacking plain TeX/LaTeX, I am
> >relatively new to ConTeXt and I too have struggled to sort out fonts in
> >the latest stable release.  This may seem trivial to some, but is there
> >documentation somewhere that describes (step-by-step) instructions on how
> >to install the Lucdia Bright fonts?  I repeatedly get to the stage where
> >I get errors saying I am missing the type 1 fonts?
> 
> did you pick up the two font manuals?
> 

I did some weeks ago, and i must say it is beyond my skill and
understanding. I agree that a step-by-step (or dummy ;> ) guide
is needed. The typescript stuff may understand who knows the
internals, but i'm only a user, and i think many others too.

AFAIK i see (for the latin world) 5 scenarios:
- a non-text font with special symbols
- a text-font without any variants
- a base font package [regular, italic (oblique), bold, bold-italic (bold-oblique)]
- the base package extended with Osf+SC fonts
- the base package extended with expert fonts

The most common case is the 3rd, thus any fonts distributed this way
can be used as example. An exmaple font for the 4th case can be Adobe Palatino,
and for the 5th may be Adobe Garamond or Minion.

I know that ConTeXt prefers texfont.pl, but i hope fonts already
installed using fontinst can be covered too, since fontinst is
afaik the only way where i can substitute the numbers of a font with
its oldstyle variants (choosing pplj instead of pplx
gives me oldstyle numbers).

I hope somebody has the time and can manage this.

Regards,
  Jens


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

* Re: Setting up lbr fonts
  2002-01-23  1:44   ` Jens-Uwe Morawski
@ 2002-01-23  8:54     ` Hans Hagen
  2002-01-24 10:56       ` Jens-Uwe Morawski
  0 siblings, 1 reply; 8+ messages in thread
From: Hans Hagen @ 2002-01-23  8:54 UTC (permalink / raw)
  Cc: ConTeXt

At 02:44 AM 1/23/2002 +0100, Jens-Uwe Morawski wrote:

>I know that ConTeXt prefers texfont.pl, but i hope fonts already
>installed using fontinst can be covered too, since fontinst is
>afaik the only way where i can substitute the numbers of a font with
>its oldstyle variants (choosing pplj instead of pplx
>gives me oldstyle numbers).
>
>I hope somebody has the time and can manage this.

If you don't use texfont.pl, the main thing you need to do is to find out 
what the names are of the tfm's that fontinst generates.

You can make typescripts as simple as you want, skipping symbolic names, or 
even not using typescript and using \definefont directly, but then you 
loose a couple of abstractions.

Say that you have this palatino and that you used fontinst to generate ec 
encoded fonts, then you have to make a script like:

\starttypescript [serif] [adobepalatino] [ec]

   \definefontsynonym [Palatino]      [thefontinstgeneratedname]
   \definefontsynonym [PalatinoBold]  [anotherfontinstgeneratedname]

\stoptypescript

It's a serif font, so now we define an accompanying serif script:

\starttypescript [serif] [adobepalatino] [name]

   \definefontsynonym [Serif]      [Palatino]
   \definefontsynonym [SerifBold]  [PalatinoBold]

\stoptypescript

Say that you put these script in a file called typeface.tex that you put 
somewhere where tex can find it. In your document (or style) you now need 
to tell context that you need this file:

\usetypescriptfile[typeface]

you will probably have a map file too and you can either load that one in 
pdftex.cfg or let context do that.

The next thing is using this font. Of course you can execute typescripts 
yourself but best is to use the command

\definetypeface [myface] [rm] [serif] [adobepalatino] [default] [encoding=ec]

this means as much as: create a typeface, map it to the rm families, using 
the serif definitions of adobepalatino matching encodning ec, and use the 
default size definition scripts.

In a similar way you can add ss, tt, mm, etc definitions to this typeface 
'myface'. Bewaqre, use rscale=... to achieve relative scaling, if needed.

Now you need to activate this typeface (because each typeface has its own 
namespace, you can mix 'm any way you want]

\setupbodyfont[myface,10pt,rm]

Now you should have an adobe palatino document.

If you do it this way, you can also say (handy for titlepages and so):

{\definedfont[SerifBold at 60pt]This is a big title}

or

\definefont[VeryBigFont][Palatino at 150pt] \VeryBigFont Guess what 
(happens after \setuphead[chapter][style=VeryBigFont])

Now, the whole idea behind this concept is that you can build your own set 
of definitions (typefaces); here we have for instance one typeface.tex file 
per project and a couple of general system wide ones for ourself.

Back to texfont vs fontinst: in the case of texfont, you can more 
conveniently mix multiple instances, like three regular weights of a 
multipel master, or seven different slanted palatino's; in the case of 
fontinst you have the advantages you already mentioned, but you're on your 
own to figure out what file names are used as well as prevent nameclashes 
yourself].

BTW, does patrick still has this idea of reprogramming those font tools?

Hans

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-pod.nl
-------------------------------------------------------------------------


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

* Re: Setting up lbr fonts
  2002-01-23  8:54     ` Hans Hagen
@ 2002-01-24 10:56       ` Jens-Uwe Morawski
  2002-01-24 13:23         ` Hans Hagen
  0 siblings, 1 reply; 8+ messages in thread
From: Jens-Uwe Morawski @ 2002-01-24 10:56 UTC (permalink / raw)


On Wed, 23 Jan 2002 09:54:07 +0100
Hans Hagen <pragma@wxs.nl> wrote:

> Say that you have this palatino and that you used fontinst to generate ec 
> encoded fonts, then you have to make a script like:

First, thank you for your explanations.

> \starttypescript [serif] [adobepalatino] [ec]
> 
>    \definefontsynonym [Palatino]      [thefontinstgeneratedname]
>    \definefontsynonym [PalatinoBold]  [anotherfontinstgeneratedname]
> 
> \stoptypescript

Okay, that's the part i understand

But,

> It's a serif font, so now we define an accompanying serif script:
> 
> \starttypescript [serif] [adobepalatino] [name]
> 
>    \definefontsynonym [Serif]      [Palatino]
>    \definefontsynonym [SerifBold]  [PalatinoBold]
> 
> \stoptypescript
> 

What means/does [name] here?

When i declare a [serif] typescript, why i need:
\definefontsynonym [Serif]      [Palatino]

In my opinion this is redundant.
\definefontsynonym [Regular] [Palatino]
is what i would use. Of course i can map Serif-->Regular in an
other [serif] typescript, but i think that would break another
[sans] typescript with the same mapping.

Or the same question from another point of view: When the font-commands
use or look for Serif, SerifBold ... why the typescript must be declared as [serif]?

or what would mean a [sans] typescript with the same 
 \definefontsynonym [Serif...] [...] definitions?

> The next thing is using this font. Of course you can execute typescripts 
> yourself but best is to use the command
> 
> \definetypeface [myface] [rm] [serif] [adobepalatino] [default] [encoding=ec]

Here again. As far as i understand the font-switching-macros use the declarations
like Serif, or SerifBold. In this case: why i have to declared it as [rm] too?

Or, why i need 'rm' in the next declaration? 'myface' is already defined as 'rm'
> 
> \setupbodyfont[myface,10pt,rm]
> 

Hmm, many questions, which show that i understand nothing ;)

And another question: fontinst generates some fonts including
symbols like degree. upright-mu or the registered-symbol. These
are in (LaTeX) TS1 encoding. What declarations are needed to use them?

Thanks in advance. Regards,
  Jens


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

* Re: Setting up lbr fonts
  2002-01-24 10:56       ` Jens-Uwe Morawski
@ 2002-01-24 13:23         ` Hans Hagen
  2002-01-25  7:25           ` Jens-Uwe Morawski
  0 siblings, 1 reply; 8+ messages in thread
From: Hans Hagen @ 2002-01-24 13:23 UTC (permalink / raw)
  Cc: ConTeXt

At 11:56 AM 1/24/2002 +0100, Jens-Uwe Morawski wrote:

>What means/does [name] here?
>
>When i declare a [serif] typescript, why i need:
>\definefontsynonym [Serif]      [Palatino]

name identifier this script as mapping a name onto a style; the 
\definetypeface macro uses this to identify what it should load (it looks 
for name, size and map scripts

>In my opinion this is redundant.

it depends, you may indeed skip that one but then you cannot write style 
files using the more symbolic Serif instead of Palatino; I tend to write 
styles independent of the font

Or the same question from another point of view: When the font-commands
>use or look for Serif, SerifBold ... why the typescript must be declared 
>as [serif]?

you can name it anything you want, this 'serif' is used to locate the 
script with \definetypeface,

   \starttypescript [fancyshape] ....

combined with

   \definetypeface [..] [..] [fancyshape]

would work as well.

>or what would mean a [sans] typescript with the same
>  \definefontsynonym [Serif...] [...] definitions?

you can do that but it does not make sense, however, some font shapes have 
alternatives, think of

   [lightserif]

so, you can organize your fonts (univers has for instance many 
alternatives) accordingly and map 'm onto different typefaces,

\definetypeface [normal] [rm] [serif] ....
\definetypeface [light]  [rm] [lightserif] ....

> > The next thing is using this font. Of course you can execute typescripts
> > yourself but best is to use the command
> >
> > \definetypeface [myface] [rm] [serif] [adobepalatino] [default] 
> [encoding=ec]
>
>Here again. As far as i understand the font-switching-macros use the 
>declarations
>like Serif, or SerifBold. In this case: why i have to declared it as [rm] too?

actually the chain is:

rmtf <- Serif     <- Palatino     <- fontname.tfm
rmbf <- SerifBold <- PalatinoBold <- boldfontname.tfm

so, rmtf, rmbf etc are the internal names ; the rm/ss/tt/hw/cf etc make up 
a (traditional) collection of familied (in terms of tex) fonts. If you skip 
the typescript altogether, you can use \definefont to set these, like

\definefont [rm] [10pt] [tf=fontname sa 1, bf=boldfontname sa 1]

>Or, why i need 'rm' in the next declaration? 'myface' is already defined 
>as 'rm'
> >
> > \setupbodyfont[myface,10pt,rm]
> >

within a typeface there can be rm,ss,etc and the default is the one defined 
first. Here indeed the rm could be omited, but it does not hurt either.

>Hmm, many questions, which show that i understand nothing ;)
>
>And another question: fontinst generates some fonts including
>symbols like degree. upright-mu or the registered-symbol. These
>are in (LaTeX) TS1 encoding. What declarations are needed to use them?

you can define them as symbols

\definesymbol [registered] [\getglyph{Serif}{\char123}]  % or 
{Palatino}{\char123} or {fontname}{\char123} or take your choice

these will scale with the current font size. The problem with these symbols 
is that because they are not always present in a font, we cannot add them 
to encoding vectors.

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-pod.nl
-------------------------------------------------------------------------


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

* Re: Setting up lbr fonts
  2002-01-24 13:23         ` Hans Hagen
@ 2002-01-25  7:25           ` Jens-Uwe Morawski
  2002-01-25  9:46             ` Hans Hagen
  0 siblings, 1 reply; 8+ messages in thread
From: Jens-Uwe Morawski @ 2002-01-25  7:25 UTC (permalink / raw)


On Thu, 24 Jan 2002 14:23:08 +0100
Hans Hagen <pragma@wxs.nl> wrote:

> >And another question: fontinst generates some fonts including
> >symbols like degree. upright-mu or the registered-symbol. These
> >are in (LaTeX) TS1 encoding. What declarations are needed to use them?
> 
> you can define them as symbols
> 
> \definesymbol [registered] [\getglyph{Serif}{\char123}]  % or 
> {Palatino}{\char123} or {fontname}{\char123} or take your choice

In mfonts.pdf is shown how font-style switches (\bf, ...)
automatically apply to the Euro-Symbol.

Is it enough when i say
\definefontsynonym [PalatinoSymbols] [<TS1-Font>]
\definefontsynonym [PalatinoSymbolsBold] [<TS1-Bold-Font>]

\definefontsynonym [SerifSymbols] [PalatinoSymbols]
\definefontsynonym [SerifSymbolsBold] [PalatinoSymbolsBold]

\definesymbol [registered] [\getglyph{SerifSymbols}{\char123}]

to reach the same automatism.

Can i use the \definesymbol declaration in typescripts in order to
make the symbol-name<-->slot mapping local?

> these will scale with the current font size. The problem with these symbols 
> is that because they are not always present in a font, we cannot add them 
> to encoding vectors.

In both cases
- declaring a symbol
- using a symbol from a predefined encoding
 one must know which symbols are available, thus some predefined
 symbol-declarations could make the life easier. TS1 s a good
 starting-point, since it includes most of the symbols commonly available
 in commercial fonts. But i see, there is no good integration in texfont.

Regards,
  Jens 


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

* Re: Setting up lbr fonts
  2002-01-25  7:25           ` Jens-Uwe Morawski
@ 2002-01-25  9:46             ` Hans Hagen
  0 siblings, 0 replies; 8+ messages in thread
From: Hans Hagen @ 2002-01-25  9:46 UTC (permalink / raw)
  Cc: ConTeXt

At 08:25 AM 1/25/2002 +0100, Jens-Uwe Morawski wrote:
>On Thu, 24 Jan 2002 14:23:08 +0100
>Hans Hagen <pragma@wxs.nl> wrote:
>
> > >And another question: fontinst generates some fonts including
> > >symbols like degree. upright-mu or the registered-symbol. These
> > >are in (LaTeX) TS1 encoding. What declarations are needed to use them?
> >
> > you can define them as symbols
> >
> > \definesymbol [registered] [\getglyph{Serif}{\char123}]  % or
> > {Palatino}{\char123} or {fontname}{\char123} or take your choice
>
>In mfonts.pdf is shown how font-style switches (\bf, ...)
>automatically apply to the Euro-Symbol.
>
>Is it enough when i say
>\definefontsynonym [PalatinoSymbols] [<TS1-Font>]
>\definefontsynonym [PalatinoSymbolsBold] [<TS1-Bold-Font>]
>
>\definefontsynonym [SerifSymbols] [PalatinoSymbols]
>\definefontsynonym [SerifSymbolsBold] [PalatinoSymbolsBold]
>
>\definesymbol [registered] [\getglyph{SerifSymbols}{\char123}]
>
>to reach the same automatism.

indeed, the getglyph macro tries to resolve size (x,xx,1,a,b,c,d,..) as 
well as style (Bold, BoldSlanted,...).

>Can i use the \definesymbol declaration in typescripts in order to
>make the symbol-name<-->slot mapping local?

in principle you can put anythinhg in a typescript, but it's not local

btw, interesting point; maybe i should add fontclass/encoding specific symbols

   \definesymbol[registered] [{\symbol[\currentencoding-registered]}]

   \definesymbol[texnansi-registered][\getglygh{SerifSymbols}{\char123}]

that one switches with the encoding, the next with the typeface

   \definesymbol [registered] [{\symbol[\fontclass-registered]}]

   \definesymbol [somename-registered] [...]

with somename being the typeface;

actually, i think that i could even automate that; will think about it. 
that way we can mix any combination of fonts / symbols

[one of the ideas behind typefaces/scripts is that one can mix in one doc 
complete different font families without clashes]

> > these will scale with the current font size. The problem with these 
> symbols
> > is that because they are not always present in a font, we cannot add them
> > to encoding vectors.
>
>In both cases
>- declaring a symbol
>- using a symbol from a predefined encoding
>  one must know which symbols are available, thus some predefined
>  symbol-declarations could make the life easier. TS1 s a good
>  starting-point, since it includes most of the symbols commonly available
>  in commercial fonts. But i see, there is no good integration in texfont.

sure, but for that i depend on users; these things can go into the symb-* files

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-pod.nl
-------------------------------------------------------------------------


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

end of thread, other threads:[~2002-01-25  9:46 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-01-22 11:45 Setting up lbr fonts Randall Skelton
2002-01-22 12:28 ` Hans Hagen
2002-01-23  1:44   ` Jens-Uwe Morawski
2002-01-23  8:54     ` Hans Hagen
2002-01-24 10:56       ` Jens-Uwe Morawski
2002-01-24 13:23         ` Hans Hagen
2002-01-25  7:25           ` Jens-Uwe Morawski
2002-01-25  9:46             ` Hans Hagen

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).