Converting to PDF: Empty tspan missing

Post questions on how to use or achieve an effect in Inkscape.
mmcguinness
Posts: 1
Joined: Fri Mar 06, 2015 12:10 am

Converting to PDF: Empty tspan missing

Postby mmcguinness » Fri Mar 06, 2015 12:25 am

I'm converting an SVG to PDF using Inkscape 0.91 r (Feb 12 2015) via the command line on Ubuntu.

However if I use an empty tspan (populated with one space) with xml:space="preserve" that tspan is ignored.

Previously in Inkscape 0.48.3.1 r9886 (Jan 29 2013) those tspans were outputted on the PDF basically like a return line. I've searched numerous forums and tried all sorts of combinations but cannot get the current version of Inkscape to output the "empty" tspan.

Can anyone shed any light on this or have any workaround?

Cheers,
Michael

Command:
inkscape -f tspantest.svg -A tspantest.pdf

Full SVG:

Code: Select all

<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="524" height="743">
<text x="44" y="208" width="414.00" height="470.00" fill="#744949" font-color="#744949" style="font-size: 26px; font-family: Arial; text-anchor: middle;" transform="matrix(1,0,0,1,8,20)">
<tspan id="text001-001" x="251" dy="" xml:space="preserve">1</tspan>
<tspan id="text001-002" x="251" dy="30" xml:space="preserve"> </tspan>
<tspan id="text001-003" x="251" dy="30" xml:space="preserve">2</tspan>
<tspan id="text001-004" x="251" dy="30" xml:space="preserve">3</tspan>
</text>
<rect x="44" y="184" width="240.5" height="161.27999999999997" fill="none" stroke="#ff0000" style="stroke-dasharray: 5px, 5px;" transform="matrix(1,0,0,1,8,20)"></rect>
</svg>
Attachments
tspantest.pdf
outputted incorrect PDF
(5.22 KiB) Downloaded 163 times

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Converting to PDF: Empty tspan missing

Postby brynn » Fri Mar 06, 2015 12:48 pm

This is not a question we've seen much. For me, I've never seen this question, and have no idea the answer. But I just wanted to suggest that you might want to try posting on the Inkscape user mailing list or maybe even development list. (https://inkscape.org/en/community/mailing-lists/) Or someone might happen to reply in LP Answers (Help menu > Ask us a question). Or there's also IRC (which I find is a bit hit and miss, but can't hurt to try) https://inkscape.org/en/community/discussion/


Return to “Help with using Inkscape”