On Windows the text widget hi-lights will disappear when text widget loses focus. Linux and Mac OS X Tk behaves appropriately. This bug is generated from a number of bugs for IDLE (Python's IDE) here http://bugs.python.org/issue14146. On Windows the IDLE debugger no longer hi-lights the current line in the editor. On Windows the find/replace functions are not functioning properly because found text is not hi-lighted. The issue was tested using Tk 8.5.13 and Tk 8.6 both exhibit the same problem. We created a small test program to reproduce this bug with Python 3.x and tkinter:
from tkinter import *
main = Tk()
text = Text(main, width=40, height=10, wrap="char")
text.pack()
text.insert(INSERT, "".join(map(str, range(100))))
text.tag_add(SEL, "1.0", "end")
text.focus_set()
def jump():
text.after(500, btn.focus_set)
text.after(1000, text.focus_set)
btn = Button(main, text="Click me", command=jump)
btn.pack()
main.mainloop()
Thanks for your help!
I should add the find/replace dialog issue with IDLE is here:
http://bugs.python.org/issue17511