Browse Source

Use bound theme properties for documentation

Yuri Sizov 1 year ago
parent
commit
596dd726a1

+ 20 - 0
doc/classes/Button.xml

@@ -131,20 +131,40 @@
 		<theme_item name="font_size" data_type="font_size" type="int">
 		<theme_item name="font_size" data_type="font_size" type="int">
 			Font size of the [Button]'s text.
 			Font size of the [Button]'s text.
 		</theme_item>
 		</theme_item>
+		<theme_item name="icon" data_type="icon" type="Texture2D">
+		</theme_item>
 		<theme_item name="disabled" data_type="style" type="StyleBox">
 		<theme_item name="disabled" data_type="style" type="StyleBox">
 			[StyleBox] used when the [Button] is disabled.
 			[StyleBox] used when the [Button] is disabled.
 		</theme_item>
 		</theme_item>
+		<theme_item name="disabled_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the [Button] is disabled (for right-to-left layouts).
+		</theme_item>
 		<theme_item name="focus" data_type="style" type="StyleBox">
 		<theme_item name="focus" data_type="style" type="StyleBox">
 			[StyleBox] used when the [Button] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
 			[StyleBox] used when the [Button] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
 		</theme_item>
 		</theme_item>
 		<theme_item name="hover" data_type="style" type="StyleBox">
 		<theme_item name="hover" data_type="style" type="StyleBox">
 			[StyleBox] used when the [Button] is being hovered.
 			[StyleBox] used when the [Button] is being hovered.
 		</theme_item>
 		</theme_item>
+		<theme_item name="hover_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the [Button] is being hovered (for right-to-left layouts).
+		</theme_item>
+		<theme_item name="hover_pressed" data_type="style" type="StyleBox">
+			[StyleBox] used when the [Button] is being pressed and hovered at the same time.
+		</theme_item>
+		<theme_item name="hover_pressed_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the [Button] is being pressed and hovered at the same time (for right-to-left layouts).
+		</theme_item>
 		<theme_item name="normal" data_type="style" type="StyleBox">
 		<theme_item name="normal" data_type="style" type="StyleBox">
 			Default [StyleBox] for the [Button].
 			Default [StyleBox] for the [Button].
 		</theme_item>
 		</theme_item>
+		<theme_item name="normal_mirrored" data_type="style" type="StyleBox">
+			Default [StyleBox] for the [Button] (for right-to-left layouts).
+		</theme_item>
 		<theme_item name="pressed" data_type="style" type="StyleBox">
 		<theme_item name="pressed" data_type="style" type="StyleBox">
 			[StyleBox] used when the [Button] is being pressed.
 			[StyleBox] used when the [Button] is being pressed.
 		</theme_item>
 		</theme_item>
+		<theme_item name="pressed_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the [Button] is being pressed (for right-to-left layouts).
+		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 0 - 52
doc/classes/CheckBox.xml

@@ -15,43 +15,9 @@
 		<member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" overrides="BaseButton" default="true" />
 		<member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" overrides="BaseButton" default="true" />
 	</members>
 	</members>
 	<theme_items>
 	<theme_items>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			The [CheckBox] text's font color.
-		</theme_item>
-		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 0.5)">
-			The [CheckBox] text's font color when it's disabled.
-		</theme_item>
-		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			The [CheckBox] text's font color when it's focused. Only replaces the normal text color of the checkbox. Disabled, hovered, and pressed states take precedence over this color.
-		</theme_item>
-		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			The [CheckBox] text's font color when it's hovered.
-		</theme_item>
-		<theme_item name="font_hover_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The [CheckBox] text's font color when it's hovered and pressed.
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [CheckBox].
-		</theme_item>
-		<theme_item name="font_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The [CheckBox] text's font color when it's pressed.
-		</theme_item>
 		<theme_item name="check_v_offset" data_type="constant" type="int" default="0">
 		<theme_item name="check_v_offset" data_type="constant" type="int" default="0">
 			The vertical offset used when rendering the check icons (in pixels).
 			The vertical offset used when rendering the check icons (in pixels).
 		</theme_item>
 		</theme_item>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The separation between the check icon and the text (in pixels). Negative values will be treated as [code]0[/code] when used.
-		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			The [Font] to use for the [CheckBox] text.
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Font size of the [CheckBox]'s text.
-		</theme_item>
 		<theme_item name="checked" data_type="icon" type="Texture2D">
 		<theme_item name="checked" data_type="icon" type="Texture2D">
 			The check icon to display when the [CheckBox] is checked.
 			The check icon to display when the [CheckBox] is checked.
 		</theme_item>
 		</theme_item>
@@ -76,23 +42,5 @@
 		<theme_item name="unchecked_disabled" data_type="icon" type="Texture2D">
 		<theme_item name="unchecked_disabled" data_type="icon" type="Texture2D">
 			The check icon to display when the [CheckBox] is unchecked and is disabled.
 			The check icon to display when the [CheckBox] is unchecked and is disabled.
 		</theme_item>
 		</theme_item>
-		<theme_item name="disabled" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckBox] is disabled.
-		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckBox] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="hover" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckBox] is hovered.
-		</theme_item>
-		<theme_item name="hover_pressed" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckBox] is hovered and pressed.
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background.
-		</theme_item>
-		<theme_item name="pressed" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckBox] is pressed.
-		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 0 - 52
doc/classes/CheckButton.xml

@@ -14,43 +14,9 @@
 		<member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" overrides="BaseButton" default="true" />
 		<member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" overrides="BaseButton" default="true" />
 	</members>
 	</members>
 	<theme_items>
 	<theme_items>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			The [CheckButton] text's font color.
-		</theme_item>
-		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 0.5)">
-			The [CheckButton] text's font color when it's disabled.
-		</theme_item>
-		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			The [CheckButton] text's font color when it's focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
-		</theme_item>
-		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			The [CheckButton] text's font color when it's hovered.
-		</theme_item>
-		<theme_item name="font_hover_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The [CheckButton] text's font color when it's hovered and pressed.
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [CheckButton].
-		</theme_item>
-		<theme_item name="font_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The [CheckButton] text's font color when it's pressed.
-		</theme_item>
 		<theme_item name="check_v_offset" data_type="constant" type="int" default="0">
 		<theme_item name="check_v_offset" data_type="constant" type="int" default="0">
 			The vertical offset used when rendering the toggle icons (in pixels).
 			The vertical offset used when rendering the toggle icons (in pixels).
 		</theme_item>
 		</theme_item>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The separation between the toggle icon and the text (in pixels). Negative values will be treated as [code]0[/code] when used.
-		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			The [Font] to use for the [CheckButton] text.
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Font size of the [CheckButton]'s text.
-		</theme_item>
 		<theme_item name="checked" data_type="icon" type="Texture2D">
 		<theme_item name="checked" data_type="icon" type="Texture2D">
 			The icon to display when the [CheckButton] is checked (for left-to-right layouts).
 			The icon to display when the [CheckButton] is checked (for left-to-right layouts).
 		</theme_item>
 		</theme_item>
@@ -75,23 +41,5 @@
 		<theme_item name="unchecked_mirrored" data_type="icon" type="Texture2D">
 		<theme_item name="unchecked_mirrored" data_type="icon" type="Texture2D">
 			The icon to display when the [CheckButton] is unchecked (for right-to-left layouts).
 			The icon to display when the [CheckButton] is unchecked (for right-to-left layouts).
 		</theme_item>
 		</theme_item>
-		<theme_item name="disabled" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckButton] is disabled.
-		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckButton] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="hover" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckButton] is hovered.
-		</theme_item>
-		<theme_item name="hover_pressed" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckButton] is hovered and pressed.
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background.
-		</theme_item>
-		<theme_item name="pressed" data_type="style" type="StyleBox">
-			The [StyleBox] to display as a background when the [CheckButton] is pressed.
-		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 0 - 70
doc/classes/CodeEdit.xml

@@ -633,9 +633,6 @@
 		</constant>
 		</constant>
 	</constants>
 	</constants>
 	<theme_items>
 	<theme_items>
-		<theme_item name="background_color" data_type="color" type="Color" default="Color(0, 0, 0, 0)">
-			Sets the background [Color].
-		</theme_item>
 		<theme_item name="bookmark_color" data_type="color" type="Color" default="Color(0.5, 0.64, 1, 0.8)">
 		<theme_item name="bookmark_color" data_type="color" type="Color" default="Color(0.5, 0.64, 1, 0.8)">
 			[Color] of the bookmark icon for bookmarked lines.
 			[Color] of the bookmark icon for bookmarked lines.
 		</theme_item>
 		</theme_item>
@@ -645,12 +642,6 @@
 		<theme_item name="breakpoint_color" data_type="color" type="Color" default="Color(0.9, 0.29, 0.3, 1)">
 		<theme_item name="breakpoint_color" data_type="color" type="Color" default="Color(0.9, 0.29, 0.3, 1)">
 			[Color] of the breakpoint icon for bookmarked lines.
 			[Color] of the breakpoint icon for bookmarked lines.
 		</theme_item>
 		</theme_item>
-		<theme_item name="caret_background_color" data_type="color" type="Color" default="Color(0, 0, 0, 1)">
-			[Color] of the text behind the caret when block caret is enabled.
-		</theme_item>
-		<theme_item name="caret_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			[Color] of the caret.
-		</theme_item>
 		<theme_item name="code_folding_color" data_type="color" type="Color" default="Color(0.8, 0.8, 0.8, 0.8)">
 		<theme_item name="code_folding_color" data_type="color" type="Color" default="Color(0.8, 0.8, 0.8, 0.8)">
 			[Color] for all icons related to line folding.
 			[Color] for all icons related to line folding.
 		</theme_item>
 		</theme_item>
@@ -660,9 +651,6 @@
 		<theme_item name="completion_existing_color" data_type="color" type="Color" default="Color(0.87, 0.87, 0.87, 0.13)">
 		<theme_item name="completion_existing_color" data_type="color" type="Color" default="Color(0.87, 0.87, 0.87, 0.13)">
 			Background highlight [Color] for matching text in code completion options.
 			Background highlight [Color] for matching text in code completion options.
 		</theme_item>
 		</theme_item>
-		<theme_item name="completion_font_color" data_type="color" type="Color" default="Color(0.67, 0.67, 0.67, 1)">
-			Font [Color] for the code completion popup.
-		</theme_item>
 		<theme_item name="completion_scroll_color" data_type="color" type="Color" default="Color(1, 1, 1, 0.29)">
 		<theme_item name="completion_scroll_color" data_type="color" type="Color" default="Color(1, 1, 1, 0.29)">
 			[Color] of the scrollbar in the code completion popup.
 			[Color] of the scrollbar in the code completion popup.
 		</theme_item>
 		</theme_item>
@@ -672,48 +660,18 @@
 		<theme_item name="completion_selected_color" data_type="color" type="Color" default="Color(0.26, 0.26, 0.27, 1)">
 		<theme_item name="completion_selected_color" data_type="color" type="Color" default="Color(0.26, 0.26, 0.27, 1)">
 			Background highlight [Color] for the current selected option item in the code completion popup.
 			Background highlight [Color] for the current selected option item in the code completion popup.
 		</theme_item>
 		</theme_item>
-		<theme_item name="current_line_color" data_type="color" type="Color" default="Color(0.25, 0.25, 0.26, 0.8)">
-			Background [Color] of the line containing the caret.
-		</theme_item>
 		<theme_item name="executing_line_color" data_type="color" type="Color" default="Color(0.98, 0.89, 0.27, 1)">
 		<theme_item name="executing_line_color" data_type="color" type="Color" default="Color(0.98, 0.89, 0.27, 1)">
 			[Color] of the executing icon for executing lines.
 			[Color] of the executing icon for executing lines.
 		</theme_item>
 		</theme_item>
 		<theme_item name="folded_code_region_color" data_type="color" type="Color" default="Color(0.68, 0.46, 0.77, 0.2)">
 		<theme_item name="folded_code_region_color" data_type="color" type="Color" default="Color(0.68, 0.46, 0.77, 0.2)">
 			[Color] of background line highlight for folded code region.
 			[Color] of background line highlight for folded code region.
 		</theme_item>
 		</theme_item>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			Sets the font [Color].
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [CodeEdit].
-		</theme_item>
-		<theme_item name="font_placeholder_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 0.6)">
-			Font color for [member TextEdit.placeholder_text].
-		</theme_item>
-		<theme_item name="font_readonly_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 0.5)">
-			Sets the font [Color] when [member TextEdit.editable] is disabled.
-		</theme_item>
-		<theme_item name="font_selected_color" data_type="color" type="Color" default="Color(0, 0, 0, 0)">
-			Sets the [Color] of the selected text. If equal to [code]Color(0, 0, 0, 0)[/code], it will be ignored.
-		</theme_item>
 		<theme_item name="line_length_guideline_color" data_type="color" type="Color" default="Color(0.3, 0.5, 0.8, 0.1)">
 		<theme_item name="line_length_guideline_color" data_type="color" type="Color" default="Color(0.3, 0.5, 0.8, 0.1)">
 			[Color] of the main line length guideline, secondary guidelines will have 50% alpha applied.
 			[Color] of the main line length guideline, secondary guidelines will have 50% alpha applied.
 		</theme_item>
 		</theme_item>
 		<theme_item name="line_number_color" data_type="color" type="Color" default="Color(0.67, 0.67, 0.67, 0.4)">
 		<theme_item name="line_number_color" data_type="color" type="Color" default="Color(0.67, 0.67, 0.67, 0.4)">
 			Sets the [Color] of line numbers.
 			Sets the [Color] of line numbers.
 		</theme_item>
 		</theme_item>
-		<theme_item name="search_result_border_color" data_type="color" type="Color" default="Color(0.3, 0.3, 0.3, 0.4)">
-			[Color] of the border around text that matches the search query.
-		</theme_item>
-		<theme_item name="search_result_color" data_type="color" type="Color" default="Color(0.3, 0.3, 0.3, 1)">
-			[Color] behind the text that matches the search query.
-		</theme_item>
-		<theme_item name="selection_color" data_type="color" type="Color" default="Color(0.5, 0.5, 0.5, 1)">
-			Sets the highlight [Color] of text selections.
-		</theme_item>
-		<theme_item name="word_highlighted_color" data_type="color" type="Color" default="Color(0.8, 0.9, 0.9, 0.15)">
-			Sets the highlight [Color] of multiple occurrences. [member TextEdit.highlight_all_occurrences] has to be enabled.
-		</theme_item>
 		<theme_item name="completion_lines" data_type="constant" type="int" default="7">
 		<theme_item name="completion_lines" data_type="constant" type="int" default="7">
 			Max number of options to display in the code completion popup at any one time.
 			Max number of options to display in the code completion popup at any one time.
 		</theme_item>
 		</theme_item>
@@ -723,19 +681,6 @@
 		<theme_item name="completion_scroll_width" data_type="constant" type="int" default="6">
 		<theme_item name="completion_scroll_width" data_type="constant" type="int" default="6">
 			Width of the scrollbar in the code completion popup.
 			Width of the scrollbar in the code completion popup.
 		</theme_item>
 		</theme_item>
-		<theme_item name="line_spacing" data_type="constant" type="int" default="4">
-			Sets the spacing between the lines.
-		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			Sets the default [Font].
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Sets default font size.
-		</theme_item>
 		<theme_item name="bookmark" data_type="icon" type="Texture2D">
 		<theme_item name="bookmark" data_type="icon" type="Texture2D">
 			Sets a custom [Texture2D] to draw in the bookmark gutter for bookmarked lines.
 			Sets a custom [Texture2D] to draw in the bookmark gutter for bookmarked lines.
 		</theme_item>
 		</theme_item>
@@ -760,23 +705,8 @@
 		<theme_item name="folded_eol_icon" data_type="icon" type="Texture2D">
 		<theme_item name="folded_eol_icon" data_type="icon" type="Texture2D">
 			Sets a custom [Texture2D] to draw at the end of a folded line.
 			Sets a custom [Texture2D] to draw at the end of a folded line.
 		</theme_item>
 		</theme_item>
-		<theme_item name="space" data_type="icon" type="Texture2D">
-			Sets a custom [Texture2D] for space text characters.
-		</theme_item>
-		<theme_item name="tab" data_type="icon" type="Texture2D">
-			Sets a custom [Texture2D] for tab text characters.
-		</theme_item>
 		<theme_item name="completion" data_type="style" type="StyleBox">
 		<theme_item name="completion" data_type="style" type="StyleBox">
 			[StyleBox] for the code completion popup.
 			[StyleBox] for the code completion popup.
 		</theme_item>
 		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			Sets the [StyleBox] when in focus. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			Sets the [StyleBox].
-		</theme_item>
-		<theme_item name="read_only" data_type="style" type="StyleBox">
-			Sets the [StyleBox] when [member TextEdit.editable] is disabled.
-		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 1 - 1
doc/classes/ColorPicker.xml

