Ciao,
how can I stretch a text to fit in a box both with width and height automatic values?
I use windows command scripts
Thanks
Marco
[SOLVED] Stretch text to fit text box
[SOLVED] Stretch text to fit text box
Last edited by iltomma on 2015-06-30T03:29:57-07:00, edited 1 time in total.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Stretch text to fit text box
see label: or caption at http://www.imagemagick.org/Usage/text/
Re: Stretch text to fit text box
thanks for reply, but with Label and Caption if I use "-size 200x" and I have the text box 200x400, the font change only the widht and not the height.
examples:
my text box is 300x50
my text it "first test"
if I use "-size 300x" the width is automatically stretch to 300 but not for the height
if I use "-size x50" the height is automatically stretch to 50 but the width no, it's shorter
Maybe another possibility is to generate a text image and then resize the image and composite with the background image, but I don't know if the quality is ok
grazie
marco
examples:
my text box is 300x50
my text it "first test"
if I use "-size 300x" the width is automatically stretch to 300 but not for the height
if I use "-size x50" the height is automatically stretch to 50 but the width no, it's shorter
Maybe another possibility is to generate a text image and then resize the image and composite with the background image, but I don't know if the quality is ok
grazie
marco
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Stretch text to fit text box
I don't understand what you want to do.
Perhaps you want to make some text exactly fill a given height and width.
If so, then make the text too large, then resize to exactly those dimensions.
Perhaps you want to make some text exactly fill a given height and width.
If so, then make the text too large, then resize to exactly those dimensions.
snibgo's IM pages: im.snibgo.com
Re: Stretch text to fit text box
Ciao,
I need to stretch both widht and height at the same time, and discard the text aspect ratio
I uploaded a image of what I need
http://imageshack.com/a/img673/2692/fgLwQn.png
thanks
Marco
I need to stretch both widht and height at the same time, and discard the text aspect ratio
I uploaded a image of what I need
http://imageshack.com/a/img673/2692/fgLwQn.png
thanks
Marco
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Stretch text to fit text box
Code: Select all
convert -pointsize 100 label:"TEXT TO FIT" -trim +repage -resize 200x50! x.png
snibgo's IM pages: im.snibgo.com
Re: Stretch text to fit text box
yessssss!!!!!
Thankyou very much!!
Marco
Thankyou very much!!
Marco