Phoenix Logo

phoenix_title wx.lib.agw.buttonpanel.ButtonPanelText

This class is used to hold data about the main caption in ButtonPanel.


class_hierarchy Class Hierarchy

Inheritance diagram for class ButtonPanelText:

method_summary Methods Summary

__init__ Default class constructor.
CreateDC Convenience function to create a wx.DC.
Draw Draws the main caption. Actually the drawing is done in BPArt.
GetBestSize Returns the best size for the main caption in ButtonPanel.
GetText Returns the caption text.
SetText Sets the caption text.

api Class API



class ButtonPanelText(Control)

This class is used to hold data about the main caption in ButtonPanel.


Methods



__init__(self, parent, text="")

Default class constructor.

Parameters:
  • parent – the text parent object, an instance of ButtonPanel;
  • text (string) – the actual main caption string.


CreateDC(self)

Convenience function to create a wx.DC.



Draw(self, dc, rect)

Draws the main caption. Actually the drawing is done in BPArt.

Parameters:
  • dc – an instance of wx.DC;
  • rect (wx.Rect) – the main caption text client rectangle.


GetBestSize(self)

Returns the best size for the main caption in ButtonPanel.

Returns:An instance of wx.Size.


GetText(self)

Returns the caption text.

Returns:A string representing the caption text.


SetText(self, text="")

Sets the caption text.

Parameters:text (string) – the main caption string.