 |
Gorgon Game Engine
|
Go to the documentation of this file.
3 #include "../UI/ComponentStackWidget.h"
4 #include "../Property.h"
6 #include "../Graphics/Bitmap.h"
10 namespace Gorgon {
namespace Widgets {
41 void SetText(
const std::string &value);
81 return icon !=
nullptr;
88 throw std::runtime_error(
"This widget has no icon.");
169 bool ownicon =
false;
173 bool selected =
false;
@ Last
In a list this denotes the item is at the last place.
Definition: Template.h:239
@ First
In a list this denotes the item is at the first place.
Definition: Template.h:233
@ Even
In lists denotes the item is in even position.
Definition: Template.h:230
@ Icon
Data will effect the displayed graphics.
Definition: Template.h:678
void SetData(ComponentTemplate::DataEffect effect, const std::string &text)
Sets the data for a specific data effect.
Definition: ComponentStack.cpp:725
This class provides event mechanism.
Definition: Event.h:134
ItemPosition
Defines where an item is located in a list.
Definition: Types.h:158
A regular drawable animation provider.
Definition: Animations.h:28
int ComponentAt(Geometry::Point location)
Returns the index of the component at the given location.
Definition: ComponentStack.h:339
This class stores visual information about a widget template.
Definition: Template.h:392
@ Odd
In lists denotes the item is in odd position.
Definition: Template.h:227
@ Opened
This condition is triggered when the widget is opened like a combobox showing its list part.
Definition: Template.h:213
@ ToggleTag
Definition: Template.h:871
@ Closed
This condition is triggered when the widget is closed like a tree view item that is folded,...
Definition: Template.h:220
void RemoveCondition(ComponentCondition condition, bool transition=true)
Removes a condition and its associated components.
Definition: ComponentStack.h:54
void RemoveData(ComponentTemplate::DataEffect effect)
Removes the data associated with data effect.
Definition: ComponentStack.cpp:759
@ Text
Works only for TextholderTemplate, data will affect the text that is displayed.
Definition: Template.h:651
Root namespace for Gorgon Game Engine.
Definition: Any.h:19
@ Last
Item is the last item.
virtual Animation & CreateAnimation(Gorgon::Animation::ControllerBase &timer) const override=0
This function should create a new animation with the given controller and if owner parameter is set t...
This object contains an bitmap image.
Definition: Bitmap.h:25
int IndexOfTag(ComponentTemplate::Tag tag)
Returns the index of the component with the specified tag.
Definition: ComponentStack.cpp:1437
virtual void DeleteAnimation() const
Deletes this animation.
Definition: Animation.h:379
void AddCondition(ComponentCondition condition, bool transition=true)
Adds a condition and its associated components to the stack.
Definition: ComponentStack.h:48
void SetClickEvent(std::function< void(ComponentTemplate::Tag, Geometry::Point, Input::Mouse::Button)> handler)
Sets the mouse down event.
Definition: ComponentStack.h:490
A regular drawable animation.
Definition: Animations.h:14
@ State2
Second state of the widget, first state is Always.
Definition: Template.h:201
@ NoTag
Definition: Template.h:851
YesNoUnset
This enumeration helps with systems that has boolen parameters that can be unset/empty.
Definition: Types.h:63
@ First
Item is the first item.
Parity
Marks the parity as Odd or Even.
Definition: Types.h:151
const Template & GetTemplate() const
Returns the template used by this stack.
Definition: ComponentStack.h:256
void HandleMouse(Input::Mouse::Button accepted=Input::Mouse::Button::All)
This function instructs stack to handle mouse to automatically change hover/down states,...
Definition: ComponentStack.cpp:1023
@ Alone
In a list this denotes the item alone.
Definition: Template.h:242