Class

Dimension

 

Defines the size of a window or UI element. Contains a 2-element array.

Specifies the height and width of an element in pixels. A Dimension object is created when you set an element’s size property. You can set the property using a JavaScript object with properties named width and height, or an array with 2 values in the order [wd, ht].

Properties

PropertyTypeAccessDescription
heightNumberr/wThe height in pixels.
lengthNumberreadonlyThe array length. (value: 2)
widthNumberr/wThe width in pixels.

Element of

Button.maximumSize

Button.minimumSize

Button.preferredSize

Button.size

Checkbox.maximumSize

Checkbox.minimumSize

Checkbox.preferredSize

Checkbox.size

DropDownList.itemSize

DropDownList.maximumSize

DropDownList.minimumSize

DropDownList.preferredSize

DropDownList.size

EditText.maximumSize

EditText.minimumSize

EditText.preferredSize

EditText.size

FlashPlayer.maximumSize

FlashPlayer.minimumSize

FlashPlayer.preferredSize

FlashPlayer.size

Group.maximumSize

Group.minimumSize

Group.preferredSize

Group.size

IconButton.maximumSize

IconButton.minimumSize

IconButton.preferredSize

IconButton.size

Image.maximumSize

Image.minimumSize

Image.preferredSize

Image.size

ListBox.itemSize

ListBox.maximumSize

ListBox.minimumSize

ListBox.preferredSize

ListBox.size

Panel.maximumSize

Panel.minimumSize

Panel.preferredSize

Panel.size

Progressbar.maximumSize

Progressbar.minimumSize

Progressbar.preferredSize

Progressbar.size

RadioButton.maximumSize

RadioButton.minimumSize

RadioButton.preferredSize

RadioButton.size

ScriptUIImage.size

Scrollbar.maximumSize

Scrollbar.minimumSize

Scrollbar.preferredSize

Scrollbar.size

Slider.maximumSize

Slider.minimumSize

Slider.preferredSize

Slider.size

StaticText.maximumSize

StaticText.minimumSize

StaticText.preferredSize

StaticText.size

TreeView.itemSize

TreeView.maximumSize

TreeView.minimumSize

TreeView.preferredSize

TreeView.size

Window.frameSize

Window.maximumSize

Window.minimumSize

Window.preferredSize

Window.size

Return

Dimension ScriptUIGraphics.measureString (text:String, font:ScriptUIFont, boundingWidth:Number)

Contents :: Index