[Fontinst] accented greek

Peter Dyballa Peter_Dyballa at Web.DE
Thu Jan 13 10:55:00 CET 2005


Am 12.01.2005 um 23:13 schrieb Michael Zedler:

> I'm trying to get greek for MinionPro [...] The problem is that I'm 
> running out of slots for the accented upper case letters. Using proper 
> kerning info for the accents and the upper case letters they could be 
> assembled, but I'd prefer using the glyphs in the font.
>
> Any idea how to achieve this?

Maybe my approach for adding glyphs from TrueType fonts might work for 
you too: I created a simple ETX file that enumerates all the extra 
glyphs that are not contained in 8r. You could transform the font using 
this encoding and assembly your output from this MTX file and the 
others. 8p is my new differential encoding vector, maybe 8g could work 
for you. (I am converting the TrueType font to PS and making it this 
way available to TeX.)

\batchmode
\input fontinst.sty
\recordtransforms{slst.recs}
%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% Lucida Sans Typewriter
%%%%%%%%%%%%%%%%%%%%%%%%%%%
\setint{smallcapsscale}{825}
% We're starting with some real things!
%% This is the usual set:
   \transformfont{slsrt8r}    {\reencodefont{8r} {\fromafm{slsrt8a}}}
   \transformfont{slsrot8r}   {\reencodefont{8r} {\fromafm{slsrot8a}}}
   \transformfont{slsbt8r}    {\reencodefont{8r} {\fromafm{slsbt8a}}}
   \transformfont{slsbot8r}   {\reencodefont{8r} {\fromafm{slsbot8a}}}
%% Here are the extras from TrueType:
   \transformfont{slsrt8p}    {\reencodefont{8p} {\fromafm{slsrt8p}}}
   \transformfont{slsrot8p}   {\reencodefont{8p} {\fromafm{slsrot8p}}}
   \transformfont{slsbt8p}    {\reencodefont{8p} {\fromafm{slsbt8p}}}
   \transformfont{slsbot8p}   {\reencodefont{8p} {\fromafm{slsbot8p}}}
%
\installfonts
%
  \installfamily{OT1}{slst}{\hyphenchar\font=-1}
   \installfont  {slsrt7t}   {slsrt8r,slsrt8p,8p,newlatin}            
{ot1tt} {OT1}{slst}{m}{n}{}
   \installfont  {slsrct7t}  {slsrt8r,slsrt8p,8p,newlatin}            
{ot1ctt}{OT1}{slst}{m}{sc}{}
   \installfont  {slsbt7t}   {slsbt8r,slsbt8p,8p,newlatin}            
{ot1tt} {OT1}{slst}{b}{n}{}
   \installfont  {slsbct7t}  {slsbt8r,slsbt8p,8p,newlatin}            
{ot1ctt}{OT1}{slst}{b}{sc}{}
   \installfont  {slsrot7t}{slsrot8r,slsrot8p,8p,newlatin option 
nosc}{ot1itt}{OT1}{slst}{m}{sl}{}
   \installfont  {slsbot7t}{slsbot8r,slsbot8p,8p,newlatin option 
nosc}{ot1itt}{OT1}{slst}{b}{sl}{}
%
  \installfamily{T1} {slst}{\hyphenchar\font=-1}
   \installfont  {slsrt8t}   {slsrt8r,slsrt8p,8p,newlatin}            
{t1}  {T1}{slst}{m}{n}{}
   \installfont  {slsrct8t}  {slsrt8r,slsrt8p,8p,newlatin}            
{t1c} {T1}{slst}{m}{sc}{}
   \installfont  {slsbt8t}   {slsbt8r,slsbt8p,8p,newlatin}            
{t1}  {T1}{slst}{b}{n}{}
   \installfont  {slsbct8t}  {slsbt8r,slsbt8p,8p,newlatin}            
{t1c} {T1}{slst}{b}{sc}{}
   \installfont  {slsrot8t}{slsrot8r,slsrot8p,8p,newlatin option 
nosc}{t1}  {T1}{slst}{m}{sl}{}
   \installfont  {slsbot8t}{slsbot8r,slsbot8p,8p,newlatin option 
nosc}{t1}  {T1}{slst}{b}{sl}{}
%
  \installfamily{TS1}{slst}{\hyphenchar\font=-1}
   \installfont  {slsrt8c}   {slsrt8r,slsrt8p,8p,textcomp}            
{ts1}{TS1}{slst}{m}{n}{}
   \installfontas{slsrt8c}                                               
   {TS1}{slst}{m}{sc}{}
   \installfont  {slsbt8c}   {slsbt8r,slsbt8p,8p,textcomp}            
{ts1}{TS1}{slst}{b}{n}{}
   \installfontas{slsbt8c}                                               
   {TS1}{slst}{b}{sc}{}
   \installfont  {slsrot8c}{slsrot8r,slsrot8p,8p,textcomp}           
{ts1i}{TS1}{slst}{m}{sl}{}
   \installfont  {slsbot8c}{slsbot8r,slsbot8p,8p,textcomp}           
{ts1i}{TS1}{slst}{b}{sl}{}
%%%
\endinstallfonts

