+ virtual void DrawScaledBitmap(const wxBitmap &bmp, wxCoord x, wxCoord y, wxCoord w, wxCoord h, bool useMask = false, int quality = wxIMAGE_QUALITY_NORMAL)
+ {
+ if (bmp.GetWidth() != w || bmp.GetHeight() != h)
+ {
+ if (quality != wxIMAGE_QUALITY_HIGH)
+ quality = wxIMAGE_QUALITY_NORMAL;
+ wxImage tmpImg = bmp.ConvertToImage();
+ tmpImg.Rescale( w, h, quality );
+ wxBitmap scaledBmp(tmpImg);
+ m_pimpl->DoDrawBitmap(scaledBmp, x, y, useMask);
+ }
+ else
+ m_pimpl->DoDrawBitmap(bmp, x, y, useMask);
+ }
+ virtual void DrawScaledBitmap(const wxBitmap &bmp, const wxPoint& pt, const wxSize& sz, bool useMask = false, int quality = wxIMAGE_QUALITY_NORMAL)
+ {
+ if (bmp.GetWidth() != sz.x || bmp.GetHeight() != sz.y)
+ {
+ if (quality != wxIMAGE_QUALITY_HIGH)
+ quality = wxIMAGE_QUALITY_NORMAL;
+ wxImage tmpImg = bmp.ConvertToImage();
+ tmpImg.Rescale( sz.x, sz.y, quality );
+ wxBitmap scaledBmp(tmpImg);
+ m_pimpl->DoDrawBitmap(scaledBmp, pt.x, pt.y, useMask);
+ }
+ else
+ m_pimpl->DoDrawBitmap(bmp, pt.x, pt.y, useMask);
+ }
+ virtual void DrawScaledBitmap(const wxBitmap &bmp, const wxRect& rect, bool useMask = false, int quality = wxIMAGE_QUALITY_NORMAL)
+ {
+ if (bmp.GetWidth() != rect.width || bmp.GetHeight() != rect.height)
+ {
+ if (quality != wxIMAGE_QUALITY_HIGH)
+ quality = wxIMAGE_QUALITY_NORMAL;
+ wxImage tmpImg = bmp.ConvertToImage();
+ tmpImg.Rescale( rect.width, rect.height, quality );
+ wxBitmap scaledBmp(tmpImg);
+ m_pimpl->DoDrawBitmap(scaledBmp, rect.x, rect.y, useMask);
+ }
+ else
+ m_pimpl->DoDrawBitmap(bmp, rect.x, rect.y, useMask);
+ }
+