Fix font handling in manuscript tool

This commit is contained in:
Veronica Berglyd Olsen
2024-05-20 17:13:10 +02:00
parent 774437f7bb
commit 0b999bd726
6 changed files with 19 additions and 32 deletions
+1 -1
View File
@@ -76,7 +76,7 @@ SETTINGS_TEMPLATE = {
"text.includeBodyText": (bool, True),
"text.ignoredKeywords": (str, ""),
"text.addNoteHeadings": (bool, True),
"format.textFont": (str, CONFIG.textFont),
"format.textFont": (str, CONFIG.textFont.family()),
"format.textSize": (int, 12),
"format.lineHeight": (float, 1.15, 0.75, 3.0),
"format.justifyText": (bool, False),
+1 -1
View File
@@ -288,7 +288,7 @@ class NWBuildDocument:
textFont = self._build.getStr("format.textFont")
textSize = self._build.getInt("format.textSize")
fontFamily = textFont or CONFIG.textFont
fontFamily = textFont or CONFIG.textFont.family()
bldFont = QFont(fontFamily, textSize)
fontInfo = QFontInfo(bldFont)
textFixed = fontInfo.fixedPitch()