readCluster

open fun readCluster(col: Int, dest: IntArray): Int

Copies all codepoints of the grapheme cluster at col into dest and returns the number of codepoints written.

Zero-allocation contract: the renderer allocates dest once at startup and reuses it across all frames. This method never allocates.

Returns 0 for non-cluster cells; callers should check isCluster first or treat a return value of 0 as "use getCodepoint instead".

Return

Number of codepoints written, or 0 if the cell is not a cluster.

Parameters

col

Column index (0-based).

dest

Destination array. Must have capacity >= actual cluster length; there is no fixed public upper bound guaranteed by this API.