SCompoundWidget

A CompoundWidget is the base from which most non-primitive widgets should be built.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

FSlateControlledConstruction

TSharedFromThis

SWidget

SCompoundWidget

IAnimationSequenceBrowser

IAnimSequenceCurveEditor

IDetailsView

IDistributionCurveEditor

ILevelEditor

INavigationEventSimulationView

IObjectNameEditableTextBox

IPersonaViewport

IPinnedCommandList

IRewindDebuggerView

ISceneOutliner

SSceneOutliner

ISinglePropertyView

ISkeletonTree

ISocketManager

IStatsViewer

ITimeSlider

ITransportControl

SAboutScreen

SAdvancedPreviewDetailsTab

SAdvancedRotationInputBox

SAdvancedTransformInputBox

SAnimationCompressionSelectionDialog

SAppIconWidget

SAssetEditorViewportsOverlay

SAssetPickerButton

SAssetSearchBox

SAssetTagItem

SAssetView

SAssetViewItem

SAssetColumnItem

SAssetListItem

SAssetTileItem

SAudioInputWidget

SAudioRadialSlider

SAudioFrequencyRadialSlider

SAudioVolumeRadialSlider

SAudioSliderBase

SAudioFrequencySlider

SAudioSlider

SAudioVolumeSlider

SAudioTextBox

SBackgroundBlur

SBarVisualizer

SBlueprintDiff

SBlueprintNamespaceEntry

SBlueprintRevisionMenu

SBoneMappingBase

SBoneSelectionWidget

SBoneTreeMenu

SBorder

SButton

SHyperlink

SRichTextHyperlink

SPrimaryButton

SSimpleButton

SCarouselNavigationButton::SPeekBorder

SDockTab

SLiveLinkCurveDebugUITab

SEditableTextBox

SSearchBox

SErrorText

SExpandableButton

SGraphEditorActionMenu

SGraphEditorActionMenuAI

SGraphPin

SGraphPinAI

SGraphPinBool

SGraphPinColor

SGraphPinExec

SGraphPinNameList

SGraphPinDataTableRowName

SGraphPinNum

SGraphPinInteger

SGraphPinObject

SGraphPinClass

SGraphPinString

SGraphPinStructInstance

SGraphPinVector

SGraphPinVector2D

SGraphPinVector4

SHeaderRow

SMultiLineEditableTextBox

SNiagaraGraphActionMenu

SNotificationBackground

SScrollBar

SSeparator

STableRow

SAssetTagItemTableRow

SComboRow

SIKRigSkeletonItem

SIKRigSolverStackItem

SItemSelector::SItemSelectorItemTableRow

SMultiColumnTableRow

SAssetColumnViewRow

SBoneMappingListRow

SBonePairRow

SEventItem

SIKRetargetChainMapRow

SIKRigRetargetChainRow

SLiveLinkCurveDebugUIListItem

SOptionTableRow

SSceneOutlinerTreeRow

SSCS_RowWidget

SSCS_RowWidget_ActorRoot

SSCS_RowWidget_Separator

SSubobject_RowWidget

SMultiSelectTableRow

SWarningOrErrorBox

SBreadcrumbTrail

SBuildProgressWidget

SCarouselNavigationBar

SCarouselNavigationButton

SCheckBox

SNiagaraSourceFilterCheckBox

SCheckBoxList

SClassPickerDialog

SClassPropertyEntryBox

SClassViewer

SColorGradingPicker

SColorPicker

SColorThemeBar

SColorThemesViewer

SColorTrash

SComboPanel

SCommentBubble

SComplexGradient

SComponentClassCombo

SConcertScrollBox

SConcertSessionActivities

SConcertSessionRecovery

SContentReference

SCreateAssetFromObject

SCreateClothingSettingsPanel

SCreditsScreen

SCSVImportOptions

SCulturePicker

SCurveEditor

SCurveEditorFilterPanel

SCurveEditorPanel

SCurveEditorTreeFilterStatusBar

SCurveEditorTreePin

SCurveEditorTreeSelect

SCurveEditorTreeTextFilter

SCurveEditorView

SCurveViewerPanel

SInteractiveCurveEditorView

SCurveEditorKeyBarView

SCurveEditorViewAbsolute

SCurveEditorViewNormalized

SCurveEditorViewStacked

SCurveKeyDetailPanel

SCurvePickerWidget

SCurveSelectionWidget

SDatasmithOptionsWindow

SDefaultGraphActionWidget

SDeleteAssetsDialog

SDirectoryPicker

SDMXEntityPickerButton

SDMXPixelMappingCell

SDMXPixelMappingComponentBox

SDMXPixelMappingScreenComponentBox

SDMXPixelMappingComponentLabel

SDMXPixelMappingScreenLayout

SDMXPixelMappingSimpleScreenLayout

SDMXPortSelector

SDNAAssetImportWindow

