DPropertySheet
Description
A tab oriented control where you can create multiple tabs with items within. Used mainly for organization.
Parent
Derives methods, etc not listed on this page from Panel.
Events
Called when a player switches the tabs.
Source code states that this is meant to be overridden.
Methods
table DPropertySheet:AddSheet( string name, Panel pnl, string icon = nil, boolean noStretchX = false, boolean noStretchY = false, string tooltip = nil )
Adds a new tab.
Removes tab and/or panel from the parent DPropertySheet.
This is used internally - although you're able to use it you probably shouldn't.
Internal function that handles the cross fade animation when the player switches tabs.
Panel DPropertySheet:GetActiveTab()
Returns the active DTab of this DPropertySheet.
number DPropertySheet:GetFadeTime()
Returns the amount of time (in seconds) it takes to fade between tabs.
Set by DPropertySheet:SetFadeTime
number DPropertySheet:GetPadding()
Gets the padding from the parent panel to child panels.
boolean DPropertySheet:GetShowIcons()
We advise against using this. It may be changed or removed in a future update.
Returns whatever value was set by DPropertySheet:SetShowIcons.
DPropertySheet:SetActiveTab( Panel tab )
Sets the active tab of the DPropertySheet.
DPropertySheet:SetFadeTime( number time = 0.1 )
Sets the amount of time (in seconds) it takes to fade between tabs.
DPropertySheet:SetPadding( number padding = 8 )
Sets the padding from parent panel to children panel.
DPropertySheet:SetShowIcons( boolean show )
We advise against using this. It may be changed or removed in a future update.
Does nothing.
DPropertySheet:SetupCloseButton( function func )
Creates a close button on the right side of the DPropertySheet that will run the given callback function when pressed.
DPropertySheet:SizeToContentWidth()
Sets the width of the DPropertySheet to fit the contents of all of the tabs.
DPropertySheet:SwitchToName( string name )
Switches the active tab to a tab with given name.
Example
Example of how you'd create and use this panel.
Output: