Is there a way to make the Tkinter text widget read only?

rectangletangle picture rectangletangle · Oct 1, 2010 · Viewed 93.7k times · Source

It doesn't look like it has that attribute, but it'd be really useful to me.

Answer

ars picture ars · Oct 1, 2010

You have to change the state of the Text widget from NORMAL to DISABLED after entering text.insert() or text.bind() :

text.config(state=DISABLED)