From 6c1ddfe68910305e3cdd467669df2c466e762091 Mon Sep 17 00:00:00 2001 From: Jean-Pierre Martineau Date: Fri, 7 Aug 2026 22:03:47 -0400 Subject: [PATCH] Sort chip: the shifted half flips the direction MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Four columns is a short ring — walking it backwards saved at most two presses, so it never earned the Shift companion. F8 now flips the sort direction instead, the other half of the sort and otherwise a Ctrl+arrow chord away. The chip names the direction it would give you, not the one already in force (Sort ▼ while the list reads ascending), drawn in the same triangle the header lights over the active column. Co-Authored-By: Claude Opus 5 (1M context) --- meshterm/ui/contactlist.py | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/meshterm/ui/contactlist.py b/meshterm/ui/contactlist.py index 40e5239..a422839 100644 --- a/meshterm/ui/contactlist.py +++ b/meshterm/ui/contactlist.py @@ -344,11 +344,28 @@ class ContactListScreen(SelectScreen): @property def fkey_lane(self): - """The PicoCalc lane: sort column cycling on F3/F8 beside the shared defaults.""" + """The PicoCalc lane: the whole sort on F3/F8 beside the shared defaults. + + Four columns is a short ring — walking it backwards saves at most two presses, so + it never earns the Shift companion. That slot takes the sort's *other* half + instead: the direction. F3 steps the column forward (each column opening in its + natural direction) and F8 flips the one in force. + + The flip chip names the direction it would *give* you, not the one already in + force — ``Sort ▼`` while the list reads ascending — in the same triangle the header + lights over the active column, so the chip and the column cue can never read as + the same claim. + """ from .tui.fkeys import DEFAULT_LANE, FPair lane = list(DEFAULT_LANE) - lane[2] = FPair("Sort→", "ctrl_right", "←Sort", "ctrl_left") + descend = self._sort.ascending # ascending now, so the flip lands descending + lane[2] = FPair( + "Sort→", + "ctrl_right", + "Sort ▼" if descend else "Sort ▲", + "ctrl_down" if descend else "ctrl_up", + ) return lane def __init__(