@@ -142,7 +142,7 @@
 	</constants>
 	</constants>
 	<theme_items>
 	<theme_items>
 		<theme_item name="center_slider_grabbers" data_type="constant" type="int" default="1">
 		<theme_item name="center_slider_grabbers" data_type="constant" type="int" default="1">
-			Overrides the [theme_item HSlider.center_grabber] theme property of the sliders.
+			Overrides the [theme_item Slider.center_grabber] theme property of the sliders.
 		</theme_item>
 		</theme_item>
 		<theme_item name="h_width" data_type="constant" type="int" default="30">
 		<theme_item name="h_width" data_type="constant" type="int" default="30">
 			The width of the hue selection slider.
 			The width of the hue selection slider.

+ 0 - 46
doc/classes/ColorPickerButton.xml

@@ -56,54 +56,8 @@
 		</signal>
 		</signal>
 	</signals>
 	</signals>
 	<theme_items>
 	<theme_items>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Default text [Color] of the [ColorPickerButton].
-		</theme_item>
-		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(0.9, 0.9, 0.9, 0.3)">
-			Text [Color] used when the [ColorPickerButton] is disabled.
-		</theme_item>
-		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Text [Color] used when the [ColorPickerButton] is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
-		</theme_item>
-		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Text [Color] used when the [ColorPickerButton] is being hovered.
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [ColorPickerButton].
-		</theme_item>
-		<theme_item name="font_pressed_color" data_type="color" type="Color" default="Color(0.8, 0.8, 0.8, 1)">
-			Text [Color] used when the [ColorPickerButton] is being pressed.
-		</theme_item>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The horizontal space between [ColorPickerButton]'s icon and text.
-		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			[Font] of the [ColorPickerButton]'s text.
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Font size of the [ColorPickerButton]'s text.
-		</theme_item>
 		<theme_item name="bg" data_type="icon" type="Texture2D">
 		<theme_item name="bg" data_type="icon" type="Texture2D">
 			The background of the color preview rect on the button.
 			The background of the color preview rect on the button.
 		</theme_item>
 		</theme_item>
-		<theme_item name="disabled" data_type="style" type="StyleBox">
-			[StyleBox] used when the [ColorPickerButton] is disabled.
-		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			[StyleBox] used when the [ColorPickerButton] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="hover" data_type="style" type="StyleBox">
-			[StyleBox] used when the [ColorPickerButton] is being hovered.
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			Default [StyleBox] for the [ColorPickerButton].
-		</theme_item>
-		<theme_item name="pressed" data_type="style" type="StyleBox">
-			[StyleBox] used when the [ColorPickerButton] is being pressed.
-		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 5 - 0
doc/classes/GraphElement.xml

@@ -66,4 +66,9 @@
 			</description>
 			</description>
 		</signal>
 		</signal>
 	</signals>
 	</signals>
+	<theme_items>
+		<theme_item name="resizer" data_type="icon" type="Texture2D">
+			The icon used for the resizer, visible when [member resizable] is enabled.
+		</theme_item>
+	</theme_items>
 </class>
 </class>

+ 0 - 3
doc/classes/GraphNode.xml

@@ -263,9 +263,6 @@
 		<theme_item name="port" data_type="icon" type="Texture2D">
 		<theme_item name="port" data_type="icon" type="Texture2D">
 			The icon used for representing ports.
 			The icon used for representing ports.
 		</theme_item>
 		</theme_item>
-		<theme_item name="resizer" data_type="icon" type="Texture2D">
-			The icon used for the resizer, visible when [member GraphElement.resizable] is enabled.
-		</theme_item>
 		<theme_item name="panel" data_type="style" type="StyleBox">
 		<theme_item name="panel" data_type="style" type="StyleBox">
 			The default background for the slot area of the [GraphNode].
 			The default background for the slot area of the [GraphNode].
 		</theme_item>
 		</theme_item>

+ 0 - 5
doc/classes/HBoxContainer.xml

@@ -9,9 +9,4 @@
 	<tutorials>
 	<tutorials>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="separation" data_type="constant" type="int" default="4">
-			The horizontal space between the [HBoxContainer]'s elements.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 8
doc/classes/HFlowContainer.xml

@@ -9,12 +9,4 @@
 	<tutorials>
 	<tutorials>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The horizontal separation of children nodes.
-		</theme_item>
-		<theme_item name="v_separation" data_type="constant" type="int" default="4">
-			The vertical separation of children nodes.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 35
doc/classes/HScrollBar.xml

@@ -8,39 +8,4 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="decrement" data_type="icon" type="Texture2D">
-			Icon used as a button to scroll the [ScrollBar] left. Supports custom step using the [member ScrollBar.custom_step] property.
-		</theme_item>
-		<theme_item name="decrement_highlight" data_type="icon" type="Texture2D">
-			Displayed when the mouse cursor hovers over the decrement button.
-		</theme_item>
-		<theme_item name="decrement_pressed" data_type="icon" type="Texture2D">
-			Displayed when the decrement button is being pressed.
-		</theme_item>
-		<theme_item name="increment" data_type="icon" type="Texture2D">
-			Icon used as a button to scroll the [ScrollBar] right. Supports custom step using the [member ScrollBar.custom_step] property.
-		</theme_item>
-		<theme_item name="increment_highlight" data_type="icon" type="Texture2D">
-			Displayed when the mouse cursor hovers over the increment button.
-		</theme_item>
-		<theme_item name="increment_pressed" data_type="icon" type="Texture2D">
-			Displayed when the increment button is being pressed.
-		</theme_item>
-		<theme_item name="grabber" data_type="style" type="StyleBox">
-			Used as texture for the grabber, the draggable element representing current scroll.
-		</theme_item>
-		<theme_item name="grabber_highlight" data_type="style" type="StyleBox">
-			Used when the mouse hovers over the grabber.
-		</theme_item>
-		<theme_item name="grabber_pressed" data_type="style" type="StyleBox">
-			Used when the grabber is being dragged.
-		</theme_item>
-		<theme_item name="scroll" data_type="style" type="StyleBox">
-			Used as background of this [ScrollBar].
-		</theme_item>
-		<theme_item name="scroll_focus" data_type="style" type="StyleBox">
-			Used as background when the [ScrollBar] has the GUI focus.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 8
doc/classes/HSeparator.xml

@@ -8,12 +8,4 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="separation" data_type="constant" type="int" default="4">
-			The height of the area covered by the separator. Effectively works like a minimum height.
-		</theme_item>
-		<theme_item name="separator" data_type="style" type="StyleBox">
-			The style for the separator line. Works best with [StyleBoxLine].
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 29
doc/classes/HSlider.xml

@@ -8,33 +8,4 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="center_grabber" data_type="constant" type="int" default="0">
-			Boolean constant. If [code]1[/code], the grabber texture size will be ignored and it will fit within slider's bounds based only on its center position.
-		</theme_item>
-		<theme_item name="grabber_offset" data_type="constant" type="int" default="0">
-			Vertical offset of the grabber.
-		</theme_item>
-		<theme_item name="grabber" data_type="icon" type="Texture2D">
-			The texture for the grabber (the draggable element).
-		</theme_item>
-		<theme_item name="grabber_disabled" data_type="icon" type="Texture2D">
-			The texture for the grabber when it's disabled.
-		</theme_item>
-		<theme_item name="grabber_highlight" data_type="icon" type="Texture2D">
-			The texture for the grabber when it's focused.
-		</theme_item>
-		<theme_item name="tick" data_type="icon" type="Texture2D">
-			The texture for the ticks, visible when [member Slider.tick_count] is greater than 0.
-		</theme_item>
-		<theme_item name="grabber_area" data_type="style" type="StyleBox">
-			The background of the area to the left of the grabber.
-		</theme_item>
-		<theme_item name="grabber_area_highlight" data_type="style" type="StyleBox">
-			The background of the area to the left of the grabber that displays when it's being hovered or focused.
-		</theme_item>
-		<theme_item name="slider" data_type="style" type="StyleBox">
-			The background for the whole slider. Determines the height of the [code]grabber_area[/code].
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 14
doc/classes/HSplitContainer.xml

@@ -9,18 +9,4 @@
 	<tutorials>
 	<tutorials>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="autohide" data_type="constant" type="int" default="1">
-			Boolean value. If 1 ([code]true[/code]), the grabber will hide automatically when it isn't under the cursor. If 0 ([code]false[/code]), it's always visible.
-		</theme_item>
-		<theme_item name="minimum_grab_thickness" data_type="constant" type="int" default="6">
-			The minimum thickness of the area users can click on to grab the splitting line. If [theme_item separation] or [theme_item grabber]'s thickness are too small, this ensure that the splitting line can still be dragged.
-		</theme_item>
-		<theme_item name="separation" data_type="constant" type="int" default="12">
-			The space between sides of the container.
-		</theme_item>
-		<theme_item name="grabber" data_type="icon" type="Texture2D">
-			The icon used for the grabber drawn in the middle area.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 6 - 0
doc/classes/LinkButton.xml

@@ -62,12 +62,18 @@
 		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
 		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
 			Default text [Color] of the [LinkButton].
 			Default text [Color] of the [LinkButton].
 		</theme_item>
 		</theme_item>
+		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(0, 0, 0, 1)">
+			Text [Color] used when the [LinkButton] is disabled.
+		</theme_item>
 		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
 		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
 			Text [Color] used when the [LinkButton] is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
 			Text [Color] used when the [LinkButton] is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
 		</theme_item>
 		</theme_item>
 		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
 		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
 			Text [Color] used when the [LinkButton] is being hovered.
 			Text [Color] used when the [LinkButton] is being hovered.
 		</theme_item>
 		</theme_item>
+		<theme_item name="font_hover_pressed_color" data_type="color" type="Color" default="Color(0, 0, 0, 1)">
+			Text [Color] used when the [LinkButton] is being hovered and pressed.
+		</theme_item>
 		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
 		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
 			The tint of text outline of the [LinkButton].
 			The tint of text outline of the [LinkButton].
 		</theme_item>
 		</theme_item>

+ 17 - 2
doc/classes/MenuBar.xml

@@ -154,17 +154,32 @@
 		<theme_item name="disabled" data_type="style" type="StyleBox">
 		<theme_item name="disabled" data_type="style" type="StyleBox">
 			[StyleBox] used when the menu item is disabled.
 			[StyleBox] used when the menu item is disabled.
 		</theme_item>
 		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			[StyleBox] used when the menu item is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
+		<theme_item name="disabled_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the menu item is disabled (for right-to-left layouts).
 		</theme_item>
 		</theme_item>
 		<theme_item name="hover" data_type="style" type="StyleBox">
 		<theme_item name="hover" data_type="style" type="StyleBox">
 			[StyleBox] used when the menu item is being hovered.
 			[StyleBox] used when the menu item is being hovered.
 		</theme_item>
 		</theme_item>
+		<theme_item name="hover_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the menu item is being hovered (for right-to-left layouts).
+		</theme_item>
+		<theme_item name="hover_pressed" data_type="style" type="StyleBox">
+			[StyleBox] used when the menu item is being pressed and hovered at the same time.
+		</theme_item>
+		<theme_item name="hover_pressed_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the menu item is being pressed and hovered at the same time (for right-to-left layouts).
+		</theme_item>
 		<theme_item name="normal" data_type="style" type="StyleBox">
 		<theme_item name="normal" data_type="style" type="StyleBox">
 			Default [StyleBox] for the menu item.
 			Default [StyleBox] for the menu item.
 		</theme_item>
 		</theme_item>
+		<theme_item name="normal_mirrored" data_type="style" type="StyleBox">
+			Default [StyleBox] for the menu item (for right-to-left layouts).
+		</theme_item>
 		<theme_item name="pressed" data_type="style" type="StyleBox">
 		<theme_item name="pressed" data_type="style" type="StyleBox">
 			[StyleBox] used when the menu item is being pressed.
 			[StyleBox] used when the menu item is being pressed.
 		</theme_item>
 		</theme_item>
+		<theme_item name="pressed_mirrored" data_type="style" type="StyleBox">
+			[StyleBox] used when the menu item is being pressed (for right-to-left layouts).
+		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 0 - 48
doc/classes/MenuButton.xml

@@ -50,52 +50,4 @@
 			</description>
 			</description>
 		</signal>
 		</signal>
 	</signals>
 	</signals>
-	<theme_items>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			Default text [Color] of the [MenuButton].
-		</theme_item>
-		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(1, 1, 1, 0.3)">
-			Text [Color] used when the [MenuButton] is disabled.
-		</theme_item>
-		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			Text [Color] used when the [MenuButton] is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
-		</theme_item>
-		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			Text [Color] used when the [MenuButton] is being hovered.
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [MenuButton].
-		</theme_item>
-		<theme_item name="font_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Text [Color] used when the [MenuButton] is being pressed.
-		</theme_item>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The horizontal space between [MenuButton]'s icon and text. Negative values will be treated as [code]0[/code] when used.
-		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			[Font] of the [MenuButton]'s text.
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Font size of the [MenuButton]'s text.
-		</theme_item>
-		<theme_item name="disabled" data_type="style" type="StyleBox">
-			[StyleBox] used when the [MenuButton] is disabled.
-		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			[StyleBox] used when the [MenuButton] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="hover" data_type="style" type="StyleBox">
-			[StyleBox] used when the [MenuButton] is being hovered.
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			Default [StyleBox] for the [MenuButton].
-		</theme_item>
-		<theme_item name="pressed" data_type="style" type="StyleBox">
-			[StyleBox] used when the [MenuButton] is being pressed.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 61
doc/classes/OptionButton.xml

@@ -243,75 +243,14 @@
 		</signal>
 		</signal>
 	</signals>
 	</signals>
 	<theme_items>
 	<theme_items>
-		<theme_item name="font_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
-			Default text [Color] of the [OptionButton].
-		</theme_item>
-		<theme_item name="font_disabled_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 0.5)">
-			Text [Color] used when the [OptionButton] is disabled.
-		</theme_item>
-		<theme_item name="font_focus_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			Text [Color] used when the [OptionButton] is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.
-		</theme_item>
-		<theme_item name="font_hover_color" data_type="color" type="Color" default="Color(0.95, 0.95, 0.95, 1)">
-			Text [Color] used when the [OptionButton] is being hovered.
-		</theme_item>
-		<theme_item name="font_hover_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Text [Color] used when the [OptionButton] is being hovered and pressed.
-		</theme_item>
-		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			The tint of text outline of the [OptionButton].
-		</theme_item>
-		<theme_item name="font_pressed_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
-			Text [Color] used when the [OptionButton] is being pressed.
-		</theme_item>
 		<theme_item name="arrow_margin" data_type="constant" type="int" default="4">
 		<theme_item name="arrow_margin" data_type="constant" type="int" default="4">
 			The horizontal space between the arrow icon and the right edge of the button.
 			The horizontal space between the arrow icon and the right edge of the button.
 		</theme_item>
 		</theme_item>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The horizontal space between [OptionButton]'s icon and text. Negative values will be treated as [code]0[/code] when used.
-		</theme_item>
 		<theme_item name="modulate_arrow" data_type="constant" type="int" default="0">
 		<theme_item name="modulate_arrow" data_type="constant" type="int" default="0">
 			If different than [code]0[/code], the arrow icon will be modulated to the font color.
 			If different than [code]0[/code], the arrow icon will be modulated to the font color.
 		</theme_item>
 		</theme_item>
-		<theme_item name="outline_size" data_type="constant" type="int" default="0">
-			The size of the text outline.
-			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
-		</theme_item>
-		<theme_item name="font" data_type="font" type="Font">
-			[Font] of the [OptionButton]'s text.
-		</theme_item>
-		<theme_item name="font_size" data_type="font_size" type="int">
-			Font size of the [OptionButton]'s text.
-		</theme_item>
 		<theme_item name="arrow" data_type="icon" type="Texture2D">
 		<theme_item name="arrow" data_type="icon" type="Texture2D">
 			The arrow icon to be drawn on the right end of the button.
 			The arrow icon to be drawn on the right end of the button.
 		</theme_item>
 		</theme_item>
-		<theme_item name="disabled" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is disabled (for left-to-right layouts).
-		</theme_item>
-		<theme_item name="disabled_mirrored" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is disabled (for right-to-left layouts).
-		</theme_item>
-		<theme_item name="focus" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is focused. The [code]focus[/code] [StyleBox] is displayed [i]over[/i] the base [StyleBox], so a partially transparent [StyleBox] should be used to ensure the base [StyleBox] remains visible. A [StyleBox] that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a [StyleBoxEmpty] resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.
-		</theme_item>
-		<theme_item name="hover" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is being hovered (for left-to-right layouts).
-		</theme_item>
-		<theme_item name="hover_mirrored" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is being hovered (for right-to-left layouts).
-		</theme_item>
-		<theme_item name="normal" data_type="style" type="StyleBox">
-			Default [StyleBox] for the [OptionButton] (for left-to-right layouts).
-		</theme_item>
-		<theme_item name="normal_mirrored" data_type="style" type="StyleBox">
-			Default [StyleBox] for the [OptionButton] (for right-to-left layouts).
-		</theme_item>
-		<theme_item name="pressed" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is being pressed (for left-to-right layouts).
-		</theme_item>
-		<theme_item name="pressed_mirrored" data_type="style" type="StyleBox">
-			[StyleBox] used when the [OptionButton] is being pressed (for right-to-left layouts).
-		</theme_item>
 	</theme_items>
 	</theme_items>
 </class>
 </class>

