Screen helpers · function

pixelCursor

Explained in Recording and clips.

function pixelCursor(rows: readonly string[], palette: Readonly<Record<string, string>>, options?: PixelCursorOptions): string
import { pixelCursor } from '@driftengine/core';

Parameters

ParameterTypeDescription
rowsreadonly string[]one string per row; each character indexes palette.
paletteReadonly<Record<string, string>>character → CSS colour. A character absent from it is transparent, which is what makes ' ' the natural empty cell.
options?PixelCursorOptions