Skip to content

Add support for the label of border nodes #1071

Closed
@lfasani

Description

@lfasani

The aim is to display the label associated to the border node.

Current behavior

Both nodes and border nodes are considered as node.

Currently the the two types of label positioning are

  • label:inside-center: the label is inside the node. It is centered horizontally and on top vertically
  • label:outside-center: the label is outside and right above the node. It centered horizontally.

cd org.eclipse.sirius.components.diagrams.components.NodeComponent.doRender(VariableManager, String, Optional<Node>)

LabelType nodeLabelType = LabelType.INSIDE_CENTER;
if (NodeType.NODE_IMAGE.equals(type)) {
    nodeLabelType = LabelType.OUTSIDE_CENTER;
}

The label may overlap its node whatever its type. So the node size does not depends on its label

Expected behavior

The label for the border node must support both label:inside-center and label:outside-center types
The behavior is the same than nodes's.

The padding and margin are those used for ELK layout

ELK layout must have the same behavior than the incremental layout

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions