KPushButton Class Reference
#include <kpushbutton.h>
Inheritance diagram for KPushButton:

Detailed Description
This is nothing but a QPushButton with drag-support and KGuiItem support.A QPushButton with drag-support and KGuiItem support.You have to call setDragEnabled( true ) and override the virtual method dragObject() to specify the QDragObject to be used.
- Author:
- Carsten Pfeiffer <pfeiffer@kde.org>
Definition at line 37 of file kpushbutton.h.
Public Member Functions | |
KPushButton (QWidget *parent, const char *name=0) | |
KPushButton (const QString &text, QWidget *parent, const char *name=0) | |
KPushButton (const QIconSet &icon, const QString &text, QWidget *parent, const char *name=0) | |
KPushButton (const KGuiItem &item, QWidget *parent, const char *name=0) | |
~KPushButton () | |
void | setDragEnabled (bool enable) |
bool | isDragEnabled () const |
void | setGuiItem (const KGuiItem &item) |
void | setGuiItem (KStdGuiItem::StdItem item) |
KStdGuiItem::StdItem | guiItem () const |
void | setGuiItm (int itm) |
int | guiItm () const |
void | setIconSet (const QIconSet &iconSet) |
void | setText (const QString &text) |
Protected Member Functions | |
virtual QDragObject * | dragObject () |
virtual void | mousePressEvent (QMouseEvent *) |
virtual void | mouseMoveEvent (QMouseEvent *) |
virtual void | startDrag () |
virtual void | virtual_hook (int id, void *data) |
Properties | |
int | stdItem |
bool | isDragEnabled |
Constructor & Destructor Documentation
|
Default constructor.
Definition at line 43 of file kpushbutton.cpp. |
|
Constructor, that sets the button-text to
Definition at line 50 of file kpushbutton.cpp. |
|
Constructor, that sets an icon and the button-text to
Definition at line 58 of file kpushbutton.cpp. |
|
Constructor that takes a KGuiItem for the text, the icon, the tooltip and the what's this help.
Definition at line 66 of file kpushbutton.cpp. |
|
Destructs the button.
Definition at line 74 of file kpushbutton.cpp. |
Member Function Documentation
|
Reimplement this and return the QDragObject that should be used for the drag. Default implementation returns 0L, so that no drag is initiated. Definition at line 205 of file kpushbutton.cpp. |
|
Reads the standard KGuiItem for this button.
Definition at line 143 of file kpushbutton.cpp. |
|
Definition at line 80 of file kpushbutton.h. |
|
Reimplemented to add drag-support.
Definition at line 188 of file kpushbutton.cpp. |
|
Reimplemented to add drag-support.
Definition at line 181 of file kpushbutton.cpp. |
|
Enables/disables drag-support. Default is disabled. Definition at line 176 of file kpushbutton.cpp. |
|
Sets the standard KGuiItem for this button.
Definition at line 137 of file kpushbutton.cpp. |
|
Sets the KGuiItem for this button.
Definition at line 120 of file kpushbutton.cpp. |
|
Sets the Icon Set for this button. It also takes into account hte KGlobalSettings::showIconsOnPushButtons() setting. Reimplemented from QPushButton. Definition at line 160 of file kpushbutton.cpp. |
|
Sets the text of the button.
Reimplemented from QPushButton. Definition at line 148 of file kpushbutton.cpp. |
|
Starts a drag (dragCopy() by default) using dragObject().
Definition at line 210 of file kpushbutton.cpp. |
The documentation for this class was generated from the following files: