Show Japanese text and close the gap in the top bar
Build / test (push) Successful in 35s
Build / build (push) Successful in 1m12s

Godot's built-in font has no Japanese, so kanji in song names showed as
boxes. The theme now sets Godot's own Open Sans SemiBold as its default
font, with Noto Sans JP Medium as fallback. The Noto file's line metrics
are set to Open Sans's, so line heights stay the same and every other
screen is pixel-identical; fonts/README.md explains how to redo it.

Search and Sync move right to where the Statistics button was.
This commit is contained in:
Sansan committed 2026-10-06 23:57:37 +02:00
1 parent a21b6e9b22
commit b40b160fde
13 files changed
+325 -15

No files matched your search

+16
View File
@@ -119,3 +119,19 @@ func test_main_window_background_comes_from_the_theme_and_lets_clicks_through()
assert_int(background.mouse_filter).is_equal(Control.MOUSE_FILTER_IGNORE)
assert_float(background.anchor_right).is_equal(1.0)
assert_float(background.anchor_bottom).is_equal(1.0)
func test_default_font_shows_japanese() -> void:
var font: Font = _theme.default_font
for character: String in "幕開けミッション":
var found: bool = font.fallbacks.any(
func(fallback: Font) -> bool: return fallback.has_char(character.unicode_at(0)))
assert_bool(found).override_failure_message("No font has " + character).is_true()
func test_japanese_fallback_keeps_the_line_height_of_godots_font() -> void:
var builtin: Font = ThemeDB.get_default_theme().default_font
for size: int in [16, 18, 20, 25, 35, 50]:
assert_float(_theme.default_font.get_height(size)) \
.override_failure_message("Line height at size %d" % size) \
.is_equal(builtin.get_height(size))