Renamed all color names so they are shorter
This commit is contained in:
parent
9e51fdc932
commit
06f8f93f83
51 changed files with 423 additions and 440 deletions
|
|
@ -11,9 +11,9 @@ Rectangle {
|
|||
implicitWidth: childrenRect.width
|
||||
implicitHeight: childrenRect.height
|
||||
|
||||
color: Colors.colorSurfaceVariant
|
||||
color: Colors.mSurfaceVariant
|
||||
radius: Style.radiusMedium * scaling
|
||||
border.color: Colors.colorOutlineVariant
|
||||
border.color: Colors.mOutlineVariant
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
clip: true
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ Item {
|
|||
readonly property real scaling: Scaling.scale(screen)
|
||||
|
||||
property bool running: true
|
||||
property color color: Colors.colorPrimary
|
||||
property color color: Colors.mPrimary
|
||||
property int size: Style.baseWidgetSize * scaling
|
||||
property int strokeWidth: Style.borderThick * scaling
|
||||
property int duration: 1000
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ Rectangle {
|
|||
implicitWidth: childrenRect.width
|
||||
implicitHeight: childrenRect.height
|
||||
|
||||
color: Colors.colorSurface
|
||||
color: Colors.mSurface
|
||||
radius: Style.radiusMedium * scaling
|
||||
border.color: Colors.colorSurfaceVariant
|
||||
border.color: Colors.mSurfaceVariant
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,9 +18,9 @@ Rectangle {
|
|||
|
||||
width: 68 * scaling
|
||||
height: 92 * scaling
|
||||
color: flat ? "transparent" : Colors.colorSurface
|
||||
color: flat ? "transparent" : Colors.mSurface
|
||||
radius: Style.radiusSmall * scaling
|
||||
border.color: flat ? "transparent" : Colors.colorSurfaceVariant
|
||||
border.color: flat ? "transparent" : Colors.mSurfaceVariant
|
||||
border.width: flat ? 0 : Math.max(1, Style.borderThin * scaling)
|
||||
clip: true
|
||||
|
||||
|
|
@ -58,14 +58,14 @@ Rectangle {
|
|||
ctx.reset()
|
||||
ctx.lineWidth = 6 * root.scaling * contentScale
|
||||
// Track uses surfaceVariant for stronger contrast
|
||||
ctx.strokeStyle = Colors.colorSurface
|
||||
ctx.strokeStyle = Colors.mSurface
|
||||
ctx.beginPath()
|
||||
ctx.arc(cx, cy, r, start, endBg)
|
||||
ctx.stroke()
|
||||
// Value arc
|
||||
const ratio = Math.max(0, Math.min(1, root.value / 100))
|
||||
const end = start + (endBg - start) * ratio
|
||||
ctx.strokeStyle = Colors.colorPrimary
|
||||
ctx.strokeStyle = Colors.mPrimary
|
||||
ctx.beginPath()
|
||||
ctx.arc(cx, cy, r, start, end)
|
||||
ctx.stroke()
|
||||
|
|
@ -79,7 +79,7 @@ Rectangle {
|
|||
text: `${root.value}${root.suffix}`
|
||||
font.pointSize: Style.fontSizeMedium * scaling * contentScale
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
}
|
||||
|
||||
|
|
@ -89,8 +89,8 @@ Rectangle {
|
|||
width: 28 * scaling * contentScale
|
||||
height: width
|
||||
radius: width / 2
|
||||
color: Colors.colorSurface
|
||||
// border.color: Colors.colorPrimary
|
||||
color: Colors.mSurface
|
||||
// border.color: Colors.mPrimary
|
||||
// border.width: Math.max(1, Style.borderThin * scaling)
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
|
|
@ -102,7 +102,7 @@ Rectangle {
|
|||
text: root.icon
|
||||
font.family: "Material Symbols Outlined"
|
||||
font.pointSize: Style.fontSizeLargeXL * scaling * contentScale
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,13 +29,13 @@ ColumnLayout {
|
|||
text: label
|
||||
font.pointSize: Style.fontSizeMedium * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: description
|
||||
font.pointSize: Style.fontSizeSmall * scaling
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
wrapMode: Text.WordWrap
|
||||
}
|
||||
}
|
||||
|
|
@ -56,8 +56,8 @@ ColumnLayout {
|
|||
background: Rectangle {
|
||||
implicitWidth: 120 * scaling
|
||||
implicitHeight: preferredHeight
|
||||
color: Colors.colorSurface
|
||||
border.color: combo.activeFocus ? Colors.colorTertiary : Colors.colorOutline
|
||||
color: Colors.mSurface
|
||||
border.color: combo.activeFocus ? Colors.mTertiary : Colors.mOutline
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
radius: Style.radiusMedium * scaling
|
||||
}
|
||||
|
|
@ -97,8 +97,8 @@ ColumnLayout {
|
|||
}
|
||||
|
||||
background: Rectangle {
|
||||
color: Colors.colorSurfaceVariant
|
||||
border.color: Colors.colorOutline
|
||||
color: Colors.mSurfaceVariant
|
||||
border.color: Colors.mOutline
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
radius: Style.radiusMedium * scaling
|
||||
}
|
||||
|
|
@ -112,14 +112,14 @@ ColumnLayout {
|
|||
text: (combo.model.indexOf(modelData) >= 0 && combo.model.indexOf(
|
||||
modelData) < root.optionsLabels.length) ? root.optionsLabels[combo.model.indexOf(modelData)] : ""
|
||||
font.pointSize: Style.fontSizeMedium * scaling
|
||||
color: highlighted ? Colors.colorSurface : Colors.colorOnSurface
|
||||
color: highlighted ? Colors.mSurface : Colors.mOnSurface
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
||||
background: Rectangle {
|
||||
width: combo.width - Style.marginMedium * scaling * 3
|
||||
color: highlighted ? Colors.colorTertiary : "transparent"
|
||||
color: highlighted ? Colors.mTertiary : "transparent"
|
||||
radius: Style.radiusSmall * scaling
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,5 +6,5 @@ import qs.Services
|
|||
Rectangle {
|
||||
width: parent.width
|
||||
height: Math.max(1, Style.borderThin * scaling)
|
||||
color: Colors.colorOutline
|
||||
color: Colors.mOutline
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,9 +26,9 @@ Rectangle {
|
|||
implicitWidth: size
|
||||
implicitHeight: size
|
||||
|
||||
color: (root.hovering || showFilled) ? Colors.colorPrimary : "transparent"
|
||||
color: (root.hovering || showFilled) ? Colors.mPrimary : "transparent"
|
||||
radius: width * 0.5
|
||||
border.color: showBorder ? Colors.colorPrimary : "transparent"
|
||||
border.color: showBorder ? Colors.mPrimary : "transparent"
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
|
||||
NText {
|
||||
|
|
@ -43,7 +43,7 @@ Rectangle {
|
|||
"wght": (Font.Normal + Font.Bold) / 2.0
|
||||
}
|
||||
color: (root.hovering
|
||||
|| showFilled) ? Colors.colorOnPrimary : showBorder ? Colors.colorPrimary : Colors.colorOnSurface
|
||||
|| showFilled) ? Colors.mOnPrimary : showBorder ? Colors.mPrimary : Colors.mOnSurface
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
opacity: root.enabled ? Style.opacityFull : Style.opacityMedium
|
||||
|
|
|
|||
|
|
@ -10,11 +10,11 @@ Item {
|
|||
property string icon: ""
|
||||
property string text: ""
|
||||
property string tooltipText: ""
|
||||
property color pillColor: Colors.colorSurfaceVariant
|
||||
property color textColor: Colors.colorOnSurface
|
||||
property color iconCircleColor: Colors.colorPrimary
|
||||
property color iconTextColor: Colors.colorSurface
|
||||
property color collapsedIconColor: Colors.colorOnSurface
|
||||
property color pillColor: Colors.mSurfaceVariant
|
||||
property color textColor: Colors.mOnSurface
|
||||
property color iconCircleColor: Colors.mPrimary
|
||||
property color iconTextColor: Colors.mSurface
|
||||
property color collapsedIconColor: Colors.mOnSurface
|
||||
property real sizeMultiplier: 0.8
|
||||
property bool autoHide: false
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ RadioButton {
|
|||
implicitHeight: 20 * scaling
|
||||
radius: width * 0.5
|
||||
color: "transparent"
|
||||
border.color: root.checked ? Colors.colorPrimary : Colors.colorOnSurface
|
||||
border.color: root.checked ? Colors.mPrimary : Colors.mOnSurface
|
||||
border.width: 2
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
|
|
@ -23,7 +23,7 @@ RadioButton {
|
|||
implicitHeight: Style.marginSmall * scaling
|
||||
|
||||
radius: width * 0.5
|
||||
color: Qt.alpha(Colors.colorPrimary, root.checked ? 1 : 0)
|
||||
color: Qt.alpha(Colors.mPrimary, root.checked ? 1 : 0)
|
||||
}
|
||||
|
||||
Behavior on border.color {
|
||||
|
|
|
|||
|
|
@ -27,13 +27,13 @@ Slider {
|
|||
width: root.availableWidth
|
||||
height: implicitHeight
|
||||
radius: height / 2
|
||||
color: Colors.colorSurface
|
||||
color: Colors.mSurface
|
||||
|
||||
Rectangle {
|
||||
id: activeTrack
|
||||
width: root.visualPosition * parent.width
|
||||
height: parent.height
|
||||
color: Colors.colorPrimary
|
||||
color: Colors.mPrimary
|
||||
radius: parent.radius
|
||||
}
|
||||
|
||||
|
|
@ -43,7 +43,7 @@ Slider {
|
|||
width: knobDiameter + cutoutExtra
|
||||
height: knobDiameter + cutoutExtra
|
||||
radius: width / 2
|
||||
color: root.cutoutColor !== undefined ? root.cutoutColor : Colors.colorSurface
|
||||
color: root.cutoutColor !== undefined ? root.cutoutColor : Colors.mSurface
|
||||
x: Math.max(0, Math.min(parent.width - width,
|
||||
root.visualPosition * (parent.width - root.knobDiameter) - cutoutExtra / 2))
|
||||
y: (parent.height - height) / 2
|
||||
|
|
@ -56,12 +56,12 @@ Slider {
|
|||
x: root.leftPadding + root.visualPosition * (root.availableWidth - width)
|
||||
y: root.topPadding + root.availableHeight / 2 - height / 2
|
||||
|
||||
// Subtle shadow for a more polished look (keeps theme colors)
|
||||
// Subtle shadow for a more polished look
|
||||
MultiEffect {
|
||||
anchors.fill: knob
|
||||
source: knob
|
||||
shadowEnabled: true
|
||||
shadowColor: Colors.colorShadow
|
||||
shadowColor: Colors.mShadow
|
||||
shadowOpacity: 0.25
|
||||
shadowHorizontalOffset: 0
|
||||
shadowVerticalOffset: 1
|
||||
|
|
@ -73,8 +73,8 @@ Slider {
|
|||
implicitWidth: knobDiameter
|
||||
implicitHeight: knobDiameter
|
||||
radius: width * 0.5
|
||||
color: root.pressed ? Colors.colorSurfaceVariant : Colors.colorSurface
|
||||
border.color: Colors.colorPrimary
|
||||
color: root.pressed ? Colors.mSurfaceVariant : Colors.mSurface
|
||||
border.color: Colors.mPrimary
|
||||
border.width: Math.max(1, Style.borderThick * scaling)
|
||||
|
||||
// Press feedback halo (using accent color, low opacity)
|
||||
|
|
@ -83,7 +83,7 @@ Slider {
|
|||
width: parent.width + 8 * scaling
|
||||
height: parent.height + 8 * scaling
|
||||
radius: width / 2
|
||||
color: Colors.colorPrimary
|
||||
color: Colors.mPrimary
|
||||
opacity: root.pressed ? 0.16 : 0.0
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,5 +10,5 @@ Text {
|
|||
font.family: Settings.data.ui.fontFamily
|
||||
font.pointSize: Style.fontSizeMedium * scaling
|
||||
font.weight: Style.fontWeightRegular
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,13 +29,13 @@ Item {
|
|||
text: label
|
||||
font.pointSize: Style.fontSizeMedium * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: description
|
||||
font.pointSize: Style.fontSizeSmall * scaling
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
|
@ -47,8 +47,8 @@ Item {
|
|||
implicitWidth: root.width
|
||||
implicitHeight: Style.baseWidgetSize * 1.35 * scaling
|
||||
radius: Style.radiusMedium * scaling
|
||||
color: Colors.colorSurface
|
||||
border.color: Colors.colorOutline
|
||||
color: Colors.mSurface
|
||||
border.color: Colors.mOutline
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
|
||||
// Focus ring
|
||||
|
|
@ -56,7 +56,7 @@ Item {
|
|||
anchors.fill: parent
|
||||
radius: frame.radius
|
||||
color: "transparent"
|
||||
border.color: input.activeFocus ? Colors.colorTertiary : "transparent"
|
||||
border.color: input.activeFocus ? Colors.mTertiary : "transparent"
|
||||
border.width: input.activeFocus ? Math.max(1, Style.borderThin * scaling) : 0
|
||||
}
|
||||
|
||||
|
|
@ -74,8 +74,8 @@ Item {
|
|||
echoMode: TextInput.Normal
|
||||
readOnly: root.readOnly
|
||||
enabled: root.enabled
|
||||
color: Colors.colorOnSurface
|
||||
placeholderTextColor: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
placeholderTextColor: Colors.mOnSurface
|
||||
background: null
|
||||
font.pointSize: Style.fontSizeSmall * scaling
|
||||
onEditingFinished: root.editingFinished()
|
||||
|
|
|
|||
|
|
@ -27,13 +27,13 @@ RowLayout {
|
|||
text: label
|
||||
font.pointSize: Style.fontSizeMedium * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: description
|
||||
font.pointSize: Style.fontSizeSmall * scaling
|
||||
color: Colors.colorOnSurface
|
||||
color: Colors.mOnSurface
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
|
@ -45,16 +45,16 @@ RowLayout {
|
|||
implicitWidth: root.baseSize * 1.625 * scaling
|
||||
implicitHeight: root.baseSize * scaling
|
||||
radius: height * 0.5
|
||||
color: value ? Colors.colorPrimary : Colors.colorSurface
|
||||
border.color: value ? Colors.colorPrimary : Colors.colorOutline
|
||||
color: value ? Colors.mPrimary : Colors.mSurface
|
||||
border.color: value ? Colors.mPrimary : Colors.mOutline
|
||||
border.width: Math.max(1, Style.borderMedium * scaling)
|
||||
|
||||
Rectangle {
|
||||
implicitWidth: (root.baseSize - 5) * scaling
|
||||
implicitHeight: (root.baseSize - 5) * scaling
|
||||
radius: height * 0.5
|
||||
color: value ? Colors.colorOnPrimary: Colors.colorPrimary
|
||||
border.color: value ? Colors.colorSurface : Colors.colorSurface
|
||||
color: value ? Colors.mOnPrimary: Colors.mPrimary
|
||||
border.color: value ? Colors.mSurface : Colors.mSurface
|
||||
border.width: Math.max(1, Style.borderMedium * scaling)
|
||||
y: 2 * scaling
|
||||
x: value ? switcher.width - width - 2 * scaling : 2 * scaling
|
||||
|
|
|
|||
|
|
@ -135,8 +135,8 @@ Window {
|
|||
id: tooltipRect
|
||||
anchors.fill: parent
|
||||
radius: Style.radiusMedium * scaling
|
||||
color: Colors.colorSurface
|
||||
border.color: Colors.colorOutline
|
||||
color: Colors.mSurface
|
||||
border.color: Colors.mOutline
|
||||
border.width: Math.max(1, Style.borderThin * scaling)
|
||||
z: 1
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue