Move project tree preferences to their own section

This commit is contained in:
Veronica Berglyd Olsen
2025-02-06 17:24:31 +01:00
parent 589bc7c313
commit aa84d998a0
3 changed files with 66 additions and 43 deletions
+14 -3
View File
@@ -178,16 +178,23 @@ def testDlgPreferences_Settings(qtbot, monkeypatch, nwGUI, fncPath, tstPaths):
mp.setattr(QFontDialog, "getFont", lambda *a, **k: (QFont(), True))
prefs.nativeFont.setChecked(False) # Use Qt font dialog
prefs.textFontButton.click()
prefs.emphLabels.setChecked(False)
prefs.showFullPath.setChecked(False)
prefs.incNotesWCount.setChecked(False)
assert CONFIG.guiSyntax != "default_dark"
assert CONFIG.textFont.family() != ""
assert CONFIG.emphLabels is True
assert CONFIG.showFullPath is True
assert CONFIG.incNotesWCount is True
# Project View
prefs.iconColTree.setCurrentData("faded", "default")
prefs.iconColDocs.setChecked(True)
prefs.emphLabels.setChecked(False)
assert CONFIG.iconColTree == "theme"
assert CONFIG.iconColDocs is False
assert CONFIG.emphLabels is True
# Behaviour
prefs.autoSaveDoc.stepUp()
prefs.autoSaveProj.stepUp()
@@ -339,10 +346,14 @@ def testDlgPreferences_Settings(qtbot, monkeypatch, nwGUI, fncPath, tstPaths):
# Document Style
assert CONFIG.guiSyntax == "default_dark"
assert CONFIG.textFont == QFont()
assert CONFIG.emphLabels is False
assert CONFIG.showFullPath is False
assert CONFIG.incNotesWCount is False
# Project View
assert CONFIG.iconColTree == "faded"
assert CONFIG.iconColDocs is True
assert CONFIG.emphLabels is False
# Behaviour
assert CONFIG.autoSaveDoc == 31
assert CONFIG.autoSaveProj == 61