+ 5 - 0
doc/classes/Popup.xml

@@ -23,4 +23,9 @@
 			</description>
 			</description>
 		</signal>
 		</signal>
 	</signals>
 	</signals>
+	<theme_items>
+		<theme_item name="panel" data_type="style" type="StyleBox">
+			Default [StyleBox] for the [Popup].
+		</theme_item>
+	</theme_items>
 </class>
 </class>

+ 0 - 6
doc/classes/PopupMenu.xml

@@ -691,12 +691,6 @@
 		<theme_item name="labeled_separator_right" data_type="style" type="StyleBox">
 		<theme_item name="labeled_separator_right" data_type="style" type="StyleBox">
 			[StyleBox] for the right side of labeled separator. See [method add_separator].
 			[StyleBox] for the right side of labeled separator. See [method add_separator].
 		</theme_item>
 		</theme_item>
-		<theme_item name="panel" data_type="style" type="StyleBox">
-			Default [StyleBox] of the [PopupMenu] items.
-		</theme_item>
-		<theme_item name="panel_disabled" data_type="style" type="StyleBox">
-			[StyleBox] used when the [PopupMenu] item is disabled.
-		</theme_item>
 		<theme_item name="separator" data_type="style" type="StyleBox">
 		<theme_item name="separator" data_type="style" type="StyleBox">
 			[StyleBox] used for the separators. See [method add_separator].
 			[StyleBox] used for the separators. See [method add_separator].
 		</theme_item>
 		</theme_item>

+ 0 - 5
doc/classes/PopupPanel.xml

@@ -8,9 +8,4 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="panel" data_type="style" type="StyleBox">
-			The background panel style of this [PopupPanel].
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 3
doc/classes/ProgressBar.xml

@@ -37,9 +37,6 @@
 		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
 		<theme_item name="font_outline_color" data_type="color" type="Color" default="Color(1, 1, 1, 1)">
 			The tint of text outline of the [ProgressBar].
 			The tint of text outline of the [ProgressBar].
 		</theme_item>
 		</theme_item>
-		<theme_item name="font_shadow_color" data_type="color" type="Color" default="Color(0, 0, 0, 1)">
-			The color of the text's shadow.
-		</theme_item>
 		<theme_item name="outline_size" data_type="constant" type="int" default="0">
 		<theme_item name="outline_size" data_type="constant" type="int" default="0">
 			The size of the text outline.
 			The size of the text outline.
 			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
 			[b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.

+ 37 - 0
doc/classes/ScrollBar.xml

@@ -21,4 +21,41 @@
 			</description>
 			</description>
 		</signal>
 		</signal>
 	</signals>
 	</signals>
+	<theme_items>
+		<theme_item name="decrement" data_type="icon" type="Texture2D">
+			Icon used as a button to scroll the [ScrollBar] left/up. Supports custom step using the [member ScrollBar.custom_step] property.
+		</theme_item>
+		<theme_item name="decrement_highlight" data_type="icon" type="Texture2D">
+			Displayed when the mouse cursor hovers over the decrement button.
+		</theme_item>
+		<theme_item name="decrement_pressed" data_type="icon" type="Texture2D">
+			Displayed when the decrement button is being pressed.
+		</theme_item>
+		<theme_item name="increment" data_type="icon" type="Texture2D">
+			Icon used as a button to scroll the [ScrollBar] right/down. Supports custom step using the [member ScrollBar.custom_step] property.
+		</theme_item>
+		<theme_item name="increment_highlight" data_type="icon" type="Texture2D">
+			Displayed when the mouse cursor hovers over the increment button.
+		</theme_item>
+		<theme_item name="increment_pressed" data_type="icon" type="Texture2D">
+			Displayed when the increment button is being pressed.
+		</theme_item>
+		<theme_item name="grabber" data_type="style" type="StyleBox">
+			Used as texture for the grabber, the draggable element representing current scroll.
+		</theme_item>
+		<theme_item name="grabber_highlight" data_type="style" type="StyleBox">
+			Used when the mouse hovers over the grabber.
+		</theme_item>
+		<theme_item name="grabber_pressed" data_type="style" type="StyleBox">
+			Used when the grabber is being dragged.
+		</theme_item>
+		<theme_item name="hscroll" data_type="style" type="StyleBox">
+		</theme_item>
+		<theme_item name="scroll" data_type="style" type="StyleBox">
+			Used as background of this [ScrollBar].
+		</theme_item>
+		<theme_item name="scroll_focus" data_type="style" type="StyleBox">
+			Used as background when the [ScrollBar] has the GUI focus.
+		</theme_item>
+	</theme_items>
 </class>
 </class>

+ 8 - 0
doc/classes/Separator.xml

@@ -8,4 +8,12 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
+	<theme_items>
+		<theme_item name="separation" data_type="constant" type="int" default="0">
+			The size of the area covered by the separator. Effectively works like a minimum width/height.
+		</theme_item>
+		<theme_item name="separator" data_type="style" type="StyleBox">
+			The style for the separator line. Works best with [StyleBoxLine] (remember to enable [member StyleBoxLine.vertical] for [VSeparator]).
+		</theme_item>
+	</theme_items>
 </class>
 </class>

+ 29 - 0
doc/classes/Slider.xml

@@ -37,4 +37,33 @@
 			</description>
 			</description>
 		</signal>
 		</signal>
 	</signals>
 	</signals>
+	<theme_items>
+		<theme_item name="center_grabber" data_type="constant" type="int" default="0">
+			Boolean constant. If [code]1[/code], the grabber texture size will be ignored and it will fit within slider's bounds based only on its center position.
+		</theme_item>
+		<theme_item name="grabber_offset" data_type="constant" type="int" default="0">
+			Vertical/horizontal offset of the grabber.
+		</theme_item>
+		<theme_item name="grabber" data_type="icon" type="Texture2D">
+			The texture for the grabber (the draggable element).
+		</theme_item>
+		<theme_item name="grabber_disabled" data_type="icon" type="Texture2D">
+			The texture for the grabber when it's disabled.
+		</theme_item>
+		<theme_item name="grabber_highlight" data_type="icon" type="Texture2D">
+			The texture for the grabber when it's focused.
+		</theme_item>
+		<theme_item name="tick" data_type="icon" type="Texture2D">
+			The texture for the ticks, visible when [member Slider.tick_count] is greater than 0.
+		</theme_item>
+		<theme_item name="grabber_area" data_type="style" type="StyleBox">
+			The background of the area to the left/bottom of the grabber.
+		</theme_item>
+		<theme_item name="grabber_area_highlight" data_type="style" type="StyleBox">
+			The background of the area to the left/bottom of the grabber that displays when it's being hovered or focused.
+		</theme_item>
+		<theme_item name="slider" data_type="style" type="StyleBox">
+			The background for the whole slider. Determines the height/width of the [code]grabber_area[/code].
+		</theme_item>
+	</theme_items>
 </class>
 </class>

+ 3 - 0
doc/classes/SplitContainer.xml

@@ -61,6 +61,9 @@
 		<theme_item name="separation" data_type="constant" type="int" default="12">
 		<theme_item name="separation" data_type="constant" type="int" default="12">
 			The space between sides of the container.
 			The space between sides of the container.
 		</theme_item>
 		</theme_item>
+		<theme_item name="grabber" data_type="icon" type="Texture2D">
+			The icon used for the grabber drawn in the middle area.
+		</theme_item>
 		<theme_item name="h_grabber" data_type="icon" type="Texture2D">
 		<theme_item name="h_grabber" data_type="icon" type="Texture2D">
 			The icon used for the grabber drawn in the middle area when [member vertical] is [code]false[/code].
 			The icon used for the grabber drawn in the middle area when [member vertical] is [code]false[/code].
 		</theme_item>
 		</theme_item>

+ 0 - 5
doc/classes/VBoxContainer.xml

@@ -10,9 +10,4 @@
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="3D Voxel Demo">https://godotengine.org/asset-library/asset/676</link>
 		<link title="3D Voxel Demo">https://godotengine.org/asset-library/asset/676</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="separation" data_type="constant" type="int" default="4">
-			The vertical space between the [VBoxContainer]'s elements.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 8
doc/classes/VFlowContainer.xml

@@ -9,12 +9,4 @@
 	<tutorials>
 	<tutorials>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="h_separation" data_type="constant" type="int" default="4">
-			The horizontal separation of children nodes.
-		</theme_item>
-		<theme_item name="v_separation" data_type="constant" type="int" default="4">
-			The vertical separation of children nodes.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 35
doc/classes/VScrollBar.xml

@@ -12,39 +12,4 @@
 		<member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="0" />
 		<member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="0" />
 		<member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="1" />
 		<member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="1" />
 	</members>
 	</members>
-	<theme_items>
-		<theme_item name="decrement" data_type="icon" type="Texture2D">
-			Icon used as a button to scroll the [ScrollBar] up. Supports custom step using the [member ScrollBar.custom_step] property.
-		</theme_item>
-		<theme_item name="decrement_highlight" data_type="icon" type="Texture2D">
-			Displayed when the mouse cursor hovers over the decrement button.
-		</theme_item>
-		<theme_item name="decrement_pressed" data_type="icon" type="Texture2D">
-			Displayed when the decrement button is being pressed.
-		</theme_item>
-		<theme_item name="increment" data_type="icon" type="Texture2D">
-			Icon used as a button to scroll the [ScrollBar] down. Supports custom step using the [member ScrollBar.custom_step] property.
-		</theme_item>
-		<theme_item name="increment_highlight" data_type="icon" type="Texture2D">
-			Displayed when the mouse cursor hovers over the increment button.
-		</theme_item>
-		<theme_item name="increment_pressed" data_type="icon" type="Texture2D">
-			Displayed when the increment button is being pressed.
-		</theme_item>
-		<theme_item name="grabber" data_type="style" type="StyleBox">
-			Used as texture for the grabber, the draggable element representing current scroll.
-		</theme_item>
-		<theme_item name="grabber_highlight" data_type="style" type="StyleBox">
-			Used when the mouse hovers over the grabber.
-		</theme_item>
-		<theme_item name="grabber_pressed" data_type="style" type="StyleBox">
-			Used when the grabber is being dragged.
-		</theme_item>
-		<theme_item name="scroll" data_type="style" type="StyleBox">
-			Used as background of this [ScrollBar].
-		</theme_item>
-		<theme_item name="scroll_focus" data_type="style" type="StyleBox">
-			Used as background when the [ScrollBar] has the GUI focus.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 8
doc/classes/VSeparator.xml

@@ -8,12 +8,4 @@
 	</description>
 	</description>
 	<tutorials>
 	<tutorials>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="separation" data_type="constant" type="int" default="4">
-			The width of the area covered by the separator. Effectively works like a minimum width.
-		</theme_item>
-		<theme_item name="separator" data_type="style" type="StyleBox">
-			The style for the separator line. Works best with [StyleBoxLine] (remember to enable [member StyleBoxLine.vertical]).
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 29
doc/classes/VSlider.xml

@@ -12,33 +12,4 @@
 		<member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="0" />
 		<member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="0" />
 		<member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="1" />
 		<member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" is_bitfield="true" default="1" />
 	</members>
 	</members>
-	<theme_items>
-		<theme_item name="center_grabber" data_type="constant" type="int" default="0">
-			Boolean constant. If [code]1[/code], the grabber texture size will be ignored and it will fit within slider's bounds based only on its center position.
-		</theme_item>
-		<theme_item name="grabber_offset" data_type="constant" type="int" default="0">
-			Horizontal offset of the grabber.
-		</theme_item>
-		<theme_item name="grabber" data_type="icon" type="Texture2D">
-			The texture for the grabber (the draggable element).
-		</theme_item>
-		<theme_item name="grabber_disabled" data_type="icon" type="Texture2D">
-			The texture for the grabber when it's disabled.
-		</theme_item>
-		<theme_item name="grabber_highlight" data_type="icon" type="Texture2D">
-			The texture for the grabber when it's focused.
-		</theme_item>
-		<theme_item name="tick" data_type="icon" type="Texture2D">
-			The texture for the ticks, visible when [member Slider.tick_count] is greater than 0.
-		</theme_item>
-		<theme_item name="grabber_area" data_type="style" type="StyleBox">
-			The background of the area below the grabber.
-		</theme_item>
-		<theme_item name="grabber_area_highlight" data_type="style" type="StyleBox">
-			The background of the area below the grabber that displays when it's being hovered or focused.
-		</theme_item>
-		<theme_item name="slider" data_type="style" type="StyleBox">
-			The background for the whole slider. Determines the width of the [code]grabber_area[/code].
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 0 - 14
doc/classes/VSplitContainer.xml

@@ -9,18 +9,4 @@
 	<tutorials>
 	<tutorials>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 		<link title="Using Containers">$DOCS_URL/tutorials/ui/gui_containers.html</link>
 	</tutorials>
 	</tutorials>
-	<theme_items>
-		<theme_item name="autohide" data_type="constant" type="int" default="1">
-			Boolean value. If 1 ([code]true[/code]), the grabber will hide automatically when it isn't under the cursor. If 0 ([code]false[/code]), it's always visible.
-		</theme_item>
-		<theme_item name="minimum_grab_thickness" data_type="constant" type="int" default="6">
-			The minimum thickness of the area users can click on to grab the splitting line. If [theme_item separation] or [theme_item grabber]'s thickness are too small, this ensure that the splitting line can still be dragged.
-		</theme_item>
-		<theme_item name="separation" data_type="constant" type="int" default="12">
-			The space between sides of the container.
-		</theme_item>
-		<theme_item name="grabber" data_type="icon" type="Texture2D">
-			The icon used for the grabber drawn in the middle area.
-		</theme_item>
-	</theme_items>
 </class>
 </class>

+ 37 - 56
editor/doc_tools.cpp

@@ -624,66 +624,47 @@ void DocTools::generate(bool p_basic_types) {
 
 
 			// Theme items.
 			// Theme items.
 			{
 			{
-				List<StringName> l;
+				List<ThemeDB::ThemeItemBind> theme_items;
+				ThemeDB::get_singleton()->get_class_own_items(cname, &theme_items);
+				Ref<Theme> default_theme = ThemeDB::get_singleton()->get_default_theme();
 
 
-				ThemeDB::get_singleton()->get_default_theme()->get_color_list(cname, &l);
-				for (const StringName &E : l) {
+				for (const ThemeDB::ThemeItemBind &theme_item : theme_items) {
 					DocData::ThemeItemDoc tid;
 					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "Color";
-					tid.data_type = "color";
-					tid.default_value = DocData::get_default_value_string(ThemeDB::get_singleton()->get_default_theme()->get_color(E, cname));
-					c.theme_properties.push_back(tid);
-				}
-
-				l.clear();
-				ThemeDB::get_singleton()->get_default_theme()->get_constant_list(cname, &l);
-				for (const StringName &E : l) {
-					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "int";
-					tid.data_type = "constant";
-					tid.default_value = itos(ThemeDB::get_singleton()->get_default_theme()->get_constant(E, cname));
-					c.theme_properties.push_back(tid);
-				}
-
-				l.clear();
-				ThemeDB::get_singleton()->get_default_theme()->get_font_list(cname, &l);
-				for (const StringName &E : l) {
-					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "Font";
-					tid.data_type = "font";
-					c.theme_properties.push_back(tid);
-				}
-
-				l.clear();
-				ThemeDB::get_singleton()->get_default_theme()->get_font_size_list(cname, &l);
-				for (const StringName &E : l) {
-					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "int";
-					tid.data_type = "font_size";
-					c.theme_properties.push_back(tid);
-				}
+					tid.name = theme_item.item_name;
+
+					switch (theme_item.data_type) {
+						case Theme::DATA_TYPE_COLOR:
+							tid.type = "Color";
+							tid.data_type = "color";
+							break;
+						case Theme::DATA_TYPE_CONSTANT:
+							tid.type = "int";
+							tid.data_type = "constant";
+							break;
+						case Theme::DATA_TYPE_FONT:
+							tid.type = "Font";
+							tid.data_type = "font";
+							break;
+						case Theme::DATA_TYPE_FONT_SIZE:
+							tid.type = "int";
+							tid.data_type = "font_size";
+							break;
+						case Theme::DATA_TYPE_ICON:
+							tid.type = "Texture2D";
+							tid.data_type = "icon";
+							break;
+						case Theme::DATA_TYPE_STYLEBOX:
+							tid.type = "StyleBox";
+							tid.data_type = "style";
+							break;
+						case Theme::DATA_TYPE_MAX:
+							break; // Can't happen, but silences warning.
+					}
 
 
-				l.clear();
-				ThemeDB::get_singleton()->get_default_theme()->get_icon_list(cname, &l);
-				for (const StringName &E : l) {
-					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "Texture2D";
-					tid.data_type = "icon";
-					c.theme_properties.push_back(tid);
-				}
+					if (theme_item.data_type == Theme::DATA_TYPE_COLOR || theme_item.data_type == Theme::DATA_TYPE_CONSTANT) {
+						tid.default_value = DocData::get_default_value_string(default_theme->get_theme_item(theme_item.data_type, theme_item.item_name, cname));
+					}
 
 
-				l.clear();
-				ThemeDB::get_singleton()->get_default_theme()->get_stylebox_list(cname, &l);
-				for (const StringName &E : l) {
-					DocData::ThemeItemDoc tid;
-					tid.name = E;
-					tid.type = "StyleBox";
-					tid.data_type = "style";
 					c.theme_properties.push_back(tid);
 					c.theme_properties.push_back(tid);
 				}
 				}
 
 

+ 0 - 2
editor/editor_themes.cpp

@@ -1129,7 +1129,6 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) {
 	theme->set_stylebox("normal", "MenuBar", style_widget);
 	theme->set_stylebox("normal", "MenuBar", style_widget);
 	theme->set_stylebox("hover", "MenuBar", style_widget_hover);
 	theme->set_stylebox("hover", "MenuBar", style_widget_hover);
 	theme->set_stylebox("pressed", "MenuBar", style_widget_pressed);
 	theme->set_stylebox("pressed", "MenuBar", style_widget_pressed);
-	theme->set_stylebox("focus", "MenuBar", style_widget_focus);
 	theme->set_stylebox("disabled", "MenuBar", style_widget_disabled);
 	theme->set_stylebox("disabled", "MenuBar", style_widget_disabled);
 
 
 	theme->set_color("font_color", "MenuBar", font_color);
 	theme->set_color("font_color", "MenuBar", font_color);
@@ -2329,7 +2328,6 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) {
 	theme->set_color("completion_existing_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_existing_color"));
 	theme->set_color("completion_existing_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_existing_color"));
 	theme->set_color("completion_scroll_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_scroll_color"));
 	theme->set_color("completion_scroll_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_scroll_color"));
 	theme->set_color("completion_scroll_hovered_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_scroll_hovered_color"));
 	theme->set_color("completion_scroll_hovered_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_scroll_hovered_color"));
-	theme->set_color("completion_font_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/completion_font_color"));
 	theme->set_color("font_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/text_color"));
 	theme->set_color("font_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/text_color"));
 	theme->set_color("line_number_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/line_number_color"));
 	theme->set_color("line_number_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/line_number_color"));
 	theme->set_color("caret_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/caret_color"));
 	theme->set_color("caret_color", "CodeEdit", EDITOR_GET("text_editor/theme/highlighting/caret_color"));

+ 0 - 6
scene/theme/default_theme.cpp

@@ -191,7 +191,6 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
 	theme->set_stylebox("hover", "MenuBar", button_hover);
 	theme->set_stylebox("hover", "MenuBar", button_hover);
 	theme->set_stylebox("pressed", "MenuBar", button_pressed);
 	theme->set_stylebox("pressed", "MenuBar", button_pressed);
 	theme->set_stylebox("disabled", "MenuBar", button_disabled);
 	theme->set_stylebox("disabled", "MenuBar", button_disabled);
-	theme->set_stylebox("focus", "MenuBar", focus);
 
 
 	theme->set_font("font", "MenuBar", Ref<Font>());
 	theme->set_font("font", "MenuBar", Ref<Font>());
 	theme->set_font_size("font_size", "MenuBar", -1);
 	theme->set_font_size("font_size", "MenuBar", -1);
@@ -451,7 +450,6 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
 	theme->set_font_size("font_size", "ProgressBar", -1);
 	theme->set_font_size("font_size", "ProgressBar", -1);
 
 
 	theme->set_color("font_color", "ProgressBar", control_font_hover_color);
 	theme->set_color("font_color", "ProgressBar", control_font_hover_color);
-	theme->set_color("font_shadow_color", "ProgressBar", Color(0, 0, 0));
 	theme->set_color("font_outline_color", "ProgressBar", Color(1, 1, 1));
 	theme->set_color("font_outline_color", "ProgressBar", Color(1, 1, 1));
 
 
 	theme->set_constant("outline_size", "ProgressBar", 0);
 	theme->set_constant("outline_size", "ProgressBar", 0);
@@ -513,7 +511,6 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
 	theme->set_color("completion_existing_color", "CodeEdit", Color(0.87, 0.87, 0.87, 0.13));
 	theme->set_color("completion_existing_color", "CodeEdit", Color(0.87, 0.87, 0.87, 0.13));
 	theme->set_color("completion_scroll_color", "CodeEdit", control_font_pressed_color * Color(1, 1, 1, 0.29));
 	theme->set_color("completion_scroll_color", "CodeEdit", control_font_pressed_color * Color(1, 1, 1, 0.29));
 	theme->set_color("completion_scroll_hovered_color", "CodeEdit", control_font_pressed_color * Color(1, 1, 1, 0.4));
 	theme->set_color("completion_scroll_hovered_color", "CodeEdit", control_font_pressed_color * Color(1, 1, 1, 0.4));
-	theme->set_color("completion_font_color", "CodeEdit", Color(0.67, 0.67, 0.67));
 	theme->set_color("font_color", "CodeEdit", control_font_color);
 	theme->set_color("font_color", "CodeEdit", control_font_color);
 	theme->set_color("font_selected_color", "CodeEdit", Color(0, 0, 0, 0));
 	theme->set_color("font_selected_color", "CodeEdit", Color(0, 0, 0, 0));
 	theme->set_color("font_readonly_color", "CodeEdit", Color(control_font_color.r, control_font_color.g, control_font_color.b, 0.5f));
 	theme->set_color("font_readonly_color", "CodeEdit", Color(control_font_color.r, control_font_color.g, control_font_color.b, 0.5f));
