1. Iñigo Serna
  2. lfm

Commits

Iñigo Serna  committed 3965326

Change PowerCLI key shortcut, now Ctrl-X.

* lfm/actions.py (keytable): change PowerCLI key shortcut, now Ctrl-X
* lfm/messages.py (EntryLine:manage_keys):
* README (Key bindings, PowerCLI): updated documentation

  • Participants
  • Parent commits b1988ee
  • Branches default

Comments (0)

Files changed (5)

File ChangeLog

View file
+Sat May 14 19:08:53 2011  Iñigo Serna  <inigoserna@gmail.com>
+
+	* lfm/actions.py (keytable): change PowerCLI key shortcut, now Ctrl-X
+	* lfm/messages.py (EntryLine:manage_keys):
+	* README (Key bindings, PowerCLI): updated documentation
+
 Sat May 14 18:37:27 2011  Iñigo Serna  <inigoserna@gmail.com>
 
 	* lfm/config.py (files_ext): added new extensions: pyw, vala, glade, ui, docx, xlsx, pptx

File README

View file
     - Ctrl-H: toggle show/hide dot files
     - Ctrl-W: toggle allow navigate in non-active pane
     - Ctrl-O: open shell. Type 'exit' or press Ctrl-D to return to lfm
-    - Ctrl-G: toggle show/hide PowerCLI
+    - Ctrl-X: toggle show/hide PowerCLI
     - Ctrl-T: tree
     - F12: file menu
         - @: do something on file(s). Deprecated, use *PowerCLI*
 + ***EntryLine* window**
     - enter: return path or execute command in *PowerCLI*
     - Ctrl-C, ESC: quit
+    - Ctrl-X: toggle show/hide in *PowerCLI*
     - insert, ...
     - special:
         - up, down: history
         - Ctrl-Q, Ctrl-Backspace: delete until previous special character
         - Ctrl-R, Ctrl-Del: delete until next special character
     - insertion
-        - Ctrl-Z: recover original content (undo)
+        - Ctrl-Z: restore original content (undo)
         - Ctrl-V: insert filename at position
         - Ctrl-D: insert path at position
         - Ctrl-O: insert other pane path at position
 PowerCLI
 ========
 *PowerCLI* is a command line interface with advanced features.
-To show it press Ctrl-G, and same again to hide, ENTER to run.
+To show it press Ctrl-X, and same again to hide, ENTER to run.
 Line contents are restored next time PowerCLI is showed.
 
 Some features:

File TODO

View file
 ============================================================================
-Last update:	Time-stamp: <2011-05-14 18:22:05 inigo>
+Last update:	Time-stamp: <2011-05-14 18:50:06 inigo>
 ============================================================================
 
 
     . do_something_on_file, execute_file
     . powercli
   . store in ~/.lfm_history
+    . config flag to enable/disable
     . format:
       [type]
       entry_1

File lfm/actions.py

View file
     0x04: 'select_bookmark',   # Ctrl-D
     0x1C: 'select_bookmark',   # Ctrl-\
     ord('b'): 'set_bookmark',
-    0x19: 'select_historic',   # Ctrl-Y
+    0x19: 'select_history',    # Ctrl-Y
 
     # panels
     ord('\t'): 'toggle_active_pane',  # tab
     ord('l'): 'create_link',
     ord('L'): 'edit_link',
     0x0F: 'open_shell',         # Ctrl-O
-    0x07: 'show_cli',           # Ctrl-G
+    0x18: 'show_cli',           # Ctrl-X
 
     # main functions
     curses.KEY_F2: 'rename',
 
     # terminal resize:
     curses.KEY_RESIZE: 'resize_window',
-    0x12: 'refresh_screen',          # Ctrl-R
+    0x12: 'refresh_screen',     # Ctrl-R
 
     # quit & exit
     ord('q'): 'quit',
             break
 
 
-def select_historic(tab):
+def select_history(tab):
     items = tab.historic[::-1]
     if not items:
         messages.error('Cannot select directory from history\nNo entries yet')

File lfm/messages.py

View file
             #      (curses.keyname(ch), ch & 255, ch, ch)
             if ch in (0x03, 0x1B) and not self.cli:       # Ctrl-C, ESC
                 return -1
-            elif ch == 0x07 and self.cli:                 # Ctrl-G
+            elif ch == 0x18 and self.cli:                 # Ctrl-X
                 return -1
             # historic
             elif ch == curses.KEY_UP: