Klortho / d3-flextree

Flexible tree layout algorithm that allows for variable node sizes
https://klortho.github.io/d3-flextree/
Do What The F*ck You Want To Public License
327 stars 45 forks source link

Horizontal tree #29

Open samevision opened 2 years ago

samevision commented 2 years ago

Hello,

thanks for providing this package!

Is it also possible to create a horizontal tree?

Best

Bogdan-Lyashenko commented 2 years ago

Hey, by "horizontal" you mean the root of the tree starting from the left and not from the top?

samevision commented 2 years ago

Hey,

yes, exactly. Is that possible?

Thanks.

SalHe commented 2 years ago

Just use a new coordinate system which inverts x and y.(treat X as Y, Y as X, width as height, height as width)