15#include <egt/animation.h>
16#include <egt/detail/meta.h>
17#include <egt/easing.h>
18#include <egt/window.h>
38 constexpr static const int HANDLE_WIDTH = 50;
64 std::chrono::milliseconds open_duration = std::chrono::milliseconds(1000),
66 std::chrono::milliseconds close_duration = std::chrono::milliseconds(1000),
67 EasingFunc close_func = easing_circular_easeinout,
Abstract base serializer class.
Definition serialize.h:34
std::list< std::tuple< std::string, std::string, Serializer::Attributes > > Properties
Definition serialize.h:47
SideBoard Window for a sliding board that slides on and off the screen.
Definition sideboard.h:34
void reset_animations()
Reset animation start/end values.
PropertyAnimator m_oanim
Open animation.
Definition sideboard.h:121
void position(PositionFlag position)
Set the position of the SideBoard.
void close()
Move to a closed state.
SideBoard(PositionFlag position, WindowHint hint)
void serialize(Serializer &serializer) const override
Serialize the widget to the specified serializer.
SideBoard(Serializer::Properties &props) noexcept
Definition sideboard.h:81
void open()
Move to an open state.
PositionFlag
Position flag of the SideBoard.
Definition sideboard.h:42
SideBoard(PositionFlag position=PositionFlag::left, std::chrono::milliseconds open_duration=std::chrono::milliseconds(1000), EasingFunc open_func=easing_cubic_easeinout, std::chrono::milliseconds close_duration=std::chrono::milliseconds(1000), EasingFunc close_func=easing_circular_easeinout, WindowHint hint=WindowHint::automatic)
void handle(Event &event) override
Handle an event.
EGT_NODISCARD PositionFlag position() const
Get the position of the SideBoard.
Definition sideboard.h:102
SideBoard(Serializer::Properties &props, bool is_derived) noexcept
PropertyAnimator m_canim
Close animation.
Definition sideboard.h:124
A Window is a Widget that handles drawing to a Screen.
Definition window.h:47
std::function< EasingScalar(EasingScalar percent)> EasingFunc
Easing function type.
Definition animation.h:41
WindowHint
Hint used for configuring Window backends.
Definition widgetflags.h:683
T & top(T &widget)
Helper to set alignment of a widget.
Definition widgetflags.h:494
T & right(T &widget)
Helper to set alignment of a widget.
Definition widgetflags.h:468
T & left(T &widget)
Helper to set alignment of a widget.
Definition widgetflags.h:442
EGT_API std::ostream & operator<<(std::ostream &os, const Color &color)
Overloaded std::ostream insertion operator.
T & bottom(T &widget)
Helper to set alignment of a widget.
Definition widgetflags.h:520
EGT framework namespace.
Definition animation.h:24
A single event that has information about the event and state for the event.
Definition event.h:255