开发者

Adding a new font to FOP. couldn't find main class. program will now exit

I am trying to add a new Font to FOP.

I start creating a metric font file by running this:

java org.apache.fop.fonts.apps.TTFReader C:\WINNT\Fonts\msgothic.ttf msgothic.xml

But I keep getting the same error: Could not find the main class: org.apache.fop.fonts.apps.TTFReader . program will exit.

I guess I should add fop.apps.TTFReader to my java path, but I can't figu开发者_如何学运维re out how.

Thanks in advance for your help,


The error you get points at not finding the main class. Here you can see that there is no main method in this class. That results in not being able to call its functionality in the way you tried.

If you're using FOP 1.0, there are ways to autodetect fonts from a directory or from the systems font folder, or even from a jar you build containing fonts. Check this tutorial.

Cheers, Wim

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