CRect rect;
rect(100,200,300,400);其中:300和400是(100,200)到对角点的距离还是对角点的坐标?

解决方案 »

  1.   

    其实也就是CRect(point1.x,point1.y,point2.x,point2.y);的意思
      

  2.   

    CRect::CRect(CPoint leftTop, CSize size);
    CSize的两个变量代表宽和高...即到对角点的距离..
      

  3.   

    坐标,
    应该这样用吧
    CRect rect(100,200,300,400);
      

  4.   

    width = rect.right - rect.left;
    height = rect.bottom - rect.top;这样不就算出来了吗?
      

  5.   

    这个,自己在屏幕上画一个来看看不就行了吗,有必要讨论吗?再说MSDN上明明有说明:CRect(
       int l,
       int t,
       int r,
       int b 
    ) throw( );Parameters

    Specifies the left position of CRect. 

    Specifies the top of CRect. 

    Specifies the right position of CRect. 

    Specifies the bottom of CRect. 
      

  6.   

    CRect rect;
    rect(100,200,300,400);//那有这样用的
    rect.SetRect(100,200,300,400);左上右下,,左上右下,念经ING...