class KKeyButton

# class KKeyButton | A push button that looks like a keyboard key. More...
Internal Use Only
Definition | `#include <kkeybutton.h>`
Inherits | QPushButton (qt) [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- KKeyButton ( QWidget *parent = 0, const char *name = 0 )
- virtual ~KKeyButton ()
- void setShortcut ( const KShortcut& cut )
- void setShortcut ( const KShortcut& cut, bool bQtShortcut )
- const KShortcut& shortcut () const
- void setText ( const QString& text )

#### Public Slots

- void captureShortcut ()

#### Signals

- void capturedShortcut ( const KShortcut& )

#### Protected Methods

- void drawButton ( QPainter* _painter )
- virtual void virtual_hook ( int id, void* data )

#### Protected Members

- KShortcut m_cut
- bool m_bEditing

## Detailed Description

A push button that looks like a keyboard key.

You must call setShortcut() to set the widget's currently displayed key. You can call captureShortcut() to get a new shortcut from the user. If captureShortcut() suceeds, then the capturedShortcut signal will be emitted with the value of the new shortcut. The widget containing a KKeyButton widget must connect to this signal and check if the shortcut is valid. If it is, you will need to call setShortcut() with the new value in order make it the key currently displayed.

KKeyButton ( QWidget *parent = 0, const char *name = 0 ) | ### KKeyButton

Constructs key button widget.

~KKeyButton () | ### ~KKeyButton

[virtual]

Destructs the key button widget.

void setShortcut ( const KShortcut& cut ) | ### setShortcut

void setShortcut ( const KShortcut& cut, bool bQtShortcut ) | ### setShortcut

const KShortcut& shortcut () | ### shortcut

[const]

void setText ( const QString& text ) | ### setText

Reimplemented for internal purposes.

void capturedShortcut ( const KShortcut& ) | ### capturedShortcut

[signal]

void captureShortcut () | ### captureShortcut

[slot]

Call this method to capture a shortcut from the keyboard. If it succeeds, the capturedShortcut() will be emitted.

KShortcut m_cut | ### m_cut

[protected]

bool m_bEditing | ### m_bEditing

[protected]

void drawButton ( QPainter* _painter ) | ### drawButton

[protected]

Reimplemented for internal reasons.

void virtual_hook ( int id, void* data ) | ### virtual_hook

[protected virtual]

- Author: Mark Donohoe
- Generated: root on macppc.ports.openbsd.org on Sat Sep 6 10:36:37 2003, using kdoc 2.0a54.