From 12fb8b02c881848dc49fedfd836aa72027160fe7 Mon Sep 17 00:00:00 2001 From: OverloadedOrama <35376950+OverloadedOrama@users.noreply.github.com> Date: Fri, 7 Feb 2020 02:40:53 +0200 Subject: [PATCH] The language buttons in the preferences have their localized names in their hint tooltips MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit For example, if you hover over the "English" button while the language is Greek, the hint tooltip will be "Αγγλικά", which is the Greek word for English. --- Changelog.md | 1 + Prefabs/Dialogs/PreferencesDialog.tscn | 55 ++++++++++++-------------- Scripts/Dialogs/PreferencesDialog.gd | 1 + 3 files changed, 28 insertions(+), 29 deletions(-) diff --git a/Changelog.md b/Changelog.md index dea1b8bf1..07690378e 100644 --- a/Changelog.md +++ b/Changelog.md @@ -20,6 +20,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Made the "X" button on the custom brushes a little smaller. - The color picker will now have a small white triangle on the top left of the color preview if at least one of its RGB values are above 1 in Raw mode. (Added automatically because of the Godot 3.2 update) - You can now toggle the visibility of hidden items on and off in the file dialogs. (Added automatically because of the Godot 3.2 update) +- The language buttons in the preferences have their localized names in their hint tooltips. For example, if you hover over the "English" button while the language is Greek, the hint tooltip will be "Αγγλικά", which is the Greek word for English. ### Fixed - Delay the splash screen popup so it shows properly centered (thanks to YeldhamDev) diff --git a/Prefabs/Dialogs/PreferencesDialog.tscn b/Prefabs/Dialogs/PreferencesDialog.tscn index d9714ae1d..909330024 100644 --- a/Prefabs/Dialogs/PreferencesDialog.tscn +++ b/Prefabs/Dialogs/PreferencesDialog.tscn @@ -37,12 +37,12 @@ size_flags_horizontal = 3 [node name="VBoxContainer" type="VBoxContainer" parent="HSplitContainer/ScrollContainer"] margin_right = 205.0 -margin_bottom = 554.0 +margin_bottom = 758.0 size_flags_horizontal = 3 [node name="Languages" type="VBoxContainer" parent="HSplitContainer/ScrollContainer/VBoxContainer"] margin_right = 205.0 -margin_bottom = 310.0 +margin_bottom = 338.0 [node name="Language Options" type="Label" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_right = 205.0 @@ -81,60 +81,59 @@ mouse_default_cursor_shape = 2 text = "English [en]" [node name="Spanish" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] -margin_top = 116.0 -margin_right = 205.0 -margin_bottom = 140.0 -mouse_default_cursor_shape = 2 -text = "Spanish [es]" - -[node name="French" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 144.0 margin_right = 205.0 margin_bottom = 168.0 mouse_default_cursor_shape = 2 -text = "Français [fr]" +text = "Español [es]" -[node name="Italian" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +[node name="French" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 172.0 margin_right = 205.0 margin_bottom = 196.0 mouse_default_cursor_shape = 2 -text = "Italian [it]" +text = "Français [fr]" -[node name="Polish" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +[node name="Italian" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 200.0 margin_right = 205.0 margin_bottom = 224.0 mouse_default_cursor_shape = 2 -text = "Polski [pl]" +text = "Italian [it]" -[node name="Brazilian Portuguese" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +[node name="Polish" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 228.0 margin_right = 205.0 margin_bottom = 252.0 mouse_default_cursor_shape = 2 -text = "Português Brasileiro [pt_BR]" +text = "Polski [pl]" -[node name="Russian" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +[node name="Brazilian Portuguese" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 256.0 margin_right = 205.0 margin_bottom = 280.0 mouse_default_cursor_shape = 2 -text = "Русский [ru]" +text = "Português Brasileiro [pt_BR]" -[node name="Traditional Chinese" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +[node name="Russian" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] margin_top = 284.0 margin_right = 205.0 -margin_bottom = 310.0 +margin_bottom = 308.0 +mouse_default_cursor_shape = 2 +text = "Русский [ru]" + +[node name="Chinese Traditional" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/Languages"] +margin_top = 312.0 +margin_right = 205.0 +margin_bottom = 338.0 mouse_default_cursor_shape = 2 custom_fonts/font = ExtResource( 3 ) text = "繁體中文 [zh_TW]" [node name="Themes" type="VBoxContainer" parent="HSplitContainer/ScrollContainer/VBoxContainer"] -editor/display_folded = true -margin_top = 314.0 +margin_top = 342.0 margin_right = 205.0 -margin_bottom = 482.0 +margin_bottom = 510.0 [node name="Theme Options" type="Label" parent="HSplitContainer/ScrollContainer/VBoxContainer/Themes"] margin_right = 205.0 @@ -178,10 +177,9 @@ mouse_default_cursor_shape = 2 text = "Light" [node name="Grid&Guides" type="VBoxContainer" parent="HSplitContainer/ScrollContainer/VBoxContainer"] -editor/display_folded = true -margin_top = 486.0 +margin_top = 514.0 margin_right = 205.0 -margin_bottom = 618.0 +margin_bottom = 646.0 [node name="GridOptionsLabel" type="Label" parent="HSplitContainer/ScrollContainer/VBoxContainer/Grid&Guides"] margin_right = 205.0 @@ -256,10 +254,9 @@ rect_min_size = Vector2( 64, 20 ) color = Color( 0.63, 0.13, 0.94, 1 ) [node name="Image" type="VBoxContainer" parent="HSplitContainer/ScrollContainer/VBoxContainer"] -editor/display_folded = true -margin_top = 622.0 +margin_top = 650.0 margin_right = 205.0 -margin_bottom = 730.0 +margin_bottom = 758.0 [node name="ImageOptionsLabel" type="Label" parent="HSplitContainer/ScrollContainer/VBoxContainer/Image"] margin_right = 205.0 diff --git a/Scripts/Dialogs/PreferencesDialog.gd b/Scripts/Dialogs/PreferencesDialog.gd index 642949edb..f3a80698a 100644 --- a/Scripts/Dialogs/PreferencesDialog.gd +++ b/Scripts/Dialogs/PreferencesDialog.gd @@ -20,6 +20,7 @@ func _ready() -> void: for child in languages.get_children(): if child is Button: child.connect("pressed", self, "_on_Language_pressed", [child]) + child.hint_tooltip = child.name for child in themes.get_children(): if child is Button: