1.Range{location,length} 一维范围
NSRange a;
a.length=10;
a.location=6;
NSRange range={10,6};
NSRange range1=NSMakeRange(10, 6);
2.Point{x,y} 点
NSPoint point;
point.x=10;
point.y=11;
NSPoint point1={20,10};
NSPoint point2=NSMakePoint(10, 20);
3.Size{height,width}
NSSize size;
size.height=10;
size.width=20;
NSSize size1 ={10,20};
NSSize size2=NSMakeSize(20, 20);
4. Rect={Point,Size} 矩形区域是由点和长宽组成的。两维范围
NSRect rect;
rect.origin=point;
rect.size=size;
NSRect rect1={0,0,1,2};
NSRect rect2=NSMakeRect(0, 0, 1, 2);