Expand description
Selection-aware edit planning for the synchronous engine.
Every command that mutates buffer text routes through here. The public
SelectionEdit enum names the operation; plan turns it into a
SelectionEditPlan of atomic EditOps in descending byte order
(so sequential Buffer::apply calls keep their pre-edit offsets valid)
plus the post-edit selection set; apply_plan runs the ops against a
mutable buffer and returns the final revision.
Per-family planners (newlines, word-scope deletes, line ops, inline shape edits, markdown) live in sibling modules to keep this file under the 600-line cap.
Structs§
- Selection
Edit Plan - A planned selection edit against one immutable pre-edit buffer state.
Enums§
- Case
Kind - Case-conversion kinds.
- Emphasis
Kind - Markdown emphasis flavor.
- Indent
Unit - Indent unit used by
SelectionEdit::Indent/SelectionEdit::Outdent. - Line
Ending - Line-ending convention.
- Selection
Edit - A selection-aware edit requested by an editor command.
- Sort
Kind - Sort variant used by
SelectionEdit::SortLines.
Functions§
- apply_
plan - Apply already-planned ops and assign the final selection set.
- plan
- Build atomic edit ops for a selection-aware edit.