Ticket #2720 (closed enhancement: invalid)
Use a hotkey to toggle between two preferred sort orders
Reported by: | guivho | Owned by: | |
---|---|---|---|
Priority: | trivial | Milestone: | |
Component: | mc-core | Version: | master |
Keywords: | sort order hotkey | Cc: | |
Blocked By: | Blocking: | ||
Branch state: | no branch | Votes for changeset: |
Description
One of the few things I frequently do with mc is switching between sorting by
name and by reverse modification time.
I know that F9 S pops up the sort order dialog which has accelerator keys for
all options, and that is fine for all less frequent sort requests.
But toggling between my two frequently used modes requires quite some
keystrokes (and, sorry, I don't want to use the mouse):
- Initial state: by Name, reverse
- Switch to Reverse Modification time: F9 S M R O
- Back to non reverse Name order: F9 S N R O
It would so nice to be able to define two favorite sort orders and have a
hotkey to toggle between the two.
UI-wise, one could imagine the sort panel to be extended as follows:
( ) Unsorted [ ] Executable first (*) Name [ ] Case sensitive ( ) Version [ ] Reverse ( ) Extension ( ) Size [ Set preferred ] ( ) Modify time [ Set alternate ] ( ) Access time ( ) Change time ( ) Inode [< OK >] [ Cancel ]
The user could select one of the order radio buttons, select any combination
of the checkboxes and hit the [ Set preferred ] or [ Set alternate ]
buttons to save this preference.
Alt-a could be used as hotkey to toggle between these two preferred orders
(well it is still free, I think).
This scenario could be extended from two preferred orders to e.g. five, and use
the hotkey to rotate between them.
Personally, I'd prefer to limit it to two sort order preferences and just use
the hotkey to toggle between them, but ... 'your mileage may vary' :)
A generic approach would be to have accelerator keys for all sort options, e.g.
Alt-0 Unsorted Alt-1 Name Alt-2 Version Alt-3 Extension Alt-4 Size Alt-5 Modify time Alt-6 Access time Alt-7 Change time Alt-8 Inode Alt-9 Executable first Alt-- Case sensitive Alt-= Reverse
But that is less convenient: one would have to look at the current state of the
checkboxes in order to decide whether or not to toggle them.
The preferred proposal allows for blind operation. Regardless of the current
state of the sort order, a maximum of two keystrokes would set the desired well
defined order.
Change History
comment:2 Changed 13 years ago by guivho
- Priority changed from major to trivial
I have mapped a hotkey in my mc.keymap for SortByName? and SortByMTime and that supplies all functionality I needed.
As far as I am concerned. this ticket can be closed.
see: mc.keymap
btw
alt-1 is f1
alt-2 is f2
etc...