|
Eneboo - Documentación para desarrolladores
|
#include <listviews.h>
Métodos públicos | |
| LVI (QListView *parent, QString text=QString::null) | |
| LVI (QListViewItem *parent, QString text=QString::null) | |
| virtual int | compare (QListViewItem *other, int column, bool ascending) const |
| virtual bool | danger () const |
Métodos protegidos | |
| void | drawObsoleteText (QPainter *p, const QColorGroup &cg, int column, int width, int align) |
| LVI::LVI | ( | QListView * | parent, |
| QString | text = QString::null |
||
| ) |
| LVI::LVI | ( | QListViewItem * | parent, |
| QString | text = QString::null |
||
| ) |
| int LVI::compare | ( | QListViewItem * | i, |
| int | col, | ||
| bool | ascending | ||
| ) | const [virtual] |
Compares this list view item to i using the column col in ascending order. Returns < 0 if this item is less than i, 0 if they are equal and > 0 if this item is greater than i.
This function is used for sorting.
The default implementation compares the item keys (key()) using QString::localeAwareCompare(). A reimplementation can use different values and a different comparison function. Here is a reimplementation that uses plain Unicode comparison:
int MyListViewItem::compare( QListViewItem *i, int col, bool ascending ) const { return key( col, ascending ).compare( i->key( col, ascending) ); }
We don't recommend using ascending so your code can safely ignore it.
Reimplementado de QListViewItem.
| virtual bool LVI::danger | ( | ) | const [inline, virtual] |
Reimplementado en ContextLVI y MessageLVI.
| void LVI::drawObsoleteText | ( | QPainter * | p, |
| const QColorGroup & | cg, | ||
| int | column, | ||
| int | width, | ||
| int | align | ||
| ) | [protected] |
1.7.4