'Display text in tooltip window'

def showtip(self, text):

    self.text = text
    if (self.tipwindow or (not self.text)):
        return
    (x, y, _cx, cy) = self.widget.bbox('insert')
    x = ((x + self.widget.winfo_rootx()) + 27)
    y = (((y + cy) + self.widget.winfo_rooty()) + 27)
    self.tipwindow = tw = Toplevel(self.widget)
    tw.wm_overrideredirect(1)
    tw.wm_geometry(('+%d+%d' % (x, y)))
    try:
        tw.tk.call('::tk::unsupported::MacWindowStyle', 'style', tw._w, 'help', 'noActivates')
    except TclError:
        pass
    label = Label(tw, text=self.text, justify=LEFT, background='#ffffe0', relief=SOLID, borderwidth=1, font=('tahoma', '8', 'normal'))
    label.pack(ipadx=1)
