- - PR -
Cocoon2.0 (FOP0.20.1)で漢字が「#」に文字化けする
1
投稿者 | 投稿内容 |
---|---|
|
投稿日時: 2002-04-18 18:00
別スレッドで、自己解決していましたが、全く文字化けが直りません。
この2日かかって進捗0です・・・ToT 環境: Cocoon2.0 Tomcat4.0.1 JDK1.3.1 Windows2000 Cocoonの画面はうまく立ち上がり、PDFのサンプルに、漢字を入れると文字化けするので、以下の方法を試しましたが、改善されませんでした。 1.JP-FOP0.20.1の文中にあるドキュメントを読み、userconfig.xmlに追加 <fonts> <font embed-file='C:\WINNT\Fonts/msgothic.ttc' kerning='yes' metrics-file='C:\Program Files/Apache Tomcat 4.0/webapps/cocoon/WEB-INF/mspgothic.xml'> <font-triplet name='MS Pゴシック' style='normal' weight='normal'/> <font-triplet name='MS PGothic' style='normal' weight='normal'/> </font> <font embed-file='C:\WINNT\Fonts/msmincho.ttc' kerning='yes' metrics-file='C:\Program Files/Apache Tomcat 4.0/webapps/cocoon/WEB-INF/msmincho.xml'> <font-triplet name='MS 明朝' style='normal' weight='normal'/> <font-triplet name='MS Mincho' style='normal' weight='normal'/> </font> <font embed-file='C:\WINNT\Fonts/msmincho.ttc' kerning='yes' metrics-file='C:\Program Files/Apache Tomcat 4.0/webapps/cocoon/WEB-INF/mspmincho.xml'> <font-triplet name='MS P明朝' style='normal' weight='normal'/> <font-triplet name='MS PMincho' style='normal' weight='normal'/> </font> <font embed-file='C:\WINNT\Fonts/msgothic.ttc' kerning='yes' metrics-file='C:\Program Files/Apache Tomcat 4.0/webapps/cocoon/WEB-INF/msgothic.xml'> <font-triplet name='MS ゴシック' style='normal' weight='normal'/> <font-triplet name='MS Gothic' style='normal' weight='normal'/> <font-triplet name='JaFont' style='normal' weight='normal'/> <font-triplet name='Osaka' style='normal' weight='normal'/> </font> (metrics-fileをこの例ではフルパスで書いていますが、Pathを消して、同一フォルダにしてもNGでした) 2.各embed-fileを作成 java org.apache.fop.fonts.apps.TTFReader -ttcname "MS Gothic" C:\WINNT\Fonts\msgothic.ttc msgothic.xml (いろいろ必要なjarファイルはlibに放り込みました)<-無いときは当然コンパイルエラー で、サンプルからとってきたfoファイルを表示しても####表示で化けてしまいます。 どなたか方法をご存知でしたらご教授願います。 |
|
投稿日時: 2002-04-24 18:55
漢字が#になってしまう現象ですが、C2のバグです。
これは、文字コードうんぬんの問題ではなく、ユーザ指定のフォントが反映されない現象です。 詳しいことは、こちら↓のページ http://www.emergence.jp/ci/ の、MLのアーカイブをご覧になってください。 |
1