14namespace hi {
inline namespace v1 {
101 different_from<std::shared_ptr<delegate_type>> Value,
102 forward_of<observer<observer_decay_t<Value>>> OnValue,
103 button_widget_attribute... Attributes>
131 different_from<std::shared_ptr<delegate_type>> Value,
132 forward_of<observer<observer_decay_t<Value>>> OnValue,
133 forward_of<observer<observer_decay_t<Value>>> OffValue,
134 button_widget_attribute... Attributes>
140 OffValue&& off_value,
141 Attributes&&...attributes)
noexcept requires requires
156 void draw(draw_context const& context) noexcept override;
159 extent2 _button_size;
160 aarectangle _button_rectangle;
161 glyph_ids _check_glyph;
162 aarectangle _check_glyph_rectangle;
163 glyph_ids _minus_glyph;
164 aarectangle _minus_glyph_rectangle;
166 void draw_check_box(draw_context const& context) noexcept;
167 void draw_check_mark(draw_context const& context) noexcept;
#define hi_forward(x)
Forward a value, based on the decltype of the value.
Definition utility.hpp:29
Defines abstract_button_widget.
std::shared_ptr< button_delegate > make_default_toggle_button_delegate(auto &&value, auto &&...args) noexcept
Make a shared pointer to a toggle-button delegate.
Definition button_delegate.hpp:245
DOXYGEN BUG.
Definition algorithm.hpp:15
The HikoGUI namespace.
Definition ascii.hpp:19
Base class for implementing button widgets.
Definition abstract_button_widget.hpp:32
std::shared_ptr< delegate_type > delegate
The delegate that controls the button widget.
Definition abstract_button_widget.hpp:39
observer< alignment > alignment
The alignment of the button and on/off/other label.
Definition abstract_button_widget.hpp:55
A button delegate controls the state of a button widget.
Definition button_delegate.hpp:45
A GUI widget that permits the user to make a binary choice.
Definition checkbox_widget.hpp:42
checkbox_widget(gui_window &window, widget *parent, Value &&value, OnValue &&on_value, OffValue &&off_value, Attributes &&...attributes) noexcept
Construct a checkbox widget with a default button delegate.
Definition checkbox_widget.hpp:135
checkbox_widget(gui_window &window, widget *parent, std::shared_ptr< delegate_type > delegate, button_widget_attribute auto &&...attributes) noexcept
Construct a checkbox widget.
Definition checkbox_widget.hpp:57
checkbox_widget(gui_window &window, widget *parent, Value &&value, OnValue &&on_value, Attributes &&...attributes) noexcept
Construct a checkbox widget with a default button delegate.
Definition checkbox_widget.hpp:104
checkbox_widget(gui_window &window, widget *parent, different_from< std::shared_ptr< delegate_type > > auto &&value, button_widget_attribute auto &&...attributes) noexcept
Construct a checkbox widget with a default button delegate.
Definition checkbox_widget.hpp:79
An interactive graphical object as part of the user-interface.
Definition widget.hpp:44
widget_layout const & layout() const noexcept
Get the current layout for this widget.
Definition widget.hpp:198
widget *const parent
Pointer to the parent widget.
Definition widget.hpp:53
gui_window & window
Convenient reference to the Window.
Definition widget.hpp:48
The constraints of a widget.
Definition widget_constraints.hpp:26
The layout of a widget.
Definition widget_layout.hpp:37
Definition abstract_button_widget.hpp:26