Morgan Smith <[email protected]> writes:

> Ihor Radchenko <[email protected]> writes:
>> I think the right fix is changing `org-scroll'
>
> Adding support for the key 'backspace in `org-scroll' would be 
> very easy to do but I wonder if it's actually correct.
> ...

We already do something similar in `org-export--dispatch-action' and
nobody complains.

> Backspace seems to correspond the ASCII escape ?\b which also 
> corresponds to "C-h".  I wonder if there is the possibility of a 
> user trying to send "C-h" for help but we interpret it as DEL.
>
> The docstring of "read-event" seems to imply it's a pretty low 
> level function and that we should consider using "read-key" 
> instead as that decodes events using "input-decode-map".
>
> I can't quite follow the logic but I think using "read-key" would 
> respect user settings like "normal-erase-is-backspace" whereas 
> "read-event" would not.
>
> On my system running the following and then hitting my backspace 
> key results in the following:
>
> (read-event "blah:") => backspace
>
> (read-key "blah:") => 127
>
> So at least on my system, switching from "read-event" to 
> "read-key" would fix this.

AFAIK, read-key will intercept even more:

    Also in contrast to read-event, input method text conversion
    will be disabled while the key sequence is read, so that
    character input events will always be generated for keyboard
    input.

> Maybe I'm overthinking this.  IDK.  What do you think? 

I think we can follow the existing patterns. If those turn out to be
problematic, we change them everywhere. Before that, we should aim for
more consistent handling of menus across Org.

-- 
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to