📄 rect2d.cpp
字号:
// Rect2D.cpp: implementation of the CRect2D class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "zMap.h"
#include "Rect2D.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CRect2D::CRect2D()
{
}
CRect2D::~CRect2D()
{
}
double CRect2D::Width()
{
return m_dRight-m_dLeft;
}
double CRect2D::Height()
{
return m_dTop-m_dBottom;
}
CPoint2D CRect2D::CenterPoint()
{
CPoint2D pt;
pt.m_dx = (m_dRight+m_dLeft)/2;
pt.m_dy = (m_dTop+m_dBottom)/2;
return pt;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -