Re : Re : Ping and a question about modifier keys

Iban HATCHONDO <[email protected]> Tue, 28 Nov 2006 20:32:48 +0000 (GMT)
Newsgroups gmane.comp.window-managers.eclipse
Message-ID <[email protected]>
Committed in revision 1.9 of lib/clx-ext/keysyms.lisp=0AThanks Ralf.=0A=0A-=
---- Message d'origine ----=0ADe : Iban HATCHONDO <[email protected]>=0A=C0=
 : [email protected]; eclipse-wm <[email protected]>=0AEnvoy=E9=
 le : Mardi, 28 Novembre 2006, 10h28mn 47s=0AObjet : Re : [eclipse-devel] P=
ing and a question about modifier keys=0A=0AHi all,=0A=0Athanks for comming=
 back on this thread,=0AAt the time Xavier has posted his question, I didn'=
t realize we were having a bug in keyboard::make-modifier-mask-table and we=
re missing a point with X keyboard handling.=0A=0ACan you please try the fo=
llowing (it seems to be working on my side.)=0A=0Ain lib/clx-ext/keysyms.li=
sp=0A=0Areplace definition of make-modifier-mask-table for the following on=
e:=0A=0A(defun make-modifier-mask-table (disp)=0A   (loop with map =3D '(:a=
ny #x8000)=0A            with keysyms-per-keycode =3D (array-dimension (xli=
b:keyboard-mapping disp) 1)=0A            for mods in (multiple-value-list =
(xlib:modifier-mapping disp))=0A            for i =3D 1 then (* 2 i) do=0A =
           (loop for mod in mods=0A                     for key-name =3D (m=
odcode->keyname disp mod keysyms-per-keycode)=0A                     for pr=
ec =3D (getf map key-name) do=0A                    (setf (getf map key-nam=
e) (logior (if (numberp prec) prec 0) i)))=0A            finally (return ma=
p)))=0A=0Aand add this new function:=0A=0A(defun modcode->keyname (disp key=
code keysyms-per-keycode)=0A   "Returns the keyword that named the specifie=
d modifier keycode."=0A   ;; This has been created to deal with X keyboard =
wierd mapping.=0A   ;; For some reasons, for few keys the first keysym in t=
he list, =0A   ;; modifiers keysym in particular, does not exists. So lets =
try=0A   ;; to resolve it anyway looking further in the array.=0A   (loop f=
or i from 0 below keysyms-per-keycode=0A            for keysym =3D (xlib:ke=
ycode->keysym disp keycode i)=0A            when (> keysym 0) do (return (k=
eysym->keyname keysym))))=0A=0A=0AFor info, here is now the content of  kb:=
:*modifier->modifier-mask*=0A=0A(:ISO-LEVEL3-SHIFT 128=0A :MODE-SWITCH 128=
=0A :HYPER-LEFT 64=0A :SUPER-LEFT 64=0A :NUM-LOCK 16=0A :META-LEFT 8=0A :AL=
T-LEFT 8=0A :CONTROL-RIGHT 4=0A :CONTROL-LEFT 4=0A :CAPS-LOCK 2=0A :SHIFT-R=
IGHT 1=0A :SHIFT-LEFT 1=0A :ANY 32768)=0A=0ACheers,=0AIban.=0A=0A----- Mess=
age d'origine ----=0ADe : Ralf Mattes <[email protected]>=0A=C0 : eclipse-w=
m <[email protected]>=0AEnvoy=E9 le : Lundi, 27 Novembre 2006, =
16h21mn 08s=0AObjet : [eclipse-devel] Ping and a question about modifier ke=
ys=0A=0AHello list, =0A        =0A        looking at the archives i'm not s=
hure anybody listens :-/=0A        I'd like to pick up a thread started by =
Xavier Maillard last=0A        year:=0A        =0A         I try to use my =
'Microsoft'-Key as the main key to interact=0A        with eclipse.=0A     =
   That key is known it X as the Super_L key (according to xev). I=0A      =
  tried to =0A        create bindings like this:=0A        =0A             =
 (define-key-combo :switch-screen-left=0A                  :keys '(:LEFT)=
=0A                  :modifiers '(:SUPER-LEFT))=0A        =0A         but e=
clipse refuses to acccept the modifier. The same happens=0A        when i=
=0A         asign META to the MS-Key.=0A         =0A         Looking at *mo=
difier->modifier-mask* i get:=0A        =0A         EWMI> kb::*modifier->mo=
difier-mask*=0A        (:ISO-LEVEL3-SHIFT 256 =0A         :MODE-SWITCH 128=
=0A         :NUM-LOCK 16=0A          NIL 144 =0A         :ALT-LEFT 8=0A    =
     :CONTROL-LEFT 4 =0A         :CONTROL-RIGHT 4 =0A         :CAPS-LOCK 4 =
=0A         :SHIFT-RIGHT 1 =0A         :SHIFT-LEFT 1=0A         :ANY 32768)=
=0A        =0A        with both META and SUPER_L missing. Any ideas?=0A    =
    =0A         Cheers, Ralf Mattes=0A        =0A        =0A        =0A    =
    =0A_______________________________________________=0Aeclipse-devel site=
 [email protected]=0Ahttp://common-lisp.net/mailman/list=
info/eclipse-devel=0A=0A=0A=0A=0A=0A    =0A=0A    =0A        =0A___________=
________________________________________________________________ =0AD=E9cou=
vrez une nouvelle fa=E7on d'obtenir des r=E9ponses =E0 toutes vos questions=
 ! =0AProfitez des connaissances, des opinions et des exp=E9riences des int=
ernautes sur Yahoo! Questions/R=E9ponses =0Ahttp://fr.answers.yahoo.com=0A_=
______________________________________________=0Aeclipse-devel site list=0A=
[email protected]=0Ahttp://common-lisp.net/mailman/listinfo/ecl=
ipse-devel=0A=0A=0A=0A=0A=0A=09=0A=0A=09=0A=09=09=0A_______________________=
____________________________________________________ =0AD=E9couvrez une nou=
velle fa=E7on d'obtenir des r=E9ponses =E0 toutes vos questions ! =0AProfit=
ez des connaissances, des opinions et des exp=E9riences des internautes sur=
 Yahoo! Questions/R=E9ponses =0Ahttp://fr.answers.yahoo.com
_______________________________________________
eclipse-devel site list
[email protected]
http://common-lisp.net/mailman/listinfo/eclipse-devel