Extend colour label widget to accept two colour states

This commit is contained in:
Veronica Berglyd Olsen
2024-06-18 22:41:29 +02:00
parent f7d0adad1b
commit 869cdd2fb0
10 changed files with 46 additions and 26 deletions
+1 -1
View File
@@ -75,7 +75,7 @@ class GuiAbout(NDialog):
# Credits
self.lblCredits = NColourLabel(
self.tr("Credits"), scale=1.6, parent=self, bold=True
self.tr("Credits"), self, scale=1.6, bold=True
)
self.txtCredits = QTextBrowser(self)
+1 -1
View File
@@ -58,7 +58,7 @@ class GuiDocMerge(NDialog):
self.headLabel.setFont(SHARED.theme.guiFontB)
self.helpLabel = NColourLabel(
self.tr("Drag and drop items to change the order, or uncheck to exclude."),
SHARED.theme.helpText, parent=self, wrap=True
self, color=SHARED.theme.helpText, wrap=True
)
iPx = SHARED.theme.baseIconHeight
+1 -1
View File
@@ -62,7 +62,7 @@ class GuiDocSplit(NDialog):
self.headLabel.setFont(SHARED.theme.guiFontB)
self.helpLabel = NColourLabel(
self.tr("Select the maximum level to split into files."),
SHARED.theme.helpText, parent=self, wrap=True
self, color=SHARED.theme.helpText, wrap=True
)
# Values
+2 -2
View File
@@ -66,8 +66,8 @@ class GuiPreferences(NDialog):
# Title
self.titleLabel = NColourLabel(
self.tr("Preferences"), SHARED.theme.helpText,
parent=self, scale=NColourLabel.HEADER_SCALE, indent=CONFIG.pxInt(4)
self.tr("Preferences"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE, indent=CONFIG.pxInt(4)
)
# Search Box
+5 -5
View File
@@ -76,8 +76,8 @@ class GuiProjectSettings(NDialog):
# Title
self.titleLabel = NColourLabel(
self.tr("Project Settings"), SHARED.theme.helpText,
parent=self, scale=NColourLabel.HEADER_SCALE, indent=CONFIG.pxInt(4)
self.tr("Project Settings"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE, indent=CONFIG.pxInt(4)
)
# SideBar
@@ -345,7 +345,7 @@ class _StatusPage(NFixedPage):
# Title
self.pageTitle = NColourLabel(
pageLabel, SHARED.theme.helpText, parent=self,
pageLabel, self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE
)
@@ -637,8 +637,8 @@ class _ReplacePage(NFixedPage):
# Title
self.pageTitle = NColourLabel(
self.tr("Text Auto-Replace for Preview and Build"),
SHARED.theme.helpText, parent=self, scale=NColourLabel.HEADER_SCALE
self.tr("Text Auto-Replace for Preview and Build"), self,
color=SHARED.theme.helpText, scale=NColourLabel.HEADER_SCALE
)
# List Box
+1 -1
View File
@@ -69,7 +69,7 @@ class GuiWordList(NDialog):
# Header
self.headLabel = NColourLabel(
self.tr("Project Word List"), SHARED.theme.helpText, parent=self,
self.tr("Project Word List"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE
)