From 592f3f3f25f00232234399f4c5f51318a3fa49d2 Mon Sep 17 00:00:00 2001 From: crupest Date: Sat, 29 Jan 2022 22:09:29 +0800 Subject: ... --- src/ui/controls/RootControl.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/ui/controls/RootControl.cpp') diff --git a/src/ui/controls/RootControl.cpp b/src/ui/controls/RootControl.cpp index 7edf4a1d..a7366155 100644 --- a/src/ui/controls/RootControl.cpp +++ b/src/ui/controls/RootControl.cpp @@ -3,6 +3,7 @@ #include "cru/common/Base.hpp" #include "cru/platform/gui/Base.hpp" #include "cru/platform/gui/Window.hpp" +#include "cru/ui/Base.hpp" #include "cru/ui/host/WindowHost.hpp" #include "cru/ui/render/Base.hpp" #include "cru/ui/render/StackLayoutRenderObject.hpp" @@ -15,6 +16,8 @@ RootControl::RootControl(Control* attached_control) : attached_control_(attached_control) { render_object_ = std::make_unique(); render_object_->SetAttachedControl(this); + render_object_->SetDefaultHorizontalAlignment(Alignment::Stretch); + render_object_->SetDefaultVertialAlignment(Alignment::Stretch); SetContainerRenderObject(render_object_.get()); window_host_ = std::make_unique(this); } -- cgit v1.2.3