[plt-scheme] Re: MrEd - Animated canvas
With your idea, the flutters disappeared. It is super, thank you:)
Now, I seek how to associate events keyboard to an action. But my code
doesn't want to work :
(define my-canvas%
(class canvas%
(define/override (on-char evt)
(case (send evt get-key-code))
((left) (printf "left\n"))
((right) (printf "right\n"))
(else (printf "Another key\n")))
(super-new)))
Moreover, it is necessary to click in the canvas in order to events
keyboards start.
I don't understand why ?
Thanks,
Laurent