If the drawing area is not a square, arranging the levels as
circles is not always the best choice. You can specify the aspect
ratio of the drawing area to better fit the layout to the drawing
area. In this case, the algorithm uses ellipses instead of circles.
See Tree layout in radial layout mode with aspect
ratio 1.5 for an example.
To specify the aspect ratio:
In CSS
Add this, for instance, to the
GraphLayout
section:
aspectRatio: "0.7";
In Java
In Java™, there are several
possibilities.
If the drawing area is a view (a subclass of
IlvManagerView
), you can use the method:
void setAspectRatio(IlvManagerView view);
If the drawing area is specified only as
a rectangle, use:
void setAspectRatio(IlvRect rect);
If neither a view nor a rectangle is specified, you can
calculate the aspect ratio from the width and height of the
drawing area as
aspectRatio = width/height
and use the method:
void setAspectRatio(float aspectRatio);