G.DisableClipping

From GMod Wiki

Jump to: navigation, search
Function
Syntax DisableClipping( Boolean should clip )
Where is this used?
Description:
Determines if things should clip when they go off a panel's edge.
Returns: nil
Part of Library: Global Functions
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=G.DisableClipping]G.DisableClipping [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]


Examples

DescriptionDraws a green box outside the panel.
Used onNewerClient.png
Code
function PANEL:Paint()
	DisableClipping(true);
 
	local w, h = self:GetSize();
	draw.RoundedBox(4, w + 32, h + 32, 64, 64, Color(0, 255, 0));
 
	DisableClipping(false);
end
OutputN/A


See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox