Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Skill :: Cheking if the user has <Meta> or <Super> key in his keyboard

24 views
Skip to first unread message

Suresh Jeevanandam

unread,
Jan 19, 2006, 9:03:24 AM1/19/06
to
Hi,
I want to write a generic code which would bind a skill function to the
key Super<Key>v or Meta<Key>v based on the keyboard the user has.

Is there a way to find this out? I could not find any function.

regards,
Suresh

Suresh Jeevanandam

unread,
Jan 19, 2006, 9:05:24 AM1/19/06
to
Note that Sun Keyboards have "Meta" key whereas other keyboards have
"Super" (Windows) Key.

regards,
Suresh

Pete nospam Zakel

unread,
Jan 19, 2006, 8:25:10 PM1/19/06
to

You can use the command:

xmodmap -pm

in a terminal window to print the modifier keys currently mapped.

-Pete Zakel
(p...@seeheader.nospam)

To be is to do. -- Plato
To do is to be. -- Socrates
Do-be-do-be-do. -- Frank Sinatra

Pete nospam Zakel

unread,
Jan 19, 2006, 8:35:04 PM1/19/06
to
In article <43d04a06$1...@news.cadence.com> px...@cadence.com (Pete nospam Zakel) writes:
>In article <dqo67e$8r$1...@home.itg.ti.com> Suresh Jeevanandam <sur...@DELETETHISti.com> writes:
>>Hi,
>> I want to write a generic code which would bind a skill function to the
>>key Super<Key>v or Meta<Key>v based on the keyboard the user has.
>>
>> Is there a way to find this out? I could not find any function.

>You can use the command:
>
> xmodmap -pm
>
>in a terminal window to print the modifier keys currently mapped.

I almost forgot -- there is a private hi function that returns the list of
modifiers available: hiiGetModifierList().

This function is unlikely to change (it was added for debug purposes), so I
don't see any harm in your using it. The return value is a list of lists,
the first list in the return list is the list of modifier strings available.
Following that is pretty much the same information given by "xmodmap -pm".

Note that starting in IC 6.1.0 we will be restricting the use of the Alt
modifier, though, so you shouldn't use that one for bindkeys. But there's
no problem using Super and/or Meta.

-Pete Zakel
(p...@seeheader.nospam)

Silverman's Law:
If Murphy's Law can go wrong, it will.

0 new messages