From 79733f62d5d3b91ad5d43bfdbb6b3702a1c106b1 Mon Sep 17 00:00:00 2001 From: Sakamoto Shiina <68018796+ShiinaSakamoto@users.noreply.github.com> Date: Mon, 22 Jan 2024 22:52:12 +0900 Subject: [PATCH] [Update] Config Window: Add description to DeepL Auth Key Section. --- locales/en.yml | 1 + locales/ja.yml | 1 + view.py | 9 +++++++-- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/locales/en.yml b/locales/en.yml index bfa7c48f..c3a0b7a1 100644 --- a/locales/en.yml +++ b/locales/en.yml @@ -131,6 +131,7 @@ config_window: deepl_auth_key: label: DeepL Auth Key + desc: Please select %{translator} on the main screen with DeepL_API when using. ※Some languages may not be supported. mic_host: label: Mic Host/Driver diff --git a/locales/ja.yml b/locales/ja.yml index 54cde38d..1b7e05ad 100644 --- a/locales/ja.yml +++ b/locales/ja.yml @@ -128,6 +128,7 @@ config_window: deepl_auth_key: label: DeepL 認証キー + desc: "使用の際は、メイン画面にある %{translator} をDeepL_APIに変更してください。\n※対応していない言語もあります。" mic_host: label: マイク(ホスト/ドライバー) diff --git a/view.py b/view.py index 97157c8d..cb3a334a 100644 --- a/view.py +++ b/view.py @@ -282,8 +282,13 @@ class View(): CALLBACK_SET_CTRANSLATE2_WEIGHT_TYPE=None, VAR_CTRANSLATE2_WEIGHT_TYPE=StringVar(value=self.getSelectableCtranslate2WeightTypeDict()[config.WEIGHT_TYPE]), - VAR_LABEL_DEEPL_AUTH_KEY=StringVar(value=i18n.t("config_window.deepl_auth_key.label")), - VAR_DESC_DEEPL_AUTH_KEY=None, + VAR_LABEL_DEEPL_AUTH_KEY=StringVar(value=i18n.t( "config_window.deepl_auth_key.label")), + VAR_DESC_DEEPL_AUTH_KEY=StringVar( + value=i18n.t( + "config_window.deepl_auth_key.desc", + translator=i18n.t("main_window.translator") + ) + ), CALLBACK_SET_DEEPL_AUTH_KEY=None, VAR_DEEPL_AUTH_KEY=StringVar(value=config.AUTH_KEYS["DeepL_API"]),