void CDrawRecView::OnDraw(CDC* pDC)
{
int x = 0;
int y = 0;
CBrush cbrush(RGB(0,0,0));
CPen pen(PS_SOLID,2,RGB(0,0,255));
pDC->SelectObject(cbrush);
CRect rectU;
GetWindowRect(rectU);//这里只需要一个参数
ScreenToClient(rectU);
x=rectU.right;
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+20,x-20,y+200);
//draw rectangle
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+205,x-20,y+405);
}
void CSubMapParcel::DrawParcelRoad(CMapView *pMapView,//
CDC *pDC,//
CRect &rcClient,//
CParcelHelper::CIntVecMap* pNameMap, // 名称
BOOL bDrawRegu)
{
//draw bigmap detail rectangle
GetWindowRect(&rcClient);//这里一个参数报错了 error C2660: 'GetWindowRect' : function does not take 1 parameters
ScreenToClient(&rcClient);//这也是。
int x=rcClient
int y=rect.top-rect.top;
CBrush cbrush(RGB(0,0,0));
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+20,x-20,y+200);
}
在线等。。新手不懂MFC
{
int x = 0;
int y = 0;
CBrush cbrush(RGB(0,0,0));
CPen pen(PS_SOLID,2,RGB(0,0,255));
pDC->SelectObject(cbrush);
CRect rectU;
GetWindowRect(rectU);//这里只需要一个参数
ScreenToClient(rectU);
x=rectU.right;
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+20,x-20,y+200);
//draw rectangle
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+205,x-20,y+405);
}
void CSubMapParcel::DrawParcelRoad(CMapView *pMapView,//
CDC *pDC,//
CRect &rcClient,//
CParcelHelper::CIntVecMap* pNameMap, // 名称
BOOL bDrawRegu)
{
//draw bigmap detail rectangle
GetWindowRect(&rcClient);//这里一个参数报错了 error C2660: 'GetWindowRect' : function does not take 1 parameters
ScreenToClient(&rcClient);//这也是。
int x=rcClient
int y=rect.top-rect.top;
CBrush cbrush(RGB(0,0,0));
pDC->SelectObject(cbrush);
pDC->Rectangle(x-220,y+20,x-20,y+200);
}
在线等。。新手不懂MFC