# listviewitem class

A listviewitem class

Inherits
listviewitem
Description

The listviewitem class implements a list view item. A list view item is a multi-column object capable of displaying itself in a listview. To use this class you must instantiate it with another listviewitem or a listview as parent. The item will be automatically displayed. You can set the text and a pixmap in each column and you can make it checkable with $setcheckable(). A checkable listviewitem will display a small check mark in the first column.

Functions

`$setText(<column:integer>,<text:string>)`
Sets the text in column column to text, if column is a valid column number and text is different from the existing text.
`<string> $text(<column:integer>)`
Returs the text of the specified column.
`$setPixmap(<column:integer>,<pixmap:hobject or imageID>)`
Sets the pixmap in column column to pm, if pm is non-null and different from the current pixmap, and if column is non-negative. Pixmap can be a Kvirc imageid, an image file or a pixmap object.
`$setRenameEnabled(<col:integer>,<bEnabled:boolean>)`
If b is TRUE (1), this item can be in-place renamed in the column col by the user; otherwise it cannot be renamed in-place.
`$setEnabled(<bEnabled:boolean>)`
Enables or disables the item
`$isEnabled()`
Returns $true if this item is enabled and $false otherwise
`$setOpen(<bOpen:boolean>)`
Opens or closes the item to show its children items
`$isOpen()`
Returns the open state of this item
`$setCheckable(<bCheckable:boolean>)`
Makes this item checkable or not. This function should be called immediately after the item creation: changing this property later at runtime may have strange results (like the item being moved inside the list, text disappearing, hidden children etc... don't do it :D ).
`$isCheckable()`
Returns $true if this item is checkable and $false otherwise
`$setChecked(<bChecked:boolean>)`
Sets this item to be checked or not. $setcheckable() must have been previously called.
`$isChecked()`
Returns the check status of this item. $setcheckable() must have been previously called.
`<listviewitem> $firstChild()`
Returns the first child item of this listviewitem or $null if this item has no children.
`<listviewitem> $nextSibling()`
Returns the next sibling item of this listviewitem or $null if there are no sibling items. Next sibling stands for the item at the same tree level coming just after :)

Index, Object Classes

KVIrc 3.4.0 Documentation
Generated by linimon at Wed Dec 3 16:16:57 2008