pub enum OverlayAnchor {
Owner,
Rect(Rect),
}Expand description
What a slot places its surface against.
Both variants resolve to a window-space rect in the owner’s paint,
where the owner’s absolute origin is finally known; nothing is subscribed to
and nothing is cached across frames, so an anchor follows its owner across
scroll, relayout and animation for free.
Variants§
Owner
The owner’s own bounds — a trigger floating a menu under itself.
Rect(Rect)
A rect in the owner’s local space: a caret, a selection’s bounding
box, a press point, one row of a list. Translated by the owner’s paint
origin, so a caller states it in the same coordinates its layout and
event already speak.
Trait Implementations§
Source§impl Clone for OverlayAnchor
impl Clone for OverlayAnchor
impl Copy for OverlayAnchor
Source§impl Debug for OverlayAnchor
impl Debug for OverlayAnchor
Source§impl Default for OverlayAnchor
impl Default for OverlayAnchor
Source§impl PartialEq for OverlayAnchor
impl PartialEq for OverlayAnchor
impl StructuralPartialEq for OverlayAnchor
Auto Trait Implementations§
impl Freeze for OverlayAnchor
impl RefUnwindSafe for OverlayAnchor
impl Send for OverlayAnchor
impl Sync for OverlayAnchor
impl Unpin for OverlayAnchor
impl UnsafeUnpin for OverlayAnchor
impl UnwindSafe for OverlayAnchor
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
impl<T> Brush for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> StorageAccess<T> for T
impl<T> StorageAccess<T> for T
Source§fn as_borrowed(&self) -> &T
fn as_borrowed(&self) -> &T
Borrows the value.
Source§fn into_taken(self) -> T
fn into_taken(self) -> T
Takes the value.