From 91918e8cb7d27b02bf4d7687f68f2e7c8fb6f376 Mon Sep 17 00:00:00 2001 From: Haoyu Qiu Date: Tue, 23 Apr 2024 09:41:05 +0800 Subject: [PATCH] Fix TabContainer not updating content rect after changing tab title --- scene/gui/tab_container.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/scene/gui/tab_container.cpp b/scene/gui/tab_container.cpp index 16358ac21f9..c38be955f0a 100644 --- a/scene/gui/tab_container.cpp +++ b/scene/gui/tab_container.cpp @@ -760,10 +760,8 @@ void TabContainer::set_tab_title(int p_tab, const String &p_title) { child->set_meta("_tab_name", p_title); } - _update_margins(); - if (!get_clip_tabs()) { - update_minimum_size(); - } + _repaint(); + queue_redraw(); } String TabContainer::get_tab_title(int p_tab) const {