Formatting
This commit is contained in:
parent
ce66b99cee
commit
84c81ecb77
6 changed files with 229 additions and 61 deletions
|
|
@ -26,37 +26,49 @@ Item {
|
||||||
label: "Show Active Window"
|
label: "Show Active Window"
|
||||||
description: "Display the title of the currently focused window below the bar"
|
description: "Display the title of the currently focused window below the bar"
|
||||||
value: Settings.data.bar.showActiveWindow
|
value: Settings.data.bar.showActiveWindow
|
||||||
onToggled: function (newValue) { Settings.data.bar.showActiveWindow = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.bar.showActiveWindow = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Show Active Window Icon"
|
label: "Show Active Window Icon"
|
||||||
description: "Display the icon of the currently focused window"
|
description: "Display the icon of the currently focused window"
|
||||||
value: Settings.data.bar.showActiveWindowIcon
|
value: Settings.data.bar.showActiveWindowIcon
|
||||||
onToggled: function (newValue) { Settings.data.bar.showActiveWindowIcon = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.bar.showActiveWindowIcon = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Show System Info"
|
label: "Show System Info"
|
||||||
description: "Display system information (CPU, RAM, Temperature)"
|
description: "Display system information (CPU, RAM, Temperature)"
|
||||||
value: Settings.data.bar.showSystemInfo
|
value: Settings.data.bar.showSystemInfo
|
||||||
onToggled: function (newValue) { Settings.data.bar.showSystemInfo = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.bar.showSystemInfo = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Show Taskbar"
|
label: "Show Taskbar"
|
||||||
description: "Display a taskbar showing currently open windows"
|
description: "Display a taskbar showing currently open windows"
|
||||||
value: Settings.data.bar.showTaskbar
|
value: Settings.data.bar.showTaskbar
|
||||||
onToggled: function (newValue) { Settings.data.bar.showTaskbar = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.bar.showTaskbar = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Show Media"
|
label: "Show Media"
|
||||||
description: "Display media controls and information"
|
description: "Display media controls and information"
|
||||||
value: Settings.data.bar.showMedia
|
value: Settings.data.bar.showMedia
|
||||||
onToggled: function (newValue) { Settings.data.bar.showMedia = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.bar.showMedia = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,17 +13,26 @@ Item {
|
||||||
|
|
||||||
// Helper functions to update arrays immutably
|
// Helper functions to update arrays immutably
|
||||||
function addMonitor(list, name) {
|
function addMonitor(list, name) {
|
||||||
const arr = (list || []).slice(); if (!arr.includes(name)) arr.push(name); return arr
|
const arr = (list || []).slice()
|
||||||
|
if (!arr.includes(name))
|
||||||
|
arr.push(name)
|
||||||
|
return arr
|
||||||
}
|
}
|
||||||
function removeMonitor(list, name) {
|
function removeMonitor(list, name) {
|
||||||
return (list || []).filter(function (n) { return n !== name })
|
return (list || []).filter(function (n) {
|
||||||
|
return n !== name
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Style.marginMedium * scaling
|
spacing: Style.marginMedium * scaling
|
||||||
|
|
||||||
NText { text: "Per‑monitor configuration"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Per‑monitor configuration"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
model: Quickshell.screens || []
|
model: Quickshell.screens || []
|
||||||
|
|
@ -41,12 +50,22 @@ Item {
|
||||||
anchors.margins: Style.marginMedium * scaling
|
anchors.margins: Style.marginMedium * scaling
|
||||||
spacing: Style.marginSmall * scaling
|
spacing: Style.marginSmall * scaling
|
||||||
|
|
||||||
NText { text: (modelData.name || "Unknown"); font.weight: Style.fontWeightBold; color: Colors.accentPrimary }
|
NText {
|
||||||
|
text: (modelData.name || "Unknown")
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentPrimary
|
||||||
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Style.marginMedium * scaling
|
spacing: Style.marginMedium * scaling
|
||||||
NText { text: `Resolution: ${modelData.width}x${modelData.height}`; color: Colors.textSecondary }
|
NText {
|
||||||
NText { text: `Position: (${modelData.x}, ${modelData.y})`; color: Colors.textSecondary }
|
text: `Resolution: ${modelData.width}x${modelData.height}`
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: `Position: (${modelData.x}, ${modelData.y})`
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
|
|
@ -83,7 +102,8 @@ Item {
|
||||||
if (newValue) {
|
if (newValue) {
|
||||||
Settings.data.notifications.monitors = addMonitor(Settings.data.notifications.monitors, modelData.name)
|
Settings.data.notifications.monitors = addMonitor(Settings.data.notifications.monitors, modelData.name)
|
||||||
} else {
|
} else {
|
||||||
Settings.data.notifications.monitors = removeMonitor(Settings.data.notifications.monitors, modelData.name)
|
Settings.data.notifications.monitors = removeMonitor(Settings.data.notifications.monitors,
|
||||||
|
modelData.name)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -91,6 +111,8 @@ Item {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -20,17 +20,28 @@ Item {
|
||||||
color: Colors.accentSecondary
|
color: Colors.accentSecondary
|
||||||
}
|
}
|
||||||
|
|
||||||
NText { text: "Visualizer Type"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Choose the style of the audio visualizer"; color: Colors.textSecondary }
|
text: "Visualizer Type"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Choose the style of the audio visualizer"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
|
|
||||||
NComboBox {
|
NComboBox {
|
||||||
id: visualizerTypeComboBox
|
id: visualizerTypeComboBox
|
||||||
optionsKeys: ["radial", "fire", "diamond"]
|
optionsKeys: ["radial", "fire", "diamond"]
|
||||||
optionsLabels: ["Radial", "Fire", "Diamond"]
|
optionsLabels: ["Radial", "Fire", "Diamond"]
|
||||||
currentKey: Settings.data.audioVisualizer.type
|
currentKey: Settings.data.audioVisualizer.type
|
||||||
onSelected: function (key) { Settings.data.audioVisualizer.type = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.audioVisualizer.type = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,11 @@ Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Style.marginMedium * scaling
|
spacing: Style.marginMedium * scaling
|
||||||
|
|
||||||
NText { text: "Wi‑Fi"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Wi‑Fi"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Enable Wi‑Fi"
|
label: "Enable Wi‑Fi"
|
||||||
|
|
@ -24,12 +28,19 @@ Item {
|
||||||
value: Settings.data.network.wifiEnabled
|
value: Settings.data.network.wifiEnabled
|
||||||
onToggled: function (newValue) {
|
onToggled: function (newValue) {
|
||||||
Settings.data.network.wifiEnabled = newValue
|
Settings.data.network.wifiEnabled = newValue
|
||||||
Quickshell.execDetached(["nmcli", "radio", "wifi", newValue ? "on" : "off"]) }
|
Quickshell.execDetached(["nmcli", "radio", "wifi", newValue ? "on" : "off"])
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NDivider { Layout.fillWidth: true }
|
NDivider {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
}
|
||||||
|
|
||||||
NText { text: "Bluetooth"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Bluetooth"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Enable Bluetooth"
|
label: "Enable Bluetooth"
|
||||||
|
|
@ -39,11 +50,14 @@ Item {
|
||||||
Settings.data.network.bluetoothEnabled = newValue
|
Settings.data.network.bluetoothEnabled = newValue
|
||||||
if (Bluetooth.defaultAdapter) {
|
if (Bluetooth.defaultAdapter) {
|
||||||
Bluetooth.defaultAdapter.enabled = newValue
|
Bluetooth.defaultAdapter.enabled = newValue
|
||||||
if (Bluetooth.defaultAdapter.enabled) Bluetooth.defaultAdapter.discovering = true
|
if (Bluetooth.defaultAdapter.enabled)
|
||||||
|
Bluetooth.defaultAdapter.discovering = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,11 +14,22 @@ Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Style.marginMedium * scaling
|
spacing: Style.marginMedium * scaling
|
||||||
|
|
||||||
NText { text: "Screen Recording"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Screen Recording"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
// Output Directory
|
// Output Directory
|
||||||
NText { text: "Output Directory"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Directory where screen recordings will be saved"; color: Colors.textSecondary }
|
text: "Output Directory"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Directory where screen recordings will be saved"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NTextBox {
|
NTextBox {
|
||||||
text: Settings.data.screenRecorder.directory
|
text: Settings.data.screenRecorder.directory
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -26,78 +37,141 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Frame Rate
|
// Frame Rate
|
||||||
NText { text: "Frame Rate"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Target frame rate for screen recordings (default: 60)"; color: Colors.textSecondary }
|
text: "Frame Rate"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Target frame rate for screen recordings (default: 60)"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
NText { text: Settings.data.screenRecorder.frameRate + " FPS"; color: Colors.textPrimary }
|
NText {
|
||||||
Item { Layout.fillWidth: true }
|
text: Settings.data.screenRecorder.frameRate + " FPS"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
}
|
||||||
|
Item {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
NSlider {
|
NSlider {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
from: 24; to: 144; stepSize: 1
|
from: 24
|
||||||
|
to: 144
|
||||||
|
stepSize: 1
|
||||||
value: Settings.data.screenRecorder.frameRate
|
value: Settings.data.screenRecorder.frameRate
|
||||||
onMoved: Settings.data.screenRecorder.frameRate = Math.round(value)
|
onMoved: Settings.data.screenRecorder.frameRate = Math.round(value)
|
||||||
cutoutColor: Colors.surface
|
cutoutColor: Colors.surface
|
||||||
}
|
}
|
||||||
|
|
||||||
// Audio Source
|
// Audio Source
|
||||||
NText { text: "Audio Source"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Audio source to capture during recording"; color: Colors.textSecondary }
|
text: "Audio Source"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Audio source to capture during recording"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["default_output", "default_input", "both"]
|
optionsKeys: ["default_output", "default_input", "both"]
|
||||||
optionsLabels: ["System Audio", "Microphone", "System Audio + Microphone"]
|
optionsLabels: ["System Audio", "Microphone", "System Audio + Microphone"]
|
||||||
currentKey: Settings.data.screenRecorder.audioSource
|
currentKey: Settings.data.screenRecorder.audioSource
|
||||||
onSelected: function (key) { Settings.data.screenRecorder.audioSource = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.screenRecorder.audioSource = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Video Quality
|
// Video Quality
|
||||||
NText { text: "Video Quality"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Higher quality results in larger file sizes"; color: Colors.textSecondary }
|
text: "Video Quality"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Higher quality results in larger file sizes"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["medium", "high", "very_high", "ultra"]
|
optionsKeys: ["medium", "high", "very_high", "ultra"]
|
||||||
optionsLabels: ["Medium", "High", "Very High", "Ultra"]
|
optionsLabels: ["Medium", "High", "Very High", "Ultra"]
|
||||||
currentKey: Settings.data.screenRecorder.quality
|
currentKey: Settings.data.screenRecorder.quality
|
||||||
onSelected: function (key) { Settings.data.screenRecorder.quality = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.screenRecorder.quality = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Video Codec
|
// Video Codec
|
||||||
NText { text: "Video Codec"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Different codecs offer different compression and compatibility"; color: Colors.textSecondary }
|
text: "Video Codec"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Different codecs offer different compression and compatibility"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["h264", "hevc", "av1", "vp8", "vp9"]
|
optionsKeys: ["h264", "hevc", "av1", "vp8", "vp9"]
|
||||||
optionsLabels: ["H264", "HEVC", "AV1", "VP8", "VP9"]
|
optionsLabels: ["H264", "HEVC", "AV1", "VP8", "VP9"]
|
||||||
currentKey: Settings.data.screenRecorder.videoCodec
|
currentKey: Settings.data.screenRecorder.videoCodec
|
||||||
onSelected: function (key) { Settings.data.screenRecorder.videoCodec = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.screenRecorder.videoCodec = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Audio Codec
|
// Audio Codec
|
||||||
NText { text: "Audio Codec"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Opus is recommended for best performance and smallest audio size"; color: Colors.textSecondary }
|
text: "Audio Codec"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Opus is recommended for best performance and smallest audio size"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["opus", "aac"]
|
optionsKeys: ["opus", "aac"]
|
||||||
optionsLabels: ["OPUS", "AAC"]
|
optionsLabels: ["OPUS", "AAC"]
|
||||||
currentKey: Settings.data.screenRecorder.audioCodec
|
currentKey: Settings.data.screenRecorder.audioCodec
|
||||||
onSelected: function (key) { Settings.data.screenRecorder.audioCodec = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.screenRecorder.audioCodec = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Color Range
|
// Color Range
|
||||||
NText { text: "Color Range"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Limited is recommended for better compatibility"; color: Colors.textSecondary }
|
text: "Color Range"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Limited is recommended for better compatibility"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["limited", "full"]
|
optionsKeys: ["limited", "full"]
|
||||||
optionsLabels: ["Limited", "Full"]
|
optionsLabels: ["Limited", "Full"]
|
||||||
currentKey: Settings.data.screenRecorder.colorRange
|
currentKey: Settings.data.screenRecorder.colorRange
|
||||||
onSelected: function (key) { Settings.data.screenRecorder.colorRange = key }
|
onSelected: function (key) {
|
||||||
|
Settings.data.screenRecorder.colorRange = key
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Show Cursor"
|
label: "Show Cursor"
|
||||||
description: "Record mouse cursor in the video"
|
description: "Record mouse cursor in the video"
|
||||||
value: Settings.data.screenRecorder.showCursor
|
value: Settings.data.screenRecorder.showCursor
|
||||||
onToggled: function (newValue) { Settings.data.screenRecorder.showCursor = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.screenRecorder.showCursor = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,28 +14,49 @@ Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Style.marginMedium * scaling
|
spacing: Style.marginMedium * scaling
|
||||||
|
|
||||||
NText { text: "Time"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Time"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "Use 12 Hour Clock"
|
label: "Use 12 Hour Clock"
|
||||||
description: "Display time in 12-hour format (e.g., 2:30 PM) instead of 24-hour format"
|
description: "Display time in 12-hour format (e.g., 2:30 PM) instead of 24-hour format"
|
||||||
value: Settings.data.location.use12HourClock
|
value: Settings.data.location.use12HourClock
|
||||||
onToggled: function (newValue) { Settings.data.location.use12HourClock = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.location.use12HourClock = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
label: "US Style Date"
|
label: "US Style Date"
|
||||||
description: "Display dates in MM/DD/YYYY format instead of DD/MM/YYYY"
|
description: "Display dates in MM/DD/YYYY format instead of DD/MM/YYYY"
|
||||||
value: Settings.data.location.reverseDayMonth
|
value: Settings.data.location.reverseDayMonth
|
||||||
onToggled: function (newValue) { Settings.data.location.reverseDayMonth = newValue }
|
onToggled: function (newValue) {
|
||||||
|
Settings.data.location.reverseDayMonth = newValue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NDivider { Layout.fillWidth: true }
|
NDivider {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
}
|
||||||
|
|
||||||
NText { text: "Weather"; font.weight: Style.fontWeightBold; color: Colors.accentSecondary }
|
NText {
|
||||||
|
text: "Weather"
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
color: Colors.accentSecondary
|
||||||
|
}
|
||||||
|
|
||||||
NText { text: "City"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
NText {
|
||||||
NText { text: "Your city name for weather information"; color: Colors.textSecondary }
|
text: "City"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Your city name for weather information"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
}
|
||||||
NTextBox {
|
NTextBox {
|
||||||
text: Settings.data.location.name
|
text: Settings.data.location.name
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -45,18 +66,32 @@ Item {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Style.marginSmall * scaling
|
spacing: Style.marginSmall * scaling
|
||||||
ColumnLayout { Layout.fillWidth: true; spacing: 2 * scaling
|
ColumnLayout {
|
||||||
NText { text: "Temperature Unit"; color: Colors.textPrimary; font.weight: Style.fontWeightBold }
|
Layout.fillWidth: true
|
||||||
NText { text: "Choose between Celsius and Fahrenheit"; color: Colors.textSecondary; wrapMode: Text.WordWrap }
|
spacing: 2 * scaling
|
||||||
|
NText {
|
||||||
|
text: "Temperature Unit"
|
||||||
|
color: Colors.textPrimary
|
||||||
|
font.weight: Style.fontWeightBold
|
||||||
|
}
|
||||||
|
NText {
|
||||||
|
text: "Choose between Celsius and Fahrenheit"
|
||||||
|
color: Colors.textSecondary
|
||||||
|
wrapMode: Text.WordWrap
|
||||||
|
}
|
||||||
}
|
}
|
||||||
NComboBox {
|
NComboBox {
|
||||||
optionsKeys: ["c", "f"]
|
optionsKeys: ["c", "f"]
|
||||||
optionsLabels: ["Celsius", "Fahrenheit"]
|
optionsLabels: ["Celsius", "Fahrenheit"]
|
||||||
currentKey: Settings.data.location.useFahrenheit ? "f" : "c"
|
currentKey: Settings.data.location.useFahrenheit ? "f" : "c"
|
||||||
onSelected: function (key) { Settings.data.location.useFahrenheit = (key === "f") }
|
onSelected: function (key) {
|
||||||
|
Settings.data.location.useFahrenheit = (key === "f")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true }
|
Item {
|
||||||
|
Layout.fillHeight: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue