Fixed a sizing issue in FlexboxComponent.

This commit is contained in:
Leon Styhre 2021-10-05 17:59:44 +02:00
parent 714be4b52a
commit 3ff5f90f36

View file

@ -173,7 +173,7 @@ void FlexboxComponent::applyTheme(const std::shared_ptr<ThemeData>& theme,
mItemMargin = elem->get<glm::vec2>("itemMargin"); mItemMargin = elem->get<glm::vec2>("itemMargin");
if (elem->has("itemWidth")) if (elem->has("itemWidth"))
mItemWidth = elem->get<float>("itemWidth") * scale.x; mItemWidth = floorf(elem->get<float>("itemWidth") * scale.x);
GuiComponent::applyTheme(theme, view, element, properties); GuiComponent::applyTheme(theme, view, element, properties);