Logo Search packages:      
Sourcecode: qa-assistant version File versions  Download package

def treetips::TreeTips::__treetip_show (   self,
  tree,
  xEvent,
  yEvent,
  ID 
) [private]

Show the treetip window.

Definition at line 168 of file treetips.py.

00168                                                       :
        '''Show the treetip window.'''
        if self.timeoutID != ID:
            return False
        pathReturn = tree.get_path_at_pos(xEvent, yEvent)
        model = tree.get_model()
        if pathReturn == None:
            self.path = None
        elif self.path != pathReturn[0]:
            self.path = pathReturn[0]
            rowIter = model.get_iter(self.path)
            text = model.get_value(rowIter, self.column)
            self.active_tips_data = text
            if not text:
                self.tip_label.set_text('')
                return False
            self.tip_label.set_text(text)
            x, y = self.tip_label.size_request()
            self.tip_window.resize(x, y)
            windowWidth, windowHeight = self.tip_window.get_size()
            cellInfo = tree.get_cell_area(self.path, pathReturn[1])
            x, y = self.__compute_tooltip_position(cellInfo, windowWidth,
                    windowHeight)
            self.tip_window.move(int(x), int(y))
            self.tip_window.show_all()

        return False

    def __compute_tooltip_position(self, cellInfo, popupWidth, popupHeight):


Generated by  Doxygen 1.6.0   Back to index