diff --git a/editor/scene/3d/node_3d_editor_plugin.cpp b/editor/scene/3d/node_3d_editor_plugin.cpp index aac34bd6912..657892cee61 100644 --- a/editor/scene/3d/node_3d_editor_plugin.cpp +++ b/editor/scene/3d/node_3d_editor_plugin.cpp @@ -3433,11 +3433,6 @@ void Node3DEditorViewport::_notification(int p_what) { frame_time_gradient->get_color_at_offset( Math::remap(fps, 110, 10, 0, 1))); } - - if (lock_rotation) { - float locked_half_width = locked_label->get_size().width / 2.0f; - locked_label->set_anchor_and_offset(SIDE_LEFT, 0.5f, -locked_half_width); - } } break; case NOTIFICATION_PHYSICS_PROCESS: { @@ -4306,6 +4301,12 @@ void Node3DEditorViewport::_update_centered_labels() { float cinema_half_width = cinema_label->get_size().width / 2.0f; cinema_label->set_anchor_and_offset(SIDE_LEFT, 0.5f, -cinema_half_width); } + + if (locked_label->is_visible()) { + locked_label->reset_size(); + float locked_half_width = locked_label->get_size().width / 2.0f; + locked_label->set_anchor_and_offset(SIDE_LEFT, 0.5f, -locked_half_width); + } } void Node3DEditorViewport::_init_gizmo_instance(int p_idx) {