phoenix_title wx.lib.buttons

This module implements various forms of generic buttons, meaning that they are not built on native controls but are self-drawn.

Description

This module implements various forms of generic buttons, meaning that they are not built on native controls but are self-drawn. They act like normal buttons but you are able to better control how they look, bevel width, colours, etc…

Usage

Sample usage:

import wx
import wx.lib.buttons as buttons

class MyFrame(wx.Frame):
    def __init__(self, parent, title):

        wx.Frame.__init__(self, parent, wx.ID_ANY, title, size=(400, 300))
        panel = wx.Panel(self)

        # Build a bitmap button and a normal one
        bmp = wx.ArtProvider.GetBitmap(wx.ART_INFORMATION, wx.ART_OTHER, (16, 16))
        btn1 = buttons.ThemedGenBitmapButton(panel, -1, bmp, pos=(50, 50))

        btn2 = buttons.GenButton(panel, -1, "Hello World!", pos=(50, 100))


app = wx.App()
frame = MyFrame(None, 'wx.lib.buttons Test')
frame.Show()
app.MainLoop()

class_summary Classes Summary

__ThemedMixin

Uses the native renderer to draw the bezel, also handle mouse-overs.

__ToggleMixin

A mixin that allows to transform GenButton in the corresponding

GenBitmapButton

A generic bitmap button.

GenBitmapTextButton

A generic bitmapped button with text label.

GenBitmapTextToggleButton

A generic toggle bitmap button with text label.

GenBitmapToggleButton

A generic toggle bitmap button.

GenButton

A generic button, and base class for the other generic buttons.

GenButtonEvent

Event sent from the generic buttons when the button is activated.

GenToggleButton

A generic toggle button.

ThemedGenBitmapButton

A themed generic bitmap button.

ThemedGenBitmapTextButton

A themed generic bitmapped button with text label.

ThemedGenBitmapTextToggleButton

A themed generic toggle bitmap button with text label.

ThemedGenBitmapToggleButton

A themed generic toggle bitmap button.

ThemedGenButton

A themed generic button.

ThemedGenToggleButton

A themed generic toggle button.