diff options
| author | Evertiro <dgriffiths@widgitlabs.com> | 2026-02-20 00:32:09 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-02-20 17:32:09 +1100 |
| commit | 4be8fc9693e439c487f091413289b782d78130e7 (patch) | |
| tree | 19c5adf8f527e958e28293404145c90bea9022ff | |
| parent | config: added option to set session icons (#1189) (diff) | |
| download | caelestia-shell-4be8fc9693e439c487f091413289b782d78130e7.tar.gz caelestia-shell-4be8fc9693e439c487f091413289b782d78130e7.tar.bz2 caelestia-shell-4be8fc9693e439c487f091413289b782d78130e7.zip | |
feat: allow different systems for weather/performance (#1109)
* Allow different systems for weather/performance
Signed-off-by: Dan Griffiths <dgriffiths@widgitlabs.com>
* readme: update options
Signed-off-by: Dan Griffiths <dgriffiths@widgitlabs.com>
---------
Signed-off-by: Dan Griffiths <dgriffiths@widgitlabs.com>
| -rw-r--r-- | README.md | 1 | ||||
| -rw-r--r-- | config/Config.qml | 1 | ||||
| -rw-r--r-- | config/ServiceConfig.qml | 1 | ||||
| -rw-r--r-- | modules/dashboard/Performance.qml | 2 |
4 files changed, 4 insertions, 1 deletions
@@ -596,6 +596,7 @@ default, you must create it manually. "playerAliases": [{ "from": "com.github.th_ch.youtube_music", "to": "YT Music" }], "weatherLocation": "", "useFahrenheit": false, + "useFahrenheitPerformance": false, "useTwelveHourClock": false, "smartScheme": true, "visualiserBars": 45 diff --git a/config/Config.qml b/config/Config.qml index a70da54..8c01014 100644 --- a/config/Config.qml +++ b/config/Config.qml @@ -441,6 +441,7 @@ Singleton { return { weatherLocation: services.weatherLocation, useFahrenheit: services.useFahrenheit, + useFahrenheitPerformance: services.useFahrenheitPerformance, useTwelveHourClock: services.useTwelveHourClock, gpuType: services.gpuType, visualiserBars: services.visualiserBars, diff --git a/config/ServiceConfig.qml b/config/ServiceConfig.qml index d083b7a..29600cc 100644 --- a/config/ServiceConfig.qml +++ b/config/ServiceConfig.qml @@ -4,6 +4,7 @@ import QtQuick JsonObject { property string weatherLocation: "" // A lat,long pair or empty for autodetection, e.g. "37.8267,-122.4233" property bool useFahrenheit: [Locale.ImperialUSSystem, Locale.ImperialSystem].includes(Qt.locale().measurementSystem) + property bool useFahrenheitPerformance: [Locale.ImperialUSSystem, Locale.ImperialSystem].includes(Qt.locale().measurementSystem) property bool useTwelveHourClock: Qt.locale().timeFormat(Locale.ShortFormat).toLowerCase().includes("a") property string gpuType: "" property int visualiserBars: 45 diff --git a/modules/dashboard/Performance.qml b/modules/dashboard/Performance.qml index a4e24c4..e73d8ed 100644 --- a/modules/dashboard/Performance.qml +++ b/modules/dashboard/Performance.qml @@ -13,7 +13,7 @@ Item { readonly property int minWidth: 400 + 400 + Appearance.spacing.normal + 120 + Appearance.padding.large * 2 function displayTemp(temp: real): string { - return `${Math.ceil(Config.services.useFahrenheit ? temp * 1.8 + 32 : temp)}°${Config.services.useFahrenheit ? "F" : "C"}`; + return `${Math.ceil(Config.services.useFahrenheitPerformance ? temp * 1.8 + 32 : temp)}°${Config.services.useFahrenheitPerformance ? "F" : "C"}`; } implicitWidth: Math.max(minWidth, content.implicitWidth) |