Re: Keyboard configurability



> I do apologise. Thanks for your advice. I updated my brain and will 
> keep this in mind next time I do `telnet mail.gnome.org 25'. I 
> usually don't do this. It is just a precausion against spammers not 
> to reveal my real email address I'm now revealing now... 

He who fears something gives it power over him.
        - Arab Proverb

> > What are terminal strings?  I don't understand your suggestion.  I hope
> > you don't mean hardcoding input escape sequences for all terminals.
> Sorry. Bad terminology on my part. I mean escape sequences. What I had 
> in mind was to use similar system to handle keyboard as JED. JED uses 
> S-Lang function setkey_via_terminfo() to recognise keys. Basically, 
> setkey_via_terminfo() checks your terminal database. If it finds an 
> escape sequence corresponding to a capability code (e.g. "k1") in your 
> terminal database, it uses it. If it doesn't, it uses the `hardcoded'
> (e.g. "^[[11~").

That's how mc works, except that "Learn Keys" is limited to most common 
key combinations, which should be fixed.

> I don't use konsole and gnome-terminal. I use xterm and my escape 
> sequences for Ctrl-PgUp and PgUp have to be different for a window 
> where I run JED, and have to be the same for a window where I run 
> MC (because of ioctls...).

First of all, a little correction - ioctls are used on Linux console.  
Under X, the modifiers are read using XQueryPointer() function, and only
if X support is enabled (--with-tm-x-support).

> Of course Shift-Arrows are desired. 
> 
> variable Key_Shift_Up	= setkey_via_terminfo ("", "\e[a");
> variable Key_Shift_Down	= setkey_via_terminfo ("", "\e[b");
> variable Key_Shift_Right= setkey_via_terminfo ("%i", "\e[c");
> variable Key_Shift_Left	= setkey_via_terminfo ("#4", "\e[d");



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