From 5b10422fba809457e381edf8d0f659793a4760fc Mon Sep 17 00:00:00 2001 From: Will Nations Date: Fri, 20 Oct 2017 23:31:45 -0500 Subject: [PATCH] updated the TabContainer docs for depth and readability. --- doc/classes/TabContainer.xml | 44 ++++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 19 deletions(-) diff --git a/doc/classes/TabContainer.xml b/doc/classes/TabContainer.xml index ad02064862..0d5db80086 100644 --- a/doc/classes/TabContainer.xml +++ b/doc/classes/TabContainer.xml @@ -4,8 +4,10 @@ Tabbed Container. - Tabbed Container. Contains several children controls, but shows only one at the same time. Clicking on the top tabs allows to change the currently visible one. - Children controls of this one automatically. + Sets the active tab's [code]visible[/code] property to the value [code]true[/code]. Sets all other children's to [code]false[/code]. + Ignores non-[class Control] children. + Individual tabs are always visible unless you use [method set_tab_disabled] and [method set_tab_title] to hide it. + To hide only a tab's content, nest the content inside a child [class Control], so it receives the [class TabContainer]'s visibility setting instead. @@ -23,33 +25,35 @@ - Returns the current tab index that is being shown. + Returns the currently visible tab's index. + Returns the child [class Control] node located at the active tab index. + Returns the [class Popup] node instance if one has been set already with [method set_popup]. - Returns the previous tab index that was being shown. + Returns the previously active tab index. - Returns the tab alignment.See the ALIGN_* constants. + Returns the tab alignment. See the [code]ALIGN_*[/code] constants. @@ -58,14 +62,14 @@ - Returns the current tab control that is being shown. + Returns the currently visible tab's [class Control] node. - Returns the amount of tabs. + Returns the number of tabs. @@ -92,7 +96,7 @@ - Returns the title for the tab at index [code]tab_idx[/code]. Tab titles are by default the children node name, but this can be overridden. + Returns the title of the tab at index [code]tab_idx[/code]. Tab titles default to the name of the indexed child node, but this can be overridden with [method set_tab_title]. @@ -101,7 +105,7 @@ - Bring a tab (and the Control it represents) to the front, and hide the rest. + Sets to [code]false[/code] the [code]visible[/code] property for all [class Control] children except for the tab at [code]tab_idx[/code]. @@ -110,6 +114,7 @@ + If set on a [class Popup] node instance, a popup menu icon appears in the top-right corner of the [class TabContainer]. Clicking it will expand the [class Popup] node. @@ -118,7 +123,7 @@ - Set tab alignment, from the ALIGN_* enum. Moves tabs to the left, right or center. + Sets tab alignment, from the [code]ALIGN_*[/code] constants. Moves tabs to the left, right, or center. @@ -129,7 +134,7 @@ - Set tab at index [code]tab_idx[/code] disabled. + If [code]disabled[/code] is false, hides the tab at index [code]tab_idx[/code]. Note that its title text will remain, unless also removed with [method set_tab_title]. @@ -140,7 +145,7 @@ - Set an icon for a tab at index [code]tab_idx[/code]. + Sets an icon for the tab at index [code]tab_idx[/code]. @@ -151,7 +156,7 @@ - Set a title for the tab at index [code]tab_idx[/code]. Tab titles are by default the children node name, but this can be overridden. + Sets a title for the tab at index [code]tab_idx[/code]. Tab titles default to the name of the indexed child node, but this can be overridden with [method set_tab_title]. @@ -160,38 +165,39 @@ - If [code]true[/code] all the tabs will be visible. + If [code]true[/code] tabs are visible. If [code]false[/code] tabs' content and titles are hidden. Default value: [code]true[/code]. - The current tab. + The current tab index. When set, this index's [class Control] node's [code]visible[/code] property is set to [code]true[/code] and all others are set to [code]false[/code]. - The alignment of all the tabs of the tab container. See the [code]ALIGN_*[/code] constants. + The alignment of all tabs in the tab container. See the [code]ALIGN_*[/code] constants for details. - If [code]true[/code] all tabs that are children of the TabContainer will be visible. + If [code]true[/code] tabs are visible. If [code]false[/code] tabs' content and titles are hidden. Default value: [code]true[/code]. + Emitted when the [class TabContainer]'s [class Popup] button is clicked. See [method set_popup] for details. - Emitted only when the current tab changes. + Emitted when switching to another tab. - Emitted when a tab is being selected, even if it is the same tab. + Emitted when a tab is selected, even if it is the current tab.