[reportlab-users] Image inside paragraph not appearing

Stevens, Ian IStevens at globeandmail.com
Mon Jan 28 12:30:18 EST 2008


Thanks, it's working now that I'm using trunk. Is there any way to
honour spacing to the right of the image? Padding is applied to the
left of the image, but not to the right even if there are spaces after
the image. This is evident in figure A-49 in the user guide as well.

Thanks,
Ian.


> -----Original Message-----

> From: reportlab-users-bounces at reportlab.com

> [mailto:reportlab-users-bounces at reportlab.com] On Behalf Of

> Robin Becker

> Sent: Saturday, January 26, 2008 4:33 AM

> To: Support list for users of Reportlab software

> Subject: Re: [reportlab-users] Image inside paragraph not appearing

>

> Stevens, Ian wrote:

> > Is this code working for anyone? I've tried this on a few

> different

> > machines with the same results.

> >

> > thanks,

> > Ian.

> >

> .......

> the img tag was added recently, but we have a test in the

> reportlab/tests area called test_platypus_paragraphs.py; if

> that test is run then the result file called

> test_platypus_paragraphs_autoleading.pdf

> contains paragraphs with embedded images.

>

> > ________________________________

> >

> > From: reportlab-users-bounces at reportlab.com

> > [mailto:reportlab-users-bounces at reportlab.com] On Behalf Of

> Stevens, Ian

> > Sent: Thursday, January 24, 2008 4:20 PM

> > To: reportlab-users at reportlab.com

> > Subject: [reportlab-users] Image inside paragraph not appearing

> >

> >

> >

> > I'm having trouble getting images to appear within a

> Paragraph when I

> > use the <img/> tag:

> >

> > 1 from reportlab.lib.styles import ParagraphStyle

> > 2 from reportlab.pdfgen.canvas import Canvas

> > 3 from reportlab.platypus import Paragraph, Frame

> > 4

> > 5 c = Canvas('test.pdf')

> > 6 f = Frame(100, 700, 400, 100, showBoundary=True)

> > 7 f.addFromList([Paragraph('This is a test image: <img

> > src="test.gif" height="5"/>. That was a test.',

> > ParagraphStyle(None))],

> > c)

> > 8 c.save()

> >

> > Where test.gif is created with the following ImageMagick

> > command:

> >

> > echo this is a test | convert -background yellow

> -page 200x50

> > text:- test.gif

> >

> > The image will not display. What am I missing?

> >

> > thanks,

> > Ian.

> >

> >

> >

> >

> >

> ----------------------------------------------------------------------

> > --

> >

> > _______________________________________________

> > reportlab-users mailing list

> > reportlab-users at reportlab.com

> > http://two.pairlist.net/mailman/listinfo/reportlab-users

>

>

> --

> Robin Becker

> _______________________________________________

> reportlab-users mailing list

> reportlab-users at reportlab.com

> http://two.pairlist.net/mailman/listinfo/reportlab-users

>



More information about the reportlab-users mailing list