[reportlab-users] image problems?
Gianni Olivieri -
reportlab-users@reportlab.com
Wed, 25 Feb 2004 19:19:14 +0100
Hallo,
I'm a new reportlab user... I've just installed the Reportlab library
on my Debian Linux... I've read the "user guide" and I've tried to do
something...
I've write this:
------------------------------------------------------------------------
#!/usr/bin/python2.3
#
#
import Image
from reportlab.pdfgen import canvas
im=Image.open("img1.jpg")
c = canvas.Canvas("test.pdf")
c.drawImage(im, 50, 50 )
c.showPage()
c.save()
------------------------------------------------------------------------
when I launch the program:
gianni@agarthi:~/report-lab$ ./image_test.py
Traceback (most recent call last):
File "./image_test.py", line 10, in ?
c.drawImage(im, 50, 50 )
File "/usr/lib/python2.3/site-packages/reportlab/pdfgen/canvas.py",
line 586, in drawImage
rawdata = image.getRGBData()
AttributeError: JpegImageFile instance has no attribute 'getRGBData'
what's wrong???
Bye :-)
--
Gianni Olivieri | Debian/GNU Linux
gianni@gnuthink.org | Linux registered user #333000
(8) It is more complicated than you think.
<RFC 1925 - Fundamental Truths of Networking>