![]() |
appkit
1.5.1
RoadNarrows Robotics Application Kit
|
Window button base class. More...
#include <WinMenu.h>
Public Member Functions | |
| WinButton (WinButtonType eType, int nEvent, WidgetState eInitState, AlignOp eAlign, const std::string &strAltText, const std::string &strTagNormal, const std::string &strToolTipNormal="", const std::string &strTagActive="", const std::string &strToolTipActive="") | |
| WinButton initialization constructor. More... | |
| WinButton (const WinButton &src) | |
| WinButton copy constructor. More... | |
| virtual | ~WinButton () |
| Destructor. | |
| virtual void * | getNormalImageWidget () |
| Get the normal icon image widget. More... | |
| virtual void * | getActiveImageWidget () |
| Get the active icon image widget. More... | |
| void * | getCurrentImageWidget () |
| Get the icon image widget associated with the current button state. More... | |
| std::string | getCurrentLabel () |
| Get the text label associated with the current button state. More... | |
| std::string | getCurrentToolTip () |
| Get the tooltip associated with the current button state. More... | |
Protected Member Functions | |
| void | copy (const WinButton *pSrc) |
| Deep copy of source to this. More... | |
Protected Attributes | |
| WinButtonType | m_eType |
| button type | |
| int | m_nEvent |
| button push "mouse click" event | |
| WidgetState | m_eInitState |
| initial button widget state | |
| WidgetState | m_eState |
| current button widget state | |
| AlignOp | m_eAlign |
| left or right alignment | |
| std::string | m_strAltText |
| alternate text for icon(s) | |
| std::string | m_strTagNormal |
| button icon for normal state | |
| std::string | m_strToolTipNormal |
| button tooltip for normal state | |
| std::string | m_strTagActive |
| button icon for active state | |
| std::string | m_strToolTipActive |
| button tooltip for active state | |
Friends | |
| class | WinButtonMenu |
|
inline |
WinButton initialization constructor.
| eType | Button type. |
| nEvent | Event associated with button press (and id). |
| eInitState | Button widget initial state. See GUI Widget State. |
| eAlign | Button alignment. See rnmpwin_align. |
| strAltText | Button alternative text string. |
| strTagNormal | Button visual tag for normal state. Either icon path or text string label. |
| strToolTipNormal | Button tooltip for normal state. |
| strTagActive | Button visual tag for active state. Either icon path or text string label. Empty for no tag. |
| strToolTipActive | Button tooltip for active state. |
Definition at line 115 of file WinMenu.h.
|
inline |
WinButton copy constructor.
| src | Source window button. |
Definition at line 142 of file WinMenu.h.
References copy().
|
protected |
Deep copy of source to this.
| pSrc | Pointer to source button. |
Definition at line 80 of file WinMenu.cxx.
References m_eAlign, m_eInitState, m_eType, m_nEvent, m_strAltText, m_strTagActive, m_strTagNormal, m_strToolTipActive, and m_strToolTipNormal.
Referenced by WinButton().
|
inlinevirtual |
Get the active icon image widget.
Reimplemented in rnr::WinGtkButton.
Definition at line 169 of file WinMenu.h.
References getCurrentImageWidget(), getCurrentLabel(), and getCurrentToolTip().
Referenced by rnr::WinButtonMenu::changeButtonState().
| void * WinButton::getCurrentImageWidget | ( | ) |
Get the icon image widget associated with the current button state.
Definition at line 94 of file WinMenu.cxx.
References rnr::WidgetStateActive, and rnr::WinButtonTypeImage.
Referenced by rnr::WinButtonMenu::bind(), and getActiveImageWidget().
| string WinButton::getCurrentLabel | ( | ) |
Get the text label associated with the current button state.
Definition at line 110 of file WinMenu.cxx.
References rnr::WidgetStateActive, and rnr::WinButtonTypeLabel.
Referenced by rnr::WinButtonMenu::bind(), and getActiveImageWidget().
| string WinButton::getCurrentToolTip | ( | ) |
Get the tooltip associated with the current button state.
Definition at line 126 of file WinMenu.cxx.
References rnr::WidgetStateActive, rnr::WinButtonTypeImage, and rnr::WinButtonTypeLabel.
Referenced by rnr::WinButtonMenu::bind(), and getActiveImageWidget().
|
inlinevirtual |
Get the normal icon image widget.
Reimplemented in rnr::WinGtkButton.
Definition at line 158 of file WinMenu.h.
Referenced by rnr::WinButtonMenu::changeButtonState().