2

I've tried my best troubleshooting and I'm still coming up short. Basically, just trying to convert a svg to png and the font is not rendering. I have the font installed on my machine; I've added all the fonts I have on my machine to a 'type.xml' document like some have said. I updated my imagemagick to use rsvg instead of msvg too.

Here's the command I'm using: $ /usr/local/bin/rsvg-convert ~/desktop/example.svg -o ~/desktop/example.png

I attached the svg code along with the my current png.enter image description here

<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 18.1.1, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
 viewBox="0 0 500 500" enable-background="new 0 0 500 500" xml:space="preserve">
<g>
<path d="M242.3,171.9c0.1,2.1,0.6,3.9,1.2,5.5c3.9,0.7,8.8-1.4,12.6,0.2c0.9-2.6,1.1-5.9,1.2-8.9c0.1-1.7,0.2-3.4,0.4-4.6
 c0.6-3.7,1.1-7.1,0.2-9.8c-0.3,0-0.5,0-0.8,0.2c-0.2,0.2-0.5,0.3-0.7,0.3c-0.9,0.3-1.7,0.8-2.7,0.6c-0.1-0.1-0.3-0.4-0.4-0.5
 c-1.3,0-2.5,0-3.7,0c-0.2,0-0.4,0.1-0.5,0c-0.2-0.2-0.5-0.1-0.7-0.1c-0.2-0.1-0.4-0.2-0.7-0.2c-0.2,0-0.4,0-0.6,0.2
 c-0.2,0.2-0.4,0.3-0.6,0.2c-0.5-0.4-1.1,0-1.5-0.4c-0.7,0.1-1.4-0.4-2.2-0.4c0,0-0.1,0-0.1,0C241.7,159.5,241.9,166.4,242.3,171.9z
 "/>
<g>
 <path d="M242.1,153.8c-0.1,0-0.1,0-0.1,0c-0.1-0.3-0.1-0.5-0.1-0.8c-0.8-0.4-1.5-1.2-1.7-2.3c-0.1-0.1-0.2-0.3-0.3-0.4
  c-0.3-0.3-0.5-0.7-0.6-1.1c-0.4-0.4-0.8-0.8-1.3-1.2c-0.3-0.3-0.6-0.6-1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0,32-15.9,51.7-37.1,51.7c-5.1,0-11.3-2.4-11.3-8.7
 c0-12.3,20.2-35.1,46.6-52.1c-0.5-6.6-1.4-13.1-2.5-19.8c-15.9,15-28.2,33.6-41.6,33.6c-4.8,0-10-2.1-10-8.1
 c0-13.5,19-25.9,32.5-33.9c5-2.9,10.9-6.3,16.7-10.2c-0.4-4.2-0.6-8.5-0.6-13c0-24.1,11.4-54.3,30.3-54.3c7.8,0,10.9,7.3,10.9,14.9
 c0,21.5-18.6,38.8-37.6,51.8c0.1,3.9,0.3,7.5,0.6,11.2c9.7-7.1,21.1-12.4,34.9-12.4c2.2,0,4.4,0.2,6.7,0.5l-0.3,1.6
 c-1.4-0.2-2.7-0.2-4.1-0.2c-14.6,0-26.3,7.5-36.6,16.7c0.6,7,1.4,13.7,1.9,20.5c18.7-11.7,40.4-20.5,60.2-20.5
 c9,0,26.5,1.7,26.5,14.6c0,19.5-28.4,32.1-50.5,32.1c-8.7,0-17.6-1.6-26-5.1L247.5,337.9z M231.9,293.3c-0.5-3.6-1-7.2-1.3-10.9
 c-5.3,3.5-10.6,6.7-15.3,9.5c-10.8,6.4-32.4,20-32.4,33c0,4,3,6.8,7.1,6.8C200,331.7,212.2,308.9,231.9,293.3z M235.4,321.6
 c-25.5,16.8-44.8,38.8-44.8,49.6c0,3.8,3.2,6.3,7.5,6.3c18.7,0,37.6-23.8,37.6-49.3C235.6,326,235.5,323.9,235.4,321.6z
  M233.6,278.9c18.1-12.6,36-29.9,36-50.5c0-5.1-1.9-13.2-8.6-13.2c-17.5,0-27.5,40.6-27.5,61.7V278.9z"/>
</g>
<text transform="matrix(1 0 0 1 93.4995 329.5063)" font-family="'Spinnaker-Regular'" font-size="114.694">S</text>
<text transform="matrix(1 0 0 1 328.4995 329.5063)" font-family="'Spinnaker-Regular'" font-size="114.694">J</text>
</svg>
thizzle
  • 43
  • 5
  • The command you are using doesn't look like any ImageMagick commands I know? If you are using ImageMagick, have you tried `identify -list font` to see what fonts it knows about? Have you seen my post here... http://stackoverflow.com/questions/24696433/why-font-list-is-empty-for-imagemagick/24701602#24701602 – Mark Setchell Mar 13 '15 at 19:25
  • Added the type.xml file into the .magick directory. Used 'identify -list font' and all the fonts correctly appear in the list but when I use this command: /usr/local/bin/convert ~/desktop/example.svg ~/desktop/example.png, the same thing happens. Everything appears correctly except the font - it uses some basic sans serif font. – thizzle Mar 16 '15 at 17:51

0 Answers0