Welcome to yEd Q&A!
Here you can ask questions and receive answers from other members of the community and yEd developers. And you can tell us your most wanted feature requests.


PartialLayout consider node labels in groups?

0 votes

I have a question about using the 'PartialLayout' in yFiles. 

I'm currently working with a graph that has been morphed using an unspecified layout. However, I also want the groups and their children in my graph to always be arranged using the 'HierarchicLayout'. In my attempt to achieve this, I used the 'PartialLayout' and set the affectedNodes and affectedEdges. While this approach somewhat worked – the nodes and edges within the groups were correctly arranged – I'm facing issues with the labels being considered properly. It seems that the labels are not being calculated by the IGroupBoundsCalculator when I use 'PartialLayout'. Is this an expected behavior, or is there a workaround to include label calculations in 'PartialLayout'?

This is my current approach:

const pL = new PartialLayout({
  coreLayout: hL,
  layoutOrientation: PartialLayoutOrientation.LEFT_TO_RIGHT,
  considerNodeAlignment: true,

const pD = new PartialLayoutData({
  affectedNodes: ItemCollection.from(affectedNodes),
  affectedEdges: ItemCollection.from(affectedEdges),

Any insights or suggestions on how to resolve this issue would be greatly appreciated.

Thank you!

closed with the note: Not a yEd question
in Help by
closed by

1 Answer

0 votes

This forum is for yEd questions only. For questions regarding the yFiles for HTML programming library, please contact yWorks support by mail. (Please include your yWorks customer or evaluator ID in your mail when doing so.)

by [yWorks] (161k points)
Legal Disclosure | Privacy Policy