Class: widget::Button
Synopsis:
+ static void init (ewol::WidgetManager & _widgetManager);
+ Button (const std::string & _shaperName);
+ ~Button (void);
+ void setShaperName (const std::string & _shaperName);
+ void setSubWidget (ewol::Widget * _subWidget);
+ void setSubWidgetToggle (ewol::Widget * _subWidget);
+ ewol::Widget * getSubWidget (void);
+ ewol::Widget * getSubWidgetToggle (void);
+ void setValue (bool _val);
+ bool getValue (void);
+ void setLock (enum buttonLock _lock);
+ void setToggleMode (bool _togg);
+ bool getToggleMode (void);
+ void calculateMinMaxSize (void);
+ void calculateSize (const vec2 & _availlable);
+ void onRegenerateDisplay (void);
+ void systemDraw (const ewol::DrawProperty & _displayProp);
+ bool onEventInput (const ewol::EventInput & _event);
+ bool onEventEntry (const ewol::EventEntry & _event);
+ bool loadXML (exml::Element * _node);
+ ewol::Widget * getWidgetNamed (const std::string & _widgetName);
# void onDraw (void);
# bool onSetConfig (const ewol::EConfig & _conf);
# bool onGetConfig (const char * _config,
std::string & _result);
- void changeStatusIn (int32_t _newStatusId);
- void CheckStatus (void);
- void periodicCall (const ewol::EventTime & _event);
Object Hierarchy:
ewol::EObject +--> ewol::Widget +--> widget::Button
Description:
/** * @ingroup ewolWidgetGroup * @brief a composed button is a button with an inside composed with the specify XML element == > this permit to generate standard element simple */Detail:
widget::init ()
static void init(ewol::WidgetManager & _widgetManager);
widget::Button ()
Button(const std::string & _shaperName);
Constructor
Parameter [input]: _shaperName Shaper file properties
widget::~Button ()
~Button(void);
Destructor
setShaperName ()
void setShaperName(const std::string & _shaperName);
set the shaper name (use the contructer one this permit to not noad unused shaper)
Parameter [input]: _shaperName The new shaper filename
setSubWidget ()
void setSubWidget(ewol::Widget * _subWidget);
Specify the current widget
Parameter [input]: _subWidget Widget to add normal
setSubWidgetToggle ()
void setSubWidgetToggle(ewol::Widget * _subWidget);
Specify the current widget
Parameter [input]: _subWidget Widget to add Toggle
getSubWidget ()
ewol::Widget * getSubWidget(void);
get the current displayed composition
Return: The base widget
getSubWidgetToggle ()
ewol::Widget * getSubWidgetToggle(void);
get the current displayed composition
Return: The toggle widget
setValue ()
void setValue(bool _val);
set the currentValue of the Button (pressed or not)
Notes: Work only in toggle mode
Parameter [input]: _val New value of the button
getValue ()
bool getValue(void);
get the current button value.
Return: True : The button is pressed.
Return: false : The button is released.
setLock ()
void setLock(enum buttonLock _lock);
set the button lock state.
Parameter [input]: _lock New lock mode of the button
setToggleMode ()
void setToggleMode(bool _togg);
change the toggle mode.
Parameter [input]: _togg New toggle mode
getToggleMode ()
bool getToggleMode(void);
get the current toggle mode.
Return: the current toggle mode.
calculateMinMaxSize ()
void calculateMinMaxSize(void);
calculateSize ()
void calculateSize(const vec2 & _availlable);
onRegenerateDisplay ()
void onRegenerateDisplay(void);
systemDraw ()
void systemDraw(const ewol::DrawProperty & _displayProp);
onEventInput ()
bool onEventInput(const ewol::EventInput & _event);
onEventEntry ()
bool onEventEntry(const ewol::EventEntry & _event);
loadXML ()
bool loadXML(exml::Element * _node);
getWidgetNamed ()
ewol::Widget * getWidgetNamed(const std::string & _widgetName);
onDraw ()
void onDraw(void);
onSetConfig ()
bool onSetConfig(const ewol::EConfig & _conf);
onGetConfig ()
bool onGetConfig(const char * _config,
std::string & _result);
changeStatusIn ()
void changeStatusIn(int32_t _newStatusId);
internal system to change the property of the current status
Parameter [input]: _newStatusId new state
CheckStatus ()
void CheckStatus(void);
update the status with the internal satte of the button ...
periodicCall ()
void periodicCall(const ewol::EventTime & _event);
widget::init ()
static void init(ewol::WidgetManager & _widgetManager);
widget::Button ()
Button(const std::string & _shaperName);
Constructor
-
Parameter [input]: _shaperName Shaper file properties
widget::~Button ()
~Button(void);
Destructor
setShaperName ()
void setShaperName(const std::string & _shaperName);
set the shaper name (use the contructer one this permit to not noad unused shaper)
-
Parameter [input]: _shaperName The new shaper filename
setSubWidget ()
void setSubWidget(ewol::Widget * _subWidget);
Specify the current widget
-
Parameter [input]: _subWidget Widget to add normal
setSubWidgetToggle ()
void setSubWidgetToggle(ewol::Widget * _subWidget);
Specify the current widget
-
Parameter [input]: _subWidget Widget to add Toggle
getSubWidget ()
ewol::Widget * getSubWidget(void);
get the current displayed composition
-
Return: The base widget
getSubWidgetToggle ()
ewol::Widget * getSubWidgetToggle(void);
get the current displayed composition
-
Return: The toggle widget
setValue ()
void setValue(bool _val);
set the currentValue of the Button (pressed or not)
Notes: Work only in toggle mode
-
Parameter [input]: _val New value of the button
getValue ()
bool getValue(void);
get the current button value.
-
Return: True : The button is pressed.
Return: false : The button is released.
setLock ()
void setLock(enum buttonLock _lock);
set the button lock state.
-
Parameter [input]: _lock New lock mode of the button
setToggleMode ()
void setToggleMode(bool _togg);
change the toggle mode.
-
Parameter [input]: _togg New toggle mode
getToggleMode ()
bool getToggleMode(void);
get the current toggle mode.
-
Return: the current toggle mode.
calculateMinMaxSize ()
void calculateMinMaxSize(void);
calculateSize ()
void calculateSize(const vec2 & _availlable);
onRegenerateDisplay ()
void onRegenerateDisplay(void);
systemDraw ()
void systemDraw(const ewol::DrawProperty & _displayProp);
onEventInput ()
bool onEventInput(const ewol::EventInput & _event);
onEventEntry ()
bool onEventEntry(const ewol::EventEntry & _event);
loadXML ()
bool loadXML(exml::Element * _node);
getWidgetNamed ()
ewol::Widget * getWidgetNamed(const std::string & _widgetName);
onDraw ()
void onDraw(void);
onSetConfig ()
bool onSetConfig(const ewol::EConfig & _conf);
onGetConfig ()
bool onGetConfig(const char * _config, std::string & _result);
changeStatusIn ()
void changeStatusIn(int32_t _newStatusId);
internal system to change the property of the current status
-
Parameter [input]: _newStatusId new state
CheckStatus ()
void CheckStatus(void);
update the status with the internal satte of the button ...
periodicCall ()
void periodicCall(const ewol::EventTime & _event);