ObjectProfile / Roassal2

Agile Visualization Engine for Pharo and VisualWorks
http://AgileVisualization.com
MIT License
26 stars 20 forks source link

Layered TreeLayout does not align elements on the top #29

Closed pavel-krivanek closed 5 years ago

pavel-krivanek commented 5 years ago

Issue by girba Friday Jun 09, 2017 at 08:32 GMT Originally opened as https://github.com/moosetechnology/Moose/issues/1222


Take a look at this script: http://ws.stfx.eu/54G9IO1XX4R2

The issue is that instead of aligning the top left, it kind of centers the entities from the same layer.

This used to work properly, and the tree algorithm did not change. So something must have changed not too long ago related to translations.

bergel commented 5 years ago

For the horizontal layout, it seems to works properly:

view := RTMondrian new.
view shape rectangle width: [:x | x * 2].
view nodes: (1 to: 99).
view edges connectFrom: [ :x | x // 5 ].
view layout horizontalTree layered.
view.
image
bergel commented 5 years ago

I have just fixed the issue:

view := RTMondrian new.
view shape rectangle height: [:x | x * 2].
view nodes: (1 to: 99).
view edges connectFrom: [ :x | x // 5 ].
view layout tree layered.
view.
image

In version 2dd177e0 @girba