On Mo, 12 Okt 2020, Philippe Meunier wrote:

> Hello,
> 
> I'm trying to create some bindings in my .muttrc file for mutt's sidebar
> (this is while running mutt in an xterm window on OpenBSD):
> 
> bind index <S-Up> sidebar-prev
> bind index <S-Down> sidebar-next
> 
> and this works fine.  Then I tried this one:
> 
> bind index <S-Return> sidebar-open
> 
> and it does not work at all: mutt seems to consider pressing the
> Shift-Enter combination on the keyboard to be the same as just pressing
> Enter.  Indeed executing the what-key function shows that the Shift-Enter
> key combination is just recognized as Return by mutt.

Shift + Return is not easily distinguishable for application on a 
terminal. 

> I also tried emacs's view-lossage function in the same xterm and emacs
> recognizes the Shift-Enter key combination as: ESC [ 2 7 ; 2 ; 1 3 ~
> So out of desperation I tried this in my .muttrc:

This is using xterms modifyOtherKeys extension. If this is enabled (and 
supported by your terminal), xterm will send a response like
CSI 27; <modifier>; <decimal_key>

CSI being ESC [

However, I believe this only works properly, if your terminal 
application (so mutt) understands and supports this scheme. As far as I 
know, mutt doesn't, but apparently your Emacs does (and Vim also 
supports this scheme for a few years).

So I think, this is currently not usable from within mutt.

regards,
Christian
-- 
To give happiness is to deserve happiness.

Reply via email to