DSysButton

From GMod Wiki

Jump to: navigation, search
Warning 64 severe.pngThis element is being removed from garrysmod once the GMod Beta 13 update becomes public


Derma Control: DSysButton
Parent Class:DButton
Subclasses:DCheckBox
Description:
A button with special icons to indicate the action; used for things like close buttons, scrollbar buttons, etc.

Examples

DescriptionCreates a close button on a panel.
Used onNewerClient.png
Code
// myParent = a Panel based object.
myButton = vgui.Create("DSysButton", myParent)
myButton:SetType( "close" ) // also can be "up" (an up arrow), "down" (a down arrow), and "grip".
myButton.DoClick = function()
        Msg("You clicked the button!\n")
    end
myButton.DoRightClick = function()
        Msg("You right-clicked the button!\n")
    end
 
OutputDSysButton-SetTypeclose.png


Methods

NewerClient.png DSysButton.ApplySchemeSettings
NewerClient.png DSysButton.GetChar
NewerClient.png DSysButton.GetType
NewerClient.png DSysButton.Init
NewerClient.png DSysButton.Paint
NewerClient.png DSysButton.SetChar
NewerClient.png DSysButton.SetType

Inherited from DButton

NewerClient.png DButton.SetDrawBackground
NewerClient.png DButton.GetSelected
NewerClient.png DButton.SetDisabled
NewerClient.png DButton.GetDrawBorder
NewerClient.png DButton.IsDown
NewerClient.png DButton.OnMouseReleased
NewerClient.png DButton.GenerateExample
NewerClient.png DButton.SetConsoleCommand
NewerClient.png DButton.DoRightClick
NewerClient.png DButton.SetSelected
NewerClient.png DButton.GetDrawBackground
NewerClient.png DButton.DoClick
NewerClient.png DButton.GetDisabled
NewerClient.png DButton.SetDrawBorder
NewerClient.png DButton.OnMousePressed

Inherited from DLabel

NewerClient.png DLabel.OnCursorEntered
NewerClient.png DLabel.GetTextColorHovered
NewerClient.png DLabel.SetAutoStretchVertical
NewerClient.png DLabel.GetColor
NewerClient.png DLabel.SetTextColor
NewerClient.png DLabel.GetTextColor
NewerClient.png DLabel.SetTextColorHovered
NewerClient.png DLabel.PerformLayout
NewerClient.png DLabel.GetAutoStretchVertical
NewerClient.png DLabel.OnCursorExited
NewerClient.png DLabel.SetColor

Notes

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox