Instance Property

bounds

The bounds rectangle, which describes the view’s location and size in its own coordinate system.

Declaration

@property(nonatomic) CGRect bounds;

Discussion

The default bounds origin is (0,0) and the size is the same as the size of the rectangle in the frame property. Changing the size portion of this rectangle grows or shrinks the view relative to its center point. Changing the size also changes the size of the rectangle in the frame property to match. The coordinates of the bounds rectangle are always specified in points.

Changing the bounds rectangle automatically redisplays the view without calling its drawRect: method. If you want UIKit to call the drawRect: method, set the contentMode property to UIViewContentModeRedraw.

Changes to this property can be animated.

See Also

Configuring the Bounds and Frame Rectangles

frame

The frame rectangle, which describes the view’s location and size in its superview’s coordinate system.

center

The center point of the view's frame rectangle.

transform

Specifies the transform applied to the view, relative to the center of its bounds.