MCPcopy Create free account
hub / github.com/Image-Py/imagepy / __init__

Method __init__

imagepy/ui/widgets/normal.py:236–249  ·  view source on GitHub ↗
( self, parent, choices, title)

Source from the content-addressed store, hash-verified

234
235class Choices(wx.Panel):
236 def __init__( self, parent, choices, title):
237 self.choices = list(choices)
238 wx.Panel.__init__(self, parent)
239
240 sizer = wx.BoxSizer(wx.VERTICAL)
241 lab_title = wx.StaticText( self, wx.ID_ANY, title,
242 wx.DefaultPosition, wx.DefaultSize)
243 lab_title.Wrap( -1 )
244 sizer.Add( lab_title, 0, wx.ALL, 5 )
245 self.ctrl = wx.CheckListBox(self, -1, (80, 50), wx.DefaultSize, [str(i) for i in choices])
246 sizer.Add( self.ctrl, 1, wx.ALL|wx.EXPAND, 0 )
247 self.ctrl.SetMaxSize( wx.Size( -1,100 ) )
248 self.SetSizer(sizer)
249 self.ctrl.Bind(wx.EVT_CHECKLISTBOX, self.on_check)
250
251 def Bind(self, z, f):
252 self.f = f

Callers

nothing calls this directly

Calls 2

__init__Method · 0.45
BindMethod · 0.45

Tested by

no test coverage detected