From d014ec2841c7d094956cfed05a85395f111c7dd6 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 14:35:04 +0100 Subject: [PATCH 01/28] :wrench: Compile locales --- Makefile | 45 ++++++++++++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index 6dc34d4..c6d8430 100644 --- a/Makefile +++ b/Makefile @@ -1,9 +1,13 @@ SHELL := /bin/bash JS_FILES = $(shell find -type f -and \( -name "*.js" \)) +UI_FILES = $(shell find -type f -and \( -name "*.ui" \)) RESOURCE_FILES = $(shell find resources -mindepth 2 -type f) -.PHONY: zip install uninstall clean +LOCALES_PO = $(wildcard po/*.po) +LOCALES_MO = $(patsubst po/%.po,locale/%/LC_MESSAGES/burn-my-windows.mo,$(LOCALES_PO)) + +.PHONY: zip install uninstall all-po pot clean zip: burn-my-windows@schneegans.github.com.zip @@ -14,23 +18,31 @@ install: burn-my-windows@schneegans.github.com.zip uninstall: gnome-extensions uninstall "burn-my-windows@schneegans.github.com" +all-po: $(LOCALES_PO) + +pot: $(JS_FILES) $(UI_FILES) + @echo "Generating 'burn-my-windows.pot'..." + @xgettext --from-code=UTF-8 \ + --add-comments=Translators \ + --copyright-holder="Simon Schneegans" \ + --package-name="Burn-My-Windows" \ + --output=po/burn-my-windows.pot \ + $(JS_FILES) $(UI_FILES) + clean: rm -rf \ burn-my-windows@schneegans.github.com.zip \ resources/burn-my-windows.gresource \ resources/burn-my-windows.gresource.xml \ - schemas/gschemas.compiled + schemas/gschemas.compiled \ + locale \ + ui/*.ui~ \ + po/*.po~ -burn-my-windows@schneegans.github.com.zip: schemas/gschemas.compiled resources/burn-my-windows.gresource $(JS_FILES) - @# Check if the VERSION variable was passed and set version to it - @if [[ "$(VERSION)" != "" ]]; then \ - sed -i "s| \"version\":.*| \"version\": $(VERSION)|g" metadata.json; \ - fi - @# TODO Maybe echo version number of the release that was built, in order to facilitate double-checking before publishing it? - +burn-my-windows@schneegans.github.com.zip: schemas/gschemas.compiled resources/burn-my-windows.gresource $(JS_FILES) $(LOCALES_MO) @echo "Packing zip file..." @rm --force burn-my-windows@schneegans.github.com.zip - @zip -r burn-my-windows@schneegans.github.com.zip -- *.js src/*.js resources/burn-my-windows.gresource schemas/gschemas.compiled metadata.json LICENSE + @zip -r burn-my-windows@schneegans.github.com.zip -- *.js src/*.js resources/burn-my-windows.gresource schemas/gschemas.compiled $(LOCALES_MO) metadata.json LICENSE @#Check if the zip size is too big to be uploaded @if [[ "$$(stat -c %s burn-my-windows@schneegans.github.com.zip)" -gt 4096000 ]]; then \ @@ -48,4 +60,15 @@ resources/burn-my-windows.gresource.xml: $(RESOURCE_FILES) schemas/gschemas.compiled: schemas/org.gnome.shell.extensions.burn-my-windows.gschema.xml @echo "Compiling schemas..." - @glib-compile-schemas schemas \ No newline at end of file + @glib-compile-schemas schemas + +locale/%/LC_MESSAGES/burn-my-windows.mo: po/%.po + @echo "Compiling $@" + @mkdir -p locale/$*/LC_MESSAGES + @msgfmt -c -o $@ $< + +po/%.po: + @echo "Updating $@" + msgmerge --previous --update $@ po/burn-my-windows.pot + @# Output translation progress + @msgfmt --check --verbose --output-file=/dev/null $@ \ No newline at end of file From 1692be778c836059932f13f3e37fafed20377ee0 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 14:35:23 +0100 Subject: [PATCH 02/28] :globe_with_meridians: Add initial translation template --- po/burn-my-windows.pot | 182 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 182 insertions(+) create mode 100644 po/burn-my-windows.pot diff --git a/po/burn-my-windows.pot b/po/burn-my-windows.pot new file mode 100644 index 0000000..2dc6f74 --- /dev/null +++ b/po/burn-my-windows.pot @@ -0,0 +1,182 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR Simon Schneegans +# This file is distributed under the same license as the Burn-My-Windows package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: Burn-My-Windows\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2022-01-28 14:12+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#: resources/ui/common/main-menu.ui:6 +msgid "Visit Homepage" +msgstr "" + +#: resources/ui/common/main-menu.ui:10 +msgid "View Changelog" +msgstr "" + +#: resources/ui/common/main-menu.ui:16 +msgid "Report a Bug" +msgstr "" + +#: resources/ui/common/main-menu.ui:20 +msgid "Create a Custom Effect" +msgstr "" + +#: resources/ui/common/main-menu.ui:24 +msgid "Donate" +msgstr "" + +#: resources/ui/common/main-menu.ui:26 +msgid "Via PayPal" +msgstr "" + +#: resources/ui/common/main-menu.ui:30 +msgid "Via GitHub" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:24 resources/ui/gtk4/BrokenGlass.ui:24 +#: resources/ui/gtk4/Wisps.ui:24 resources/ui/gtk4/Fire.ui:49 +#: resources/ui/gtk4/TRexAttack.ui:24 resources/ui/gtk4/TVEffect.ui:24 +#: resources/ui/gtk4/EnergizeA.ui:24 resources/ui/gtk4/EnergizeB.ui:24 +#: resources/ui/gtk3/Wisps.ui:42 resources/ui/gtk3/Fire.ui:93 +#: resources/ui/gtk3/TVEffect.ui:35 resources/ui/gtk3/EnergizeA.ui:42 +#: resources/ui/gtk3/EnergizeB.ui:42 +msgid "Animation Time [ms]" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:70 resources/ui/gtk4/BrokenGlass.ui:70 +#: resources/ui/gtk4/Wisps.ui:70 resources/ui/gtk4/Fire.ui:95 +#: resources/ui/gtk4/EnergizeA.ui:70 resources/ui/gtk4/EnergizeB.ui:70 +#: resources/ui/gtk3/Wisps.ui:91 resources/ui/gtk3/Fire.ui:141 +#: resources/ui/gtk3/EnergizeA.ui:91 resources/ui/gtk3/EnergizeB.ui:91 +msgid "Scale" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:116 +msgid "Randomness" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:162 +msgid "Vertical Overshooting" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:208 +msgid "Trail Color" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:242 +msgid "Tip Color" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:116 +msgid "Gravity" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:162 +msgid "Blow Force" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:212 +msgid "Shatter From Pointer Location" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:221 +msgid "" +"The shards will fly away from where your mouse pointer was when closing the " +"window." +msgstr "" + +#: resources/ui/gtk4/Wisps.ui:116 resources/ui/gtk4/TVEffect.ui:70 +#: resources/ui/gtk4/EnergizeA.ui:116 resources/ui/gtk4/EnergizeB.ui:116 +#: resources/ui/gtk3/Wisps.ui:139 resources/ui/gtk3/TVEffect.ui:83 +#: resources/ui/gtk3/EnergizeA.ui:139 resources/ui/gtk3/EnergizeB.ui:139 +msgid "Color" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:25 resources/ui/gtk3/Fire.ui:49 +msgid "Presets" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:141 resources/ui/gtk3/Fire.ui:189 +msgid "Speed" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:191 resources/ui/gtk3/Fire.ui:241 +msgid "3D Noise" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:200 resources/ui/gtk3/Fire.ui:250 +msgid "Creates a more dynamic fire but requires more GPU power." +msgstr "" + +#: resources/ui/gtk4/Fire.ui:240 resources/ui/gtk3/Fire.ui:300 +msgid "Gradient" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:70 +msgid "Claw Scratch Scale" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:116 +msgid "Claw Scratch Count" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:162 +msgid "Warp Effect" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:208 +msgid "Flash Color" +msgstr "" + +#: resources/ui/gtk4/effectPage.ui:41 resources/ui/gtk3/effectPage.ui:41 +msgid "Preview this Effect" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:27 resources/ui/gtk3/prefs.ui:251 +msgid "General Options" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:47 resources/ui/gtk3/prefs.ui:49 +msgid "Welcome to Burn-My-Windows!" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:58 resources/ui/gtk3/prefs.ui:60 +msgid "If you like this extension, recommend it to your friends :)" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:85 resources/ui/gtk3/prefs.ui:88 +msgid "Open Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:94 resources/ui/gtk4/prefs.ui:138 +#: resources/ui/gtk3/prefs.ui:97 resources/ui/gtk3/prefs.ui:161 +msgid "If multiple are selected, one is chosen randomly." +msgstr "" + +#: resources/ui/gtk4/prefs.ui:129 resources/ui/gtk3/prefs.ui:152 +msgid "Close Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:169 resources/ui/gtk3/prefs.ui:212 +msgid "Also Add Effects to Dialogs" +msgstr "" + +#: resources/ui/gtk3/Fire.ui:63 +msgid "Choose a Preset" +msgstr "" + +#: resources/ui/gtk3/prefs.ui:118 resources/ui/gtk3/prefs.ui:182 +msgid "Choose Effects" +msgstr "" From fc902f2a736e258925929d4a24f6f52e6ecaf161 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 15:00:22 +0100 Subject: [PATCH 03/28] :globe_with_meridians: Update translation template --- po/burn-my-windows.pot | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/po/burn-my-windows.pot b/po/burn-my-windows.pot index 2dc6f74..998acde 100644 --- a/po/burn-my-windows.pot +++ b/po/burn-my-windows.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-28 14:12+0100\n" +"POT-Creation-Date: 2022-01-28 14:59+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,6 +17,10 @@ msgstr "" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" +#: prefs.js:355 +msgid "Close this Window to Preview the Effect!" +msgstr "" + #: resources/ui/common/main-menu.ui:6 msgid "Visit Homepage" msgstr "" From f9b6f1ffbc25523c9cb0da43ea2bb91448b8c0dd Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 15:00:35 +0100 Subject: [PATCH 04/28] :wrench: Load translations --- prefs.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/prefs.js b/prefs.js index ffe9c17..2d5d93a 100644 --- a/prefs.js +++ b/prefs.js @@ -15,6 +15,8 @@ const {Gio, Gtk, Gdk, GLib, GObject} = imports.gi; +const _ = imports.gettext.domain('burn-my-windows').gettext; + const ExtensionUtils = imports.misc.extensionUtils; const Me = imports.misc.extensionUtils.getCurrentExtension(); const utils = Me.imports.src.utils; @@ -350,7 +352,7 @@ var PreferencesDialog = class PreferencesDialog { spacing: 10, }); - const label = Gtk.Label.new('Close this Window to Preview the Effect!'); + const label = Gtk.Label.new(_('Close this Window to Preview the Effect!')); label.get_style_context().add_class('large-title'); const image = new Gtk.Image({ @@ -376,8 +378,10 @@ var PreferencesDialog = class PreferencesDialog { } } -// Nothing to do for now... -function init() {} +// This is used for setting up the translations. +function init() { + ExtensionUtils.initTranslations(); +} // This function is called when the preferences window is created to build and return a // Gtk widget. We create a new instance of the PreferencesDialog class each time this From a3fa8254f74849f0c18bbd74495f7d500a4a6a96 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 14:50:22 +0100 Subject: [PATCH 05/28] :globe_with_meridians: Added translation using Weblate (German) --- po/de.po | 181 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 181 insertions(+) create mode 100644 po/de.po diff --git a/po/de.po b/po/de.po new file mode 100644 index 0000000..ea532e1 --- /dev/null +++ b/po/de.po @@ -0,0 +1,181 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR Simon Schneegans +# This file is distributed under the same license as the Burn-My-Windows package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: Burn-My-Windows\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2022-01-28 14:12+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: Automatically generated\n" +"Language-Team: none\n" +"Language: de\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: resources/ui/common/main-menu.ui:6 +msgid "Visit Homepage" +msgstr "" + +#: resources/ui/common/main-menu.ui:10 +msgid "View Changelog" +msgstr "" + +#: resources/ui/common/main-menu.ui:16 +msgid "Report a Bug" +msgstr "" + +#: resources/ui/common/main-menu.ui:20 +msgid "Create a Custom Effect" +msgstr "" + +#: resources/ui/common/main-menu.ui:24 +msgid "Donate" +msgstr "" + +#: resources/ui/common/main-menu.ui:26 +msgid "Via PayPal" +msgstr "" + +#: resources/ui/common/main-menu.ui:30 +msgid "Via GitHub" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:24 resources/ui/gtk4/BrokenGlass.ui:24 +#: resources/ui/gtk4/Wisps.ui:24 resources/ui/gtk4/Fire.ui:49 +#: resources/ui/gtk4/TRexAttack.ui:24 resources/ui/gtk4/TVEffect.ui:24 +#: resources/ui/gtk4/EnergizeA.ui:24 resources/ui/gtk4/EnergizeB.ui:24 +#: resources/ui/gtk3/Wisps.ui:42 resources/ui/gtk3/Fire.ui:93 +#: resources/ui/gtk3/TVEffect.ui:35 resources/ui/gtk3/EnergizeA.ui:42 +#: resources/ui/gtk3/EnergizeB.ui:42 +msgid "Animation Time [ms]" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:70 resources/ui/gtk4/BrokenGlass.ui:70 +#: resources/ui/gtk4/Wisps.ui:70 resources/ui/gtk4/Fire.ui:95 +#: resources/ui/gtk4/EnergizeA.ui:70 resources/ui/gtk4/EnergizeB.ui:70 +#: resources/ui/gtk3/Wisps.ui:91 resources/ui/gtk3/Fire.ui:141 +#: resources/ui/gtk3/EnergizeA.ui:91 resources/ui/gtk3/EnergizeB.ui:91 +msgid "Scale" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:116 +msgid "Randomness" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:162 +msgid "Vertical Overshooting" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:208 +msgid "Trail Color" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:242 +msgid "Tip Color" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:116 +msgid "Gravity" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:162 +msgid "Blow Force" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:212 +msgid "Shatter From Pointer Location" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:221 +msgid "" +"The shards will fly away from where your mouse pointer was when closing the " +"window." +msgstr "" + +#: resources/ui/gtk4/Wisps.ui:116 resources/ui/gtk4/TVEffect.ui:70 +#: resources/ui/gtk4/EnergizeA.ui:116 resources/ui/gtk4/EnergizeB.ui:116 +#: resources/ui/gtk3/Wisps.ui:139 resources/ui/gtk3/TVEffect.ui:83 +#: resources/ui/gtk3/EnergizeA.ui:139 resources/ui/gtk3/EnergizeB.ui:139 +msgid "Color" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:25 resources/ui/gtk3/Fire.ui:49 +msgid "Presets" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:141 resources/ui/gtk3/Fire.ui:189 +msgid "Speed" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:191 resources/ui/gtk3/Fire.ui:241 +msgid "3D Noise" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:200 resources/ui/gtk3/Fire.ui:250 +msgid "Creates a more dynamic fire but requires more GPU power." +msgstr "" + +#: resources/ui/gtk4/Fire.ui:240 resources/ui/gtk3/Fire.ui:300 +msgid "Gradient" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:70 +msgid "Claw Scratch Scale" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:116 +msgid "Claw Scratch Count" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:162 +msgid "Warp Effect" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:208 +msgid "Flash Color" +msgstr "" + +#: resources/ui/gtk4/effectPage.ui:41 resources/ui/gtk3/effectPage.ui:41 +msgid "Preview this Effect" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:27 resources/ui/gtk3/prefs.ui:251 +msgid "General Options" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:47 resources/ui/gtk3/prefs.ui:49 +msgid "Welcome to Burn-My-Windows!" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:58 resources/ui/gtk3/prefs.ui:60 +msgid "If you like this extension, recommend it to your friends :)" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:85 resources/ui/gtk3/prefs.ui:88 +msgid "Open Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:94 resources/ui/gtk4/prefs.ui:138 +#: resources/ui/gtk3/prefs.ui:97 resources/ui/gtk3/prefs.ui:161 +msgid "If multiple are selected, one is chosen randomly." +msgstr "" + +#: resources/ui/gtk4/prefs.ui:129 resources/ui/gtk3/prefs.ui:152 +msgid "Close Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:169 resources/ui/gtk3/prefs.ui:212 +msgid "Also Add Effects to Dialogs" +msgstr "" + +#: resources/ui/gtk3/Fire.ui:63 +msgid "Choose a Preset" +msgstr "" + +#: resources/ui/gtk3/prefs.ui:118 resources/ui/gtk3/prefs.ui:182 +msgid "Choose Effects" +msgstr "" From b95fbac409407046436d537de878149af64902ce Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 13:52:16 +0000 Subject: [PATCH 06/28] :globe_with_meridians: Translated using Weblate (German) --- po/de.po | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/po/de.po b/po/de.po index ea532e1..55ef13f 100644 --- a/po/de.po +++ b/po/de.po @@ -8,41 +8,44 @@ msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2022-01-28 14:12+0100\n" -"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" -"Last-Translator: Automatically generated\n" -"Language-Team: none\n" +"PO-Revision-Date: 2022-01-28 13:52+0000\n" +"Last-Translator: Simon Schneegans \n" +"Language-Team: German \n" "Language: de\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.11-dev\n" #: resources/ui/common/main-menu.ui:6 msgid "Visit Homepage" -msgstr "" +msgstr "Homepage besuchen" #: resources/ui/common/main-menu.ui:10 msgid "View Changelog" -msgstr "" +msgstr "Changelog anzeigen" #: resources/ui/common/main-menu.ui:16 msgid "Report a Bug" -msgstr "" +msgstr "Fehler melden" #: resources/ui/common/main-menu.ui:20 msgid "Create a Custom Effect" -msgstr "" +msgstr "Einen neuen Effekt erstellen" #: resources/ui/common/main-menu.ui:24 msgid "Donate" -msgstr "" +msgstr "Spenden" #: resources/ui/common/main-menu.ui:26 msgid "Via PayPal" -msgstr "" +msgstr "Mit PayPal" #: resources/ui/common/main-menu.ui:30 msgid "Via GitHub" -msgstr "" +msgstr "Mit GitHub" #: resources/ui/gtk4/Matrix.ui:24 resources/ui/gtk4/BrokenGlass.ui:24 #: resources/ui/gtk4/Wisps.ui:24 resources/ui/gtk4/Fire.ui:49 From 357c5063704b852f6d3005c75513713b9de8e5da Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 20:09:19 +0100 Subject: [PATCH 07/28] :wrench: Add another translatable string --- .gitignore | 1 + po/burn-my-windows.pot | 10 ++++++++-- prefs.js | 3 ++- resources/ui/gtk3/prefs.ui | 2 +- resources/ui/gtk4/prefs.ui | 2 +- 5 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 77585ec..11da693 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,7 @@ *.blend1 *.blend2 *.blend3 +/locale /schemas/gschemas.compiled /resources/burn-my-windows.gresource /resources/burn-my-windows.gresource.xml \ No newline at end of file diff --git a/po/burn-my-windows.pot b/po/burn-my-windows.pot index 998acde..a9c5f3b 100644 --- a/po/burn-my-windows.pot +++ b/po/burn-my-windows.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-28 14:59+0100\n" +"POT-Creation-Date: 2022-01-28 20:08+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,7 +17,13 @@ msgstr "" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" -#: prefs.js:355 +#. Translators: %s will be replaced by the effect's name. +#: prefs.js:336 +#, javascript-format +msgid "Preview for %s" +msgstr "" + +#: prefs.js:356 msgid "Close this Window to Preview the Effect!" msgstr "" diff --git a/prefs.js b/prefs.js index 2d5d93a..26e2a23 100644 --- a/prefs.js +++ b/prefs.js @@ -332,7 +332,8 @@ var PreferencesDialog = class PreferencesDialog { // Create the preview-window. const window = new Gtk.Window({ - title: `Preview for ${Effect.getLabel()}`, + // Translators: %s will be replaced by the effect's name. + title: _('Preview for %s').replace("%s", Effect.getLabel()), default_width: 800, default_height: 450, modal: true, diff --git a/resources/ui/gtk3/prefs.ui b/resources/ui/gtk3/prefs.ui index 708d1f5..b52ebf4 100644 --- a/resources/ui/gtk3/prefs.ui +++ b/resources/ui/gtk3/prefs.ui @@ -1,5 +1,5 @@ - + diff --git a/resources/ui/gtk4/prefs.ui b/resources/ui/gtk4/prefs.ui index a4182b1..02ea86b 100644 --- a/resources/ui/gtk4/prefs.ui +++ b/resources/ui/gtk4/prefs.ui @@ -1,5 +1,5 @@ - + From 9d324bfff3175bb01aa674285b15d088fbe82d9a Mon Sep 17 00:00:00 2001 From: "J. Lavoie" Date: Fri, 28 Jan 2022 19:12:43 +0100 Subject: [PATCH 08/28] :globe_with_meridians: Added translation using Weblate (French) --- po/fr.po | 185 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 185 insertions(+) create mode 100644 po/fr.po diff --git a/po/fr.po b/po/fr.po new file mode 100644 index 0000000..cbd992a --- /dev/null +++ b/po/fr.po @@ -0,0 +1,185 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR Simon Schneegans +# This file is distributed under the same license as the Burn-My-Windows package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: Burn-My-Windows\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2022-01-28 14:59+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: Automatically generated\n" +"Language-Team: none\n" +"Language: fr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: prefs.js:355 +msgid "Close this Window to Preview the Effect!" +msgstr "" + +#: resources/ui/common/main-menu.ui:6 +msgid "Visit Homepage" +msgstr "" + +#: resources/ui/common/main-menu.ui:10 +msgid "View Changelog" +msgstr "" + +#: resources/ui/common/main-menu.ui:16 +msgid "Report a Bug" +msgstr "" + +#: resources/ui/common/main-menu.ui:20 +msgid "Create a Custom Effect" +msgstr "" + +#: resources/ui/common/main-menu.ui:24 +msgid "Donate" +msgstr "" + +#: resources/ui/common/main-menu.ui:26 +msgid "Via PayPal" +msgstr "" + +#: resources/ui/common/main-menu.ui:30 +msgid "Via GitHub" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:24 resources/ui/gtk4/BrokenGlass.ui:24 +#: resources/ui/gtk4/Wisps.ui:24 resources/ui/gtk4/Fire.ui:49 +#: resources/ui/gtk4/TRexAttack.ui:24 resources/ui/gtk4/TVEffect.ui:24 +#: resources/ui/gtk4/EnergizeA.ui:24 resources/ui/gtk4/EnergizeB.ui:24 +#: resources/ui/gtk3/Wisps.ui:42 resources/ui/gtk3/Fire.ui:93 +#: resources/ui/gtk3/TVEffect.ui:35 resources/ui/gtk3/EnergizeA.ui:42 +#: resources/ui/gtk3/EnergizeB.ui:42 +msgid "Animation Time [ms]" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:70 resources/ui/gtk4/BrokenGlass.ui:70 +#: resources/ui/gtk4/Wisps.ui:70 resources/ui/gtk4/Fire.ui:95 +#: resources/ui/gtk4/EnergizeA.ui:70 resources/ui/gtk4/EnergizeB.ui:70 +#: resources/ui/gtk3/Wisps.ui:91 resources/ui/gtk3/Fire.ui:141 +#: resources/ui/gtk3/EnergizeA.ui:91 resources/ui/gtk3/EnergizeB.ui:91 +msgid "Scale" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:116 +msgid "Randomness" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:162 +msgid "Vertical Overshooting" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:208 +msgid "Trail Color" +msgstr "" + +#: resources/ui/gtk4/Matrix.ui:242 +msgid "Tip Color" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:116 +msgid "Gravity" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:162 +msgid "Blow Force" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:212 +msgid "Shatter From Pointer Location" +msgstr "" + +#: resources/ui/gtk4/BrokenGlass.ui:221 +msgid "" +"The shards will fly away from where your mouse pointer was when closing the " +"window." +msgstr "" + +#: resources/ui/gtk4/Wisps.ui:116 resources/ui/gtk4/TVEffect.ui:70 +#: resources/ui/gtk4/EnergizeA.ui:116 resources/ui/gtk4/EnergizeB.ui:116 +#: resources/ui/gtk3/Wisps.ui:139 resources/ui/gtk3/TVEffect.ui:83 +#: resources/ui/gtk3/EnergizeA.ui:139 resources/ui/gtk3/EnergizeB.ui:139 +msgid "Color" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:25 resources/ui/gtk3/Fire.ui:49 +msgid "Presets" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:141 resources/ui/gtk3/Fire.ui:189 +msgid "Speed" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:191 resources/ui/gtk3/Fire.ui:241 +msgid "3D Noise" +msgstr "" + +#: resources/ui/gtk4/Fire.ui:200 resources/ui/gtk3/Fire.ui:250 +msgid "Creates a more dynamic fire but requires more GPU power." +msgstr "" + +#: resources/ui/gtk4/Fire.ui:240 resources/ui/gtk3/Fire.ui:300 +msgid "Gradient" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:70 +msgid "Claw Scratch Scale" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:116 +msgid "Claw Scratch Count" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:162 +msgid "Warp Effect" +msgstr "" + +#: resources/ui/gtk4/TRexAttack.ui:208 +msgid "Flash Color" +msgstr "" + +#: resources/ui/gtk4/effectPage.ui:41 resources/ui/gtk3/effectPage.ui:41 +msgid "Preview this Effect" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:27 resources/ui/gtk3/prefs.ui:251 +msgid "General Options" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:47 resources/ui/gtk3/prefs.ui:49 +msgid "Welcome to Burn-My-Windows!" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:58 resources/ui/gtk3/prefs.ui:60 +msgid "If you like this extension, recommend it to your friends :)" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:85 resources/ui/gtk3/prefs.ui:88 +msgid "Open Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:94 resources/ui/gtk4/prefs.ui:138 +#: resources/ui/gtk3/prefs.ui:97 resources/ui/gtk3/prefs.ui:161 +msgid "If multiple are selected, one is chosen randomly." +msgstr "" + +#: resources/ui/gtk4/prefs.ui:129 resources/ui/gtk3/prefs.ui:152 +msgid "Close Window Animation" +msgstr "" + +#: resources/ui/gtk4/prefs.ui:169 resources/ui/gtk3/prefs.ui:212 +msgid "Also Add Effects to Dialogs" +msgstr "" + +#: resources/ui/gtk3/Fire.ui:63 +msgid "Choose a Preset" +msgstr "" + +#: resources/ui/gtk3/prefs.ui:118 resources/ui/gtk3/prefs.ui:182 +msgid "Choose Effects" +msgstr "" From 58244cfbb4168fec25bbe75d8b752b36ab1b9806 Mon Sep 17 00:00:00 2001 From: Hosted Weblate Date: Fri, 28 Jan 2022 20:05:55 +0100 Subject: [PATCH 09/28] :globe_with_meridians: Update translation files --- po/de.po | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/po/de.po b/po/de.po index 55ef13f..f35d0ab 100644 --- a/po/de.po +++ b/po/de.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-28 14:12+0100\n" +"POT-Creation-Date: 2022-01-28 14:59+0100\n" "PO-Revision-Date: 2022-01-28 13:52+0000\n" "Last-Translator: Simon Schneegans \n" "Language-Team: German Date: Fri, 28 Jan 2022 20:09:32 +0100 Subject: [PATCH 10/28] :globe_with_meridians: Update translation files --- po/de.po | 10 ++++++++-- po/fr.po | 10 ++++++++-- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/po/de.po b/po/de.po index f35d0ab..dbbaa35 100644 --- a/po/de.po +++ b/po/de.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-01-28 14:59+0100\n" +"POT-Creation-Date: 2022-01-28 20:08+0100\n" "PO-Revision-Date: 2022-01-28 13:52+0000\n" "Last-Translator: Simon Schneegans \n" "Language-Team: German Date: Fri, 28 Jan 2022 19:09:51 +0000 Subject: [PATCH 11/28] :globe_with_meridians: Translated using Weblate (German) --- po/de.po | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/po/de.po b/po/de.po index dbbaa35..5f0b32d 100644 --- a/po/de.po +++ b/po/de.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: Burn-My-Windows\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2022-01-28 20:08+0100\n" -"PO-Revision-Date: 2022-01-28 13:52+0000\n" +"PO-Revision-Date: 2022-01-28 19:10+0000\n" "Last-Translator: Simon Schneegans \n" "Language-Team: German \n" @@ -23,11 +23,11 @@ msgstr "" #: prefs.js:336 #, javascript-format msgid "Preview for %s" -msgstr "" +msgstr "Vorschau für %s" #: prefs.js:356 msgid "Close this Window to Preview the Effect!" -msgstr "" +msgstr "Schließen Sie dieses Fenster, um eine Vorschau des Effekts anzuzeigen!" #: resources/ui/common/main-menu.ui:6 msgid "Visit Homepage" From e92ab9fe187c9d342155ec8cfe82ac023cf87164 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 20:26:28 +0100 Subject: [PATCH 12/28] :lipstick: Improve appearance of preview window --- prefs.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/prefs.js b/prefs.js index 26e2a23..9d383c0 100644 --- a/prefs.js +++ b/prefs.js @@ -351,9 +351,13 @@ var PreferencesDialog = class PreferencesDialog { orientation: Gtk.Orientation.VERTICAL, valign: Gtk.Align.CENTER, spacing: 10, + margin_start:50, + margin_end:50 }); const label = Gtk.Label.new(_('Close this Window to Preview the Effect!')); + label.wrap = true; + label.justify = Gtk.Justification.CENTER; label.get_style_context().add_class('large-title'); const image = new Gtk.Image({ From 65969ce7a6ed2c8d33cb444648b36641296ba444 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Fri, 28 Jan 2022 20:29:38 +0100 Subject: [PATCH 13/28] :wrench: Add translation domains --- resources/ui/common/main-menu.ui | 2 +- resources/ui/gtk3/EnergizeA.ui | 2 +- resources/ui/gtk3/EnergizeB.ui | 2 +- resources/ui/gtk3/Fire.ui | 2 +- resources/ui/gtk3/TVEffect.ui | 2 +- resources/ui/gtk3/Wisps.ui | 2 +- resources/ui/gtk3/effectPage.ui | 2 +- resources/ui/gtk4/BrokenGlass.ui | 2 +- resources/ui/gtk4/EnergizeA.ui | 2 +- resources/ui/gtk4/EnergizeB.ui | 2 +- resources/ui/gtk4/Fire.ui | 2 +- resources/ui/gtk4/Matrix.ui | 2 +- resources/ui/gtk4/TRexAttack.ui | 2 +- resources/ui/gtk4/TVEffect.ui | 2 +- resources/ui/gtk4/Wisps.ui | 2 +- resources/ui/gtk4/effectPage.ui | 2 +- 16 files changed, 16 insertions(+), 16 deletions(-) diff --git a/resources/ui/common/main-menu.ui b/resources/ui/common/main-menu.ui index 0d8a0b8..94a86b8 100644 --- a/resources/ui/common/main-menu.ui +++ b/resources/ui/common/main-menu.ui @@ -1,5 +1,5 @@ - +
diff --git a/resources/ui/gtk3/EnergizeA.ui b/resources/ui/gtk3/EnergizeA.ui index 79afebc..d4e6bc0 100644 --- a/resources/ui/gtk3/EnergizeA.ui +++ b/resources/ui/gtk3/EnergizeA.ui @@ -1,5 +1,5 @@ - + 10000 diff --git a/resources/ui/gtk3/EnergizeB.ui b/resources/ui/gtk3/EnergizeB.ui index 051821d..c691889 100644 --- a/resources/ui/gtk3/EnergizeB.ui +++ b/resources/ui/gtk3/EnergizeB.ui @@ -1,5 +1,5 @@ - + 10000 diff --git a/resources/ui/gtk3/Fire.ui b/resources/ui/gtk3/Fire.ui index 4b43025..3417f83 100644 --- a/resources/ui/gtk3/Fire.ui +++ b/resources/ui/gtk3/Fire.ui @@ -1,5 +1,5 @@ - + 10000 diff --git a/resources/ui/gtk3/TVEffect.ui b/resources/ui/gtk3/TVEffect.ui index adebe01..e5206da 100644 --- a/resources/ui/gtk3/TVEffect.ui +++ b/resources/ui/gtk3/TVEffect.ui @@ -1,5 +1,5 @@ - + 5000 diff --git a/resources/ui/gtk3/Wisps.ui b/resources/ui/gtk3/Wisps.ui index ff096ae..2cec6ef 100644 --- a/resources/ui/gtk3/Wisps.ui +++ b/resources/ui/gtk3/Wisps.ui @@ -1,5 +1,5 @@ - + 10000 diff --git a/resources/ui/gtk3/effectPage.ui b/resources/ui/gtk3/effectPage.ui index 2ec5311..52419a5 100644 --- a/resources/ui/gtk3/effectPage.ui +++ b/resources/ui/gtk3/effectPage.ui @@ -1,5 +1,5 @@ - +