From 22303c62ff038c51e3e40b312412c1b4d036a796 Mon Sep 17 00:00:00 2001 From: funman300 Date: Mon, 11 May 2026 22:00:58 -0700 Subject: [PATCH] fix(android): replace non-FiraMono HUD glyphs with safe Unicode alternatives MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ⏸ (U+23F8), ★ (U+2605), ⚙ (U+2699) are absent from FiraMono and rendered as boxes on device. Replace with ← ‖ → ▾ which all fall within FiraMono's covered blocks (Basic Latin + Arrows + General Punctuation + Geometric Shapes). Co-Authored-By: Claude Sonnet 4.6 --- solitaire_engine/src/hud_plugin.rs | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/solitaire_engine/src/hud_plugin.rs b/solitaire_engine/src/hud_plugin.rs index 454bf43..771ef07 100644 --- a/solitaire_engine/src/hud_plugin.rs +++ b/solitaire_engine/src/hud_plugin.rs @@ -626,11 +626,16 @@ fn spawn_action_buttons( mut commands: Commands, ) { let top_inset = insets.as_deref().copied().unwrap_or_default().top; + #[cfg(not(target_os = "android"))] let font = TextFont { font: font_res.as_ref().map(|f| f.0.clone()).unwrap_or_default(), font_size: TYPE_BODY, ..default() }; + // Android labels use only FiraMono-safe glyphs (≡ ← ‖ → ▾), so the same + // embedded font works — no system font fallback required. + #[cfg(target_os = "android")] + let font = TextFont { font_size: TYPE_BODY, ..default() }; // On Android, 7 text-labelled buttons at 48 dp each wrap to two rows on // a 411 dp phone. Use compact Unicode symbols and tighter gaps so all 7 @@ -645,12 +650,12 @@ fn spawn_action_buttons( #[cfg(target_os = "android")] let labels = ( - /* menu */ "\u{2261}", // ≡ hamburger - /* undo */ "\u{21A9}", // ↩ undo arrow - /* pause */ "\u{23F8}", // ⏸ pause symbol + /* menu */ "\u{2261}", // ≡ identical-to (hamburger look-alike, in FiraMono) + /* undo */ "\u{2190}", // ← leftwards arrow (in FiraMono) + /* pause */ "\u{2016}", // ‖ double vertical line (in FiraMono general-punct) /* help */ "?", - /* hint */ "\u{2605}", // ★ star - /* modes */ "\u{2699}\u{25BE}", // ⚙▾ gear+chevron + /* hint */ "\u{2192}", // → rightwards arrow (in FiraMono) + /* modes */ "\u{25BE}", // ▾ small down-pointing triangle (in FiraMono) /* new */ "+", ); #[cfg(not(target_os = "android"))]