How can I add a outline border to a widget in wxpython? (Any widget, for example, a wx.Button
)
For panel, you can use
p = wx.Panel(....., style=wx.SUNKEN_BORDER)
there you can choose from constants:
wx.SIMPLE_BORDER
wx.RAISED_BORDER
wx.SUNKEN_BORDER
wx.NO_BORDER
If you want to create border around wx.Button
, i would use my custom bitmap with wx.BitmapButton
:
b = wx.BitmapButton(pane, -1, wx.Bitmap('buttons/my_beautiful_button.png'))
For any widget, i think you can always create a wx.Panel
with some border and put the widget into the panel.