Class Listview

Inheritance

WinControl Listview 🡄 WinControl 🡄 Control 🡄 Component 🡄 Object

Properties

AutoWidthLastColumn When set to true the last column will resize when the control resizes.
Canvas The canvas object used to render the listview.
Columns The Listcolumns object of the listview.
HideSelection When set to true the selection will not hide when the focus leaves the control.
ItemIndex The currently selected index in the Items object.
Items The ListItems objects of the listview.
OnCustomDraw
OnCustomDrawItem
OnCustomDrawSubItem
OnData Called when a listview with OwnerData true renders a line.
OwnerData When set to true the listview will call the onData function for every line being displayed.
RowSelect When set to true the whole row will be selected instead of just the first column.
Selected The currently selected listitem.

Methods

beginUpdate () Tells the listview to stop updating while you're busy.
clear ()
endUpdate () Applies all updates between beginUpdate and endUpdate.
getCanvas () Returns the canvas object used to render the listview.
getColumns () Returns a ListColumns object.
getItemIndex () Returns the currently selected index in the Items object.
getItems () Returns a ListItems object.
setItemIndex ( index ) Sets the current itemindex.

Creation

createListView ( owner ) Creates a ListView class object which belongs to the given owner.


Inheritance

WinControl
Listview 🡄 WinControl 🡄 Control 🡄 Component 🡄 Object

Properties

AutoWidthLastColumn
When set to true the last column will resize when the control resizes.

Type:

    boolean
Canvas
The canvas object used to render the listview. (Readonly)

Type:

Columns
The Listcolumns object of the listview. (Readonly)

Type:

HideSelection
When set to true the selection will not hide when the focus leaves the control.

Type:

    boolean
ItemIndex
The currently selected index in the Items object.

(-1 if nothing is selected)

Type:

    integer
Items
The ListItems objects of the listview.

Type:

OnCustomDraw

Type:

    function

Usage:

    ListView.OnCustomDraw = function(Sender, {Top, Left, Bottom, Right}, DefaultDraw Optional): NewDefaultDraw
OnCustomDrawItem

Type:

    function

Usage:

    ListView.OnCustomDrawItem = function(Sender, ListItem, {cdsSelected=true/false(nil), cdsGrayed=true/false(nil), cdsDisabled, cdsChecked, cdsFocused, cdsDefault, cdsHot, cdsMarked, cdsIndeterminate}, DefaultDraw Optional): NewDefaultDraw
OnCustomDrawSubItem

Type:

    function

Usage:

    ListView.OnCustomDrawSubItem function(Sender, ListItem, SubItemIndex, {cdsSelected=true/false(nil), cdsGrayed=true/false(nil), cdsDisabled, cdsChecked, cdsFocused, cdsDefault, cdsHot, cdsMarked, cdsIndeterminate}, DefaultDraw Optional): NewDefaultDraw
OnData
Called when a listview with OwnerData true renders a line.

Type:

    function

Usage:

    ListView.OnData = function(sender, ListItem)
OwnerData
When set to true the listview will call the onData function for every line being displayed. Use Items.Count to set the number of virtual lines.

Type:

    boolean
RowSelect
When set to true the whole row will be selected instead of just the first column.

Type:

    boolean
Selected
The currently selected listitem.

(nil if nothing is selected)

Type:

Methods

beginUpdate ()
Tells the listview to stop updating while you're busy.
clear ()
endUpdate ()
Applies all updates between beginUpdate and endUpdate.
getCanvas ()
Returns the canvas object used to render the listview.

Returns:

    Canvas
getColumns ()
Returns a ListColumns object.

Returns:

    ListColumns
getItemIndex ()
Returns the currently selected index in the Items object.

Returns:

    integer
getItems ()
Returns a ListItems object.

Returns:

    ListItems
setItemIndex ( index )
Sets the current itemindex.

Parameters:

  • index integer

Creation

createListView ( owner )
Creates a ListView class object which belongs to the given owner. Owner can be any object inherited from WinControl.

Parameters:

generated by LDoc 1.4.6-antum-dev-1 Last updated 2019-02-27 23:30:35