[xep-support] Adding Japanese fonts

Mark Giffin mgiffin at earthlink.net
Tue Jun 13 23:44:55 PDT 2017


I'm using XEP 4.22 inside of the DITA Open Toolkit and I'm trying to get 
it to use Japanese fonts by configuring xep.xml. I have this under my 
<fonts> element:

         <!-- Japanese open type font. -->
     <font-group label="Japanese Open Type" embed="false">
       <font-family name="KozminPro">
         <font><font-data otf="KozMinPr6N-Regular.otf"/></font>
         <font style="italic"><font-data 
otf="KozMinPr6N-Regular.otf"/></font>
         <font weight="bold"><font-data otf="KozGoPr6N-Medium.otf"/></font>
         <font weight="bold" style="italic"><font-data 
otf="KozGoPr6N-Medium.otf"/></font>
       </font-family>
     </font-group>

It's PDF output and the font seems to be installed on my Windows 7 
machine. KozGoPr6N-Medium.otf and another similar file are in the XEP 
fonts directory.

The PDF comes out with none of the Japanese characters in the original 
XML files, but does display the occasional English word that is in the XML.

I get errors like this from the DITA OT:

transform.fo2pdf.xep:
       [xep] Processing 
C:\Users\Mark\Documents\clients\cloudera\altus-data-engr-docs-ja/temp/pdf/topic.fo 
to 
C:\Users\Mark\Documents\clients\cloudera\altus-data-engr-docs-ja\out\pdf/altus-dataengr.pdf
       [xep] [XEPJ001W][WARN] could not find any font family matching 
"KozMinProVI-Regular,ArialUnicodeMS,Batang"; replaced by Helvetica
...

The OT's font mapping file has this:

     <physical-font char-set="Japanese">
         <font-face>KozMinProVI-Regular</font-face>
       </physical-font>

Thanks,
Mark




More information about the Xep-support mailing list