stumpwm-devel
[Top][All Lists]
Advanced

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

Re: [STUMP] Xmodmap keys


From: Sébastien Vauban
Subject: Re: [STUMP] Xmodmap keys
Date: Fri, 26 Jun 2009 12:30:09 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.94 (gnu/linux)

Hi Shawn,

>> I'll ask just for the sake of it:  By any chance, is this happening when
>> Caps Lock is ON?
>
> That raises a good question. What should stumpwm do about caps lock? I
> believe it just ignores it right now which means if you have caps lock on
> then none of the top level bindings will work.

In my case, with my .stumpwm where I have:

--8<---------------cut here---------------start------------->8---
;; Custom Shortcuts

;; keyboard layout (see section "Prefix Key" for keycode 133)
(defvar *keyboard-layout* :qwerty-gb)
(run-shell-command "setxkbmap gb && xmodmap -e 'keycode 133 = F20' -e 'clear 
Lock' -e 'keycode 66 = F19'")

(defcommand toggle-keyboard-layout () ()
  "docstring"
  (ecase *keyboard-layout*
    (:qwerty-gb
     (setf *keyboard-layout* :azerty-fr)
     (run-shell-command "setxkbmap fr && xmodmap -e 'keycode 133 = F20' -e 
'clear Lock' -e 'keycode 66 = F19'")
     (message "Selected keyboard layout: France")
     (run-shell-command "xset led 3"))
    (:azerty-fr
     (setf *keyboard-layout* :qwerty-gb)
     (run-shell-command "setxkbmap gb && xmodmap -e 'keycode 133 = F20' -e 
'clear Lock' -e 'keycode 66 = F19'")
     (message "Selected keyboard layout: United Kingdom")
     (run-shell-command "xset -led 3"))))

(define-key *top-map* (kbd "F19") "toggle-keyboard-layout")
--8<---------------cut here---------------end--------------->8---

yes, Caps Lock is simply ignored (thanks to clear Lock, I guess), and all my
keys operate in "non-shifted mode" within the chosen keyboard layout (FR or
UK).

So, I still have to press `Super_L Shift-q' for making the chosen frame the
only one on the screen. When in FR keyboard, I have to *physically* press
`Super_L Shift-a'. By this, I mean that Caps Lock LED being one does not imply
every key is "shifted" (or should I say "capsed"). Not sure I'm clear,
though...

Seb

-- 
Sébastien Vauban





reply via email to

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