Nuno So who is invoking FOP ? Dont you write code to invoice it somewhere in the web application ?
I am using XSLTInputhandler explicitly in my servlet to do the xml to pdf conversion and then render the pdf using acrobat. All this happens in the servlet within the weblogic application server paradigm. Right now I have hardcode the userconfig.xml file in the servlet as File userConfigFile = new File("C:\\fop-0.20.5\\conf\\userconfig.xml"); I need to find a way to not hardcode it as its deployed as a jar file on production server. Thanks Manoj <[EMAIL PROTECTED] wareag.com> To: <[EMAIL PROTECTED]> cc: 2005/02/04 10:49 Subject: RE: Fonts in FOP Please respond to fop-user Hi Manoj, Thanks for your help. I really need to re-build "fop.jar", because my web application uses it standalone and I don't have code access. I think I really should configure something in the "build.xml" of FOP. Something like: <property name="ttfcomic.xml" value="${build.codegen}/ttfcomic.xml"/> I need to know, what and how do I need to configure? Nuno -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: sexta-feira, 4 de Fevereiro de 2005 17:48 To: [EMAIL PROTECTED] Subject: Re: Fonts in FOP Nuno I am also working on a similar issue which involves Japanese fonts but dont have it in a working condition. These are the points I have learned in process. 1) Open the ttfcomic.xml and see whats the name given in the <font-name> tag? This name should match the "ComicSansMS" as you have given in font-triplet tag in the userconfig.xml 2) I would advice for time being to hardcode the complete path to ttfcomic.xml as <font metrics-file="c:\dir\ttfcomic.xml" just like you did for the embed-file 3) No need to change build.xml 4) No need to recompile fop.jar 5) You need to load the fonts by invoking the configuration before your parse XML --> PDF. How are you doing the xml to pdf ? I am using the XSLTInputHandler(xml,xsl) in a servlet or are u running it from command prompt ? 6) I came to know today that I need to manually change the XSL file ( which i had created using XMLSPY) to refer to the font explicitly using the font-family tag. (courtsey of Lou ) <fo:block font-family="ComicSansMS" font-weight="bold" padding-bottom="1mm"> 经营单位 </fo:block> Let me know Manoj <[EMAIL PROTECTED] wareag.com> To: <[EMAIL PROTECTED]> cc: 2005/02/04 08:32 Subject: Fonts in FOP Please respond to fop-user Hello, I need to include a new font in FOP. I already generate a new xml file of the font "comic.ttf" (ttfcomic.xml), and in the "userconfig.xml" added the new font. <font metrics-file="ttfcomic.xml" kerning="yes" embed-file="c:\windows\fonts\comic.ttf"> <font-triplet name="ComicSansMS" style="normal" weight="normal"/> </font> To recompile the "fop.jar", what is necessary to configure? Is it necessary anything else in the "build.xml" of FOP? And where should I put the new "ttfcomic.xml" file for the new font? Is it in "/src/codegen"? Next in the XSL-FO, how can I refer the new font? The font name should be "ComicSansMS" like refer above or the name of the font file? font-style="ComicSansMS" Thanks in advance. Best regards. Nuno Canais --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]