code_forge/editor library

Functions

foldsComputeAll({required Rope rope}) → Future<List<RustFoldRange>>
Bracket-based fold ranges. Brackets inside strings and comments are not excluded, so replace this with tree-sitter/LSP folds when available.
foldsFindMatchingBracket({required Rope rope, required int targetOffset, int maxScan = 100000}) → int
Offset of the bracket matching the one at targetOffset, or -1. Scans in 4 KB slices and gives up after maxScan code units.
guidesComputeViewport({required Rope rope, required int firstVisible, required int lastVisible, required int tabSize}) → List<GuideBlock>
Indent info for visible lines. Blank (whitespace-only) lines are skipped. Tabs advance to the next tab stop, so tab-indented files get correct levels.
wordsExtract({required Rope rope}) → Future<List<String>>