pub struct ContentSnapshot {
pub pre: Vec<InlineContent>,
pub post: Vec<InlineContent>,
}Expand description
MWA-C-undo_redo: styled-content snapshots for an operation.
Kept OUT of the FFI-exposed UndoableOperation (which crosses the C API
via inspect_undo_operation) and keyed by TextChangeset.id. Undo restores
pre, redo restores post — previously both rebuilt the text with
StyleProperties::default(), discarding all styling, and redo re-entered
the recording pipeline (double-recording + clearing the redo stack).
Fields§
§pre: Vec<InlineContent>Full styled inline content BEFORE the operation
post: Vec<InlineContent>Full styled inline content AFTER the operation
Trait Implementations§
Source§impl Clone for ContentSnapshot
impl Clone for ContentSnapshot
Source§fn clone(&self) -> ContentSnapshot
fn clone(&self) -> ContentSnapshot
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ContentSnapshot
impl RefUnwindSafe for ContentSnapshot
impl Send for ContentSnapshot
impl Sync for ContentSnapshot
impl Unpin for ContentSnapshot
impl UnsafeUnpin for ContentSnapshot
impl UnwindSafe for ContentSnapshot
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more