My XSL style uses Arial font
<fo:block font-family="Arial" font-size="8pt" font-weight="normal">
Configuration file fonts.xml:
<?xml version="1.0"?>
<fop>
<renderers>
<renderer mime="application/pdf">
<fonts>
<base>file:///C:/windows/fonts</base>
</fonts>
</renderer>
</renderers>
</fop>
also tried using this:
<auto-detect/>
and
<directory>C:\windows\fonts</directory>
I am always getting:
WARNING: Font "Arial,normal,400" not found. Substituting with "any,normal,400".
What should I fix in order to use Arial font?
This worked for me, need to specify the Arial font explicitly in configuration file:
<?xml version="1.0"?>
<fop>
<renderers>
<renderer mime="application/pdf">
<fonts>
<font kerning="yes" embed-url="file:///C:/windows/fonts/arial.ttf">
<font-triplet name="Arial" style="normal" weight="normal"/>
</font>
</fonts>
</renderer>
</renderers>
</fop>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With