A revisioned atomic set of text edits and resulting selections.
Use new/2 with a GPUI.Text.Snapshot when preparing an external edit. The
constructor copies the snapshot revision and current selections, so callers
specify only what changes. Pass :selections when the transaction should
produce a different complete selection set.
Summary
Functions
Builds a validated transaction against the supplied text snapshot.
Validates a transaction's public shape and returns it.
Types
@type t() :: %GPUI.Text.Transaction{ base_revision: non_neg_integer(), edits: [GPUI.Text.Edit.t()], id: String.t(), origin: origin(), selections: [GPUI.Text.Selection.t()] }
Functions
@spec new( GPUI.Text.Snapshot.t(), keyword() ) :: t()
Builds a validated transaction against the supplied text snapshot.
Validates a transaction's public shape and returns it.