5

How can I find out when the text has been changed in a text view widget in the GTK3 framework? I think there must be a signal associated with it, but could not find it. For example, there is an ontextchanged signal in qt4, so there should be a similar signal in GTK. I am using Python.

rob74
  • 4,939
  • 29
  • 31
Gaurav Sood
  • 157
  • 3
  • 16
  • The answer is correct (I have just checked), could you please accept it so it is ranked higher in the search results? – rob74 Nov 25 '12 at 10:20

1 Answers1

11

Every TextView widget is associated to a TextBuffer object. The signal you are looking for is changed but of the associated text buffer. If you create a TextView without an associated buffer, a default one is created for you and you can retrieve it with textview.get_buffer()

mg.
  • 7,822
  • 1
  • 26
  • 30