From 8cbac328a9f1b9a6c1e4b53fe7d34968cf5cc858 Mon Sep 17 00:00:00 2001 From: Joe R Date: Thu, 14 Nov 2024 23:36:50 -0500 Subject: [PATCH] Trim strings in the select all games submenu --- pysollib/ui/tktile/menubar.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pysollib/ui/tktile/menubar.py b/pysollib/ui/tktile/menubar.py index c1e1a67c1..cde24ac69 100644 --- a/pysollib/ui/tktile/menubar.py +++ b/pysollib/ui/tktile/menubar.py @@ -1119,8 +1119,8 @@ def sort_func(gi): if not mahjongg_games[n:n + d]: break m = min(n + d - 1, len(mahjongg_games) - 1) - label = mahjongg_games[n].short_name[:3] + ' - ' + \ - mahjongg_games[m].short_name[:3] + label = mahjongg_games[n].short_name[:3].strip() + ' - ' + \ + mahjongg_games[m].short_name[:3].strip() submenu = MfxMenu(menu, label=label, name=None) self._addSelectGameSubSubMenu(mahjongg_games[n:n + d], submenu, command, variable, short_name=True) @@ -1182,7 +1182,8 @@ def _addSelectAllGameSubMenu(self, games, menu, command, variable): if not games[n:n+d]: break m = min(n+d-1, len(games)-1) - label = games[n].name[:3] + ' - ' + games[m].name[:3] + label = games[n].name[:3].strip() + ' - ' + \ + games[m].name[:3].strip() submenu = MfxMenu(menu, label=label, name=None) self._addSelectGameSubSubMenu(games[n:n+d], submenu, command, variable)