4#ifndef FTXUI_COMPONENT_COMPONENT_OPTIONS_HPP
5#define FTXUI_COMPONENT_COMPONENT_OPTIONS_HPP
38 animation::easing::QuadraticInOut;
40 animation::easing::QuadraticInOut;
61 animation::easing::Function
function = animation::easing::QuadraticInOut);
67 animation::easing::Function
function = animation::easing::QuadraticInOut;
A class representing terminal colors.
An adapter. Own or reference an immutable object.
An adapter. Reference a list of strings.
An adapter. Own or reference a constant string. For convenience, this class convert multiple immutabl...
An adapter. Own or reference an mutable object.
An adapter. Own or reference a constant string. For convenience, this class convert multiple mutable ...
std::chrono::duration< float > Duration
bool active
< The state of the button/checkbox/radiobox
Ref< bool > resize_down
< Can the top side be resized?
Ref< bool > resize_left
< The height of the window.
AnimatedColorOption foreground
bool drag
< Whether the window is the active one.
std::function< Element()> separator_func
std::shared_ptr< Node > Element
bool focused
< Whether the entry is the active one.
bool hover_down
< Whether the resizeable top side is hovered.
std::shared_ptr< ComponentBase > Component
const std::string & title
< The element wrapped inside this window.
Ref< int > height
< The width of the window.
bool resize
< Whether the window is being dragged.
AnimatedColorOption background
std::function< Element(const EntryState &state)> transform
Ref< bool > resize_top
< Can the right side be resized?
bool hover_right
< Whether the resizeable left side is hovered.
Ref< int > width
< The top side position of the window.
Component Slider(SliderOption< T > options)
A slider in any direction.
std::function< Element(const WindowRenderState &)> render
< Can the down side be resized?
bool is_placeholder
< Whether the input is focused by the user.
bool state
< The label to display.
AnimatedColorsOption animated_colors
ConstStringRef title
< The component wrapped by this window.
Ref< bool > resize_right
< Can the left side be resized?
bool hover_left
< Whether the window is being resized.
bool hover_top
< Whether the resizeable right side is hovered.
Ref< int > left
< The title displayed by this window.
Ref< Direction > direction
Ref< int > top
< The left side position of the window.
Decorator color(Color)
Decorate using a foreground color.
arguments for |ButtonOption::transform|, |CheckboxOption::transform|, |Radiobox::transform|,...
Option about a potentially animated color.
animation::easing::Function function
animation::Duration duration
void Set(Color inactive, Color active, animation::Duration duration=std::chrono::milliseconds(250), animation::easing::Function function=animation::easing::QuadraticInOut)
A color option that can be animated. @params _inactive The color when the component is inactive....
Option for the Checkbox component.
static CheckboxOption Simple()
Option for standard Checkbox.
std::function< void()> on_change
Called when the user change the state.
std::function< Element(const EntryState &)> transform
Option for the Radiobox component.
ConstStringListRef entries
std::function< void()> on_change
Called when the selected entry changes.
static RadioboxOption Simple()
Option for standard Radiobox.
std::function< Element(const EntryState &)> transform
animation::Duration follower_duration
animation::easing::Function leader_function
animation::Duration follower_delay
void SetAnimationFunction(animation::easing::Function f)
Set how the underline should animate.
animation::Duration leader_duration
void SetAnimation(animation::Duration d, animation::easing::Function f)
Set how the underline should animate.
void SetAnimationDuration(animation::Duration d)
Set how the underline should animate.
animation::easing::Function follower_function
animation::Duration leader_delay