From 72048aa8f04e447cb893e6cc253c2843ed3230f1 Mon Sep 17 00:00:00 2001 From: torsten Date: Fri, 13 Nov 2026 15:33:25 +0100 Subject: [PATCH] fix: Statusleiste passt auf schmale Tablet-Breiten MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Auf dem Galaxy Tab S9+ (2800x1752 px, DPR 2) ist die logische Breite 1400 Punkte. Die Statusleiste verlangte 1573 Punkte Minimum: Der Text des Status-Labels konnte nicht schrumpfen, also wuchs die gesamte Leiste über den Bildschirm und wurde links und rechts abgeschnitten. - `StatusLabel` darf jetzt kürzen (`clip_text`), statt die Breite vorzugeben; die Leiste kommt damit auf 836 Punkte. - Feste Breiten der drei Auswahlfelder und des Prüf-Knopfs leicht reduziert (Saison 158, Programm 104, Kategorie 146, Prüfen 104). - `_apply_display_scale` stößt nach dem Setzen des Skalierungsfaktors einen verzögerten Layoutdurchlauf an: Die Viewport-Größe ändert sich erst im nächsten Frame, sonst entscheidet das kompakte Layout über die Pixelbreite. Geprüft auf dem Tablet: obere Leiste und Statusleiste vollständig sichtbar (obere Leiste 1391 von 1400 Punkten). Hochformat bleibt offen: Bei 876 Punkten Breite reicht die obere Leiste weiterhin nicht — das ist der Roadmap-Punkt "obere Leiste umbruchfähig". --- rinkplanner/scenes/whiteboard/whiteboard.tscn | 9 +++++---- rinkplanner/src/whiteboard/ctrl/whiteboard_controller.gd | 4 ++++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/rinkplanner/scenes/whiteboard/whiteboard.tscn b/rinkplanner/scenes/whiteboard/whiteboard.tscn index 130ee74..2aa0d66 100644 --- a/rinkplanner/scenes/whiteboard/whiteboard.tscn +++ b/rinkplanner/scenes/whiteboard/whiteboard.tscn @@ -769,6 +769,7 @@ theme_override_constants/separation = 6 unique_name_in_owner = true layout_mode = 2 size_flags_horizontal = 3 +clip_text = true theme_override_colors/font_color = Color(0.580392, 0.639216, 0.721569, 1) theme_override_font_sizes/font_size = 15 text = "Abschnitt 1 · 0 Segmente" @@ -784,25 +785,25 @@ tooltip_text = "Hilfe und Annahmen" [node name="SeasonOption" type="OptionButton" parent="Layout/StatusBar/StatusBarContent"] unique_name_in_owner = true -custom_minimum_size = Vector2(190, 48) +custom_minimum_size = Vector2(158, 48) layout_mode = 2 theme_override_font_sizes/font_size = 15 [node name="ProgramOption" type="OptionButton" parent="Layout/StatusBar/StatusBarContent"] unique_name_in_owner = true -custom_minimum_size = Vector2(120, 48) +custom_minimum_size = Vector2(104, 48) layout_mode = 2 theme_override_font_sizes/font_size = 15 [node name="AdultCategoryOption" type="OptionButton" parent="Layout/StatusBar/StatusBarContent"] unique_name_in_owner = true -custom_minimum_size = Vector2(170, 48) +custom_minimum_size = Vector2(146, 48) layout_mode = 2 theme_override_font_sizes/font_size = 15 [node name="ValidationButton" type="Button" parent="Layout/StatusBar/StatusBarContent"] unique_name_in_owner = true -custom_minimum_size = Vector2(120, 48) +custom_minimum_size = Vector2(104, 48) layout_mode = 2 theme_override_font_sizes/font_size = 15 text = "Prüfen" diff --git a/rinkplanner/src/whiteboard/ctrl/whiteboard_controller.gd b/rinkplanner/src/whiteboard/ctrl/whiteboard_controller.gd index 0f11611..0253195 100644 --- a/rinkplanner/src/whiteboard/ctrl/whiteboard_controller.gd +++ b/rinkplanner/src/whiteboard/ctrl/whiteboard_controller.gd @@ -5574,6 +5574,10 @@ func _apply_display_scale() -> void: var factor := maxf(1.0, DisplayServer.screen_get_scale()) if not is_equal_approx(window.content_scale_factor, factor): window.content_scale_factor = factor + # The viewport size changes with the scale factor, but only after the + # next frame. Without the deferred pass the compact layout would be + # decided from the pixel width and the bars would overflow on tablets. + _apply_responsive_layout.call_deferred() func _apply_responsive_layout() -> void: