-
Notifications
You must be signed in to change notification settings - Fork 156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed translation hook in EDSM.py and Inara.py #2086
Conversation
Corrected the text of code line 295; The text text="Show API Key" cannot be translated as indicated, so I rewrote it as text=_('Show API Key').
Corrected the text of code line 355; The text text="Show API Key" cannot be translated as indicated, so I rewrote it as text=_('Show API Key').
These lines will need |
They are already commented above, instead of to the right of the text.
Should I do this in the English language file? |
OK, I'm obviously blind today. Yes, on the same line is preferred, so long as it fits without making the line over 120 characters long. Don't bother with |
Forgive me, when I wrote to put them above the comments I was actually thinking of a previous version. They are actually placed to the side as done on other points. So I don't understand what you are specifically referring to. diff --git a/plugins/edsm.py b/plugins/edsm.py
index 2f644dcb9..82324ced4 100644
--- a/plugins/edsm.py
+++ b/plugins/edsm.py
@@ -352,7 +352,7 @@ def plugin_prefs(parent: ttk.Notebook, cmdr: Optional[str], is_beta: bool) -> tk
show_password_checkbox = nb.Checkbutton(
frame,
- text="Show API Key",
+ text=_('Show API Key'), # LANG: Text EDSM Show API Key
variable=show_password_var,
command=toggle_password_visibility
)
diff --git a/plugins/inara.py b/plugins/inara.py
index efe010df6..ec034840b 100644
--- a/plugins/inara.py
+++ b/plugins/inara.py
@@ -292,7 +292,7 @@ def plugin_prefs(parent: ttk.Notebook, cmdr: str, is_beta: bool) -> tk.Frame:
show_password_var.set(False) # Password is initially masked
show_password_checkbox = nb.Checkbutton(
frame,
- text="Show API Key",
+ text=_('Show API Key'), # LANG: Text Inara Show API key
variable=show_password_var,
command=toggle_password_visibility,
) |
Thanks for catching these! |
Corrected the text of code line 295 of the EDSM.py file and code line 355 of the Inara.py file;
The text text="Show API Key" cannot be translated as indicated, so I rewrote it as text=_('Show API Key').