[patch] change sort order with single keyboard shortcut



I have created a "change sort order by simple keyboard shortcuts patch" (includes also useful sort mode indicator)

(since, for instance f9,enter,s,m,r,o is not very user friendly 'keystroke' to change to "sort by mtime")
After applying my patch, following keys start to work:
 Sort by name               Ctrl-F3
 Sort by extension          Ctrl-F4
 Sort by modification time  Ctrl-F5
 Sort by size               Ctrl-F6
 Keep unsorted              Ctrl-F7
 Sort by creation time      Ctrl-F8
 Sort by access time        Ctrl-F9
(additional keyboard shortcuts for changing sort modes may be defined in main.c, but I leave that decision to others. These work for me in gnome-terminal and linux text console:o)
(although they don't work in xterm for instance .... if there are any seven keys that I can use and are not used by anything else, please tell me which to use, I can add extra seven lines to main.c for these functions...)

Also two options are added, allow_reversed_sort_modes (default is on)
and enable_sort_indicator (default is off - indicator is disabled)

I have documented them in mc.1.in (patch for this file included in this patch) in advanced options (no gui to edit them in settings (yet), but maybe I can add them to layout section...)

sort indicator puts letter representing current sort mode in top left corner of the panel, reversed sort modes when enabled will reverse sort order if you select current sort mode again.

Any bug reports or suggestions for this patch should go to my address.

Martin Petricek

--------------------
Jeden z největších letních open air festivalů v České republice. 3. - 6. 7. 2003, Český Brod. Těšit se můžete na téměř 130 umělců, kapel a DJs.
http://user.centrum.cz/redir.php?url=http://www.rockforpeople.cz




Attachment: sort_order.tgz
Description: GNU Zip compressed data



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]