// PaintVw.h : interface of the CPaintView class // ///////////////////////////////////////////////////////////////////////////// //{{AFX_INCLUDES() #include "lead.h" #include "ppaint.h" //}}AFX_INCLUDES class CPaintView : public CFormView { private: void SetJ2KOptions(); protected: // create from serialization only CPaintView(); DECLARE_DYNCREATE(CPaintView) public: void CreateDefaultObjects(); HPALETTE CreateDIBPalette (LPBITMAPINFO lpbmi, LPINT lpiNumColors); void LoadResourceBitmap(long nResourceID); void UpdatePaintMetrics(); void UpdateXForm(); void UpdateStatusBar(int nPane = 0, char *pszMsg = NULL); int m_nPointCount; int m_bFirstDraw; float m_nStartY; float m_nStartX; float m_nEndX; float m_nEndY; float m_FirstPointX; float m_FirstPointY; int m_nToolType; int m_bDrawing; CRect m_rcFloater; BOOL m_bMovingFloater; //{{AFX_DATA(CPaintView) enum { IDD = IDD_PAINT_FORM }; CLead m_Lead; CLead m_Lead7; CLEADPaint m_LeadPaint; CLead m_LeadPaper; CLead m_LeadTemp; CLead m_LeadBackground; CLead m_LeadTouch; CLead m_LeadBorder; //}}AFX_DATA // Attributes public: CPaintDoc* GetDocument(); CPalette *m_pPalette; // Operations public: // Overrides // ClassWizard generated virtual function overrides //{{AFX_VIRTUAL(CPaintView) public: virtual BOOL PreCreateWindow(CREATESTRUCT& cs); virtual void OnInitialUpdate(); protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support virtual BOOL OnPreparePrinting(CPrintInfo* pInfo); virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo); virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo); virtual void OnPrint(CDC* pDC, CPrintInfo*); virtual void OnActivateView(BOOL bActivate, CView* pActivateView, CView* pDeactiveView); //}}AFX_VIRTUAL // Implementation public: COLORREF m_crBorder; float m_FirstMouseMoveStartX; float m_FirstMouseMoveStartY ; float m_FirstMouseMoveEndX; float m_FirstMouseMoveEndY; int m_bFirstMouseMove; int m_bButtonDown; virtual ~CPaintView(); #ifdef _DEBUG virtual void AssertValid() const; virtual void Dump(CDumpContext& dc) const; #endif protected: // Generated message map functions protected: //{{AFX_MSG(CPaintView) afx_msg LRESULT OnDoRealize(WPARAM wParam, LPARAM lParam); // user message afx_msg void OnSize(UINT nType, int cx, int cy); afx_msg void OnMouseDownLeadctrl1(short Button, short Shift, long x, long y); afx_msg void OnMouseMoveLeadctrl1(short Button, short Shift, long x, long y); afx_msg void OnMouseUpLeadctrl1(short Button, short Shift, long x, long y); afx_msg void OnToolBrush(); afx_msg void OnUpdateToolBrush(CCmdUI* pCmdUI); afx_msg void OnToolShapeLine(); afx_msg void OnUpdateToolShapeLine(CCmdUI* pCmdUI); afx_msg void OnToolShapePolygon(); afx_msg void OnUpdateToolShapePolygon(CCmdUI* pCmdUI); afx_msg void OnToolShapeRectangle(); afx_msg void OnUpdateToolShapeRectangle(CCmdUI* pCmdUI); afx_msg void OnToolShapeRoundrectangle(); afx_msg void OnUpdateToolShapeRoundrectangle(CCmdUI* pCmdUI); afx_msg void OnToolShapeEllipse(); afx_msg void OnUpdateToolShapeEllipse(CCmdUI* pCmdUI); afx_msg void OnDblClickLeadctrl1(); afx_msg void OnScrollLeadctrl1(); afx_msg void OnToolRegionBorder(); afx_msg void OnUpdateToolRegionBorder(CCmdUI* pCmdUI); afx_msg void OnToolRegionCancel(); afx_msg void OnUpdateToolRegionCancel(CCmdUI* pCmdUI); afx_msg void OnToolRegionColor(); afx_msg void OnUpdateToolRegionColor(CCmdUI* pCmdUI); afx_msg void OnToolRegionEllipse(); afx_msg void OnUpdateToolRegionEllipse(CCmdUI* pCmdUI); afx_msg void OnToolRegionPolygon(); afx_msg void OnUpdateToolRegionPolygon(CCmdUI* pCmdUI); afx_msg void OnToolRegionRectangle(); afx_msg void OnUpdateToolRegionRectangle(CCmdUI* pCmdUI); afx_msg void OnToolRegionRoundrectangle(); afx_msg void OnUpdateToolRegionRoundrectangle(CCmdUI* pCmdUI); afx_msg void OnToolRegionSurface(); afx_msg void OnUpdateToolRegionSurface(CCmdUI* pCmdUI); afx_msg void OnToolFillBorder(); afx_msg void OnUpdateToolFillBorder(CCmdUI* pCmdUI); afx_msg void OnToolFillColorreplace(); afx_msg void OnUpdateToolFillColorreplace(CCmdUI* pCmdUI); afx_msg void OnToolFillSurface(); afx_msg void OnUpdateToolFillSurface(CCmdUI* pCmdUI); afx_msg void OnToolText(); afx_msg void OnUpdateToolText(CCmdUI* pCmdUI); afx_msg void OnOptionsBrush(); afx_msg void OnOptionsShape(); afx_msg void OnOptionsRegion(); afx_msg void OnOptionsFill(); afx_msg void OnOptionsText(); afx_msg void OnEditCopy(); afx_msg void OnFileSaveAs(); afx_msg void OnViewZoomIn(); afx_msg void OnViewZoomOut(); DECLARE_EVENTSINK_MAP() //}}AFX_MSG DECLARE_MESSAGE_MAP() }; #ifndef _DEBUG // debug version in PaintVw.cpp inline CPaintDoc* CPaintView::GetDocument() { return (CPaintDoc*)m_pDocument; } #endif /////////////////////////////////////////////////////////////////////////////