Carousel
struct · ferroui-controls · v0.5.0
struct Carousel
An items control that displays its items as pages and can reveal adjacent
pages using viewport_fraction.
Members
TYPEto_refpage_transition_propertyis_swipe_enabled_propertyviewport_fraction_propertyis_swiping_propertyconstructnewpage_transitionset_page_transitionis_swipe_enabledset_is_swipe_enabledviewport_fractionset_viewport_fractionis_swipingnextprevious
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<Carousel>
Returns a strong reference to this object.
page_transition_property
fn page_transition_property() -> &'static StyledProperty<Option<Rc<dyn IPageTransition>>>
Defines the PageTransition property.
is_swipe_enabled_property
fn is_swipe_enabled_property() -> &'static StyledProperty<bool>
Defines the IsSwipeEnabled property.
viewport_fraction_property
fn viewport_fraction_property() -> &'static StyledProperty<f64>
Defines the ViewportFraction property.
is_swiping_property
fn is_swiping_property() -> &'static DirectProperty<Carousel, bool>
Defines the IsSwiping property.
construct
fn construct() -> Self
Creates the class data; see ferroui_base::FerroObject::construct.
new
fn new() -> Ref<Self>
page_transition
fn page_transition(self: &Self) -> Option<Rc<dyn IPageTransition>>
Gets or sets the transition to use when moving between pages.
set_page_transition
fn set_page_transition(self: &Self, value: Option<Rc<dyn IPageTransition>>)
is_swipe_enabled
fn is_swipe_enabled(self: &Self) -> bool
Gets or sets whether swipe gestures are enabled for navigating between pages. When enabled, mouse pointer events are also accepted in addition to touch and pen.
set_is_swipe_enabled
fn set_is_swipe_enabled(self: &Self, value: bool)
viewport_fraction
fn viewport_fraction(self: &Self) -> f64
Gets or sets the fraction of the viewport occupied by each page. A value of 1 shows a single full page; values below 1 reveal adjacent pages.
set_viewport_fraction
fn set_viewport_fraction(self: &Self, value: f64)
is_swiping
fn is_swiping(self: &Self) -> bool
Gets a value indicating whether a swipe gesture is currently in progress.
next
fn next(self: &Self)
Moves to the next item in the carousel.
previous
fn previous(self: &Self)
Moves to the previous item in the carousel.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeTemplatedControlImplExtSelectingItemsControlImplExtControlImplExtItemsControlImplExtBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyInputElementImplExtInteractiveImplExtLayoutableImplExtFerroObjectImplExtStyledElementImplExtClassDefaultsVisualImplExtErasedDestructorIntoEitherDerefUpcast<T>Upcast<Carousel>StaticTypeObjectTypeSubclassable<T>DefaultConstructibleStyledElementImplVisualImplInteractiveImplControlImplItemsControlImplSelectingItemsControlImplFerroObjectImplInputElementImplLayoutableImplTemplatedControlImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.