I have a configuration file to download custom fonts for Apache FOP. I'm struggling to set up embed-url on the server so that the url font changes according to the server domain.
I tried the value of the embed-url property as:
Broken Embedded URLs:
- embed-url = "context: /etc/designs/projectName/clientlibs/pdffonts/Batang.ttf"
- embed-url = "File: /etc/designs/projectName/clientlibs/pdffonts/Batang.ttf"
Working Embed URL:
- embed-url = "http: // local: 4503 / etc / constructs / projectname / clientlibs / pdffonts / batang.ttf"
Somehow I cannot find the correct syntax here. I am using FOP with AEM 6.0.
<?xml version="1.0"?>
<fop version="1.0">
<renderers>
<renderer mime="application/pdf">
<fonts>
<font kerning="yes"
embed-url="context:/etc/designs/projectName/clientlibs/pdffonts/Batang.ttf" -- this doesn't
embedding-mode="subset">
<font-triplet name="SimSun" style="normal" weight="normal" />
</font>
<font kerning="yes"
embed-url="file:/etc/designs/projectName/clientlibs/pdffonts/Batang.ttf" -- this doesn't
embedding-mode="subset">
<font-triplet name="Batang" style="normal" weight="normal" />
</font>
<font kerning="yes"
embed-url="http://localhost:4503/etc/designs/projectName/clientlibs/pdffonts/Batang.ttf" -- this works
embedding-mode="subset">
<font-triplet name="Batang" style="normal" weight="normal" />
</font>
</fonts>
</renderer>
</renderers>
</fop>