all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Arash Esbati <arash@gnu.org>
To: Michael Heerdegen via Users list for the GNU Emacs text editor
	<help-gnu-emacs@gnu.org>
Cc: Michael Heerdegen <michael_heerdegen@web.de>
Subject: Re: Customize the key bindings in the org mode
Date: Fri, 08 Mar 2024 12:35:39 +0100	[thread overview]
Message-ID: <m2le6tvtv8.fsf@macmutant.fritz.box> (raw)
In-Reply-To: <87wmqdwobr.fsf@web.de> (Michael Heerdegen via Users list for the's message of "Fri, 08 Mar 2024 01:37:44 +0100")

Michael Heerdegen via Users list for the GNU Emacs text editor <help-gnu-emacs@gnu.org> writes:

> Volker Wysk <post@volker-wysk.de> writes:
>
>> I found something on the web and adapted it:
>>
>> (with-eval-after-load "org"  (define-key org-mode-map [M-down] #'absatz-vor)
>>
>> But this doesn't work, because the org-mode-map is nil. Seems like that's
>> because org-mode hasn't been read yet, in the ~/.emacs file.
>
> Org consists of multiple source files, and at the moment where org.el
> has been loaded the rest of org has not yet - including the file that
> actually defines and fills the org-mode's keymap (note that C-h v
> org-mode-map tells you org.el would define the variable, this is true
> but only for internal technical reasons: the keymap is not yet created
> by loading that file).

Caveat emptor: I'm not an Org user.

Does the above mean that this example in Org manual[1] doesn't work
OOTB?

  C-c C-x C-n (org-next-link)
  C-c C-x C-p (org-previous-link)

    Move forward/backward to the next link in the buffer. At the limit
    of the buffer, the search fails once, and then wraps around. The key
    bindings for this are really too long; you might want to bind this
    also to M-n and M-p.

      (with-eval-after-load 'org
        (define-key org-mode-map (kbd "M-n") #'org-next-link)
        (define-key org-mode-map (kbd "M-p") #'org-previous-link))

Best, Arash

Footnotes:
[1]  https://orgmode.org/manual/Handling-Links.html



  reply	other threads:[~2024-03-08 11:35 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-07 10:41 Customize the key bindings in the org mode Volker Wysk
2024-03-07 12:59 ` Michel Verdier
2024-03-07 13:13   ` Volker Wysk
2024-03-08  0:37 ` Michael Heerdegen via Users list for the GNU Emacs text editor
2024-03-08 11:35   ` Arash Esbati [this message]
2024-03-09  0:01     ` Michael Heerdegen via Users list for the GNU Emacs text editor
2024-03-09 10:35       ` Arash Esbati

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2le6tvtv8.fsf@macmutant.fritz.box \
    --to=arash@gnu.org \
    --cc=help-gnu-emacs@gnu.org \
    --cc=michael_heerdegen@web.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.