Esempio n. 1
0
 def sizeHint(self):
     sz = QwtTextLabel.sizeHint(self)
     sz.setHeight(max([sz.height(), self.__data.icon.height()+4]))
     if self.__data.itemMode != QwtLegendData.ReadOnly:
         sz += buttonShift(self)
         sz = sz.expandedTo(QApplication.globalStrut())
     return sz
Esempio n. 2
0
 def sizeHint(self):
     sz = QwtTextLabel.sizeHint(self)
     sz.setHeight(max([sz.height(), self.__data.icon.height() + 4]))
     if self.__data.itemMode != QwtLegendData.ReadOnly:
         sz += buttonShift(self)
         sz = sz.expandedTo(QApplication.globalStrut())
     return sz
Esempio n. 3
0
 def sizeHint(self):
     """
     :return: a size hint
     """
     sz = QwtTextLabel.sizeHint(self)
     sz.setHeight(max([sz.height(), self.__data.icon.height() + 4]))
     if self.__data.itemMode != QwtLegendData.ReadOnly:
         sz += buttonShift(self)
     return sz