Daniel E. Doherty <[email protected]> writes:
> All,
>
> I make *very* frequent use of the shift-arrow keys to move from window
> to window inside emacs via windmove. It is probably the most frequent
> key combination I access.
>
> Anyway, is there a way to make org-mode friendlier to it by passing the
> key along whenever org-mode would otherwise throw an error. For
> example, when not on a heading, when in the agenda, and wherever else?
>
> I really like Carsten's use of the arrow keys for structure editing and
> don't want to lose that, just whenever org-mode can't make use of the
> keys.
Yes, that would be helpfull!
I guess you could do this:
(defun my/org-windmove-right-maybe (&optional arg)
(interactive "P")
(if (and (not (org-on-heading-p))
(not (org-at-item-p)))
(windmove-right arg)
(org-shiftright arg)))
;; and bind it in org-mode-hook:
(add-hook 'org-mode-hook
(lambda ()
(define-key org-mode-map [(shift right)]
'my/org-windmove-right-maybe)))
Sebastian
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-orgmode