Flint Engine
Modular C++20 2D game engine powered by SDL3
Loading...
Searching...
No Matches
Flint::UIConstraints Struct Reference

Represents the boundary budget passed down the node tree during layout allocation. More...

#include <flint/ui/ui-types.h>

+ Collaboration diagram for Flint::UIConstraints:

Public Attributes

Vec2f minSize {}
 
Vec2f maxSize {}
 
float scale = 1.f
 
UICanvas * canvas
 

Detailed Description

Represents the boundary budget passed down the node tree during layout allocation.

Note
Created by the context root and modified by parent containers before measuring children.
See also
UINode::measure, UIPanel::measure, UIButton::measure, UILabel::measure

Definition at line 76 of file ui-types.h.

Member Data Documentation

◆ canvas

UICanvas* Flint::UIConstraints::canvas
Initial value:
=
nullptr

Optional context pointer required for font/string pixel measurement.

Definition at line 81 of file ui-types.h.

◆ maxSize

Vec2f Flint::UIConstraints::maxSize {}

Maximum layout dimensions a node is allowed to occupy.

Definition at line 78 of file ui-types.h.

◆ minSize

Vec2f Flint::UIConstraints::minSize {}

Minimum layout dimensions a node must occupy.

Definition at line 77 of file ui-types.h.

◆ scale

float Flint::UIConstraints::scale = 1.f

Global UI display scale factor used for DPI/resolution scaling.

Definition at line 79 of file ui-types.h.


The documentation for this struct was generated from the following file: