def _Event ( self , e ): """ 이벤트를 처리합니다 """ if e.char != "": ## 특수 기호나, 한글이 걸러짐 if e.keycode > 47 and e.keycode < 58:##숫자들만 걸러짐 id.Event_re ( id = "KeyEvent", char = e.char) elif e.keycode > 64 and e.keycode <91:##알파벳들 id.Event_re ( id = "KeyEvent", char = e.char) elif '힣' > e.char and e.char > 'ㄱ': id.Event_re ( id = "KeyEvent", char = e.char) elif e.keycode == 8: id.Event_re ( id = "KeyEvent", char = "Eraser") elif e.keycode == 13: id.Event_re ( id = "KeyEvent", char = "Enter") elif e.keycode == 9: id.Event_re ( id = "KeyEvent", char = "Tab") elif e.keycode == 32: id.Event_re ( id = "KeyEvent", char = "Space") else: ## 그외 한글이나 특수 버 if e.keycode == 0: ##한글이나, 특수문자들ㄹ 걸러짐 id.Event_re ( id = "KeyEvent", char = e.char) elif e.keycode == 8: print("지우길를 눌렀습니다.") id.Event_re ( id = "KeyEvent", char = "Eraser")
def click_event(self, event, Release): if Release == True: id.Event_re(id="TextClickRelease", Object=self) id.Event_re(id=self.id, Object=self) else: id.Event_re(id="TextClick", Object=self)
def click_event(self, event, Release): print(Release) if Release == True: id.Event_re(id=self.id, Object=self) else: id.Event_re(id="Button", Object=self)