-
Notifications
You must be signed in to change notification settings - Fork 29
UI.View.frame
kerrishotts edited this page Apr 1, 2013
·
1 revision
(part of UI.View)
Type: rect
Default: zeroRect
Represents the frame of the element. Changing the frame
property directly affects the bounds
of the object, and also sends out boundsDidChange
and frameDidChange
notifications.
The frame
is relative to the view's superView.
Note: changing the properties of the frame
object should be avoided, as it does not utilize the setter method for the property. Therefore notifications will fail to fire and properties that rely on it will fail to be updated. When changing this property, you should always assign a new copy of the object that contains the desired modifications.
var aView = new UI.View();
aView.frame = UI.makeRect ( UI.makePoint ( 10, 10 ), UI.makeSize ( 100, 150 ) );
//aView's frame starts at (10,10) and is 100 wide and 150 high.
//aView's bounds are now 100 wide and 150 high
0.3 Introduced; Docs Valid.