mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-09 08:43:10 +02:00
Prevent use of system Qt style on linux as it causes hangs/crashes
This commit is contained in:
parent
a22b5e10fe
commit
0d690f3225
2 changed files with 9 additions and 1 deletions
|
|
@ -1077,6 +1077,10 @@ def load_builtin_fonts(self, scan_for_fonts=False):
|
|||
def setup_styles(self, force_calibre_style):
|
||||
self.using_calibre_style = force_calibre_style or 'CALIBRE_IGNORE_SYSTEM_THEME' in os.environ or (
|
||||
gprefs['ui_style'] != 'system')
|
||||
if not iswindows and not isosx:
|
||||
# Force calibre style on linux as the system style causes
|
||||
# crashes/hangs in Qt
|
||||
self.using_calibre_style = True
|
||||
if self.using_calibre_style:
|
||||
self.load_calibre_style()
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@
|
|||
|
||||
from calibre import human_readable
|
||||
from calibre.ebooks.metadata.book.render import DEFAULT_AUTHOR_LINK
|
||||
from calibre.constants import isosx
|
||||
from calibre.constants import isosx, iswindows
|
||||
from calibre.ebooks.metadata.sources.prefs import msprefs
|
||||
from calibre.gui2 import default_author_link
|
||||
from calibre.gui2.dialogs.template_dialog import TemplateDialog
|
||||
|
|
@ -325,6 +325,10 @@ class ConfigWidget(ConfigWidgetBase, Ui_Form):
|
|||
|
||||
def genesis(self, gui):
|
||||
self.gui = gui
|
||||
if not isosx and not iswindows:
|
||||
self.label_widget_style.setVisible(False)
|
||||
self.opt_ui_style.setVisible(False)
|
||||
|
||||
db = gui.library_view.model().db
|
||||
|
||||
r = self.register
|
||||
|
|
|
|||
Loading…
Reference in a new issue