[Image-SIG] problems with simple task.
Jim Tittsler
jwt-python@dskk.co.jp
Tue, 20 Jun 2000 10:11:00 +0900
On Mon, Jun 19, 2000 at 04:56:34PM -0400, Gregory Haley wrote:
> im = Image.new('RGB", (size, size))
> draw = ImageDraw.ImageDraw(im)
> bgcolor = (255, 0, 0) #should be red background
> fgcolor = (0, 0, 0) #should be black border
>
> im = draw.rectangle( [0,0, size, size], fill=bgcolor,
> outline=fgcolor )
Try making this line simply:
draw.rectangle( [0,0, size, size], fill=bgcolor, outline=fgcolor )
(You don't want to assign the result of the rectangle method to your 'im'
image object.)
http://www.pythonware.com/library/pil/handbook/imagedraw.htm
--
Jim Tittsler, Tokyo
Python Starship http://starship.python.net/crew/jwt/