Label

From Garry's Mod
Jump to: navigation, search
 Label( )

Contents

Description

Convenience function that creates a DLabel, sets the text, and returns it

Arguments

string text

The string to set the label's text to

Arguments

Panel parent=nil

Optional. The panel to parent the DLabel to

Returns

Panel

The created DLabel

Examples

Example

Create a label

local lbl = Label( "The quick brown fox" )


Examples

Example

Create a label and parents it to a DPanel

local pnl = vgui.Create("DPanel")
local lbl = Label( "The quick brown fox", pnl )


Personal tools
Navigation