Skip to main content

ListTile

Struct ListTile 

Source
pub struct ListTile {
Show 38 fields pub key: Option<KeyRef>, pub leading: Option<WidgetRef>, pub title: Option<WidgetRef>, pub subtitle: Option<WidgetRef>, pub trailing: Option<WidgetRef>, pub is_three_line: Option<bool>, pub dense: Option<bool>, pub visual_density: Option<VisualDensity>, pub shape: Option<ShapeBorderRef>, pub selected_color: Option<Color>, pub icon_color: Option<AnyColor>, pub text_color: Option<AnyColor>, pub title_text_style: Option<TextStyle>, pub subtitle_text_style: Option<TextStyle>, pub leading_and_trailing_text_style: Option<TextStyle>, pub style: Option<ListTileStyle>, pub content_padding: Option<EdgeInsetsGeometry>, pub enabled: bool, pub on_tap: Option<GestureTapCallback>, pub on_long_press: Option<GestureLongPressCallback>, pub on_focus_change: Option<ValueChanged<bool>>, pub mouse_cursor: Option<MouseCursorRef>, pub selected: bool, pub focus_color: Option<Color>, pub hover_color: Option<Color>, pub splash_color: Option<Color>, pub focus_node: Option<FocusNodeRef>, pub autofocus: bool, pub tile_color: Option<Color>, pub selected_tile_color: Option<Color>, pub enable_feedback: Option<bool>, pub horizontal_title_gap: Option<f64>, pub min_vertical_padding: Option<f64>, pub min_leading_width: Option<f64>, pub min_tile_height: Option<f64>, pub title_alignment: Option<ListTileTitleAlignment>, pub internal_add_semantic_for_on_tap: bool, pub states_controller: Option<Ref<MaterialStatesController>>,
}
Expand description

A single fixed-height row that typically contains some text as well as a leading or trailing icon.

A list tile contains one to three lines of text optionally flanked by icons or other widgets, such as check boxes. The icons (or other widgets) for the tile are defined with the leading and trailing parameters. The first line of text is not optional and is specified with title. The value of subtitle, which is optional, will occupy the space allocated for an additional line of text, or two lines if is_three_line is true. If dense is true then the overall height of this tile and the size of the DefaultTextStyles that wrap the title and subtitle widget are reduced.

It is the responsibility of the caller to ensure that title does not wrap, and to ensure that subtitle doesn’t wrap (if is_three_line is false) or wraps to two lines (if it is true).

The heights of the leading and trailing widgets are constrained according to the Material spec. An exception is made for one-line ListTiles for accessibility. Please see the example below to see how to adhere to both Material spec and accessibility requirements.

The leading and trailing widgets can expand as far as they wish horizontally, so ensure that they are properly constrained.

List tiles are typically used in ListViews, or arranged in Columns in Drawers and Cards.

This widget requires a Material widget ancestor in the tree to paint itself on, which is typically provided by the app’s Scaffold. The tile_color, selected_tile_color, focus_color, and hover_color are not painted by the ListTile itself but by the Material widget ancestor. In this case, one can wrap a Material widget around the ListTile.

§Performance considerations when wrapping ListTile with Material

Wrapping a large number of ListTiles individually with Materials is expensive. Consider only wrapping the ListTiles that require it or include a common Material ancestor where possible.

ListTile must be wrapped in a Material widget to animate tile_color, selected_tile_color, focus_color, and hover_color as these colors are not drawn by the list tile itself but by the material widget ancestor.

To use a ListTile within a Row, it needs to be wrapped in an Expanded widget. ListTile requires fixed width constraints, whereas a Row does not constrain its children.

To be accessible, tappable leading and trailing widgets have to be at least 48x48 in size. However, to adhere to the Material spec, trailing and leading widgets in one-line ListTiles should visually be at most 32 (dense: true) or 40 (dense: false) in height, which may conflict with the accessibility requirement.

For this reason, a one-line ListTile allows the height of leading and trailing widgets to be constrained by the height of the ListTile. This allows for the creation of tappable leading and trailing widgets that are large enough, but it is up to the developer to ensure that their widgets follow the Material spec.

§The ListTile layout isn’t exactly what I want

If the way ListTile pads and positions its elements isn’t quite what you’re looking for, it’s easy to create custom list items with a combination of other widgets, such as Rows and Columns.

See also:

Fields§

§key: Option<KeyRef>§leading: Option<WidgetRef>

A widget to display before the title.

Typically an Icon or a CircleAvatar widget.

§title: Option<WidgetRef>

The primary content of the list tile.

Typically a Text widget.

This should not wrap. To enforce the single line limit, use Text::max_lines.

§subtitle: Option<WidgetRef>

Additional content displayed below the title.

Typically a Text widget.

If is_three_line is false, this should not wrap.

If is_three_line is true, this should be configured to take a maximum of two lines. For example, you can use Text::max_lines to enforce the number of lines.

The subtitle’s default TextStyle depends on TextTheme::body_medium except TextStyle::color. The TextStyle::color depends on the value of enabled and selected.

When enabled is false, the text color is set to ThemeData::disabled_color.

When selected is false, the text color is set to ListTileTheme::text_color if it’s not null and to TextTheme::body_small’s color if ListTileTheme::text_color is null.

§trailing: Option<WidgetRef>

A widget to display after the title.

Typically an Icon widget.

To show right-aligned metadata (assuming left-to-right reading order; left-aligned for right-to-left reading order), consider using a Row with CrossAxisAlignment::Baseline alignment whose first item is Expanded and whose second child is the metadata text, instead of using the trailing property.

§is_three_line: Option<bool>

Whether this list tile is intended to display three lines of text.

If true, then subtitle must be non-null (since it is expected to give the second and third lines of text).

If false, the list tile is treated as having one line if the subtitle is null and treated as having two lines if the subtitle is non-null.

When using a Text widget for title and subtitle, you can enforce line limits using Text::max_lines.

See also:

§dense: Option<bool>

Whether this list tile is part of a vertically dense list.

If this property is null then its value is based on ListTileTheme::dense.

Dense list tiles default to a smaller height.

It is not recommended to set dense to true when ThemeData::use_material3 is true.

§visual_density: Option<VisualDensity>

Defines how compact the list tile’s layout will be.

See also:

  • ThemeData::visual_density, which specifies the visual_density for all widgets within a Theme.
§shape: Option<ShapeBorderRef>

Defines the tile’s InkWell::custom_border and Ink::decoration shape.

If this property is null then ListTileThemeData::shape is used. If that is also null then a rectangular Border will be used.

See also:

§selected_color: Option<Color>

Defines the color used for icons and text when the list tile is selected.

If this property is null then ListTileThemeData::selected_color is used. If that is also null then ColorScheme::primary is used.

See also:

§icon_color: Option<AnyColor>

Defines the default color for leading and trailing icons.

If this property is null and selected is false then ListTileThemeData::icon_color is used. If that is also null and ThemeData::use_material3 is true, ColorScheme::on_surface_variant is used, otherwise if ThemeData::brightness is Brightness::Light, Colors::BLACK54 is used, and if ThemeData::brightness is Brightness::Dark, the value is null.

If this property is null and selected is true then ListTileThemeData::selected_color is used. If that is also null then ColorScheme::primary is used.

If this color is a WidgetStateColor it will be resolved against WidgetState::Selected and WidgetState::Disabled states.

See also:

§text_color: Option<AnyColor>

Defines the text color for the title, subtitle, leading, and trailing.

If this property is null and selected is false then ListTileThemeData::text_color is used. If that is also null then default text color is used for the title, subtitle leading, and trailing. Except for subtitle, if ThemeData::use_material3 is false, TextTheme::body_small is used.

If this property is null and selected is true then ListTileThemeData::selected_color is used. If that is also null then ColorScheme::primary is used.

If this color is a WidgetStateColor it will be resolved against WidgetState::Selected and WidgetState::Disabled states.

See also:

§title_text_style: Option<TextStyle>

The text style for ListTile’s title.

If this property is null, then ListTileThemeData::title_text_style is used. If that is also null and ThemeData::use_material3 is true, TextTheme::body_large with ColorScheme::on_surface will be used. Otherwise, If ListTile style is ListTileStyle::List, TextTheme::title_medium will be used and if ListTile style is ListTileStyle::Drawer, TextTheme::body_large will be used.

§subtitle_text_style: Option<TextStyle>

The text style for ListTile’s subtitle.

If this property is null, then ListTileThemeData::subtitle_text_style is used. If that is also null and ThemeData::use_material3 is true, TextTheme::body_medium with ColorScheme::on_surface_variant will be used, otherwise TextTheme::body_medium with TextTheme::body_small color will be used.

§leading_and_trailing_text_style: Option<TextStyle>

The text style for ListTile’s leading and trailing.

If this property is null, then ListTileThemeData::leading_and_trailing_text_style is used. If that is also null and ThemeData::use_material3 is true, TextTheme::label_small with ColorScheme::on_surface_variant will be used, otherwise TextTheme::body_medium will be used.

§style: Option<ListTileStyle>

Defines the font used for the title.

If this property is null then ListTileThemeData::style is used. If that is also null then ListTileStyle::List is used.

See also:

§content_padding: Option<EdgeInsetsGeometry>

The tile’s internal padding.

Insets a ListTile’s contents: its leading, title, subtitle, and trailing widgets.

If this property is null, then ListTileThemeData::content_padding is used. If that is also null and ThemeData::use_material3 is true, then a default value of EdgeInsetsDirectional::only(start: 16.0, end: 24.0) will be used. Otherwise, a default value of EdgeInsets::symmetric(horizontal: 16.0) will be used.

§enabled: bool

Whether this list tile is interactive.

If false, this list tile is styled with the disabled color from the current Theme and the on_tap and on_long_press callbacks are inoperative.

§on_tap: Option<GestureTapCallback>

Called when the user taps this list tile.

Inoperative if enabled is false.

§on_long_press: Option<GestureLongPressCallback>

Called when the user long-presses on this list tile.

Inoperative if enabled is false.

§on_focus_change: Option<ValueChanged<bool>>

Handler called when the focus changes.

Called with true if this widget’s node gains focus, and false if it loses focus.

§mouse_cursor: Option<MouseCursorRef>

The cursor for a mouse pointer when it enters or is hovering over the widget.

If mouse_cursor is a WidgetStateMouseCursor, WidgetStateProperty::resolve is used for the following WidgetStates:

If null, then the value of ListTileThemeData::mouse_cursor is used. If that is also null, then WidgetStateMouseCursor::clickable is used.

§selected: bool

If this tile is also enabled then icons and text are rendered with the same color.

By default the selected color is the theme’s primary color. The selected color can be overridden with a ListTileTheme.

§focus_color: Option<Color>

The color for the tile’s Material when it has the input focus.

§hover_color: Option<Color>

The color for the tile’s Material when a pointer is hovering over it.

§splash_color: Option<Color>

The color of splash for the tile’s Material.

§focus_node: Option<FocusNodeRef>

An optional focus node to use as the focus node for this widget.

§autofocus: bool

True if this widget will be selected as the initial focus when no other node in its scope is currently focused.

§tile_color: Option<Color>

Defines the background color of ListTile when selected is false.

If this property is null and selected is false then ListTileThemeData::tile_color is used. If that is also null and selected is true, selected_tile_color is used. When that is also null, the ListTileTheme::selected_tile_color is used, otherwise Colors::TRANSPARENT is used.

§selected_tile_color: Option<Color>

Defines the background color of ListTile when selected is true.

When the value if null, the selected_tile_color is set to ListTileTheme::selected_tile_color if it’s not null and to Colors::TRANSPARENT if it’s null.

§enable_feedback: Option<bool>

Whether detected gestures should provide acoustic and/or haptic feedback.

For example, on Android a tap will produce a clicking sound and a long-press will produce a short vibration, when feedback is enabled.

When null, the default value is true.

See also:

  • Feedback for providing platform-specific feedback to certain actions.
§horizontal_title_gap: Option<f64>

The horizontal gap between the titles and the leading/trailing widgets.

If null, then the value of ListTileTheme::horizontal_title_gap is used. If that is also null, then a default value of 16 is used.

§min_vertical_padding: Option<f64>

The minimum padding on the top and bottom of the title and subtitle widgets.

If null, then the value of ListTileTheme::min_vertical_padding is used. If that is also null, then a default value of 4 is used.

§min_leading_width: Option<f64>

The minimum width allocated for the ListTile::leading widget.

If null, then the value of ListTileTheme::min_leading_width is used. If that is also null, then a default value of 40 is used.

§min_tile_height: Option<f64>

The minimum height allocated for the ListTile widget.

If this is null, default tile heights are 56.0, 72.0, and 88.0 for one, two, and three lines of text respectively. If isDense is true, these defaults are changed to 48.0, 64.0, and 76.0. A visual density value or a large title will also adjust the default tile heights.

§title_alignment: Option<ListTileTitleAlignment>

Defines how ListTile::leading and ListTile::trailing are vertically aligned relative to the ListTile’s titles (ListTile::title and ListTile::subtitle).

If this property is null then ListTileThemeData::title_alignment is used. If that is also null then ListTileTitleAlignment::ThreeLine is used.

See also:

§internal_add_semantic_for_on_tap: bool

Whether to add button:true to the semantics if onTap is provided. This is a temporary flag to help changing the behavior of ListTile onTap semantics.

Defaults to true.

§states_controller: Option<Ref<MaterialStatesController>>

Represents the interactive “state” of this widget in terms of a set of WidgetStates, including WidgetState::Pressed, WidgetState::Hovered and WidgetState::Focused.

Implementations§

Source§

impl ListTile

Source

pub fn new() -> ListTile

Creates a list tile; Dart’s named arguments are the setters.

If is_three_line is true, then subtitle must not be null.

Requires one of its ancestors to be a Material widget.

Source

pub fn key(self, key: KeyRef) -> ListTile

Dart ListTile(key:).

Source

pub fn leading<K>(self, leading: impl IntoWidget<K>) -> ListTile

Dart ListTile(leading:).

Source

pub fn title<K>(self, title: impl IntoWidget<K>) -> ListTile

Dart ListTile(title:).

Source

pub fn subtitle<K>(self, subtitle: impl IntoWidget<K>) -> ListTile

Dart ListTile(subtitle:).

Source

pub fn trailing<K>(self, trailing: impl IntoWidget<K>) -> ListTile

Dart ListTile(trailing:).

Source

pub fn is_three_line(self, is_three_line: bool) -> ListTile

Dart ListTile(isThreeLine:).

Source

pub fn dense(self, dense: impl Into<bool>) -> ListTile

Dart ListTile(dense:).

Source

pub fn visual_density( self, visual_density: impl Into<VisualDensity>, ) -> ListTile

Dart ListTile(visualDensity:).

Source

pub fn shape(self, shape: impl Into<ShapeBorderRef>) -> ListTile

Dart ListTile(shape:).

Source

pub fn style(self, style: impl Into<ListTileStyle>) -> ListTile

Dart ListTile(style:).

Source

pub fn selected_color(self, selected_color: impl Into<Color>) -> ListTile

Dart ListTile(selectedColor:).

Source

pub fn icon_color(self, icon_color: impl Into<AnyColor>) -> ListTile

Dart ListTile(iconColor:).

Source

pub fn text_color(self, text_color: impl Into<AnyColor>) -> ListTile

Dart ListTile(textColor:).

Source

pub fn title_text_style( self, title_text_style: impl Into<TextStyle>, ) -> ListTile

Dart ListTile(titleTextStyle:).

Source

pub fn subtitle_text_style( self, subtitle_text_style: impl Into<TextStyle>, ) -> ListTile

Dart ListTile(subtitleTextStyle:).

Source

pub fn leading_and_trailing_text_style( self, leading_and_trailing_text_style: impl Into<TextStyle>, ) -> ListTile

Dart ListTile(leadingAndTrailingTextStyle:).

Source

pub fn content_padding( self, content_padding: impl Into<EdgeInsetsGeometry>, ) -> ListTile

Dart ListTile(contentPadding:).

Source

pub fn on_tap(self, on_tap: impl Into<GestureTapCallback>) -> ListTile

Dart ListTile(onTap:).

Source

pub fn on_long_press( self, on_long_press: impl Into<GestureLongPressCallback>, ) -> ListTile

Dart ListTile(onLongPress:).

Source

pub fn on_focus_change( self, on_focus_change: impl Into<ValueChanged<bool>>, ) -> ListTile

Dart ListTile(onFocusChange:).

Source

pub fn mouse_cursor(self, mouse_cursor: impl Into<MouseCursorRef>) -> ListTile

Dart ListTile(mouseCursor:).

Source

pub fn focus_color(self, focus_color: impl Into<Color>) -> ListTile

Dart ListTile(focusColor:).

Source

pub fn hover_color(self, hover_color: impl Into<Color>) -> ListTile

Dart ListTile(hoverColor:).

Source

pub fn splash_color(self, splash_color: impl Into<Color>) -> ListTile

Dart ListTile(splashColor:).

Source

pub fn focus_node(self, focus_node: impl Into<FocusNodeRef>) -> ListTile

Dart ListTile(focusNode:).

Source

pub fn tile_color(self, tile_color: impl Into<Color>) -> ListTile

Dart ListTile(tileColor:).

Source

pub fn selected_tile_color( self, selected_tile_color: impl Into<Color>, ) -> ListTile

Dart ListTile(selectedTileColor:).

Source

pub fn enable_feedback(self, enable_feedback: impl Into<bool>) -> ListTile

Dart ListTile(enableFeedback:).

Source

pub fn horizontal_title_gap( self, horizontal_title_gap: impl Into<f64>, ) -> ListTile

Dart ListTile(horizontalTitleGap:).

Source

pub fn min_vertical_padding( self, min_vertical_padding: impl Into<f64>, ) -> ListTile

Dart ListTile(minVerticalPadding:).

Source

pub fn min_leading_width(self, min_leading_width: impl Into<f64>) -> ListTile

Dart ListTile(minLeadingWidth:).

Source

pub fn min_tile_height(self, min_tile_height: impl Into<f64>) -> ListTile

Dart ListTile(minTileHeight:).

Source

pub fn title_alignment( self, title_alignment: impl Into<ListTileTitleAlignment>, ) -> ListTile

Dart ListTile(titleAlignment:).

Source

pub fn states_controller( self, states_controller: impl Into<Ref<MaterialStatesController>>, ) -> ListTile

Dart ListTile(statesController:).

Source

pub fn enabled(self, enabled: bool) -> ListTile

Dart ListTile(enabled:).

Source

pub fn selected(self, selected: bool) -> ListTile

Dart ListTile(selected:).

Source

pub fn autofocus(self, autofocus: bool) -> ListTile

Dart ListTile(autofocus:).

Source

pub fn internal_add_semantic_for_on_tap( self, internal_add_semantic_for_on_tap: bool, ) -> ListTile

Dart ListTile(internalAddSemanticForOnTap:).

Source

pub fn divide_tiles( app: &mut App, context: Option<BuildContext>, tiles: impl IntoIterator<Item = WidgetRef>, color: Option<Color>, ) -> Vec<WidgetRef>

Add a one pixel border in between each tile. If color isn’t specified the ThemeData::divider_color of the context’s Theme is used.

See also:

  • Divider, which you can use to obtain this effect manually.

Trait Implementations§

Source§

impl Clone for ListTile

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ListTile

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for ListTile

Source§

fn default() -> ListTile

Returns the “default value” for a type. Read more
Source§

impl StatelessWidget for ListTile

Source§

fn key(&self) -> Option<&KeyRef>

Source§

fn debug_fill_properties( &self, app: &App, properties: &mut DiagnosticPropertiesBuilder, )

Dart’s debugFillProperties: the properties a dump shows for this widget, in Dart’s order. Dart’s Widget base only sets the dense tree style, which the framework does.
Source§

fn debug_check_constructor(&self)

Dart’s constructor asserts that relate two or more arguments. Read more
Source§

fn build(&self, app: &mut App, context: BuildContext) -> WidgetRef

Describes the part of the user interface represented by this widget. Read more
Source§

fn as_preferred_size_widget( &self, ) -> Option<&(dyn PreferredSizeWidget + 'static)>

Dart’s this is PreferredSizeWidget: a widget that implements PreferredSizeWidget answers with itself, which is what a parent asking an erased child for its preferred size reads.

Auto Trait Implementations§

§

impl !RefUnwindSafe for ListTile

§

impl !Send for ListTile

§

impl !Sync for ListTile

§

impl !UnwindSafe for ListTile

§

impl Forget for ListTile

§

impl Freeze for ListTile
where *const RcInner<dyn Key> is !null: Freeze, PhantomData<RcInner<dyn Key>>: Freeze, *const RcInner<dyn Widget> is !null: Freeze, PhantomData<RcInner<dyn Widget>>: Freeze, *const RcInner<dyn ShapeBorder> is !null: Freeze, PhantomData<RcInner<dyn ShapeBorder>>: Freeze, &'static dyn ColorExtension: Freeze, *const RcInner<dyn ColorExtension> is !null: Freeze, PhantomData<RcInner<dyn ColorExtension>>: Freeze, *const u8 is !null: Freeze, PhantomData<u8>: Freeze, PhantomData<String>: Freeze, *const RcInner<Paint> is !null: Freeze, PhantomData<RcInner<Paint>>: Freeze, PhantomData<Shadow>: Freeze, PhantomData<FontFeature>: Freeze, PhantomData<FontVariation>: Freeze, *const RcInner<dyn Fn(&mut App)> is !null: Freeze, PhantomData<RcInner<dyn Fn(&mut App)>>: Freeze, NonZero<u32>: Freeze, *const (): Freeze, *const RcInner<dyn Fn(&mut App, bool)> is !null: Freeze, PhantomData<RcInner<dyn Fn(&mut App, bool)>>: Freeze, *const RcInner<dyn MouseCursor> is !null: Freeze, PhantomData<RcInner<dyn MouseCursor>>: Freeze, &'static FocusNodeVTable: Freeze, *const RcInner<Keep> is !null: Freeze, PhantomData<RcInner<Keep>>: Freeze, PhantomData<fn() -> WidgetStatesController>: Freeze,

§

impl Move for ListTile

§

impl Unpin for ListTile
where Rc<dyn Key>: Unpin, Rc<dyn Widget>: Unpin, Rc<dyn ShapeBorder>: Unpin, &'static dyn ColorExtension: Unpin, Rc<dyn ColorExtension>: Unpin, *const u8 is !null: Unpin, Rc<Paint>: Unpin, Rc<dyn Fn(&mut App)>: Unpin, NonZero<u32>: Unpin, *const (): Unpin, Rc<dyn Fn(&mut App, bool)>: Unpin, Rc<dyn MouseCursor>: Unpin, &'static FocusNodeVTable: Unpin, Rc<Keep>: Unpin,

§

impl UnsafeUnpin for ListTile
where *const RcInner<dyn Key> is !null: UnsafeUnpin, PhantomData<RcInner<dyn Key>>: UnsafeUnpin, *const RcInner<dyn Widget> is !null: UnsafeUnpin, PhantomData<RcInner<dyn Widget>>: UnsafeUnpin, *const RcInner<dyn ShapeBorder> is !null: UnsafeUnpin, PhantomData<RcInner<dyn ShapeBorder>>: UnsafeUnpin, &'static dyn ColorExtension: UnsafeUnpin, *const RcInner<dyn ColorExtension> is !null: UnsafeUnpin, PhantomData<RcInner<dyn ColorExtension>>: UnsafeUnpin, *const u8 is !null: UnsafeUnpin, PhantomData<u8>: UnsafeUnpin, PhantomData<String>: UnsafeUnpin, *const RcInner<Paint> is !null: UnsafeUnpin, PhantomData<RcInner<Paint>>: UnsafeUnpin, PhantomData<Shadow>: UnsafeUnpin, PhantomData<FontFeature>: UnsafeUnpin, PhantomData<FontVariation>: UnsafeUnpin, *const RcInner<dyn Fn(&mut App)> is !null: UnsafeUnpin, PhantomData<RcInner<dyn Fn(&mut App)>>: UnsafeUnpin, NonZeroU32Inner: UnsafeUnpin, *const (): UnsafeUnpin, *const RcInner<dyn Fn(&mut App, bool)> is !null: UnsafeUnpin, PhantomData<RcInner<dyn Fn(&mut App, bool)>>: UnsafeUnpin, *const RcInner<dyn MouseCursor> is !null: UnsafeUnpin, PhantomData<RcInner<dyn MouseCursor>>: UnsafeUnpin, &'static FocusNodeVTable: UnsafeUnpin, *const RcInner<Keep> is !null: UnsafeUnpin, PhantomData<RcInner<Keep>>: UnsafeUnpin, PhantomData<fn() -> WidgetStatesController>: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> Downcast<T> for T

Source§

fn downcast(&self) -> &T

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<W> IntoWidget<StatelessKind> for W
where W: StatelessWidget,

Source§

fn into_widget(self) -> Rc<dyn Widget>

The widget as a tree node, made where this is called: its creation_location.
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Upcast<T> for T

Source§

fn upcast(&self) -> Option<&T>