ctrlStyle: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " *\|Problems= * " to " ")
m (Some wiki formatting)
(8 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{RV|type=command
{{RV|type=command


|game1= arma3dev
|game1= arma3
|version1= 2.02


|version1= 2.01
|arg= local
 
|arg=
 
|eff=
 
|serverExec=


|gr1= GUI Control
|gr1= GUI Control


|descr= Returns the provided control's style. See {{HashLink|Arma: GUI Configuration#Control Styles}}.
|descr= Returns the provided control's style. See {{HashLink|Arma: GUI Configuration#Control Styles}}.
|mp= |Multiplayer Behaviour=
|pr=


|s1= [[ctrlStyle]] control
|s1= [[ctrlStyle]] control


|p1= control
|p1= control: [[Control]]


|r1= [[Number]] - see {{HashLink|Arma: GUI Configuration#Control Styles}}
|r1= [[Number]] - see {{HashLink|Arma: GUI Configuration#Control Styles}}


|x1= <code>[[private]] _ctrlStyle = [[ctrlStyle]] _myControl;
|x1= <sqf>
private _ctrlStyle = ctrlStyle _myControl;


[[private]] _bitFlags = _ctrlStyle [[call]] [[BIS_fnc_bitflagsToArray]];
private _bitFlags = _ctrlStyle call BIS_fnc_bitflagsToArray;
[[if]] (2 [[in]] _bitFlags) [[then]]
if (2 in _bitFlags) then
{
{
[[hint]] "This control has centered text!";
hint "This control has centered text!";
};
};
</code>
</sqf>


|seealso= [[ctrlType]] [[BIS_fnc_bitflagsToArray]]
|seealso= [[ctrlType]] [[BIS_fnc_bitflagsToArray]]
}}
}}

Revision as of 14:40, 5 May 2022

Hover & click on the images for description

Description

Description:
Returns the provided control's style. See Arma: GUI Configuration - Control Styles.
Groups:
GUI Control

Syntax

Syntax:
ctrlStyle control
Parameters:
control: Control
Return Value:
Number - see Arma: GUI Configuration - Control Styles

Examples

Example 1:
private _ctrlStyle = ctrlStyle _myControl; private _bitFlags = _ctrlStyle call BIS_fnc_bitflagsToArray; if (2 in _bitFlags) then { hint "This control has centered text!"; };

Additional Information

See also:
ctrlType BIS_fnc_bitflagsToArray

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note