Skip to content

ATextBase#

Base class for AText without public APIs.

Header:#include <AUI/View/ATextBase.h>
CMake:aui_link(my_target PUBLIC aui::views)

Public Methods#

measureLayoutForWidth#


AOptional<glm::ivec2> ATextBase::measureLayoutForWidth(int width)

Lays the text out for the given width without writing positions, reporting the space it occupies.

shrinksToOccupiedWidth#


virtual bool ATextBase::shrinksToOccupiedWidth()

Whether this view may report less than the width it was offered, when the text does not fill it.

Editable views want to keep the whole width: clicking to the right of the last character must still hit them.