pub struct Caret { /* private fields */ }Expand description
重导出所有内置元素类型 下拉选择箭头(caret)元素。
Implementations§
Source§impl Caret
impl Caret
Sourcepub fn new(size: ElementSize) -> Self
pub fn new(size: ElementSize) -> Self
创建尺寸适配触发器的选择箭头。
Sourcepub fn text_color(self, color: Hsla) -> Self
pub fn text_color(self, color: Hsla) -> Self
设置箭头颜色。
Trait Implementations§
Source§impl IntoElement for Caret
impl IntoElement for Caret
Source§fn into_element(self) -> Self::Element
fn into_element(self) -> Self::Element
将 self 转换为实现
Element 的类型。Source§fn into_any_element(self) -> AnyElement
fn into_any_element(self) -> AnyElement
将 self 转换为动态类型的
AnyElement。Source§impl RenderOnce for Caret
impl RenderOnce for Caret
Source§fn render(self, _: &mut Window, _: &mut App) -> impl IntoElement
fn render(self, _: &mut Window, _: &mut App) -> impl IntoElement
将此组件渲染为元素树。注意此方法获取 self 的所有权,
而
Render::render() 接收可变引用。Auto Trait Implementations§
impl Freeze for Caret
impl RefUnwindSafe for Caret
impl Send for Caret
impl Sync for Caret
impl Unpin for Caret
impl UnsafeUnpin for Caret
impl UnwindSafe for Caret
Blanket Implementations§
Source§impl<E> AnimationExt for Ewhere
E: IntoElement + 'static,
impl<E> AnimationExt for Ewhere
E: IntoElement + 'static,
Source§fn with_animation(
self,
id: impl Into<ElementId>,
animation: Animation,
animator: impl Fn(Self, f32) -> Self + 'static,
) -> AnimationElement<Self>where
Self: Sized,
fn with_animation(
self,
id: impl Into<ElementId>,
animation: Animation,
animator: impl Fn(Self, f32) -> Self + 'static,
) -> AnimationElement<Self>where
Self: Sized,
使用动画渲染此组件或元素
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
Source§impl<T> FluentBuilder for Twhere
T: IntoElement,
impl<T> FluentBuilder for Twhere
T: IntoElement,
Source§fn when(self, condition: bool, then: impl FnOnce(Self) -> Self) -> Selfwhere
Self: Sized,
fn when(self, condition: bool, then: impl FnOnce(Self) -> Self) -> Selfwhere
Self: Sized,
使用给定的闭包有条件地修改自身。
Source§fn when_else(
self,
condition: bool,
then: impl FnOnce(Self) -> Self,
else_fn: impl FnOnce(Self) -> Self,
) -> Selfwhere
Self: Sized,
fn when_else(
self,
condition: bool,
then: impl FnOnce(Self) -> Self,
else_fn: impl FnOnce(Self) -> Self,
) -> Selfwhere
Self: Sized,
使用给定的闭包有条件地修改自身。
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 more