Specify layers?

Open
#356 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
csharp

Research direction

Start by reviewing the existing PinNodesToSameLayer behavior and the graph-layout API; the issue does not name a file, test, or entry point. Done should mean callers can explicitly assign nodes to the requested layers and obtain the illustrated ordering, including the separate layers for G, Z, and H.

Written by the indexing model from the issue text.

Description

I was wondering if there was a way to explicitly specify the layer that a node should be on?

For example, given the following :

image

Can I instead, specify something like the following pseudo code?

SetLayer(0, [E, D, B A]);
SetLayer(1, [F, C]);
SetLayer(2, [G]);
SetLayer(3, [Z]);
SetLayer(4, [H]);

So I get something like this ?
image

Basically, what I want is to be able to say that [E, D, B A] should be on one layer, [F, C] on another layer, G another, Z another and H another. I hope that makes sense.

I've tried using PinNodesToSameLayer, but I cant get the result I want for G, Z and H

Thank you

Dominant language
C#
Stars
1.5k
Forks
319
Avg merge
38m
Merged PRs (30d)
1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/automatic-graph-layout

All issues in microsoft/automatic-graph-layout

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.