Class SfCarousel
The Carousel control allows the user to navigate between their items with rich animated UI
Implements
Inherited Members
Namespace: Syncfusion.UI.Xaml.Controls.Layout
Assembly: Syncfusion.SfCarousel.UWP.dll
Syntax
public class SfCarousel : Selector, IDisposable
Remarks
Carousel is a Selector in navigator layout that renders list of items in rich UI, based the properties set with the control animate items on navigate. The item has rich customization support and animation will reflected based on the user values.
Constructors
SfCarousel()
Initializes a new instance of the SfCarousel class.
Declaration
public SfCarousel()
See Also
Fields
AllowLoadMoreProperty
Using a DependencyProperty as the backing store for AllowLoadMore. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty AllowLoadMoreProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
DurationProperty
Using a DependencyProperty as the backing store for Duration. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty DurationProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
EasingFunctionProperty
Using a DependencyProperty as the backing store for EasingFunction. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty EasingFunctionProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
EnableVirtualizationProperty
Using a DependencyProperty as the backing store for EnableVirtualization. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty EnableVirtualizationProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ItemHeightProperty
Using a DependencyProperty as the backing store for ItemHeight. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ItemHeightProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ItemSpaceProperty
Using a DependencyProperty as the backing store for VisualMode. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ItemSpaceProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ItemsSourceProperty
Using a DependencyProperty as the backing store for ItemsSource. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ItemsSourceProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ItemWidthProperty
Using a DependencyProperty as the backing store for ItemWidth. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ItemWidthProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
LoadMoreItemsCountProperty
Using a DependencyProperty as the backing store for LoadMoreItemsCount. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty LoadMoreItemsCountProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
LoadMoreViewProperty
Using a DependencyProperty as the backing store for LoadMoreView. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty LoadMoreViewProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
OffsetProperty
Using a DependencyProperty as the backing store for Offset. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty OffsetProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
OrientationProperty
Using a DependencyProperty as the backing store for Orientation. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty OrientationProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
RotationAngleProperty
Using a DependencyProperty as the backing store for RotationAngle. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty RotationAngleProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ScaleOffsetProperty
Using a DependencyProperty as the backing store for ScaleOffset. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ScaleOffsetProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
SelectedItemOffsetProperty
Using a DependencyProperty as the backing store for SelectedItemOffset. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectedItemOffsetProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
SelectedItemTemplateProperty
Using a DependencyProperty as the backing store for SelectedTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectedItemTemplateProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
VisualModeProperty
Using a DependencyProperty as the backing store for VisualMode. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty VisualModeProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
ZOffsetProperty
Using a DependencyProperty as the backing store for ZOffset. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ZOffsetProperty
Field Value
Type |
---|
Windows.UI.Xaml.DependencyProperty |
Properties
AllowLoadMore
Gets or sets a value indicating whether enable or disable allow load more
Declaration
public bool AllowLoadMore { get; set; }
Property Value
Type |
---|
System.Boolean |
Duration
Gets or sets the length of time for which this timeline plays, not counting repetitions.
Declaration
public TimeSpan Duration { get; set; }
Property Value
Type | Description |
---|---|
System.TimeSpan | The default value is System.TimeSpan. |
Remarks
Specify the time taken for move an item.
EasingFunction
Gets or sets the easing function applied to this animation with SfCarousel.
Declaration
public EasingFunctionBase EasingFunction { get; set; }
Property Value
Type | Description |
---|---|
Windows.UI.Xaml.Media.Animation.EasingFunctionBase | The default value is Windows.UI.Xaml.Media.Animation.EasingFunctionBase. |
Remarks
Customize the animation effect.
EnableVirtualization
Gets or sets a value indicating whether enable or disable Is Virtualization
Declaration
public bool EnableVirtualization { get; set; }
Property Value
Type |
---|
System.Boolean |
ItemHeight
Gets or sets the value of ItemHeight
Declaration
public double ItemHeight { get; set; }
Property Value
Type |
---|
System.Double |
ItemSpace
Gets or sets the ItemSpace
Declaration
public int ItemSpace { get; set; }
Property Value
Type |
---|
System.Int32 |
ItemsSource
Gets or sets the items source.
Declaration
public object ItemsSource { get; set; }
Property Value
Type |
---|
System.Object |
ItemWidth
Gets or sets the ItemWidth.
Declaration
public double ItemWidth { get; set; }
Property Value
Type |
---|
System.Double |
LoadMoreItemsCount
Gets or sets the maximum items count.
Declaration
public int LoadMoreItemsCount { get; set; }
Property Value
Type |
---|
System.Int32 |
LoadMoreView
Gets or sets the load more view.
Declaration
public object LoadMoreView { get; set; }
Property Value
Type |
---|
System.Object |
Offset
Gets or sets the space between items.
Declaration
public double Offset { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 60. |
See Also
Orientation
Gets or sets the Orientation
Declaration
public Orientation Orientation { get; set; }
Property Value
Type |
---|
Windows.UI.Xaml.Controls.Orientation |
RotationAngle
Gets or sets the rotation angle for SfCarouselItem.
Declaration
public double RotationAngle { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 45. |
Remarks
Rotation angel of the items.
ScaleOffset
Gets or sets the scale offset with SfCarousel.
Declaration
public double ScaleOffset { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 0.7. |
See Also
SelectedItemOffset
Gets or sets the distance between the current item and other.
Declaration
public double SelectedItemOffset { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 120. |
See Also
SelectedItemTemplate
Gets or sets the template for the selected item
Declaration
public DataTemplate SelectedItemTemplate { get; set; }
Property Value
Type |
---|
Windows.UI.Xaml.DataTemplate |
VisualMode
Gets or sets the VisualMode.
Declaration
public VisualMode VisualMode { get; set; }
Property Value
Type | Description |
---|---|
VisualMode | By default set to Default. |
ZOffset
Gets or sets the zooming offset.
Declaration
public double ZOffset { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is zero. The ZOffset should be set in between 0 and 1. |
See Also
Methods
add_ItemLoaded(ItemLoadedHandler)
Declaration
public void add_ItemLoaded(ItemLoadedHandler value)
Parameters
Type | Name | Description |
---|---|---|
ItemLoadedHandler | value |
add_ItemsCollectionChanged(ItemsCollectionChangedHandler)
Declaration
public void add_ItemsCollectionChanged(ItemsCollectionChangedHandler value)
Parameters
Type | Name | Description |
---|---|---|
ItemsCollectionChangedHandler | value |
ArrangeOverride(Size)
Sets the size for the arranging items
Declaration
protected override Size ArrangeOverride(Size finalSize)
Parameters
Type | Name | Description |
---|---|---|
Windows.Foundation.Size | finalSize | the finalSize |
Returns
Type | Description |
---|---|
Windows.Foundation.Size | The size |
Dispose()
To dispose unused objects
Declaration
public void Dispose()
Dispose(Boolean)
To remove all the instance which is used in Carousel
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | The disposing |
GetContainerForItemOverride()
Gets a SfCarouselItem for override.
Declaration
protected override DependencyObject GetContainerForItemOverride()
Returns
Type | Description |
---|---|
Windows.UI.Xaml.DependencyObject |
IsItemItsOwnContainerOverride(Object)
Checks whether the item is a SfCarouselItem
Declaration
protected override bool IsItemItsOwnContainerOverride(object item)
Parameters
Type | Name | Description |
---|---|---|
System.Object | item | object as item |
Returns
Type | Description |
---|---|
System.Boolean |
|
LoadMore()
Load more method.
Declaration
public void LoadMore()
MeasureOverride(Size)
Carousel Measure Override Method.
Declaration
protected override Size MeasureOverride(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Windows.Foundation.Size | availableSize | The available Size |
Returns
Type | Description |
---|---|
Windows.Foundation.Size | Available size has returned. |
MoveNext()
Moves the selection next SfCarouselItem.
Declaration
public void MoveNext()
Remarks
The MoveNext method moves the current item position, one position forward. Return value is void.
See Also
MovePrevious()
Moves the selection to previous SfCarouselItem.
Declaration
public void MovePrevious()
Remarks
The MovePrevious method moves the current item position, one position backward. Return value is void.
See Also
OnApplyTemplate()
Gets or sets the Framework elements on applying the templates.
Declaration
protected override void OnApplyTemplate()
Overrides
OnKeyDown(KeyRoutedEventArgs)
Sets the selected item as the next or previous carousal item SfCarouselItem based on the keys pressed.
Declaration
protected override void OnKeyDown(KeyRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.KeyRoutedEventArgs | e | KeyRoutedEventArgs as e |
OnManipulationCompleted(ManipulationCompletedRoutedEventArgs)
Sets the selected item as SfCarouselItem
Declaration
protected override void OnManipulationCompleted(ManipulationCompletedRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.ManipulationCompletedRoutedEventArgs | e | ManipulationCompletedRoutedEventArgs as e |
OnManipulationDelta(ManipulationDeltaRoutedEventArgs)
Sets the selected index
Declaration
protected override void OnManipulationDelta(ManipulationDeltaRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.ManipulationDeltaRoutedEventArgs | e | ManipulationDeltaRoutedEventArgs as e |
OnManipulationInertiaStarting(ManipulationInertiaStartingRoutedEventArgs)
Sets the translation information associated with the event.
Declaration
protected override void OnManipulationInertiaStarting(ManipulationInertiaStartingRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.ManipulationInertiaStartingRoutedEventArgs | e | ManipulationInertiaStartingRoutedEventArgs as e |
OnManipulationStarted(ManipulationStartedRoutedEventArgs)
manipulation started method.
Declaration
protected override void OnManipulationStarted(ManipulationStartedRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.ManipulationStartedRoutedEventArgs | e | ManipulationStartedRoutedEventArgs as e |
OnPointerEntered(PointerRoutedEventArgs)
method for pointer entered
Declaration
protected override void OnPointerEntered(PointerRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.PointerRoutedEventArgs | e | PointerRoutedEventArgs as e |
OnPointerWheelChanged(PointerRoutedEventArgs)
Sets the selected item as the next or previous carousal item SfCarouselItem based on the mouse movement
Declaration
protected override void OnPointerWheelChanged(PointerRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.PointerRoutedEventArgs | e | PointerRoutedEventArgs as e |
OnSelectionChanged(DependencyPropertyChangedEventArgs)
Sets the selected item when the selection has been changed by the user
Declaration
protected override void OnSelectionChanged(DependencyPropertyChangedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.DependencyPropertyChangedEventArgs | args | DependencyPropertyChangedEventArgs as args |
Overrides
See Also
PrepareContainerForItemOverride(DependencyObject, Object)
Sets the properties for the SfCarouselItem item.
Declaration
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.DependencyObject | element | DependencyObject as element |
System.Object | item | object as item |
Refresh()
Refresh the layout and rearrange the children with SfCarousel.
Declaration
public void Refresh()
Remarks
Return value is void.
remove_ItemLoaded(ItemLoadedHandler)
Declaration
public void remove_ItemLoaded(ItemLoadedHandler value)
Parameters
Type | Name | Description |
---|---|---|
ItemLoadedHandler | value |
remove_ItemsCollectionChanged(ItemsCollectionChangedHandler)
Declaration
public void remove_ItemsCollectionChanged(ItemsCollectionChangedHandler value)
Parameters
Type | Name | Description |
---|---|---|
ItemsCollectionChangedHandler | value |
Events
ItemLoaded
Initializes a new instance of the ItemLoadedHandler
Declaration
public event ItemLoadedHandler ItemLoaded
Event Type
Type |
---|
ItemLoadedHandler |
ItemsCollectionChanged
Initializes a new instance of the ItemsCollectionChangedHandler
Declaration
public event ItemsCollectionChangedHandler ItemsCollectionChanged
Event Type
Type |
---|
ItemsCollectionChangedHandler |