Class Carousel
Carousel Control - a circular conveyor used on which objects are displayed and rotated. The Carousel control provides a 3D interface for displaying objects.
Inherited Members
Namespace: Syncfusion.Windows.Forms.Tools
Assembly: Syncfusion.Tools.Windows.dll
Syntax
public class Carousel : BaseControl, IThemeProvider, IVisualStyle, IDisposable
Constructors
Carousel()
Constructor. Creates a new instance of Carousel.
Declaration
public Carousel()
Properties
ActiveImage
Currently active Item or Control in the view.
Declaration
public Image ActiveImage { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Image |
ActiveItem
Currently active Item or Control in the view.
Declaration
public Control ActiveItem { get; set; }
Property Value
| Type |
|---|
| System.Windows.Forms.Control |
CarouselBounds
Gets or sets the Carousel Item Bounds
Declaration
public int CarouselBounds { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
CarouselPath
Gets or sets the value to the path in which the child items in Carousel should traverse
Declaration
public CarouselPath CarouselPath { get; set; }
Property Value
| Type |
|---|
| CarouselPath |
DesignText
Gets or sets the text to display in the Design mode, when ImageSlides are enabled
Declaration
public string DesignText { get; set; }
Property Value
| Type |
|---|
| System.String |
FilePath
Address of a location where the control can fetch images to display.
Declaration
public string FilePath { get; set; }
Property Value
| Type |
|---|
| System.String |
Remarks
Last priority in loading images to control
Font
Overrides the font property
Declaration
public override Font Font { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
HighlightColor
Gets or sets the color to render the selection rectangle of images
Declaration
public Color HighlightColor { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Color |
ImageList
Imagelist which contains images to populate in the control
Declaration
public ImageList ImageList { get; set; }
Property Value
| Type |
|---|
| System.Windows.Forms.ImageList |
Remarks
Second priority in loading images to the control
ImageListCollection
Gets or sets the collection of items to display.
Declaration
public CarouselImageCollection ImageListCollection { get; set; }
Property Value
| Type |
|---|
| CarouselImageCollection |
Remarks
First priority in loading images to the control
ImageshadeColor
Gets or sets the color to shade the images in view
Declaration
public Color ImageshadeColor { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Color |
ImageSlides
Gets or sets the value to display images in the control
Declaration
public bool ImageSlides { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
Items
Gets or sets the items associated with the Carousel.
Declaration
public ItemCollection Items { get; set; }
Property Value
| Type |
|---|
| ItemCollection |
PadX
Gets or sets the value to shift the items with respect to X - axis.
Declaration
public int PadX { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
PadY
Gets or sets the value to shift the items with respect to Y - axis.
Declaration
public int PadY { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
Perspective
Gets or sets the value to render the items in specified angle
Declaration
public float Perspective { get; set; }
Property Value
| Type |
|---|
| System.Single |
RotateAlways
Gets or sets whether to rotate Carousel items continuously.
Declaration
public bool RotateAlways { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
ShowImagePreview
Gets or sets the value to preview the selected image.
Declaration
public bool ShowImagePreview { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
ShowImageShadow
Gets or sets the value to display shadow for the images
Declaration
public bool ShowImageShadow { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
Remarks
Turn off this will increase performance.
ThemeStyle
Gets or sets the SfCarouselVisualStyle value used to customize the appearance of the Carousel.
Declaration
public SfCarouselVisualStyle ThemeStyle { get; set; }
Property Value
| Type |
|---|
| SfCarouselVisualStyle |
Remarks
This ThemeStyle settings will be applied only when the VisualStyleBased theme has been applied to the control.
TouchTransitionSpeed
Gets or sets the value to rotate the child objects of the control based on Touch Gestures
Declaration
public float TouchTransitionSpeed { get; set; }
Property Value
| Type |
|---|
| System.Single |
TransitionSpeed
Gets or sets the value to rotate the child objects of the control
Declaration
public float TransitionSpeed { get; set; }
Property Value
| Type |
|---|
| System.Single |
UseCustomBounds
Gets or Sets whether custom bounds should be used
Declaration
public bool UseCustomBounds { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
UseOriginalImageinPreview
Gets or sets the value to display original image for preview, else compressed image will be used.
Declaration
public bool UseOriginalImageinPreview { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
Remarks
For high resolution images, its preview may affect performance
VisualStyle
Gets or sets the VisualStyle property.
Declaration
public CarouselVisualStyle VisualStyle { get; set; }
Property Value
| Type |
|---|
| CarouselVisualStyle |
Methods
CreateAccessibilityInstance()
Creates the accessibilty for the control.
Declaration
protected override AccessibleObject CreateAccessibilityInstance()
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.AccessibleObject | Accessibility |
Dispose(Boolean)
Releases the unmanaged resources used by the System.Windows.Forms.Control and its child controls and optionally releases the managed resources.
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | disposing | true to release both managed and unmanaged resources; false to release only unmanaged resources. |
GetControlName(String)
Helps to apply the ControlName settings in control
Declaration
public override string GetControlName(string controlName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | controlName |
Returns
| Type |
|---|
| System.String |
Overrides
OnCanApplyThemeChanged(Boolean)
Helps to apply the CanApplyTheme settings in control
Declaration
public override void OnCanApplyThemeChanged(bool canApplyTheme)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | canApplyTheme |
Overrides
OnCanOverrideStyleChanged(Boolean)
Helps to apply the CanOverriderStyle settings in control
Declaration
public override void OnCanOverrideStyleChanged(bool canOverriderStyle)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | canOverriderStyle |
Overrides
OnControlAdded(ControlEventArgs)
Raises the System.Windows.Forms.Control.ControlAdded event.
Declaration
protected override void OnControlAdded(ControlEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.ControlEventArgs | e | ControlEventArgs which contains EventData |
OnControlRemoved(ControlEventArgs)
Raises the System.Windows.Forms.Control.ControlRemoved event.
Declaration
protected override void OnControlRemoved(ControlEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.ControlEventArgs | e | ControlEventArgs which contains EventData |
OnHandleCreated(EventArgs)
Raises the System.Windows.Forms.Control.HandleCreated event.
Declaration
protected override void OnHandleCreated(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | EventArgs which contains EventData |
OnHandleDestroyed(EventArgs)
Raises the System.Windows.Forms.Control.HandleDestroyed event.
Declaration
protected override void OnHandleDestroyed(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e | EventArgs which contains EventData |
OnLayout(LayoutEventArgs)
Raises the System.Windows.Forms.Control.Layout event.
Declaration
protected override void OnLayout(LayoutEventArgs levent)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.LayoutEventArgs | levent | LayoutEventArgs which contains EventData |
OnMouseDown(MouseEventArgs)
Raises the System.Windows.Forms.Control.MouseDown event.
Declaration
protected override void OnMouseDown(MouseEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.MouseEventArgs | e | MouseEventArgs which contains EventData |
OnPaint(PaintEventArgs)
Raises the System.Windows.Forms.Control.Paint event.
Declaration
protected override void OnPaint(PaintEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.PaintEventArgs | e | PaintEventArgs which contains EventData |
OnThemeNameChanged(String)
Helps to apply the ThemeName settings in control
Declaration
public override void OnThemeNameChanged(string themeName)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | themeName | ThemeName |
Overrides
WndProc(ref Message)
Processes Windows messages.
Declaration
protected override void WndProc(ref Message m)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.Message | m | Windows Message |
Events
OnCarouselItemFocused
Occurs when a selected item arrives to the center of the Carousel view
Declaration
public virtual event OnCarouselItemFocusedEventHandler OnCarouselItemFocused
Event Type
| Type |
|---|
| OnCarouselItemFocusedEventHandler |
OnCarouselItemSelectionChanged
Occurs when an item in the Carousel view is selected
Declaration
public virtual event OnCarouselItemSelectionChangedEventHandler OnCarouselItemSelectionChanged
Event Type
| Type |
|---|
| OnCarouselItemSelectionChangedEventHandler |
OnCarouselItemSelectionChanging
Occurs when an item in the Carousel view is being selected
Declaration
public virtual event OnCarouselItemSelectionChangingEventHandler OnCarouselItemSelectionChanging
Event Type
| Type |
|---|
| OnCarouselItemSelectionChangingEventHandler |