AGW Logo

rulerctrl functions

This is the description of standalone Python functions in the rulerctrl module.

method_summary Functions Summary


ConvertPILToWX Converts a PIL image into a wx.Image.
ConvertWXToPIL Converts a wx.Image into a PIL image.
GetIndicatorBitmap Returns the image indicator as a wx.Bitmap.
GetIndicatorData Returns the image indicator as a decompressed stream of characters.
GetIndicatorImage Returns the image indicator as a wx.Image.
MakePalette Creates a palette to be applied on an image based on input colour.

API Functions API



ConvertPILToWX(pil, alpha=True)[source]

Converts a PIL image into a wx.Image.

Parameters:
  • pil – a PIL image;
  • alphaTrue if the image contains alpha transparency, False otherwise.

Note

Requires PIL (Python Imaging Library), which can be downloaded from http://www.pythonware.com/products/pil/



ConvertWXToPIL(bmp)[source]

Converts a wx.Image into a PIL image.

Parameters:bmp – an instance of wx.Image.

Note

Requires PIL (Python Imaging Library), which can be downloaded from http://www.pythonware.com/products/pil/



GetIndicatorBitmap()[source]

Returns the image indicator as a wx.Bitmap.



GetIndicatorData()[source]

Returns the image indicator as a decompressed stream of characters.



GetIndicatorImage()[source]

Returns the image indicator as a wx.Image.



MakePalette(tr, tg, tb)[source]

Creates a palette to be applied on an image based on input colour.

Parameters:
  • tr – the red intensity of the input colour;
  • tg – the green intensity of the input colour;
  • tb – the blue intensity of the input colour.
Tree

Table Of Contents

Previous topic

RulerCtrlEvent

Next topic

SVN Revision 68362 For rulerctrl