From 0072819204d1f6ed04fbeb102291c97f0ee9c650 Mon Sep 17 00:00:00 2001 From: Paul Oliver Date: Thu, 29 Feb 2024 01:50:44 +0100 Subject: Allowed longer simulation names --- tsalis/src/printer.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'tsalis/src/printer.c') diff --git a/tsalis/src/printer.c b/tsalis/src/printer.c index a3f60b6..469b803 100644 --- a/tsalis/src/printer.c +++ b/tsalis/src/printer.c @@ -1,4 +1,5 @@ #include +#include #include #include #include "printer.h" @@ -714,7 +715,15 @@ tsp_printData(void) int linev = 1; int *line = &linev; PHEADER("SALIS"); - PSIDGET("name", g_simName); + + if (strlen(g_simName) < 24) { + PHEADER(g_simName); + } else { + attron(COLOR_PAIR(PAIR_HEADER)); + printWidget((*line)++, "%.20s...", g_simName); + standend(); + } + PSIDGET("state", g_running ? "running" : "paused"); if (g_autoSaveInterval) { -- cgit v1.2.1