svg-net / SVG

Fork of the ms svg library
http://svg-net.github.io/SVG/
Microsoft Public License
1.16k stars 474 forks source link

Converting from svg to png loses text #247

Open marvel420 opened 8 years ago

marvel420 commented 8 years ago

Hi -

First of all just praises for this tool from me. It has been really useful for me. Apart from that I am running into an issue where some of the "text" tag elements are not being rendered when I convert svg to png. Is this because of a known issue with the tool or something invalid passed in through my svg. Please advise.

Attached you will find the new png with missing images and what it should look like.

Thanks Akash

`<?xml version="1.0" encoding="UTF-8"?>

1 2 3 4 5 6 7 8 9 10 © 2016 Microsoft Corporation © 2016 HERE N IL AL NC CCRC / LPC ` ![right_image](https://cloud.githubusercontent.com/assets/17169168/17444766/c2232ce6-5b0f-11e6-9baf-5aa828a84540.png) ![wrong_image](https://cloud.githubusercontent.com/assets/17169168/17444782/e110d536-5b0f-11e6-9489-9f79e4d41a9d.png)
Cacxa commented 7 years ago

+1 Troubles with text Sample (created by Corel Draw) is here: https://yadi.sk/d/vLKtrObYxXeoC

tkowalczyk commented 7 years ago

I am also confirming this issue.

Cacxa commented 7 years ago

The text disappears if the glyphs for this text are described as \<path />, and not as the "d" attribute. Examples: Text created by CorelDraw 13 (loss of text): \<glyph unicode="e" horiz-adv-x="547">\<path d="M295.83 ... -117.661,38.9998z"/>\</glyph> Text created by CorelDraw 18 (correct text output): \<glyph unicode="e" horiz-adv-x="547" d="M295.83 ... -117.661,38.9998z"/>

Here is wrong and correct samples: https://yadi.sk/d/aha6AinA3FNHY7