#include <tdetoolbarbutton.h>
Inherits TQToolButton.
|
void | clicked (int) |
|
void | buttonClicked (int, TQt::ButtonState state) |
|
void | doubleClicked (int) |
|
void | pressed (int) |
|
void | released (int) |
|
void | toggled (int) |
|
void | highlighted (int, bool) |
|
|
| TDEToolBarButton (const TQString &icon, int id, TQWidget *parent, const char *name=0L, const TQString &txt=TQString::null, TDEInstance *_instance=TDEGlobal::instance()) |
|
| TDEToolBarButton (const TQPixmap &pixmap, int id, TQWidget *parent, const char *name=0L, const TQString &txt=TQString::null) |
|
| TDEToolBarButton (TQWidget *parent=0L, const char *name=0L) |
|
| ~TDEToolBarButton () |
|
virtual void | setPixmap (const TQPixmap &pixmap) TDE_DEPRECATED |
|
void | setDefaultPixmap (const TQPixmap &pixmap) TDE_DEPRECATED |
|
void | setDisabledPixmap (const TQPixmap &pixmap) TDE_DEPRECATED |
|
virtual void | setText (const TQString &text) |
|
virtual void | setIcon (const TQString &icon) |
|
virtual void | setIcon (const TQPixmap &pixmap) |
|
virtual void | setIconSet (const TQIconSet &iconset) |
|
TDE_DEPRECATED void | setIcon (const TQString &icon, bool generate) |
|
void | setDefaultIcon (const TQString &icon) TDE_DEPRECATED |
|
void | setDisabledIcon (const TQString &icon) TDE_DEPRECATED |
|
void | on (bool flag=true) |
|
void | toggle () |
|
void | setToggle (bool toggle=true) |
|
TQPopupMenu * | popup () |
|
int | id () const |
|
void | setPopup (TQPopupMenu *p, bool unused=false) |
|
void | setDelayedPopup (TQPopupMenu *p, bool unused=false) |
|
void | setRadio (bool f=true) |
|
void | setNoStyle (bool no_style=true) |
|
A toolbar button.
This is used internally by TDEToolBar, use the TDEToolBar methods instead.
Definition at line 44 of file tdetoolbarbutton.h.
◆ TDEToolBarButton() [1/3]
TDEToolBarButton::TDEToolBarButton |
( |
const TQString & |
icon, |
|
|
int |
id, |
|
|
TQWidget * |
parent, |
|
|
const char * |
name = 0L , |
|
|
const TQString & |
txt = TQString::null , |
|
|
TDEInstance * |
_instance = TDEGlobal::instance() |
|
) |
| |
Construct a button with an icon loaded by the button itself.
This will trust the button to load the correct icon with the correct size.
- Parameters
-
icon | Name of icon to load (may be absolute or relative) |
id | Id of this button |
parent | This button's parent |
name | This button's internal name |
txt | This button's text (in a tooltip or otherwise) |
_instance | the instance to use for this button |
Definition at line 115 of file tdetoolbarbutton.cpp.
◆ TDEToolBarButton() [2/3]
TDEToolBarButton::TDEToolBarButton |
( |
const TQPixmap & |
pixmap, |
|
|
int |
id, |
|
|
TQWidget * |
parent, |
|
|
const char * |
name = 0L , |
|
|
const TQString & |
txt = TQString::null |
|
) |
| |
Construct a button with an existing pixmap.
It is not recommended that you use this as the internal icon loading code will almost always get it "right".
- Parameters
-
pixmap | Name of icon to load (may be absolute or relative) |
id | Id of this button |
parent | This button's parent |
name | This button's internal name |
txt | This button's text (in a tooltip or otherwise) |
Definition at line 149 of file tdetoolbarbutton.cpp.
◆ TDEToolBarButton() [3/3]
TDEToolBarButton::TDEToolBarButton |
( |
TQWidget * |
parent = 0L , |
|
|
const char * |
name = 0L |
|
) |
| |
Construct a separator button.
- Parameters
-
parent | This button's parent |
name | This button's internal name |
Definition at line 105 of file tdetoolbarbutton.cpp.
◆ ~TDEToolBarButton()
TDEToolBarButton::~TDEToolBarButton |
( |
| ) |
|
◆ buttonClicked
void TDEToolBarButton::buttonClicked |
( |
int |
, |
|
|
TQt::ButtonState |
state |
|
) |
| |
|
signal |
Emitted when the toolbar button is clicked (with any mouse button)
- Parameters
-
state | makes it possible to find out which button was pressed, and whether any keyboard modifiers were held. |
- Since
- 3.4
◆ clicked
void TDEToolBarButton::clicked |
( |
int |
| ) |
|
|
signal |
Emitted when the toolbar button is clicked (with LMB or MMB)
◆ drawButton()
void TDEToolBarButton::drawButton |
( |
TQPainter * |
p | ) |
|
|
protected |
◆ enterEvent()
void TDEToolBarButton::enterEvent |
( |
TQEvent * |
e | ) |
|
|
protected |
◆ event()
bool TDEToolBarButton::event |
( |
TQEvent * |
e | ) |
|
|
protected |
◆ eventFilter()
bool TDEToolBarButton::eventFilter |
( |
TQObject * |
o, |
|
|
TQEvent * |
e |
|
) |
| |
|
protected |
◆ iconTextMode()
int TDEToolBarButton::iconTextMode |
( |
| ) |
const |
|
protected |
◆ id()
int TDEToolBarButton::id |
( |
| ) |
const |
◆ isActive()
bool TDEToolBarButton::isActive |
( |
| ) |
const |
|
protected |
◆ isRaised()
bool TDEToolBarButton::isRaised |
( |
| ) |
const |
|
protected |
◆ leaveEvent()
void TDEToolBarButton::leaveEvent |
( |
TQEvent * |
e | ) |
|
|
protected |
◆ minimumSize()
TQSize TDEToolBarButton::minimumSize |
( |
| ) |
const |
|
protected |
◆ minimumSizeHint()
TQSize TDEToolBarButton::minimumSizeHint |
( |
void |
| ) |
const |
|
protected |
◆ modeChange
void TDEToolBarButton::modeChange |
( |
| ) |
|
|
slot |
This slot should be called whenever the toolbar mode has potentially changed.
This includes such events as text changing, orientation changing, etc.
Definition at line 186 of file tdetoolbarbutton.cpp.
◆ mousePressEvent()
void TDEToolBarButton::mousePressEvent |
( |
TQMouseEvent * |
e | ) |
|
|
protected |
◆ mouseReleaseEvent()
void TDEToolBarButton::mouseReleaseEvent |
( |
TQMouseEvent * |
e | ) |
|
|
protected |
◆ on()
void TDEToolBarButton::on |
( |
bool |
flag = true | ) |
|
◆ paletteChange()
void TDEToolBarButton::paletteChange |
( |
const TQPalette & |
| ) |
|
|
protected |
◆ popup()
TQPopupMenu * TDEToolBarButton::popup |
( |
| ) |
|
◆ setDefaultIcon()
void TDEToolBarButton::setDefaultIcon |
( |
const TQString & |
icon | ) |
|
- Deprecated:
- Force the button to use this icon as the default one rather then generating it using effects.
- Parameters
-
icon | The icon to use as the default (normal) one |
Definition at line 330 of file tdetoolbarbutton.cpp.
◆ setDefaultPixmap()
void TDEToolBarButton::setDefaultPixmap |
( |
const TQPixmap & |
pixmap | ) |
|
- Deprecated:
- Force the button to use this pixmap as the default one rather then generating it using effects.
- Parameters
-
pixmap | The pixmap to use as the default (normal) one |
Definition at line 316 of file tdetoolbarbutton.cpp.
◆ setDelayedPopup()
void TDEToolBarButton::setDelayedPopup |
( |
TQPopupMenu * |
p, |
|
|
bool |
unused = false |
|
) |
| |
Gives this button a delayed popup menu.
This function allows you to add a delayed popup menu to the button. The popup menu is then only displayed when the button is pressed and held down for about half a second.
- Parameters
-
p | the new popup menu |
unused | Has no effect - ignore it. |
Definition at line 372 of file tdetoolbarbutton.cpp.
◆ setDisabledIcon()
void TDEToolBarButton::setDisabledIcon |
( |
const TQString & |
icon | ) |
|
- Deprecated:
- Force the button to use this icon when disabled one rather then generating it using effects.
- Parameters
-
icon | The icon to use when disabled |
Definition at line 344 of file tdetoolbarbutton.cpp.
◆ setDisabledPixmap()
void TDEToolBarButton::setDisabledPixmap |
( |
const TQPixmap & |
pixmap | ) |
|
- Deprecated:
- Force the button to use this pixmap when disabled one rather then generating it using effects.
- Parameters
-
pixmap | The pixmap to use when disabled |
Definition at line 323 of file tdetoolbarbutton.cpp.
◆ setIcon() [1/3]
virtual void TDEToolBarButton::setIcon |
( |
const TQPixmap & |
pixmap | ) |
|
|
inlinevirtual |
◆ setIcon() [2/3]
void TDEToolBarButton::setIcon |
( |
const TQString & |
icon | ) |
|
|
virtual |
Set the icon for this button.
The icon will be loaded internally with the correct size. This function is preferred over setIconSet
- Parameters
-
Definition at line 284 of file tdetoolbarbutton.cpp.
◆ setIcon() [3/3]
TDE_DEPRECATED void TDEToolBarButton::setIcon |
( |
const TQString & |
icon, |
|
|
bool |
generate |
|
) |
| |
|
inline |
- Deprecated:
- Set the active icon for this button. The pixmap itself is loaded internally based on the icon size... .. the disabled and default pixmaps, however will only be constructed if generate is true. This function is preferred over setPixmap
- Parameters
-
icon | The name of the active icon |
generate | If true, then the other icons are automagically generated from this one |
Definition at line 165 of file tdetoolbarbutton.h.
◆ setIconSet()
void TDEToolBarButton::setIconSet |
( |
const TQIconSet & |
iconset | ) |
|
|
virtual |
Set the pixmaps for this toolbar button from a TQIconSet.
If you call this you don't need to call any of the other methods that set icons or pixmaps.
- Parameters
-
iconset | The iconset to use |
Definition at line 298 of file tdetoolbarbutton.cpp.
◆ setNoStyle()
void TDEToolBarButton::setNoStyle |
( |
bool |
no_style = true | ) |
|
Toolbar buttons naturally will assume the global styles concerning icons, icons sizes, etc.
You can use this function to explicitly turn this off, if you like.
- Parameters
-
no_style | Will disable styles if true |
Definition at line 700 of file tdetoolbarbutton.cpp.
◆ setPixmap()
void TDEToolBarButton::setPixmap |
( |
const TQPixmap & |
pixmap | ) |
|
|
virtual |
- Deprecated:
- Set the pixmap directly for this button. This pixmap should be the active one... the dimmed and disabled pixmaps are constructed based on this one. However, don't use this function unless you are positive that you don't want to use setIcon.
- Parameters
-
Definition at line 304 of file tdetoolbarbutton.cpp.
◆ setPopup()
void TDEToolBarButton::setPopup |
( |
TQPopupMenu * |
p, |
|
|
bool |
unused = false |
|
) |
| |
Give this button a popup menu.
There will not be a delay when you press the button. Use setDelayedPopup if you want that behavior.
- Parameters
-
p | The new popup menu |
unused | Has no effect - ignore it. |
Definition at line 365 of file tdetoolbarbutton.cpp.
◆ setRadio()
void TDEToolBarButton::setRadio |
( |
bool |
f = true | ) |
|
◆ setText()
void TDEToolBarButton::setText |
( |
const TQString & |
text | ) |
|
|
virtual |
Set the text for this button.
The text will be either used as a tooltip (IconOnly) or will be along side the icon
- Parameters
-
text | The button (or tooltip) text |
Definition at line 278 of file tdetoolbarbutton.cpp.
◆ setTextLabel
void TDEToolBarButton::setTextLabel |
( |
const TQString & |
text, |
|
|
bool |
tipToo |
|
) |
| |
|
virtualslot |
◆ setToggle()
void TDEToolBarButton::setToggle |
( |
bool |
toggle = true | ) |
|
Turn this button into a toggle button or disable the toggle aspects of it.
This does not toggle the button itself. Use toggle() for that.
- Parameters
-
Definition at line 733 of file tdetoolbarbutton.cpp.
◆ showMenu()
void TDEToolBarButton::showMenu |
( |
| ) |
|
|
protected |
◆ sizeHint()
TQSize TDEToolBarButton::sizeHint |
( |
void |
| ) |
const |
|
protected |
◆ slotClicked
void TDEToolBarButton::slotClicked |
( |
| ) |
|
|
protectedslot |
◆ slotDelayTimeout
void TDEToolBarButton::slotDelayTimeout |
( |
| ) |
|
|
protectedslot |
◆ slotPressed
void TDEToolBarButton::slotPressed |
( |
| ) |
|
|
protectedslot |
◆ slotReleased
void TDEToolBarButton::slotReleased |
( |
| ) |
|
|
protectedslot |
◆ slotToggled
void TDEToolBarButton::slotToggled |
( |
| ) |
|
|
protectedslot |
◆ toggle()
void TDEToolBarButton::toggle |
( |
| ) |
|
◆ virtual_hook()
void TDEToolBarButton::virtual_hook |
( |
int |
id, |
|
|
void * |
data |
|
) |
| |
|
protectedvirtual |
The documentation for this class was generated from the following files: