Kaushal Modi <kaushal.m...@gmail.com> writes:

> On Wed, Jan 23, 2019 at 3:54 PM Marco Wahl <marcowahls...@gmail.com> wrote:
>  As a workaround you can evaluate the lines (that were active before the
>  commit)
>  (org-defkey org-mode-map (kbd "S-<return>") #'org-table-copy-down)
>  (org-defkey org-mode-map (kbd "M-S-<return>") #'org-insert-todo-heading)
>  (org-defkey org-mode-map (kbd "ESC S-<return>") #'org-insert-todo-heading)
>  or put them into your init file AFAICS.
> Yep, that commit broke the -<return> bindings for me too. I'll have to do the 
> same.
> Copying Kevin who originally requested the change of these bindings (this 
> switching of bindings between RET and <return> feels like dejavu to me .. I 
> have seen this done before in Org repo).
>  Is this a reliable fix to add these lines to the source code again?
>  To be honest I don't see clearly.
> May be those keys should be bound to both RET and <return> variants? 
> For Emacs GUI, I think that the <return> variant is needed, RET does nothing.

Gah!  Apologies for the breakage.  I assumed that in GUI frames, since
<return> is translated to RET when the former is not bound
explicitly[1], *modifier*-<return> would also be translated to
*modifier*-RET, but that does not seem to be the case[2].

My previous experience with M-RET in markdown-mode[3] led me to assume I
could suggest this change without breaking anything…  Next time I'll
know better and write those unit tests :)

Thank you for catching this and again, sorry for the disruption.

[1]: In fundamental-mode:

    C-h k <return>
    ⇒ RET (translated from <return>) runs the command newline…

[2]: In fundamental-mode:

    M-: (global-set-key (kbd "S-RET") (lambda () (interactive) (message "foo")))
    C-h k S-<return>
    ⇒ RET (translated from <S-return>) runs the command newline…

    M-: (global-set-key (kbd "M-S-RET") (lambda () (interactive) (message 
    C-h M-S-<return>
    ⇒ <M-S-return> is undefined

    M-: (global-set-key (kbd "M-RET") (lambda () (interactive) (message "baz")))
    C-h M-<return>
    ⇒ M-RET (translated from <M-return>) runs the command (lambda…)


Reply via email to