phoenix_title wx.GraphicsGradientStop¶

Represents a single gradient stop in a collection of gradient stops as represented by wx.GraphicsGradientStops.

Added in version 2.9.1.


class_hierarchy Class Hierarchy¶

Inheritance diagram for class GraphicsGradientStop:

method_summary Methods Summary¶

__init__

Creates a stop with the given colour and position.

GetColour

Return the stop colour.

GetPosition

Return the stop position.

SetColour

Change the stop colour.

SetPosition

Change the stop position.


property_summary Properties Summary¶

Colour

See GetColour and SetColour

Position

See GetPosition and SetPosition


api Class API¶

class wx.GraphicsGradientStop(object)¶

Possible constructors:

GraphicsGradientStop(col=TransparentColour, pos=0.) -> None

Represents a single gradient stop in a collection of gradient stops as represented by GraphicsGradientStops.


Methods¶

__init__(self, col=TransparentColour, pos=0.)¶

Creates a stop with the given colour and position.

Parameters:
  • col (wx.Colour) – The colour of this stop. Note that the alpha component of the colour is honoured thus allowing the background colours to partially show through the gradient.

  • pos (float) – The stop position, must be in [0, 1] range with 0 being the beginning and 1 the end of the gradient.

Return type:

None



GetColour(self)¶

Return the stop colour.

Return type:

wx.Colour



GetPosition(self)¶

Return the stop position.

Return type:

float



SetColour(self, col)¶

Change the stop colour.

Parameters:

col (wx.Colour) – The new colour.

Return type:

None



SetPosition(self, pos)¶

Change the stop position.

Parameters:

pos (float) – The new position, must always be in [0, 1] range.

Return type:

None


Properties¶

Colour¶

See GetColour and SetColour



Position¶

See GetPosition and SetPosition