You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Rakesh Kumar S <Ra...@infosys.com> on 2008/05/16 15:35:25 UTC
Font Recognition in FOP 0.20.4
Hi
I am using fop version 0.20.4, i am a new bee in this arena.
I want to use arial font in my PDF, I had made a post earlier in this mailing group and based on that i had referred a URL and had done the following steps.
1. I created a arial.xml file pointing to the arial.ttf file in my system using the following command.
java -cp fop.jar;avalon-framework.jar;xml-apis.jar;xercesImpl.jar;xalan.jar org.apache.fop.fonts.apps.TTFReader C:\WINDOWS\fonts\arial.ttf arial.xml
2. Then i unzip my FOP jar file and change the userconfig.xml ( I doubt if i am doing something wrong here)
3. The changed entries in userconfig are below :
<font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
<font-triplet name="arial" style="normal" weight="normal"/>
</font>
4. Now i place both the ttf and the xml files in the corresponding locations and unzip the fop folder back.
5. Now i place the FOP jar in the necessary location and run my application, i still get a error stating that
[ERROR] : unknown font arail,normal,normal defaulting to any.
What is the mistake i am doing???
Could someone please help me in sorting out this???
I know that there are many new version of FOP but i am helpless i have to stick to 0.20.4.
I know i am doing some basic mistake, please guide me.
Thanks in Advance
Rakesh
**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Font Recognition in FOP 0.20.4
Posted by Stefan Heuer <sh...@gmx.de>.
Rakesh Kumar S schrieb:
> <font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
> <font-triplet name="arial" style="normal" weight="normal"/>
> </font>
>
The URL to your file doesn't seem correct.
Test a little bit, like:
- "file://C:\arial.xml" (should be most correct URL specification,
but doesn't work every time) or
- "C:\arial.xml" or
- "C:/arial.xml"
> [ERROR] : unknown font arail,normal,normal defaulting to any
A Typo?: arail
Regards
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Font Recognition in FOP 0.20.4
Posted by Stefan Heuer <sh...@gmx.de>.
Rakesh Kumar S schrieb:
> No luck mate !!!!
>
> Tell me this,
>
> We have the FOP jar and inside that we have the conf/userconfig.xml, i
unzip this file and change the XML.
> Then i zip it back and run the application....
>
I don't if this can work.
In my application I use a adapted conf file. To tell this to the fop
processor I use command line parameter "-c".
Regards
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
Re: Font Recognition in FOP 0.20.4
Posted by "kindaian@gmail.com" <ki...@gmail.com>.
I never touched 0.20.4, only the 0.20.5, but i remember that to make my
fonts to work out, i needed to place the paths in the config file by
hand, and explicitly to all files.
And also, i was adding the config from java (well, php but running as if
it was java), and i had to use also the full path to make it work...
;)
p.s.- i would recomend an upgrade to the latest version, but... i still
remember the pain i had to upgrade my project from 0.20.5 to 0.94...
some years ago ;)
Rakesh Kumar S escreveu:
> The way my application works is that i get a XML file, use XSL:FO and FOP to convert the XML into PDF.
> I dont use command line here....
>
> I am sure i am making a mistake bby changing the userconfig.xml inside the fop jar directly but am not sure what's the right way of doing it....
>
> Can anyone guide me????
> _______________________________________
>
> I don't if this can work.
> In my application I use a adapted conf file. To tell this to the fop
> processor I use command line parameter "-c".
> Regards
> Stefan
> _______________________________________
> From: Rakesh Kumar S
> Sent: Friday, May 16, 2008 7:49 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: RE: Font Recognition in FOP 0.20.4
>
> No luck mate !!!!
>
> Tell me this,
>
> We have the FOP jar and inside that we have the conf/userconfig.xml, i unzip this file and change the XML.
> Then i zip it back and run the application....
>
> Is this the right approach????
>
>
> Rakesh Kumar S schrieb:
>
>> <font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
>> <font-triplet name="arial" style="normal" weight="normal"/>
>> </font>
>>
>>
> The URL to your file doesn't seem correct.
> Test a little bit, like:
> - "file://C:\arial.xml" (should be most correct URL specification,
> but doesn't work every time) or
> - "C:\arial.xml" or
> - "C:/arial.xml"
>
>
>> [ERROR] : unknown font arail,normal,normal defaulting to any
>>
> A Typo?: arail
>
> Regards
> Stefan
>
>
> ________________________________________
> From: Rakesh Kumar S [Rakesh_Kumar06@infosys.com]
> Sent: Friday, May 16, 2008 7:05 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: Font Recognition in FOP 0.20.4
>
> Hi
>
> I am using fop version 0.20.4, i am a new bee in this arena.
>
> I want to use arial font in my PDF, I had made a post earlier in this mailing group and based on that i had referred a URL and had done the following steps.
>
> 1. I created a arial.xml file pointing to the arial.ttf file in my system using the following command.
>
> java -cp fop.jar;avalon-framework.jar;xml-apis.jar;xercesImpl.jar;xalan.jar org.apache.fop.fonts.apps.TTFReader C:\WINDOWS\fonts\arial.ttf arial.xml
>
> 2. Then i unzip my FOP jar file and change the userconfig.xml ( I doubt if i am doing something wrong here)
>
> 3. The changed entries in userconfig are below :
>
> <font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
> <font-triplet name="arial" style="normal" weight="normal"/>
> </font>
>
> 4. Now i place both the ttf and the xml files in the corresponding locations and unzip the fop folder back.
>
> 5. Now i place the FOP jar in the necessary location and run my application, i still get a error stating that
> [ERROR] : unknown font arail,normal,normal defaulting to any.
>
> What is the mistake i am doing???
> Could someone please help me in sorting out this???
>
> I know that there are many new version of FOP but i am helpless i have to stick to 0.20.4.
>
> I know i am doing some basic mistake, please guide me.
>
> Thanks in Advance
>
> Rakesh
>
> **************** CAUTION - Disclaimer *****************
> This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system.
> ***INFOSYS******** End of Disclaimer ********INFOSYS***
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>
Re: Font Recognition in FOP 0.20.4
Posted by Andreas Delmelle <an...@telenet.be>.
On May 16, 2008, at 16:51, Rakesh Kumar S wrote:
> The way my application works is that i get a XML file, use XSL:FO
> and FOP to convert the XML into PDF.
> I dont use command line here....
>
> I am sure i am making a mistake bby changing the userconfig.xml
> inside the fop jar directly but am not sure what's the right way of
> doing it....
Modifying the userconfig.xml, and adding it to the fop.jar has zero
effect. The userconfig.xml is provided as an example, and is never
used, unless you tell FOP to use it.
For FOP 0.20.5:
If you're running FOP from the command-line, this is done, as Stefan
already hinted, by means of supplying '-c /path/to/userconfig.xml'.
If you're using FOP embedded in a Java application, you need to have
a line of code like:
options = new Options(new File("/path/to/userconfig.xml"));
to set up a static configuration class (before the first rendering
process starts, obviously)
HTH!
Cheers
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
RE: Font Recognition in FOP 0.20.4
Posted by Rakesh Kumar S <Ra...@infosys.com>.
The way my application works is that i get a XML file, use XSL:FO and FOP to convert the XML into PDF.
I dont use command line here....
I am sure i am making a mistake bby changing the userconfig.xml inside the fop jar directly but am not sure what's the right way of doing it....
Can anyone guide me????
_______________________________________
I don't if this can work.
In my application I use a adapted conf file. To tell this to the fop
processor I use command line parameter "-c".
Regards
Stefan
_______________________________________
From: Rakesh Kumar S
Sent: Friday, May 16, 2008 7:49 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: Font Recognition in FOP 0.20.4
No luck mate !!!!
Tell me this,
We have the FOP jar and inside that we have the conf/userconfig.xml, i unzip this file and change the XML.
Then i zip it back and run the application....
Is this the right approach????
Rakesh Kumar S schrieb:
> <font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
> <font-triplet name="arial" style="normal" weight="normal"/>
> </font>
>
The URL to your file doesn't seem correct.
Test a little bit, like:
- "file://C:\arial.xml" (should be most correct URL specification,
but doesn't work every time) or
- "C:\arial.xml" or
- "C:/arial.xml"
> [ERROR] : unknown font arail,normal,normal defaulting to any
A Typo?: arail
Regards
Stefan
________________________________________
From: Rakesh Kumar S [Rakesh_Kumar06@infosys.com]
Sent: Friday, May 16, 2008 7:05 PM
To: fop-users@xmlgraphics.apache.org
Subject: Font Recognition in FOP 0.20.4
Hi
I am using fop version 0.20.4, i am a new bee in this arena.
I want to use arial font in my PDF, I had made a post earlier in this mailing group and based on that i had referred a URL and had done the following steps.
1. I created a arial.xml file pointing to the arial.ttf file in my system using the following command.
java -cp fop.jar;avalon-framework.jar;xml-apis.jar;xercesImpl.jar;xalan.jar org.apache.fop.fonts.apps.TTFReader C:\WINDOWS\fonts\arial.ttf arial.xml
2. Then i unzip my FOP jar file and change the userconfig.xml ( I doubt if i am doing something wrong here)
3. The changed entries in userconfig are below :
<font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
<font-triplet name="arial" style="normal" weight="normal"/>
</font>
4. Now i place both the ttf and the xml files in the corresponding locations and unzip the fop folder back.
5. Now i place the FOP jar in the necessary location and run my application, i still get a error stating that
[ERROR] : unknown font arail,normal,normal defaulting to any.
What is the mistake i am doing???
Could someone please help me in sorting out this???
I know that there are many new version of FOP but i am helpless i have to stick to 0.20.4.
I know i am doing some basic mistake, please guide me.
Thanks in Advance
Rakesh
**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
RE: Font Recognition in FOP 0.20.4
Posted by Rakesh Kumar S <Ra...@infosys.com>.
No luck mate !!!!
Tell me this,
We have the FOP jar and inside that we have the conf/userconfig.xml, i unzip this file and change the XML.
Then i zip it back and run the application....
Is this the right approach????
Rakesh Kumar S schrieb:
> <font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
> <font-triplet name="arial" style="normal" weight="normal"/>
> </font>
>
The URL to your file doesn't seem correct.
Test a little bit, like:
- "file://C:\arial.xml" (should be most correct URL specification,
but doesn't work every time) or
- "C:\arial.xml" or
- "C:/arial.xml"
> [ERROR] : unknown font arail,normal,normal defaulting to any
A Typo?: arail
Regards
Stefan
________________________________________
From: Rakesh Kumar S [Rakesh_Kumar06@infosys.com]
Sent: Friday, May 16, 2008 7:05 PM
To: fop-users@xmlgraphics.apache.org
Subject: Font Recognition in FOP 0.20.4
Hi
I am using fop version 0.20.4, i am a new bee in this arena.
I want to use arial font in my PDF, I had made a post earlier in this mailing group and based on that i had referred a URL and had done the following steps.
1. I created a arial.xml file pointing to the arial.ttf file in my system using the following command.
java -cp fop.jar;avalon-framework.jar;xml-apis.jar;xercesImpl.jar;xalan.jar org.apache.fop.fonts.apps.TTFReader C:\WINDOWS\fonts\arial.ttf arial.xml
2. Then i unzip my FOP jar file and change the userconfig.xml ( I doubt if i am doing something wrong here)
3. The changed entries in userconfig are below :
<font metrics-file="file:C:/arial.xml" kerning="yes" embed-file="file:C:/arial.ttf">
<font-triplet name="arial" style="normal" weight="normal"/>
</font>
4. Now i place both the ttf and the xml files in the corresponding locations and unzip the fop folder back.
5. Now i place the FOP jar in the necessary location and run my application, i still get a error stating that
[ERROR] : unknown font arail,normal,normal defaulting to any.
What is the mistake i am doing???
Could someone please help me in sorting out this???
I know that there are many new version of FOP but i am helpless i have to stick to 0.20.4.
I know i am doing some basic mistake, please guide me.
Thanks in Advance
Rakesh
**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org