|
|
|
|
@ -186,8 +186,9 @@ class PayToEdit(ScanQRTextEdit):
|
|
|
|
|
self.update_size() |
|
|
|
|
|
|
|
|
|
def update_size(self): |
|
|
|
|
lineHeight = QFontMetrics(self.document().defaultFont()).height() |
|
|
|
|
docHeight = self.document().size().height() |
|
|
|
|
h = docHeight*17 + 11 |
|
|
|
|
h = docHeight * lineHeight + 11 |
|
|
|
|
if self.heightMin <= h <= self.heightMax: |
|
|
|
|
self.setMinimumHeight(h) |
|
|
|
|
self.setMaximumHeight(h) |
|
|
|
|
|