예제 #1
0
    def __init__(self, fv):
        # superclass defines some variables for us, like logger
        super(IRAFBase, self).__init__(fv)

        self.keyqueue = Queue.Queue()
        self.keyevent = threading.Event()
        self.keymap = {
            'comma': ',',
        }
        self.ctrldown = False

        self.layertag = 'iraf-canvas'
        # this will be set in initialize()
        self.canvas = None

        self.addr = iis.get_interface()

        self.ev_quit = self.fv.ev_quit
        self.dataTask = None

        # colormap for use with IRAF displays
        self.cm_iis = cmap.ColorMap('iis_iraf', cmap_iis_iraf)
        self.im_iis = imap.get_imap('ultrasmooth')

        fv.add_callback('add-channel', self.add_channel)
        fv.add_callback('delete-channel', self.delete_channel)
예제 #2
0
파일: IRAF.py 프로젝트: zhouyaoji/ginga
    def __init__(self, fv):
        # superclass defines some variables for us, like logger
        super(IRAF, self).__init__(fv)

        self.keyqueue = Queue.Queue()
        self.keyevent = threading.Event()
        self.keymap = {
            'comma': ',',
        }
        self.ctrldown = False

        self.layertag = 'iraf-canvas'
        # this will be set in initialize()
        self.canvas = None
        self.dc = fv.get_draw_classes()

        self.addr = iis.get_interface()

        self.ev_quit = self.fv.ev_quit
        self.data_task = None

        # Holds frame buffers
        self.fb = {}
        self.current_frame = 0

        # cursor position
        self.cursor_x = 1.0
        self.cursor_y = 1.0

        self.mode = 'ginga'
        self.imexam_active = False
        self.imexam_chname = None

        # init the first frame(frame 0)
        self.init_frame(0)

        # colormap for use with IRAF displays
        self.cm_iis = cmap.ColorMap('iis_iraf', cmap_iis_iraf)
        self.im_iis = imap.get_imap('ultrasmooth')

        fv.add_callback('add-channel', self.add_channel)
        fv.add_callback('delete-channel', self.delete_channel)
        #fv.set_callback('channel-change', self.focus_cb)

        self.gui_up = False