From 700542e74ad3ba61a39a4a18aa0a1837d832a7d1 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 20 Dec 2020 10:55:55 +0530 Subject: [PATCH] More stupid PyQt enums --- src/calibre/gui2/convert/docx_output.py | 2 +- src/calibre/gui2/convert/pdf_output.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/calibre/gui2/convert/docx_output.py b/src/calibre/gui2/convert/docx_output.py index e1ac7b7c7d..932ca92d64 100644 --- a/src/calibre/gui2/convert/docx_output.py +++ b/src/calibre/gui2/convert/docx_output.py @@ -27,7 +27,7 @@ class PluginWidget(Widget): self.opt_docx_page_size.addItem(x) self.initialize_options(get_option, get_help, db, book_id) - self.layout().setFieldGrowthPolicy(self.layout().ExpandingFieldsGrow) + self.layout().setFieldGrowthPolicy(QFormLayout.FieldGrowthPolicy.ExpandingFieldsGrow) def setupUi(self, *a): self.l = l = QFormLayout(self) diff --git a/src/calibre/gui2/convert/pdf_output.py b/src/calibre/gui2/convert/pdf_output.py index 5c98b19442..3bb98534a6 100644 --- a/src/calibre/gui2/convert/pdf_output.py +++ b/src/calibre/gui2/convert/pdf_output.py @@ -40,8 +40,8 @@ class PluginWidget(Widget, Ui_Form): self.opt_pdf_standard_font.addItem(x) self.initialize_options(get_option, get_help, db, book_id) - self.layout().setFieldGrowthPolicy(self.layout().ExpandingFieldsGrow) - self.template_box.layout().setFieldGrowthPolicy(self.layout().AllNonFixedFieldsGrow) + self.layout().setFieldGrowthPolicy(QFormLayout.FieldGrowthPolicy.ExpandingFieldsGrow) + self.template_box.layout().setFieldGrowthPolicy(QFormLayout.FieldGrowthPolicy.AllNonFixedFieldsGrow) self.profile_size_toggled() def profile_size_toggled(self):