From 5c683b3e91bc3e8c3db3efc755c9a57b6d3298fd Mon Sep 17 00:00:00 2001 From: blasty Date: Fri, 24 Jul 2026 16:07:51 +0200 Subject: ux: omit the splash logo when the terminal is too small for it The logo.ans art is 33 rows tall; on a short/narrow terminal the auto-height loading box would overflow and clip both the art and the title/note/help (center-aligned, so the useful text scrolls off top and bottom). LoadingScreen now only mounts the logo when app.size fits it plus the chrome (height >= lines+9 and width >= 64); otherwise it falls back to the text-only overlay. Verified across sizes: 90x44 -> shown, 90x30 -> omitted (too short), 50x44 -> omitted (too narrow), 120x50 -> shown. --- idatui/app.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/idatui/app.py b/idatui/app.py index 446c364..ac55864 100644 --- a/idatui/app.py +++ b/idatui/app.py @@ -2063,8 +2063,14 @@ class LoadingScreen(ModalScreen): def compose(self) -> ComposeResult: with Vertical(id="loading-box"): logo = _load_logo() + # Only show the splash art when the terminal can fit it plus the + # title/note/help + box chrome; otherwise fall back to a text-only + # overlay so nothing important is clipped off a small screen. if logo is not None: - yield Static(logo, id="loading-logo") + sz = self.app.size + n = len(logo.split("\n")) + if sz.height >= n + 9 and sz.width >= 64: + yield Static(logo, id="loading-logo") yield Static(f"\u23f3 loading {self._title}", id="loading-title") yield Static(self._note, id="loading-note") yield Static("first open of a big binary can take a while \u00b7 " -- cgit v1.3.1-sl0p