Mobile app version of vmapp.org
Login or Join
Sent7350415

: Why is my text messed up when converting a PDF to SVG? I'm trying to convert a PDF to a vector image so that I can display it online. When I convert it to SVG, it doesn't convert the font

@Sent7350415

Posted in: #Pdf #Svg #Vector

I'm trying to convert a PDF to a vector image so that I can display it online.
When I convert it to SVG, it doesn't convert the font glyphs correctly.
When I convert to SWF, it is perfect, but I would rather use SVG.

SVG Rendering (download link):


Click image for full size

PDF Rendering (download link):


Click image for full size

What is going on? Is SWF superior to SVG or is this because of a bad converter?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Sent7350415

1 Comments

Sorted by latest first Latest Oldest Best

 

@Pierce403

Why this is happening:

The PDF is embedding your font, the SVG is not. When I try and open the PDF in Illustrator, it yells at me for all the fonts I don't have installed:

The font CMBX10 is missing. Affected text will be displayed using a substitute font.
The font CMEX10 is missing. Affected text will be displayed using a substitute font.
The font CMMI10 is missing. Affected text will be displayed using a substitute font.
The font CMMI8 is missing. Affected text will be displayed using a substitute font.
The font CMR10 is missing. Affected text will be displayed using a substitute font.
The font CMR8 is missing. Affected text will be displayed using a substitute font.
The font CMSY10 is missing. Affected text will be displayed using a substitute font.
The font CMSY8 is missing. Affected text will be displayed using a substitute font.
The font CMTI10 is missing. Affected text will be displayed using a substitute font.
The font MSBM10 is missing. Affected text will be displayed using a substitute font.


Your SVG will just tell the rendering agent to grab whatever font is convenient, and in this case it makes your rendered output look crummy.

How you can fix it:

Option 1: Embed all those fonts in the SVG

Rather than explain how to do this, just go check the answer to this question: How do I embed Google Web Fonts into an SVG?

Option 2: Outline all the text

Assuming you're using Inkscape (since the SVG source code told me so), I believe all you'd have to do is select the text objects then use Path → Object to Path

This will make the file size considerably larger. I'd try Option 1 before this. Also, the text will no longer be editable.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme