def textheight(self, txt, height=None, **kwargs): if height is None: height = 0 h = CanvasContext.textheight(self, unicode(txt), height) # todo: handle kwargs? return h