summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuben Pollan <meskio@sindominio.net>2020-07-10 11:04:49 +0200
committerRuben Pollan <meskio@sindominio.net>2020-07-28 13:44:58 +0200
commitcf5ed56c943599c092a91933b45471c4c0e5d579 (patch)
treec2a4f1ce4cffff3dce4c207575d15aa2a43c365f
parentcdb42f0d6b47a60ceb647e3ac6a6ce66352dbae4 (diff)
Add support for internationalization
- Resolves: #243
-rw-r--r--.gitignore1
-rw-r--r--Makefile21
-rw-r--r--bitmask.pro5
-rwxr-xr-xbuild.sh1
-rw-r--r--gui/i18n/base.ts172
-rw-r--r--gui/i18n/main_ar.ts172
-rw-r--r--gui/i18n/main_es.ts172
-rw-r--r--gui/i18n/main_es_ES.ts172
-rw-r--r--gui/i18n/main_nl.ts172
-rw-r--r--gui/i18n/main_pl.ts172
-rw-r--r--gui/i18n/main_pt_BR.ts172
-rw-r--r--gui/main.cpp5
-rw-r--r--gui/qml/AboutDialog.qml9
-rw-r--r--gui/qml/DonateDialog.qml2
-rw-r--r--gui/qml/LoginConfirmation.qml4
-rw-r--r--gui/qml/LoginDialog.qml8
-rw-r--r--gui/qml/main.qml16
-rw-r--r--tools/transifex/Makefile8
-rw-r--r--tools/transifex/main.go124
-rw-r--r--tools/transifex/messages.json28
20 files changed, 1247 insertions, 189 deletions
diff --git a/.gitignore b/.gitignore
index 5cb4e9e..7c8e96b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,6 +9,7 @@ cmd/bitmask-vpn/bitmask-vpn
cmd/bitmask-helper/bitmask-helper
/bitmask-connect
cmd/bitmask-connect/bitmask-connect
+gui/i18n/*.qm
locales/*/out.gotext.json
tools/transifex/transifex
diff --git a/Makefile b/Makefile
index 7d284b4..4722146 100644
--- a/Makefile
+++ b/Makefile
@@ -241,23 +241,12 @@ icon:
@make -C icon
-LANGS ?= $(foreach path,$(wildcard locales/*),$(patsubst locales/%,%,$(path)))
-empty :=
-space := $(empty) $(empty)
-lang_list := $(subst $(space),,$(foreach lang,$(LANGS),$(lang),))
+LANGS ?= $(foreach path,$(wildcard gui/i18n/main_*.ts),$(patsubst gui/i18n/main_%.ts,%,$(path)))
-locales: $(foreach lang,$(LANGS),get_$(lang)) cmd/bitmask-vpn/catalog.go
+locales: $(foreach lang,$(LANGS),get_$(lang))
generate_locales:
- @gotext update -lang=$(lang_list) ./pkg/systray ./pkg/bitmask
- @make -C tools/transifex
+ @lupdate bitmask.pro
-locales/%/out.gotext.json: pkg/systray/systray.go pkg/systray/notificator.go pkg/bitmask/standalone.go
- @gotext update -lang=$* ./pkg/systray ./pkg/bitmask
-
-cmd/bitmask-vpn/catalog.go: $(foreach lang,$(LANGS),locales/$(lang)/messages.gotext.json)
- @gotext update -lang=$(lang_list) -out cmd/bitmask-vpn/catalog.go ./pkg/systray ./pkg/bitmask
-
-get_%: locales/%/out.gotext.json
- @make -C tools/transifex build
- @curl -L -X GET --user "api:${API_TOKEN}" "https://www.transifex.com/api/2/project/bitmask/resource/RiseupVPN/translation/${subst -,_,$*}/?file" | tools/transifex/transifex t2g locales/$*/
+get_%:
+ @curl -L -X GET --user "api:${API_TOKEN}" "https://www.transifex.com/api/2/project/bitmask/resource/riseupvpn-test/translation/${subst -,_,$*}/?file" > gui/i18n/main_$*.ts
diff --git a/bitmask.pro b/bitmask.pro
index 7a29483..fcedd75 100644
--- a/bitmask.pro
+++ b/bitmask.pro
@@ -47,3 +47,8 @@ Debug:UI_DIR = debug/.ui
DISTFILES += \
README.md
+
+CONFIG += lrelease embed_translations
+
+TRANSLATIONS += $$files(gui/i18n/*.ts, true)
+RESOURCES += $$files(gui/i18n/*.qm, true)
diff --git a/build.sh b/build.sh
index c7085a6..94f77b3 100755
--- a/build.sh
+++ b/build.sh
@@ -51,6 +51,7 @@ function buildQmake {
echo "[+] Building BitmaskVPN"
+lrelease bitmask.pro
buildGoLib
buildQmake
make -C qtbuild clean
diff --git a/gui/i18n/base.ts b/gui/i18n/base.ts
new file mode 100644
index 0000000..9110c36
--- /dev/null
+++ b/gui/i18n/base.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_ar.ts b/gui/i18n/main_ar.ts
new file mode 100644
index 0000000..5a8869a
--- /dev/null
+++ b/gui/i18n/main_ar.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="ar">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>حول</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>تبرَّع</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>تسجيل الدخول </translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>جارى التحقق من الوضع...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>إعادة الاتصال</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>تشغيل</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>إلغاء </translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>إغلاق</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>المساعدة...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>تبرع...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>عن الخدمة...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>خروج</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>حدث خطأ فى تشغيل VPN</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>أداة الدخول للحساب مفقودة</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>لم يجد البرنامج أداة الدخول (polkit). من فضلك شغل واحدة وحاول ثانية.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_es.ts b/gui/i18n/main_es.ts
new file mode 100644
index 0000000..48e98ef
--- /dev/null
+++ b/gui/i18n/main_es.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="es">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>Acerca de</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>Dona</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>Acceder</translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>Comprobando el estado...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>Volver a conectar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>Encender</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>Cancelar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>Apagar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>Ayuda...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>Dona...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>Acerca de...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>Cerrar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>Error al iniciar la VPN</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>Falta un agente de autenticación</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>No se pudo encontrar ningún agente de autenticacion de polkit. Por favor lanza uno y prueba de nuevo.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_es_ES.ts b/gui/i18n/main_es_ES.ts
new file mode 100644
index 0000000..48ca2c2
--- /dev/null
+++ b/gui/i18n/main_es_ES.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="es_ES">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>Acerca de</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>Donar</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>Iniciar Sesión</translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>Comprobando estado...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>Reconectar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>Activar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>Cancelar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>Desactivar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>Ayuda...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>Donar...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>Acerca de...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>Salir</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>Error iniciando VPN</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>Falta agente de autenticación</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>No se pudo encontrar un agente de autenticación polkit. Por favor corre uno e intenta de nuevo.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_nl.ts b/gui/i18n/main_nl.ts
new file mode 100644
index 0000000..4709f71
--- /dev/null
+++ b/gui/i18n/main_nl.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="nl">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>Over</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>Doneren</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>Inloggen</translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>Status controleren...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>Opnieuw verbinden</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>Inschakelen</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>Annuleren</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>Uitschakelen</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>Hulp...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>Doneren...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>Over...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>Stoppen</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>Fout bij het opstarten van de VPN</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>Authenticatieagent ontbreekt</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>Kan geen polkit authenticatieagent vinden. Voer er een uit en probeer opnieuw.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_pl.ts b/gui/i18n/main_pl.ts
new file mode 100644
index 0000000..768b383
--- /dev/null
+++ b/gui/i18n/main_pl.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="pl">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>O programie...</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>Darowizna</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>Login</translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>Sprawdzanie statusu</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>Połącz ponownie</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>Włącz</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>Anuluj</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>Wyłącz</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>Pomoc...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>Wesprzyj...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>O programie...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>Zamknij</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>Błąd przy uruchamianiu VPN&apos;a</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>Brakujący agent autoryzacji</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>Nie znaleziono agenta autentykacji polkit. Proszę uruchom go i spróbuj ponownie.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/i18n/main_pt_BR.ts b/gui/i18n/main_pt_BR.ts
new file mode 100644
index 0000000..ad04d47
--- /dev/null
+++ b/gui/i18n/main_pt_BR.ts
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="pt_BR">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="5"/>
+ <source>About</source>
+ <translation>Sobre</translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="19"/>
+ <source>&lt;p&gt;%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.&lt;/p&gt; &lt;p&gt;This service is paid for entirely by donations from users like you. &lt;a href=&quot;%3&quot;&gt;Please donate&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;By using this application, you agree to the &lt;a href=&quot;%4&quot;&gt;Terms of Service&lt;/a&gt;. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.&lt;/p&gt;</source>
+ <extracomment>about dialog %1 -&gt; application name %2 -&gt; provider name %3 -&gt; donation URL %4 -&gt; TOS URL</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/AboutDialog.qml" line="29"/>
+ <source>%1 version: %2</source>
+ <extracomment>%1 -&gt; application name %2 -&gt; version string</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>DonateDialog</name>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="6"/>
+ <source>Donate</source>
+ <translation>Fazer uma doação</translation>
+ </message>
+ <message>
+ <location filename="../qml/DonateDialog.qml" line="14"/>
+ <source>The %1 service is expensive to run. Because we don&apos;t want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.
+
+Do you want to donate now?</source>
+ <extracomment>donate dialog %1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>LoginDialog</name>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="7"/>
+ <source>Login</source>
+ <translation>Conectar</translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="11"/>
+ <source>Log in with your library credentials</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="15"/>
+ <source>patron id</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/LoginDialog.qml" line="19"/>
+ <source>password</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>main</name>
+ <message>
+ <location filename="../qml/main.qml" line="25"/>
+ <source>Could not find helpers. Check your installation</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="27"/>
+ <source>Could not find polkit agent.</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="56"/>
+ <source>%1 off</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="59"/>
+ <source>%1 on</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="62"/>
+ <source>Connecting to %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="65"/>
+ <source>Stopping %1</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="68"/>
+ <source>%1 blocking internet</source>
+ <extracomment>%1 -&gt; application name</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="105"/>
+ <location filename="../qml/main.qml" line="151"/>
+ <source>Checking status...</source>
+ <translation>Verificando estado...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="158"/>
+ <source>Reconnect</source>
+ <translation>Reconectar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="160"/>
+ <source>Turn on</source>
+ <translation>Ligar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="171"/>
+ <source>Cancel</source>
+ <translation>Cancelar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="173"/>
+ <source>Turn off</source>
+ <translation>Desligar</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="184"/>
+ <source>Help...</source>
+ <translation>Ajuda...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="189"/>
+ <source>Donate...</source>
+ <translation>Fazer uma doação...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="195"/>
+ <source>About...</source>
+ <translation>Sobre...</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="202"/>
+ <source>Quit</source>
+ <translation>Sair</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="227"/>
+ <source>Error starting VPN</source>
+ <translation>Erro ao iniciar a VPN</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="237"/>
+ <source>Missing authentication agent</source>
+ <translation>Um agente de autenticação está faltando</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="238"/>
+ <source>Could not find a polkit authentication agent. Please run one and try again.</source>
+ <translation>Não foi possível encontrar um agente de autenticação polkit. Por favor, execute um agente e tente novamente.</translation>
+ </message>
+ <message>
+ <location filename="../qml/main.qml" line="246"/>
+ <source>Initialization Error</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/gui/main.cpp b/gui/main.cpp
index 670e664..73d55cc 100644
--- a/gui/main.cpp
+++ b/gui/main.cpp
@@ -4,6 +4,7 @@
#include <QApplication>
#include <QSystemTrayIcon>
#include <QTimer>
+#include <QTranslator>
#include <QtQml>
#include <QQmlApplicationEngine>
#include <QQuickWindow>
@@ -56,6 +57,10 @@ int main(int argc, char **argv) {
if (!QSystemTrayIcon::isSystemTrayAvailable()) {
qDebug() << "No systray icon available. Things might not work for now, sorry...";
}
+
+ QTranslator translator;
+ translator.load(QLocale(), QLatin1String("main"), QLatin1String("_"), QLatin1String(":/i18n"));
+ app.installTranslator(&translator);
app.setQuitOnLastWindowClosed(false);
QQmlApplicationEngine engine;
diff --git a/gui/qml/AboutDialog.qml b/gui/qml/AboutDialog.qml
index 98cacdc..68e76d3 100644
--- a/gui/qml/AboutDialog.qml
+++ b/gui/qml/AboutDialog.qml
@@ -11,6 +11,11 @@ MessageDialog {
var _provider = ctx ? ctx.provider : "unknown"
var _donateURL= ctx ? ctx.donateURL : "..."
var _tosURL = ctx ? ctx.tosURL : "..."
+ //: about dialog
+ //: %1 -> application name
+ //: %2 -> provider name
+ //: %3 -> donation URL
+ //: %4 -> TOS URL
var _txt = qsTr(
"<p>%1 is an easy, fast, and secure VPN service from %2. %1 does not require a user account, keep logs, or track you in any way.</p> <p>This service is paid for entirely by donations from users like you. <a href=\"%3\">Please donate</a>.</p> <p>By using this application, you agree to the <a href=\"%4\">Terms of Service</a>. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.</p>").arg(_name).arg(_provider).arg(_donateURL).arg(_tosURL)
return _txt
@@ -19,7 +24,9 @@ MessageDialog {
function getVersion() {
var _name = ctx ? ctx.appName : "vpn"
var _ver = ctx ? ctx.version : "unknown"
- var _txt = "%1 version: %2".arg(_name).arg(_ver)
+ //: %1 -> application name
+ //: %2 -> version string
+ var _txt = qsTr("%1 version: %2").arg(_name).arg(_ver)
return _txt
}
}
diff --git a/gui/qml/DonateDialog.qml b/gui/qml/DonateDialog.qml
index de7ab5b..afbd57b 100644
--- a/gui/qml/DonateDialog.qml
+++ b/gui/qml/DonateDialog.qml
@@ -9,6 +9,8 @@ MessageDialog {
function getText() {
var _name = ctx ? ctx.appName : "vpn"
+ //: donate dialog
+ //: %1 -> application name
var _txt = qsTr(
"The %1 service is expensive to run. Because we don't want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.\n\nDo you want to donate now?").arg(_name)
return _txt
diff --git a/gui/qml/LoginConfirmation.qml b/gui/qml/LoginConfirmation.qml
index 476cdad..618b870 100644
--- a/gui/qml/LoginConfirmation.qml
+++ b/gui/qml/LoginConfirmation.qml
@@ -4,8 +4,8 @@ import QtQuick.Controls 1.4
Dialog {
standardButtons: StandardButton.Ok
- title: "Login Success"
- text: "You are now logged in, connecting now"
+ title: qsTr("Login Success")
+ text: qsTr("You are now logged in, connecting now")
visible: ctxSystray.loginConfirmationDialog == true
}
diff --git a/gui/qml/LoginDialog.qml b/gui/qml/LoginDialog.qml
index fbe5ce1..0c0f18e 100644
--- a/gui/qml/LoginDialog.qml
+++ b/gui/qml/LoginDialog.qml
@@ -4,19 +4,19 @@ import QtQuick.Controls 1.4
Dialog {
standardButtons: StandardButton.Ok
- title: "Login"
+ title: qsTr("Login")
Column {
anchors.fill: parent
Text {
- text: "Log in with your library credentials"
+ text: qsTr("Log in with your library credentials")
}
TextField {
id: username
- placeholderText: "patron id"
+ placeholderText: qsTr("patron id")
}
TextField {
id: password
- placeholderText: "password"
+ placeholderText: qsTr("password")
echoMode: TextInput.PasswordEchoOnEdit
}
}
diff --git a/gui/qml/main.qml b/gui/qml/main.qml
index 4aab7f1..2ac9398 100644
--- a/gui/qml/main.qml
+++ b/gui/qml/main.qml
@@ -52,16 +52,20 @@ ApplicationWindow {
function toHuman(st) {
switch(st) {
case "off":
- // TODO improve string interpolation, give context to translators etc
- return qsTr(ctx.appName + " off");
+ //: %1 -> application name
+ return qsTr("%1 off").arg(ctx.appName);
case "on":
- return qsTr(ctx.appName + " on");
+ //: %1 -> application name
+ return qsTr("%1 on").arg(ctx.appName);
case "connecting":
- return qsTr("Connecting to " + ctx.appName);
+ //: %1 -> application name
+ return qsTr("Connecting to %1").arg(ctx.appName);
case "stopping":
- return qsTr("Stopping " + ctx.appName);
+ //: %1 -> application name
+ return qsTr("Stopping %1").arg(ctx.appName);
case "failed":
- return qsTr(ctx.appName + " blocking internet"); // TODO failed is not handed yet
+ //: %1 -> application name
+ return qsTr("%1 blocking internet").arg(ctx.appName); // TODO failed is not handed yet
}
}
diff --git a/tools/transifex/Makefile b/tools/transifex/Makefile
deleted file mode 100644
index bf5bf2b..0000000
--- a/tools/transifex/Makefile
+++ /dev/null
@@ -1,8 +0,0 @@
-
-all: build generate_json
-
-build:
- go build
-
-generate_json:
- ./transifex g2t ../../locales/en-US/out.gotext.json messages.json
diff --git a/tools/transifex/main.go b/tools/transifex/main.go
deleted file mode 100644
index 37bae97..0000000
--- a/tools/transifex/main.go
+++ /dev/null
@@ -1,124 +0,0 @@
-package main
-
-import (
- "encoding/json"
- "fmt"
- "os"
- "path"
-
- "golang.org/x/text/message/pipeline"
-)
-
-const (
- outGotext = "out.gotext.json"
- messagesGotext = "messages.gotext.json"
-)
-
-type transifex map[string]string
-
-func main() {
- if len(os.Args) < 2 {
- panic("g2t or t2g should be passed as argument")
- }
-
- switch os.Args[1] {
- case "g2t":
- g2t(func(m pipeline.Message) string { return m.Message.Msg })
- case "lang2t":
- g2t(func(m pipeline.Message) string { return m.Translation.Msg })
- case "t2g":
- t2g()
- default:
- panic("g2t or t2g should be passed as argument")
- }
-}
-
-func g2t(getMessage func(pipeline.Message) string) {
- if len(os.Args) < 4 {
- panic(fmt.Sprintf("usage: %s g2t inFile outFile", os.Args[0]))
- }
-
- inF, err := os.Open(os.Args[2])
- if err != nil {
- panic(fmt.Sprintf("Can't open input file %s: %v", os.Args[2], err))
- }
- outF, err := os.Create(os.Args[3])
- if err != nil {
- panic(fmt.Sprintf("Can't open output file %s: %v", os.Args[3], err))
- }
-
- toTransifex(inF, outF, getMessage)
-}
-
-func t2g() {
- if len(os.Args) < 3 {
- panic(fmt.Sprintf("usage: %s t2g localeFolder", os.Args[0]))
- }
-
- origF, err := os.Open(path.Join(os.Args[2], outGotext))
- if err != nil {
- panic(fmt.Sprintf("Can't open file %s/%s: %v", os.Args[3], outGotext, err))
- }
- outF, err := os.Create(path.Join(os.Args[2], messagesGotext))
- if err != nil {
- panic(fmt.Sprintf("Can't open output file %s/%v: %v", os.Args[3], messagesGotext, err))
- }
- toGotext(origF, os.Stdin, outF)
-}
-
-func toTransifex(inF, outF *os.File, getMessage func(pipeline.Message) string) {
- messages := pipeline.Messages{}
- dec := json.NewDecoder(inF)
- err := dec.Decode(&messages)
- if err != nil {
- panic(fmt.Sprintf("An error ocurred decoding json: %v", err))
- }
-
- transfx := make(transifex)
- for _, m := range messages.Messages {
- transfx[m.ID[0]] = getMessage(m)
- }
- enc := json.NewEncoder(outF)
- enc.SetIndent("", " ")
- err = enc.Encode(transfx)
- if err != nil {
- panic(fmt.Sprintf("An error ocurred encoding json: %v", err))
- }
-}
-
-func toGotext(origF, inF, outF *os.File) {
- transfx := make(transifex)
- dec := json.NewDecoder(inF)
- err := dec.Decode(&transfx)
- if err != nil {
- panic(fmt.Sprintf("An error ocurred decoding json: %v", err))
- }
-
- messages := pipeline.Messages{}
- dec = json.NewDecoder(origF)
- err = dec.Decode(&messages)
- if err != nil {
- panic(fmt.Sprintf("An error ocurred decoding orig json: %v", err))
- }
-
- for k, v := range transfx {
- found := false
- for i, m := range messages.Messages {
- if m.ID[0] == k {
- messages.Messages[i].Translation.Msg = v
- found = true
- break
- }
- }
- if !found {
- fmt.Printf("The original document doesn't have id: %s\n", k)
- }
- }
-
- enc := json.NewEncoder(outF)
- enc.SetIndent("", " ")
- err = enc.Encode(messages)
- if err != nil {
- panic(fmt.Sprintf("An error ocurred encoding json: %v", err))
- }
-}
diff --git a/tools/transifex/messages.json b/tools/transifex/messages.json
deleted file mode 100644
index a8e0111..0000000
--- a/tools/transifex/messages.json
+++ /dev/null
@@ -1,28 +0,0 @@
-{
- "About": "About",
- "About...": "About...",
- "Cancel": "Cancel",
- "Checking status...": "Checking status...",
- "Connecting to {ApplicationName}": "Connecting to {ApplicationName}",
- "Donate": "Donate",
- "Donate...": "Donate...",
- "Error starting VPN": "Error starting VPN",
- "Help...": "Help...",
- "Initialization error": "Initialization error",
- "Missing authentication agent": "Missing authentication agent",
- "Quit": "Quit",
- "Reconnect": "Reconnect",
- "Route traffic through:": "Route traffic through:",
- "Stopping {ApplicationName}": "Stopping {ApplicationName}",
- "Turn off": "Turn off",
- "Turn on": "Turn on",
- "Use {ApplicationName} {City} gateway": "Use {ApplicationName} {City} gateway",
- "aboutText": "{ApplicationName} is an easy, fast, and secure VPN service from {Provider}. {ApplicationName} does not require a user account, keep logs, or track you in any way.\n\t \nThis service is paid for entirely by donations from users like you. Please donate at {DonateURL}.\n\t\t\nBy using this application, you agree to the Terms of Service available at {TosURL}. This service is provided as-is, without any warranty, and is intended for people who work to make the world a better place.\n\n\n{ApplicationName_1} version: {Version}",
- "donationText": "The {ApplicationName} service is expensive to run. Because we don't want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.\n\t\nDo you want to donate now?",
- "errorMsg": "An error has ocurred initializing the VPN: {Err}",
- "errorStartingVPN": "Can't connect to {ApplicationName}: {Err}",
- "missingAuthAgent": "Could not find a polkit authentication agent. Please run one and try again.",
- "{ApplicationName} blocking internet": "{ApplicationName} blocking internet",
- "{ApplicationName} off": "{ApplicationName} off",
- "{ApplicationName} on": "{ApplicationName} on"
-}