[reportlab-users] Two flowables inline?

Andrés Maneiro andres.maneiro at gmail.com
Tue Apr 22 15:26:25 EDT 2008


Hi people,

i'm trying to insert two flowables inline (at same frame) but i don't
get it yet. By now, i have two flowables at same frame, first one on
top and other below it.

How i can insert them inline? and .. can flowables "float" inline? i
have seen some examples in user manual but i didn't see this issue
anyway.

br
/amaneiro

PD: my test code ...

from reportlab.pdfgen.canvas import Canvas
from reportlab.lib.units import inch, cm
from reportlab.platypus import Frame, Image
from reportlab.lib.pagesizes import A4

c = Canvas("test-inline.pdf")

origin = (0*cm, 0*cm)

story1 = []
story2 = []

f1 = Frame(origin[0], origin[1], A4[0], A4[1]/2, showBoundary=1)
f2 = Frame(origin[0], A4[1]/2, A4[0], A4[1]/2, showBoundary=1)

story1.append(Image("./prueba1.jpg",width=A4[0]/6,height=(135*A4[0]/6)/673))
story1.append(Image("./prueba1.jpg",width=A4[0]/6,height=(135*A4[0]/6)/673))

story2.append(Image("./prueba1.jpg"))
story2.append(Image("./prueba1.jpg"))

f1.addFromList(story1,c)
f2.addFromList(story2,c)
c.showPage()
c.save()


More information about the reportlab-users mailing list