derma.DefineControl

From GMod Wiki

Jump to: navigation, search
Function
Syntax derma.DefineControl( String Name, String Description, Table Panel setup, String Base )
Where is this used?
Description:
Creates a new Derma control derived from base control
Returns: Panel new control
Part of Library: Derma
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Derma.DefineControl]Derma.DefineControl [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]


Examples

DescriptionCreates the DButton derived from the DLabel (from addons/derma/lua/vgui/DButton.lua)
Used onNewerClient.png
Code
local PANEL = derma.DefineControl( "DButton", "A standard Button", PANEL, "DLabel" )
OutputPANEL assigned to newly made control
Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox