Use Color and Colour consistently in the code

This commit is contained in:
Veronica Berglyd Olsen
2025-01-22 00:42:45 +01:00
parent 41a32b4fe9
commit 23398f2f8a
18 changed files with 106 additions and 105 deletions
+1 -1
View File
@@ -773,7 +773,7 @@ class _PreviewWidget(QTextBrowser):
self.buildProgress.setVisible(False)
self.buildProgress.setMaximum(1)
self.buildProgress.setValue(0)
self.buildProgress.setColours(
self.buildProgress.setColors(
back=QColor(255, 255, 255, 224),
track=QColor(196, 196, 196, 128),
text=QColor(0, 0, 0)
+3 -3
View File
@@ -41,7 +41,7 @@ from novelwriter.common import describeFont, fontMatcher, qtAddAction, qtLambda
from novelwriter.constants import nwHeadFmt, nwKeyWords, nwLabels, nwStyles, trConst
from novelwriter.core.buildsettings import BuildSettings, FilterMode
from novelwriter.extensions.configlayout import (
NColourLabel, NFixedPage, NScrollableForm, NScrollablePage
NColorLabel, NFixedPage, NScrollableForm, NScrollablePage
)
from novelwriter.extensions.modified import (
NComboBox, NDoubleSpinBox, NIconToolButton, NSpinBox, NToolDialog
@@ -92,9 +92,9 @@ class GuiBuildSettings(NToolDialog):
)
# Title
self.titleLabel = NColourLabel(
self.titleLabel = NColorLabel(
self.tr("Manuscript Build Settings"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE, indent=4,
scale=NColorLabel.HEADER_SCALE, indent=4,
)
# Settings Name
+9 -9
View File
@@ -37,7 +37,7 @@ from PyQt6.QtWidgets import (
from novelwriter import SHARED
from novelwriter.common import formatTime, numberToRoman
from novelwriter.constants import nwUnicode
from novelwriter.extensions.configlayout import NColourLabel, NFixedPage, NScrollablePage
from novelwriter.extensions.configlayout import NColorLabel, NFixedPage, NScrollablePage
from novelwriter.extensions.modified import NNonBlockingDialog
from novelwriter.extensions.novelselector import NovelSelector
from novelwriter.extensions.pagedsidebar import NPagedSideBar
@@ -67,9 +67,9 @@ class GuiNovelDetails(NNonBlockingDialog):
)
# Title
self.titleLabel = NColourLabel(
self.titleLabel = NColorLabel(
self.tr("Novel Details"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE, indent=4,
scale=NColorLabel.HEADER_SCALE, indent=4,
)
# Novel Selector
@@ -188,9 +188,9 @@ class _OverviewPage(NScrollablePage):
super().__init__(parent=parent)
# Project Info
self.projLabel = NColourLabel(
self.projLabel = NColorLabel(
self.tr("Project"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE
scale=NColorLabel.HEADER_SCALE
)
self.projName = QLabel("", self)
@@ -212,9 +212,9 @@ class _OverviewPage(NScrollablePage):
self.projForm.setVerticalSpacing(4)
# Novel Info
self.novelLabel = NColourLabel(
self.novelLabel = NColorLabel(
self.tr("Selected Novel"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE
scale=NColorLabel.HEADER_SCALE
)
self.novelName = QLabel("", self)
@@ -302,9 +302,9 @@ class _ContentsPage(NFixedPage):
options = SHARED.project.options
# Title
self.contentLabel = NColourLabel(
self.contentLabel = NColorLabel(
self.tr("Table of Contents"), self, color=SHARED.theme.helpText,
scale=NColourLabel.HEADER_SCALE
scale=NColorLabel.HEADER_SCALE
)
# Contents Tree