def __init__(self, parent, size=(475, 325), **kws):
        self.parent = parent
        conf  = parent.conf
        kws['style'] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, parent, -1, size=size,
                          title='XRF Line Selection', **kws)
        panel = GridPanel(self)
        self.checkbox = {}
        def add_elines(panel, lines, checked):
            for i in lines:
                cb = Check(panel, '%s ' % i, default = checked in i,
                           action=partial(self.onLine, label=i, lines=checked))
                self.checkbox[i] = cb
                panel.Add(cb, style=LEFT)

        hopts = {'size': (125, -1), 'bgcolour': (250, 250, 200)}
        labopts = {'newrow': True, 'style': LEFT}
        self.linedata = {'Major K Lines:': self.k1lines,
                         'Minor K Lines:': self.k2lines,
                         'Major L Lines:': self.l1lines,
                         'Minor L Lines:': self.l2lines+self.l3lines,
                         'Major M Lines:': self.mlines}
        panel.AddText(' Select X-ray Emission Lines', dcol=4, colour='#880000')
        panel.Add(HLine(panel, size=(450, 3)),  dcol=5, newrow=True)

        panel.Add(HyperText(panel, 'Major K Lines:',
                            action=partial(self.ToggleLines, lines=conf.K_major),
                            **hopts), **labopts)
        add_elines(panel, self.k1lines, conf.K_major)

        panel.Add(HyperText(panel, 'Minor K Lines:',
                            action=partial(self.ToggleLines, lines=conf.K_minor),
                            **hopts), **labopts)
        add_elines(panel, self.k2lines, conf.K_minor)

        panel.Add(HyperText(panel, 'Major L Lines:',
                            action=partial(self.ToggleLines, lines=conf.L_major),
                            **hopts), **labopts)
        add_elines(panel, self.l1lines, conf.L_major)

        panel.Add(HyperText(panel, 'Minor L Lines:',
                            action=partial(self.ToggleLines, lines=conf.L_minor),
                            **hopts), **labopts)
        add_elines(panel, self.l2lines, conf.L_minor)

        panel.AddText(' ', **labopts)
        add_elines(panel, self.l3lines, conf.L_minor)

        panel.Add(HyperText(panel, 'Major M Lines:',
                            action=partial(self.ToggleLines, lines=conf.M_major),
                            **hopts), **labopts)
        add_elines(panel, self.mlines,  conf.M_major)

        panel.AddText('Energy Range (keV): ', **labopts)
        fopts = {'minval':0, 'maxval':1000, 'precision':2, 'size':(75, -1)}
        panel.Add(FloatCtrl(panel, value=conf.e_min,
                            action=partial(self.onErange, is_max=False),
                            **fopts),  dcol=2, style=LEFT)

        panel.AddText(' : ')
        panel.Add(FloatCtrl(panel, value=conf.e_max,
                            action=partial(self.onErange, is_max=True),
                            **fopts), dcol=2, style=LEFT)

        panel.Add(HLine(panel, size=(450, 3)),  dcol=5, newrow=True)
        panel.Add(Button(panel, 'Done', size=(80, -1), action=self.onDone),
                  newrow=True, style=LEFT)
        panel.pack()
        self.Show()
        self.Raise()
dataset/ETHPy150Open xraypy/xraylarch/plugins/wx/xrfdisplay_utils.py/XrayLinesFrame.__init__/swapped operands of `in`