pdf2swf couldn't create a font for 'SimSun'

396 Views Asked by At

I was trying to convert a pdf into a swf and i was using swftools. To support Chinese, i downloaded xpdf-chinese-simplified.tar and modified the add-to-xpdfrc file like this

#----- begin Chinese Simplified support package (2011-sep-02)
cidToUnicode    Adobe-GB1       /usr/local/share/xpdf-chinese-simplified/Adobe-GB1.cidToUnicode
unicodeMap      ISO-2022-CN     /usr/local/share/xpdf-chinese-simplified/ISO-2022-CN.unicodeMap
unicodeMap      EUC-CN          /usr/local/share/xpdf-chinese-simplified/EUC-CN.unicodeMap
unicodeMap      GBK             /usr/local/share/xpdf-chinese-simplified/GBK.unicodeMap
cMapDir         Adobe-GB1       /usr/local/share/xpdf-chinese-simplified/CMap
toUnicodeDir                    /usr/local/share/xpdf-chinese-simplified/CMap
#fontFileCC     Adobe-GB1       /usr/..../gkai00mp.ttf
displayCIDFontTT        Adobe-GB1 /usr/local/share/xpdf-chinese-simplified/gkai00mp.ttf
#----- end Chinese Simplified support package

When i tried to convert the pdf,

/usr/local/bin/pdf2swf 10434_102_demo_1414995035745.pdf -o test.swf -s 
    languagedir=/usr/local/share/xpdf-chinese-simplified

an error occured:

Error: Couldn't create a font for 'SimSun'

PS. I have two environments, one is MAC and the other is Redhat, everything is ok in MAC and this error only occurs in Redhat.

1

There are 1 best solutions below

0
David Thomas On

As this question is missing an answer, I can add an optional solution (as a workaround) here.

For Flexpaper, if you use the "HTML5" render mode, it will render Chinese, and other unicode text, correctly.