First app, thanks people

Will McGugan news at NOwillmcguganSPAM.com
Mon Jul 25 12:17:44 EDT 2005


Jan Danielsson wrote:
.
> 
>    Oh, I do have one more question though. I'm using wxPython, and when
> I check for keys I use the evt.GetKeyCode() call, and compare it with
> integers which I have found by printing what event.GetKeyCode() returns.
> I would prefer a more portable way, since I assume that F1 doesn't have
> the same code on a Sparc Ultra10. (?) Is there a way to get "key codes"
> in wxPython in a portable manner?

Hi,

You should use the keycode constants.

http://www.wxwidgets.org/manuals/2.6.1/wx_keycodes.html#keycodes


Will

-- 
http://www.willmcgugan.com
"".join({'*':'@','^':'.'}.get(c,0) or chr(97+(ord(c)-84)%26) for c in 
"jvyy*jvyyzpthtna^pbz")



More information about the Python-list mailing list