def __init__(self, text, font, color, width, padding=2.0, justify=solidfuel.constants.CENTER): VBox.__init__(self, padding=padding, justify=justify) final_lines = self._splitlines(text, font, width) for x in final_lines: if len(x): self.addChild(Text(font, x, color)) else: s = Box() s.h = font.get_height() self.addChild(s) self.pack()