mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-04-28 08:53:55 +02:00
Fix #1858779 [Fails to load KIPEO plugin](https://bugs.launchpad.net/calibre/+bug/1858779)
This commit is contained in:
parent
7474547bd2
commit
7a16568127
1 changed files with 1 additions and 1 deletions
|
|
@ -20,7 +20,6 @@
|
|||
QCheckBox, pyqtSignal, QDoubleSpinBox, QComboBox, QLabel, QFont, QApplication,
|
||||
QFontComboBox, QPushButton, QSizePolicy, QHBoxLayout, QGroupBox,
|
||||
QToolButton, QVBoxLayout, QSpacerItem, QTimer)
|
||||
from PyQt5.QtWebEngineWidgets import QWebEngineSettings
|
||||
|
||||
from calibre import prepare_string_for_xml
|
||||
from calibre.utils.localization import get_lang
|
||||
|
|
@ -345,6 +344,7 @@ def __init__(self, parent=None):
|
|||
self.setLayout(l)
|
||||
|
||||
def default_font(which):
|
||||
from PyQt5.QtWebEngineWidgets import QWebEngineSettings
|
||||
s = QWebEngineSettings.defaultSettings()
|
||||
which = getattr(s, {'serif': 'SerifFont', 'sans': 'SansSerifFont', 'mono': 'FixedFont'}[which])
|
||||
return s.fontFamily(which)
|
||||
|
|
|
|||
Loading…
Reference in a new issue