simulating keyboard events
Martin Franklin
mfranklin1 at gatwick.westerngeco.slb.com
Mon Mar 31 08:59:31 EST 2003
On Monday 31 March 2003 14:21, Michael Hudson wrote:
> student00 at angelfire.com (student) writes:
> > is there an easy way to simulate a keyboard event in python..
>
> I doubt it, but I don't actually know...
>
I don;t really know how to do this either but read on.....
> > i need to send a 'Delete' key event to a text widget (at the current
> > cursor position/selection)
>
If this is a Tkinter Text widget and all you want to do is delete the last
inserted character then this should work:-
text.delete("insert - 1 char", "insert")
Cheers
Martin
More information about the Python-list
mailing list