suis en train de mettre la radio dans le centre et un bouton en dessous, mais peu importe je l'essaie le radioBox est positionné dans le coin supérieur gauche du cadre et le bouton ne montre même pas! . Je ne comprends pas pourquoi cela se produitposition du widget dans un panneau en utilisant wxpython
class Panelchoose(wx.Panel):
"""
panel for calculating separately without saving
"""
def __init__(self ,*args, **kw):
super(Panelchoose, self).__init__(*args, **kw)
self.SetBackgroundColour('#48C9B0')
topsizer=wx.BoxSizer(wx.VERTICAL)
radiosizer=wx.BoxSizer(wx.VERTICAL)
btnsizer=wx.BoxSizer(wx.HORIZONTAL)
lblist=['calculationGrid','calculations','xyz2comcat']
self.rbox=wx.RadioBox(self,label="choose from the models below: ",
choices=lblist,majorDimension=3,
style=wx.RA_SPECIFY_ROWS)
btn_next=wx.Button(self ,label=" NEXT ")
#self.Bind(wx.EVT_BUTTON,self.next_, btn_next)
topsizer.Add(self.rbox,0,wx.CENTER|wx.ALIGN_CENTER_VERTICAL,10)
btnsizer.Add(btn_next,0,wx.ALIGN_CENTER_VERTICAL|wx.BOTTOM|wx.EXPAND,5)
topsizer.Add(btnsizer,4,wx.CENTER|wx.BOTTOM,10)
'topsizer.Add (btnsizer, 0, wx.CENTER | wx.BOTTOM, 10)' aurait l'air plus agréable! –
Assez vrai, bien que tout ce que j'essayais de faire était montrer OP ce qui n'allait pas. –
Merci, il a été résolu maintenant et j'ai compris la partie manquante – muna