From 76d67dd0aaaf46f2339038fd3ba836b07db7767d Mon Sep 17 00:00:00 2001 From: Veronica Berglyd Olsen <1619840+vkbo@users.noreply.github.com> Date: Thu, 9 Nov 2023 19:04:36 +0100 Subject: [PATCH] Clean up build settings and update tests --- novelwriter/core/buildsettings.py | 2 -- novelwriter/core/tohtml.py | 5 ++++- tests/reference/coreTools_NewMinimal_nwProject.nwx | 2 +- tests/test_core/test_core_coretools.py | 2 ++ tests/test_tools/test_tools_manussettings.py | 3 --- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/novelwriter/core/buildsettings.py b/novelwriter/core/buildsettings.py index 931525ea..0698c2e0 100644 --- a/novelwriter/core/buildsettings.py +++ b/novelwriter/core/buildsettings.py @@ -64,7 +64,6 @@ SETTINGS_TEMPLATE = { "text.includeKeywords": (bool, False), "text.includeBodyText": (bool, True), "text.addNoteHeadings": (bool, True), - "format.buildLang": (str, "en_GB"), "format.textFont": (str, CONFIG.textFont), "format.textSize": (int, 12), "format.lineHeight": (float, 1.15, 0.75, 3.0), @@ -107,7 +106,6 @@ SETTINGS_LABELS = { "text.addNoteHeadings": QT_TRANSLATE_NOOP("Builds", "Add Titles for Notes"), "format.grpFormat": QT_TRANSLATE_NOOP("Builds", "Text Format"), - "format.buildLang": QT_TRANSLATE_NOOP("Builds", "Language"), "format.textFont": QT_TRANSLATE_NOOP("Builds", "Font Family"), "format.textSize": QT_TRANSLATE_NOOP("Builds", "Font Size"), "format.lineHeight": QT_TRANSLATE_NOOP("Builds", "Line Height"), diff --git a/novelwriter/core/tohtml.py b/novelwriter/core/tohtml.py index ac73418d..7443ed34 100644 --- a/novelwriter/core/tohtml.py +++ b/novelwriter/core/tohtml.py @@ -457,7 +457,10 @@ class ToHtml(Tokenizer): def _formatSynopsis(self, text: str) -> str: """Apply HTML formatting to synopsis.""" sSynop = self._localLookup("Synopsis") - return f"
{sSynop}: {text}
\n" + if self._genMode == self.M_PREVIEW: + return f"{sSynop}: {text}
\n" + else: + return f"{sSynop}: {text}
\n" def _formatComments(self, text: str) -> str: """Apply HTML formatting to comments.""" diff --git a/tests/reference/coreTools_NewMinimal_nwProject.nwx b/tests/reference/coreTools_NewMinimal_nwProject.nwx index 23a377f5..a38b56b0 100644 --- a/tests/reference/coreTools_NewMinimal_nwProject.nwx +++ b/tests/reference/coreTools_NewMinimal_nwProject.nwx @@ -7,7 +7,7 @@