I found recently that my keyboard (Linux Mint 4 KDE full version) was apparently locked up though the mouse was working. Logging out and in, restarting didn't fix it. The keyboard did work when logged in as root or as a new user to test it. I spent the day looking up similar problems online and finally found the answer.
The end result found in the evening? Sometime late the previous night just before I went to bed I must have been trying to change the text size in my browser by holding down the ALT key and using the scroll wheel on my trackball, with cookies popping up and interfering with the text size change. How did this cause it? KDE has accessibility features and if you hold a key too long it thinks that you want to use the slow keys function and pops up a window asking if you really do want to activate slow keys. I think it must have popped up just as I clicked on a cookie (to deny likely) and been clicked on without my even seeing it. The slow keys feature is so handicapped people who have trouble hitting the right key and hit several keys briefly but only the key they hold down will register. The keyboard would have responded if I held the keys longer.
After spending the day using my Windows machine to search for the answer I do know that switching back to Windows as my primary OS would be painful. I kept trying to switch desktops and scroll between open programs with the scroll wheel while pointing to the task bar.
I'm not an advanced Linux user and given how hard it was to find the answer I thought that sharing it here might help some people.