Ross Goodell | 1 Oct 16:06

How can I find out the state of capslock?

Although I can use KeyEvent#shift_down to find out if the shift key was
held down when a key is pressed, I don't know how to find out if the
capslock key is in effect (the capslock key was pressed the capslock LED
is on, and other programs are treating an 'a' keypress as an 'A').  I
could catch capslock keypresses by checking evt.get_key_code for 311,
but don't know what the starting capslock state is since it might have
been set when the user was in another program.  Can someone tell me how
to find out what what the capslock state is?

Thanks, Ross
--

-- 
Posted via http://www.ruby-forum.com/.

Gmane