Page 1 of 1

Write text with imagemagick

Posted: 2016-08-22T04:30:19-07:00
by mariusturcu01
Hi!
I try to create a image with text and replace the text from a svg file with the image, but i have some problems regarding the distance between letters.
The font is Times New Roman, the font size is the same but still the result is different.
This the command i have runned:

convert -size 1188.2661328125x26.18 xc:transparent -kerning -0 -font 'path_to_font' -pointsize 28.56 -fill "cmyk(0,0,100%,20%)" -colorspace CMYK -gravity South -draw "text 0,0 'DOubleclicktochangetextasdasjkdfhaskfjsgdhfjkshdfjskldhfskjdfhskjdfhskjdfhksjdjfhjkiiidsjijfsdkfdddd'" "path_to_saved_image";

And this is how result is looking:
-with black color is the text from svg-file
-width green is the image with text
Image

You have some ideas?

Re: Write text with imagemagick

Posted: 2016-08-22T05:02:26-07:00
by snibgo
"-draw" and SVG probably use different code for rasterising text. If you want two pieces of text to align exactly, you must use the same command to write them both.