wx.lib.ogl.bmpshape.BitmapShape¶
The wx.BitmapShape
class draws a bitmap (non-resizable).
Class Hierarchy¶
Known Superclasses¶
wx.lib.ogl.basic.RectangleShape
Methods Summary¶
Default class constructor. |
|
Get the associated bitmap. |
|
Return the bitmap filename. |
|
The draw handler. |
|
Set the associated bitmap. |
|
Set the bitmap filename. |
|
Set the size. |
Class API¶
- class BitmapShape(RectangleShape)¶
The
wx.BitmapShape
class draws a bitmap (non-resizable).
Methods¶
- __init__(self)¶
Default class constructor.
- GetBitmap(self)¶
Get the associated bitmap.
- GetFilename(self)¶
Return the bitmap filename.
- OnDraw(self, dc)¶
The draw handler.
- SetBitmap(self, bitmap)¶
Set the associated bitmap.
- Parameters:
bitmap – a
wx.Bitmap
instance
Note
You can delete the bitmap from the calling application, since reference counting will take care of holding on to the internal bitmap data.
- SetFilename(self, f)¶
Set the bitmap filename.
- Parameters:
f (str) – the bitmap file name
- SetSize(self, w, h, recursive=True)¶
Set the size.
- Parameters:
w – the width
h – the height
recursive – not used