Next in thread → Next in month →

Re: [docbook-apps] Adding a font

From
David Nedrow <>
Date
2005-07-12T01:31:47+00:00
ID
Thread
Re: [docbook-apps] Adding a font
On Jul 9, 2005, at 3:49 PM, Jacques Foucry wrote:


> I located the font file (/System/Library/Fonts/LucidaGrande.dfont).
>
> If I insterstood what I read I have to add in the xep.xml file  
> something like :
>
> <font-family name="LucidaGrande" embed="true">
>     <font>
>         <font-data ttf="LucidaGrande.dfont/> <!-- is it ttf= or  
> dfont=  ? -->
>     </font>
> </font-family>
>


Hmmm, the dfont files are Apple's data-fork-only font file. I'm not  
sure these are 1-1 compatible with Windows TrueType fonts.

Remember, after you've defined the font, you also need to apply it in  
the stylesheets. Here's an example where I'm applying an OCR font to  
verbatim elements using a customization layer:

     <xsl:attribute-set name="monospace.verbatim.properties"
         use-attribute-sets="verbatim.properties monospace.properties">
         <xsl:attribute name="font-family">OCRAStd</xsl:attribute>
         <xsl:attribute name="font-size">55%</xsl:attribute>
         <xsl:attribute name="text-align">start</xsl:attribute>
         <xsl:attribute name="wrap-option">no-wrap</xsl:attribute>
     </xsl:attribute-set>


-David
Next in thread → Next in month →