Добавил:
Studfiles2
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз:
Предмет:
Файл:Рандомизированный алгоритм построения выпуклой оболочки / program / RandchView
.h#pragma once
//************** RandchView h ***************
class CRandchView : public CView
{
protected: // create from serialization only
CRandchView();
DECLARE_DYNCREATE(CRandchView)
// Attributes
public:
CRandchDoc* GetDocument() const;
CCHList ch;
CStatusBar *SB;
FlPoint CP,cur_p, first_p, second_p;
list<CCHPoint*>::iterator cur_i,lft_i,rt_i;
list<list<CCHPoint*>::iterator> recheck;
int num_of_st;
int vx,vy;
int t;
// Operations
public:
void displayAll(CRandchDoc* pDoc);
void ClearArea();
void displayL(CDC* pDC, CCHList Lst,COLORREF p,COLORREF l,bool Edg);
void displayVeer(CDC* pDC, CCHList lst, int count, COLORREF p, COLORREF l, bool bDrawLines);
void LNum(CCHList Lst,COLORREF p);
void displayP(CDC* pDC, float x, float y, COLORREF p);
void displayR(CDC* pDC, float x, float y, COLORREF p);
void displayBaseLine(CDC* pDC, float x, float y, COLORREF p, COLORREF l);
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CRandchView)
public:
virtual void OnDraw(CDC* pDC);
// overridden to draw this view
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
//}}AFX_VIRTUAL
// Implementation
public:
virtual ~CRandchView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected:
// Generated message map functions
protected:
//{{AFX_MSG(CRandchView)
afx_msg void OnStep();
afx_msg void OnUpdateStep(CCmdUI* pCmdUI);
afx_msg void OnTest();
afx_msg void OnGen();
afx_msg void OnGo();
afx_msg void OnUpdateGo(CCmdUI* pCmdUI);
afx_msg void OnUpdatePane (CCmdUI *pCmdUI);
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnStartagain();
afx_msg void OnUpdateStartagain(CCmdUI* pCmdUI);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
public:
afx_msg void OnFileOpen();
afx_msg void OnFileSave();
afx_msg void OnFileNew();
};
#ifndef _DEBUG // debug version in RandchView.cpp
inline CRandchDoc* CRandchView::GetDocument() const
{ return reinterpret_cast<CRandchDoc*>(m_pDocument); }
#endif
Соседние файлы в папке program