diff options
| author | Somelauw <Somelauw> | 2017-02-13 13:38:35 +0100 |
|---|---|---|
| committer | Somelauw <Somelauw> | 2017-02-13 14:29:20 +0100 |
| commit | 750cdb9d20bc44f9e2b164f3b5e46ff7841140a6 (patch) | |
| tree | 629d017f9f8dbfea37182364888a59b8b12445a3 /README.org | |
| parent | 6404568b664ae8283549ac36b7615b3ecf4959f3 (diff) | |
Add operators, textobjects and insert bindings
Diffstat (limited to 'README.org')
| -rw-r--r-- | README.org | 149 |
1 files changed, 104 insertions, 45 deletions
@@ -6,8 +6,9 @@ This is an extended and actively maintained version of https://github.com/edwtjo * New features since evil-org-mode - [X] key themes - [X] customizable movement keys -- [ ] operators -- [ ] text objects +- [X] operators +- [X] text objects +- [X] insert mode bindings * Requirements @@ -26,77 +27,135 @@ This is an extended and actively maintained version of https://github.com/edwtjo #+begin_src emacs-lisp (add-to-list 'load-path "~/.emacs.d/plugins/evil-org-mode") (require 'evil-org) - (evil-org-set-key-theme '(additional)) + (evil-org-set-key-theme '(textobjects insert additional)) #+end_src -* Keythemes -The new config is set up in keythemes +* Key themes +The new config is set up in key themes To enable all bindings use: #+begin_src emacs-lisp - (evil-org-set-key-theme '(additional shift leader todo heading)) + (evil-org-set-key-theme '(textobjects insert additional shift leader todo heading)) #+end_src - |-----------+--------------------------------------------| ** Basic These keys are always enabled - | 'x' | org-delete-previous-char | - | 'X' | org-delete-char | - | '$' | org-end-of-line | - | '^' | org-beginning-of-line | - | < | org-metaleft | - | > | org-metaright | - | ( | org-forward-sentence | - | ) | org-backward-sentence | - | { | org-forward-paragraph | - | } | org-backward-paragraph | - | TAB | org-cycle | - | o | always-insert-item | + |-----+--------------------------| + | key | function | + |-----+--------------------------| + | 'x' | org-delete-previous-char | + | 'X' | org-delete-char | + | '$' | org-end-of-line | + | '^' | org-beginning-of-line | + | < | org-metaleft | + | > | org-metaright | + | ( | org-forward-sentence | + | ) | org-backward-sentence | + | { | org-forward-paragraph | + | } | org-backward-paragraph | + | TAB | org-cycle | + | o | always-insert-item | + |-----+--------------------------| + +** Text objects +"var" to select an element +"dar" to delete a subtree +"2yar" to yank the parent of a subtree + + |-----+-------------+------------------------------------------------| + | key | function | explanation | + |-----+-------------+------------------------------------------------| + | ae | org-element | An org element | + | ar | org-subtree | A subtree. Use a count to select parent trees. | + |-----+-------------+------------------------------------------------| + +** Operators +Operators for promoting/demoting headings + +">>" to promote a heading +">ar" to promote a tree + + |-----+----------------------+-------------------------------------| + | key | function | explanation | + |-----+----------------------+-------------------------------------| + | < | evil-org-shift-left | Promote all headings in marked area | + | > | evil-org-shift-right | Demote all headings in marked area | + |-----+----------------------+-------------------------------------| + +If you want < and > similar to evil-org-mode, put the following in your init file + +#+begin_src emacs-lisp + (evil-define-key 'normal evil-org-mode-map + (kbd ">") 'org-meta-right + (kbd "<") 'org-meta-left) +#+end_src + +Or you enable additional and use M-h and M-l. ** Additional If you don't want to use hjkl, you can customize evil-org-movement-bindings. - | gh | outline-up-heading | - | gj | org-forward-heading-same-level | - | gk | org-backward-heading-same-level | - | gl | outline-next-visible-heading | - | M-l | org-metaright | - | M-h | org-metaleft | - | M-k | org-metaup | - | M-j | org-metadown | - | M-L | org-shiftmetaright | - | M-H | org-shiftmetaleft | - | M-K | org-shiftmetaup | - | M-J | org-shiftmetadown | - | M-t | org-insert-todo-heading nil+ org-metaright | + |-----+---------------------------------------------+---------------------| + | key | function | explanation | + |-----+---------------------------------------------+---------------------| + | gh | outline-up-heading | Go to parent tree | + | gj | org-forward-heading-same-level | Next heading | + | gk | org-backward-heading-same-level | Previous heading | + | gl | outline-next-visible-heading | Go to first subtree | + | M-l | org-metaright | Demote heading | + | M-h | org-metaleft | Promote heading | + | M-k | org-metaup | Move subtree up | + | M-j | org-metadown | Move subtree down | + | M-L | org-shiftmetaright | Demote subtree | + | M-H | org-shiftmetaleft | Promote subtree | + | M-K | org-shiftmetaup | Move heading up | + | M-J | org-shiftmetadown | Move heading down | + |-----+---------------------------------------------+---------------------| ** Shift If you don't want to use hjkl, you can customize evil-org-movement-bindings. - | H | org-shiftleft | - | J | org-shiftdown | - | K | org-shiftup | - | L | org-shiftright | + |-----+----------------+--------------------| + | key | function | explanation | + |-----+----------------+--------------------| + | H | org-shiftleft | previous todo item | + | L | org-shiftright | next todo item | + | J | org-shiftdown | decrease priority | + | K | org-shiftup | increase priority | + |-----+----------------+--------------------| ** Leader - | <leader>a | org-agenda | - | <leader>t | org-show-todo-tree | - | <leader>c | org-archive-subtree | - | <leader>l | evil-org-open-links | - | <leader>o | evil-org-recompute-clocks | + |-----------+---------------------------| + | key | function | + |-----------+---------------------------| + | <leader>a | org-agenda | + | <leader>t | org-show-todo-tree | + | <leader>c | org-archive-subtree | + | <leader>l | evil-org-open-links | + | <leader>o | evil-org-recompute-clocks | + |-----------+---------------------------| ** Todo - | t | org-todo | - | T | org-insert-todo-heading nil | + |-----+---------------------------------------| + | key | function | + |-----+---------------------------------------| + | t | org-todo | + | T | org-insert-todo-heading nil | + | M-t | org-insert-todo-heading+org-metaright | + |-----+---------------------------------------| ** Heading - | O | org-insert-heading | - | M-o | org-insert-heading+org-metaright | + |-----+----------------------------------| + | key | function | + |-----+----------------------------------| + | O | org-insert-heading | + | M-o | org-insert-heading+org-metaright | + |-----+----------------------------------| * License |
