Package | com.greensock.layout |
Class | public class ScaleMode |
Inheritance | ScaleMode ![]() |
LiquidArea
or AutoFitArea
).
Copyright 2010-2013, GreenSock. All rights reserved. This work is subject to the terms in http://www.greensock.com/terms_of_use.html or for Club GreenSock members, the software agreement that was issued with the membership.
Constant | Defined By | ||
---|---|---|---|
HEIGHT_ONLY : String = heightOnly [static] Stretches the object's height to fill the area vertically, but does not affect its width | ScaleMode | ||
NONE : String = none [static] Does not scale the object at all | ScaleMode | ||
PROPORTIONAL_INSIDE : String = proportionalInside [static] Scales the object proportionally to fit inside the area (its edges will never exceed the bounds of the area). | ScaleMode | ||
PROPORTIONAL_OUTSIDE : String = proportionalOutside [static] Scales the object proportionally to completely fill the area, allowing portions of it to exceed the bounds when its aspect ratio doesn't match the area's. | ScaleMode | ||
STRETCH : String = stretch [static] Stretches the object to fill the area completely in terms of both width and height. | ScaleMode | ||
WIDTH_ONLY : String = widthOnly [static] Stretches the object's width to fill the area horizontally, but does not affect its height | ScaleMode |
HEIGHT_ONLY | Constant |
public static const HEIGHT_ONLY:String = heightOnly
Stretches the object's height to fill the area vertically, but does not affect its width
NONE | Constant |
public static const NONE:String = none
Does not scale the object at all
PROPORTIONAL_INSIDE | Constant |
public static const PROPORTIONAL_INSIDE:String = proportionalInside
Scales the object proportionally to fit inside the area (its edges will never exceed the bounds of the area). For example, if the area is 100x50 and the DisplayObject is natively 200x200, it will scale it down to 50x50 meaning it will not fill the area horizontally, but it will vertically.
PROPORTIONAL_OUTSIDE | Constant |
public static const PROPORTIONAL_OUTSIDE:String = proportionalOutside
Scales the object proportionally to completely fill the area, allowing portions of it to exceed the bounds when its aspect ratio doesn't match the area's. For example, if the area is 100x50 and the DisplayObject is natively 200x200, it will scale it down to 100x100 meaning it will exceed the bounds of the area vertically.
STRETCH | Constant |
public static const STRETCH:String = stretch
Stretches the object to fill the area completely in terms of both width and height. This mode does NOT concern itself with preserving the object's original aspect ratio (proportions).
WIDTH_ONLY | Constant |
public static const WIDTH_ONLY:String = widthOnly
Stretches the object's width to fill the area horizontally, but does not affect its height