- Home
- General Usage
- DCX Controls
- DCX Features
- About DCX
|
List |
Normal listbox control.
|
Control Styles |
These control styles are available when creating a List control. Remember that the general styles disabled, group, hidden, notheme, tabstop and transparent apply to all DCX controls except the embedded Dialog and Window controls. |
alpha |
Control is alpha blended. |
dragline |
Used with draglist, this replaces the standard arrow and draws a line in the list to indicate the drop position. |
draglist |
Allows items in the list to be dragged using the mouse. Cannot be used with multi. |
extsel |
Allows multiple items to be selected. |
hsbar |
Enables the horizontal scrollbar |
multi |
Turns string selection on or off each time the user clicks or double-clicks a string in the list box. The user can select any number of strings. |
multicol |
Allows a multi column list. |
noformat |
Disables support for mIRC codes in control (faster). |
nointegral |
Specifies that the size of the list box is exactly the size specified by the application when it created the list box. Normally, the system sizes a list box so that the list box does not display partial items. |
noscroll |
Shows a disabled vertical scroll bar for the list box when the box does not contain enough items to scroll. If you do not specify this style, the scroll bar is hidden when the list box does not contain enough items. |
nosel |
Specifies that the list box contains items that can be viewed but not selected. |
vsbar |
Specifies that the list box should display a vertical scrollbar when it overflows. |
/xdid flags |
Control commands are input to the control with the /xdid command. |
/xdid -a |
This command lets you add a new item to the listbox. |
Syntax: |
/xdid -a [DNAME] [ID] [N] [Item Text] |
Example: |
/xdid -a dcx 4 0 New Item |
| Note. You can use 0 for N to insert at the end of the listbox. |
/xdid -c |
This command lets you select items in the listbox. |
Syntax: |
/xdid -c [DNAME] [ID] [N(,N,...)] |
Example: |
/xdid -c dcx 4 1,2,3 |
| Note.- In a single line listbox, you only provide the line number to select.
- You can use 0 for N to select the last item.
|
/xdid -d |
This command lets you delete an item in the listbox. |
Syntax: |
/xdid -d [DNAME] [ID] [N] |
Example: |
/xdid -d dcx 4 1 |
| Note. You can use 0 for N to delete the last item. |
/xdid -m |
This command lets you to modify the multicol properties. |
Syntax: |
/xdid -m [DNAME] [ID] [+FLAG] [N](,N,N,...) |
Example: |
/xdid -m dcx 4 +w 150 |
Parameters: |
w |
Sets the width of the colums. N is the width of the column. |
t |
Sets the tabstops within the list. |
-1 |
Resets the tabs to the control default of 2. |
N |
Sets the tabs to a fixed value for each tab. |
N1,N2,... |
Sets the tabs to specific values for each tab. |
| Note. Currently only one tabstop can be set. |
/xdid -o |
This command lets you overwrite an item in the listbox. |
Syntax: |
/xdid -o [DNAME] [ID] [N] [Item Text] |
Example: |
/xdid -o dcx 4 1 New Text |
| Note. You can use 0 for N to overwrite the last item. |
/xdid -r |
This command lets you clear the listbox contents. |
Syntax: |
/xdid -r [DNAME] [ID] |
Example: |
/xdid -r dcx 4 |
/xdid -u |
This command lets you unselect items the listbox. |
Syntax: |
/xdid -u [DNAME] [ID] |
Example: |
/xdid -u dcx 4 |
/xdid -A |
This command lets you add new items to the listbox. |
Syntax: |
/xdid -A [DNAME] [ID] [N] [+FLAG] [ARGS] |
Example: |
/xdid -A dcx 4 0 +t settings |
Parameters: |
N |
The position to insert the new item(s) |
+FLAGS |
New item flags. |
f |
Loads the entire contents of a file into the list. |
H |
Allows you to load an item from a hash table by name. |
n |
Allows you to load an item from a hash table by index. |
t |
Loads entire hashtable into list. |
Variable parameters ARGS: |
f |
[START] [END] [FILENAME] |
START |
The starting index for items to add. Use 0 to ignore. Negative values are treated as an offset from the end of the file. |
END |
The ending index for items to add. Use 0 to ignore. Negative values are treated as an offset from the end of the file. |
H |
[HASHTABLE] [ITEM] |
n |
[HASHTABLE] [INDEX] |
t |
[HASHTABLE] [START] [END] |
START |
The starting index for items to add. Use 0 to ignore. Negative values are treated as an offset from the end of the table. |
END |
The ending index for items to add. Use 0 to ignore. Negative values are treated as an offset from the end of the table. |
No flags |
[TEXT] |
| Note.- You can use 0 for N to insert at the end of the listbox.
- If no FLAG is specified, this behaves exactly like /xdid -a.
|
$xdid() Properties |
The $xdid identifier is a given mIRC alias that communicates with the DCX DLL to extract information in DCX controls. |
$xdid().find |
This property lets you retreive the listview item index and column index of the Nth found listview item matching the input search patern. |
Syntax: |
$xdid(dialog, ID, [TAB]Matchtext[TAB], T, N).find |
Example: |
$xdid(dcx, 4, $chr(9) *Item* $chr(9), W, 3).find |
Parameters: |
MATCHTEXT |
String composed of wildcards or regex paterns used for the search. |
T |
Value indicating if the search is using a regex patern or wildcard string. |
W |
Matchtext is a wildcard string. |
R |
Matchtext is a regex patern. |
N |
Parameter indicating to return the Nth match. |
| Note.- If N is 0, returns the total number of matching items.
- The [TAB] characters surrounding the matchtext are mandatory or else it wont work.
- The global search iterates line by line, starting at the top.
|
$xdid().num |
This property lets you retreive the number of listbox items. |
Syntax: |
$xdid(dialog, ID).num |
Example: |
$xdid(dcx, 4).num |
$xdid().sel |
This property lets you retreive the indexes of selected items in the list. |
Syntax: |
$xdid(dialog, ID, (N)).sel |
Example: |
$xdid(dcx, 4, 2).sel |
Parameters: |
N |
Optional parameter allowing you to obtain the Nth selected index. |
| Note.- If the list is multi, and N is not supplied, then this command will return a comma-separated list of the selected indexes.
- If N is 0, then this will return the number of lines selected.
- When using this property without N, the result is limited to 900 characters. This is due to an implementation that mIRC has imposed on DLL communication, so it is advised to use the N parameter to prevent inaccurate results.
|
$xdid().tbitem |
This property lets you retreive top and bottom visible item indexes. |
Syntax: |
$xdid(dialog, ID).tbitem |
Example: |
$xdid(dcx, 4).tbitem |
$xdid().text |
This property lets you retreive the Nth listbox item text. |
Syntax: |
$xdid(dialog, ID, N).text |
Example: |
$xdid(dcx, 4, 2).text |
List Events |
These events are fired when activity occurs in the List control. |
dclick |
When an item is double-clicked in the listbox. |
Syntax: |
/cb_alias DNAME dclick ID ITEM |
Example: |
/cb_alias dcx dclick 4 6 |
Parameters: |
ITEM |
Item number where the event was triggered. |
dragbegin |
Triggers when one or more files are dropped onto the control. |
Syntax: |
/cb_alias DNAME dragbegin ID COUNT |
Example: |
/cb_alias dcx dragbegin 4 3 |
Parameters: |
COUNT |
Total number of files dragged into the control. |
Return | cancel to stop the drag drop events from occuring. |
dragfile |
The filename of the file that has |
Syntax: |
/cb_alias DNAME dragfile ID FILENAME |
Example: |
/cb_alias dcx dragfile 4 C:/mIRC/blah.txt |
dragfinish |
Event triggered when processing of drag drop is complete. |
Syntax: |
/cb_alias DNAME dragfinish ID |
Example: |
/cb_alias dcx dragfinish 4 |
help |
Launched when you click on a control using the ? contexthelp button. |
Syntax: |
/cb_alias DNAME help ID |
Example: |
/cb_alias dcx help 4 |
itemdrag |
Triggers when an item is dragged. |
Syntax: |
/cb_alias DNAME itemdrag ID ITEM_ID ITEM_MOUSEOVER |
Example: |
/cb_alias dcx itemdrag 4 5 3 |
Parameters: |
ITEM_ID |
The ID of the item dragged. |
ITEM_MOUSEOVER |
The ID of the item the mouse is currently over. |
Return | stop to display a stop cursor. copy to display a copy cursor. | | Note. If the mouse is not currently over the control, ITEM_MOUSEOVER will be 0. |
itemdragbegin |
Triggers when an item is about to be dragged. |
Syntax: |
/cb_alias DNAME itemdragbegin ID ITEM_ID |
Example: |
/cb_alias dcx itemdragbegin 4 5 |
Parameters: |
ITEM_ID |
The ID of the item about to be dragged. |
Return | nodrag to prevent the item from being dragged. |
itemdragcancel |
Triggers when user cancels drag by either pressing ESC or right clicking the mouse button. |
Syntax: |
/cb_alias DNAME itemdragcancel ID ITEM_ID |
Example: |
/cb_alias dcx itemdragcancel 4 5 |
Parameters: |
ITEM_ID |
The ID of the item selected for dragging. |
itemdragfinish |
Triggers when an item has finished dragging. |
Syntax: |
/cb_alias DNAME itemdragfinish ID ITEM_ID ITEM_MOUSEOVER |
Example: |
/cb_alias dcx itemdragfinish 4 5 3 |
Parameters: |
ITEM_ID |
The ID of the item dragged. |
ITEM_MOUSEOVER |
The ID of the item the mouse is currently over. |
| Note. If the mouse is not currently over the control, ITEM_MOUSEOVER will be 0. |
rclick |
When you right-click on the list. |
Syntax: |
/cb_alias DNAME rclick ID |
Example: |
/cb_alias dcx rclick 4 |
sclick |
When an item is selected in the listbox. |
Syntax: |
/cb_alias DNAME sclick ID ITEM |
Example: |
/cb_alias dcx sclick 4 6 |
Parameters: |
ITEM |
Item number where the event was triggered. |
scrollend |
Event triggered when the list has finished scrolling. |
Syntax: |
/cb_alias DNAME scrollend ID |
Example: |
/cb_alias dcx scrollend 4 |
|