BoxBag

Extends: module:boxes/AbstractBox.AbstractBox

Source: BoxBag.js:42

BoxBag is a class derived from AbstractBox that contains a collection of "boxes"
(objects also derived from AbstractBox). This class implements methods to add, remove
and retrieve boxes, and to manage some of its properties like visibility, status, location and size.


Constructor

new BoxBag( parent?: module:boxes/AbstractBox.AbstractBox, container?: module:AWT.Container, boxBase?: module:boxes/BoxBase.BoxBase, ): BoxBag

BoxBag constructor

Parameters


Instance Methods

getPreferredSize(): module:AWT.Dimension

Gets the preferred size of this BoxBag

Returns

getMinimumSize(): module:AWT.Dimension

Gets the minimum size requested by this BoxBag

Returns

getScaledSize(scale: number): module:AWT.Dimension

Scales the current size of this box bag, multiplying all values by a specific factor

Parameters

  • scale (number) — The scale factor

Returns

addBox(bx: module:boxes/AbstractBox.AbstractBox)

Adds an AbstractBox to the collection of cells

Parameters

boxIndex(bx: module:boxes/AbstractBox.AbstractBox): number

Returns the index of a specific box in the cells array

Parameters

Returns

  • number

getBox(n: number): module:boxes/AbstractBox.AbstractBox

Returns the box at a specific index in the cells array

Parameters

  • n (number) — The index

Returns

getBackgroundBox(): module:boxes/AbstractBox.AbstractBox

Gets the background box

Returns

setBackgroundBox(bx: module:boxes/AbstractBox.AbstractBox)

Sets the background box

Parameters

recalcSize()

Recalculates the total size of this BoxBag (useful after direct additions o deletions of
elements in the cells array).
Updates preferredBounds and the current position and size of the box bag.

getNumCells(): number

Returns the number of cells stored in this BoxBag

Returns

  • number

setCellAttr(key: string, value: any)

Sets the specified key - value pair to all cells of this bag.

Parameters

  • key (string) — The key to be established
  • value (any) — The value, of any type

setBorder(newVal: boolean)

Overrides module:boxes/AbstractBox.AbstractBox#setBorder iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the border

setVisible(newVal: boolean)

Overrides module:boxes/AbstractBox.AbstractBox#setVisible iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set the cells visible or not

setAlternative(newVal: boolean)

Overrides module:boxes/AbstractBox.AbstractBox#setAlternative iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the cells in "alternative" mode

setBounds( rect: AWT.Rectangle | number, ry?: number, rw?: number, rh?: number, )

Overrides module:boxes/AbstractBox.AbstractBox#setBounds adjusting the position and size of all cells

Parameters

  • rect (AWT.Rectangle | number) — An AWT.Rectangle object, or the x coordinate of the
    upper-left corner of a new rectangle.
  • ry (number, optional) — y coordinate of the upper-left corner of the new rectangle.
  • rw (number, optional) — Width of the new rectangle.
  • rh (number, optional) — Height of the new rectangle.

update( ctx: external:CanvasRenderingContext2D, dirtyRegion?: module:AWT.Rectangle, )

Performs graphics operations for each cell.
Overrides module:boxes/AbstractBox.AbstractBox#update

Parameters

findBox( p: module:AWT.Point, ): module:boxes/AbstractBox.AbstractBox

Finds the first visible AbstractBox located under the specified point

Parameters

Returns

countInactiveCells(): number

Count the number of cells of this BoxBag that are in "inactive" state

Returns

  • number

setParent(parent: module:boxes/AbstractBox.AbstractBox)

Inherited from module:boxes/AbstractBox.AbstractBox#setParent

Overrides: module:boxes/AbstractBox.AbstractBox#setParent

Setter method for parent

Parameters

getParent(): module:boxes/AbstractBox.AbstractBox

Inherited from module:boxes/AbstractBox.AbstractBox#getParent

Overrides: module:boxes/AbstractBox.AbstractBox#getParent

Gets the current parent of this box

Returns

end()

Inherited from module:boxes/AbstractBox.AbstractBox#end

Overrides: module:boxes/AbstractBox.AbstractBox#end

Finisher method

setContainer(newContainer: module:AWT.Container)

Inherited from module:boxes/AbstractBox.AbstractBox#setContainer

Overrides: module:boxes/AbstractBox.AbstractBox#setContainer

Setter method for container

Parameters

getContainerX(): module:AWT.Container

Inherited from module:boxes/AbstractBox.AbstractBox#getContainerX

Overrides: module:boxes/AbstractBox.AbstractBox#getContainerX

Gets the container attribute of this box, without checking its parent

Returns

getContainerResolve(): module:AWT.Container

Inherited from module:boxes/AbstractBox.AbstractBox#getContainerResolve

Overrides: module:boxes/AbstractBox.AbstractBox#getContainerResolve

Gets the container associated to this box, asking its parents when null.

Returns

invalidate(rect: module:AWT.Rectangle)

Inherited from module:boxes/AbstractBox.AbstractBox#invalidate

Overrides: module:boxes/AbstractBox.AbstractBox#invalidate

Invalidates the zone corresponding to this box in the associated module:AWT.Container, if any.

Parameters

  • rect (module:AWT.Rectangle) — The rectangle to be invalidated. When null, it's the full
    container area.

setBoxBase(boxBase: module:boxes/BoxBase.BoxBase)

Inherited from module:boxes/AbstractBox.AbstractBox#setBoxBase

Overrides: module:boxes/AbstractBox.AbstractBox#setBoxBase

Sets the BoxBase of this box

Parameters

getBoxBaseResolve(): module:boxes/BoxBase.BoxBase

Inherited from module:boxes/AbstractBox.AbstractBox#getBoxBaseResolve

Overrides: module:boxes/AbstractBox.AbstractBox#getBoxBaseResolve

Gets the real BoxBase associated to this box, scanning down parent relationships.

Returns

setShape(sh: module:AWT.Shape)

Inherited from module:boxes/AbstractBox.AbstractBox#setShape

Overrides: module:boxes/AbstractBox.AbstractBox#setShape

Sets the shape used to draw the content of this box

Parameters

getShape(): module:AWT.Shape

Inherited from module:boxes/AbstractBox.AbstractBox#getShape

Overrides: module:boxes/AbstractBox.AbstractBox#getShape

Gets the current shape used in this box

Returns

contains(p: module:AWT.Point): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#contains

Check if this box contains the specified point

Parameters

Returns

  • boolean

setBounds( rect: AWT.Rectangle | number, ry?: number, rw?: number, rh?: number, ): module:AWT.Rectangle

Inherited from module:boxes/BoxBag.BoxBag#setBounds

Overrides: module:boxes/AbstractBox.AbstractBox#setBounds

Overrides module:boxes/AbstractBox.AbstractBox#setBounds adjusting the position and size of all cells

Parameters

  • rect (AWT.Rectangle | number) — An AWT.Rectangle object, or the x coordinate of the
    upper-left corner of a new rectangle.
  • ry (number, optional) — y coordinate of the upper-left corner of the new rectangle.
  • rw (number, optional) — Width of the new rectangle.
  • rh (number, optional) — Height of the new rectangle.

Returns

moveTo(newPos: AWT.Point | number, y?: number)

Inherited from module:boxes/AbstractBox.AbstractBox#moveTo

Overrides: module:boxes/AbstractBox.AbstractBox#moveTo

Sets a new location for this box. In JClic this method was named setLocation

Parameters

  • newPos (AWT.Point | number) — A point or the x coordinate of a new point.
  • y (number, optional) — The y coordinate of a new point.

moveBy(dx: number, dy: number)

Inherited from module:boxes/AbstractBox.AbstractBox#moveBy

