### Godot version

4.2 dev4

### System information

Windows 10.0.19045 - Vulkan (Forward+) - dedicated NVIDIA GeForce GTX 1060 (NVIDIA; 30.0.15.1403) - Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 Threads)

### Issue description

When you have many tabs opened and they are overflowing with the < > buttons, when you switch scene tab it may hide some tabs in specific circumstances:

https://github.com/godotengine/godot/assets/2223172/e5904497-6e3f-48af-815a-3a156ca15018

I'd expect that simply switching to another tab has no effect on visibility.

### Steps to reproduce

1. Open many scene tabs
2. Repeat what I did on the video
May depend on tab names and window size.

### Minimal reproduction project

N/A
switch (p_what) {
		case NOTIFICATION_THEME_CHANGED: {
			tabbar_panel->add_theme_style_override("panel", get_theme_stylebox(SNAME("tabbar_background"), SNAME("TabContainer")));
			scene_tabs->add_theme_constant_override("icon_max_width", get_theme_constant(SNAME("class_icon_size"), EditorStringName(Editor)));
			scene_tab_add->set_icon(get_editor_theme_icon(SNAME("Add")));
			scene_tab_add->add_theme_color_override("icon_normal_color", Color(0.6f, 0.6f, 0.6f, 0.8f));
			scene_tab_add_ph->set_custom_minimum_size(scene_tab_add->get_minimum_size());
		} break;
		case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: {
			scene_tabs->set_tab_close_display_policy((TabBar::CloseButtonDisplayPolicy)EDITOR_GET("interface/scene_tabs/display_close_button").operator int());
			scene_tabs->set_max_tab_width(int(EDITOR_GET("interface/scene_tabs/maximum_width")) * EDSCALE);
		} break;
	}
}
void EditorSceneTabs::_scene_tab_changed(int p_tab) {