From 634d96ea66ac02006cfb7235747c6705412dd25a Mon Sep 17 00:00:00 2001 From: CTCaer Date: Thu, 12 Feb 2026 22:02:04 +0200 Subject: [PATCH] nyx: fix launch rolling boot entry names Somehow this broke half a decade ago and it went unnoticed... which is good. Fix it and make measurements fully proper. --- nyx/nyx_gui/frontend/gui.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/nyx/nyx_gui/frontend/gui.c b/nyx/nyx_gui/frontend/gui.c index c1d46bd1..4916e89d 100644 --- a/nyx/nyx_gui/frontend/gui.c +++ b/nyx/nyx_gui/frontend/gui.c @@ -1950,9 +1950,13 @@ ini_parsing: lv_label_set_text(launch_ctxt.label[curr_btn_idx], ini_sec->name); lv_obj_set_opa_scale(launch_ctxt.label[curr_btn_idx], LV_OPA_COVER); - // Set rolling text if name is big. - if (strlen(ini_sec->name) > 22) + // Set rolling text if name is too big. + u32 max_label_size = 238 - (n_cfg.entries_5_col ? 12 : 0); + if (lv_obj_get_width(launch_ctxt.label[curr_btn_idx]) > max_label_size) + { lv_label_set_long_mode(launch_ctxt.label[curr_btn_idx], LV_LABEL_LONG_ROLL); + lv_obj_set_width(launch_ctxt.label[curr_btn_idx], max_label_size); + } entry_idx++; curr_btn_idx++;