diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2024-07-17 16:13:58 +0200 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2024-07-17 16:13:58 +0200 |
| commit | cc79957d304deb923d31f865809b194172511b73 (patch) | |
| tree | 217b476f159bbb4530615aff5e8a4f8953dc0878 | |
| parent | 79c06fc454b91bc14b4a85dd6ec0c870c8ab6da8 (diff) | |
| download | turns-cc79957d304deb923d31f865809b194172511b73.tar.xz turns-cc79957d304deb923d31f865809b194172511b73.zip | |
lang: add missing translations
| -rw-r--r-- | lang/include/turns/lang/messages.hpp | 3 | ||||
| -rw-r--r-- | lang/po/de.po | 9 | ||||
| -rw-r--r-- | lang/po/en.po | 9 | ||||
| -rw-r--r-- | lang/tests/messages.cpp | 46 | ||||
| -rw-r--r-- | res/ui.cmb | 6 |
5 files changed, 50 insertions, 23 deletions
diff --git a/lang/include/turns/lang/messages.hpp b/lang/include/turns/lang/messages.hpp index 4a52945..9c07917 100644 --- a/lang/include/turns/lang/messages.hpp +++ b/lang/include/turns/lang/messages.hpp @@ -8,11 +8,14 @@ namespace turns::lang auto constexpr static disposition = "Disposition"; auto constexpr static delete_participant = "Delete participant"; auto constexpr static edit_participant = "Edit participant"; + auto constexpr static end_turn_order = "End turn order"; auto constexpr static finish = "Finish"; auto constexpr static main_menu = "Main Menu"; auto constexpr static mark_as_defeated = "Mark as defeated"; auto constexpr static name = "Name"; + auto constexpr static next_participant = "Next participant"; auto constexpr static no_active_turn_order = "No active turn order"; + auto constexpr static previous_participant = "Previous participant"; auto constexpr static priority = "Priority"; auto constexpr static priority_number = "Priority {}"; auto constexpr static quit = "_Quit"; diff --git a/lang/po/de.po b/lang/po/de.po index b98f2b2..5f57e3d 100644 --- a/lang/po/de.po +++ b/lang/po/de.po @@ -23,6 +23,9 @@ msgstr "Teilnehmer entfernen" msgid "Edit participant" msgstr "Teilnehmer bearbeiten" +msgid "End turn order" +msgstr "Zugreihenfolge beenden" + msgid "Finish" msgstr "Abschließen" @@ -35,9 +38,15 @@ msgstr "Als besiegt markieren" msgid "Name" msgstr "Name" +msgid "Next participant" +msgstr "Nächster Teilnehmer" + msgid "No active turn order" msgstr "Keine aktive Zugreihenfolge" +msgid "Previous participant" +msgstr "Vorhergehender Teilnehmer" + msgid "Priority" msgstr "Priorität" diff --git a/lang/po/en.po b/lang/po/en.po index 0ad410b..2f7ff85 100644 --- a/lang/po/en.po +++ b/lang/po/en.po @@ -23,6 +23,9 @@ msgstr "Delete participant" msgid "Edit participant" msgstr "Edit participant" +msgid "End turn order" +msgstr "End turn order" + msgid "Finish" msgstr "Finish" @@ -35,9 +38,15 @@ msgstr "Mark as defeated" msgid "Name" msgstr "Name" +msgid "Next participant" +msgstr "Next participant" + msgid "No active turn order" msgstr "No active turn order" +msgid "Previous participant" +msgstr "Previous participant" + msgid "Priority" msgstr "Priority" diff --git a/lang/tests/messages.cpp b/lang/tests/messages.cpp index df991d6..53442b6 100644 --- a/lang/tests/messages.cpp +++ b/lang/tests/messages.cpp @@ -13,29 +13,35 @@ namespace turns::lang::tests TEST_CASE("Translated messages") { - auto message = GENERATE(add_participant, - clear, - disposition, - delete_participant, - edit_participant, - finish, - main_menu, - mark_as_defeated, - // a better solution is required to test the following entry: - // name, - no_active_turn_order, - priority, - priority_number, - quit, - start_turn_order, - turns); - auto locale = GENERATE("de_CH.UTF-8", "de_DE.UTF-8", "de_AT.UTF-8"); + setlocale(LC_ALL, locale); - SECTION(std::format("'{}' has a translation in '{}'", message, locale)) + SECTION(std::format("Locale '{}'", locale)) { - setlocale(LC_ALL, locale); - REQUIRE(std::string{gettext(message)} != message); + auto message = GENERATE(add_participant, + clear, + disposition, + delete_participant, + edit_participant, + end_turn_order, + finish, + main_menu, + mark_as_defeated, + // a better solution is required to test the following entry: + // name, + next_participant, + no_active_turn_order, + previous_participant, + priority, + priority_number, + quit, + start_turn_order, + turns); + + SECTION(std::format("has a translation for '{}'", message)) + { + REQUIRE(std::string{gettext(message)} != message); + } } } @@ -91,13 +91,13 @@ (1,20,"GtkRevealer","transition-type","slide-up",None,None,None,None,None,None,None,None,None), (1,22,"GtkActionable","action-name","win.previous",None,None,None,None,None,None,None,None,None), (1,22,"GtkButton","icon-name","media-skip-backward-symbolic",None,None,None,None,None,None,None,None,None), - (1,22,"GtkWidget","tooltip-markup","Previous participant",None,None,None,None,None,None,None,None,None), + (1,22,"GtkWidget","tooltip-markup","Previous participant",1,None,None,None,None,None,None,None,None), (1,23,"GtkActionable","action-name","win.stop",None,None,None,None,None,None,None,None,None), (1,23,"GtkButton","icon-name","media-playback-stop-symbolic",None,None,None,None,None,None,None,None,None), - (1,23,"GtkWidget","tooltip-markup","End turn order",None,None,None,None,None,None,None,None,None), + (1,23,"GtkWidget","tooltip-markup","End turn order",1,None,None,None,None,None,None,None,None), (1,24,"GtkActionable","action-name","win.next",None,None,None,None,None,None,None,None,None), (1,24,"GtkButton","icon-name","media-skip-forward-symbolic",None,None,None,None,None,None,None,None,None), - (1,24,"GtkWidget","tooltip-markup","Next participant",None,None,None,None,None,None,None,None,None), + (1,24,"GtkWidget","tooltip-markup","Next participant",1,None,None,None,None,None,None,None,None), (2,1,"AdwDialog","child",None,None,None,None,None,2,None,None,None,None), (2,1,"AdwDialog","default-widget",None,None,None,None,None,None,None,None,None,None), (2,1,"GtkWidget","hexpand","True",None,None,None,None,None,None,None,None,None), |
