xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cheri Dennison <che...@amazon.com>
Subject Japanese Char Issues
Date Mon, 06 Apr 2009 22:13:16 GMT

I’m trying to get Japanese characters to show up in the PDF output. I’ve read
in detail the earlier thread about this
(http://www.nabble.com/Japanese-characters-do-not-appear-in-PDF-td21683276.html#a21683276)
and tried to follow along with the suggestions there. But I’m still running
into problems. I am using FOP 0.95 (released version). I wasn't sure what
the bug was that was mentioned in the other thread (should I not be using
the released version of 0.95)?

FYI, the XHTML looks fine; it's the PDF output with the problem.

If I tell my DocBook customization layer to use Arial as the font, I get
this:
-- In FO, as expected: 
<fo:root font-family="Arial,Symbol,ZapfDingbats" font-size="9.2pt"
text-align="left" line-height="normal"
font-selection-strategy="character-by-character"
line-height-shift-adjustment="disregard-shifts" language="en">

--And in the PDF output, all the Japanese characters show up as squares
everywhere.


So, I believe this tells me that I need to find a font that handles the
glyphs. So, I do this next:

--Create a font metrics file for Arial Unicode MS (ARIALUNI.TTF) and place
that file (ARIALUNI.XML) in C:\MyFonts.
--Update my FOP config with font stuff. Here’s what the relevant part of the
file looks like:
<renderer mime="application/pdf">
	<filterList>
		<value>flate</value>
	</filterList>
	<fonts>
		<directory>C:\WINDOWS\FONTS</directory> 
		<directory>C:\MyFonts</directory>
					
		
		  <font-triplet name="ARIALUNI" style="normal" weight="normal"/>
		
	</fonts>
</renderer>

--Update my DocBook customization layer to use ARIALUNI as the font. When I
do all this, then when I open the PDF, Adobe gives me an error message that
says “Can’t find or create the font ArialUnicodeMS. Some characters may not
display or print correctly”. And the file has no characters—just dots here
and there. To me, this message from Adobe means it recognizes the font
metrics file, but it can’t find the font. Interestingly, the bookmarks
themselves correctly display the Japanese characters. FYI, the FO then has
this as you’d expect (ARIALUNI,Symbol,ZapfDingbats” everywhere a font-family
is specified).

I'm attaching the PDF output, and the FO file. Notice that the PDF's
bookmarks look OK and the Japanese characters appear correctly.
http://www.nabble.com/file/p22918536/test_nochars.pdf test_nochars.pdf 
http://www.nabble.com/file/p22918536/test_nochars_fo.xml test_nochars_fo.xml 

What am I missing here? Let me know if I haven't provided enough info.

Thanks so much!
cheri

-- 
View this message in context: http://www.nabble.com/Japanese-Char-Issues-tp22918536p22918536.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Mime
View raw message