⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 direction2view.h

📁 数据结构求最短路径vc++ 实现手动作图
💻 H
字号:
// direction2View.h : interface of the CDirection2View class
//
/////////////////////////////////////////////////////////////////////////////
#include "StdAfx.h"
#if !defined(AFX_DIRECTION2VIEW_H__1333ECC0_D36F_460E_B6E3_3035815AC30B__INCLUDED_)
#define AFX_DIRECTION2VIEW_H__1333ECC0_D36F_460E_B6E3_3035815AC30B__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "ZUOTU.h"

#include "RECTHW.h"

#include "RectSet.h"

#include "Word.h"

#include "LineSet.h"

class CDirection2View : public CScrollView
{
protected:
    COLORREF  m_cTextColor;    //字体颜色
	LOGFONT    m_text;         //字体式样
	COLORREF m_FillColor;      //填充颜色

	COLORREF m_PenColor;       //画笔颜色
    
	int recrwidth;
    int rectchang;

	int m_CurrentPenThickness;   //画笔宽度

	int m_CurrentLineStyle;     //画笔式样



	CString m_ClassName;     //注册的类名
	int m_Dragging;          //鼠标左键是否按下
	BOOL m_IsRect;           //是否绘制Focus矩形 
	HCURSOR m_hArrow;        //箭头光标
	HCURSOR m_hCross;        //十字光标

	CPen m_PenDotted;        //点状画笔
	CPoint m_PointOld;        //鼠标上次坐标
	CPoint m_PointOrigin;     //鼠标按下时的坐标
    int index;
	int type;
	int lindex1;
	int lindex2;
  
	int  selectindex;            //当前被选中的对象的索引


	int m_begin;                //最短路径的起点

	int m_last;                //最短路径的终点


public:
  CZUOTU *m_huitu;	
  CRECTHW *m_rect;
  CRectSet *m_rectset;
  CWord    *m_textset;
  CLineSet  *m_lineset;
protected: // create from serialization only

	CDirection2View();
	DECLARE_DYNCREATE(CDirection2View)

// Attributes
public:
	CDirection2Doc* GetDocument();

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CDirection2View)
	public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual void OnInitialUpdate(); // called first time after construct
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint);
	//}}AFX_VIRTUAL

// Implementation
public:

	virtual ~CDirection2View();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:



// Generated message map functions
protected:
	//{{AFX_MSG(CDirection2View)
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnMouseMove(UINT nFlags, CPoint point);
	afx_msg void OnChushihua();
	afx_msg void OnColorpen();
	afx_msg void OnColorfill();
	afx_msg void OnPenstyle();
	afx_msg void OnRecthw();
	afx_msg void OnUpdateRecthw(CCmdUI* pCmdUI);
	afx_msg void Setpenstyle(WPARAM wParam,LPARAM lParam);
	afx_msg void Setrectwh(WPARAM wParam,LPARAM lParam);
	afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point);
	afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnShuxing();
    afx_msg void Onrectchange(WPARAM wParam ,LPARAM lParam);
    afx_msg void Onlinechange(WPARAM wParam ,LPARAM lParam);
    afx_msg void WriteText(WPARAM wParam ,LPARAM lParam);
	afx_msg void OnLook();
	afx_msg void OnShanchu112();
	afx_msg void OnFanhui();
	afx_msg void OnSetbedin();
	afx_msg void OnSetlast();
	afx_msg void OnUpdatePenstyle(CCmdUI* pCmdUI);
	afx_msg void OnBegin22();
	afx_msg void OnUpdateBegin22(CCmdUI* pCmdUI);

	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in direction2View.cpp
inline CDirection2Doc* CDirection2View::GetDocument()
   { return (CDirection2Doc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DIRECTION2VIEW_H__1333ECC0_D36F_460E_B6E3_3035815AC30B__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -