class jive.geom.IntDimension

The Dimension class encapsulates the width and height of a componentin a single object.
Note this Class use int as its parameters on purpose to avoid problems that happended in aswing before. @author paling

Class Fields

static function createBigDimension(): IntDimension

Create a big dimension for component.

returns

a IntDimension(100000, 100000)

static function createNullDimension(): IntDimension

Create a null dimension for component.

returns

a IntDimension(-1, 11)

Instance Fields

function new(?width:Int, ?height:Int): Void

Creates a dimension.

function change(deltaW:Int, deltaH:Int): IntDimension

modify the size and return itself.

function changedSize(deltaW:Int, deltaH:Int): IntDimension

return a new size with this size with a change.

function clone(): IntDimension

Duplicates current instance.

returns

copy of the current instance.

function combine(d:IntDimension): IntDimension

Combines current and specified dimensions by getting max sizes and puts result into itself.

returns

the combined dimension itself.

function combineSize(d:IntDimension): IntDimension

Combines current and specified dimensions by getting max sizes and returns new IntDimension object

returns

a new dimension with combined size.

function decreaseSize(s:IntDimension): IntDimension

Decreases the size by s and return its self(this).

returnsthis.

function equals(d:IntDimension): Bool

Returns whether or not the passing o is an same value IntDimension.

function getBounds(?x:Int, ?y:Int): IntRectangle

return a new bounds with this size with a location. @prame y the location y.

x

the location x.

returns

the bounds.

function increaseSize(s:IntDimension): IntDimension

Increases the size by s and return its self(this).

returnsthis.

function setSize(dim:IntDimension): Void

Sets the size as same as the dim.

function setSizeWH(width:Int, height:Int): Void

Sets the size with width and height.

function toString(): String