Пример #1
0
def epar(theTask, parent=None, isChild=0):

    if wutil is None or not wutil.hasGraphics:
        raise IrafError("Cannot run epar without graphics windows")

    if not isChild:
        oldFoc = wutil.getFocalWindowID()
        wutil.forceFocusToNewWindow()

    PyrafEparDialog(theTask, parent, isChild)

    if not isChild:
        wutil.setFocusTo(oldFoc)
Пример #2
0
 def Destroy(self, event=None):
     if event:
         # make sure button release occurred in window
         # tkinter should take care of this but doesn't
         if event.x<0 or event.x>=self.winfo_width() or \
            event.y<0 or event.y>=self.winfo_height():
             self['cursor'] = self.defaultCursor
             return
     self.destroy()
     # disable future writes
     self.text = None
     self.update_idletasks()
     # put focus back on terminal (if set)
     if self.__termWin:
         wutil.setFocusTo(self.__termWin)
Пример #3
0
 def Destroy(self, event=None):
     if event:
         # make sure button release occurred in window
         # tkinter should take care of this but doesn't
         if event.x<0 or event.x>=self.winfo_width() or \
            event.y<0 or event.y>=self.winfo_height():
             self['cursor'] = self.defaultCursor
             return
     self.destroy()
     # disable future writes
     self.text = None
     self.update_idletasks()
     # put focus back on terminal (if set)
     if self.__termWin:
         wutil.setFocusTo(self.__termWin)