>I'm having a hard time drawing a border around an image.
>The image actually /does/ have a white border (width: 100 px)
>already, but I would like IM to draw an additional small, grey line
>inside this white area. How do I go about there? I'm actually a bit
>unsure about the proper syntax.


There are two ways.

1) Find the coordinates in the upper left corner and lower right 
corner within the white area from the dimensions of the image and the 
width of the white border where you want to draw the gray border, 
then just draw a rectangle with some strokewidth and stroke gray and 
-fill none

convert image -fill none -stroke gray -strokewidth 10 -draw 
"rectangle $x1,$y1 $x2,$y2" result

2) Use -shave to remove 50 pixels around the image, then use 
-bordercolor gray -border XX to add your gray border, then use 
-bordercolor white -border 50 to add another 50 pixels (or whatever 
you want) of white around the gray border.

convert image -shave 50x50 -bordercolor gray -border 10 -bordercolor 
white -border 50 result


Fred
_______________________________________________
Magick-users mailing list
[email protected]
http://studio.imagemagick.org/mailman/listinfo/magick-users

Reply via email to