eric7/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py

branch
eric7
changeset 8319
ea11a3948f40
parent 8318
962bce857696
child 8322
b422b4e77d19
diff -r 962bce857696 -r ea11a3948f40 eric7/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py
--- a/eric7/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py	Sun May 16 20:07:24 2021 +0200
+++ b/eric7/Preferences/ConfigurationPages/EditorHighlightingStylesPage.py	Mon May 17 19:58:15 2021 +0200
@@ -23,12 +23,6 @@
 
 import UI.PixmapCache
 
-try:
-    MonospacedFontsOption = QFontDialog.FontDialogOption.MonospacedFonts
-except AttributeError:
-    MonospacedFontsOption = QFontDialog.FontDialogOptions(0x10)
-NoFontsOption = QFontDialog.FontDialogOptions(0)
-
 
 class EditorHighlightingStylesPage(ConfigurationPageBase,
                                    Ui_EditorHighlightingStylesPage):
@@ -355,9 +349,9 @@
         
         style, substyle = self.__currentStyles()
         options = (
-            MonospacedFontsOption
+            QFontDialog.FontDialogOption.MonospacedFonts
             if self.monospacedButton.isChecked() else
-            NoFontsOption
+            QFontDialog.FontDialogOption(0)
         )
         font, ok = QFontDialog.getFont(self.lexer.font(style, substyle), self,
                                        "", options)

eric ide

mercurial