OnDgsRender: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ {{Client event}} This event is triggered every time after dgs renders. ==Parameters== ''None'' ==Source== The source of this event i...")
 
m (Thisdp moved page OnClientDgsDxRender to OnDgsRender)
 
(2 intermediate revisions by the same user not shown)
Line 10: Line 10:


==Example==
==Example==
This example shows dx
This example shows that we can draw a rectangle above dgs gui.
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
DGS = exports.dgs
DGS = exports.dgs
edit = DGS:dgsDxCreateEdit(200,200,500,200,"test",false)
edit = DGS:dgsCreateEdit(200,200,500,200,"test",false)


function drawAboveDGS ()
function drawAboveDGS ()
dxDrawRectangle(200,200,500,200,tocolor(0,0,0,200),true) -- POSTGUI is always set to true
dxDrawRectangle(200,200,500,200,tocolor(0,0,0,200),true) -- POSTGUI is always set to true
end
end
addEventHandler ( "onClientDgsDxRender", root, drawAboveDGS )
addEventHandler ( "onDgsRender", root, drawAboveDGS )
 
</syntaxhighlight>
</syntaxhighlight>



Latest revision as of 13:39, 20 January 2018

This event is triggered every time after dgs renders.

Parameters

None

Source

The source of this event is the client's root element.

Example

This example shows that we can draw a rectangle above dgs gui.

DGS = exports.dgs
edit = DGS:dgsCreateEdit(200,200,500,200,"test",false)

function drawAboveDGS ()
	dxDrawRectangle(200,200,500,200,tocolor(0,0,0,200),true) -- POSTGUI is always set to true
end
addEventHandler ( "onDgsRender", root, drawAboveDGS )

See Also

DGS events

General

Check Box

Combo Box

Drag'N Drop

Edit

Grid List

Menu

Selector

Mouse

Radio Button

Switch Button

Tab

Animation

Plugin

Media

Color Picker

QRCode

Remote Image

Client event functions