reportlab/platypus/flowables.py
changeset 2694 dd0ea6474ea0
parent 2662 0a5217162c3f
child 2695 feb999d5dbd1
equal deleted inserted replaced
2693:3c61a57aecd1 2694:dd0ea6474ea0
   742             I = c._ptoinfo
   742             I = c._ptoinfo
   743             if I not in I2W.keys():
   743             if I not in I2W.keys():
   744                 T = I.trailer
   744                 T = I.trailer
   745                 Hdr = I.header
   745                 Hdr = I.header
   746                 tW, tH = _listWrapOn(T, availWidth, self.canv)
   746                 tW, tH = _listWrapOn(T, availWidth, self.canv)
   747                 tSB = T[0].getSpaceBefore()
   747                 if len(T):  #trailer may have no content
       
   748                     tSB = T[0].getSpaceBefore()
       
   749                 else:
       
   750                     tSB = 0
   748                 I2W[I] = T,tW,tH,tSB
   751                 I2W[I] = T,tW,tH,tSB
   749             else:
   752             else:
   750                 T,tW,tH,tSB = I2W[I]
   753                 T,tW,tH,tSB = I2W[I]
   751             _, h = c.wrapOn(canv,availWidth,0xfffffff)
   754             _, h = c.wrapOn(canv,availWidth,0xfffffff)
   752             if x:
   755             if x: