Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
|
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 20th, 2004, 04:57 AM
Registered User
 
Join Date: Jan 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default I can't show Chinese when .fo to .pdf

<?xml version="1.0" encoding="big5"?>
 <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
  <fo:layout-master-set>
   <fo:simple-page-master
    margin-right="2.0cm"
    margin-left="2.0cm"
    margin-bottom="2.0cm"
    margin-top="2.0cm"
    page-width="21.0cm"
    page-height="29.7cm"
    master-name="first">
   <fo:region-body margin-top="1.0cm" margin-bottom="1.5cm"/>
   <fo:region-before extent="1.0cm"/>
   <fo:region-after extent="1.5cm"/>
  </fo:simple-page-master>
 </fo:layout-master-set>
 <fo:page-sequence master-reference="first">
  <fo:flow flow-name="xsl-region-body">
   <fo:block font-size="50pt" space-after.optimum="20pt" text-align="left">
Input Chinese here , but I can't see Chinese !
   </fo:block>
  </fo:flow>
 </fo:page-sequence>
</fo:root>

This is a file.fo , I want change to file.pdf , and it finished to file.pdf .
If that text is English ,that file.pdf is OK.
but if that text is Chinese ,that file.pdf will not show right Chinese.

Please tell me , what should I do .

 
Old January 20th, 2004, 05:14 AM
joefawcett's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

Are you sure the fo file is encode correctly? Which fo-to-pdf are you using? Does it support big5?

Joe (MVP - xml)
 
Old January 20th, 2004, 06:00 AM
Registered User
 
Join Date: Jan 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I use fop-0.20.5 , and run
[root@Local fo]# /home/fop-0.20.5/fop.sh -fo /root/file.fo -pdf /root/file.pdf
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] FOP 0.20.5
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] building formatting object tree
[INFO] setting up fonts
[INFO] [1]
[INFO] Parsing of document complete, stopping renderer
[root@Local fo]#

So,that file.pdf is encode correctly.
English or Chinese are encode correctly , but everyone Chinese word is show # .
If I input 4 Chinese word ,will show 4 # .

Or,what kind of program is good for .fo to .pdf ?






Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML to PDF via XSL-FO NEO1976 XSLT 2 September 8th, 2006 06:47 AM
xHTML to XSL:FO to PDF NotesSensei XSLT 0 September 2nd, 2006 10:02 AM
Alternative print output for fo generated pdf Ma7T XSLT 0 August 2nd, 2005 08:27 AM
xml + xsl:fo --> PDF Kabe Classic ASP XML 0 August 26th, 2004 06:17 AM
Show PDF without a webpage?? morpheus Classic ASP Basics 2 March 6th, 2004 09:05 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.