pub struct TooltipOverlay { /* private fields */ }Expand description
Per-window tooltip provider and overlay.
Show requests are ignored on iOS and Android, where touch input must not
open hover tooltips. This does not control GPUI’s native .tooltip() API.
Implementations§
Source§impl TooltipOverlay
impl TooltipOverlay
pub fn new() -> Self
pub fn render_with( self, renderer: impl Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement + 'static, ) -> Self
pub fn request_show( &mut self, content: TooltipRequest, window: &mut Window, cx: &mut Context<'_, Self>, )
pub fn request_hide(&mut self, window: &mut Window, cx: &mut Context<'_, Self>)
pub fn hide(&mut self, cx: &mut Context<'_, Self>)
Trait Implementations§
Source§impl Default for TooltipOverlay
impl Default for TooltipOverlay
Source§impl Render for TooltipOverlay
impl Render for TooltipOverlay
Auto Trait Implementations§
impl !RefUnwindSafe for TooltipOverlay
impl !Send for TooltipOverlay
impl !Sync for TooltipOverlay
impl !UnwindSafe for TooltipOverlay
impl Forget for TooltipOverlay
impl Freeze for TooltipOverlaywhere
*const RcInner<dyn Fn(&mut Window, &mut App) -> AnyView> is !null: Freeze,
PhantomData<RcInner<dyn Fn(&mut Window, &mut App) -> AnyView>>: Freeze,
*const () is !null: Freeze,
PhantomData<((), RunnableMeta)>: Freeze,
*const Task<Box<dyn Any + Sync + Send>> is !null: Freeze,
PhantomData<Task<Box<dyn Any + Sync + Send>>>: Freeze,
PhantomData<fn()>: Freeze,
*const ArcInner<Mutex<RawMutex, RendezvousState<()>>> is !null: Freeze,
PhantomData<ArcInner<Mutex<RawMutex, RendezvousState<()>>>>: Freeze,
*const RcInner<dyn Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement> is !null: Freeze,
PhantomData<RcInner<dyn Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement>>: Freeze,
NonZero<u32>: Freeze,
*const (): Freeze,
*const ArcInner<RwLock<RawRwLock, EntityRefCounts>> is !null: Freeze,
&'static str: Freeze,
impl Move for TooltipOverlay
impl Unpin for TooltipOverlaywhere
Rc<dyn Fn(&mut Window, &mut App) -> AnyView>: Unpin,
Task<(), RunnableMeta>: Unpin,
Box<Task<Box<dyn Any + Sync + Send>>>: Unpin,
Arc<Mutex<RawMutex, RendezvousState<()>>>: Unpin,
Rc<dyn Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement>: Unpin,
NonZero<u32>: Unpin,
*const (): Unpin,
*const ArcInner<RwLock<RawRwLock, EntityRefCounts>> is !null: Unpin,
&'static str: Unpin,
impl UnsafeUnpin for TooltipOverlaywhere
*const RcInner<dyn Fn(&mut Window, &mut App) -> AnyView> is !null: UnsafeUnpin,
PhantomData<RcInner<dyn Fn(&mut Window, &mut App) -> AnyView>>: UnsafeUnpin,
*const () is !null: UnsafeUnpin,
PhantomData<((), RunnableMeta)>: UnsafeUnpin,
*const Task<Box<dyn Any + Sync + Send>> is !null: UnsafeUnpin,
PhantomData<Task<Box<dyn Any + Sync + Send>>>: UnsafeUnpin,
PhantomData<fn()>: UnsafeUnpin,
*const ArcInner<Mutex<RawMutex, RendezvousState<()>>> is !null: UnsafeUnpin,
PhantomData<ArcInner<Mutex<RawMutex, RendezvousState<()>>>>: UnsafeUnpin,
*const RcInner<dyn Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement> is !null: UnsafeUnpin,
PhantomData<RcInner<dyn Fn(AnyView, TooltipTransition, &mut Window, &mut App) -> AnyElement>>: UnsafeUnpin,
NonZeroU32Inner: UnsafeUnpin,
*const (): UnsafeUnpin,
*const ArcInner<RwLock<RawRwLock, EntityRefCounts>> is !null: UnsafeUnpin,
&'static str: UnsafeUnpin,
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().