Garry's Mod Wiki

draw.Text

number, number draw.Text( table textdata )

Description

Works like draw.SimpleText but uses a table structure instead.

This is a rendering function that requires a 2d rendering context.

This means that it will only work in 2d Rendering Hooks.

Arguments

1 table textdata
The text properties. See the Structures/TextData

Returns

1 number
Width of drawn text
2 number
Height of drawn text

Example

Example usage

hook.Add( "HUDPaint", "drawTextExample", function() draw.Text( { text = "test", pos = { 50, 50 } } ) end )

Page Links


Special Pages


Wikis

?

Render Time: 37ms

DB GetPage 3
Generate Html 12
SaveChanges (1) 8
Render Body 0
Render Sidebar 11