Rewrite keyboard emulation for Windows

The keyboard emulation through SendKeys had some issues. Namely, it was not possible to emulate Windows key or a lot of special keys. It also didn't emulate keys, rather it sent characters to the foreground application.

I have rewritten the emulation using SendInput, which is a little more low-level. It can emulate most keys on the OS level, and it uses CTypes. It also has support for outputting Unicode characters using VK_PACKET. For more information, the commit messages have details surrounded around the various commits.