118 |
118 |
119 width = self.header.boundingRect().width() |
119 width = self.header.boundingRect().width() |
120 height = self.header.boundingRect().height() |
120 height = self.header.boundingRect().height() |
121 if self.classes: |
121 if self.classes: |
122 width = max(width, self.classes.boundingRect().width()) |
122 width = max(width, self.classes.boundingRect().width()) |
123 height = height + self.classes.boundingRect().height() |
123 height += self.classes.boundingRect().height() |
124 self.setSize(width + 2 * self.margin, height + 2 * self.margin) |
124 self.setSize(width + 2 * self.margin, height + 2 * self.margin) |
125 |
125 |
126 def setModel(self, model): |
126 def setModel(self, model): |
127 """ |
127 """ |
128 Public method to set the module model. |
128 Public method to set the module model. |