org.kde.koala

Class KPushButton

public class KPushButton extends QPushButton

This is nothing but a QPushButton with drag-support and KGuiItem support. You have to call setDragEnabled( true ) and override the method dragObject() to specify the QDragObject to be used.

Author: Carsten Pfeiffer

UNKNOWN: A QPushButton with drag-support and KGuiItem support.

Constructor Summary
protected KPushButton(Class dummy)
KPushButton(QWidget parent, String name)
Default constructor.
KPushButton(QWidget parent)
KPushButton(String text, QWidget parent, String name)
Constructor, that sets the button-text to text
KPushButton(String text, QWidget parent)
KPushButton(QIconSet icon, String text, QWidget parent, String name)
Constructor, that sets an icon and the button-text to text
KPushButton(QIconSet icon, String text, QWidget parent)
KPushButton(KGuiItem item, QWidget parent, String name)
Constructor that takes a KGuiItem for the text, the icon, the tooltip and the what's this help
KPushButton(KGuiItem item, QWidget parent)
Method Summary
StringclassName()
voiddispose()
Delete the wrapped C++ instance ahead of finalize()
protected QDragObjectdragObject()
Reimplement this and return the QDragObject that should be used for the drag.
protected voidfinalize()
Deletes the wrapped C++ instance
intguiItem()
Reads the standard KGuiItem for this button.
intguiItm()
booleanisDisposed()
Has the wrapped C++ instance been deleted?
booleanisDragEnabled()
QMetaObjectmetaObject()
protected voidmouseMoveEvent(QMouseEvent arg1)
Reimplemented to add drag-support
protected voidmousePressEvent(QMouseEvent arg1)
Reimplemented to add drag-support
voidsetDragEnabled(boolean enable)
Enables/disables drag-support.
voidsetGuiItem(KGuiItem item)
Sets the KGuiItem for this button.
voidsetGuiItem(int item)
Sets the standard KGuiItem for this button.
voidsetGuiItm(int itm)
voidsetIconSet(QIconSet iconSet)
Sets the Icon Set for this button.
voidsetText(String text)
Sets the text of the button
protected voidstartDrag()
Starts a drag (dragCopy() by default) using dragObject()

Constructor Detail

KPushButton

protected KPushButton(Class dummy)

KPushButton

public KPushButton(QWidget parent, String name)
Default constructor.

UNKNOWN: Default constructor.

KPushButton

public KPushButton(QWidget parent)

KPushButton

public KPushButton(String text, QWidget parent, String name)
Constructor, that sets the button-text to text

UNKNOWN: Constructor, that sets the button-text to text

KPushButton

public KPushButton(String text, QWidget parent)

KPushButton

public KPushButton(QIconSet icon, String text, QWidget parent, String name)
Constructor, that sets an icon and the button-text to text

UNKNOWN: Constructor, that sets an icon and the button-text to text

KPushButton

public KPushButton(QIconSet icon, String text, QWidget parent)

KPushButton

public KPushButton(KGuiItem item, QWidget parent, String name)
Constructor that takes a KGuiItem for the text, the icon, the tooltip and the what's this help

UNKNOWN: Constructor that takes a KGuiItem for the text, the icon, the tooltip and the what's this help

KPushButton

public KPushButton(KGuiItem item, QWidget parent)

Method Detail

className

public String className()

dispose

public void dispose()
Delete the wrapped C++ instance ahead of finalize()

dragObject

protected QDragObject dragObject()
Reimplement this and return the QDragObject that should be used for the drag. Default implementation returns null, so that no drag is initiated.

UNKNOWN: Reimplement this and return the QDragObject that should be used for the drag.

finalize

protected void finalize()
Deletes the wrapped C++ instance

guiItem

public int guiItem()
Reads the standard KGuiItem for this button.

UNKNOWN: Reads the standard KGuiItem for this button.

guiItm

public int guiItm()

isDisposed

public boolean isDisposed()
Has the wrapped C++ instance been deleted?

isDragEnabled

public boolean isDragEnabled()

Returns: if drag support is enabled or not.

UNKNOWN:

metaObject

public QMetaObject metaObject()

mouseMoveEvent

protected void mouseMoveEvent(QMouseEvent arg1)
Reimplemented to add drag-support

UNKNOWN: Reimplemented to add drag-support

mousePressEvent

protected void mousePressEvent(QMouseEvent arg1)
Reimplemented to add drag-support

UNKNOWN: Reimplemented to add drag-support

setDragEnabled

public void setDragEnabled(boolean enable)
Enables/disables drag-support. Default is disabled.

UNKNOWN: Enables/disables drag-support.

setGuiItem

public void setGuiItem(KGuiItem item)
Sets the KGuiItem for this button.

UNKNOWN: Sets the KGuiItem for this button.

setGuiItem

public void setGuiItem(int item)
Sets the standard KGuiItem for this button.

UNKNOWN: Sets the standard KGuiItem for this button.

setGuiItm

public void setGuiItm(int itm)

setIconSet

public void setIconSet(QIconSet iconSet)
Sets the Icon Set for this button. It also takes into account hte KGlobalSettings.showIconsOnPushButtons() setting.

UNKNOWN: Sets the Icon Set for this button.

setText

public void setText(String text)
Sets the text of the button

UNKNOWN: Sets the text of the button

startDrag

protected void startDrag()
Starts a drag (dragCopy() by default) using dragObject()

UNKNOWN: Starts a drag (dragCopy() by default) using dragObject()