This interface defines a child element of a table or a table element container.
Implements
- I
- I
- I
- I
Members
Show:
Properties
This is the maximum of minimumSize and the horizontal or vertical padding.
readonly
This is always the stripe size which is actually used for the stripe. For leaf stripes, this is the same as size, otherwise, it is the accumulated size of all descendants with taking nested padding into account.
readonly
See Also
Developer's Guide
Gets the direct children of stripe in a table hierarchy.
Gets the direct children of
stripe in a table hierarchy.readonly
See Also
Returns a collection of all descendants of stripe.
Returns a collection of all descendants of
stripe.The descendants are returned in top to bottom order.
readonly
Gets a collection of labels that are owned by this instance.
Gets a collection of labels that are owned by this instance.
This gives access to a read-only live view of the labels, i.e. the collection can change over time, as well as the labels contained in it. If a snapshot of the current state is needed, one needs to copy the collection and its contents.
To modify the label collection for instances of the default implementations that were created via the factory methods on IGraph, use addLabel and remove.
readonlyabstract
Examples
// add label with given text, default style, and default placement
// and determine the preferred size automatically
const label1 = graph.addLabel(node, 'Some Label')
// add label with given text, placement, style, size, and tag (user object)
const label2 = graph.addLabel(
node,
'Some Label',
InteriorNodeLabelModel.CENTER,
new LabelStyle(),
new Size(10, 150),
userObject,
)
// add label with given text and style but default placement
// and determine the preferred size automatically
const label3 = graph.addLabel({
owner: node,
text: 'Some Label',
style: new LabelStyle(),
})for (const label of node.labels) {
// ...
}graph.remove(label)See Also
Defined in
ILabelOwner.labelsGets a live view of the relative layout of the stripe.
Gets a live view of the relative layout of the stripe.
The layout of a stripe is a rectangle in the coordinate system that is relative to the upper left corner of the parent. Since this method will yield a live view, it is up to the client to copy the values of the instance if a snapshot of the state is needed.
readonlyabstract
See Also
Developer's Guide
Returns a collection of all descendants of stripe that are leaves and therefore don't have any child stripes.
Returns a collection of all descendants of
stripe that are leaves and therefore don't have any child stripes.Gets the minimal permissible value for size.
Gets the minimal permissible value for size.
This value determines how much the stripe may be shrunk by interactive manipulation.
readonlyabstract
Gets the padding for this stripe.
Gets the padding for this stripe.
This padding is applied in addition to any implicit padding provided by the child stripes. To find out the actual padding that is currently in effect, use totalPadding.
readonlyabstract
Gets the parent of stripe in a table hierarchy.
Gets the parent of
stripe in a table hierarchy.readonly
See Also
Gets the root of the stripe hierarchy of stripe in a table hierarchy.
Gets the root of the stripe hierarchy of
stripe in a table hierarchy.If the stripe is part of an ITable instance, this returns rootColumn for IColumn instances and parentRow for rootRow instances. Otherwise
null is returned.readonly
See Also
API
- rootColumn, rootRow, isRoot
Gets the style for this stripe.
Gets the style for this stripe.
The tag is an optional user-defined object which can be used to store arbitrary data related to this item. The item itself just provides the storage for the object.
abstract
Property Value
The user object associated with this item instance.
Examples
owner.tag = newTagconst tag = owner.tagSee Also
- Tags are presented in detail in the section The Graph Model.
Developer's Guide
Defined in
ITagOwner.tagMethods
Since layout is relative to the owning node's left corner, you need to provide an
node node to calculate the absolute layout.Parameters
- node: INode
- The node relative to which the stripe layout is calculated. This should be the same node where table for
stripeis associated to.
Return Value
- Rect
- The layout of the supplied stripe in absolute coordinates.
Typically, this method will be called to obtain a different view or aspect of the current instance. This is quite similar to casting or using a super type or interface of this instance, but is not limited to inheritance or compile-time constraints. An instance implementing this method is not required to return non-
null implementations for the types, nor does it have to return the same instance any time. Also, it depends on the type and context whether the instance returned stays up to date or needs to be re-obtained for further use.abstract
Parameters
- type: Constructor<T>
- the type for which an instance shall be returned
Return Value
- T
- an instance that is assignable to the type or
null
See Also
Developer's Guide