Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public final class Squarify
- Object
- Squarify
The squarified treemap layout of Bruls, Huizing and van Wijk: rectangles with areas
proportional to values and aspect ratios as close to square as the greedy row filling
allows, which keeps small cells readable.
Methods
public static float[][] layout(double[] values, float x, float y, float w, float h) | Lays out values in a rectangle. |
Inherited methods
Method details
layout
public static float[][] layout(double[] values, float x, float y, float w, float h)Lays out values in a rectangle.
Parameters
valuesdouble[]- the values, not necessarily sorted; negative and non-finite values count as 0
xfloat- the rectangle’s left
yfloat- the rectangle’s top
wfloat- the rectangle’s width
hfloat- the rectangle’s height
Returns
one
{x, y, w, h} per value, in the order given