\endrecordtransforms
\bye


The ETX is oriented on t1.etx ans looks like:

\setslot{baht} \endsetslot      %%bahtthai
\setslot{bahtthai} \endsetslot
\setslot{colonmonetary} \endsetslot
\setslot{dong} \endsetslot
\setslot{euro} \endsetslot
\setslot{afii08941} \endsetslot %%lira
\setslot{lira} \endsetslot
\setslot{naira} \endsetslot
\setslot{peso} \endsetslot
\setslot{rupiah} \endsetslot
\setslot{won} \endsetslot
\setslot{discount} \endsetslot
\setslot{pertenthousand} \endsetslot
\setslot{estimated} \endsetslot
\setslot{afii61352} \endsetslot %%numero
\setslot{numero} \endsetslot
\setslot{radical} \endsetslot
\setslot{centigrade} \endsetslot
\setslot{recipe} \endsetslot


To access the deviating names you need an MTX file (8p.mtx) that makes 
them accessible by mapping them to the defined names:

\ifisglyph{Eng}\then
    setglyph{Ng} \glyph{Eng}{1000} \endsetglyph
\Fi
\ifisglyph{eng}\then
    setglyph{ng} \glyph{eng}{1000} \endsetglyph
\Fi
\ifisglyph{afii08941}\then
    setglyph{lira} \glyph{afii08941}{1000} \endsetglyph
\Fi
\ifisglyph{bahtthai}\then
    \setglyph{baht} \glyph{bahtthai}{1000} \endsetglyph
\Fi
\ifisglyph{afii61352}\then
    setglyph{numero} \glyph{afii61352}{1000} \endsetglyph
\Fi
\ifisglyph{Idot}\then
    \setglyph{Idotaccent} \glyph{Idot}{1000} \endsetglyph
\Fi
\ifisglyph{Odblacute}\then
    \setglyph{Ohungarumlaut} \glyph{Odblacute}{1000} \endsetglyph
\Fi


In the fontinst news archive 
(http://www.math.utah.edu/pipermail/tex-fonts) you can find some more 
on this, it's in the time since Christmas. The names you'll have to use 
in 8g.mtx can be retrieved from the AFM file. To see the glyphs and 
their PS names you can run t1testpage on the PS font programme. It is 
part of Eddie Kohler's LCDF type tools and creates a many pages long 
font chart showing the glyphs, their names and the 'slot positions', 
i.e. where you write "u" in your text a "Xi" might appear on paper.

--
Mit friedvollen Grüßen

   Pete

The most exciting phrase to hear in science, the one that heralds new 
discoveries, is not "Eureka!" (I found it!) but "That's funny..." 
[Isaac Asimov]



More information about the fontinst mailing list