DTree Node.SetExpanded

From GMod Wiki

Jump to: navigation, search
Function
Syntax DTree_Node:SetExpanded( Boolean Boolean )
Description:
Sets whether or not the node should be expanded (open).
Returns: nil
In Object: DTree_Node
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=DTree Node.SetExpanded]DTree Node.SetExpanded [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionExpands a node after creating it
Used onNewerClient.png
Code
 
	local Dtree = vgui.Create( "DTree" )
	Dtree:SetPadding( 3 )
	Dtree:SetSize( 200, 500 )
 
	local parent = Dtree:AddNode( "Parent node")
	local child = parent:AddNode( "Child node" )
	parent:SetExpanded( true )
 
OutputN/A
Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox