From 1f10d34f8734d2031921ac1c9095e97a3fe0f98d Mon Sep 17 00:00:00 2001 From: Pascal Thomet Date: Wed, 15 May 2024 19:56:10 +0200 Subject: [PATCH] resizable text: min size = 1 --- src/hello_imgui/impl/hello_imgui_widgets.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hello_imgui/impl/hello_imgui_widgets.cpp b/src/hello_imgui/impl/hello_imgui_widgets.cpp index d49c1472..916fbbcf 100644 --- a/src/hello_imgui/impl/hello_imgui_widgets.cpp +++ b/src/hello_imgui/impl/hello_imgui_widgets.cpp @@ -174,6 +174,8 @@ namespace HelloImGui textInput->SizeEm = newSize; else textInput->SizeEm.x = newSize.x; + if (textInput->SizeEm.x < 1.f) + textInput->SizeEm.x = 1.f; if (!labelIsHidden) {