UISizeConstraint
Ensures a GuiObject does not become larger or smaller than the constraint's maximum size or minimum size.
Memory category | Instances |
---|
Member index 2
Description
The UISizeConstraint
ensures a GuiObject does not become larger or
smaller than the MaxSize and
MinSize. For example, if
MaxSize is set to
(200, 200)
(100, 100)
Note that if the object with this constraint is also under the control of a UILayout such as UIGridLayout, the constraint determines the object's minimum/maximum size and overwrites any size the layout would apply.
History 9
- 553 Change Default of MinSize from to Vector2(0, 0)
- 553 Change Default of MaxSize from to Vector2(INF, INF)
- 486 Change ThreadSafety of MinSize from ReadOnly to ReadSafe
- 486 Change ThreadSafety of MaxSize from ReadOnly to ReadSafe
- 462 Change ThreadSafety of MinSize from to ReadOnly
- 462 Change ThreadSafety of MaxSize from to ReadOnly
- 266 Add MinSize
- 266 Add MaxSize
- 266 Add UISizeConstraint
Members 2
MaxSize
Type | Default | |
---|---|---|
Vector2 | INF, INF |
The largest size, in pixels, the parent object is allowed to be. The X and Y of this value must be greater than or equal to the corresponding components of MinSize.
Thread safety | ReadSafe |
---|---|
Category | Behavior |
Loaded/Saved | true |
MinSize
Type | Default | |
---|---|---|
Vector2 | 0, 0 |
The smallest size, in pixels, the object is allowed to be. The X and Y of this value must be less than or equal to the corresponding components of MaxSize.
Thread safety | ReadSafe |
---|---|
Category | Behavior |
Loaded/Saved | true |