screen-users
[Top][All Lists]
Advanced

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

Re: how do I bind Super- and Meta- ?


From: Micah Cowan
Subject: Re: how do I bind Super- and Meta- ?
Date: Mon, 25 Jun 2007 11:50:40 -0700
User-agent: Thunderbird 1.5.0.12 (X11/20070604)

David Douthitt wrote:
> Micah Cowan wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Miernik wrote:
>>   
>>> How can I bind Super- (mod4) or Meta- (mod3) to some function in GNU
>>> screen?
>>>     
>> I'm pretty sure you can't. I don't think any terminals actually send
>> anything for those modifiers. Shift, Control, and Alt all work by
>> modifying the base ASCII code value they send (for regular keys);
> My understanding is that keyboards do send codes for those.  For
> example, my KVM works by using a quick doubletap on "Control"; and some
> Windows systems will change mode if you lean on the Control key or Shift
> key too long, and a quintuple tap on the Control key activates an
> assistive mode.
> 
> The keyboard sends a keycode for all keys (including control, meta, alt,
> super, et al) and the cpu converts the keycodes to characters.

The keyboard sends a keycode for all keys. The CPU doesn't convert all
keycodes to characters, and none of this has to do with what I said: the
_terminal_ does not send information for these keys.

> I couldn't find anything on key codes in the screen manual (or source
> code), but I'd suggest looking at the termcap (is there a termcap entry
> for Meta or Super?) and using that.

Termcap/terminfo have no means by which to specify _modifiers_: they can
only specify _modified_ combinations. They have never specified this for
keys modified by Meta or Super; Alt, Control and Shift have only very
limited coverage (Control and Alt only covered for function keys,
AFAICT; Shift is covered for some others. No modified regular key
combinations are ever covered; terminals just use the conventions that
Control shifts some values (or strips bits if you like, but that doesn't
cover ^?), and Alt sets the high bit. There are no conventions for Meta
or Super (except that Meta usually mimics Alt).

-- 
Micah J. Cowan
Programmer, musician, typesetting enthusiast, gamer...
http://micah.cowan.name/


Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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