[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ctrl-[ ?

From: Clément Pit-Claudel
Subject: Re: Ctrl-[ ?
Date: Thu, 6 Jun 2019 14:48:38 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0

On 2019-06-06 14:34, Eli Zaretskii wrote:
>> Date: Thu, 06 Jun 2019 20:48:49 +0300
>> From: Eli Zaretskii <address@hidden>
>> Cc: address@hidden
>>>> It's a prefix command, so I'm not sure what you are asking, exactly.
>>> I wan wondering whether there was a way to make it a regular (non-prefix) 
>>> command.  For example, can you bind it to `forward-char'?
>> Can you do that with any other prefix command?
> I'm sorry if that sounded unfriendly.  It's just that the answer is so
> obviously YES that I keep thinking I'm missing something in your
> questions.  It's like asking whether C-f can be bound to some
> command.
I thought so too, but I didn't manage to make it work.  I likely did something 
silly.  I tried this:

  (global-set-key (kbd "ESC") #'forward-char)

…and all that achieved was to break all keybindings starting with meta.

The reason I'm asking is that, assuming it's possible to rebind ESC, I think 
there's an easy solution to the OP's question:

Bind <escape> to esc-map
Bind ESC to whatever you want C-[ to do.

As I understood it, the request was this:

On 2019-06-06 08:37, Jean-Christophe Helary wrote:
> […] in my other applications I do have the ability to use Ctrl+[ in a way 
> that is not ESC. Like assign C-[ as a shortcut similarly to C-].
> Is there a way to do the same in emacs ?

Assuming you can bind ESC and <escape> separately, the above should work, 
shouldn't it?  Maybe I'm missing something obvious.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]