SetDebugViewActive: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "{{Client function}} __NOTOC__ This function enables or disables the debug window. ==Syntax== <syntaxhighlight lang="lua"> bool setDebugViewActive ( bool enabled ) </syntaxhi...")
 
 
(2 intermediate revisions by 2 users not shown)
Line 6: Line 6:
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
bool setDebugViewActive ( bool enabled )
bool setDebugViewActive ( bool enabled )
</syntaxhighlight>  
</syntaxhighlight>
{{OOP||[[GUI widgets|GuiElement]].setDebugViewActive|debugViewActive|isDebugViewActive}}


===Required Arguments===
===Required Arguments===
Line 18: Line 19:
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
function enableDebug()
function enableDebug()
local state = not isDebugViewEnabled()
local state = not isDebugViewActive()
setDebugViewActive(state)
setDebugViewActive(state)
end
end
Line 26: Line 27:
==See Also==
==See Also==
{{GUI_functions}}
{{GUI_functions}}
{{GUI_events}}

Latest revision as of 17:22, 21 November 2018

This function enables or disables the debug window.

Syntax

bool setDebugViewActive ( bool enabled )

OOP Syntax Help! I don't understand this!

Method: GuiElement.setDebugViewActive(...)
Variable: .debugViewActive
Counterpart: isDebugViewActive


Required Arguments

  • enabled: true if debug window should be visible, false otherwise.

Returns

Returns true, false if invalid parameters are passed.

Example

This example enables or disables the debug window.

function enableDebug()
	local state = not isDebugViewActive()
	setDebugViewActive(state)
end
addCommandHandler("debug", enableDebug)

See Also

General functions

Browsers

Buttons

Checkboxes

Comboboxes

Edit Boxes

Gridlists

Memos

Progressbars

Radio Buttons

Scrollbars

Scrollpanes

Static Images

Tab Panels

Tabs

Text Labels

Windows

Input

GUI