Page 1 of 1

Creating text image from a font file

Posted: 2008-10-20T05:01:32-07:00
by marco_tv
I have to create a png image extarcting a single char from a font file (ttf)

For example i create a png file rappresenting the letter A of a particular font.
I use this command: convert -font arial.ttf label:a a.png
I obtain this png:
Image




Then i have to elaborate this png and at the end i have to join more png (char) using the comand:
montage a.png b.png -mode Concatenate -tile x1 ab.png

if i view the joined png (ab.png) with ImageMagick Display i note that there are two rows and not one.
Image

I think that the bottom row is the text field of png. The problem is that I would like to have a single row and not double. Where is the mistake? I suppose in the convert command

Re: Creating text image from a font file

Posted: 2008-10-20T05:25:33-07:00
by Bonzo
Have you tried:

Code: Select all

convert a.png b.png +append ab.png

Re: Creating text image from a font file

Posted: 2008-10-20T05:50:31-07:00
by marco_tv
great!!
thank you very much, now it's ok!