Page 1 of 1

Posted: 2006-12-19T19:29:23-07:00
by anthony
See http://www.cit.gu.edu.au/~anthony/graph ... k/#windows
When you have an example it would be useful to send it to me so I can include it in that section. I am NOT a windows user so have to relay on others for this part.

Posted: 2006-12-19T20:04:30-07:00
by el_supremo
I couldn't get %f to work with the text subcommand of "draw" (even when I added a coordinate after the text subcommand). But I could get it to work with the annotate command. You also have to put two percents in the string so that DOS doesn't interpret %f as a variable name.

Try a command like this:

Code: Select all

mogrify -size 600x400 -font Arial -pointsize 20 -gravity east -fill black -annotate +0+0 "Name of the file : %%f" logo1.jpg
You'll have to play with the coordinates +0+0 to put the text where you want it.

Pete

Posted: 2006-12-19T20:12:31-07:00
by anthony
Escapes and newlines are no longer usable from -draw text, as it interfers with IM's handling of SVG images. Annotate is the correct way of 'drawing' these complexities.

Posted: 2006-12-20T16:29:28-07:00
by anthony
I am glad it is now working for you..

Just to recap..
Escapes and newlines are no longer usable from -draw text, as it interfers with IM's handling of SVG images. Annotate is the correct way of 'drawing' these complexities.


Also from Im Examples, Text to Image, Draw...
As of IM version 6.2.4, the "-draw text" operation no longer understands the use of '\n' as meaning newline, or the use of percent '%' image information escapes. (See Drawing a Percent Bug).
These abilities, and problems, however remain available in the new IM v6 operator "-annotate". See the Annotate Text Drawing Operator below.


I also meantion this in the 'Percent Bug' page, and in other places in IM examples. Look for the special '!' warning notes for version differences and additions.