Navigation
API > API/Runtime > API/Runtime/WidgetCarousel
Inheritance Hierarchy
- FSlateControlledConstruction
- TSharedFromThis
- SWidget
- SCompoundWidget
- SWidgetCarousel
References
| Module | WidgetCarousel |
| Header | /Engine/Source/Runtime/WidgetCarousel/Public/SWidgetCarousel.h |
| Include | #include "SWidgetCarousel.h" |
Syntax
template<typename ItemType>
class SWidgetCarousel : public SCompoundWidget
Remarks
Implements a widget Carousel.
A widget Carousel displays widgets that can be scrolled in and out.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TSharedPtr< FCarouselDisplayItem > | CenterCarouselWidget | ||
| float | FadeRate | The fade rate. | |
| const TArray< ItemType > * | ItemsSource | Pointer to the array of data items that we are observing. | |
| TSharedPtr< FCarouselDisplayItem > | LeftCarouselWidget | Holds the CarouselWidgets. | |
| float | MoveSpeed | Holds the move speed. | |
| FOnGenerateWidget | OnGenerateWidget | Hold the delegate to be invoked when a widget changes. | |
| FOnCarouselPageChanged | OnPageChanged | Hold the delegate to be invoked when the current page changes. | |
| float | PeakValueLeftLimit | Holds The peak left limit. | |
| float | PeakValueRightLimit | The peak right limit. | |
| TSharedPtr< FCarouselDisplayItem > | RightCarouselWidget | ||
| float | SlideValueLeftLimit | Holds The left limit. | |
| float | SlideValueRightLimit | The right limit. | |
| TSharedPtr< SHorizontalBox > | WidgetDisplayBox | Holds the widget display box. | |
| int32 | WidgetIndex | Holds the visible widget index. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Construct
(
const FArguments& InArgs |
Constructs the widget. | |
| void | |||
| void | Regenerate the widgets to display them. | ||
| int32 | GetLeftWidgetIndex
(
int32 Index |
||
| float | |||
| int32 | GetRightWidgetIndex
(
int32 Index |
||
| int32 | Get the current widget index. | ||
| bool | |||
| void | Peak
(
EWidgetCarouselScrollDirection::Type Direction |
||
| EActiveTimerReturnType | RegisteredTick
(
double InCurrentTime, |
||
| void | SetActiveWidgetIndex
(
int32 Index |
Sets the active widget to display at the specified index. | |
| void | SetItemSource
(
const TArray< ItemType >* InWidgetItemsSource |
Set the item source, and scroll to the first item. | |
| void | Scroll right. | ||
| void | Scroll left. | ||
| void | |||
| void | SwapBuffer
(
EWidgetCarouselScrollDirection::Type ScrollDirection, |
Swap the buffer index. |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FArguments |
Typedefs
| Name | Description |
|---|---|
| FOnCarouselPageChanged | |
| FOnGenerateWidget |