def focus_out(self, event = None): value = self.value.get() if self.unicode: value = unicodify(value) else: value = encode (value) if value != self.old_value: self.validate()
def validate(self, event = None): value = self.text.get("0.0", "end") if value[-1] == "\n": value = value[0:-1] if self.unicode: value = unicodify(value) else: value = encode (value) self.set_value(value)
def validate(self, event = None): value = self.value.get() if self.unicode: value = unicodify(value) else: value = encode (value) self.old_value = value self.set_value(value)