Switch to kbdd program for manage input method.
authorOleksandr Gavenko <gavenkoa@gmail.com>
Fri, 06 Jul 2012 19:29:26 +0300
changeset 477 d0c29482707d
parent 476 12a22ad9bab2
child 478 2913a8a1a474
Switch to kbdd program for manage input method.
.bashrc
.fvwm/config
.xinitrc
--- a/.bashrc	Fri Jul 06 19:13:56 2012 +0300
+++ b/.bashrc	Fri Jul 06 19:29:26 2012 +0300
@@ -115,8 +115,8 @@
 # alias realpath='readlink -f'
 
 # Fix lang under X.
-alias en="setxkbmap -layout us; xmodmap ~/.xmodmaprc"
-alias ут="setxkbmap -layout us; xmodmap ~/.xmodmaprc"
+alias en="dbus-send --dest=ru.gentoo.KbddService /ru/gentoo/KbddService ru.gentoo.kbdd.set_layout uint32:0"
+alias ут="dbus-send --dest=ru.gentoo.KbddService /ru/gentoo/KbddService ru.gentoo.kbdd.set_layout uint32:0"
 
 ################################################################
 # Key binding.
--- a/.fvwm/config	Fri Jul 06 19:13:56 2012 +0300
+++ b/.fvwm/config	Fri Jul 06 19:29:26 2012 +0300
@@ -243,9 +243,9 @@
 Key F12 A S CursorMove +50p +0p
 
 # Switch input method.
-Key 1 A 3 Exec setxkbmap -layout us; xmodmap ~/.xmodmaprc
-Key 2 A 3 Exec setxkbmap -layout ru,us; xmodmap ~/.xmodmaprc
-Key 3 A 3 Exec setxkbmap -layout ua,us; xmodmap ~/.xmodmaprc
+Key 1 A 3 Exec dbus-send --dest=ru.gentoo.KbddService /ru/gentoo/KbddService ru.gentoo.kbdd.set_layout uint32:0
+Key 2 A 3 Exec dbus-send --dest=ru.gentoo.KbddService /ru/gentoo/KbddService ru.gentoo.kbdd.set_layout uint32:1
+Key 3 A 3 Exec dbus-send --dest=ru.gentoo.KbddService /ru/gentoo/KbddService ru.gentoo.kbdd.set_layout uint32:2
 
 # Win+R like in Windows.
 Key R A 3 Exec exec gmrun
@@ -430,5 +430,6 @@
 AddToFunc StartFunction
 + I Module FvwmPager 0 4
 + I Module FvwmAuto 1 -menter enter_handler
+# + I Module FvwmPerl
 # Add next to load desktop image (must be .xpm or .png)
 # + I Exec fvwm-root -r ~/tmp/MagicItemComp2_1280x1024.png
--- a/.xinitrc	Fri Jul 06 19:13:56 2012 +0300
+++ b/.xinitrc	Fri Jul 06 19:29:26 2012 +0300
@@ -15,6 +15,8 @@
 
 # Under Cygwin I prefer '-multiwindow' option, so it needn't to setup WM.
 if [[ -z $COMSPEC ]]; then
+  setxkbmap us,ru,ua
+  kbdd &
   if [[ -f ~/.xmodmaprc ]]; then
     xmodmap ~/.xmodmaprc
   fi