pub enum LayoutUndoOp<T: LayoutBase> {
HierarchyOp(HierarchyUndoOp<T>),
SetDbu(T::Coord),
CreateLayer(T::LayerId),
SetLayerName(T::LayerId, Option<T::NameType>),
InsertShape(T::ShapeId),
RemoveShape {
parent_cell: T::CellId,
layer: T::LayerId,
geometry: Geometry<T::Coord>,
},
ReplaceShape(T::ShapeId, Geometry<T::Coord>),
SetTransform(T::CellInstId, SimpleTransform<T::Coord>),
}Expand description
Undo operation for LayoutEdit operations.
Variants§
HierarchyOp(HierarchyUndoOp<T>)
Undo an operation on the cell hierarchy.
SetDbu(T::Coord)
Store previous dbu.
CreateLayer(T::LayerId)
Store ID of the created layer.
SetLayerName(T::LayerId, Option<T::NameType>)
Store previous layer name.
InsertShape(T::ShapeId)
Store id of created shape.
RemoveShape
Store the geometry of the previous shape.
Fields
ReplaceShape(T::ShapeId, Geometry<T::Coord>)
Store the old geometry of the shape.
SetTransform(T::CellInstId, SimpleTransform<T::Coord>)
Store the old transform.
Trait Implementations§
Source§impl<T: LayoutBase> From<HierarchyUndoOp<T>> for LayoutUndoOp<T>
impl<T: LayoutBase> From<HierarchyUndoOp<T>> for LayoutUndoOp<T>
Source§fn from(op: HierarchyUndoOp<T>) -> Self
fn from(op: HierarchyUndoOp<T>) -> Self
Converts to this type from the input type.
Source§impl<T: L2NBase> From<LayoutUndoOp<T>> for L2NUndoOp<T>
impl<T: L2NBase> From<LayoutUndoOp<T>> for L2NUndoOp<T>
Source§fn from(op: LayoutUndoOp<T>) -> Self
fn from(op: LayoutUndoOp<T>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<T> Freeze for LayoutUndoOp<T>where
<T as LayoutIds>::Coord: Freeze,
<T as LayoutIds>::LayerId: Freeze,
<T as LayoutIds>::ShapeId: Freeze,
<T as HierarchyIds>::CellId: Freeze,
<T as HierarchyIds>::CellInstId: Freeze,
<T as HierarchyBase>::NameType: Freeze,
impl<T> RefUnwindSafe for LayoutUndoOp<T>where
<T as LayoutIds>::Coord: RefUnwindSafe,
<T as LayoutIds>::LayerId: RefUnwindSafe,
<T as LayoutIds>::ShapeId: RefUnwindSafe,
<T as HierarchyIds>::CellId: RefUnwindSafe,
<T as HierarchyIds>::CellInstId: RefUnwindSafe,
<T as HierarchyBase>::NameType: RefUnwindSafe,
impl<T> Send for LayoutUndoOp<T>where
<T as LayoutIds>::LayerId: Send,
<T as LayoutIds>::ShapeId: Send,
<T as HierarchyIds>::CellId: Send,
<T as HierarchyIds>::CellInstId: Send,
<T as HierarchyBase>::NameType: Send,
impl<T> Sync for LayoutUndoOp<T>where
<T as LayoutIds>::LayerId: Sync,
<T as LayoutIds>::ShapeId: Sync,
<T as HierarchyIds>::CellId: Sync,
<T as HierarchyIds>::CellInstId: Sync,
<T as HierarchyBase>::NameType: Sync,
impl<T> Unpin for LayoutUndoOp<T>where
<T as LayoutIds>::Coord: Unpin,
<T as LayoutIds>::LayerId: Unpin,
<T as LayoutIds>::ShapeId: Unpin,
<T as HierarchyIds>::CellId: Unpin,
<T as HierarchyIds>::CellInstId: Unpin,
<T as HierarchyBase>::NameType: Unpin,
impl<T> UnwindSafe for LayoutUndoOp<T>where
<T as LayoutIds>::Coord: UnwindSafe,
<T as LayoutIds>::LayerId: UnwindSafe,
<T as LayoutIds>::ShapeId: UnwindSafe,
<T as HierarchyIds>::CellId: UnwindSafe,
<T as HierarchyIds>::CellInstId: UnwindSafe,
<T as HierarchyBase>::NameType: UnwindSafe,
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> 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