Results 1 to 3 of 3

Thread: Directinput and text input, the best way ?

  1. #1

    Directinput and text input, the best way ?

    Hello All !

    Well, another boring question...

    Directinput is a great way to handle user input, but when it comes to handle text input it's not as simple as it seems

    Do I need to translate DIK keys in char ?

    or use WM_CHAR message in my window message handlin procedure ?

    If you have some tricks, please let me know...

    many thanks

  2. #2

    Directinput and text input, the best way ?

    I suggest you use WM_CHAR as it is far easier, and because Directinput indirectly uses WM_CHAR anyway (AFAIK). By using WM_CHAR, you can save yourself the troubles of writing a system that converts Directinput keystate data to KeyPress/KeyRelease events. Moreover you need your program to resend these messages when the user holds a character key (so he can type "aaaaaa", by holding 'a'). By using WM_CHAR you get all this functionality anyway and as far as i can tell, there are no drawbacks.

    Check this link for reasons not to use Directinput for keyboard and mouse.
    Coders rule nr 1: Face ur bugz.. dont cage them with code, kill'em with ur cursor.

  3. #3

    Directinput and text input, the best way ?

    thanks for the advice !

    I'm already facing problems, since I thought i could handle user input with a queue... i don't have the results i expected..


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Comodo SSL