cbpporter Messages: 1427 Registered: September 2007
Ultimate Contributor
Hi alendar,
ButtonOption is a full featured widget that behaves pretty much the way you described it and it does have text. It is not a secret because it is not in the right click list in the layout editor.
A lot of widgets can only be accessed by editing the class field in the editor. This is less than optimal though .
Right now I consider it almost deprecated and use ToolButton instead, but that doesn't mean that ButtonOption does not do its job right. ToolButton is meant for ToolBars, but it works well anywhere. If you choose to use ButtonOption, you can set the text with SetLabel. It is simpler than ToolButton, and might be the right thing for your needs. You can also set the style to flat with StyleFlat(), and you will get a quite popular flat two state button which appears in a lot of applications.