GridBagSizer, can you specify different sized borders, top, bottom, left, right

Hi, I'm a new wxPython user and brand new to this list. I've been
searching the examples for any indication that you can specify
different borders, but have found none.

My current code looks something like this:

self.sizer.Add(self.logo, (0.7), flag = wx.TOP | wx.BOTTOM, border =
15)

Which is all well and good.

But what if I want to specify a different border, say 50, for wx.LEFT?

Is this possible, and if so, what is the syntax?

Thank you in advance.

Steve

Hi Steve,

ยทยทยท

On Apr 5, 1:08 pm, MiddleForkGIS <middlefork...@gmail.com> wrote:

Hi, I'm a new wxPython user and brand new to this list. I've been
searching the examples for any indication that you can specify
different borders, but have found none.

My current code looks something like this:

self.sizer.Add(self.logo, (0.7), flag = wx.TOP | wx.BOTTOM, border =
15)

Which is all well and good.

But what if I want to specify a different border, say 50, for wx.LEFT?

Is this possible, and if so, what is the syntax?

Thank you in advance.

Steve

That's simple. You just need to nest your sizers bit. Do something
like this:

topSizer = wx.BoxSizer(wx.VERTICAL)
topSizer.Add(self.sizer, 0, wx.LEFT, 50)

Things can get tricky when you need to EXPAND as well, but we'll cross
that bridge when we come to it.

-------------------
Mike Driscoll

Blog: http://blog.pythonlibrary.org