i18n: even more integration

autoformat
This commit is contained in:
Ly-sec
2025-09-24 14:24:21 +02:00
parent 2a23b6afdd
commit 2bfed74851
35 changed files with 301 additions and 245 deletions
+35 -48
View File
@@ -326,24 +326,19 @@ ColumnLayout {
id: audioVisualizerCombo
label: I18n.tr("settings.audio.media.visualizer-type.label")
description: I18n.tr("settings.audio.media.visualizer-type.description")
model: [
{
key: "none",
name: I18n.tr("options.visualizer-types.none")
},
{
key: "linear",
name: I18n.tr("options.visualizer-types.linear")
},
{
key: "mirrored",
name: I18n.tr("options.visualizer-types.mirrored")
},
{
key: "wave",
name: I18n.tr("options.visualizer-types.wave")
}
]
model: [{
"key": "none",
"name": I18n.tr("options.visualizer-types.none")
}, {
"key": "linear",
"name": I18n.tr("options.visualizer-types.linear")
}, {
"key": "mirrored",
"name": I18n.tr("options.visualizer-types.mirrored")
}, {
"key": "wave",
"name": I18n.tr("options.visualizer-types.wave")
}]
currentKey: Settings.data.audio.visualizerType
onSelected: key => Settings.data.audio.visualizerType = key
}
@@ -351,36 +346,28 @@ ColumnLayout {
NComboBox {
label: I18n.tr("settings.audio.media.frame-rate.label")
description: I18n.tr("settings.audio.media.frame-rate.description")
model: [
{
key: "30",
name: I18n.tr("options.frame-rates.30-fps")
},
{
key: "60",
name: I18n.tr("options.frame-rates.60-fps")
},
{
key: "100",
name: I18n.tr("options.frame-rates.100-fps")
},
{
key: "120",
name: I18n.tr("options.frame-rates.120-fps")
},
{
key: "144",
name: I18n.tr("options.frame-rates.144-fps")
},
{
key: "165",
name: I18n.tr("options.frame-rates.165-fps")
},
{
key: "240",
name: I18n.tr("options.frame-rates.240-fps")
}
]
model: [{
"key": "30",
"name": I18n.tr("options.frame-rates.30-fps")
}, {
"key": "60",
"name": I18n.tr("options.frame-rates.60-fps")
}, {
"key": "100",
"name": I18n.tr("options.frame-rates.100-fps")
}, {
"key": "120",
"name": I18n.tr("options.frame-rates.120-fps")
}, {
"key": "144",
"name": I18n.tr("options.frame-rates.144-fps")
}, {
"key": "165",
"name": I18n.tr("options.frame-rates.165-fps")
}, {
"key": "240",
"name": I18n.tr("options.frame-rates.240-fps")
}]
currentKey: Settings.data.audio.cavaFrameRate
onSelected: key => Settings.data.audio.cavaFrameRate = key
}
+5 -1
View File
@@ -277,7 +277,11 @@ ColumnLayout {
delegate: NCheckbox {
Layout.fillWidth: true
label: modelData.name || "Unknown"
description: `${modelData.model} (${modelData.width}x${modelData.height})`
description: I18n.tr("system.monitor-description", {
"model": modelData.model,
"width": modelData.width,
"height": modelData.height
})
checked: (Settings.data.bar.monitors || []).indexOf(modelData.name) !== -1
onToggled: checked => {
if (checked) {
+8 -2
View File
@@ -90,7 +90,11 @@ ColumnLayout {
NLabel {
label: modelData.name || "Unknown"
description: `${modelData.model} (${modelData.width}x${modelData.height})`
description: I18n.tr("system.monitor-description", {
"model": modelData.model,
"width": modelData.width,
"height": modelData.height
})
}
// Scale
@@ -114,7 +118,9 @@ ColumnLayout {
stepSize: 0.01
value: localScaling
onPressedChanged: (pressed, value) => ScalingService.setScreenScale(modelData, value)
text: `${Math.round(localScaling * 100)}%`
text: I18n.tr("system.scaling-percentage", {
"percentage": Math.round(localScaling * 100)
})
Layout.fillWidth: true
}
+5 -1
View File
@@ -101,7 +101,11 @@ ColumnLayout {
delegate: NCheckbox {
Layout.fillWidth: true
label: modelData.name || "Unknown"
description: `${modelData.model} (${modelData.width}x${modelData.height})`
description: I18n.tr("system.monitor-description", {
"model": modelData.model,
"width": modelData.width,
"height": modelData.height
})
checked: (Settings.data.dock.monitors || []).indexOf(modelData.name) !== -1
onToggled: checked => {
if (checked) {
+4 -1
View File
@@ -42,7 +42,10 @@ ColumnLayout {
NText {
visible: LocationService.coordinatesReady
text: `${LocationService.stableName} (${LocationService.displayCoordinates})`
text: I18n.tr("system.location-display", {
"name": LocationService.stableName,
"coordinates": LocationService.displayCoordinates
})
font.pointSize: Style.fontSizeS * scaling
color: Color.mOnSurfaceVariant
verticalAlignment: Text.AlignVCenter
+5 -1
View File
@@ -151,7 +151,11 @@ ColumnLayout {
delegate: NCheckbox {
Layout.fillWidth: true
label: modelData.name || "Unknown"
description: `${modelData.model} (${modelData.width}x${modelData.height})`
description: I18n.tr("system.monitor-description", {
"model": modelData.model,
"width": modelData.width,
"height": modelData.height
})
checked: (Settings.data.notifications.monitors || []).indexOf(modelData.name) !== -1
onToggled: checked => {
if (checked) {
+7 -10
View File
@@ -61,16 +61,13 @@ ColumnLayout {
NComboBox {
label: I18n.tr("settings.screen-recorder.video.video-source.label")
description: I18n.tr("settings.screen-recorder.video.video-source.description")
model: [
{
key: "portal",
name: I18n.tr("options.screen-recording.sources.portal")
},
{
key: "screen",
name: I18n.tr("options.screen-recording.sources.screen")
}
]
model: [{
"key": "portal",
"name": I18n.tr("options.screen-recording.sources.portal")
}, {
"key": "screen",
"name": I18n.tr("options.screen-recording.sources.screen")
}]
currentKey: Settings.data.screenRecorder.videoSource
onSelected: key => Settings.data.screenRecorder.videoSource = key
}