diff options
-rw-r--r-- | ranger/defaults/commands.py | 2 | ||||
-rw-r--r-- | ranger/defaults/rc.conf | 46 |
2 files changed, 36 insertions, 12 deletions
diff --git a/ranger/defaults/commands.py b/ranger/defaults/commands.py index 20f40d13..78a406a7 100644 --- a/ranger/defaults/commands.py +++ b/ranger/defaults/commands.py @@ -857,7 +857,7 @@ class pmap(map_): """:pmap <keysequence> <command> Maps a command to a keysequence in the "pager" context. """ - context = 'pager' + context = 'embedded_pager' class filter(Command): diff --git a/ranger/defaults/rc.conf b/ranger/defaults/rc.conf index 7743f37a..92573832 100644 --- a/ranger/defaults/rc.conf +++ b/ranger/defaults/rc.conf @@ -260,26 +260,50 @@ cmap <C-y> eval fm.ui.console.paste() # =================================================================== +# == Pager Keybindings +# =================================================================== + +# Movement +pmap j eval -q fm.ui.pager.move(down=1) +pmap k eval -q fm.ui.pager.move(up=1) +pmap gg eval -q fm.ui.pager.move(down=0, absolute=True) +pmap G eval -q fm.ui.pager.move(down=-1, absolute=True) +pmap <down> eval -q fm.ui.pager.move(down=1) +pmap <up> eval -q fm.ui.pager.move(up=1) +pmap <home> eval -q fm.ui.pager.move(down=0, absolute=True) +pmap <end> eval -q fm.ui.pager.move(down=-1, absolute=True) + +pmap h eval -q fm.ui.pager.move(left=4) +pmap l eval -q fm.ui.pager.move(right=4) +pmap <left> eval -q fm.ui.pager.move(left=4) +pmap <right> eval -q fm.ui.pager.move(right=4) + +pmap q eval -q fm.ui.close_pager(); fm.ui.close_embedded_pager() +pmap i eval -q fm.ui.close_pager(); fm.ui.close_embedded_pager() +pmap <ESC> eval -q fm.ui.close_pager(); fm.ui.close_embedded_pager() +pmap <F3> eval -q fm.ui.close_pager(); fm.ui.close_embedded_pager() + +# =================================================================== # == Taskview Keybindings # =================================================================== # Movement -tmap j eval -q fm.ui.taskview.move(down=1) -tmap k eval -q fm.ui.taskview.move(up=1) -tmap gg eval -q fm.ui.taskview.move(down=0, absolute=True) -tmap G eval -q fm.ui.taskview.move(down=-1, absolute=True) +tmap j eval -q fm.ui.taskview.move(down=1) +tmap k eval -q fm.ui.taskview.move(up=1) +tmap gg eval -q fm.ui.taskview.move(down=0, absolute=True) +tmap G eval -q fm.ui.taskview.move(down=-1, absolute=True) tmap <down> eval -q fm.ui.taskview.move(down=1) -tmap <up> eval -q fm.ui.taskview.move(up=1) +tmap <up> eval -q fm.ui.taskview.move(up=1) tmap <home> eval -q fm.ui.taskview.move(down=0, absolute=True) -tmap <end> eval -q fm.ui.taskview.move(down=-1, absolute=True) +tmap <end> eval -q fm.ui.taskview.move(down=-1, absolute=True) # Changing priority and deleting tasks -tmap J eval -q fm.ui.taskview.task_move(-1) -tmap K eval -q fm.ui.taskview.task_move(0) -tmap dd eval -q fm.ui.taskview.task_remove() +tmap J eval -q fm.ui.taskview.task_move(-1) +tmap K eval -q fm.ui.taskview.task_move(0) +tmap dd eval -q fm.ui.taskview.task_remove() tmap <pagedown> eval -q fm.ui.taskview.task_move(-1) -tmap <pageup> eval -q fm.ui.taskview.task_move(0) -tmap <delete> eval -q fm.ui.taskview.task_remove() +tmap <pageup> eval -q fm.ui.taskview.task_move(0) +tmap <delete> eval -q fm.ui.taskview.task_remove() # A bunch of aliases for closing tmap w eval -q fm.ui.close_taskview() |