Overrides: module:boxes/AbstractBox.AbstractBox#moveBy

Sets a new location to this box. In JClic this method was named translate.

Parameters

  • dx (number) — The displacement on the X axis
  • dy (number) — The displacement on the Y axis

setSize(width: number, height: number)

Inherited from module:boxes/AbstractBox.AbstractBox#setSize

Overrides: module:boxes/AbstractBox.AbstractBox#setSize

Changes the size of this box

Parameters

  • width (number)
  • height (number)

hasBorder(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#hasBorder

Overrides: module:boxes/AbstractBox.AbstractBox#hasBorder

Checks if this box has border

Returns

  • boolean

setBorder(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setBorder

Overrides: module:boxes/AbstractBox.AbstractBox#setBorder

Overrides module:boxes/AbstractBox.AbstractBox#setBorder iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the border

isVisible(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isVisible

Overrides: module:boxes/AbstractBox.AbstractBox#isVisible

Checks if this box is fully visible

Returns

  • boolean

setVisible(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setVisible

Overrides: module:boxes/AbstractBox.AbstractBox#setVisible

Overrides module:boxes/AbstractBox.AbstractBox#setVisible iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set the cells visible or not

setHostedComponentVisible()

Inherited from module:boxes/AbstractBox.AbstractBox#setHostedComponentVisible

Overrides: module:boxes/AbstractBox.AbstractBox#setHostedComponentVisible

Makes module:boxes/AbstractBox.AbstractBox#$hostedComponent visible or invisible, based on the value of
the AbstractBox visible flag.

isTemporaryHidden(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isTemporaryHidden

Overrides: module:boxes/AbstractBox.AbstractBox#isTemporaryHidden

Checks if this box is temporary hidden

Returns

  • boolean

setTemporaryHidden(newVal: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setTemporaryHidden

Overrides: module:boxes/AbstractBox.AbstractBox#setTemporaryHidden

Makes this box temporary hidden (newVal true) or resets its original state (newVal false)

Parameters

  • newVal (boolean)

isInactive(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isInactive

Overrides: module:boxes/AbstractBox.AbstractBox#isInactive

Checks if this box is currently inactive.

Returns

  • boolean

setInactive(newVal: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setInactive

Overrides: module:boxes/AbstractBox.AbstractBox#setInactive

Makes this box active (false) or inactive (true)

Parameters

  • newVal (boolean)

isInverted(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isInverted

Overrides: module:boxes/AbstractBox.AbstractBox#isInverted

Checks if this box is in inverted state.

Returns

  • boolean

setInverted(newVal: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setInverted

Overrides: module:boxes/AbstractBox.AbstractBox#setInverted

Puts this box in inverted mode or restores its original state.

Parameters

  • newVal (boolean)

isMarked(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isMarked

Overrides: module:boxes/AbstractBox.AbstractBox#isMarked

Checks if this box is marked

Returns

  • boolean

setMarked(newVal: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setMarked

Overrides: module:boxes/AbstractBox.AbstractBox#setMarked

Sets this box in marked mode, or restores its original state.

Parameters

  • newVal (boolean)

isFocused(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isFocused

Overrides: module:boxes/AbstractBox.AbstractBox#isFocused

Checks if this box has the input focus

Returns

  • boolean

setFocused(newVal: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setFocused

Overrides: module:boxes/AbstractBox.AbstractBox#setFocused

Sets or unsets the input focus to this box.

Parameters

  • newVal (boolean)

isAlternative(): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#isAlternative

Overrides: module:boxes/AbstractBox.AbstractBox#isAlternative

Checks if this box is in alternative state.

Returns

  • boolean

setAlternative(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setAlternative

Overrides: module:boxes/AbstractBox.AbstractBox#setAlternative

Overrides module:boxes/AbstractBox.AbstractBox#setAlternative iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the cells in "alternative" mode

update( ctx: external:CanvasRenderingContext2D, dirtyRegion?: module:AWT.Rectangle, )

Inherited from module:boxes/BoxBag.BoxBag#update

Overrides: module:boxes/AbstractBox.AbstractBox#update

Performs graphics operations for each cell.
Overrides module:boxes/AbstractBox.AbstractBox#update

Parameters

updateContent( _ctx: external:CanvasRenderingContext2D, _dirtyRegion?: module:AWT.Rectangle, )

Inherited from module:boxes/AbstractBox.AbstractBox#updateContent

Overrides: module:boxes/AbstractBox.AbstractBox#updateContent

Here is where classes derived from AbstractBox should implement the drawing of its
content. Background and border are already painted in module:boxes/AbstractBox.AbstractBox#update.

Parameters

drawBorder(ctx: external:CanvasRenderingContext2D)

Inherited from module:boxes/AbstractBox.AbstractBox#drawBorder

Overrides: module:boxes/AbstractBox.AbstractBox#drawBorder

Draws the box border

Parameters

getBorderBounds(): module:AWT.Rectangle

Inherited from module:boxes/AbstractBox.AbstractBox#getBorderBounds

Overrides: module:boxes/AbstractBox.AbstractBox#getBorderBounds

Returns the enclosing Rectangle of this box including its border (if any)

Returns

setHostedComponent($hc: external:jQuery)

Inherited from module:boxes/AbstractBox.AbstractBox#setHostedComponent

Overrides: module:boxes/AbstractBox.AbstractBox#setHostedComponent

Sets the $hostedComponent member.

Parameters

getHostedComponent(): external:jQuery

Inherited from module:boxes/AbstractBox.AbstractBox#getHostedComponent

Overrides: module:boxes/AbstractBox.AbstractBox#getHostedComponent

Gets the current $hostedComponent member

Returns

setHostedComponentColors()

Inherited from module:boxes/AbstractBox.AbstractBox#setHostedComponentColors

Overrides: module:boxes/AbstractBox.AbstractBox#setHostedComponentColors

Sets $hostedComponent colors and other css properties
based on the current BoxBase of this box.

setHostedComponentBorder()

Inherited from module:boxes/AbstractBox.AbstractBox#setHostedComponentBorder

Overrides: module:boxes/AbstractBox.AbstractBox#setHostedComponentBorder

Sets the $hostedComponent border, based on the current
BoxBase of this box.

setHostedComponentBounds(_sizeChanged: boolean)

Inherited from module:boxes/AbstractBox.AbstractBox#setHostedComponentBounds

Overrides: module:boxes/AbstractBox.AbstractBox#setHostedComponentBounds

Places and resizes $hostedComponent, based on the size
and position of this box.

Parameters

  • _sizeChanged (boolean) — true when this ActiveBox has changed its size

getBounds(): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#getBounds

Overrides: module:boxes/AbstractBox.AbstractBox#getBounds

Gets the enclosing Rectangle of this Shape.

Returns

equals(r: module:AWT.Shape): boolean

Inherited from module:AWT.Rectangle#equals

Overrides: module:boxes/AbstractBox.AbstractBox#equals

Checks if two shapes are equivalent.

Parameters

Returns

  • boolean

clone(): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#clone

Overrides: module:boxes/AbstractBox.AbstractBox#clone

Clones this Rectangle

Returns

scaleBy(delta: Point | Dimension): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#scaleBy

Overrides: module:boxes/AbstractBox.AbstractBox#scaleBy

Multiplies the dimension of the Shape by the specified delta amount.

Parameters

  • delta (Point | Dimension) — Object containing the X and Y ratio to be scaled.

Returns

grow(dx: number, dy: number): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#grow

Overrides: module:boxes/AbstractBox.AbstractBox#grow

Expands the boundaries of this shape. This affects the current position and dimension.

Parameters

  • dx (number) — The amount to grow (or decrease) in horizontal direction
  • dy (number) — The amount to grow (or decrease) in vertical direction

Returns

getOppositeVertex(): module:AWT.Point

Inherited from module:AWT.Rectangle#getOppositeVertex

Overrides: module:boxes/AbstractBox.AbstractBox#getOppositeVertex

Gets the module:AWT.Point corresponding to the lower-right vertex of the Rectangle.

Returns

add(shape: module:AWT.Shape): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#add

Overrides: module:boxes/AbstractBox.AbstractBox#add

Adds the boundaries of another shape to the current one

Parameters

Returns

getCoords(): string

Inherited from module:AWT.Rectangle#getCoords

Overrides: module:boxes/AbstractBox.AbstractBox#getCoords

Gets a string with the co-ordinates of the upper-left and lower-right vertexs of this rectangle,
(with values rounded to int)

Returns

  • string

getAttributes(): object

Inherited from module:AWT.Rectangle#getAttributes

Overrides: module:boxes/AbstractBox.AbstractBox#getAttributes

Gets a object with the basic attributes needed to rebuild this instance excluding functions,
parent references, constants and also attributes retaining the default value.
The resulting object is commonly usued to serialize elements in JSON format.

Returns

  • object

setAttributes(data: object): module:AWT.Rectangle

Inherited from module:AWT.Rectangle#setAttributes

Overrides: module:boxes/AbstractBox.AbstractBox#setAttributes

Reads the properties of this Rectangle from a data object

Parameters

  • data (object) — The data object to be parsed

Returns

intersects(_r: module:AWT.Rectangle): boolean

Inherited from module:AWT.Shape#intersects

Overrides: module:boxes/AbstractBox.AbstractBox#intersects

Checks if the provided Rectangle r intersects with this shape.

Parameters

Returns

  • boolean

fill( ctx: external:CanvasRenderingContext2D, dirtyRegion?: module:AWT.Rectangle, ): external:CanvasRenderingContext2D

Inherited from module:AWT.Shape#fill

Overrides: module:boxes/AbstractBox.AbstractBox#fill

Fills the Shape with the current style in the provided HTML canvas context

Parameters

Returns

stroke( ctx: external:CanvasRenderingContext2D, ): external:CanvasRenderingContext2D

Inherited from module:AWT.Shape#stroke

Overrides: module:boxes/AbstractBox.AbstractBox#stroke

Draws this shape in the provided HTML canvas 2D rendering context.

Parameters

Returns

preparePath( ctx: external:CanvasRenderingContext2D, ): external:CanvasRenderingContext2D

Inherited from module:AWT.Shape#preparePath

Overrides: module:boxes/AbstractBox.AbstractBox#preparePath

Prepares an HTML canvas 2D rendering context with a path that can be used to stroke a line,
to fill a surface or to define a clipping region.

Parameters

Returns

clip( ctx: external:CanvasRenderingContext2D, fillRule?: string, ): external:CanvasRenderingContext2D

Inherited from module:AWT.Shape#clip

Overrides: module:boxes/AbstractBox.AbstractBox#clip

Creates a clipping region on the specified HTML canvas 2D rendering context

Parameters

  • ctx (external:CanvasRenderingContext2D) — The rendering context
  • fillRule (string, optional, default: "'nonzero'") — Can be 'nonzero' (default when not set) or 'evenodd'

Returns

isRect(): boolean

Inherited from module:AWT.Shape#isRect

Overrides: module:boxes/AbstractBox.AbstractBox#isRect

Shorthand method for determining if a Shape is an Rectangle

Returns

  • boolean

toString(): string

Inherited from module:AWT.Shape#toString

Overrides: module:boxes/AbstractBox.AbstractBox#toString

Overwrites the original 'Object.toString' method with a more descriptive text

Returns

  • string

contains(p: module:AWT.Point): boolean

Inherited from module:boxes/AbstractBox.AbstractBox#contains

Check if this box contains the specified point

Parameters

Returns

  • boolean

setBounds( rect: AWT.Rectangle | number, ry?: number, rw?: number, rh?: number, ): module:AWT.Rectangle

Inherited from module:boxes/BoxBag.BoxBag#setBounds

Overrides: module:boxes/AbstractBox.AbstractBox#setBounds

Overrides module:boxes/AbstractBox.AbstractBox#setBounds adjusting the position and size of all cells

Parameters

  • rect (AWT.Rectangle | number) — An AWT.Rectangle object, or the x coordinate of the
    upper-left corner of a new rectangle.
  • ry (number, optional) — y coordinate of the upper-left corner of the new rectangle.
  • rw (number, optional) — Width of the new rectangle.
  • rh (number, optional) — Height of the new rectangle.

Returns

setBorder(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setBorder

Overrides: module:boxes/AbstractBox.AbstractBox#setBorder

Overrides module:boxes/AbstractBox.AbstractBox#setBorder iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the border

setVisible(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setVisible

Overrides: module:boxes/AbstractBox.AbstractBox#setVisible

Overrides module:boxes/AbstractBox.AbstractBox#setVisible iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set the cells visible or not

setAlternative(newVal: boolean)

Inherited from module:boxes/BoxBag.BoxBag#setAlternative

Overrides: module:boxes/AbstractBox.AbstractBox#setAlternative

Overrides module:boxes/AbstractBox.AbstractBox#setAlternative iterating over all the cells stored in this box bag.

Parameters

  • newVal (boolean) — Whether to set or unset the cells in "alternative" mode

update( ctx: external:CanvasRenderingContext2D, dirtyRegion?: module:AWT.Rectangle, )

Inherited from module:boxes/BoxBag.BoxBag#update

Overrides: module:boxes/AbstractBox.AbstractBox#update

Performs graphics operations for each cell.
Overrides module:boxes/AbstractBox.AbstractBox#update

Parameters

Static Methods

layoutSingle( preferredMaxSize: module:AWT.Dimension, rs: Resizable, margin: number, ): module:AWT.Dimension

Static method that sets the position and dimension of a Resizable object based on a
preferred maximum dimension and a margin.

Parameters

  • preferredMaxSize (module:AWT.Dimension) — The preferred maximum size
  • rs (Resizable) — A resizable object implementing the methods described in the
    Resizable
    interface of JClic. Currently a BoxBag or TextGrid.
  • margin (number) — The margin between the available area and the BoxBag

Returns

layoutDouble( desiredMaxSize: module:AWT.Dimension, rsA: Resizable, rsB: Resizable, boxGridPos: string, margin: number, ): module:AWT.Dimension

Static method that sets the position and dimension of two Resizable objects based on a
preferred maximum size, a layout schema and a margin.

Parameters

  • desiredMaxSize (module:AWT.Dimension) — The preferred maximum size
  • rsA (Resizable) — First resizable object implementing the methods described in the
    Resizable
    interface of JClic. Currently a BoxBag or TextGrid.
  • rsB (Resizable) — Second resizable object
  • boxGridPos (string) — The layout schema. Possible values are:
  • margin (number) — The margin between the available area and the BoxBag

Returns

buildShape(data: object): module:AWT.Shape

Inherited from module:AWT.Shape

Builds a shape based on the provided data object.
Data should contain a 'type' member, specifying the type of shape requested ('rect', 'ellipse', 'rectangle' or 'path')

Parameters

  • data (object) — Specific data for this shape

Returns

Instance Fields

cells: Array.<module:boxes/AbstractBox.AbstractBox>

The array of cells

preferredBounds: module:AWT.Rectangle

Rectangle containing the preferred bounds of the BoxBag

backgroundBox: module:boxes/AbstractBox.AbstractBox

An optional box used as a background by this BoxBag

parent: module:boxes/AbstractBox.AbstractBox

Inherited from module:boxes/AbstractBox.AbstractBox#parent

Overrides: module:boxes/AbstractBox.AbstractBox#parent

The parent AbstractBox (can be null)

container: module:AWT.Container

Inherited from module:boxes/AbstractBox.AbstractBox#container

Overrides: module:boxes/AbstractBox.AbstractBox#container

The Container to which this AbstractBox belongs

boxBase: module:boxes/BoxBase.BoxBase

Inherited from module:boxes/AbstractBox.AbstractBox#boxBase

Overrides: module:boxes/AbstractBox.AbstractBox#boxBase

The BoxBase related to this AbstractBox. When null, the parent can provide an
alternative one.

border: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#border

Overrides: module:boxes/AbstractBox.AbstractBox#border

Whether this box has a border or not

shape: module:AWT.Shape

Inherited from module:boxes/AbstractBox.AbstractBox#shape

Overrides: module:boxes/AbstractBox.AbstractBox#shape

The shape of this box (the box Rectangle or a special Shape, if set)

specialShape: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#specialShape

Overrides: module:boxes/AbstractBox.AbstractBox#specialShape

Whether this box has a shape that is not a rectangle

visible: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#visible

Overrides: module:boxes/AbstractBox.AbstractBox#visible

Whether this box is visible or not

temporaryHidden: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#temporaryHidden

Overrides: module:boxes/AbstractBox.AbstractBox#temporaryHidden

Used to temporary hide a box while other drawing operations are done

tmpTrans: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#tmpTrans

Overrides: module:boxes/AbstractBox.AbstractBox#tmpTrans

Cells with this attribute will be transparent but with painted border

inactive: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#inactive

Overrides: module:boxes/AbstractBox.AbstractBox#inactive

Whether this box is active or inactive

inverted: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#inverted

Overrides: module:boxes/AbstractBox.AbstractBox#inverted

Whether this box must be displayed with inverted or regular colors

alternative: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#alternative

Overrides: module:boxes/AbstractBox.AbstractBox#alternative

Whether this box must be displayed with alternative or regular color and font settings

marked: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#marked

Overrides: module:boxes/AbstractBox.AbstractBox#marked

Whether this box is marked (selected) or not

focused: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#focused

Overrides: module:boxes/AbstractBox.AbstractBox#focused

Whether this box holds the input focus

accessibleText: string

Inherited from module:boxes/AbstractBox.AbstractBox#accessibleText

Overrides: module:boxes/AbstractBox.AbstractBox#accessibleText

Text to be used in accessible contexts

role: string

Inherited from module:boxes/AbstractBox.AbstractBox#role

Overrides: module:boxes/AbstractBox.AbstractBox#role

Describes the main role of this box on the activity. Useful in wai-aria descriptions.

$accessibleElement: external:jQuery

Inherited from module:boxes/AbstractBox.AbstractBox#$accessibleElement

Overrides: module:boxes/AbstractBox.AbstractBox#$accessibleElement

DOM element used to display this cell content in wai-aria contexts

accessibleAlwaysActive: boolean

Inherited from module:boxes/AbstractBox.AbstractBox#accessibleAlwaysActive

Overrides: module:boxes/AbstractBox.AbstractBox#accessibleAlwaysActive

Flag indicating that $accessibleElement should be always active

$hostedComponent: external:jQuery

Inherited from module:boxes/AbstractBox.AbstractBox#$hostedComponent

Overrides: module:boxes/AbstractBox.AbstractBox#$hostedComponent

An external JQuery DOM element hosted by this box

type: string

Inherited from module:AWT.Rectangle#type

Overrides: module:boxes/AbstractBox.AbstractBox#type

Shape type id

dim: module:AWT.Dimension

Inherited from module:AWT.Rectangle#dim

Overrides: module:boxes/AbstractBox.AbstractBox#dim

The Dimension of the Rectangle

pos: module:AWT.Point

Inherited from module:AWT.Shape#pos

Overrides: module:boxes/AbstractBox.AbstractBox#pos

The current position of the shape