def METHOD_NAME(self, *a):
    cmd = self.entry.get_text()
    if cmd == 'HALMETER':
        self.load_halmeter()
        return
    elif cmd == 'STATUS':
        self.load_status()
        return
    elif cmd == 'HALSHOW':
        self.load_halshow()
        return
    if not cmd:
        return
    #ensure_mode(self.stat, self.linuxcnc, linuxcnc.MODE_MDI)
    name = cmd.split()
    path = self.foldername+ "/" + name[0] + ".ngc"
    self.emit('macro-submitted',path,cmd)
    #self.linuxcnc.mdi(cmd)
    self.entry.set_text('')
    self.entry.grab_focus()