简体   繁体   中英

Turtle Onkey - Enter Key

Simple question, what is the term for the Enter key for Turtle.Onkey()

I've tried turtle.onkey(check, 'Enter') but I get the error:

TclError: bad event type or keysym "Enter"

So, I think that I have entered the wrong word for 'Enter'

Just in-case you don't know what the Enter key, here it is:P

回车键

Use 'Return' For example, turtle.onkey(check, 'Return') .

turtle.onkey(check, 'return')

This should do it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM