سؤال

I have a Button and a Text Widget. When a user click the Button, I want to know if the text in the Text Widget has been modified since the last time the user clicked the Button.

How do I check this?

هل كانت مفيدة؟

المحلول

The invocation

$t edit modified

(where t holds the pathname of your text widget) should tell you if the text widget has been modified. Reset with

$t edit modified false

or whatever the corresponding Perl-Tk is.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top