From aa5497c5169fbb5ee415dd02203096e5b9637427 Mon Sep 17 00:00:00 2001 From: hz Date: Sat, 25 Jul 2026 11:00:48 -0500 Subject: [PATCH] Center the legal consent row instead of left-aligning it Wrapped the row in a CenterContainer so the checkbox+text sit centered under the field column instead of hugging the left edge. Had to drop the RichTextLabel's EXPAND_FILL (meaningless inside a CenterContainer, which never stretches its child) in favor of an explicit 480px minimum width - without one, the label collapsed toward zero width and wrapped character-by-character, which is what the first attempt at this actually rendered as before I caught it. Verified with a direct coordinate check: the row's horizontal center now matches the confirm-password field's center exactly (delta 0.0). --- scripts/ui/login_screen.gd | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/scripts/ui/login_screen.gd b/scripts/ui/login_screen.gd index 0ca8ca5..8670cb8 100644 --- a/scripts/ui/login_screen.gd +++ b/scripts/ui/login_screen.gd @@ -364,13 +364,14 @@ func _add_legal_consent(parent: VBoxContainer) -> CheckBox: parent.add_child(check) var margin := MarginContainer.new() - margin.add_theme_constant_override("margin_left", 6) margin.add_theme_constant_override("margin_top", 8) margin.add_theme_constant_override("margin_bottom", 8) parent.add_child(margin) + var center := CenterContainer.new() + margin.add_child(center) var row := HBoxContainer.new() row.add_theme_constant_override("separation", 12) - margin.add_child(row) + center.add_child(row) var square := Panel.new() square.custom_minimum_size = Vector2(20, 20) @@ -391,7 +392,7 @@ func _add_legal_consent(parent: VBoxContainer) -> CheckBox: consent_text.fit_content = true consent_text.scroll_active = false consent_text.meta_underlined = false - consent_text.size_flags_horizontal = Control.SIZE_EXPAND_FILL + consent_text.custom_minimum_size = Vector2(480, 0) consent_text.size_flags_vertical = Control.SIZE_SHRINK_CENTER consent_text.add_theme_font_override("normal_font", Brand.font) consent_text.add_theme_font_size_override("normal_font_size", 13)