We are about to switch to a new forum software. Until then we have removed the registration on this forum.
hello, is there a quick trick to register a "keyEvent" method in processing applet so i could register keyboard handling in any of my classes?
As far as i know we can register "draw", "pre", "post" and "mouseEvent" , keyboard input would also be helpful! If it's not currently supported, is there any quick tweak inside PApplet class to do it? I find method registering very useful :)
thanks for feedback
Answers
keyPressed, keyTyped, keyReleased.....
see reference
I guess you've meant registerMethod(), right? ;)
Dunno how you've reached the conclusion that "mouseEvent" is recognized, but not "keyEvent"?! :-/
Just take a look at registerMethod() inside class PApplet itself:
https://github.com/processing/processing/blob/master/core/src/processing/core/PApplet.java#L1342