Tkinter.Text.index() puzzlement

David R. Smith DSmithSprint05 at earthlink.net
Sat Apr 20 20:59:04 EDT 2002


Matthew, thanks for your response.

I'm trying to add a textual read-eval-print cycle onto a program which is
mainly GUI-driven.  I thought I'd set a marker at the end of the
computer-generated output, e.g.,

    marker = text.index(END)

and then when the <Return> event strikes, pick up the text between marker
and text.index(END) as of that time, and send it off to eval.  This keeps
resulting in null strings, even though I entered  "123+456<Return>".  Then
the string might belatedly come through.  Is it hopeless to use
text.index() to do useful work?

    David Smith





More information about the Python-list mailing list