From 9c358d708ba4988648d7b19ccb842f076ec4c354 Mon Sep 17 00:00:00 2001 From: Adrien Hopkins Date: Sun, 23 Feb 2025 20:23:47 -0500 Subject: Allow internationalization of about.txt This works with custom locales (by placing the text in [config_dir]/about/[name].txt), but if such a file does not exist, it will default to the default locale (en)'s about text. --- src/main/resources/about/en.txt | 25 +++++++++++++++++++++++++ src/main/resources/about/fr.txt | 24 ++++++++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 src/main/resources/about/en.txt create mode 100644 src/main/resources/about/fr.txt (limited to 'src/main/resources/about') diff --git a/src/main/resources/about/en.txt b/src/main/resources/about/en.txt new file mode 100644 index 0000000..068f922 --- /dev/null +++ b/src/main/resources/about/en.txt @@ -0,0 +1,25 @@ +About 7Units Version [VERSION] + +7Units is a unit converter program with many features, +inspired by GNU Units (https://www.gnu.org/software/units/). +You can use it to simply convert units, but you can also +use it like a calculator, computing and converting expressions +like "10 m/s + (25^2 - 5^2) mi/hr". + +This software was written by Adrien Hopkins +. + +Unit/Prefix/Dimension Statistics: + +[LOADSTATS] + +Copyright Notice: + +Unit Converter Copyright (C) 2018-2025 Adrien Hopkins +This program comes with ABSOLUTELY NO WARRANTY; +for details read the LICENSE file, section 15 + +This is free software, and you are welcome to redistribute +it under certain conditions; for details go to + +or read the LICENSE file. diff --git a/src/main/resources/about/fr.txt b/src/main/resources/about/fr.txt new file mode 100644 index 0000000..d8d82aa --- /dev/null +++ b/src/main/resources/about/fr.txt @@ -0,0 +1,24 @@ +À propos de 7Unités version [VERSION] + +7Unités est une programme pour convertir les unités avec plusieurs fonctions, +inspiré par GNU Units (https://www.gnu.org/software/units/). +Vous pouvez l’utiliser pour convertir des unités, mais vous pouvez aussi +l’utiliser comme calculatrice, computer et convertir des expressions +comme "10 m/s + (25^2 - 5^2) mi/hr". + +Ce logiciel est par Adrien Hopkins . + +Statistiques d’unités, préfixes et dimensions: + +[LOADSTATS] + +Copyright Notice: + +Unit Converter Copyright (C) 2018-2025 Adrien Hopkins +This program comes with ABSOLUTELY NO WARRANTY; +for details read the LICENSE file, section 15 + +This is free software, and you are welcome to redistribute +it under certain conditions; for details go to + +or read the LICENSE file. -- cgit v1.2.3 From ef34d9b0a1346ec6a6243dc4df7c59612faf6768 Mon Sep 17 00:00:00 2001 From: Adrien Hopkins Date: Tue, 10 Jun 2025 12:37:50 -0500 Subject: Correct sample expressions in about text The expressions were valid, but used 'hr' instead of 'h' for the hour, which is not the abbreviation used by 7Units. --- src/main/resources/about/en.txt | 2 +- src/main/resources/about/fr.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/main/resources/about') diff --git a/src/main/resources/about/en.txt b/src/main/resources/about/en.txt index 068f922..37986e5 100644 --- a/src/main/resources/about/en.txt +++ b/src/main/resources/about/en.txt @@ -4,7 +4,7 @@ About 7Units Version [VERSION] inspired by GNU Units (https://www.gnu.org/software/units/). You can use it to simply convert units, but you can also use it like a calculator, computing and converting expressions -like "10 m/s + (25^2 - 5^2) mi/hr". +like "10 m/s + (25^2 - 5^2) mi/h". This software was written by Adrien Hopkins . diff --git a/src/main/resources/about/fr.txt b/src/main/resources/about/fr.txt index d8d82aa..fc7ed83 100644 --- a/src/main/resources/about/fr.txt +++ b/src/main/resources/about/fr.txt @@ -4,7 +4,7 @@ inspiré par GNU Units (https://www.gnu.org/software/units/). Vous pouvez l’utiliser pour convertir des unités, mais vous pouvez aussi l’utiliser comme calculatrice, computer et convertir des expressions -comme "10 m/s + (25^2 - 5^2) mi/hr". +comme "10 m/s + (25^2 - 5^2) mi/h". Ce logiciel est par Adrien Hopkins . -- cgit v1.2.3