| Saturday, March 05, 2005 - 10:55 am |
I tried to map hiragana to my keyboard using a hook and the clipboard (because WM_CHAR / WM_UNICHAR wasn't doing it).
It's working a bit so-so. While Skype, notepad, explorer and other programs handle it if the data is only available in CF_UNICODETEXT most RTF applications fails to paste anything.
How do I convert this so more applications can paste it?
void ClipBoard(void* dat, int len)
HANDLE hData = GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, len + 2);
char* CB = (char*) GlobalLock(hData);
memcpy(CB, dat, len);
CB[len] = 0;
CB[len+1] = 0;
(Caps locks on = hiragana mode, off = normal mode)
These executables are guarantied to:
- Crash wordpad
- Contain at least 1 serius flaw yet to be discovered
- Contain at least 1 minor flaw yet to be discovered