AFXColorButton

This class contains a label that precedes a color well, which allows the user to bring up a color dialog by double clicking.


AFXColorButton(p, text, tgt=None, sel=0, opts=0, x=0, y=0, w=0, h=0, pl=DEFAULT_SPACING, pr=DEFAULT_SPACING, pt=DEFAULT_SPACING, pb=DEFAULT_SPACING)

Constructor.

ArgumentTypeDefaultDescription
pFXComposite Parent widget.
textString Label string.
tgtFXObjectNoneMessage target.
selInt0Message ID.
optsInt0Options and hints.
xInt0X coordinate of origin.
yInt0Y coordinate of origin.
wInt0Width of the widget.
hInt0Width of the widget.
plIntDEFAULT_SPACINGLeft padding (margin).
prIntDEFAULT_SPACINGRight padding (margin).
ptIntDEFAULT_SPACINGTop padding (margin).
pbIntDEFAULT_SPACINGBottom padding (margin).


create()

Creates the color button widget.

Reimplemented from FXComposite.


disable()

Disables the color button.

Reimplemented from FXWindow.


enable()

Enables the color button.

Reimplemented from FXWindow.


getHelpText()

Returns the status line help text.


getLabelFont()

Returns the label font.


getLabelText()

Returns the label string.


getRGBA()

Returns the color of the button.


getTipText()

Returns the tool tip message.


setHelpText(text)

Sets the status line help text.

ArgumentTypeDefaultDescription
textString  


setLabelFont(fnt)

Sets the label font.

ArgumentTypeDefaultDescription
fntFXFont  


setLabelText(txt)

Sets the label string.

ArgumentTypeDefaultDescription
txtString  


setRGBA(clr)

Sets the color of the button.

ArgumentTypeDefaultDescription
clrFXColor  


setTipText(text)

Sets the tool tip message.

ArgumentTypeDefaultDescription
textString  


Class flags

Message ID's.

ID_COLORWELL

ID for color button.


Global flags

Flags for AFX color button options.

AFXCOLORBUTTON_VERTICAL

Orient label above button.