diff --git a/Configs/Home/.directory b/Configs/Home/.directory
deleted file mode 100644
index 05b013a..0000000
--- a/Configs/Home/.directory
+++ /dev/null
@@ -1,6 +0,0 @@
-[Dolphin]
-Timestamp=2024,4,2,10,52,16.196
-Version=4
-
-[Settings]
-HiddenFilesShown=true
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/code/pws-api.js b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/code/pws-api.js
index 987b800..98fd81f 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/code/pws-api.js
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/code/pws-api.js
@@ -177,7 +177,7 @@ function getForecastData() {
plasmoid.configuration.longitude;
url += "/forecast/daily/7day.json";
url += "?apiKey=" + API_KEY;
- url += "&language=en-US";
+ url += "&language=" + Qt.locale().name.replace("_","-");
if (unitsChoice === 0) {
url += "&units=m";
@@ -215,6 +215,7 @@ function getForecastData() {
fullDateTime.split("T")[0].split("-")[2]
);
+ // API returns empty string if no snow. Check for empty string.
var snowDesc = "";
if (isDay) {
snowDesc =
@@ -228,6 +229,24 @@ function getForecastData() {
: night["snow_phrase"];
}
+ // API does not return a thunderDesc for non-English languages. Check for null value.
+ var thunderDesc = "";
+ if (isDay) {
+ thunderDesc = day["thunder_enum_phrase"] !== null ? day["thunder_enum_phrase"] : "N/A"
+ } else {
+ thunderDesc = night["thunder_enum_phrase"] !== null ? night["thunder_enum_phrase"] : "N/A"
+ }
+
+ // API does not return a 12char weather description for non-English languages, but it always returns a 32char. Check for empty string.
+ var shortDesc = "";
+ if (isDay) {
+ shortDesc = day["phrase_12char"] !== "" ? day["phrase_12char"] : day["phrase_32char"]
+ } else {
+
+ shortDesc = night["phrase_12char"] !== "" ? night["phrase_12char"] : night["phrase_32char"]
+ }
+
+
forecastModel.append({
date: date,
dayOfWeek: isDay ? forecast["dow"] : "Tonight",
@@ -235,13 +254,9 @@ function getForecastData() {
high: isDay ? forecast["max_temp"] : night["hi"],
low: forecast["min_temp"],
feelsLike: isDay ? day["hi"] : night["hi"],
- shortDesc: isDay
- ? day["phrase_12char"]
- : night["phrase_12char"],
+ shortDesc: shortDesc,
longDesc: isDay ? day["narrative"] : night["narrative"],
- thunderDesc: isDay
- ? day["thunder_enum_phrase"]
- : night["thunder_enum_phrase"],
+ thunderDesc: thunderDesc,
winDesc: isDay
? day["wind_phrase"]
: night["wind_phrase"],
@@ -328,7 +343,7 @@ function findIconCode() {
url += "?geocode=" + lat + "," + long;
url += "&apiKey=" + API_KEY;
- url += "&language=en-US";
+ url += "&language=" + Qt.locale().name.replace("_","-");
if (unitsChoice === 0) {
url += "&units=m";
@@ -462,5 +477,3 @@ function getExtendedConditions() {
req.send();
}
-/**
- * Get air quality
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/config/config.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/config/config.qml
index 21d5e23..5830ab0 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/config/config.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/config/config.qml
@@ -19,22 +19,22 @@ import org.kde.plasma.configuration
ConfigModel {
ConfigCategory {
- name: "Station"
+ name: i18n("Station")
icon: "flag"
source: "config/ConfigStation.qml"
}
ConfigCategory {
- name: "Appearance"
+ name: i18n("Appearance")
icon: "preferences-desktop-color"
source: "config/ConfigAppearance.qml"
}
ConfigCategory {
- name: "Units"
+ name: i18n("Units")
icon: "configure"
source: "config/ConfigUnits.qml"
}
ConfigCategory {
- name: "Debug"
+ name: i18n("Debug")
icon: "preferences-other"
source: "config/ConfigDebug.qml"
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/de_DE/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/de_DE/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..8d91ee1
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/de_DE/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/es_ES/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/es_ES/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..d94f8ec
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/es_ES/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/fr_FR/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/fr_FR/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..af7d0ad
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/fr_FR/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ja_JP/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ja_JP/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..d1f9e01
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ja_JP/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/nl_NL/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/nl_NL/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..aff1558
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/nl_NL/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ru_RU/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ru_RU/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
new file mode 100644
index 0000000..9949658
Binary files /dev/null and b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/locale/ru_RU/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/ForecastItem.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/ForecastItem.qml
index 76cdb83..a675a5e 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/ForecastItem.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/ForecastItem.qml
@@ -48,6 +48,7 @@ RowLayout {
PlasmaComponents.Label {
Layout.alignment: Qt.AlignVCenter | Qt.AlignHCenter
+ // TODO: add elide behavior since non-English descriptions can be longer
text: shortDesc
}
Kirigami.Icon {
@@ -64,7 +65,7 @@ RowLayout {
id: tooltip
mainText: longDesc
- subText: "" + "Feels like: " + Utils.currentTempUnit(feelsLike) + "
Thunder: " + thunderDesc + "
UV: " + UVDesc + "
Snow: " + snowDesc + "
Golf: " + golfDesc + ""
+ subText: i18nc("Do not edit HTML tags.","Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5", Utils.currentTempUnit(feelsLike), thunderDesc, UVDesc, snowDesc, golfDesc)
interactive: true
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/config/ConfigStation.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/config/ConfigStation.qml
index 49a0f5d..9616a62 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/config/ConfigStation.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/config/ConfigStation.qml
@@ -95,7 +95,7 @@ KCM.SimpleKCM {
}
PlasmaComponents.Label {
- text: "Version 2.5.5"
+ text: "Version 0.0.9"
}
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/lib/ConfigBtn.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/lib/ConfigBtn.qml
index b27deb7..9b56716 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/lib/ConfigBtn.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/lib/ConfigBtn.qml
@@ -22,7 +22,7 @@ import org.kde.plasma.plasmoid
import org.kde.plasma.core as PlasmaCore
Button {
- text: "Configure Wunderground"
+ text: i18n("Configure Wunderground")
icon.name: "settings"
onClicked: plasmoid.internalAction("configure").trigger()
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/main.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/main.qml
index 09420d1..ddb12a3 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/main.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/contents/ui/main.qml
@@ -15,6 +15,7 @@
* along with this program. If not, see .
*/
+import QtQml
import QtQuick
import QtQuick.Layouts
import QtQuick.Controls
@@ -144,12 +145,7 @@ PlasmoidItem {
Component.onCompleted: {
//printDebug(plasmoid.containment.corona.kPackage)
- //printDebug("qlocation: " + plasmoid.location)
- //printDebug("qformfactor: " + plasmoid.formFactor)
- //printDebug("qavailscreen: " + plasmoid.containment.availableScreenRect)
- //printDebug("qcontaintype: " + plasmoid.containment.containmentType)
- //printDebug("qcontainhint: " + plasmoid.containment.containmentDisplayHints)
- inTray = plasmoid.containment.containmentType == 129 && plasmoid.formFactor == 2
+ inTray = plasmoid.containment.containmentType == 129 && plasmoid.formFactor == 2
plasmoid.configurationRequiredReason = i18n("Set the weather station to pull data from.")
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/metadata.json b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/metadata.json
index c143ea4..2347081 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/metadata.json
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/metadata.json
@@ -1,35 +1,35 @@
{
- "KPackageStructure": "Plasma/Applet",
- "KPlugin": {
- "Authors": [
- {
- "Email": "k-donn@github.com",
- "Name": "k-donn"
- }
- ],
- "Category": "Environment and Weather",
- "Description": "Wunderground Personal Weather Station viewer",
- "Description[de_DE]": "Wunderground Personal Weather Station viewer",
- "Description[es_ES]": "Visor de la estación meteorológica personal Wunderground",
- "Description[fr_FR]": "Visualisation de station météorologique personnelle Wunderground",
- "Description[ja_JP]": "Wunderground Personal Weather Station viewer",
- "Description[nl_NL]": "Wunderground - Bekijk je eigen weerstation",
- "Description[ru_RU]": "Программа просмотра персональных метеостанций Wunderground",
- "Icon": "weather-clear",
- "Id": "com.github.k-donn.plasmoid-wunderground",
- "License": "GPL2-or-later",
- "Name": "Wunderground",
- "Name[de_DE]": "Wunderground",
- "Name[es_ES]": "Wunderground",
- "Name[fr_FR]": "Wunderground",
- "Name[ja_JP]": "Wunderground",
- "Name[nl_NL]": "Wunderground",
- "Name[ru_RU]": "Wunderground",
- "Version": "0.0.6",
- "Website": "https://github.com/k-donn/plasmoid-wunderground"
- },
- "X-KDE-ParentApp": "",
- "X-Plasma-API-Minimum-Version": "6.0",
- "X-Plasma-NotificationArea": "true",
- "X-Plasma-NotificationAreaCategory": "SystemServices"
+ "KPackageStructure": "Plasma/Applet",
+ "KPlugin": {
+ "Authors": [
+ {
+ "Email": "k-donn@github.com",
+ "Name": "k-donn"
+ }
+ ],
+ "Category": "Environment and Weather",
+ "Description": "Wunderground Personal Weather Station viewer",
+ "Description[de_DE]": "Wunderground Personal Weather Station viewer",
+ "Description[es_ES]": "Visor de la estación meteorológica personal Wunderground",
+ "Description[fr_FR]": "Visualisation de station météorologique personnelle Wunderground",
+ "Description[ja_JP]": "Wunderground Personal Weather Station viewer",
+ "Description[nl_NL]": "Wunderground - Bekijk je eigen weerstation",
+ "Description[ru_RU]": "Программа просмотра персональных метеостанций Wunderground",
+ "Icon": "weather-clear",
+ "Id": "com.github.k-donn.plasmoid-wunderground",
+ "License": "GPL2-or-later",
+ "Name": "Wunderground",
+ "Name[de_DE]": "Wunderground",
+ "Name[es_ES]": "Wunderground",
+ "Name[fr_FR]": "Wunderground",
+ "Name[ja_JP]": "Wunderground",
+ "Name[nl_NL]": "Wunderground",
+ "Name[ru_RU]": "Wunderground",
+ "Version": "0.0.9",
+ "Website": "https://github.com/k-donn/plasmoid-wunderground"
+ },
+ "X-KDE-ParentApp": "",
+ "X-Plasma-API-Minimum-Version": "6.0",
+ "X-Plasma-NotificationArea": "true",
+ "X-Plasma-NotificationAreaCategory": "SystemServices"
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ReadMe.md b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ReadMe.md
index 8c893f6..85411f0 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ReadMe.md
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ReadMe.md
@@ -1,43 +1,55 @@
-> Version 7 of Zren's i18n scripts.
+# Translate
-With KDE Frameworks v5.37 and above, translations are bundled with the `*.plasmoid` file downloaded from the store.
+## Status
-## Install Translations
+| Locale | Lines | % Done|
+|----------|---------|-------|
+| Template | 50 | |
+| ru_RU | 44/50 | 88% |
+| nl_NL | 44/50 | 88% |
+| es_ES | 44/50 | 88% |
+| de_DE | 48/50 | 96% |
+| ja_JP | 44/50 | 88% |
+| fr_FR | 44/50 | 88% |
-Go to `~/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/` and run `sh ./build --restartplasma`.
## New Translations
-1. Fill out [`template.pot`](template.pot) with your translations then open a [new issue](https://github.com/k-donn/plasmoid-wunderground/issues/new), name the file `spanish.txt`, attach the txt file to the issue (drag and drop).
+* Fill out [`template.pot`](template.pot) with your translations then open a [new issue](https://github.com/k-donn/plasmoid-wunderground/issues/new), name the file `spanish.txt`, attach the txt file to the issue (drag and drop).
Or if you know how to make a pull request
-1. Copy the `template.pot` file and name it your locale's code (Eg: `en`/`de`/`fr`) with the extension `.po`. Then fill out all the `msgstr ""`.
+* Copy the `template.pot` file and name it your locale's code (Eg: `en`/`de`/`fr`) with the extension `.po`. Then fill out all the `msgstr ""`.
+* Your region's locale code can be found at: https://stackoverflow.com/questions/3191664/list-of-all-locales-and-their-short-codes/28357857#28357857
## Scripts
-- `sh ./merge` will parse the `i18n()` calls in the `*.qml` files and write it to the `template.pot` file. Then it will merge any changes into the `*.po` language files.
-- `sh ./build` will convert the `*.po` files to it's binary `*.mo` version and move it to `contents/locale/...` which will bundle the translations in the `*.plasmoid` without needing the user to manually install them.
-- `sh ./plasmoidlocaletest` will run `./build` then `plasmoidviewer` (part of `plasma-sdk`).
+Zren's `kpac` script can easily run the `gettext` commands for you, parsing the `metadata.json` and filling out any placeholders for you. `kpac` can be [downloaded here](https://github.com/Zren/plasma-applet-lib/blob/master/kpac) and should be placed at `~/Code/plasmoid-widgetname/kpac` to edit translations at `~/Code/plasmoid-widgetname/package/translate/`.
-## Links
-- https://zren.github.io/kde/docs/widget/#translations-i18n
-- https://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems
-- https://api.kde.org/frameworks/ki18n/html/prg_guide.html
+* `python3 ./kpac i18n` will parse the `i18n()` calls in the `*.qml` files and write it to the `template.pot` file. Then it will merge any changes into the `*.po` language files. Then it converts the `*.po` files to it's binary `*.mo` version and move it to `contents/locale/...` which will bundle the translations in the `*.plasmoid` without needing the user to manually install them.
+* `python3 ./kpac localetest` will convert the `.po` to the `*.mo` files then run `plasmoidviewer` (part of `plasma-sdk`).
-## Examples
+## How it works
-- https://l10n.kde.org/stats/gui/trunk-kf5/team/fr/plasma-desktop/
-- https://github.com/psifidotos/nowdock-plasmoid/tree/master/po
-- https://github.com/kotelnik/plasma-applet-redshift-control/tree/master/translations
+Since KDE Frameworks v5.37, translations can be bundled with the zipped `*.plasmoid` file downloaded from the store.
-| Locale | Lines | % Done|
-|----------|---------|-------|
-| Template | 44 | |
-| de_DE | 44/44 | 100% |
-| es_ES | 44/44 | 100% |
-| fr_FR | 44/44 | 100% |
-| ja_JP | 44/44 | 100% |
-| nl_NL | 44/44 | 100% |
-| ru_RU | 44/44 | 100% |
+* `xgettext` extracts the messages from the source code into a `template.pot`.
+* Translators copy the `template.pot` to `fr.po` to translate the French language.
+* When the source code is updated, we use `msgmerge` to update the `fr.po` based on the updated `template.pot`.
+* When testing or releasing the widget, we convert the `.po` files to their binary `.mo` form with `msgfmt`.
+
+The binary `.mo` translation files are placed in `package/contents/locale/` so you may want to add `*.mo` to your `.gitignore`.
+
+```
+package/contents/locale/fr/LC_MESSAGES/plasma_applet_com.github.k-donn.plasmoid-wunderground.mo
+```
+
+## Links
+
+* https://develop.kde.org/docs/plasma/widget/translations-i18n/
+* https://l10n.kde.org/stats/gui/trunk-kf5/team/fr/plasma-desktop/
+* https://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems
+* https://api.kde.org/frameworks/ki18n/html/prg_guide.html
+
+> Version 8 of [Zren's i18n scripts](https://github.com/Zren/plasma-applet-lib).
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/build.sh b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/build.sh
deleted file mode 100755
index e68eef7..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/build.sh
+++ /dev/null
@@ -1,53 +0,0 @@
-#!/bin/sh
-# Version: 8
-
-# This script will convert the *.po files to *.mo files, rebuilding the package/contents/locale folder.
-# Feature discussion: https://phabricator.kde.org/D5209
-# Eg: contents/locale/fr_CA/LC_MESSAGES/plasma_applet_org.kde.plasma.eventcalendar.mo
-
-DIR=`cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd`
-plasmoidName=`kreadconfig6 --file="$DIR/../metadata.json" --group="Desktop Entry" --key="X-KDE-PluginInfo-Name"`
-website=`kreadconfig6 --file="$DIR/../metadata.json" --group="Desktop Entry" --key="X-KDE-PluginInfo-Website"`
-bugAddress="$website"
-packageRoot=".." # Root of translatable sources
-projectName="plasma_applet_${plasmoidName}" # project name
-
-#---
-if [ -z "$plasmoidName" ]; then
- echo "[build] Error: Couldn't read plasmoidName."
- exit
-fi
-
-if [ -z "$(which msgfmt)" ]; then
- echo "[build] Error: msgfmt command not found. Need to install gettext"
- echo "[build] Running 'sudo apt install gettext'"
- sudo apt install gettext
- echo "[build] gettext installation should be finished. Going back to installing translations."
-fi
-
-#---
-echo "[build] Compiling messages"
-
-catalogs=`find . -name '*.po' | sort`
-for cat in $catalogs; do
- echo "$cat"
- catLocale=`basename ${cat%.*}`
- msgfmt -o "${catLocale}.mo" "$cat"
-
- installPath="$DIR/../contents/locale/${catLocale}/LC_MESSAGES/${projectName}.mo"
-
- echo "[build] Install to ${installPath}"
- mkdir -p "$(dirname "$installPath")"
- mv "${catLocale}.mo" "${installPath}"
-done
-
-echo "[build] Done building messages"
-
-if [ "$1" = "--restartplasma" ]; then
- echo "[build] Restarting plasmashell"
- killall plasmashell
- kstart5 plasmashell
- echo "[build] Done restarting plasmashell"
-else
- echo "[build] (re)install the plasmoid and restart plasmashell to test."
-fi
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/de_DE.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/de_DE.po
index cf83679..65f7709 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/de_DE.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/de_DE.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: DA-Mo-YEAR HO:MI+ZONE\n"
"Last-Translator: Stefan Wannemacher \n"
"Language-Team: LANGUAGE \n"
@@ -17,14 +17,30 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Wunderground Personal Weather Station viewer"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr "Station"
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr "Aussehen"
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr "Einheiten"
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr "Debug"
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "Kontrollleistenansicht"
@@ -126,8 +142,8 @@ msgid "Feels like %1"
msgstr "Gefühlt wie %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "Wind von: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "Wind von: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -156,10 +172,19 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "UV-Index"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid "Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "Lade Daten..."
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -202,3 +227,6 @@ msgstr "Wettervorhersage"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "Temp max.: %1 Temp min.: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "Wind von: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/es_ES.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/es_ES.po
index a70fabf..508a2a3 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/es_ES.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/es_ES.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: 2022-03-09 20:36+0100\n"
"Last-Translator: victorhck \n"
"Language-Team: Spanish <>\n"
@@ -18,14 +18,30 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Lokalize 21.12.3\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Visor de la estación meteorológica personal Wunderground"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "Representación compacta"
@@ -127,8 +143,8 @@ msgid "Feels like %1"
msgstr "Sensación térmica de %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "Viento desde: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "Viento desde: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -157,10 +173,21 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "UV"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid ""
+"Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "Cargando datos..."
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -203,3 +230,6 @@ msgstr "Pronóstico"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "Alto: %1 Bajo: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "Viento desde: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/fr_FR.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/fr_FR.po
index 28f6991..8186a07 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/fr_FR.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/fr_FR.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: 2023-11-05 21:20+0100\n"
"Last-Translator: Bruno Bianchessi \n"
"Language-Team: French <>\n"
@@ -17,14 +17,30 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Visualisation de station météorologique personnelle Wunderground"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "Affichage Compact"
@@ -126,8 +142,8 @@ msgid "Feels like %1"
msgstr "Ressenti %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "Direction du vent: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "Direction du vent: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -156,10 +172,19 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "UV"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid "Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "Chargement des données"
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -202,3 +227,6 @@ msgstr "Prévisions"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "Maxi: %1 Mini: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "Direction du vent: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ja_JP.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ja_JP.po
index 8fe437b..44a516e 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ja_JP.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ja_JP.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: 2024-01-14 22:54+0900\n"
"Last-Translator: Yuta Takahashi \n"
"Language-Team: Japanese-Team \n"
@@ -17,14 +17,30 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Wunderground Personal Weather Station viewer"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "コンパクトな表示"
@@ -126,8 +142,8 @@ msgid "Feels like %1"
msgstr "体感温度 %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "風向: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "風向: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -156,10 +172,19 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "紫外線"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid "Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "データを読み込み中..."
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -202,3 +227,6 @@ msgstr "予報"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "最高気温: %1 最低気温: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "風向: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/merge.sh b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/merge.sh
deleted file mode 100755
index 0a0c71b..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/merge.sh
+++ /dev/null
@@ -1,223 +0,0 @@
-#!/bin/sh
-# Version: 20
-
-# https://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems
-# https://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems/Outside_KDE_repositories
-# https://invent.kde.org/sysadmin/l10n-scripty/-/blob/master/extract-messages.sh
-
-DIR=`cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd`
-plasmoidName=`kreadconfig6 --file="$DIR/../metadata.json" --group="Desktop Entry" --key="X-KDE-PluginInfo-Name"`
-widgetName="${plasmoidName##*.}" # Strip namespace
-website=`kreadconfig6 --file="$DIR/../metadata.json" --group="Desktop Entry" --key="X-KDE-PluginInfo-Website"`
-bugAddress="$website"
-packageRoot=".." # Root of translatable sources
-projectName="plasma_applet_${plasmoidName}" # project name
-
-#---
-if [ -z "$plasmoidName" ]; then
- echo "[merge] Error: Couldn't read plasmoidName."
- exit
-fi
-
-if [ -z "$(which xgettext)" ]; then
- echo "[merge] Error: xgettext command not found. Need to install gettext"
- echo "[merge] Running 'sudo apt install gettext'"
- sudo apt install gettext
- echo "[merge] gettext installation should be finished. Going back to merging translations."
-fi
-
-#---
-echo "[merge] Extracting messages"
-potArgs="--from-code=UTF-8 --width=200 --add-location=file"
-
-find "${packageRoot}" -name '*.desktop' | sort > "${DIR}/infiles.list"
-xgettext \
- ${potArgs} \
- --files-from="${DIR}/infiles.list" \
- --language=Desktop \
- -D "${packageRoot}" \
- -D "${DIR}" \
- -o "template.pot.new" \
- || \
- { echo "[merge] error while calling xgettext. aborting."; exit 1; }
-
-sed -i 's/"Content-Type: text\/plain; charset=CHARSET\\n"/"Content-Type: text\/plain; charset=UTF-8\\n"/' "template.pot.new"
-
-# See Ki18n's extract-messages.sh for a full example:
-# https://invent.kde.org/sysadmin/l10n-scripty/-/blob/master/extract-messages.sh#L25
-# The -kN_ and -kaliasLocale keywords are mentioned in the Outside_KDE_repositories wiki.
-# We don't need -kN_ since we don't use intltool-extract but might as well keep it.
-# I have no idea what -kaliasLocale is used for. Googling aliasLocale found only listed kde1 code.
-# We don't need to parse -ki18nd since that'll extract messages from other domains.
-find "${packageRoot}" -name '*.cpp' -o -name '*.h' -o -name '*.c' -o -name '*.qml' -o -name '*.js' | sort > "${DIR}/infiles.list"
-xgettext \
- ${potArgs} \
- --files-from="${DIR}/infiles.list" \
- -C -kde \
- -ci18n \
- -ki18n:1 -ki18nc:1c,2 -ki18np:1,2 -ki18ncp:1c,2,3 \
- -kki18n:1 -kki18nc:1c,2 -kki18np:1,2 -kki18ncp:1c,2,3 \
- -kxi18n:1 -kxi18nc:1c,2 -kxi18np:1,2 -kxi18ncp:1c,2,3 \
- -kkxi18n:1 -kkxi18nc:1c,2 -kkxi18np:1,2 -kkxi18ncp:1c,2,3 \
- -kI18N_NOOP:1 -kI18NC_NOOP:1c,2 \
- -kI18N_NOOP2:1c,2 -kI18N_NOOP2_NOSTRIP:1c,2 \
- -ktr2i18n:1 -ktr2xi18n:1 \
- -kN_:1 \
- -kaliasLocale \
- --package-name="${widgetName}" \
- --msgid-bugs-address="${bugAddress}" \
- -D "${packageRoot}" \
- -D "${DIR}" \
- --join-existing \
- -o "template.pot.new" \
- || \
- { echo "[merge] error while calling xgettext. aborting."; exit 1; }
-
-sed -i 's/# SOME DESCRIPTIVE TITLE./'"# Translation of ${widgetName} in LANGUAGE"'/' "template.pot.new"
-sed -i 's/# Copyright (C) YEAR THE PACKAGE'"'"'S COPYRIGHT HOLDER/'"# Copyright (C) $(date +%Y)"'/' "template.pot.new"
-
-if [ -f "template.pot" ]; then
- newPotDate=`grep "POT-Creation-Date:" template.pot.new | sed 's/.\{3\}$//'`
- oldPotDate=`grep "POT-Creation-Date:" template.pot | sed 's/.\{3\}$//'`
- sed -i 's/'"${newPotDate}"'/'"${oldPotDate}"'/' "template.pot.new"
- changes=`diff "template.pot" "template.pot.new"`
- if [ ! -z "$changes" ]; then
- # There's been changes
- sed -i 's/'"${oldPotDate}"'/'"${newPotDate}"'/' "template.pot.new"
- mv "template.pot.new" "template.pot"
-
- addedKeys=`echo "$changes" | grep "> msgid" | cut -c 9- | sort`
- removedKeys=`echo "$changes" | grep "< msgid" | cut -c 9- | sort`
- echo ""
- echo "Added Keys:"
- echo "$addedKeys"
- echo ""
- echo "Removed Keys:"
- echo "$removedKeys"
- echo ""
-
- else
- # No changes
- rm "template.pot.new"
- fi
-else
- # template.pot didn't already exist
- mv "template.pot.new" "template.pot"
-fi
-
-potMessageCount=`expr $(grep -Pzo 'msgstr ""\n(\n|$)' "template.pot" | grep -c 'msgstr ""')`
-echo "| Locale | Lines | % Done|" > "./Status.md"
-echo "|----------|---------|-------|" >> "./Status.md"
-entryFormat="| %-8s | %7s | %5s |"
-templateLine=`perl -e "printf(\"$entryFormat\", \"Template\", \"${potMessageCount}\", \"\")"`
-echo "$templateLine" >> "./Status.md"
-
-rm "${DIR}/infiles.list"
-echo "[merge] Done extracting messages"
-
-#---
-echo "[merge] Merging messages"
-catalogs=`find . -name '*.po' | sort`
-for cat in $catalogs; do
- echo "[merge] $cat"
- catLocale=`basename ${cat%.*}`
-
- widthArg=""
- catUsesGenerator=`grep "X-Generator:" "$cat"`
- if [ -z "$catUsesGenerator" ]; then
- widthArg="--width=400"
- fi
-
- cp "$cat" "$cat.new"
- sed -i 's/"Content-Type: text\/plain; charset=CHARSET\\n"/"Content-Type: text\/plain; charset=UTF-8\\n"/' "$cat.new"
-
- msgmerge \
- ${widthArg} \
- --add-location=file \
- --no-fuzzy-matching \
- -o "$cat.new" \
- "$cat.new" "${DIR}/template.pot"
-
- sed -i 's/# SOME DESCRIPTIVE TITLE./'"# Translation of ${widgetName} in ${catLocale}"'/' "$cat.new"
- sed -i 's/# Translation of '"${widgetName}"' in LANGUAGE/'"# Translation of ${widgetName} in ${catLocale}"'/' "$cat.new"
- sed -i 's/# Copyright (C) YEAR THE PACKAGE'"'"'S COPYRIGHT HOLDER/'"# Copyright (C) $(date +%Y)"'/' "$cat.new"
-
- poEmptyMessageCount=`expr $(grep -Pzo 'msgstr ""\n(\n|$)' "$cat.new" | grep -c 'msgstr ""')`
- poMessagesDoneCount=`expr $potMessageCount - $poEmptyMessageCount`
- poCompletion=`perl -e "printf(\"%d\", $poMessagesDoneCount * 100 / $potMessageCount)"`
- poLine=`perl -e "printf(\"$entryFormat\", \"$catLocale\", \"${poMessagesDoneCount}/${potMessageCount}\", \"${poCompletion}%\")"`
- echo "$poLine" >> "./Status.md"
-
- # mv "$cat" "$cat.old"
- mv "$cat.new" "$cat"
-done
-echo "[merge] Done merging messages"
-
-#---
-echo "[merge] Updating .desktop file"
-
-# Generate LINGUAS for msgfmt
-if [ -f "$DIR/LINGUAS" ]; then
- rm "$DIR/LINGUAS"
-fi
-touch "$DIR/LINGUAS"
-for cat in $catalogs; do
- catLocale=`basename ${cat%.*}`
- echo "${catLocale}" >> "$DIR/LINGUAS"
-done
-
-cp -f "$DIR/../metadata.json" "$DIR/template.desktop"
-sed -i '/^Name\[/ d; /^GenericName\[/ d; /^Comment\[/ d; /^Keywords\[/ d' "$DIR/template.desktop"
-
-msgfmt \
- --desktop \
- --template="$DIR/template.desktop" \
- -d "$DIR/" \
- -o "$DIR/new.desktop"
-
-# Delete empty msgid messages that used the po header
-if [ ! -z "$(grep '^Name=$' "$DIR/new.desktop")" ]; then
- echo "[merge] Name in metadata.json is empty!"
- sed -i '/^Name\[/ d' "$DIR/new.desktop"
-fi
-if [ ! -z "$(grep '^GenericName=$' "$DIR/new.desktop")" ]; then
- echo "[merge] GenericName in metadata.json is empty!"
- sed -i '/^GenericName\[/ d' "$DIR/new.desktop"
-fi
-if [ ! -z "$(grep '^Comment=$' "$DIR/new.desktop")" ]; then
- echo "[merge] Comment in metadata.json is empty!"
- sed -i '/^Comment\[/ d' "$DIR/new.desktop"
-fi
-if [ ! -z "$(grep '^Keywords=$' "$DIR/new.desktop")" ]; then
- echo "[merge] Keywords in metadata.json is empty!"
- sed -i '/^Keywords\[/ d' "$DIR/new.desktop"
-fi
-
-# Place translations at the bottom of the desktop file.
-translatedLines=`cat "$DIR/new.desktop" | grep "]="`
-if [ ! -z "${translatedLines}" ]; then
- sed -i '/^Name\[/ d; /^GenericName\[/ d; /^Comment\[/ d; /^Keywords\[/ d' "$DIR/new.desktop"
- if [ "$(tail -c 2 "$DIR/new.desktop" | wc -l)" != "2" ]; then
- # Does not end with 2 empty lines, so add an empty line.
- echo "" >> "$DIR/new.desktop"
- fi
- echo "${translatedLines}" >> "$DIR/new.desktop"
-fi
-
-# Cleanup
-mv "$DIR/new.desktop" "$DIR/../metadata.json"
-rm "$DIR/template.desktop"
-rm "$DIR/LINGUAS"
-
-#---
-# Populate ReadMe.md
-echo "[merge] Updating translate/ReadMe.md"
-sed -i -E 's`share\/plasma\/plasmoids\/(.+)\/translate`share/plasma/plasmoids/'"${plasmoidName}"'/translate`' ./ReadMe.md
-if [[ "$website" == *"github.com"* ]]; then
- sed -i -E 's`\[new issue\]\(https:\/\/github\.com\/(.+)\/(.+)\/issues\/new\)`[new issue]('"${website}"'/issues/new)`' ./ReadMe.md
-fi
-sed -i '/^|/ d' ./ReadMe.md # Remove status table from ReadMe
-cat ./Status.md >> ./ReadMe.md
-rm ./Status.md
-
-echo "[merge] Done"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/nl_NL.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/nl_NL.po
index 31969cd..397e1dc 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/nl_NL.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/nl_NL.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: 2022-04-17 14:14+0200\n"
"Last-Translator: Heimen Stoffels \n"
"Language-Team: Dutch <>\n"
@@ -18,14 +18,30 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Lokalize 22.03.90\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Wunderground - Bekijk je eigen weerstation"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "Compacte indeling gebruiken"
@@ -127,8 +143,8 @@ msgid "Feels like %1"
msgstr "Gevoelstemperatuur: %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "Windrichting: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "Windrichting: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -157,10 +173,21 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "UV-index"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid ""
+"Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "Bezig met laden…"
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -203,3 +230,6 @@ msgstr "Weersvoorspelling"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "Hoog: %1 - Laag: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "Windrichting: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/plasmoidlocaletest b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/plasmoidlocaletest
deleted file mode 100755
index dacdedb..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/plasmoidlocaletest
+++ /dev/null
@@ -1,181 +0,0 @@
-#!/bin/bash
-# Version 9
-# Requires plasmoidviewer v5.13.0
-
-function checkIfLangInstalled {
- if [ -x "$(command -v dpkg)" ]; then
- dpkg -l ${1} >/dev/null 2>&1 || ( \
- echo -e "${1} not installed.\nInstalling now before continuing.\n" \
- ; sudo apt install ${1} \
- ) || ( \
- echo -e "\nError trying to install ${1}\nPlease run 'sudo apt install ${1}'\n" \
- ; exit 1 \
- )
- elif [ -x "$(command -v pacman)" ]; then
- # TODO: run `locale -a` and check if the locale is enabled.
- if false; then
- # https://wiki.archlinux.org/index.php/Locale
- # Uncomment the locale in /etc/locale.gen
- # Then run `locale-gen`
- echo -e "\nPlease install this locale in System Settings first.\n"
- exit 1
- else
- echo ""
- fi
- else
- echo -e "\nPackage manager not recognized. If the widget is not translated, please install the package '${1}'\n"
- fi
-}
-
-langInput="${1}"
-lang=""
-languagePack=""
-
-if [[ "$langInput" =~ ":" ]]; then # String contains a colon so assume it's a locale code.
- lang="${langInput}"
- IFS=: read -r l1 l2 <<< "${lang}"
- languagePack="language-pack-${l2}"
-fi
-
-# https://stackoverflow.com/questions/3191664/list-of-all-locales-and-their-short-codes/28357857#28357857
-declare -a langArr=(
- "af_ZA:af:Afrikaans (South Africa)"
- "ak_GH:ak:Akan (Ghana)"
- "am_ET:am:Amharic (Ethiopia)"
- "ar_EG:ar:Arabic (Egypt)"
- "as_IN:as:Assamese (India)"
- "az_AZ:az:Azerbaijani (Azerbaijan)"
- "be_BY:be:Belarusian (Belarus)"
- "bem_ZM:bem:Bemba (Zambia)"
- "bg_BG:bg:Bulgarian (Bulgaria)"
- "bo_IN:bo:Tibetan (India)"
- "bs_BA:bs:Bosnian (Bosnia and Herzegovina)"
- "ca_ES:ca:Catalan (Spain)"
- "chr_US:ch:Cherokee (United States)"
- "cs_CZ:cs:Czech (Czech Republic)"
- "cy_GB:cy:Welsh (United Kingdom)"
- "da_DK:da:Danish (Denmark)"
- "de_DE:de:German (Germany)"
- "el_GR:el:Greek (Greece)"
- "es_MX:es:Spanish (Mexico)"
- "et_EE:et:Estonian (Estonia)"
- "eu_ES:eu:Basque (Spain)"
- "fa_IR:fa:Persian (Iran)"
- "ff_SN:ff:Fulah (Senegal)"
- "fi_FI:fi:Finnish (Finland)"
- "fo_FO:fo:Faroese (Faroe Islands)"
- "fr_CA:fr:French (Canada)"
- "ga_IE:ga:Irish (Ireland)"
- "gl_ES:gl:Galician (Spain)"
- "gu_IN:gu:Gujarati (India)"
- "gv_GB:gv:Manx (United Kingdom)"
- "ha_NG:ha:Hausa (Nigeria)"
- "he_IL:he:Hebrew (Israel)"
- "hi_IN:hi:Hindi (India)"
- "hr_HR:hr:Croatian (Croatia)"
- "hu_HU:hu:Hungarian (Hungary)"
- "hy_AM:hy:Armenian (Armenia)"
- "id_ID:id:Indonesian (Indonesia)"
- "ig_NG:ig:Igbo (Nigeria)"
- "is_IS:is:Icelandic (Iceland)"
- "it_IT:it:Italian (Italy)"
- "ja_JP:ja:Japanese (Japan)"
- "ka_GE:ka:Georgian (Georgia)"
- "kk_KZ:kk:Kazakh (Kazakhstan)"
- "kl_GL:kl:Kalaallisut (Greenland)"
- "km_KH:km:Khmer (Cambodia)"
- "kn_IN:kn:Kannada (India)"
- "ko_KR:ko:Korean (South Korea)"
- "ko_KR:ko:Korean (South Korea)"
- "lg_UG:lg:Ganda (Uganda)"
- "lt_LT:lt:Lithuanian (Lithuania)"
- "lv_LV:lv:Latvian (Latvia)"
- "mg_MG:mg:Malagasy (Madagascar)"
- "mk_MK:mk:Macedonian (Macedonia)"
- "ml_IN:ml:Malayalam (India)"
- "mr_IN:mr:Marathi (India)"
- "ms_MY:ms:Malay (Malaysia)"
- "mt_MT:mt:Maltese (Malta)"
- "my_MM:my:Burmese (Myanmar [Burma])"
- "nb_NO:nb:Norwegian Bokmål (Norway)"
- "ne_NP:ne:Nepali (Nepal)"
- "nl_NL:nl:Dutch (Netherlands)"
- "nn_NO:nn:Norwegian Nynorsk (Norway)"
- "om_ET:om:Oromo (Ethiopia)"
- "or_IN:or:Oriya (India)"
- "pa_PK:pa:Punjabi (Pakistan)"
- "pl_PL:pl:Polish (Poland)"
- "ps_AF:ps:Pashto (Afghanistan)"
- "pt_BR:pt:Portuguese (Brazil)"
- "ro_RO:ro:Romanian (Romania)"
- "ru_RU:ru:Russian (Russia)"
- "rw_RW:rw:Kinyarwanda (Rwanda)"
- "si_LK:si:Sinhala (Sri Lanka)"
- "sk_SK:sk:Slovak (Slovakia)"
- "sl_SI:sl:Slovenian (Slovenia)"
- "so_SO:so:Somali (Somalia)"
- "sq_AL:sq:Albanian (Albania)"
- "sr_RS:sr:Serbian (Serbia)"
- "sv_SE:sv:Swedish (Sweden)"
- "sw_KE:sw:Swahili (Kenya)"
- "ta_IN:ta:Tamil (India)"
- "te_IN:te:Telugu (India)"
- "th_TH:th:Thai (Thailand)"
- "ti_ER:ti:Tigrinya (Eritrea)"
- "to_TO:to:Tonga (Tonga)"
- "tr_TR:tr:Turkish (Turkey)"
- "uk_UA:uk:Ukrainian (Ukraine)"
- "ur_IN:ur:Urdu (India)"
- "uz_UZ:uz:Uzbek (Uzbekistan)"
- "vi_VN:vi:Vietnamese (Vietnam)"
- "yo_NG:yo:Yoruba (Nigeria)"
- "yo_NG:yo:Yoruba (Nigeria)"
- "yue_HK:yu:Cantonese (Hong Kong)"
- "zh_CN:zh:Chinese (China)"
- "zu_ZA:zu:Zulu (South Africa)"
-)
-
-for i in "${langArr[@]}"; do
- IFS=: read -r l1 l2 l3 <<< "$i"
- if [ "$langInput" == "$l2" ]; then
- lang="${l1}:${l2}"
- languagePack="language-pack-${l2}"
- fi
-done
-
-if [ -z "$lang" ]; then
- echo "plasmoidlocaletest doesn't recognize the language '$lang'"
- echo "Eg:"
- scriptcmd='sh ./plasmoidlocaletest'
- for i in "${langArr[@]}"; do
- IFS=: read -r l1 l2 l3 <<< "$i"
- echo " ${scriptcmd} ${l2} | ${l3}"
- done
- echo ""
- echo "Or use a the full locale code:"
- echo " ${scriptcmd} ar_EG:ar"
- exit 1
-fi
-
-IFS=: read -r l1 l2 <<< "${lang}"
-l1="${l1}.UTF-8"
-
-# Check if language is installed
-if [ ! -z "$languagePack" ]; then
- if [ "$lang" == "zh_CN:zh" ]; then languagePack="language-pack-zh-hans"
- fi
-
- checkIfLangInstalled "$languagePack" || exit 1
-fi
-
-
-echo "LANGUAGE=\"${lang}\""
-echo "LANG=\"${l1}\""
-
-scriptDir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-packageDir="${scriptDir}/.."
-
-# Build local translations for plasmoidviewer
-sh "${scriptDir}/build"
-
-LANGUAGE="${lang}" LANG="${l1}" LC_TIME="${l1}" QML_DISABLE_DISK_CACHE=true plasmoidviewer -a "$packageDir" -l topedge -f horizontal -x 0 -y 0
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ru_RU.po b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ru_RU.po
index f789c2f..9e49dad 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ru_RU.po
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/ru_RU.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: 2023-07-03 20:36+0100\n"
"Last-Translator: AleksZZ \n"
"Language-Team: Russian \n"
@@ -17,14 +17,30 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr "Wunderground"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr "Программа просмотра персональных метеостанций Wunderground"
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr "Компактное представление"
@@ -126,8 +142,8 @@ msgid "Feels like %1"
msgstr "По ощущениям %1"
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
-msgstr "Напралвение ветра: %1"
+msgid "Wind from: %1 (%2°)"
+msgstr "Напралвение ветра: %1 (%2°)"
#: ../contents/ui/DetailsItem.qml
msgid "DEWPOINT"
@@ -156,10 +172,19 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr "УФ"
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid "Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr "Загрузка данных ..."
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
@@ -202,3 +227,6 @@ msgstr "Прогноз"
#: ../contents/ui/TopPanel.qml
msgid "High: %1 Low: %2"
msgstr "Высокий: %1 Низкий: %2"
+
+#~ msgid "Wind from: %1"
+#~ msgstr "Напралвение ветра: %1"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/template.pot b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/template.pot
index f9f0d81..57b9808 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/template.pot
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.github.k-donn.plasmoid-wunderground/translate/template.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: plasmoid-wunderground\n"
"Report-Msgid-Bugs-To: https://github.com/k-donn/plasmoid-wunderground\n"
-"POT-Creation-Date: 2024-01-21 20:04-0500\n"
+"POT-Creation-Date: 2024-03-28 21:52-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
@@ -17,14 +17,30 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground"
msgstr ""
-#: ../metadata.desktop
+#: ../metadata.json
msgid "Wunderground Personal Weather Station viewer"
msgstr ""
+#: ../contents/config/config.qml
+msgid "Station"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Appearance"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Units"
+msgstr ""
+
+#: ../contents/config/config.qml
+msgid "Debug"
+msgstr ""
+
#: ../contents/ui/config/ConfigAppearance.qml
msgid "Compact Representation"
msgstr ""
@@ -126,7 +142,7 @@ msgid "Feels like %1"
msgstr ""
#: ../contents/ui/DetailsItem.qml
-msgid "Wind from: %1"
+msgid "Wind from: %1 (%2°)"
msgstr ""
#: ../contents/ui/DetailsItem.qml
@@ -156,10 +172,19 @@ msgctxt "Ultra Violet"
msgid "UV"
msgstr ""
+#: ../contents/ui/ForecastItem.qml
+msgctxt "Do not edit HTML tags."
+msgid "Feels like: %1
Thunder: %2
UV: %3
Snow: %4
Golf: %5"
+msgstr ""
+
#: ../contents/ui/FullRepresentation.qml
msgid "Loading data..."
msgstr ""
+#: ../contents/ui/lib/ConfigBtn.qml
+msgid "Configure Wunderground"
+msgstr ""
+
#: ../contents/ui/main.qml
msgctxt "Do not edit HTML tags. 'Temp' means temperature"
msgid "Temp: %1
"
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/config.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/config.qml
deleted file mode 100644
index 99b0aa7..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/config.qml
+++ /dev/null
@@ -1,14 +0,0 @@
-import org.kde.plasma.configuration
-
-ConfigModel {
- ConfigCategory {
- name: i18n("Appearance")
- icon: "preferences-desktop-color"
- source: "configAppearance.qml"
- }
- ConfigCategory {
- name: i18n("Behaviour")
- icon: "preferences-desktop"
- source: "configPreferences.qml"
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/main.xml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/main.xml
deleted file mode 100644
index fde6845..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/config/main.xml
+++ /dev/null
@@ -1,103 +0,0 @@
-
-
-
-
-
-
-
- true
-
-
- true
-
-
- true
-
-
- true
-
-
- true
-
-
- false
-
-
- false
-
-
- false
-
-
-
-
- 48
-
-
- 108
-
-
- 38
-
-
- 250
-
-
- 48
-
-
- 38
-
-
- 20
-
-
- 20
-
-
- 14
-
-
- 16
-
-
- 200
-
-
- 50
-
-
-
-
- 2000
-
-
-
-
- 0
-
-
- 0
-
-
- 0
-
-
-
-
- #d78695
-
-
- #9ed24a
-
-
- #dfa45c
-
-
- #464a4b
-
-
-
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/fonts/Hasteristico.ttf b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/fonts/Hasteristico.ttf
deleted file mode 100644
index bb2de99..0000000
Binary files a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/fonts/Hasteristico.ttf and /dev/null differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/BooleanField.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/BooleanField.qml
deleted file mode 100644
index 76bc510..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/BooleanField.qml
+++ /dev/null
@@ -1,15 +0,0 @@
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-
-RowLayout {
- property alias text: label.text
- property alias checked: checkbox.checked
-
- Label {
- id: label
- }
- CheckBox {
- id: checkbox
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/ColorField.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/ColorField.qml
deleted file mode 100644
index 03ebbfa..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/ColorField.qml
+++ /dev/null
@@ -1,25 +0,0 @@
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-import QtQuick.Dialogs
-import org.kde.kirigami 2.4 as Kirigami
-import org.kde.kquickcontrols 2.0 as KQControls
-
-RowLayout {
- id: colorfield
- property alias text: label.text
- property alias color: colorbutton.color
-
- Label {
- id: label
- }
- KQControls.ColorButton {
- id: colorbutton
- color: root.color
- showAlphaChannel: false
-
- onAccepted: {
- colorfield.color = color
- }
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/FontLabel.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/FontLabel.qml
deleted file mode 100644
index 66b4bd6..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/FontLabel.qml
+++ /dev/null
@@ -1,51 +0,0 @@
-import QtQuick
-import QtQuick.Layouts
-import org.kde.plasma.components as PlasmaComponents
-
-Item {
- id: labelWrapper
- Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter
- Layout.minimumWidth: label.contentWidth
- Layout.minimumHeight: label.contentHeight
- property alias text: label.text
- property alias font: label.font
- property alias elide: label.elide
- property alias color: label2.color
- property alias labelWidth: label.width
- property bool fill: true && root.enableFillAnimation
-
- property int from;
- property int to;
- property int currentVal;
-
- Text {
- id: label
- font.family: root.fontFamily
- font.capitalization: Font.AllUppercase
- font.weight: Font.Thin
- color: labelWrapper.fill ? root.textBackgroundColor : labelWrapper.color
- verticalAlignment: Text.AlignBottom
- renderType: Text.QtRendering
- }
- FontMetrics {
- id: metrics
- font: label.font
- }
- Text {
- id: label2
- visible: labelWrapper.fill
- elide: label.elide
- width: label.width
- // HACK "metrics.ascent-metrics.descent+(root.sizeFactor*0.1)" is approximately the same as cap height of the font but not exactly equal
- height: labelWrapper.fill ? ((metrics.ascent-metrics.descent + (font.pixelSize*0.1))/(((to-from)+1)/currentVal))+metrics.descent : 0
- anchors.bottom: label.bottom
- verticalAlignment: Text.AlignBottom
- renderType: Text.QtRendering
- text: label.text
- font: label.font
- clip: true
- Component.onCompleted: {
- console.log(metrics.descent)
- }
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/NumberField.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/NumberField.qml
deleted file mode 100644
index 9c8545a..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/NumberField.qml
+++ /dev/null
@@ -1,19 +0,0 @@
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-import org.kde.plasma.core as PlasmaCore
-
-RowLayout {
- property alias text: label.text
- property alias value: spinbox.value
- property alias enabled: spinbox.enabled
-
- Label {
- id: label
- color: spinbox.enabled ? PlasmaCore.Theme.textColor : PlasmaCore.Theme.disabledTextColor
- }
- SpinBox {
- id: spinbox
- from: 0; to: 999999
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/SysMonLabel.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/SysMonLabel.qml
deleted file mode 100644
index ed9f81d..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/SysMonLabel.qml
+++ /dev/null
@@ -1,29 +0,0 @@
-import QtQuick
-import QtQuick.Layouts
-import org.kde.plasma.components as PlasmaComponents
-
-RowLayout {
- id: labelWrapper
- property alias text: displayText.text
- property alias from: displayText.from
- property alias to: displayText.to
- property string color;
- property string usage;
- property string unit;
-
- FontLabel {
- id: displayText
- font.family: root.fontFamily
- font.pixelSize: root.sysMonTextFontSize
- color: labelWrapper.color
- currentVal: usage
- }
- FontLabel {
- id: usageText
- font.family: root.fontFamily
- font.pixelSize: root.sysMonUsageFontSize
- color: labelWrapper.color
- fill: false
- text: unit ? usage + unit : usage
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/Title.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/Title.qml
deleted file mode 100644
index e9a13c6..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/Title.qml
+++ /dev/null
@@ -1,8 +0,0 @@
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-
-Label {
- font.pixelSize: 18
- Layout.topMargin: 10
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configAppearance.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configAppearance.qml
deleted file mode 100644
index c440b12..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configAppearance.qml
+++ /dev/null
@@ -1,184 +0,0 @@
-import QtQuick
-import QtQuick.Layouts
-import QtQuick.Controls
-import org.kde.kcmutils as KCM
-
-
-KCM.SimpleKCM {
- // Properties
- property alias cfg_time_font_size: timeFontSize.value
- property alias cfg_month_font_size: monthFontSize.value
- property alias cfg_year_font_size: yearFontSize.value
- property alias cfg_day_font_size: dayFontSize.value
- property alias cfg_timeap_font_size: timeAPFontSize.value
- property alias cfg_sys_mon_text_font_size: sysMonTextFontSize.value
- property alias cfg_sys_mon_usage_font_size: sysMonUsageFontSize.value
- property alias cfg_audio_title_font_size: audioTitleFontSize.value
- property alias cfg_audio_artist_font_size: audioArtistFontSize.value
- property alias cfg_now_playing_font_size: nowPlayingFontSize.value
- property alias cfg_global_font_size: globalFontSize.value
- property alias cfg_audio_image_width: audioImageWidth.value
-
- property alias cfg_date_spacing: dateSpacing.value
- property alias cfg_audio_spacing: audioSpacing.value
- property alias cfg_sys_mon_spacing: sysMonSpacing.value
-
- property alias cfg_text_background_color: textBackgroundColor.color
- property alias cfg_color_one: colorOne.color
- property alias cfg_color_two: colorTwo.color
- property alias cfg_color_three: colorThree.color
-
- property alias cfg_proportional_font: proportionalFont.checked
- property alias cfg_enable_shadows: enableShadows.checked
- property alias cfg_show_sys_mon: showSysMon.checked
- property alias cfg_show_audio: showAudio.checked
- property alias cfg_enable_fill_animation: enableFillAnimation.checked
- property alias cfg_show_date: showDate.checked
- property alias cfg_enable_24_hour: enable24Hour.checked
- property alias cfg_use_system_colors: useSystemColors.checked
-ColumnLayout {
- Title {
- text: i18n("Font Sizes")
- }
- BooleanField {
- id: proportionalFont
- text: i18n("Use proportional font")
- }
- NumberField {
- id: globalFontSize
- text: i18n("Global font size")
- enabled: proportionalFont.checked
- }
- NumberField {
- id: monthFontSize
- text: i18n("Month")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: yearFontSize
- text: i18n("Year")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: dayFontSize
- text: i18n("Day")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: timeFontSize
- text: i18n("Time")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: timeAPFontSize
- text: i18n("AM/PM")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: sysMonTextFontSize
- text: i18n("System monitor title")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: sysMonUsageFontSize
- text: i18n("System monitor usage")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: audioTitleFontSize
- text: i18n("Music title")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: audioArtistFontSize
- text: i18n("Music artist")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: nowPlayingFontSize
- text: i18n("\"Now Playing\" text")
- enabled: !proportionalFont.checked
- }
- NumberField {
- id: audioImageWidth
- text: i18n("Music thumbnail width")
- enabled: !proportionalFont.checked
- }
-
- Title {
- text: i18n("Spacing")
- }
- NumberField {
- id: dateSpacing
- text: i18n("Spacing between the month, day and year")
- }
- NumberField {
- id: sysMonSpacing
- text: i18n("Spacing between system monitor and time")
- }
- NumberField {
- id: audioSpacing
- text: i18n("Spacing between \"Now Playing\" and time")
- }
-
- Title {
- text: i18n("Colors")
- }
- BooleanField {
- id: useSystemColors
- text: i18n("Use colors from the current color scheme")
- }
- ColorField {
- id: textBackgroundColor
- text: "Text Background Color"
- }
- ColorField {
- id: colorOne
- text: "Color 1"
- }
- ColorField {
- id: colorTwo
- text: "Color 2"
- }
- ColorField {
- id: colorThree
- text: "Color 3"
- }
-
-
- Title {
- text: i18n("Other")
- }
- BooleanField {
- id: enableShadows
- text: i18n("Enable shadows")
- }
- BooleanField {
- id: showDate
- text: i18n("Show Date")
- }
- BooleanField {
- id: showSysMon
- text: i18n("Show System Monitor")
- }
- BooleanField {
- id: showAudio
- text: i18n("Show \"Now Playing\"")
- }
- BooleanField {
- id: enableFillAnimation
- text: i18n("Show Fill Animation")
- }
- BooleanField {
- id: enable24Hour
- text: i18n("Use 24 hour clock")
- }
-
-
-
- // Tight Spacing
- Item {
- Layout.fillHeight: true
- }
-}
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configPreferences.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configPreferences.qml
deleted file mode 100644
index 4747124..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/configPreferences.qml
+++ /dev/null
@@ -1,20 +0,0 @@
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-import org.kde.kcmutils as KCM
-
-KCM.SimpleKCM {
-ColumnLayout {
- property alias cfg_sys_mon_interval: sysMonInterval.value
- Title {
- text: i18n("System Monitor")
- }
- NumberField {
- id: sysMonInterval
- text: i18n("Interval (in milliseconds)")
- }
- Item {
- Layout.fillHeight: true
- }
-}
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/main.qml b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/main.qml
deleted file mode 100644
index 4206bf9..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/contents/ui/main.qml
+++ /dev/null
@@ -1,353 +0,0 @@
-// IMPORT
-// QtQuick
-import QtQuick
-import QtQuick.Controls
-import QtQuick.Layouts
-import QtQml
-
-// Plasma Modules
-import org.kde.plasma.plasmoid
-import org.kde.plasma.core as PlasmaCore
-import org.kde.plasma.plasma5support as Plasma5Support
-import org.kde.plasma.components as PlasmaComponents
-
-// MAIN
-PlasmoidItem {
- id: root
-
- // Loading Fonts
- FontLoader {
- id: defaultFont
- source: "../fonts/Hasteristico.ttf"
- }
-
- // Properties
- // Fonts
- property var fontFamily: defaultFont.name
-
- // Booleans
- property bool proportionalFont: Plasmoid.configuration.proportional_font
- property bool enableShadows: Plasmoid.configuration.enable_shadows
- property bool showDate: Plasmoid.configuration.show_date
- property bool showSysMon: Plasmoid.configuration.show_sys_mon
- property bool enableFillAnimation: Plasmoid.configuration.enable_fill_animation
- property bool enable24Hour: Plasmoid.configuration.enable_24_hour
- property bool useSystemColors: Plasmoid.configuration.use_system_colors
- // Font Sizes
- property int globalFontSize: Plasmoid.configuration.global_font_size
- property int monthFontSize: proportionalFont ? globalFontSize * 0.24 : Plasmoid.configuration.month_font_size
- property int dayFontSize: proportionalFont ? globalFontSize * 0.54 : Plasmoid.configuration.day_font_size
- property int yearFontSize: proportionalFont ? globalFontSize * 0.19 : Plasmoid.configuration.year_font_size
- property int timeFontSize: proportionalFont ? globalFontSize * 1.25 : Plasmoid.configuration.time_font_size
- property int timeAPFontSize: proportionalFont ? globalFontSize * 0.24 : Plasmoid.configuration.timeap_font_size
- property int sysMonTextFontSize: proportionalFont ? globalFontSize * 0.19 : Plasmoid.configuration.sys_mon_text_font_size
- property int sysMonUsageFontSize: proportionalFont ? globalFontSize * 0.1 : Plasmoid.configuration.sys_mon_usage_font_size
- property int audioTitleFontSize: proportionalFont ? globalFontSize * 0.1 : Plasmoid.configuration.audio_title_font_size
- property int audioArtistFontSize: proportionalFont ? globalFontSize * 0.07 : Plasmoid.configuration.audio_artist_font_size
- property int nowPlayingFontSize: proportionalFont ? globalFontSize * 0.08: Plasmoid.configuration.now_playing_font_size
- property int audioImageWidth: proportionalFont ? globalFontSize * 0.25 : Plasmoid.configuration.audio_image_width
-
- // subtracting some amount of spacing because this font has really big line height
- property int sysMonSpacing: -40 + Plasmoid.configuration.sys_mon_spacing
- property int audioSpacing: -20 + Plasmoid.configuration.audio_spacing
- property int dateSpacing: -15 + Plasmoid.configuration.date_spacing
-
- // Other
- property int sysMonInterval: Plasmoid.configuration.sys_mon_interval
-
- // Colors
- property string textBackgroundColor: useSystemColors ? PlasmaCore.Theme.backgroundColor : Plasmoid.configuration.text_background_color
- property string colorOne: useSystemColors ? PlasmaCore.Theme.negativeTextColor : Plasmoid.configuration.color_one
- property string colorTwo: useSystemColors ? PlasmaCore.Theme.positiveTextColor : Plasmoid.configuration.color_two
- property string colorThree: useSystemColors ? PlasmaCore.Theme.neutralTextColor : Plasmoid.configuration.color_three
-
- // Plasmoid
- fullRepresentation: Item {
- id: widget
- Plasmoid.backgroundHints: (enableShadows ? PlasmaCore.Types.ShadowBackground : PlasmaCore.Types.NoBackground) | PlasmaCore.Types.ConfigurableBackground
- Layout.minimumWidth: wrapper.implicitWidth + 50
- Layout.minimumHeight: wrapper.implicitHeight + 50
-
-
- // Time Data Source
- Plasma5Support.DataSource {
- id: timeSource
- engine: "time"
- connectedSources: ["Local"]
- interval: 1000
- signal fillDataChanged
- property bool use24Hour: root.enable24Hour
-
- onDataChanged: {
- var curDate = timeSource.data["Local"]["DateTime"]
-
- var DAY = parseInt(Qt.formatDate(curDate, "dd"))
- var HOUR = parseInt(Qt.formatTime(curDate, "hh"))
- var HOURAP = HOUR > 12 || HOUR == 0 ? Math.abs(HOUR - 12) : HOUR
- var MIN = parseInt(Qt.formatTime(curDate, "mm"))
- month.text = Qt.formatDate(curDate, "MMM")
- year.text = Qt.formatDate(curDate, "yyyy")
- timeAP.text = use24Hour ? ":" : Qt.formatTime(curDate, "AP")
-
- if (enable24Hour) {
- hours.text = HOUR
- } else {
- hours.text = HOURAP < 10 ? "0" + HOURAP.toString(): HOURAP
- }
- day.text = DAY < 10 ? "0" + DAY.toString() : DAY
- minutes.text = MIN < 10 ? "0" + MIN.toString() : MIN
-
- if (enableFillAnimation) fillDataChanged()
- }
- onUse24HourChanged: {
- dataChanged()
- }
- onFillDataChanged: {
- var curDate = timeSource.data["Local"]["DateTime"]
- // updating minute fill value each second
- minutes.currentVal = parseInt(Qt.formatTime(curDate, "ss"))
- hours.currentVal = parseInt(minutes.text)
- day.currentVal = parseInt(Qt.formatTime(curDate,"hh"))+1
- month.to = daysInMonth(parseInt(Qt.formatDate(curDate, "MM")), parseInt(year.text))
- month.currentVal = parseInt(day.text)
- year.currentVal = parseInt(Qt.formatDate(curDate, "MM"))
- if(!use24Hour) {
- timeAP.currentVal = timeAP.text == "AM" ? 1 : 2
- }
- }
-
- }
-
- // Return days in a month to get fill data for the current month
- function daysInMonth (month, year) {
- return new Date(year, month, 0).getDate();
- }
-
- // System Monitor Data Source
- Plasma5Support.DataSource {
- id: sysMonSource
- engine: "systemmonitor"
- connectedSources: ["mem/physical/available", "cpu/system/TotalLoad", "system/uptime"]
- interval: sysMonInterval
- onDataChanged: {
- cpuUsage.usage = Math.round(data["cpu/system/TotalLoad"]["value"])
- var ramUsageData = data["mem/physical/available"]
- ramUsage.usage = Math.round(((ramUsageData["max"]-ramUsageData["value"])/ramUsageData["max"])*100)
-
- // uptime
- var up = parseInt((data["system/uptime"]["value"]))
- if (up < 60) {
- uptime.unit = "s"
- uptime.from = 0
- uptime.to = 60
- } else if (up < 3600) {
- uptime.unit = "m"
- uptime.from = 0
- uptime.to = 60
- up = up/60
- } else if (up < 86400) {
- uptime.unit = "h"
- uptime.from = 0
- uptime.to = 24
- up = up/3600
- } else {
- uptime.unit = "d"
- uptime.from = 0
- uptime.to = 365
- up = up/86400
- }
- uptime.usage = parseInt(up)
- }
- }
-
- // Music Data Source
- Plasma5Support.DataSource {
- id: musicSource
- engine: "mpris2"
- property bool showAudio: Plasmoid.configuration.show_audio
-
- onDataChanged: {
- connectedSources = ["@multiplex"]
- var audioData = data["@multiplex"]
-
-
- // show if and only if the audio source exists, the metadata exists, showAudio is enabled and the audio is currently playing
- if (audioData && showAudio && audioData["PlaybackStatus"] === "Playing") {
- sectionAudio.visible = true
-
- var audioMetadata = audioData["Metadata"]
- var title = audioMetadata["xesam:title"]
- var artist = audioMetadata["xesam:artist"]
- var thumb = audioMetadata["mpris:artUrl"]
-
- audioTitle.text = title ? title : ""
- audioThumb.source = thumb ? thumb : ""
-
- try {
- audioArtist.text = artist.join(", ")
- } catch(err) {
- audioArtist.text = artist
- }
- } else {
- sectionAudio.visible = false
- }
- }
- onSourcesChanged: {
- dataChanged()
- }
- onSourceRemoved: {
- dataChanged()
- }
- onShowAudioChanged: {
- dataChanged()
- }
- Component.onCompleted: {
- dataChanged()
- }
- }
-
-
- // Layout
- ColumnLayout {
- id: wrapper
- anchors.centerIn: parent
- RowLayout {
- id: sectionAudio
- Layout.fillWidth: true
- Layout.bottomMargin: audioSpacing
- ColumnLayout {
- id: nowPlaying
- property var fontSize: nowPlayingFontSize;
- FontLabel {
- fill: false
- color: colorOne
- text: "Now"
- Layout.alignment: Qt.AlignRight
- font.pixelSize: nowPlaying.fontSize
- }
- FontLabel {
- fill: false
- color: colorOne
- text: "Playing"
- Layout.alignment: Qt.AlignRight
- font.pixelSize: nowPlaying.fontSize
- }
- }
- Image {
- id: audioThumb
- fillMode: Image.PreserveAspectCrop
- Layout.maximumHeight: audioImageWidth
- Layout.maximumWidth: audioImageWidth
- }
- ColumnLayout {
- FontLabel {
- id: audioTitle
- color: colorTwo
- fill: false
- font.pixelSize: audioTitleFontSize
- elide: Text.ElideRight
- labelWidth: sectionTime.width
- Layout.alignment: Qt.AlignLeft
- }
- FontLabel {
- id: audioArtist
- color: colorThree
- fill: false
- font.pixelSize: audioArtistFontSize
- elide: Text.ElideRight
- labelWidth: sectionTime.width
- Layout.alignment: Qt.AlignLeft
- }
- }
- }
- RowLayout {
- id: sectionDateTime
- Layout.fillWidth: true
- Layout.fillHeight: true
- ColumnLayout {
- id: sectionDate
- Layout.alignment: Qt.AlignHCenter
- Layout.fillWidth: true
- spacing: dateSpacing
- visible: showDate
- FontLabel {
- id: month
- font.pixelSize: monthFontSize
- color: colorOne
- from: 0
- }
- FontLabel {
- id: day
- font.pixelSize: dayFontSize
- color: colorTwo
- from: 0
- to: 24
- }
- FontLabel {
- id: year
- font.pixelSize: yearFontSize
- color: colorThree
- from: 1
- to: 12
- }
- }
- RowLayout {
- id: sectionTime
- Layout.alignment: Qt.AlignHCenter
- Layout.fillWidth: true
- FontLabel {
- id: hours
- font.pixelSize: timeFontSize
- color: colorOne
- from: 0
- to: 60
- }
- FontLabel {
- id: timeAP
- font.pixelSize: timeAPFontSize
- color: colorThree
- from: 1
- to: 2
- }
- FontLabel {
- id: minutes
- font.pixelSize: timeFontSize
- color: colorTwo
- from: 0
- to: 60
- }
- }
- }
- RowLayout {
- id: sectionSysMon
- Layout.fillWidth: true
- Layout.topMargin: sysMonSpacing
- Layout.alignment: Qt.AlignRight
- visible: showSysMon
-
- SysMonLabel {
- id: cpuUsage
- text: "CPU"
- color: colorOne
- from: 0
- to: 100
- unit: "%"
- }
- SysMonLabel {
- id: ramUsage
- text: "RAM"
- color: colorTwo
- from: 0
- to: 100
- unit: "%"
- }
- SysMonLabel {
- id: uptime
- text: "UPTIME"
- color: colorThree
- }
- }
-
- }
- }
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/metadata.json b/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/metadata.json
deleted file mode 100644
index e9ccb78..0000000
--- a/Configs/Home/.local/share/plasma/plasmoids/com.github.prayag2.aestheticclock/metadata.json
+++ /dev/null
@@ -1,22 +0,0 @@
-{
- "KPlugin": {
- "Authors": [
- {
- "Email": "prayagjain2@gmail.com",
- "Name": "Prayag Jain"
- }
- ],
- "Category": "Date and Time",
- "Description": "An aesthetic looking and customizable widget with a built-in system monitor and media player!",
- "Icon": "org.kde.plasma.digitalclock",
- "Id": "com.github.prayag2.aestheticclock",
- "License": "GPLv3",
- "Name": "Aesthetic Clock",
- "ServiceTypes": ["Plasma/Applet"],
- "Version": "0.2.2",
- "Website": "https://github.com/prayag2/kde_aestheticclock"
- },
- "X-Plasma-API-Minimum-Version": "6.0",
- "X-Plasma-Provides": "org.kde.plasma.time,org.kde.plasma.date"
-
-}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/config/main.xml b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/config/main.xml
index 1f667e0..213c67d 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/config/main.xml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/config/main.xml
@@ -9,9 +9,6 @@
-
-
-
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/fr/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/fr/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo
index f48c94b..7f7901f 100644
Binary files a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/fr/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo and b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/fr/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/nl/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/nl/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo
index b635693..4bcecd8 100644
Binary files a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/nl/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo and b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/locale/nl/LC_MESSAGES/plasma_applet_com.gitlab.scias.advancedreboot.mo differ
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/BootManager.qml b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/BootManager.qml
index 7cf7702..f1bc1cf 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/BootManager.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/BootManager.qml
@@ -6,7 +6,7 @@ import org.kde.plasma.plasma5support as Plasma5Support
Item {
readonly property int minVersion: 251 // Minimum required systemd version
- readonly property int confVersion: 1 // Used to flush existing config data on new releases if needed
+ readonly property int confVersion: 2 // Used to flush existing config data on new releases if needed
readonly property string cmdSudo: "pkexec "
readonly property string cmdDbusPre: "busctl"
@@ -221,7 +221,7 @@ Item {
}
function getEntriesFull(root) {
- alog("Attempting to get fresh bootctl entries - root access: " + root)
+ alog("Attempting to get fresh bootctl entries - as root: " + root)
let cmd = cmdGetEntriesFull
if (root) cmd = cmdSudo + cmd
executable.exec(cmd)
@@ -234,6 +234,7 @@ Item {
showTitle: id == "firmware-setup" ? i18n("Firmware Setup") : i18n("Bootloader Menu"),
version: "",
bIcon: id == "firmware-setup" ? "settings" : "menu",
+ show: true,
})
alog("Added \"" + id + "\"")
}
@@ -255,6 +256,7 @@ Item {
showTitle: entry.showTitle,
version: entry.version ?? "",
bIcon: bIcon,
+ show: true,
})
alog("Added \"" + entry.id + "\"")
}
@@ -275,9 +277,9 @@ Item {
if (step >= BootManager.Ready) {
alog("Finished initialization - Error state: " + (step === BootManager.Error))
if (!reusedConfig) plasmoid.configuration.savedEntries = JSON.stringify(bootEntries)
- loaded(step)
-
- plasmoid.configuration.confVersion = confVersion
+ if (plasmoid.configuration.confVersion != confVersion) plasmoid.configuration.confVersion = confVersion
+ // Workaround mainview not updating sometimes...
+ ready(step)
// Ugly workaround to give info to config panels
plasmoid.configuration.checkState = [busctlOK,bootctlOK,canEfi,canMenu,canEntry,gotEntries]
plasmoid.configuration.appState = step
@@ -299,6 +301,6 @@ Item {
console.log("advancedreboot: " + msg)
}
- signal loaded(int step)
+ signal ready(int step)
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/FullRepresentation.qml b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/FullRepresentation.qml
index 488b537..7b9016f 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/FullRepresentation.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/FullRepresentation.qml
@@ -11,6 +11,7 @@ PlasmaExtras.Representation {
property var selectedEntry
property bool busy: false
+ property bool resetting: false
implicitWidth: Kirigami.Units.gridUnit * 20
implicitHeight: mainList.height + header.height + Kirigami.Units.largeSpacing
@@ -30,8 +31,11 @@ PlasmaExtras.Representation {
}
PlasmaComponents.ToolButton {
icon.name: "view-refresh"
- onClicked: plasmoid.internalAction("reset").trigger()
- PlasmaComponents.ToolTip { text: i18n("Reload this applet") }
+ onClicked: {
+ plasmoid.internalAction("reset").trigger()
+ resetting = true
+ }
+ PlasmaComponents.ToolTip { text: i18n("Reset this applet") }
}
PlasmaComponents.ToolButton {
icon.name: "configure"
@@ -58,7 +62,7 @@ PlasmaExtras.Representation {
required property string bIcon
required property string title
required property string version
- width: parent ? parent.width : 0 // BUG: Occasional error here
+ width: parent ? parent.width : 0
contentItem: RowLayout {
Layout.fillWidth: true
@@ -94,12 +98,12 @@ PlasmaExtras.Representation {
}
}
- // TODO: sections
- /*section.property: "system"
- section.delegate: Kirigami.ListSectionHeader {
- width: parent.width
- label: section == 1 ? "System entries" : "Custom entries"
- }*/
+ PlasmaComponents.BusyIndicator {
+ implicitWidth: 150
+ implicitHeight: 150
+ anchors.centerIn: parent
+ visible: bootMgr.step < BootManager.Ready || busy
+ }
ErrorMessage {
id: noEntriesMsg
@@ -114,13 +118,6 @@ PlasmaExtras.Representation {
}
}
- PlasmaComponents.BusyIndicator {
- implicitWidth: 150
- implicitHeight: 150
- anchors.centerIn: parent
- visible: bootMgr.step < BootManager.Ready || busy
- }
-
ErrorMessage {
id: notEligibleMsg
anchors.centerIn: parent
@@ -164,41 +161,40 @@ PlasmaExtras.Representation {
function updateModel() {
busy = true
shownEntries.clear()
- for (let entry of bootMgr.bootEntries) {
- if (!plasmoid.configuration.blacklist.includes(entry.id)) {
- shownEntries.append(entry)
+ try {
+ for (let entry of JSON.parse(plasmoid.configuration.savedEntries)) {
+ if (entry.show) shownEntries.append(entry)
}
}
+ catch (err) {
+ bootmgr.alog("Error parsing saved entries for the mainview: " + err)
+ }
busy = false
}
Component.onCompleted: {
- if (bootMgr.step === BootManager.Ready) {
- updateModel()
- }
+ if (bootMgr.step === BootManager.Ready || bootMgr.step === BootManager.Error) updateModel()
}
Connections {
- target: bootMgr
+ target: plasmoid.configuration
- function onLoaded(signal) {
- if (signal === BootManager.Ready) {
- bootMgr.alog("Boot entries are ready - Updating the listview")
+ function onValueChanged(value) {
+ if (bootMgr.step === BootManager.Ready && value == "savedEntries" && plasmoid.configuration.savedEntries) {
updateModel()
}
}
-
- }
+ }
+ // Workaround bug mainview not updating when ready
Connections {
- target: plasmoid.configuration
+ target: bootMgr
- function onValueChanged(value) {
- if (bootMgr.step === BootManager.Ready && value == "blacklist") {
- //bootMgr.alog("Configuration has changed - Updating the listview")
- updateModel()
+ function onReady(step) {
+ if (step === BootManager.Ready) {
+ resetting ? resetting = false : updateModel() // Prevent double refresh upon reset...
}
}
- }
+ }
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configEntries.qml b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configEntries.qml
index 78e4422..a84d1dd 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configEntries.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configEntries.qml
@@ -3,6 +3,7 @@ import QtQuick.Layouts 1.15
import QtQuick.Controls 2.15 as Controls
import org.kde.kirigami 2.20 as Kirigami
+import org.kde.plasma.components as PlasmaComponents
import org.kde.kcmutils as KCM
KCM.ScrollViewKCM {
@@ -10,32 +11,79 @@ KCM.ScrollViewKCM {
property alias cfg_rebootMode: rebootMode.currentIndex
property var allEntries: ListModel { }
+ readonly property var transition: Transition {
+ NumberAnimation { properties: "x,y"; duration: 300; easing.type: Easing.OutQuart }
+ }
header: Controls.Label {
Layout.fillWidth: true
horizontalAlignment: Text.AlignHCenter
- text: i18n("Displayed boot entries in the plasmoid view")
+ text: i18n("Toggle and rearrange entries displayed in the main view")
wrapMode: Text.WordWrap
}
view: ListView {
+ id: entriesView
focus: true
model: allEntries
- delegate: Controls.SwitchDelegate {
+ reuseItems: true
+ move: transition
+ displaced: transition
+
+ delegate: Rectangle {
+ required property int index
+ //required property string title
required property string showTitle
- required property string id
- required property string version
- width: ListView.view.width - ListView.view.leftMargin - ListView.view.rightMargin
- text: showTitle
- checked: !plasmoid.configuration.blacklist.includes(id)
- onToggled: toggleEntry(id, checked)
+ //required property string id
+ //required property string version
+ required property string bIcon
+ required property bool show
+ color: index % 2 == 0 ? Kirigami.Theme.backgroundColor : Kirigami.Theme.alternateBackgroundColor
+ width: parent.width
+ height: rowEntry.implicitHeight
+ RowLayout {
+ id: rowEntry
+ width: parent.width
+ Kirigami.Icon {
+ source: Qt.resolvedUrl("../../assets/icons/" + bIcon + ".svg")
+ color: Kirigami.Theme.colorSet
+ smooth: true
+ isMask: true
+ scale: 0.5
+ }
+ Controls.Label {
+ Layout.fillWidth: true
+ text: showTitle
+ elide: Text.ElideRight
+ }
+ Controls.ToolButton {
+ icon.name: show ? "password-show-on" : "password-show-off"
+ onClicked: toggleEntry(index, !show)
+ icon.color: show ? Kirigami.Theme.textColor : Kirigami.Theme.disabledTextColor
+ PlasmaComponents.ToolTip { text: i18n("Toggle display of this entry") }
+ }
+ Controls.ToolButton {
+ icon.name: "arrow-up"
+ onClicked: moveEntry(index, index - 1)
+ opacity: index > 0 ? 1 : 0
+ enabled: index > 0
+ PlasmaComponents.ToolTip { text: i18n("Move this entry up the list") }
+ }
+ Controls.ToolButton {
+ icon.name: "arrow-down"
+ onClicked: moveEntry(index, index + 1)
+ opacity: index < allEntries.count - 1 ? 1 : 0
+ enabled: index < allEntries.count - 1
+ PlasmaComponents.ToolTip { text: i18n("Move this entry down the list") }
+ }
+ }
}
ErrorMessage {
id: noEntriesMsg
sIcon: "dialog-error-symbolic"
message: i18n("No boot entries could be found.")
- show: !plasmoid.configuration.savedEntries || plasmoid.configuration.appState == 4
+ show: allEntries.count == 0 || plasmoid.configuration.appState == 4
}
//TODO: Placeholder while entries not ready yet
}
@@ -55,26 +103,52 @@ KCM.ScrollViewKCM {
}
}
- function toggleEntry(id, enabled) {
- // BUG/WORKAROUND: Have to use copy methods because direct modification (push) doesn't work...
- if (enabled) {
- plasmoid.configuration.blacklist = plasmoid.configuration.blacklist.filter((entry) => entry != id)
- }
- else {
- plasmoid.configuration.blacklist = plasmoid.configuration.blacklist.concat([id])
- }
+ function moveEntry(from, to) {
+ allEntries.move(from, to, 1)
+ saveEntries()
}
- Component.onCompleted: {
+ function toggleEntry(index, show) {
+ allEntries.setProperty(index, "show", show)
+ saveEntries()
+ }
+
+ function loadEntries() {
if (plasmoid.configuration.savedEntries) {
- for (const entry of JSON.parse(plasmoid.configuration.savedEntries)) {
- allEntries.append({
- id: entry.id,
- showTitle: entry.showTitle,
- version: entry.version
- })
+ try {
+ for (const entry of JSON.parse(plasmoid.configuration.savedEntries)) {
+ allEntries.append(entry)
+ }
+ }
+ catch (err) {
+ console.log("advancedreboot: Error parsing saved entries for the config view: " + err)
}
}
}
+ function saveEntries() {
+ let tmp = []
+ for (let i = 0; i < allEntries.count; i++) {
+ let entry = allEntries.get(i)
+ tmp.push({
+ id: entry.id,
+ title: entry.title,
+ showTitle: entry.showTitle,
+ version: entry.version,
+ bIcon: entry.bIcon,
+ show: entry.show,
+ })
+ }
+ try {
+ plasmoid.configuration.savedEntries = JSON.stringify(tmp)
+ }
+ catch (err) {
+ console.log("advancedreboot: Error saving entries from the config view: " + err)
+ }
+ }
+
+ Component.onCompleted: {
+ if (plasmoid.configuration.savedEntries) loadEntries()
+ }
+
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configInfo.qml b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configInfo.qml
index 5ba2d12..8ad0df2 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configInfo.qml
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/contents/ui/configInfo.qml
@@ -39,6 +39,7 @@ KCM.SimpleKCM {
Layout.fillWidth: true
Layout.leftMargin: Kirigami.Units.gridUnit*2
verticalAlignment: Text.AlignVCenter
+ elide: Text.ElideRight
text: modelData
}
Kirigami.Icon {
@@ -77,7 +78,6 @@ KCM.SimpleKCM {
standardButtons: Kirigami.Dialog.Ok | Kirigami.Dialog.Cancel
onAccepted: {
- plasmoid.configuration.blacklist = []
plasmoid.configuration.rebootMode = 0
plasmoid.internalAction("reset").trigger()
showPassiveNotification(i18n("This plasmoid's configuration and state have been reset."))
diff --git a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/metadata.json b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/metadata.json
index c140518..a9ab3a2 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/metadata.json
+++ b/Configs/Home/.local/share/plasma/plasmoids/com.gitlab.scias.advancedreboot/metadata.json
@@ -1,22 +1,22 @@
{
- "KPlugin": {
- "Authors": [
- {
- "Email": "khirac@proton.me",
- "Name": "Scias"
- }
- ],
- "Category": "Utilities",
- "Description": "Quickly reboot to a bootloader entry",
- "Description[fr]": "Redémarrage rapide vers une entrée de démarrage",
- "Icon": "chronometer-reset",
- "Id": "com.gitlab.scias.advancedreboot",
- "Name": "Advanced Reboot",
- "Name[fr]": "Redémarrage avancé",
- "Version": "0.53",
- "License": "Mozilla Public License 2.0",
- "Website": "https://www.gitlab.com/Scias/plasma-advancedreboot"
- },
- "KPackageStructure": "Plasma/Applet",
- "X-Plasma-API-Minimum-Version": "6.0"
+ "KPlugin": {
+ "Authors": [
+ {
+ "Email": "khirac@proton.me",
+ "Name": "Scias"
+ }
+ ],
+ "Category": "Utilities",
+ "Description": "Quickly reboot to a bootloader entry",
+ "Description[fr]": "Redémarrage rapide vers une entrée de démarrage",
+ "Icon": "chronometer-reset",
+ "Id": "com.gitlab.scias.advancedreboot",
+ "Name": "Advanced Reboot",
+ "Name[fr]": "Redémarrage avancé",
+ "Version": "0.60",
+ "License": "Mozilla Public License 2.0",
+ "Website": "https://www.gitlab.com/Scias/plasma-advancedreboot"
+ },
+ "KPackageStructure": "Plasma/Applet",
+ "X-Plasma-API-Minimum-Version": "6.0"
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/org.kde.netspeedWidget/metadata.json b/Configs/Home/.local/share/plasma/plasmoids/org.kde.netspeedWidget/metadata.json
index 3e27f41..39cba66 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/org.kde.netspeedWidget/metadata.json
+++ b/Configs/Home/.local/share/plasma/plasmoids/org.kde.netspeedWidget/metadata.json
@@ -1,25 +1,26 @@
{
- "KPlugin": {
- "Authors": [
- {
- "Email": "hessijames@gmail.com",
- "Name": "Daniel Faust"
- }
- ],
- "Category": "System Information",
- "Description": "Displays the currently used network bandwidth",
- "Icon": "network-connect",
- "Id": "org.kde.netspeedWidget",
- "License": "GPL2",
- "Name": "Netspeed Widget",
- "KPackageStructure": [
- "Plasma/Applet"
- ],
- "Version": "3.1",
- "Website": "https://github.com/dfaust/plasma-applet-netspeed-widget"
- },
- "X-KDE-ParentApp": "",
- "X-Plasma-API-Minimum-Version": "6.0",
- "X-Plasma-MainScript": "ui/main.qml",
- "X-Plasma-RemoteLocation": ""
+ "KPlugin": {
+ "Authors": [
+ {
+ "Email": "hessijames@gmail.com",
+ "Name": "Daniel Faust"
+ }
+ ],
+ "Category": "System Information",
+ "Description": "Displays the currently used network bandwidth",
+ "Icon": "network-connect",
+ "Id": "org.kde.netspeedWidget",
+ "License": "GPL2",
+ "Name": "Netspeed Widget",
+ "KPackageStructure": [
+ "Plasma/Applet"
+ ],
+ "Version": "3.1",
+ "Website": "https://github.com/dfaust/plasma-applet-netspeed-widget"
+ },
+ "X-KDE-ParentApp": "",
+ "X-Plasma-API-Minimum-Version": "6.0",
+ "X-Plasma-MainScript": "ui/main.qml",
+ "X-Plasma-RemoteLocation": "",
+ "KPackageStructure": "Plasma/Applet"
}
diff --git a/Configs/Home/.local/share/plasma/plasmoids/zayron.simple.separator/metadata.json b/Configs/Home/.local/share/plasma/plasmoids/zayron.simple.separator/metadata.json
index 739c733..d80a9b5 100644
--- a/Configs/Home/.local/share/plasma/plasmoids/zayron.simple.separator/metadata.json
+++ b/Configs/Home/.local/share/plasma/plasmoids/zayron.simple.separator/metadata.json
@@ -1,23 +1,24 @@
{
- "KPlugin": {
- "Authors": [
- {
- "Name": "zayronxio"
- }
- ],
- "Name": "simple separator",
- "Id": "zayron.simple.separator",
- "Description": "a simple separator",
- "Category": "Utilities",
- "Icon": "setting",
- "EnabledByDefault": true,
- "License": "GPL-3.0+",
- "ServiceTypes": [
- "Plasma/Applet"
- ],
- "Version": "1.0.4",
- "Website": ""
- },
- "X-Plasma-API-Minimum-Version": "6.0",
- "X-Plasma-MainScript": "ui/main.qml"
+ "KPlugin": {
+ "Authors": [
+ {
+ "Name": "zayronxio"
+ }
+ ],
+ "Name": "simple separator",
+ "Id": "zayron.simple.separator",
+ "Description": "a simple separator",
+ "Category": "Utilities",
+ "Icon": "setting",
+ "EnabledByDefault": true,
+ "License": "GPL-3.0+",
+ "ServiceTypes": [
+ "Plasma/Applet"
+ ],
+ "Version": "1.0.3",
+ "Website": ""
+ },
+ "X-Plasma-API-Minimum-Version": "6.0",
+ "X-Plasma-MainScript": "ui/main.qml",
+ "KPackageStructure": "Plasma/Applet"
}
diff --git a/install.sh b/install.sh
index 65cee76..eb78395 100755
--- a/install.sh
+++ b/install.sh
@@ -9,7 +9,7 @@ echo "#############################"
echo
echo "Native Packages..."
echo
-sudo pacman -S --noconfirm --needed kvantum neofetch gtk-engine-murrine gtk-engines ttf-hack-nerd ttf-fira-code kdeconnect ttf-terminus-nerd noto-fonts-emoji ttf-meslo-nerd kde-wallpapers
+sudo pacman -S --noconfirm --needed kvantum jq xmlstarlet neofetch gtk-engine-murrine gtk-engines ttf-hack-nerd ttf-fira-code kdeconnect ttf-terminus-nerd noto-fonts-emoji ttf-meslo-nerd kde-wallpapers
echo
echo "AUR Packages..."
echo