class KEditListBox

An editable listbox More...

Definition#include <keditlistbox.h>
InheritsQGroupBox (qt)
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Types

Public Methods

Signals

Protected Slots

Protected Members


Detailed Description

An editable listbox

This class provides a editable listbox ;-), this means a listbox which is accompanied by a line edit to enter new items into the listbox and pushbuttons to add and remove items from the listbox and two buttons to move items up and down.

enum Button {Add = 1, Remove = 2, UpDown = 4, All = Add|Remove|UpDown }

Enumeration of the buttons, the listbox offers. Specify them in the constructor in the buttons parameter.

 KEditListBox (QWidget *parent = 0, const char *name = 0, bool checkAtEntering=false, int buttons = All )

Create an editable listbox.

If checkAtEntering is true, after every character you type in the line edit KEditListBox will enable or disable the Add-button, depending whether the current content of the line edit is already in the listbox. Maybe this can become a performance hit with large lists on slow machines. If checkAtEntering is false, it will be checked if you press the Add-button. It is not possible to enter items twice into the listbox.

 KEditListBox (const QString& title, QWidget *parent = 0, const char *name = 0, bool checkAtEntering=false, int buttons = All )

Create an editable listbox.

The same as the other constructor, additionally it takes @title, which will be the title of the frame around the listbox.

QListBox*  listBox ()

[const]

Return a pointer to the embedded QListBox.

KLineEdit*  lineEdit ()

[const]

Return a pointer to the embedded QLineEdit.

QPushButton*  addButton ()

[const]

Return a pointer to the Add button

QPushButton*  removeButton ()

[const]

Return a pointer to the Remove button

QPushButton*  upButton ()

[const]

Return a pointer to the Up button

QPushButton*  downButton ()

[const]

Return a pointer to the Down button

int  count ()

[const]

See QListBox::count()

void  insertStringList (const QStringList& list, int index=-1)

See QListBox::insertStringList()

void  insertStrList (const QStrList* list, int index=-1)

See QListBox::insertStringList()

void  insertStrList (const QStrList& list, int index=-1)

See QListBox::insertStrList()

void  insertStrList (const char ** list, int numStrings=-1, int index=-1)

See QListBox::insertStrList()

void  insertItem (const QString& text, int index=-1)

See QListBox::insertItem()

void  clear ()

Clears both the listbox and the line edit.

QString  text (int index)

[const]

See QListBox::text()

int  currentItem ()

[const]

See QListBox::currentItem()

QString  currentText ()

[const]

See QListBox::currentText()

QStringList  items ()

[const]

Returns: a stringlist of all items in the listbox


Generated by: ssk@tauon.ph.unimelb.EDU.AU on Wed May 23 04:29:58 2001, using kdoc 2.0a35.