SDocumentationToolTip

SDropTarget

SAssetDropTarget

SDynamicLayoutBox

SDynamicNumericEntry

SEditableComboBox

SEditorViewport

SAssetEditorViewport

SLevelViewport

SUVEditor2DViewport

SUVEditor3DViewport

SBasePoseViewport

SGroomEditorViewport

SRetargetPoseViewport

SEditorViewportToolBarButton

SEditorViewportToolbarMenu

SEditorViewportViewMenu

SErrorHint

SEventsTree

SExpandableArea

SExpanderArrow

SExpanderArrow

SNiagaraActionMenuExpander

SExtensionPanel

SExternalImageReference

SFilePathPicker

SFilterableObjectList

SFindInBlueprints

SFindInMaterial

SFixupSelfContextDialog

SFrameRateEntryBox

SFrameRatePicker

SFxWidget

SGameLayerManager

SGameplayTagWidget

SGenericDialogWidget

SGlobalPlayWorldActions

SGraphActionMenu

SGraphEditor

SGraphPalette

SGraphPaletteItem

SNiagaraIconWidget

SGraphPreviewer

SGridLineSpacingList

SHyperlinkLaunchURL

SIKRetargetChainMapList

SIKRigRetargetChainList

SIKRigSkeleton

SIKRigSolverStack

SIndent

SInlineEditableTextBlock

SInputKeySelector

SInvalidationPanel

SItemSelector

SKeyEditInterface

SKeySelector

SKismetDebugTreeView

SKismetInspector

SKismetLinearExpression

SLayerHandle

SLevelOfDetailBranchNode

SListViewSelectorDropdownMenu

SLiveLinkSubjectRepresentationPicker

SLoadGuard

SLogWidget

SMaterialSlotWidget

SMediaImage

SMediaPermutationsSelector

SMenuOwner

SMultiBoxWidget

SMetaDataView

SMiniCurveEditor

SModeWidget

SMotionTrailOptions

SMultiBlockBaseWidget

SToolBarButtonBlock

SToolBarComboButtonBlock

SMultipleOptionTable

SMyBlueprint

SNameComboBox

SNameListPicker

SNegativeActionButton

SNiagaraActionWidget

SNiagaraAddParameterMenu

SNiagaraFilterBox

SNiagaraGraphActionWidget

SNiagaraLibraryOnlyToggleHeader

SNiagaraParameterEditor

SNiagaraParameterMapView

SNiagaraParameterMenu

SNiagaraAddParameterFromPanelMenu

SNiagaraAddParameterFromPinMenu

SNiagaraChangePinTypeMenu

SNiagaraParameterName

SNiagaraParameterNameTextBlock

SNiagaraParameterNamePinLabel

SNiagaraParameterPanel

SNiagaraPinTypeSelector

SNiagaraScriptGraph

SNiagaraSelectedObjectsDetails

SNiagaraSourceFilterBox

SNiagaraTemplateTabBox

SNodeTitle

SNotificationItem

SNotificationList

SNumericDropDown

SNumericEntryBox

SNumericRotatorInputBox

SNumericVectorInputBox

SObjectBindingTag

SObjectBindingTags

SObjectPropertyEntryBox

SObjectWidget

SObjectTableRow

SCommonButtonTableRow

SOutputLogDialog

SOverridePropertiesWidget

SPerQualityLevelPropertiesWidget

SPackageDetails

SPinComboBox

SPinTypeSelector

SPinValueInspector

SPlatformSetupMessage

SPListEditorPanel

SPopup

SPoseAssetNameWidget

SPositiveActionButton

SProperty

SReferenceSectionSelectionWidget

SReferenceTree

SResetToDefaultMenu

SResetToDefaultPropertyEditor

SRetainerWidget

SRetargetAnimAssetsWindow

SScalabilitySettings

SScaleBox

SScrollBorder

SScrollBox

SCommonHierarchicalScrollBox

SScrubControlPanel

SScrubWidget

SSCSEditor

SSegmentedControl

SSessionBrowser

SSettingsEditorCheckoutNotice

SSimpleGradient

SSimplePreLoadScreenWidget

SSimpleTimeSlider

SSingleObjectDetailsPanel

SSkeletonBoneRemoval

SSkeletonSelectorWindow

SSkeletonWidget

SSkeletonCompareWidget

SSkeletonListWidget

SSkinWeightProfileImportOptions

SSpinBox

SSplineGeneratorPanel

SStructPropertyEntryBox

SSubMenuHandler

SSubobjectEditor

SSubobjectBlueprintEditor

SSubobjectInstanceEditor

SSuggestionTextBox

STabDrawer

STableViewBase

SListView

SAssetColumnView

SAssetListView

SCommonListView

STileView

SAssetTileView

STreeView

SCommonTreeView

SCurveEditorTree

SIKRigSkeletonTreeView

SSceneOutlinerTreeView

