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

◆ measureText()

Vec2f Flint::UICanvas::measureText ( const std::string & text,
float fontSize,
const std::string & fontName = "",
uint16_t weight = 400 )

Calculates structural spatial dimensions a text block requires before executing layout renders.

Note
Frequently polled by UINode::measure blocks to evaluate dynamic layout budgeting flows.
Returns
A dimensions vector tracking absolute horizontal and vertical pixel bounds.