CRect::CenterPoint

CPoint CenterPoint() const;

返回值:
返回一个CPoint对象,该对象是CRect的中心点。

说明:
要计算CRect的中心点,将其左、右坐标值相加再除2,将其上、下值相加再除2。

请参阅:
CRect::Width, CRect::Height, CRect::Size, CRect::TopLeft, CRect::BottomRight, CRect::IsRectNull, CPoint