coffeedrinker |
2008-08-06 03:34 |
fvwmbuttons keyboard
I posted this in another thread, but thought I would put it here along with some modifications I made. I changed a few colors and now the return key works in all gtk apps so no more hildon-input-method.
edit: Caps, shift, ctrl all working (ctrl only sends lower case for now)
I use these styles for the windows:
Code:
Style *vk* Title, NeverFocus, StaysOnTop
Style *sym* Title, NeverFocus, StaysOnTop
And launch the keyboard with this command:
Code:
Module FvwmButtons vk -g 420x170+348+298
Code:
DestroyFunc sendfakekey
AddToFunc sendfakekey
+ I Test (EnvMatch fakectrl 1) FakeKeypress modifiers 8 press $0 modifiers -8
+ I TestRc (NoMatch) Test (EnvMatch fakecaps 1) FakeKeypress modifiers 7 press $0 modifiers -7
+ I TestRc (NoMatch) Test (EnvMatch fakeshift 1) FakeKeypress modifiers 7 press $0 modifiers -7
+ I TestRc (NoMatch) FakeKeypress press $0
+ I Test (EnvMatch fakectrl 1) setfakectrl
+ I Test (EnvMatch fakeshift 1) setfakeshift
DestroyFunc setfakecaps
AddToFunc setfakecaps
+ I Test (EnvMatch fakecaps 1) SetEnv fakecaps 0
+ I TestRc (NoMatch) SetEnv fakecaps 1
+ I Test (EnvMatch fakecaps 1) SendToModule vk ChangeButton caps Title CP
+ I TestRc (NoMatch) SendToModule vk ChangeButton caps Title cp
DestroyFunc setfakectrl
AddToFunc setfakectrl
+ I Test (EnvMatch fakectrl 1) SetEnv fakectrl 0
+ I TestRc (NoMatch) SetEnv fakectrl 1
+ I Test (EnvMatch fakectrl 1) SendToModule vk ChangeButton ctrl Title ^
+ I TestRc (NoMatch) SendToModule vk ChangeButton ctrl Title "ct"
DestroyFunc setfakeshift
AddToFunc setfakeshift
+ I Test (EnvMatch fakeshift 1) SetEnv fakeshift 0
+ I TestRc (NoMatch) SetEnv fakeshift 1
+ I Test (EnvMatch fakeshift 1) SendToModule vk ChangeButton shift Title SH
+ I TestRc (NoMatch) SendToModule vk ChangeButton shift Title sh
Module FvwmButtons: vk
#*vk: Geometry 720x400
*vk: ButtonGeometry 30x34
*vk: Rows 5
*vk: Columns 14
*vk: BoxSize fixed
*vk: Font "xft:Tahoma:antialias=True:pixelsize=24"
*vk: Fore black
*vk: Back white
*vk: (2x1, fore white, back red, Title ">>", Action (Mouse 1) FakeKeypress press Tab)
*vk: (1x1, Title "1", Action (Mouse 1) FakeKeypress press 1)
*vk: (1x1, Title "2", Action (Mouse 1) FakeKeypress press 2)
*vk: (1x1, Title "3", Action (Mouse 1) FakeKeypress press 3)
*vk: (1x1, Title "4", Action (Mouse 1) FakeKeypress press 4)
*vk: (1x1, Title "5", Action (Mouse 1) FakeKeypress press 5)
*vk: (1x1, Title "6", Action (Mouse 1) FakeKeypress press 6)
*vk: (1x1, Title "7", Action (Mouse 1) FakeKeypress press 7)
*vk: (1x1, Title "8", Action (Mouse 1) FakeKeypress press 8)
*vk: (1x1, Title "9", Action (Mouse 1) FakeKeypress press 9)
*vk: (1x1, Title "0", Action (Mouse 1) FakeKeypress press 0)
*vk: (2x1, fore white, back red, Title "<<<", Action (Mouse 1) FakeKeypress press BackSpace)
*vk: (2x1, fore white, back red, Title ">>", Action (Mouse 1) FakeKeypress press Tab)
*vk: (1x1, Title "q", Action (Mouse 1) sendfakekey q)
*vk: (1x1, Title "w", Action (Mouse 1) sendfakekey w)
*vk: (1x1, Title "e", Action (Mouse 1) sendfakekey e)
*vk: (1x1, Title "r", Action (Mouse 1) sendfakekey r)
*vk: (1x1, Title "t", Action (Mouse 1) sendfakekey t)
*vk: (1x1, Title "y", Action (Mouse 1) sendfakekey y)
*vk: (1x1, Title "u", Action (Mouse 1) sendfakekey u)
*vk: (1x1, Title "i", Action (Mouse 1) sendfakekey i)
*vk: (1x1, Title "o", Action (Mouse 1) sendfakekey o)
*vk: (1x1, Title "p", Action (Mouse 1) sendfakekey p)
*vk: (2x1, fore white, back blue, Title "RTN", Action (Mouse 1) FakeKeypress press KP_Enter)
*vk: (2x1, fore white, back blue, Id caps, Title "cp", Action (Mouse 1) setfakecaps)
*vk: (1x1, Title "a", Action (Mouse 1) sendfakekey a)
*vk: (1x1, Title "s", Action (Mouse 1) sendfakekey s)
*vk: (1x1, Title "d", Action (Mouse 1) sendfakekey d)
*vk: (1x1, Title "f", Action (Mouse 1) sendfakekey f)
*vk: (1x1, Title "g", Action (Mouse 1) sendfakekey g)
*vk: (1x1, Title "h", Action (Mouse 1) sendfakekey h)
*vk: (1x1, Title "j", Action (Mouse 1) sendfakekey j)
*vk: (1x1, Title "k", Action (Mouse 1) sendfakekey k)
*vk: (1x1, Title "l", Action (Mouse 1) sendfakekey l)
*vk: (1x1, Title ":", Action (Mouse 1) FakeKeypress press colon)
*vk: (1x1, Title "/", Action (Mouse 1) FakeKeypress press slash)
*vk: (1x1, Title "@", Action (Mouse 1) FakeKeypress press at)
*vk: (2x1, fore white, back green, Id shift, Title "sh", Action (Mouse 1) setfakeshift)
*vk: (1x1, Title "z", Action (Mouse 1) sendfakekey z)
*vk: (1x1, Title "x", Action (Mouse 1) sendfakekey x)
*vk: (1x1, Title "c", Action (Mouse 1) sendfakekey c)
*vk: (1x1, Title "v", Action (Mouse 1) sendfakekey v)
*vk: (1x1, Title "b", Action (Mouse 1) sendfakekey b)
*vk: (1x1, Title "n", Action (Mouse 1) sendfakekey n)
*vk: (1x1, Title "m", Action (Mouse 1) sendfakekey m)
*vk: (1x1, Title ",", Action (Mouse 1) FakeKeypress press comma)
*vk: (1x1, Title ".", Action (Mouse 1) FakeKeypress press period)
*vk: (1x1, Title "'", Action (Mouse 1) FakeKeypress press quoteright)
*vk: (1x1, Title "\"", Action (Mouse 1) FakeKeypress press quotedbl)
*vk: (1x1, Title "-", Action (Mouse 1) FakeKeypress press minus)
#*vk: (1x1, fore white, back blue, Id caps, Title "c", Action (Mouse 1) setfakecaps)
*vk: (2x1, fore white, back black, Id ctrl, Title "ct", Action (Mouse 1) setfakectrl)
#*vk: (2x1, fore white, back red, Title ">>>", Action (Mouse 1) FakeKeypress press Tab)
*vk: (9x1, Title " ", Action (Mouse 1) FakeKeypress press space)
*vk: (1x1, back red, Title " ", Action "Module FvwmButtons sym -g 250x110+0+302")
Module FvwmButtons: sym
#*sym: Geometry 720x400
*sym: ButtonGeometry 30x34
*sym: Rows 3
*sym: Columns 8
*sym: BoxSize fixed
*sym: Font "xft:Tahoma:antialias=True:pixelsize=24"
*sym: Fore white
*sym: Back black
*sym: (1x1, Title "!", Action (Mouse 1) FakeKeypress press exclam)
*sym: (1x1, Title "#", Action (Mouse 1) FakeKeypress press numbersign)
*sym: (1x1, Title "$", Action (Mouse 1) FakeKeypress press dollar)
*sym: (1x1, Title "\%", Action (Mouse 1) FakeKeypress press percent)
*sym: (1x1, Title "^", Action (Mouse 1) FakeKeypress press asciicircum)
*sym: (1x1, Title "&", Action (Mouse 1) FakeKeypress press ampersand)
*sym: (1x1, Title "*", Action (Mouse 1) FakeKeypress press asterisk)
*sym: (1x1, Title "_", Action (Mouse 1) FakeKeypress press underscore)
*sym: (1x1, Title "+", Action (Mouse 1) FakeKeypress press plus)
*sym: (1x1, Title "=", Action (Mouse 1) FakeKeypress press equal)
*sym: (1x1, Title ";", Action (Mouse 1) FakeKeypress press semicolon)
*sym: (1x1, Title "?", Action (Mouse 1) FakeKeypress press question)
*sym: (1x1, Title "\\", Action (Mouse 1) FakeKeypress press backslash)
*sym: (1x1, Title "`", Action (Mouse 1) FakeKeypress press quoteleft)
*sym: (1x1, Title "~", Action (Mouse 1) FakeKeypress press asciitilde)
*sym: (1x1, Title "|", Action (Mouse 1) FakeKeypress press bar)
*sym: (1x1, Title "(", Action (Mouse 1) FakeKeypress press parenleft)
*sym: (1x1, Title ")" Action (Mouse 1) FakeKeypress press parenright)
*sym: (1x1, Title "<", Action (Mouse 1) FakeKeypress press less)
*sym: (1x1, Title ">", Action (Mouse 1) FakeKeypress press greater)
*sym: (1x1, Title "[", Action (Mouse 1) FakeKeypress press bracketleft)
*sym: (1x1, Title "]", Action (Mouse 1) FakeKeypress press bracketright)
*sym: (1x1, Title "{", Action (Mouse 1) FakeKeypress press braceleft)
*sym: (1x1, Title "}", Action (Mouse 1) FakeKeypress press braceright)
|