#pragma implementation "bitmap.h"
#endif
+#ifdef __VMS
+#define XtParent XTPARENT
+#endif
+
#include "wx/setup.h"
#include "wx/utils.h"
#include "wx/palette.h"
wxList wxBitmap::sm_handlers;
+#define M_BMPDATA ((wxBitmapRefData *)m_refData)
+
wxBitmap::wxBitmap()
{
m_refData = NULL;
M_BITMAPDATA->m_bitmapMask = mask ;
}
+wxBitmap wxBitmap::GetSubBitmap( const wxRect& rect) const
+{
+ wxCHECK_MSG( Ok() &&
+ (rect.x >= 0) && (rect.y >= 0) &&
+ (rect.x+rect.width <= M_BMPDATA->m_width) && (rect.y+rect.height <= M_BMPDATA->m_height),
+ wxNullBitmap, wxT("invalid bitmap or bitmap region") );
+
+ wxBitmap ret( rect.width, rect.height, 0 );
+ wxASSERT_MSG( ret.Ok(), wxT("GetSubBitmap error") );
+
+ // The remaining still TODO
+ return ret;
+}
+
void wxBitmap::AddHandler(wxBitmapHandler *handler)
{
sm_handlers.Append(handler);