Skip to content

Interface: Cell ​

Properties ​

area ​

ts
area: number;

bbox ​

ts
bbox: Rect;

boundary ​

ts
boundary: boolean;

The tile crosses the region outline (it was cut in "clip" mode, or sticks out in "overflow").


centroid ​

ts
centroid: Vec;

ts
optional featured?: number;

For a featured cell: its position in features. Featured cells get content first.


featuredItem? ​

ts
optional featuredItem?: number;

For a featured cell: the content item it's for, when its feature names one (Feature.item).


holes? ​

ts
optional holes?: Polygon[];

Holes in the visible shape, when a region hole lies wholly inside the tile. Absent otherwise. area and centroid account for them.


id ​

ts
id: string;

Stable id derived from the tile's position in the pattern.


index ​

ts
index: number;

Position in reading order (top-to-bottom, then left-to-right). Use it to assign content to cells.


merged? ​

ts
optional merged?: string[];

For a featured cell: ids of the tiles merged into it.


neighbors ​

ts
neighbors: string[];

Ids of cells that share an edge with this one in the underlying pattern.


original ​

ts
original: Polygon;

The full pattern tile before gap and edge handling.


polygon ​

ts
polygon: Polygon;

Visible shape: after gap and edge handling.


protoTile ​

ts
protoTile: number;

Which prototile this is a copy of (e.g. herringbone: 0 horizontal, 1 vertical).


tile? ​

ts
optional tile?: Polygon;

With edges: "window", for a cell the region outline cuts: the whole tile (after the gap), which renderers shape, round and fill, letting the region hide the rest. polygon is still the visible part (its largest piece, when the outline cuts the tile in two). See cellShape and visibleShapes.

Hat tiling and isohedral tilings after Craig S. Kaplan's hatviz and Tactile (BSD 3-Clause).