Commits

Anonymous committed e460de0

2004-12-07 Zajcev Evgeny <zevlg@yandex.ru>

* lisp/xwem-keyboard.el (xwem-kbd-xksym->emacs):
(xwem-kbd-emacs->xksym): support for all the special X keysyms like
multimedia keys in /usr/X11R6/lib/X11/XKeysymDB.

2004-12-08 Richard Klinda <ignotus@hixsplit.hu>

* lisp/xwem-misc.el: (xwem-misc-find-cl-by-emacs-frame):
[fix] use x-emacs-application-classi nstead of hardcoded
"Emacs" string.

Comments (0)

Files changed (3)

+2004-12-07  Zajcev Evgeny  <zevlg@yandex.ru>
+
+	* lisp/xwem-keyboard.el (xwem-kbd-xksym->emacs):
+	(xwem-kbd-emacs->xksym): support for all the special X keysyms like
+	multimedia keys in /usr/X11R6/lib/X11/XKeysymDB.
+
+2004-12-08  Richard Klinda  <ignotus@hixsplit.hu>
+
+	* lisp/xwem-misc.el: (xwem-misc-find-cl-by-emacs-frame):
+	[fix] use x-emacs-application-classi nstead of hardcoded
+	"Emacs" string.
+
 2004-12-06  Zajcev Evgeny <zevlg@yandex.ru>
 
 	* extra/xwem-frametrans.el (Repository): initial import of frame

lisp/xwem-keyboard.el

 
 (require 'xlib-xlib)
 (require 'xlib-xtest)
+(require 'xlib-xkeysymdb)
 
 (require 'xwem-load)
 (require 'xwem-misc)
 
    ((= ksym 0) nil)
 
-   (t (XCharacter ksym))))		;nil or proper character
+   (t (or (X-XKeysymDB-keysym->sym ksym)
+          (XCharacter ksym)))))	;nil or proper character
 
 (defun xwem-kbd-emacs->xksym (ksym)
   "Convert back from Emacs key symbol KSYM to proper X key symbol."
 		 ((string= symname "button5") (list X-XButton5))
 
 		 ;; Functional keys
-		 ((string-match "[fF]\\([0-9]+\\)" symname)
+		 ((string-match "^[fF]\\([0-9]+\\)$" symname)
 		  (symbol-value
 		   (intern
 		    (concat "XK-F"
 			    (substring symname (match-beginning 1)
 				       (match-end 1))))))
 
-		 (t (Xforcenum (string-to-char osymname))))))
+		 (t (or (X-XKeysymDB-sym->keysym ksym)
+         (Xforcenum (string-to-char osymname)))))))
 
 	((characterp ksym) (Xforcenum ksym)) ;Should not be there
 

lisp/xwem-misc.el

         wm-class xtr rcl)
     (while clients
       (setq wm-class (xwem-hints-wm-class (xwem-cl-hints (car clients))))
-      (when (and (string= (car wm-class) "emacs")
-                 (string= (cdr wm-class) "Emacs"))
+      (when (string= (cdr wm-class) x-emacs-application-class))
         (setq xtr (XQueryTree (xwem-dpy) (xwem-cl-xwin (car clients))))
         (if (car xtr)
             (setq xtr (mapcar 'X-Win-id (cdr (cdr (cdr (cdr xtr))))))