diff --git a/tests/inventory_notepad_art_validation.gd b/tests/inventory_notepad_art_validation.gd index cba0797..de76221 100644 --- a/tests/inventory_notepad_art_validation.gd +++ b/tests/inventory_notepad_art_validation.gd @@ -58,6 +58,7 @@ func _run() -> void: )) _validate_shared_inventory_geometry(player_menu) _validate_inventory_layering(player_menu) + _validate_cooler_notepad_typography(player_menu) _validate_resolution_matrix() await _capture_inventory_pages(player_menu) print("Inventory notepad artwork validation: PASS") @@ -128,7 +129,7 @@ func _validate_inventory_layering(player_menu: PlayerMenu) -> void: # The contextual Hotbar uses z=90 while the Player Menu is open. assert(sale_confirmation.z_index > 90) assert(sale_confirmation.position.is_equal_approx(Vector2(380.0, 265.0))) - assert(sale_confirmation.size.is_equal_approx(Vector2(520.0, 190.0))) + assert(sale_confirmation.size.is_equal_approx(Vector2(520.0, 200.0))) var confirmation_style := sale_confirmation.get_theme_stylebox( "panel" ) as StyleBoxFlat @@ -140,6 +141,39 @@ func _validate_inventory_layering(player_menu: PlayerMenu) -> void: ) +func _validate_cooler_notepad_typography(player_menu: PlayerMenu) -> void: + var sort_choice := player_menu.get_node("%CoolerSortOption") as Control + var sort_direction := player_menu.get_node( + "%CoolerSortDirection" + ) as Button + var empty_selection := player_menu.get_node( + "%CoolerSelectionEmpty" + ) as Label + var favorite := player_menu.get_node("%FavoriteBubble") as Button + var sell := player_menu.get_node("%SellBubble") as Button + var sell_all := player_menu.get_node("%SellAllBubble") as Button + assert(sort_choice != null) + assert(sort_direction != null) + assert(empty_selection != null) + assert(favorite != null and sell != null and sell_all != null) + var displayed_value := sort_choice.get_node("%DisplayedValue") as Label + assert(displayed_value != null) + assert(displayed_value.get_theme_font_size("font_size") == 17) + for choice_name: StringName in [ + &"CatchOrderChoice", + &"NameChoice", + &"RarityChoice", + ]: + var choice := sort_choice.get_node("%%%s" % choice_name) as Button + assert(choice != null) + assert(choice.get_theme_font_size("font_size") == 17) + assert(sort_direction.get_theme_font_size("font_size") == 17) + assert(empty_selection.get_theme_font_size("font_size") == 20) + assert(favorite.get_theme_font_size("font_size") == 19) + assert(sell.get_theme_font_size("font_size") == 19) + assert(sell_all.get_theme_font_size("font_size") == 17) + + func _validate_resolution_matrix() -> void: for target_size: Vector2 in TARGET_SIZES: var stage_rect: Rect2 = UIReferencePresentationType.get_rect( diff --git a/ui/player_menu.gd b/ui/player_menu.gd index 6bdc73c..7f73acd 100644 --- a/ui/player_menu.gd +++ b/ui/player_menu.gd @@ -2391,10 +2391,10 @@ func _update_shell_layout() -> void: _cooler_sort_direction.custom_minimum_size = ( Vector2(140.0, 31.0) if compact else Vector2(123.0, 38.0) ) - _cooler_sort_option.set_choice_font_size(12 if compact else 15) + _cooler_sort_option.set_choice_font_size(14 if compact else 17) _cooler_sort_direction.add_theme_font_size_override( "font_size", - 12 if compact else 14, + 14 if compact else 17, ) _notepad_wallet_value.position = ( Vector2(10.0, 33.0) if compact else Vector2(18.0, 61.0) @@ -2472,13 +2472,13 @@ func _update_shell_layout() -> void: Vector2(96.0, 38.0) if compact else Vector2(122.0, 44.0) ) _favorite_bubble.add_theme_font_size_override( - "font_size", 11 if compact else 17, + "font_size", 13 if compact else 19, ) _sell_bubble.add_theme_font_size_override( - "font_size", 11 if compact else 17, + "font_size", 13 if compact else 19, ) _sell_all_bubble.add_theme_font_size_override( - "font_size", 11 if compact else 15, + "font_size", 12 if compact else 17, ) _update_sort_direction_text() _bag_page.size = reference_size @@ -2611,8 +2611,10 @@ func _layout_cooler_selection_text(compact: bool) -> void: _cooler_combined_offer_value.get_amount_label().add_theme_font_size_override( "font_size", 10 if compact else 14 ) + _cooler_selection_empty.add_theme_font_size_override( + "font_size", 14 if compact else 20 + ) for word_label: Label in [ - _cooler_selection_empty, _cooler_selected_count_label, _cooler_combined_offer_label, ]: diff --git a/ui/player_menu.tscn b/ui/player_menu.tscn index b56b57d..e20077c 100644 --- a/ui/player_menu.tscn +++ b/ui/player_menu.tscn @@ -391,7 +391,7 @@ grow_horizontal = 2 grow_vertical = 2 mouse_filter = 2 theme_override_colors/font_color = Color(0.2, 0.18, 0.15, 0.86) -theme_override_font_sizes/font_size = 18 +theme_override_font_sizes/font_size = 20 text = "no fish selected" horizontal_alignment = 1 vertical_alignment = 1