You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by Matthias Born <bo...@oio.de> on 2001/08/13 16:47:31 UTC

embedding fonts using xml-font-files and userconf.xml

hi!

i've got problems embedding fonts.

as described in http://xml.apache.org/fop/fonts.html and other resources i
generated the xml font-file with:

	java -cp fop.jar org.apache.fop.fonts.apps.TTFReader zurchn.ttf	zurich.xml

i placed resulting zurich.xml along with the original *.ttf-file in the
fop-directory and in the conf-directory as well

Then i renamed the font-name in the <font-name>-tag to "Zurich" in the
zurich.xml

i configured the userconfig in the conf-directory in the following way:

	<fonts>
		<font metrics-file="zurich.xml" kerning="yes" embed-file="zurich.ttf">
			<font-triplet name="Zurich" style="normal" weight="bold"/>
		</font>
	</fonts>

then i tried to use it as font-family="Zurich" in a <fo:block>-tag in my fo
file.

but when i invoked that file with:

	java -cp fop.jar org.apache.fop.apps.Fop -c userconfig.xml -fo
schulung.fo -pdf output.pdf
	and
	fop -c userconfig.xml -fo schulung.fo -pdf output.pdf
	among others

the result always was:

	WARNING: unknown font Zurich,normal,normal so defaulted font to any

any ideas what went wrong?

regards matze


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: AW: embedding fonts using xml-font-files and userconf.xml

Posted by Tore Engvig <te...@manamind.com>.

Hehe, it would've been to easy if it was only a typo :)
It really don't have any other suggestions except using absolute
urls/paths in userconfig.xml, like:

<font metrics-file="file:///C:/fop/zurich.xml"
      kerning="yes"
      embed-file="C:\WINNT\Fonts\zurich.ttf"
   <font-triplet name="Zurich" style="normal" weight="normal"/>
</font>


Tore



On Mon, 13 Aug 2001, Matthias Born wrote:

> ups!
>
> thanks and sorry!
> it was a mistake in the mail.
>
> >>   > 	<fonts>
> >>   > 		<font metrics-file="zurich.xml" kerning="yes"
> embed-file="zurich.ttf">
> >>   > 			<font-triplet name="Zurich" style="normal" weight="bold"/>
> >>   > 		</font>
> >>   > 	</fonts>
>
> >>   Yes, you only added Zurich bold to userconfig.xml. If you want to use
> the
> >>   normal weight, you have to add that one too (weight="normal").
>
> i tried differend styles and weights, also i tried "normal", "normal", again
> after your mail.
> unfortunately it was not the solution.
>
> the weight="bold" was one of my last try outs, therefore it's written in the
> mail.
>
> any over ideas?
>
> regards matze
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


AW: embedding fonts using xml-font-files and userconf.xml

Posted by Matthias Born <bo...@oio.de>.
ups!

thanks and sorry!
it was a mistake in the mail.

>>   > 	<fonts>
>>   > 		<font metrics-file="zurich.xml" kerning="yes"
embed-file="zurich.ttf">
>>   > 			<font-triplet name="Zurich" style="normal" weight="bold"/>
>>   > 		</font>
>>   > 	</fonts>

>>   Yes, you only added Zurich bold to userconfig.xml. If you want to use
the
>>   normal weight, you have to add that one too (weight="normal").

i tried differend styles and weights, also i tried "normal", "normal", again
after your mail.
unfortunately it was not the solution.

the weight="bold" was one of my last try outs, therefore it's written in the
mail.

any over ideas?

regards matze



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


horizontal alignment

Posted by Matthias Born <bo...@oio.de>.
hi!

how can i place a table (the whole table, not the text) in the middle of the
page, sth. like horizontal-alignment="center|middle"?

thx matze


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: embedding fonts using xml-font-files and userconf.xml

Posted by Tore Engvig <te...@manamind.com>.

On Mon, 13 Aug 2001, Matthias Born wrote:

> hi!
>
> i've got problems embedding fonts.

[snip]

> i configured the userconfig in the conf-directory in the following way:
>
> 	<fonts>
> 		<font metrics-file="zurich.xml" kerning="yes" embed-file="zurich.ttf">
> 			<font-triplet name="Zurich" style="normal" weight="bold"/>
> 		</font>
> 	</fonts>

[snip]
> 	WARNING: unknown font Zurich,normal,normal so defaulted font to any
>
> any ideas what went wrong?

Yes, you only added Zurich bold to userconfig.xml. If you want to use the
normal weight, you have to add that one too (weight="normal").


Tore

>
> regards matze
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org