Skip to main content

minimap_buckets_rows

Function minimap_buckets_rows 

Source
pub fn minimap_buckets_rows(
    pairs: &[DiffLineKind],
    rows: usize,
) -> Vec<MinimapBucket>
Expand description

Bucket a flat list of (line-kind) rows into rows slots so the minimap draws one cell per visible row.

Out-of-bounds rows are clamped (no crash) — the caller may pass a rows count derived from the viewport height, which can shift between frames as the user resizes.