Eneboo - Documentación para desarrolladores
|
The QListBoxText class provides list box items that display text. Más...
#include <qlistbox.h>
Métodos públicos | |
QListBoxText (QListBox *listbox, const QString &text=QString::null) | |
QListBoxText (const QString &text=QString::null) | |
QListBoxText (QListBox *listbox, const QString &text, QListBoxItem *after) | |
~QListBoxText () | |
int | height (const QListBox *) const |
int | width (const QListBox *) const |
int | rtti () const |
QListBoxText (QListBox *listbox, const QString &text=QString::null) | |
QListBoxText (const QString &text=QString::null) | |
QListBoxText (QListBox *listbox, const QString &text, QListBoxItem *after) | |
~QListBoxText () | |
int | height (const QListBox *) const |
int | width (const QListBox *) const |
int | rtti () const |
Atributos públicos estáticos | |
static int | RTTI = 1 |
Métodos protegidos | |
void | paint (QPainter *) |
void | paint (QPainter *) |
The QListBoxText class provides list box items that display text.
The text is drawn in the widget's current font. If you need several different fonts, you must implement your own subclass of QListBoxItem.
QListBoxText::QListBoxText | ( | QListBox * | listbox, |
const QString & | text = QString::null |
||
) |
Constructs a list box item in list box listbox showing the text text.
QListBoxText::QListBoxText | ( | const QString & | text = QString::null | ) |
Constructs a list box item showing the text text.
QListBoxText::QListBoxText | ( | QListBox * | listbox, |
const QString & | text, | ||
QListBoxItem * | after | ||
) |
Constructs a list box item in list box listbox showing the text text. The item is inserted after the item after, or at the beginning if after is 0.
QListBoxText::~QListBoxText | ( | ) |
Destroys the item.
QListBoxText::QListBoxText | ( | QListBox * | listbox, |
const QString & | text = QString::null |
||
) |
QListBoxText::QListBoxText | ( | const QString & | text = QString::null | ) |
QListBoxText::QListBoxText | ( | QListBox * | listbox, |
const QString & | text, | ||
QListBoxItem * | after | ||
) |
QListBoxText::~QListBoxText | ( | ) |
Returns the height of a line of text in list box lb.
Reimplementado de QListBoxItem.
Implement this function to return the height of your item. The lb parameter is the same as listBox() and is provided for convenience and compatibility.
The default implementation returns {QApplication::globalStrut()}'s height.
Reimplementado de QListBoxItem.
void QListBoxText::paint | ( | QPainter * | p | ) | [protected, virtual] |
Implement this function to draw your item. The painter, p, is already open for painting.
Implementa QListBoxItem.
Reimplementado en BoldListBoxText.
void QListBoxText::paint | ( | QPainter * | painter | ) | [protected, virtual] |
int QListBoxText::rtti | ( | ) | const [virtual] |
Returns 0.
Make your derived classes return their own values for rtti(), and you can distinguish between listbox items. You should use values greater than 1000 preferably a large random number, to allow for extensions to this class.
Reimplementado de QListBoxItem.
int QListBoxText::rtti | ( | ) | const [virtual] |
Returns 1.
Make your derived classes return their own values for rtti(), and you can distinguish between listbox items. You should use values greater than 1000 preferably a large random number, to allow for extensions to this class.
Reimplementado de QListBoxItem.
Returns the width of this line in list box lb.
Reimplementado de QListBoxItem.
Reimplement this function to return the width of your item. The lb parameter is the same as listBox() and is provided for convenience and compatibility.
The default implementation returns {QApplication::globalStrut()}'s width.
Reimplementado de QListBoxItem.
static int QListBoxText::RTTI = 1 [static] |
Reimplementado de QListBoxItem.