Settings: using NLabel everywhere
This commit is contained in:
parent
f67a0b8420
commit
7d2534644d
10 changed files with 40 additions and 100 deletions
|
|
@ -45,7 +45,7 @@ ColumnLayout {
|
|||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: "Audio"
|
||||
text: "Audio Output Volume"
|
||||
font.pointSize: Style.fontSizeXXL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ ColumnLayout {
|
|||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: "Components"
|
||||
text: "Bar Components"
|
||||
font.pointSize: Style.fontSizeXXL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
|
|
|
|||
|
|
@ -34,59 +34,24 @@ Item {
|
|||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: "Configure brightness controls and monitor settings."
|
||||
font.pointSize: Style.fontSize * scaling
|
||||
color: Color.mOnSurfaceVariant
|
||||
}
|
||||
|
||||
// Bar Visibility Section
|
||||
ColumnLayout {
|
||||
spacing: Style.marginS * scaling
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Style.marginL * scaling
|
||||
|
||||
NText {
|
||||
text: "Bar Integration"
|
||||
font.pointSize: Style.fontSizeL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
NToggle {
|
||||
label: "Show Brightness Icon"
|
||||
description: "Display the brightness control icon in the top bar."
|
||||
label: "Show Bar Icon"
|
||||
description: "Display the brightness control icon in the bar."
|
||||
checked: Settings.data.bar.showBrightness
|
||||
onToggled: checked => {
|
||||
Settings.data.bar.showBrightness = checked
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
NDivider {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Style.marginL * scaling
|
||||
Layout.bottomMargin: Style.marginL * scaling
|
||||
}
|
||||
|
||||
// Brightness Step Section
|
||||
ColumnLayout {
|
||||
spacing: Style.marginS * scaling
|
||||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: "Brightness Step Size"
|
||||
font.pointSize: Style.fontSizeL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: "Adjust the step size for brightness changes (scroll wheel, keyboard shortcuts)."
|
||||
font.pointSize: Style.fontSizeXS * scaling
|
||||
color: Color.mOnSurfaceVariant
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.fillWidth: true
|
||||
NLabel {
|
||||
label: "Brightness Step Size"
|
||||
description: "Adjust the step size for brightness changes (scroll wheel, keyboard shortcuts)."
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
|
|
@ -127,19 +92,9 @@ Item {
|
|||
spacing: Style.marginS * scaling
|
||||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: "Monitor Brightness Overview"
|
||||
font.pointSize: Style.fontSizeL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: "Current brightness levels for all detected monitors."
|
||||
font.pointSize: Style.fontSizeXS * scaling
|
||||
color: Color.mOnSurfaceVariant
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.fillWidth: true
|
||||
NLabel {
|
||||
label: "Monitors Brightness Control"
|
||||
description: "Current brightness levels for all detected monitors."
|
||||
}
|
||||
|
||||
// Single monitor display using the same data source as the bar icon
|
||||
|
|
|
|||
|
|
@ -107,19 +107,6 @@ ColumnLayout {
|
|||
spacing: Style.marginL * scaling
|
||||
Layout.fillWidth: true
|
||||
|
||||
// Use Matugen
|
||||
NToggle {
|
||||
label: "Enable Matugen"
|
||||
description: "Automatically generate colors based on your active wallpaper."
|
||||
checked: Settings.data.colorSchemes.useWallpaperColors
|
||||
onToggled: checked => {
|
||||
Settings.data.colorSchemes.useWallpaperColors = checked
|
||||
if (Settings.data.colorSchemes.useWallpaperColors) {
|
||||
ColorSchemeService.changedWallpaper()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Dark Mode Toggle (affects both Matugen and predefined schemes that provide variants)
|
||||
NToggle {
|
||||
label: "Dark Mode"
|
||||
|
|
@ -154,6 +141,19 @@ ColumnLayout {
|
|||
}
|
||||
}
|
||||
|
||||
// Use Matugen
|
||||
NToggle {
|
||||
label: "Enable Matugen"
|
||||
description: "Automatically generate colors based on your active wallpaper."
|
||||
checked: Settings.data.colorSchemes.useWallpaperColors
|
||||
onToggled: checked => {
|
||||
Settings.data.colorSchemes.useWallpaperColors = checked
|
||||
if (Settings.data.colorSchemes.useWallpaperColors) {
|
||||
ColorSchemeService.changedWallpaper()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
NDivider {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Style.marginL * scaling
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ Item {
|
|||
|
||||
NToggle {
|
||||
label: "Bar"
|
||||
description: "Enable the top bar on this monitor."
|
||||
description: "Enable the bar on this monitor."
|
||||
checked: (Settings.data.bar.monitors || []).indexOf(modelData.name) !== -1
|
||||
onToggled: checked => {
|
||||
if (checked) {
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ ColumnLayout {
|
|||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: "Recording"
|
||||
text: "Recordings"
|
||||
font.pointSize: Style.fontSizeXXL * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
|
|
|
|||
|
|
@ -38,21 +38,16 @@ Item {
|
|||
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: 120 * scaling
|
||||
Layout.preferredHeight: 140 * scaling
|
||||
radius: Style.radiusM * scaling
|
||||
color: Color.mSurface
|
||||
border.color: Color.mOutline
|
||||
border.width: Math.max(1, Style.borderS * scaling)
|
||||
clip: true
|
||||
color: Color.mPrimary
|
||||
|
||||
NImageRounded {
|
||||
id: currentWallpaperImage
|
||||
anchors.fill: parent
|
||||
anchors.margins: Style.marginS * scaling
|
||||
anchors.margins: Style.marginXS * scaling
|
||||
imagePath: WallpaperService.currentWallpaper
|
||||
fallbackIcon: "image"
|
||||
borderColor: Color.mOutline
|
||||
borderWidth: Math.max(1, Style.borderS * scaling)
|
||||
imageRadius: Style.radiusM * scaling
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -96,22 +96,10 @@ ColumnLayout {
|
|||
// Interval
|
||||
ColumnLayout {
|
||||
RowLayout {
|
||||
NLabel {
|
||||
label: "Wallpaper Interval"
|
||||
description: "How often to change wallpapers automatically (in seconds)."
|
||||
Layout.fillWidth: true
|
||||
|
||||
ColumnLayout {
|
||||
NText {
|
||||
text: "Wallpaper Interval"
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
}
|
||||
|
||||
NText {
|
||||
text: "How often to change wallpapers automatically (in seconds)."
|
||||
font.pointSize: Style.fontSizeXS * scaling
|
||||
color: Color.mOnSurface
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
}
|
||||
|
||||
NText {
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import qs.Commons
|
|||
Singleton {
|
||||
id: root
|
||||
|
||||
// Automatic, orientation-agnostic scaling
|
||||
function scale(aScreen) {
|
||||
return scaleByName(aScreen.name)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ ColumnLayout {
|
|||
font.pointSize: Style.fontSizeM * scaling
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
visible: label !== ""
|
||||
}
|
||||
|
||||
NText {
|
||||
|
|
@ -21,5 +22,7 @@ ColumnLayout {
|
|||
font.pointSize: Style.fontSizeS * scaling
|
||||
color: Color.mOnSurfaceVariant
|
||||
wrapMode: Text.WordWrap
|
||||
visible: description !== ""
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue