wx.StaticBox label's alignment

python, wxpython

Solution

You can try passing alignment flags to the style parameter, but I wasn't able to get that to work on Windows. It may be OS dependent or it may just not be supported. You may be better off just drawing it yourself using wx.DC or similar. There are drawing examples in the wxPython demo you can use to get started.

Problem

I am writing program in python using wx library. I can not find answer for the following question: Is it possible to change label's alignment for wx.StaticBox (from Left to Center)? That is, given I have this: ``` ASysBox = wx.StaticBox(self, label='System A') ``` I need to align center 'System A' header Thanks for your time and consideration.

Original source