Re: SVG text not displaying in PDF
Jeremy Heiler <[email protected]>
| Newsgroups | gmane.text.xml.fop.user |
|---|---|
| Message-ID | <CAKL9L2=CYRNUM_Mhv9BcWa_+FQz4uauMVzsx8Pymzd78q+KTfQ@mail.gmail.com> |
Sure.
*<?xml version="1.0" encoding="UTF-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format
<http://www.w3.org/1999/XSL/Format>"
xmlns:svg="http://www.w3.org/2000/svg <http://www.w3.org/2000/svg>">
<fo:layout-master-set>
<fo:simple-page-master margin-right="50pt" margin-left="50pt"
margin-bottom="25pt" margin-top="75pt" master-name="page">
<fo:region-body margin-bottom="50pt"/>
<fo:region-after extent="25pt"/>
</fo:simple-page-master>
<fo:page-sequence-master master-name="all">
<fo:repeatable-page-master-alternatives>
<fo:conditional-page-master-reference
page-position="first" master-reference="page"/>
<fo:conditional-page-master-reference
page-position="rest" master-reference="page"/>
</fo:repeatable-page-master-alternatives>
</fo:page-sequence-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="all">
<fo:static-content flow-name="xsl-region-after">
<fo:table table-layout="fixed">
<fo:table-column column-width="6.25in"/>
<fo:table-column column-width="0.25in"/>
<fo:table-body font-family="Helvetica" font-size="10pt">
<fo:table-row line-height="12pt">
<fo:table-cell>
<fo:block text-align="start">
© Foo Ltd
</fo:block>
</fo:table-cell>
<fo:table-cell>
<fo:block text-align="end"/>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:static-content>
<fo:flow flow-name="xsl-region-body">
<fo:block space-after.optimum="15pt" space-before.optimum="15pt">
<fo:instream-foreign-object display-align="center">
<svg:svg height="152pt" width="600pt">
<svg:defs>
<svg:style type="text/css">
svg:text { font-size:14; fill:#10559B;
stroke:#10559B; stroke-width:0; font-family:Helvetica }
</svg:style>
</svg:defs>
<svg:rect
style="fill:none;stroke:#10559B;stroke-width:2" height="150pt"
width="150pt" y="1pt" x="155pt"/>
<svg:line
style="fill:none;stroke:#10559B;stroke-width:2" y2="75pt" x2="305pt"
y1="75pt" x1="155pt"/>
<svg:line
style="fill:none;stroke:#10559B;stroke-width:2" y2="150pt" x2="230pt"
y1="1pt" x1="230pt"/>
<svg:text
style="font-size:14;fill:#10559B;stroke:#10559B;stroke-width:0;
font-family:Helvetica" text-anchor="middle" y="41pt"
x="192pt">Relater</svg:text>
<svg:text
style="font-size:14;fill:#10559B;stroke:#10559B;stroke-width:0;
font-family:Helvetica" text-anchor="middle" y="41pt"
x="267pt">Expresser</svg:text>
<svg:text
style="font-size:14;fill:#10559B;stroke:#10559B;stroke-width:0;
font-family:Helvetica" text-anchor="middle" y="116pt"
x="192pt">Analyzer</svg:text>
<svg:text
style="font-size:14;fill:#10559B;stroke:#10559B;stroke-width:0;
font-family:Helvetica" text-anchor="middle" y="116pt"
x="267pt">Director</svg:text>
</svg:svg>
</fo:instream-foreign-object>
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>*
On Thu, Apr 28, 2016 at 5:16 PM, Andreas Delmelle <
[email protected]> wrote:
> Hi Jeremy
>
> > On 28 Apr 2016, at 22:40, Jeremy Heiler <[email protected]> wrote:
> >
> > I am in the process of upgrading from FOP 0.92-beta to 2.1, and for the
> most part I have been able to work out the issues. However, I am stumped
> with this particular issue of rending text in an SVG. Any SVG text that
> used to render no longer displays at all.
> ...
> > What am I missing?
>
> Hmm... difficult to say without seeing the FO source. Is it possible for
> you to post a reduced sample that demonstrates the issue?
>
>
> TIA
>
> Andreas
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
Screen Shot 2016-04-28 at 5.27.02 PM.png
(image/png, 65.6 KB) - not displayed