New to KendoReact? Start a free 30-day trial

Layout

Class

Represents a layout container that automatically arranges child elements. Extends Group to provide automatic layout and positioning capabilities.

Definition

Package:@progress/kendo-react-diagram

Properties

Array of child visual elements contained in this group.

The underlying drawing element that handles the actual rendering.

id

string

The unique identifier of the element.

Configuration options for the element.

Methods

Appends a visual element to this group.

Parameters:visualany

The visual element to append to the group

Removes all child visual elements from this group.

Gets the drawing container for this element.

Returns:

any

The drawing element container

Gets the position of the element.

Returns:

Point

The current element position.

Sets the position of the element from a point.

Parameters:pointPoint

The new element position.

Sets the position of the element from coordinates.

Parameters:xnumber

The horizontal coordinate.

ynumber

The vertical coordinate.

Gets the rectangle bounds of the layout.

Returns:

undefined | Rect

The current layout bounds, or undefined when no bounds are set.

Sets the rectangle bounds of the layout.

Parameters:rectRect

The new layout bounds.

Redraws the layout with updated options.

Parameters:optionsany

New options to apply to the layout

Triggers a reflow of the layout, recalculating positions and sizes.

Removes a visual element from this group.

Parameters:visualany

The visual element to remove from the group

Gets the rotation of the element.

Returns:

Rotation

The current element rotation.

Sets the rotation of the element.

Parameters:anglenumber

The rotation angle in radians.

centerPoint

The center of rotation.

Returns:

Rotation

The applied element rotation.

Moves the specified visual elements to the back of the display order.

Parameters:visualsany

Array of visual elements to move to back

Moves the specified visual elements to the front of the display order.

Parameters:visualsany

Array of visual elements to move to front

Moves the specified visual elements to specific indices in the display order.

Parameters:visualsany

Array of visual elements to reorder

indicesany

Target indices for the visual elements

Gets the visibility of the element.

Returns:

boolean

true when the element is visible; otherwise, false.

Sets the visibility of the element.

Parameters:valueboolean

Whether the element should be visible.