SSCSEditorDragDropTree

SSubobjectEditorDragDropTree

STextComboBox

STextComboPopup

STextEntryPopup

STextHighlightOverlay

STextPropertyEditableStringTableReference

STextPropertyEditableTextBox

STextScroller

SThemeColorBlock

SThrobber

STimecodeProvider

STimeline

SToolInputAssetComboPanel

SToolInputAssetPicker

SToolTip

SUndoHistoryDetails

SUsdOptionsWindow

SUserWidget

SLiveLinkCurveDebugUI

SVerticalResizeBox

SViewport

SViewportToolBar

SCommonEditorViewportToolbarBase

STransformViewportToolBar

SUVEditor2DViewportToolBar

SUVEditor3DViewportToolBar

SViewportToolBarComboMenu

SViewportToolBarIconMenu

SVolumeControl

SVPBookmarkListView

SWebBrowser

SWebBrowserView

SWidgetCarousel

SWidgetCarouselWithNavigation

SWindow

SCreateAnimationAssetDlg

SCustomDialog

SDlgPickAssetPath

SDlgPickPath

SLogWindow

SSelectExportPathDialog

SSelectFolderDlg

SVirtualWindow

SWindowTitleBar

SWizard

SWorldPartitionBuildNavigationDialog

SWorldPartitionEditor

SWorldPartitionEditorGrid

SWorldPartitionEditorGrid2D

SWorldPartitionEditorGridSpatialHash

SWorldWidgetScreenLayer

References

Module

SlateCore

Header

/Engine/Source/Runtime/SlateCore/Public/Widgets/SCompoundWidget.h

Include

#include "Widgets/SCompoundWidget.h"

Syntax

class SCompoundWidget : public SWidget

Remarks

A CompoundWidget is the base from which most non-primitive widgets should be built. CompoundWidgets have a protected member named ChildSlot.

Variables

Name Description

Protected variable

FCompoundWidget...

 

ChildSlot

The slot that contains this widget's descendants.

Constructors

Name Description

Protected function

SCompoundWidget()

Disallow public construction

Functions

Name Description

Public function Const

FLinearColor

 

GetColorAndOpacity()

Gets the widget's color.

Protected function Const

TSlateAttrib...

 

GetColorAndOpacityAttribute()

Public function Const

const FVecto...

 

GetContentScale()

Returns the size scaling factor for this widget.

Protected function Const

TSlateAttrib...

 

GetContentScaleAttribute()

Protected function Const

TSlateAttrib...

 

GetForegroundColorAttribute()

Public function

void

 

SetColorAndOpacity

(
    TAttribute< FLinearColor > InColorA...
)

Sets the widget's color.

Public function

void

 

SetContentScale

(
    TAttribute< FVector2D > InContentSc...
)

Sets the content scale for this widget.

Public function

void

 

SetForegroundColor

(
    TAttribute< FSlateColor > InForegro...
)

Sets the widget's foreground color.

Public function Static

const FSlate...

 

StaticWidgetClass()

Overridden from SWidget

Name Description

Protected function Virtual Const

FVector2D

 

ComputeDesiredSize

(
    float LayoutScaleMultiplier
)

Compute the ideal size necessary to display this widget.

Public function Virtual

FChildren &#...

 

GetChildren()

Returns the useful children (if any) of this widget.

Public function Virtual Const

FSlateColor

 

GetForegroundColor()

Public function Virtual Const

void

 

OnArrangeChildren

(
    const FGeometry& AllottedGeometry,
    FArrangedChildren& ArrangedChildre...
)

Compute the Geometry of all the children and add populate the ArrangedChildren list with their values.

Public function Virtual Const

int32

 

OnPaint

(
    const FPaintArgs& Args,
    const FGeometry& AllottedGeometry,
    const FSlateRect& MyCullingRect,
    FSlateWindowElementList& OutDrawEl...,
    int32 LayerId,
    const FWidgetStyle& InWidgetStyle,
    bool bParentEnabled
)

The widget should respond by populating the OutDrawElements array with FDrawElements that represent it and any of its children.

Public function Virtual

void

 

SetVisibility

(
    TAttribute< EVisibility > InVisibil...
)

Overridden from FSlateControlledConstruction

Name Description

Public function Virtual Const

const FSlate...

 

GetWidgetClass()

Classes

Name

Description

Protected struct

FCompoundWidgetOneChildSlot

Typedefs

Deprecated Variables

Name Description

Protected variable

TSlateDeprecate...

 

ColorAndOpacity

Direct access to ColorAndOpacity is now deprecated. Use the setter or getter.

Protected variable

TSlateDeprecate...

 

ContentScale

Direct access to ContentScale is now deprecated. Use the setter or getter.

Protected variable

TSlateDeprecate...

 

ForegroundColor

Direct access to ForegroundColor is now deprecated. Use the setter or getter.