From 35441fda1b7ea166b38ce76d9f817b9c367d8b00 Mon Sep 17 00:00:00 2001 From: Mikael Hermansson Date: Wed, 3 Dec 2025 12:32:35 +0100 Subject: [PATCH] Fix truncation of node name in bezier animation editor --- editor/animation/animation_bezier_editor.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/editor/animation/animation_bezier_editor.cpp b/editor/animation/animation_bezier_editor.cpp index b1eced534a2..5c97d735f51 100644 --- a/editor/animation/animation_bezier_editor.cpp +++ b/editor/animation/animation_bezier_editor.cpp @@ -430,18 +430,15 @@ void AnimationBezierTrackEdit::_notification(int p_what) { node = root->get_node(path); } - String text; - if (node) { - int ofs = 0; + int ofs = h_separation; Ref icon = EditorNode::get_singleton()->get_object_icon(node); - text = node->get_name(); - ofs += h_separation; - - TextLine text_buf = TextLine(text, font, font_size); - text_buf.set_width(limit - ofs - icon->get_width() - h_separation); + TextLine text_buf = TextLine(node->get_name(), font, font_size); + int total_icon_width = icon->get_width() + solo->get_width() + visibility_visible->get_width() + lock->get_width() + remove->get_width(); + int total_icon_separation = h_separation * 5; + text_buf.set_width(limit - ofs - total_icon_width - total_icon_separation); int h = MAX(text_buf.get_size().y, icon->get_height());