wxListEvent(3)
π wxListEvent π
okay bestie, welcome to wxListEvent β the Erlang module definition, brought to you by the fine folks at Ericsson AB on wx 2.6. let's get into it π¦
β¨ NAME β¨
wxListEvent β a list event holds information about events associated with wxListCtrl objects. that's it, that's the vibe. π
πΈ DESCRIPTION πΈ
see also: wxListCtrl π
this class is derived, and can use functions, from:
wxNotifyEventwxCommandEventwxEvent
wxWidgets docs: wxListEvent π
π«Ά Events
use wxEvtHandler:connect/3 with wxListEventType to subscribe to events of this type. fr fr, that's how you get on the list. π
β DATA TYPES β
wxList() :: #wxList{}.wxListEvent() :: wx:wx_object().wxListEventType() ::with all these iconic little atoms:
command_list_begin_drag | command_list_begin_rdrag |
command_list_begin_label_edit | command_list_end_label_edit |
command_list_delete_item | command_list_delete_all_items |
command_list_key_down | command_list_insert_item |
command_list_col_click | command_list_col_right_click |
command_list_col_begin_drag | command_list_col_dragging |
command_list_col_end_drag | command_list_item_selected |
command_list_item_deselected | command_list_item_right_click |
command_list_item_middle_click | command_list_item_activated |
command_list_item_focused | command_list_cache_hint.
π₯ FUNCTIONS π₯
getCacheFrom(This) -> integer()whenThis :: wxListEvent().
for EVT_LIST_CACHE_HINT event only: return the first item which the list control advises us to cache. lowkey a lil hint from the list control, take it bestie β¨
getCacheTo(This) -> integer()whenThis :: wxListEvent().
for EVT_LIST_CACHE_HINT event only: return the last item (inclusive, no that's not a typo, it's inclusive) which the list control advises us to cache. π
getColumn(This) -> integer()whenThis :: wxListEvent().
the column position: it is only used with COL events. π
for the column dragging events, it is the column to the left of the divider being dragged. for the column click events it may be -1 if the user clicked in the list control header outside any column. yes, -1, the void, the nothing-column. π
getData(This) -> integer()whenThis :: wxListEvent().
the data. short and sweet, periodt. π
getImage(This) -> integer()whenThis :: wxListEvent().
the image. π
getIndex(This) -> integer()whenThis :: wxListEvent().
the item index. go off. β¨
getItem(This) -> wxListItem:wxListItem()whenThis :: wxListEvent().
an item object, used by some events. π
see also wxListCtrl:setItem/5.
getKeyCode(This) -> integer()whenThis :: wxListEvent().
key code if the event is a keypress event. keyboard moment. β¨οΈ
getLabel(This) -> unicode:charlist()whenThis :: wxListEvent().
the (new) item label for EVT_LIST_END_LABEL_EDIT event. π·οΈ
getMask(This) -> integer()whenThis :: wxListEvent().
the mask. slay. π
getPoint(This) -> {X :: integer(), Y :: integer()}whenThis :: wxListEvent().
the position of the mouse pointer if the event is a drag event. where the cursor at, bestie π±οΈ
getText(This) -> unicode:charlist()whenThis :: wxListEvent().
the text. π¬
isEditCancelled(This) -> boolean()whenThis :: wxListEvent().
this method only makes sense for EVT_LIST_END_LABEL_EDIT message and returns true if it the label editing has been cancelled by the user (getLabel/1 returns an empty string in this case but it doesn't allow the application to distinguish between really cancelling the edit and the admittedly rare case when the user wants to rename it to an empty string). π the empty-string ambiguity is real and the manpage said what it said.
not me giving you the exact same caveat the original gave you, because the facts stay facts even when the vibe is immaculate. π
and that's the whole page, bestie β every flag, every return type, every atom, all of it, no cap. this was Ericsson AB, wx 2.6, wxListEvent(3), and you officially know it now. go be the main character of your own list control. π
ππ¦
π¦ where this page comes from
- ubuntu stonking: erlang-doc 1:29.0.6+dfsg-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms