def _setup_ui(self): hbox = QtGui.QVBoxLayout(self) self.setLayout(hbox) self.status_label = QtGui.QLabel("(No status has been read.)") self.status_label.setTextInteractionFlags(QtCore.Qt.TextSelectableByMouse) self.status_label.setWordWrap(True) self.status_label.setAlignment(QtCore.Qt.AlignTop) status_scroll_area = QtGui.QScrollArea() status_scroll_area.setMaximumSize(QtCore.QSize(100000, 100)) status_scroll_area.setWidgetResizable(True) status_scroll_area.setWidget(self.status_label) hbox.addWidget(status_scroll_area) self.status = None self.statusTrigger.connect(self.updateStatus)
def scaleSize(self): size = self.form.scrollArea.widget().frameSize() return QtCore.QSize(size.width(), size.height() * self.scale_factor)