@@ -680,11 +677,8 @@ void fill_default_theme(Ref<Theme> &theme, const Ref<Font> &default_font, const
 	Ref<StyleBoxFlat> style_popup_panel = make_flat_stylebox(style_popup_color);
 	Ref<StyleBoxFlat> style_popup_panel = make_flat_stylebox(style_popup_color);
 	style_popup_panel->set_border_width_all(2);
 	style_popup_panel->set_border_width_all(2);
 	style_popup_panel->set_border_color(style_popup_border_color);
 	style_popup_panel->set_border_color(style_popup_border_color);
-	Ref<StyleBoxFlat> style_popup_panel_disabled = style_popup_panel->duplicate();
-	style_popup_panel_disabled->set_bg_color(style_disabled_color);
 
 
 	theme->set_stylebox("panel", "PopupMenu", style_popup_panel);
 	theme->set_stylebox("panel", "PopupMenu", style_popup_panel);
-	theme->set_stylebox("panel_disabled", "PopupMenu", style_popup_panel_disabled);
 	theme->set_stylebox("hover", "PopupMenu", make_flat_stylebox(style_popup_hover_color));
 	theme->set_stylebox("hover", "PopupMenu", make_flat_stylebox(style_popup_hover_color));
 	theme->set_stylebox("separator", "PopupMenu", separator_horizontal);
 	theme->set_stylebox("separator", "PopupMenu", separator_horizontal);
 	theme->set_stylebox("labeled_separator_left", "PopupMenu", separator_horizontal);
 	theme->set_stylebox("labeled_separator_left", "PopupMenu", separator_horizontal);

+ 31 - 3
scene/theme/theme_db.cpp

@@ -38,7 +38,6 @@
 #include "scene/resources/font.h"
 #include "scene/resources/font.h"
 #include "scene/resources/style_box.h"
 #include "scene/resources/style_box.h"
 #include "scene/resources/texture.h"
 #include "scene/resources/texture.h"
-#include "scene/resources/theme.h"
 #include "scene/theme/default_theme.h"
 #include "scene/theme/default_theme.h"
 #include "servers/text_server.h"
 #include "servers/text_server.h"
 
 
@@ -328,10 +327,11 @@ ThemeContext *ThemeDB::get_nearest_theme_context(Node *p_for_node) const {
 
 
 // Theme item binding.
 // Theme item binding.
 
 
-void ThemeDB::bind_class_item(const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, ThemeItemSetter p_setter) {
+void ThemeDB::bind_class_item(Theme::DataType p_data_type, const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, ThemeItemSetter p_setter) {
 	ERR_FAIL_COND_MSG(theme_item_binds[p_class_name].has(p_prop_name), vformat("Failed to bind theme item '%s' in class '%s': already bound", p_prop_name, p_class_name));
 	ERR_FAIL_COND_MSG(theme_item_binds[p_class_name].has(p_prop_name), vformat("Failed to bind theme item '%s' in class '%s': already bound", p_prop_name, p_class_name));
 
 
 	ThemeItemBind bind;
 	ThemeItemBind bind;
+	bind.data_type = p_data_type;
 	bind.class_name = p_class_name;
 	bind.class_name = p_class_name;
 	bind.item_name = p_item_name;
 	bind.item_name = p_item_name;
 	bind.setter = p_setter;
 	bind.setter = p_setter;
@@ -339,10 +339,11 @@ void ThemeDB::bind_class_item(const StringName &p_class_name, const StringName &
 	theme_item_binds[p_class_name][p_prop_name] = bind;
 	theme_item_binds[p_class_name][p_prop_name] = bind;
 }
 }
 
 
-void ThemeDB::bind_class_external_item(const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, const StringName &p_type_name, ThemeItemSetter p_setter) {
+void ThemeDB::bind_class_external_item(Theme::DataType p_data_type, const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, const StringName &p_type_name, ThemeItemSetter p_setter) {
 	ERR_FAIL_COND_MSG(theme_item_binds[p_class_name].has(p_prop_name), vformat("Failed to bind theme item '%s' in class '%s': already bound", p_prop_name, p_class_name));
 	ERR_FAIL_COND_MSG(theme_item_binds[p_class_name].has(p_prop_name), vformat("Failed to bind theme item '%s' in class '%s': already bound", p_prop_name, p_class_name));
 
 
 	ThemeItemBind bind;
 	ThemeItemBind bind;
+	bind.data_type = p_data_type;
 	bind.class_name = p_class_name;
 	bind.class_name = p_class_name;
 	bind.item_name = p_item_name;
 	bind.item_name = p_item_name;
 	bind.type_name = p_type_name;
 	bind.type_name = p_type_name;
@@ -370,6 +371,33 @@ void ThemeDB::update_class_instance_items(Node *p_instance) {
 	}
 	}
 }
 }
 
 
+void ThemeDB::get_class_own_items(const StringName &p_class_name, List<ThemeItemBind> *r_list) {
+	List<StringName> class_hierarchy;
+	StringName class_name = p_class_name;
+	while (class_name != StringName()) {
+		class_hierarchy.push_front(class_name); // Put parent classes in front.
+		class_name = ClassDB::get_parent_class_nocheck(class_name);
+	}
+
+	HashSet<StringName> inherited_props;
+	for (const StringName &theme_type : class_hierarchy) {
+		HashMap<StringName, HashMap<StringName, ThemeItemBind>>::Iterator E = theme_item_binds.find(theme_type);
+		if (E) {
+			for (const KeyValue<StringName, ThemeItemBind> &F : E->value) {
+				if (inherited_props.has(F.value.item_name)) {
+					continue; // Skip inherited properties.
+				}
+				if (F.value.external || F.value.class_name != p_class_name) {
+					inherited_props.insert(F.value.item_name);
+					continue; // Track properties defined in parent classes, and skip them.
+				}
+
+				r_list->push_back(F.value);
+			}
+		}
+	}
+}
+
 // Object methods.
 // Object methods.
 
 
 void ThemeDB::_bind_methods() {
 void ThemeDB::_bind_methods() {

+ 20 - 15
scene/theme/theme_db.h

@@ -33,6 +33,7 @@
 
 
 #include "core/object/class_db.h"
 #include "core/object/class_db.h"
 #include "core/object/ref_counted.h"
 #include "core/object/ref_counted.h"
+#include "scene/resources/theme.h"
 
 
 #include <functional>
 #include <functional>
 
 
@@ -40,31 +41,30 @@ class Font;
 class Node;
 class Node;
 class StyleBox;
 class StyleBox;
 class Texture2D;
 class Texture2D;
-class Theme;
 class ThemeContext;
 class ThemeContext;
 
 
 // Macros for binding theme items of this class. This information is used for the documentation, theme
 // Macros for binding theme items of this class. This information is used for the documentation, theme
 // overrides, etc. This is also the basis for theme cache.
 // overrides, etc. This is also the basis for theme cache.
 
 
-#define BIND_THEME_ITEM(m_data_type, m_class, m_prop)                                                      \
-	ThemeDB::get_singleton()->bind_class_item(get_class_static(), #m_prop, #m_prop, [](Node *p_instance) { \
-		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                            \
-		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(#m_prop));            \
+#define BIND_THEME_ITEM(m_data_type, m_class, m_prop)                                                                   \
+	ThemeDB::get_singleton()->bind_class_item(m_data_type, get_class_static(), #m_prop, #m_prop, [](Node *p_instance) { \
+		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                                         \
+		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(#m_prop));                         \
 	})
 	})
 
 
-#define BIND_THEME_ITEM_CUSTOM(m_data_type, m_class, m_prop, m_item_name)                                      \
-	ThemeDB::get_singleton()->bind_class_item(get_class_static(), #m_prop, m_item_name, [](Node *p_instance) { \
-		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                                \
-		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(m_item_name));            \
+#define BIND_THEME_ITEM_CUSTOM(m_data_type, m_class, m_prop, m_item_name)                                                   \
+	ThemeDB::get_singleton()->bind_class_item(m_data_type, get_class_static(), #m_prop, m_item_name, [](Node *p_instance) { \
+		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                                             \
+		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(m_item_name));                         \
 	})
 	})
 
 
 // Macro for binding theme items used by this class, but defined/binded by other classes. This is primarily used for
 // Macro for binding theme items used by this class, but defined/binded by other classes. This is primarily used for
 // the theme cache. Can also be used to list such items in documentation.
 // the theme cache. Can also be used to list such items in documentation.
 
 
-#define BIND_THEME_ITEM_EXT(m_data_type, m_class, m_prop, m_item_name, m_type_name)                                                  \
-	ThemeDB::get_singleton()->bind_class_external_item(get_class_static(), #m_prop, m_item_name, m_type_name, [](Node *p_instance) { \
-		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                                                      \
-		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(m_item_name), _scs_create(m_type_name));        \
+#define BIND_THEME_ITEM_EXT(m_data_type, m_class, m_prop, m_item_name, m_type_name)                                                               \
+	ThemeDB::get_singleton()->bind_class_external_item(m_data_type, get_class_static(), #m_prop, m_item_name, m_type_name, [](Node *p_instance) { \
+		m_class *p_cast = Object::cast_to<m_class>(p_instance);                                                                                   \
+		p_cast->theme_cache.m_prop = p_cast->get_theme_item(m_data_type, _scs_create(m_item_name), _scs_create(m_type_name));                     \
 	})
 	})
 
 
 class ThemeDB : public Object {
 class ThemeDB : public Object {
@@ -96,9 +96,11 @@ class ThemeDB : public Object {
 
 
 	// Binding of theme items to Node classes.
 	// Binding of theme items to Node classes.
 
 
+public:
 	typedef std::function<void(Node *)> ThemeItemSetter;
 	typedef std::function<void(Node *)> ThemeItemSetter;
 
 
 	struct ThemeItemBind {
 	struct ThemeItemBind {
+		Theme::DataType data_type;
 		StringName class_name;
 		StringName class_name;
 		StringName item_name;
 		StringName item_name;
 		StringName type_name;
 		StringName type_name;
@@ -107,6 +109,7 @@ class ThemeDB : public Object {
 		ThemeItemSetter setter;
 		ThemeItemSetter setter;
 	};
 	};
 
 
+private:
 	HashMap<StringName, HashMap<StringName, ThemeItemBind>> theme_item_binds;
 	HashMap<StringName, HashMap<StringName, ThemeItemBind>> theme_item_binds;
 
 
 protected:
 protected:
@@ -155,10 +158,12 @@ public:
 
 
 	// Theme item binding.
 	// Theme item binding.
 
 
-	void bind_class_item(const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, ThemeItemSetter p_setter);
-	void bind_class_external_item(const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, const StringName &p_type_name, ThemeItemSetter p_setter);
+	void bind_class_item(Theme::DataType p_data_type, const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, ThemeItemSetter p_setter);
+	void bind_class_external_item(Theme::DataType p_data_type, const StringName &p_class_name, const StringName &p_prop_name, const StringName &p_item_name, const StringName &p_type_name, ThemeItemSetter p_setter);
 	void update_class_instance_items(Node *p_instance);
 	void update_class_instance_items(Node *p_instance);
 
 
+	void get_class_own_items(const StringName &p_class_name, List<ThemeItemBind> *r_list);
+
 	// Memory management, reference, and initialization.
 	// Memory management, reference, and initialization.
 
 
 	static ThemeDB *get_singleton();
 	static ThemeDB *get_singleton();