Add block level movement in org-files.

This commit is contained in:
Howard Abrams 2022-11-03 22:16:16 -07:00
parent 7e496beee9
commit a08a5d2dc8
2 changed files with 54 additions and 49 deletions

View file

@ -507,59 +507,63 @@ Global keybindings available to all file buffers:
Bindings specific to org files: Bindings specific to org files:
#+name: org-keybindings #+name: org-keybindings
#+begin_src emacs-lisp :tangle no #+begin_src emacs-lisp :tangle no
(evil-define-key '(normal motion operator visual) org-mode-map "gu" #'org-up-element) (evil-define-key '(normal motion operator visual)
org-mode-map
"gu" #'org-up-element
"gb" #'org-next-block
"gB" #'org-previous-block)
(ha-org-leader (ha-org-leader
"e" '("exports" . org-export-dispatch) "e" '("exports" . org-export-dispatch)
"I" '("insert id" . org-id-get-create) "I" '("insert id" . org-id-get-create)
"l" '("insert link" . org-insert-link) "l" '("insert link" . org-insert-link)
"N" '("store link" . org-store-link) "N" '("store link" . org-store-link)
"P" '("set property" . org-set-property) "P" '("set property" . org-set-property)
"q" '("set tags" . org-set-tags-command) "q" '("set tags" . org-set-tags-command)
"t" '("todo" . org-todo) "t" '("todo" . org-todo)
"T" '("list todos" . org-todo-list) "T" '("list todos" . org-todo-list)
"h" '("toggle heading" . org-toggle-heading) "h" '("toggle heading" . org-toggle-heading)
"i" '("toggle item" . org-toggle-item) "i" '("toggle item" . org-toggle-item)
"x" '("toggle checkbox" . org-toggle-checkbox) "x" '("toggle checkbox" . org-toggle-checkbox)
"." '("goto heading" . consult-org-heading) "." '("goto heading" . consult-org-heading)
"/" '("agenda" . consult-org-agenda) "/" '("agenda" . consult-org-agenda)
"'" '("edit" . org-edit-special) "'" '("edit" . org-edit-special)
"*" '("C-c *" . org-ctrl-c-star) "*" '("C-c *" . org-ctrl-c-star)
"+" '("C-c -" . org-ctrl-c-minus) "+" '("C-c -" . org-ctrl-c-minus)
"d" '(:ignore t :which-key "dates") "d" '(:ignore t :which-key "dates")
"d s" '("schedule" . org-schedule) "d s" '("schedule" . org-schedule)
"d d" '("deadline" . org-deadline) "d d" '("deadline" . org-deadline)
"d t" '("timestamp" . org-time-stamp) "d t" '("timestamp" . org-time-stamp)
"d T" '("inactive time" . org-time-stamp-inactive) "d T" '("inactive time" . org-time-stamp-inactive)
"b" '(:ignore t :which-key "tables") "b" '(:ignore t :which-key "tables")
"b -" '("insert hline" . org-table-insert-hline) "b -" '("insert hline" . org-table-insert-hline)
"b a" '("align" . org-table-align) "b a" '("align" . org-table-align)
"b b" '("blank field" . org-table-blank-field) "b b" '("blank field" . org-table-blank-field)
"b c" '("create teable" . org-table-create-or-convert-from-region) "b c" '("create teable" . org-table-create-or-convert-from-region)
"b e" '("edit field" . org-table-edit-field) "b e" '("edit field" . org-table-edit-field)
"b f" '("edit formula" . org-table-edit-formulas) "b f" '("edit formula" . org-table-edit-formulas)
"b h" '("field info" . org-table-field-info) "b h" '("field info" . org-table-field-info)
"b s" '("sort lines" . org-table-sort-lines) "b s" '("sort lines" . org-table-sort-lines)
"b r" '("recalculate" . org-table-recalculate) "b r" '("recalculate" . org-table-recalculate)
"b d" '(:ignore t :which-key "delete") "b d" '(:ignore t :which-key "delete")
"b d c" '("delete column" . org-table-delete-column) "b d c" '("delete column" . org-table-delete-column)
"b d r" '("delete row" . org-table-kill-row) "b d r" '("delete row" . org-table-kill-row)
"b i" '(:ignore t :which-key "insert") "b i" '(:ignore t :which-key "insert")
"b i c" '("insert column" . org-table-insert-column) "b i c" '("insert column" . org-table-insert-column)
"b i h" '("insert hline" . org-table-insert-hline) "b i h" '("insert hline" . org-table-insert-hline)
"b i r" '("insert row" . org-table-insert-row) "b i r" '("insert row" . org-table-insert-row)
"b i H" '("insert hline ↓" . org-table-hline-and-move) "b i H" '("insert hline ↓" . org-table-hline-and-move)
"n" '(:ignore t :which-key "narrow") "n" '(:ignore t :which-key "narrow")
"n s" '("subtree" . org-narrow-to-subtree) "n s" '("subtree" . org-narrow-to-subtree)
"n b" '("block" . org-narrow-to-block) "n b" '("block" . org-narrow-to-block)
"n e" '("element" . org-narrow-to-element) "n e" '("element" . org-narrow-to-element)
"n w" '("widen" . widen)) "n w" '("widen" . widen))
#+end_src #+end_src
* Supporting Packages * Supporting Packages
** Exporters ** Exporters

View file

@ -80,12 +80,13 @@ Why use [[https://www.flycheck.org/][flycheck]] over the built-in =flymake=? Spe
"<" '("previous problem" . flycheck-previous-error) "<" '("previous problem" . flycheck-previous-error)
"e" '(:ignore t :which-key "errors") "e" '(:ignore t :which-key "errors")
"e n" '(flycheck-next-error :repeat t :wk "next")
"e N" '(flycheck-next-error :repeat t :wk "next")
"e p" '(flycheck-previous-error :repeat t :wk "previous")
"e P" '(flycheck-previous-error :repeat t :wk "previous")
"e b" '("error buffer" . flycheck-buffer) "e b" '("error buffer" . flycheck-buffer)
"e c" '("clear" . flycheck-clear) "e c" '("clear" . flycheck-clear)
"e n" '("next" . flycheck-next-error)
"e N" '("next" . flycheck-next-error)
"e p" '("previous" . flycheck-previous-error)
"e P" '("previous" . flycheck-previous-error)
"e l" '("list all" . flycheck-list-errors) "e l" '("list all" . flycheck-list-errors)
"e g" '("goto error" . counsel-flycheck) "e g" '("goto error" . counsel-flycheck)
"e y" '("copy errors" . flycheck-copy-errors-as-kill) "e y" '("copy errors" . flycheck-copy-errors-as-kill)