12#include "../geometry/axis.hpp"
15namespace hi {
inline namespace v1 {
19template<
typename Context>
32 observer<label> title;
57 [[nodiscard]] axis resize_axis() const noexcept
60 if (_constraints.minimum.width() != _constraints.maximum.width()) {
63 if (_constraints.minimum.height() != _constraints.maximum.height()) {
70 [[nodiscard]] generator<widget *> children() const noexcept override;
73 void draw(draw_context const& context) noexcept override;
74 [[nodiscard]] hitbox hitbox_test(point3 position) const noexcept override;
75 bool handle_event(
gui_event const& event) noexcept override;
76 bool process_event(
gui_event const& event) const noexcept override;
81 aarectangle _content_rectangle;
84 aarectangle _toolbar_rectangle;
89 void set_attributes() noexcept {}
90 void set_attributes(window_widget_attribute
auto&& first, window_widget_attribute
auto&&...rest)
noexcept
92 if constexpr (forward_of<
decltype(first), observer<hi::label>>) {
#define hi_static_no_default()
This part of the code should not be reachable, unless a programming bug.
Definition assert.hpp:172
#define hi_forward(x)
Forward a value, based on the decltype of the value.
Definition utility.hpp:29
Functionality for labels, text and icons.
DOXYGEN BUG.
Definition algorithm.hpp:15
The HikoGUI namespace.
Definition ascii.hpp:19
A user interface event.
Definition gui_event.hpp:76
A GUI widget that lays out child-widgets in a grid with variable sized cells.
Definition grid_widget.hpp:40
Definition set_constraints_context.hpp:15
A toolbar widget is located at the top of a window and lays out its children horizontally.
Definition toolbar_widget.hpp:35
An interactive graphical object as part of the user-interface.
Definition widget.hpp:45
widget(widget *parent) noexcept
The constraints of a widget.
Definition widget_constraints.hpp:26
The layout of a widget.
Definition widget_layout.hpp:40
The top-level window widget.
Definition window_widget.hpp:28
grid_widget & content() noexcept
Get a reference to the window's content widget.
toolbar_widget & toolbar() noexcept
Get a reference to window's toolbar widget.
color background_color() noexcept
The background color of the window.
Definition window_widget.hpp:20