📄 geotwopoint.h
字号:
// GeoTwoPoint.h: interface for the GeoTwoPoint class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_GEOTWOPOINT_H__D5977F59_9183_11D7_908B_00A00CC807C7__INCLUDED_)
#define AFX_GEOTWOPOINT_H__D5977F59_9183_11D7_908B_00A00CC807C7__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
//
//虚基类,两点几何图元的基类!!!
//
#include "GeoObject.h"
class GeoTwoPoint : public GeoObject
{
public:
GeoTwoPoint();
GeoTwoPoint(int x1, int y1, int x2, int y2)
{
SetTwoPoint(x1, y1, x2, y2);
}
GeoTwoPoint(CPoint pt1, CPoint pt2)
{
SetTwoPoint(pt1, pt2);
}
void SetTwoPoint(int x1, int y1, int x2, int y2)
{
m_pPoint1.x = x1; m_pPoint1.y = y1;
m_pPoint2.x = x2; m_pPoint2.y = y2;
}
void SetTwoPoint(CPoint pt1, CPoint pt2)
{
m_pPoint1.x = pt1.x; m_pPoint1.y = pt1.y;
m_pPoint2.x = pt2.x; m_pPoint2.y = pt2.y;
}
CPoint GetFirstPoint() { return m_pPoint1; }
CPoint GetSecondPoint() { return m_pPoint2; }
virtual ~GeoTwoPoint();
protected:
CPoint m_pPoint1, m_pPoint2;
};
#endif // !defined(AFX_GEOTWOPOINT_H__D5977F59_9183_11D7_908B_00A00CC807C7__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -