BIS fnc initListNBoxSorting: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl>" to "") |
Lou Montana (talk | contribs) m (Text replacement - " *\| *([Cc]omments|COMMENTS|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments \("local" or "global"\)|Multiplayer Effects \("local" or "global"\)|Multiplayer Execution \("server" o...) |
||
Line 1: | Line 1: | ||
{{Function | {{Function | ||
| arma3 | | arma3 | ||
|1.56 | |1.56 | ||
|gr1= GUI | |gr1= GUI | ||
| Automatically creates buttons and sets them up so they can be used to sort a [[CT_LISTNBOX]]. The buttons will automatically be resized to the column width of given <tt>controlFilter</tt>. | | Automatically creates buttons and sets them up so they can be used to sort a [[CT_LISTNBOX]]. The buttons will automatically be resized to the column width of given <tt>controlFilter</tt>. | ||
Line 18: | Line 18: | ||
** To keep a uniform style between vanilla controls and custom ones it's advisable to create a background with [[CT_STATIC]] behind the <tt>controlFilter</tt> with </tt>colorBackground[] {{=}} {0,0,0,1};</tt>}} | ** To keep a uniform style between vanilla controls and custom ones it's advisable to create a background with [[CT_STATIC]] behind the <tt>controlFilter</tt> with </tt>colorBackground[] {{=}} {0,0,0,1};</tt>}} | ||
[[Image:A3_BIS_fnc_initListNBoxSorting_example.jpg|400px|thumb|center|Example GUI using this function]] | [[Image:A3_BIS_fnc_initListNBoxSorting_example.jpg|400px|thumb|center|Example GUI using this function]] | ||
| | | [controlFilter, controlContent, columnIndexes, idc] call [[BIS_fnc_initListNBoxSorting]] | ||
| | |p1= controlFilter: [[Control]] - Dummy [[CT_LISTNBOX]] control used for setting up the filter. If parameter is [[controlNull]] function will show an error message. | ||
| | |p2= controlContent: [[Control]] - The [[CT_LISTNBOX]] which actually contains the content. If parameter is [[controlNull]] function will show an error message. | ||
| | |p3= columnIndexes: [[Array]] - Array of [[Number|numbers]]. These are the indexes of the <tt>controlContent</tt> which should be filterable/sortable | ||
| [[ | |p4= idc: [[Number]] - (Optional, default 200) Will be used to assign idcs to the buttons which are automatically created. First button has <tt>idc</tt>, second button <tt>idc + 1</tt> and so on | ||
| | | [[Boolean]] - [[true]] on success, otherwise [[false]] | ||
| [[BIS_fnc_initSliderValue]] | |x1= <code>[_lnbFilter, _lnbContent, [0,1,2,3]] [[call]] [[BIS_fnc_initListNBoxSorting]];</code> | ||
| [[BIS_fnc_initSliderValue]] | |||
}} | }} | ||
Revision as of 23:11, 17 January 2021
Description
- Description:
- Automatically creates buttons and sets them up so they can be used to sort a CT_LISTNBOX. The buttons will automatically be resized to the column width of given controlFilter.
- Execution:
- call
- Groups:
- GUI
Syntax
- Syntax:
- [controlFilter, controlContent, columnIndexes, idc] call BIS_fnc_initListNBoxSorting
- Parameters:
- controlFilter: Control - Dummy CT_LISTNBOX control used for setting up the filter. If parameter is controlNull function will show an error message.
- controlContent: Control - The CT_LISTNBOX which actually contains the content. If parameter is controlNull function will show an error message.
- columnIndexes: Array - Array of numbers. These are the indexes of the controlContent which should be filterable/sortable
- idc: Number - (Optional, default 200) Will be used to assign idcs to the buttons which are automatically created. First button has idc, second button idc + 1 and so on
- Return Value:
- Boolean - true on success, otherwise false
Examples
- Example 1:
[_lnbFilter, _lnbContent, [0,1,2,3]] call BIS_fnc_initListNBoxSorting;
Additional Information
- See also:
- BIS_fnc_initSliderValue
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