CCompatibleDC.h 439 B

1234567891011121314151617181920212223
  1. #pragma once
  2. #include <afxwin.h>
  3. BOOL DisplayBMP(CDC* pDC, int nX1, int nY1, int nXX, int nYY, CString strBMPFile, BOOL bStretch);
  4. void DrawColorButton(LPDRAWITEMSTRUCT lpDIS, COLORREF clrButton);
  5. class CCompatibleDC :public CDC
  6. {
  7. public:
  8. CCompatibleDC();
  9. ~CCompatibleDC();
  10. private:
  11. CDC* m_pDrawDC;
  12. CRect m_rect;
  13. CBitmap m_bitmap, *m_pOldBitmap;
  14. public:
  15. void Create(CDC* pDC);
  16. void Destroy(void);
  17. void Destroy(CRect rect);
  18. };