📄 draw.h
字号:
// Draw.h: interface for the CDraw class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_DRAW_H__9988EE28_9CDB_4FD5_80CA_05E5DEDE9D68__INCLUDED_)
#define AFX_DRAW_H__9988EE28_9CDB_4FD5_80CA_05E5DEDE9D68__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "Base\as_transf.hxx"
#include "Base\as_position.hxx"
#include "Base\as_unitvec.hxx"
#include "ViewWnd.h"
#include "DcEx.h"
#define M_PI 3.1415926
class CDraw :public CDCEx
{
public:
CDraw(CViewWnd *pView);
virtual ~CDraw();
public:
private:
CViewWnd *m_pView;
CWnd *m_pWnd;
transf m_zoom_transf; //坐标变换
transf m_DRAW_TO_SCREEN_TRAN;
transf m_SCREEN_TO_DRAW_TRAN;
transf m_offset_transf;
int m_PickTol;//捕捉误差
long m_nRelationColor;//捕捉显示颜色
double m_nPaperWidth,m_nPaperHight;
public:
void ComputeTransf();
void ZoomTransf(transf tran);
transf ZoomTransf(){return m_zoom_transf;};
void PaperWidth(double dWidth){m_nPaperWidth=dWidth;};
double PaperWidth(){return m_nPaperWidth;};
void PaperHight(double dHight){m_nPaperHight=dHight;};
double PaperHight(){return m_nPaperHight;};
public:
transf ScreenToDrawing();
transf DrawingToScreen();
int GetPickTol(){return m_PickTol;};
void SetPickTol(int PickTol){m_PickTol=PickTol;};
long RelationColor(){return m_nRelationColor;};
void RelationColor(long nColor){m_nRelationColor=nColor;};
};
#endif // !defined(AFX_DRAW_H__9988EE28_9CDB_4FD5_80CA_05E5DEDE9D68__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -