Please suggest the best way to create key events for HTML5 canvas. I don’t prefer any library, but if you think that it’s the best way then go answer it. Thanks in advance!
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This will return the key code:
If you would like a demonstration of different things being done based on key:
Or if you have a long list of keys you’ll be using, do it in a switch case: