UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FSlateApplicationBase Class Referenceabstract

#include <SlateApplicationBase.h>

+ Inheritance diagram for FSlateApplicationBase:

Public Member Functions

SLATECORE_API FSlateApplicationBase ()
 
virtual ~FSlateApplicationBase ()
 
virtual bool IsActive () const =0
 
FSlateRendererGetRenderer () const
 
virtual TSharedRef< SWindowAddWindow (TSharedRef< SWindow > InSlateWindow, const bool bShowImmediately=true)=0
 
virtual void ArrangeWindowToFrontVirtual (TArray< TSharedRef< SWindow > > &Windows, const TSharedRef< SWindow > &WindowToBringToFront)=0
 
virtual bool FindPathToWidget (TSharedRef< const SWidget > InWidget, FWidgetPath &OutWidgetPath, EVisibility VisibilityFilter=EVisibility::Visible)=0
 
virtual TSharedPtr< SWindowFindWidgetWindow (TSharedRef< const SWidget > InWidget) const =0
 
virtual TSharedPtr< SWindowGetActiveTopLevelWindow () const =0
 
virtual TSharedPtr< SWindowGetActiveTopLevelRegularWindow () const =0
 
virtual const TArray< TSharedRef< SWindow > > GetTopLevelWindows () const =0
 
virtual const FSlateBrushGetAppIcon () const =0
 
virtual const FSlateBrushGetAppIconSmall () const =0
 
virtual float GetApplicationScale () const =0
 
virtual const double GetCurrentTime () const =0
 
virtual UE::Slate::FDeprecateVector2DResult GetCursorPos () const =0
 
virtual UE::Slate::FDeprecateVector2DResult GetLastCursorPos () const =0
 
virtual UE::Slate::FDeprecateVector2DResult GetCursorSize () const =0
 
virtual bool GetSoftwareCursorAvailable () const =0
 
virtual EVisibility GetSoftwareCursorVis () const =0
 
SLATECORE_API void GetDisplayMetrics (FDisplayMetrics &OutDisplayMetrics)
 
SLATECORE_API void GetCachedDisplayMetrics (FDisplayMetrics &OutDisplayMetrics) const
 
SLATECORE_API void GetSafeZoneSize (FMargin &SafeZone, const UE::Slate::FDeprecateVector2DParameter &OverrideSize)
 
virtual EWindowTransparency GetWindowTransparencySupport () const =0
 
virtual TSharedPtr< SWidgetGetKeyboardFocusedWidget () const =0
 
virtual EUINavigation GetNavigationDirectionFromKey (const FKeyEvent &InKeyEvent) const =0
 
virtual EUINavigation GetNavigationDirectionFromAnalog (const FAnalogInputEvent &InAnalogEvent)=0
 
virtual EUINavigationAction GetNavigationActionFromKey (const FKeyEvent &InKeyEvent) const =0
 
virtual EUINavigationAction GetNavigationActionForKey (const FKey &InKey) const =0
 
virtual bool AnyMenusVisible () const =0
 
virtual bool HasAnyMouseCaptor () const =0
 
virtual bool HasUserMouseCapture (int32 UserIndex) const =0
 
virtual const TSharedPtr< GenericApplicationGetPlatformApplication () const
 
virtual FSlateRect GetPreferredWorkArea () const =0
 
virtual bool HasUserFocusedDescendants (const TSharedRef< const SWidget > &Widget, int32 UserIndex) const =0
 
virtual bool HasFocusedDescendants (const TSharedRef< const SWidget > &Widget) const =0
 
virtual bool IsExternalUIOpened ()=0
 
SLATECORE_API const FHitTestingGetHitTesting () const
 
virtual FWidgetPath LocateWindowUnderMouse (UE::Slate::FDeprecateVector2DParameter ScreenspaceMouseCoordinate, const TArray< TSharedRef< SWindow > > &Windows, bool bIgnoreEnabledStatus=false, int32 UserIndex=INDEX_NONE)=0
 
virtual UE::Slate::FDeprecateVector2DResult CalculateTooltipWindowPosition (const FSlateRect &InAnchorRect, const UE::Slate::FDeprecateVector2DParameter &InSize, bool bAutoAdjustForDPIScale, EPopupCursorOverlapMode CursorOverlapMode=EPopupCursorOverlapMode::PreventOverlap) const =0
 
virtual bool IsWindowHousingInteractiveTooltip (const TSharedRef< const SWindow > &WindowToTest) const =0
 
virtual TSharedRef< SImageMakeImage (const TAttribute< const FSlateBrush * > &Image, const TAttribute< FSlateColor > &Color, const TAttribute< EVisibility > &Visibility) const =0
 
virtual TSharedRef< IToolTipMakeToolTip (const TAttribute< FText > &ToolTipText)=0
 
virtual TSharedRef< IToolTipMakeToolTip (const FText &ToolTipText)=0
 
virtual TSharedRef< SWidgetMakeWindowTitleBar (const FWindowTitleBarArgs &InArgs, TSharedPtr< IWindowTitleBar > &OutTitleBar) const =0
 
virtual void RequestDestroyWindow (TSharedRef< SWindow > WindowToDestroy)=0
 
virtual bool SetKeyboardFocus (const FWidgetPath &InFocusPath, const EFocusCause InCause)=0
 
virtual bool SetUserFocus (const uint32 InUserIndex, const FWidgetPath &InFocusPath, const EFocusCause InCause)=0
 
virtual bool SetUserFocusAllowingDescendantFocus (const uint32 InUserIndex, const FWidgetPath &InFocusPath, const EFocusCause InCause)=0
 
virtual void SetAllUserFocus (const FWidgetPath &InFocusPath, const EFocusCause InCause)=0
 
virtual void SetAllUserFocusAllowingDescendantFocus (const FWidgetPath &InFocusPath, const EFocusCause InCause)=0
 
virtual TSharedPtr< SWidgetGetUserFocusedWidget (uint32 UserIndex) const =0
 
virtual TSharedPtr< SWidgetGetCurrentDebugContextWidget () const =0
 
 DECLARE_EVENT_OneParam (FSlateApplicationBase, FOnInvalidateAllWidgets, bool)
 
FOnInvalidateAllWidgetsOnInvalidateAllWidgets ()
 
 DECLARE_EVENT_OneParam (FSlateApplicationBase, FOnGlobalInvalidationToggled, bool)
 
FOnGlobalInvalidationToggledOnGlobalInvalidationToggled ()
 
SLATECORE_API void ToggleGlobalInvalidation (bool bIsGlobalInvalidationEnabled)
 
SLATECORE_API void InvalidateAllWidgets (bool bClearResourcesImmediately) const
 
SLATECORE_API bool IsSlateAsleep ()
 
TSharedPtr< ICursorGetPlatformCursor ()
 
TSharedPtr< class GenericApplicationGetPlatformApplication ()
 
SLATECORE_API void ResetCustomSafeZone ()
 
SLATECORE_API bool IsCustomSafeZoneSet () const
 
SLATECORE_API void SetCustomSafeZone (const FMargin &InSafeZone)
 
const FMarginGetCustomSafeZone () const
 

Static Public Member Functions

static FSlateApplicationBaseGet ()
 
static bool IsInitialized ()
 

Static Public Attributes

SLATECORE_API static const uint32 CursorPointerIndex = ETouchIndex::CursorPointerIndex
 
SLATECORE_API static const uint32 CursorUserIndex = 0
 
SLATECORE_API static const FPlatformUserId SlateAppPrimaryPlatformUser = FPlatformUserId::CreateFromInternalId(0)
 

Protected Types

enum class  ECustomSafeZoneState : uint8 { Unset , Set , Debug }
 

Protected Member Functions

virtual TSharedPtr< SWidgetGetMouseCaptorImpl () const =0
 
SLATECORE_API void GetSafeZoneRatio (FMargin &SafeZoneRatio)
 
SLATECORE_API void UpdateAnyActiveTimersArePending ()
 
virtual bool DoesWidgetHaveMouseCapture (const TSharedPtr< const SWidget > Widget) const =0
 
virtual bool DoesWidgetHaveMouseCaptureByUser (const TSharedPtr< const SWidget > Widget, int32 UserIndex, TOptional< int32 > PointerIndex) const =0
 
virtual TOptional< EFocusCauseHasUserFocus (const TSharedPtr< const SWidget > Widget, int32 UserIndex) const =0
 
virtual TOptional< EFocusCauseHasAnyUserFocus (const TSharedPtr< const SWidget > Widget) const =0
 
virtual bool IsWidgetDirectlyHovered (const TSharedPtr< const SWidget > Widget) const =0
 
virtual bool ShowUserFocus (const TSharedPtr< const SWidget > Widget) const =0
 
virtual FWidgetPath LocateWidgetInWindow (UE::Slate::FDeprecateVector2DParameter ScreenspaceMouseCoordinate, const TSharedRef< SWindow > &Window, bool bIgnoreEnabledStatus, int32 UserIndex) const =0
 
SLATECORE_API void UpdateCustomSafeZone (const FMargin &NewSafeZoneRatio, bool bShouldRecacheMetrics)
 

Protected Attributes

TSharedPtr< FSlateRendererRenderer
 
FHitTesting HitTesting
 
FDisplayMetrics CachedDisplayMetrics
 
float CachedDebugTitleSafeRatio
 
FOnInvalidateAllWidgets OnInvalidateAllWidgetsEvent
 
FOnGlobalInvalidationToggled OnGlobalInvalidationToggledEvent
 
FCriticalSection ActiveTimerCS
 
bool bIsSlateAsleep
 
ECustomSafeZoneState CustomSafeZoneState
 
FMargin CustomSafeZoneRatio
 
bool bAnyActiveTimersPending = false
 

Static Protected Attributes

static SLATECORE_API TSharedPtr< FSlateApplicationBaseCurrentBaseApplication = nullptr
 
static SLATECORE_API TSharedPtr< class GenericApplicationPlatformApplication = nullptr
 

Friends

class SWidget
 
class FHitTesting
 

Detailed Description

Base class for Slate applications.

This class currently serves a temporary workaround for solving SlateCore dependencies to FSlateApplication. It should probably be removed once FSlateApplication has been refactored into SlateCore.

Member Enumeration Documentation

◆ ECustomSafeZoneState

Enumerator
Unset 
Set 
Debug 

Constructor & Destructor Documentation

◆ FSlateApplicationBase()

FSlateApplicationBase::FSlateApplicationBase ( )

◆ ~FSlateApplicationBase()

virtual FSlateApplicationBase::~FSlateApplicationBase ( )
inlinevirtual

Member Function Documentation

◆ AddWindow()

virtual TSharedRef< SWindow > FSlateApplicationBase::AddWindow ( TSharedRef< SWindow InSlateWindow,
const bool  bShowImmediately = true 
)
pure virtual

Associates a top level Slate Window with a native window and ensures that it is tracked properly by the application. Calling this method will cause the window to be displayed (unless specified otherwise), so be sure to associate content with the window object you're passing in first!

Parameters
InSlateWindowA SlateWindow to which to add a native window.
bShowImmediatelytrue to show the window, false if you're going to call ShowWindow() yourself later.
Returns
a reference to the SWindow that was just added.

Implemented in FSlateApplication.

◆ AnyMenusVisible()

virtual bool FSlateApplicationBase::AnyMenusVisible ( ) const
pure virtual
Returns
Returns true if there are any pop-up menus summoned

Implemented in FSlateApplication.

◆ ArrangeWindowToFrontVirtual()

virtual void FSlateApplicationBase::ArrangeWindowToFrontVirtual ( TArray< TSharedRef< SWindow > > &  Windows,
const TSharedRef< SWindow > &  WindowToBringToFront 
)
pure virtual

Reorders an array of windows so the specified window is "brought to the front"

Implemented in FSlateApplication.

◆ CalculateTooltipWindowPosition()

virtual UE::Slate::FDeprecateVector2DResult FSlateApplicationBase::CalculateTooltipWindowPosition ( const FSlateRect InAnchorRect,
const UE::Slate::FDeprecateVector2DParameter InSize,
bool  bAutoAdjustForDPIScale,
EPopupCursorOverlapMode  CursorOverlapMode = EPopupCursorOverlapMode::PreventOverlap 
) const
pure virtual

Calculates the tooltip window position.

Parameters
InAnchorRectThe current(suggested) window position and size of an area which may not be covered by the popup.
InSizeThe size of the tooltip window.
bAutoAdjustForDPIScaleWhether the method should attempt to correct for the DPI scale of the monitor.
CursorOverlapModeWhether the tooltip window should be permitted to open under the position of the cursor.
Returns
The suggested position.

Implemented in FSlateApplication.

◆ DECLARE_EVENT_OneParam() [1/2]

FSlateApplicationBase::DECLARE_EVENT_OneParam ( FSlateApplicationBase  ,
FOnGlobalInvalidationToggled  ,
bool   
)

◆ DECLARE_EVENT_OneParam() [2/2]

FSlateApplicationBase::DECLARE_EVENT_OneParam ( FSlateApplicationBase  ,
FOnInvalidateAllWidgets  ,
bool   
)

Gets a delegate that is invoked when a global invalidate of all widgets should occur

◆ DoesWidgetHaveMouseCapture()

virtual bool FSlateApplicationBase::DoesWidgetHaveMouseCapture ( const TSharedPtr< const SWidget Widget) const
protectedpure virtual

Gets whether or not a particular widget has mouse capture.

Returns
True if the widget has mouse capture, otherwise false.

Implemented in FSlateApplication.

◆ DoesWidgetHaveMouseCaptureByUser()

virtual bool FSlateApplicationBase::DoesWidgetHaveMouseCaptureByUser ( const TSharedPtr< const SWidget Widget,
int32  UserIndex,
TOptional< int32 PointerIndex 
) const
protectedpure virtual

Gets whether or not a particular widget has mouse capture by a user.

Returns
True if the widget has mouse capture, otherwise false.

Implemented in FSlateApplication.

◆ FindPathToWidget()

virtual bool FSlateApplicationBase::FindPathToWidget ( TSharedRef< const SWidget InWidget,
FWidgetPath OutWidgetPath,
EVisibility  VisibilityFilter = EVisibility::Visible 
)
pure virtual

Searches for the specified widget and generates a full path to it.

Note: this is a relatively slow operation!

Parameters
InWidgetWidget to generate a path to
OutWidgetPathThe generated widget path
VisibilityFilterWidgets must have this type of visibility to be included the path
Returns
True if the widget path was found

Implemented in FSlateApplication.

◆ FindWidgetWindow()

virtual TSharedPtr< SWindow > FSlateApplicationBase::FindWidgetWindow ( TSharedRef< const SWidget InWidget) const
pure virtual

Returns the window the provided widget is contained in

Parameters
InWidgetWidget to find the window for
Returns
returns the window the provided widget is contained in or nullptr if it's not currently in a window

Implemented in FSlateApplication.

◆ Get()

static FSlateApplicationBase & FSlateApplicationBase::Get ( )
inlinestatic

Returns the current instance of the application. The application should have been initialized before this method is called

Returns
Reference to the application

◆ GetActiveTopLevelRegularWindow()

virtual TSharedPtr< SWindow > FSlateApplicationBase::GetActiveTopLevelRegularWindow ( ) const
pure virtual

Gets the active regular top-level window. A regular window is a non-menu, non-tooltip, non-cursor decorator window

Returns
The top level window, or nullptr if no Slate windows are currently active.

Implemented in FSlateApplication.

◆ GetActiveTopLevelWindow()

virtual TSharedPtr< SWindow > FSlateApplicationBase::GetActiveTopLevelWindow ( ) const
pure virtual

Gets the active top-level window.

Returns
The top level window, or nullptr if no Slate windows are currently active.

Implemented in FSlateApplication.

◆ GetAppIcon()

virtual const FSlateBrush * FSlateApplicationBase::GetAppIcon ( ) const
pure virtual

Gets the global application icon.

Returns
The icon.

Implemented in FSlateApplication.

◆ GetAppIconSmall()

virtual const FSlateBrush * FSlateApplicationBase::GetAppIconSmall ( ) const
pure virtual

Implemented in FSlateApplication.

◆ GetApplicationScale()

virtual float FSlateApplicationBase::GetApplicationScale ( ) const
pure virtual

Gets the ratio SlateUnit / ScreenPixel.

Returns
Application scale.

Implemented in FSlateApplication.

◆ GetCachedDisplayMetrics()

void FSlateApplicationBase::GetCachedDisplayMetrics ( FDisplayMetrics OutDisplayMetrics) const

Gets the application's cached display metrics.

Parameters
OutDisplayMetricsWill contain the display metrics.

◆ GetCurrentDebugContextWidget()

virtual TSharedPtr< SWidget > FSlateApplicationBase::GetCurrentDebugContextWidget ( ) const
pure virtual
Returns
the Widget that started a tick, paint, prepass or an event.

Implemented in FSlateApplication.

◆ GetCurrentTime()

virtual const double FSlateApplicationBase::GetCurrentTime ( ) const
pure virtual

Gets Slate's current cached real time.

This time value is updated every frame right before we tick widgets and is the recommended time value to use for UI animations and transitions, as opposed to calling FPlatformTime::Seconds() (which is generally slower)

Returns
The current Slate real time in seconds

Implemented in FSlateApplication.

◆ GetCursorPos()

virtual UE::Slate::FDeprecateVector2DResult FSlateApplicationBase::GetCursorPos ( ) const
pure virtual

Gets the current position of the cursor.

Returns
Cursor position.

Implemented in FSlateApplication.

◆ GetCursorSize()

virtual UE::Slate::FDeprecateVector2DResult FSlateApplicationBase::GetCursorSize ( ) const
pure virtual

Gets the size of the cursor..

Returns
Cursor size.

Implemented in FSlateApplication.

◆ GetCustomSafeZone()

const FMargin & FSlateApplicationBase::GetCustomSafeZone ( ) const
inline

◆ GetDisplayMetrics()

void FSlateApplicationBase::GetDisplayMetrics ( FDisplayMetrics OutDisplayMetrics)

Gets the application's display metrics.

Parameters
OutDisplayMetricsWill contain the display metrics.

◆ GetHitTesting()

const FHitTesting & FSlateApplicationBase::GetHitTesting ( ) const

◆ GetKeyboardFocusedWidget()

virtual TSharedPtr< SWidget > FSlateApplicationBase::GetKeyboardFocusedWidget ( ) const
pure virtual

Gets the widget that currently has keyboard focus, if any.

Returns
The focused widget, or nullptr if no widget has focus.

Implemented in FSlateApplication.

◆ GetLastCursorPos()

virtual UE::Slate::FDeprecateVector2DResult FSlateApplicationBase::GetLastCursorPos ( ) const
pure virtual

Gets the last known position of the cursor.

Returns
Cursor position.

Implemented in FSlateApplication.

◆ GetMouseCaptorImpl()

virtual TSharedPtr< SWidget > FSlateApplicationBase::GetMouseCaptorImpl ( ) const
protectedpure virtual

Implementation of GetMouseCaptor which can be overridden without warnings.

Returns
Widget with the mouse capture

Implemented in FSlateApplication.

◆ GetNavigationActionForKey()

virtual EUINavigationAction FSlateApplicationBase::GetNavigationActionForKey ( const FKey InKey) const
pure virtual

Implemented in FSlateApplication.

◆ GetNavigationActionFromKey()

virtual EUINavigationAction FSlateApplicationBase::GetNavigationActionFromKey ( const FKeyEvent InKeyEvent) const
pure virtual

Implemented in FSlateApplication.

◆ GetNavigationDirectionFromAnalog()

virtual EUINavigation FSlateApplicationBase::GetNavigationDirectionFromAnalog ( const FAnalogInputEvent InAnalogEvent)
pure virtual

Implemented in FSlateApplication.

◆ GetNavigationDirectionFromKey()

virtual EUINavigation FSlateApplicationBase::GetNavigationDirectionFromKey ( const FKeyEvent InKeyEvent) const
pure virtual

Implemented in FSlateApplication.

◆ GetPlatformApplication() [1/2]

TSharedPtr< class GenericApplication > FSlateApplicationBase::GetPlatformApplication ( )
inline

◆ GetPlatformApplication() [2/2]

virtual const TSharedPtr< GenericApplication > FSlateApplicationBase::GetPlatformApplication ( ) const
inlinevirtual

Gets the platform application.

Returns
Platform application.

◆ GetPlatformCursor()

TSharedPtr< ICursor > FSlateApplicationBase::GetPlatformCursor ( )
inline

◆ GetPreferredWorkArea()

virtual FSlateRect FSlateApplicationBase::GetPreferredWorkArea ( ) const
pure virtual

Gets the rectangle of the current preferred work area.

Returns
Area rectangle.

Implemented in FSlateApplication.

◆ GetRenderer()

FSlateRenderer * FSlateApplicationBase::GetRenderer ( ) const
inline

Gets the renderer being used to draw this application.

Returns
The Slate renderer.

◆ GetSafeZoneRatio()

void FSlateApplicationBase::GetSafeZoneRatio ( FMargin SafeZoneRatio)
protected

◆ GetSafeZoneSize()

void FSlateApplicationBase::GetSafeZoneSize ( FMargin SafeZone,
const UE::Slate::FDeprecateVector2DParameter OverrideSize 
)

◆ GetSoftwareCursorAvailable()

virtual bool FSlateApplicationBase::GetSoftwareCursorAvailable ( ) const
pure virtual

Whether the software cursor is enabled for this application.

Returns
software cursor available or not.

Implemented in FSlateApplication.

◆ GetSoftwareCursorVis()

virtual EVisibility FSlateApplicationBase::GetSoftwareCursorVis ( ) const
pure virtual

Gets the desired visibility of the software cursor

Returns
Software Cursor visibility

Implemented in FSlateApplication.

◆ GetTopLevelWindows()

virtual const TArray< TSharedRef< SWindow > > FSlateApplicationBase::GetTopLevelWindows ( ) const
pure virtual

Get a list of all top-level windows in the application, excluding virtual windows.

Returns
An array of all current top-level SWindows.

Implemented in FSlateApplication.

◆ GetUserFocusedWidget()

virtual TSharedPtr< SWidget > FSlateApplicationBase::GetUserFocusedWidget ( uint32  UserIndex) const
pure virtual
Returns
a pointer to the Widget that currently has the users focus; Empty pointer when the user has no focus.

Implemented in FSlateApplication.

◆ GetWindowTransparencySupport()

virtual EWindowTransparency FSlateApplicationBase::GetWindowTransparencySupport ( ) const
pure virtual

Get the highest level of window transparency support currently enabled by this application

Returns
Enumeration value specifying the level of transparency currently supported

Implemented in FSlateApplication.

◆ HasAnyMouseCaptor()

virtual bool FSlateApplicationBase::HasAnyMouseCaptor ( ) const
pure virtual

Gets whether or not a widget has captured the mouse.

Returns
True if one or more widgets have capture, otherwise false.

Implemented in FSlateApplication.

◆ HasAnyUserFocus()

virtual TOptional< EFocusCause > FSlateApplicationBase::HasAnyUserFocus ( const TSharedPtr< const SWidget Widget) const
protectedpure virtual

Gets whether or not a particular widget has any users focus, and if so the type of focus (first one found).

Returns
The optional will be set with the focus cause, if unset this widget doesn't have focus.

Implemented in FSlateApplication.

◆ HasFocusedDescendants()

virtual bool FSlateApplicationBase::HasFocusedDescendants ( const TSharedRef< const SWidget > &  Widget) const
pure virtual

Checks whether the specified widget has any descendants which are currently focused.

Parameters
WidgetThe widget to check.
Returns
true if any descendants are focused, false otherwise.

Implemented in FSlateApplication.

◆ HasUserFocus()

virtual TOptional< EFocusCause > FSlateApplicationBase::HasUserFocus ( const TSharedPtr< const SWidget Widget,
int32  UserIndex 
) const
protectedpure virtual

Gets whether or not a particular widget has the specified users focus, and if so the type of focus.

Returns
The optional will be set with the focus cause, if unset this widget doesn't have focus.

Implemented in FSlateApplication.

◆ HasUserFocusedDescendants()

virtual bool FSlateApplicationBase::HasUserFocusedDescendants ( const TSharedRef< const SWidget > &  Widget,
int32  UserIndex 
) const
pure virtual

Checks whether the specified widget has any descendants which are currently focused for the specified user user.

Parameters
WidgetThe widget to check.
InUserIndexIndex of the user that we want to check for.
Returns
true if any descendants are focused, false otherwise.

Implemented in FSlateApplication.

◆ HasUserMouseCapture()

virtual bool FSlateApplicationBase::HasUserMouseCapture ( int32  UserIndex) const
pure virtual

Gets whether or not a widget has captured the mouse for a particular user.

Returns
True if one or more widgets have capture, otherwise false.

Implemented in FSlateApplication.

◆ InvalidateAllWidgets()

void FSlateApplicationBase::InvalidateAllWidgets ( bool  bClearResourcesImmediately) const

Notifies all invalidation panels that they should invalidate their contents Note: this is a very expensive call and should only be done in non-performance critical situations

◆ IsActive()

virtual bool FSlateApplicationBase::IsActive ( ) const
pure virtual

Whether the application is active.

Returns
application active or not

Implemented in FSlateApplication.

◆ IsCustomSafeZoneSet()

bool FSlateApplicationBase::IsCustomSafeZoneSet ( ) const

◆ IsExternalUIOpened()

virtual bool FSlateApplicationBase::IsExternalUIOpened ( )
pure virtual

Checks whether an UI for external services such as Steam is open.

Returns
true if an external UI is open, false otherwise.

Implemented in FSlateApplication.

◆ IsInitialized()

static bool FSlateApplicationBase::IsInitialized ( )
inlinestatic

Returns true if a Slate application instance is currently initialized and ready

Returns
True if Slate application is initialized

◆ IsSlateAsleep()

bool FSlateApplicationBase::IsSlateAsleep ( )

Is Slate currently sleeping or not.

Returns
True if Slate is sleeping.

◆ IsWidgetDirectlyHovered()

virtual bool FSlateApplicationBase::IsWidgetDirectlyHovered ( const TSharedPtr< const SWidget Widget) const
protectedpure virtual

Gets whether or not a particular widget is directly hovered. Directly hovered means that the widget is directly under the pointer, is not true for ancestors tho they are Hovered.

Returns
True if the widget is directly hovered, otherwise false.

Implemented in FSlateApplication.

◆ IsWindowHousingInteractiveTooltip()

virtual bool FSlateApplicationBase::IsWindowHousingInteractiveTooltip ( const TSharedRef< const SWindow > &  WindowToTest) const
pure virtual
Returns
true if 'WindowToTest' is being used to display the current tooltip and the tooltip is interactive.

Implemented in FSlateApplication.

◆ LocateWidgetInWindow()

virtual FWidgetPath FSlateApplicationBase::LocateWidgetInWindow ( UE::Slate::FDeprecateVector2DParameter  ScreenspaceMouseCoordinate,
const TSharedRef< SWindow > &  Window,
bool  bIgnoreEnabledStatus,
int32  UserIndex 
) const
protectedpure virtual

Given a window, locate a widget under the cursor in it; returns an invalid path if cursor is not over this window.

Implemented in FSlateApplication.

◆ LocateWindowUnderMouse()

virtual FWidgetPath FSlateApplicationBase::LocateWindowUnderMouse ( UE::Slate::FDeprecateVector2DParameter  ScreenspaceMouseCoordinate,
const TArray< TSharedRef< SWindow > > &  Windows,
bool  bIgnoreEnabledStatus = false,
int32  UserIndex = INDEX_NONE 
)
pure virtual

Given the screen-space coordinate of the mouse cursor, searches for a string of widgets that are under the mouse.

The widgets will be returned with the associated geometry. The first item will always be the top-level window while the last item will be the leaf-most widget.

Returns
The path to the widget.

Implemented in FSlateApplication.

◆ MakeImage()

virtual TSharedRef< SImage > FSlateApplicationBase::MakeImage ( const TAttribute< const FSlateBrush * > &  Image,
const TAttribute< FSlateColor > &  Color,
const TAttribute< EVisibility > &  Visibility 
) const
pure virtual

Creates an image widget.

Returns
The new image widget.

Implemented in FSlateApplication.

◆ MakeToolTip() [1/2]

virtual TSharedRef< IToolTip > FSlateApplicationBase::MakeToolTip ( const FText ToolTipText)
pure virtual

Creates a tool tip with the specified text.

Parameters
ToolTipTextThe text to assign to the tool tip.
Returns
The tool tip.

Implemented in FSlateApplication.

◆ MakeToolTip() [2/2]

virtual TSharedRef< IToolTip > FSlateApplicationBase::MakeToolTip ( const TAttribute< FText > &  ToolTipText)
pure virtual

Creates a tool tip with the specified text.

Parameters
ToolTipTextThe text attribute to assign to the tool tip.
Returns
The tool tip.

Implemented in FSlateApplication.

◆ MakeWindowTitleBar()

virtual TSharedRef< SWidget > FSlateApplicationBase::MakeWindowTitleBar ( const FWindowTitleBarArgs InArgs,
TSharedPtr< IWindowTitleBar > &  OutTitleBar 
) const
pure virtual

Creates a title bar for the specified window.

Parameters
InArgsThe creation arguments for the titlebar
OutTitleBarWill hold a pointer to the title bar's interface.
Returns
The new title bar widget.

Implemented in FSlateApplication.

◆ OnGlobalInvalidationToggled()

FOnGlobalInvalidationToggled & FSlateApplicationBase::OnGlobalInvalidationToggled ( )
inline

◆ OnInvalidateAllWidgets()

FOnInvalidateAllWidgets & FSlateApplicationBase::OnInvalidateAllWidgets ( )
inline

◆ RequestDestroyWindow()

virtual void FSlateApplicationBase::RequestDestroyWindow ( TSharedRef< SWindow WindowToDestroy)
pure virtual

Destroying windows has implications on some OSs (e.g. destroying Win32 HWNDs can cause events to be lost).

Slate strictly controls when windows are destroyed.

Parameters
WindowToDestroyThe window to queue for destruction.

Implemented in FSlateApplication.

◆ ResetCustomSafeZone()

void FSlateApplicationBase::ResetCustomSafeZone ( )

◆ SetAllUserFocus()

virtual void FSlateApplicationBase::SetAllUserFocus ( const FWidgetPath InFocusPath,
const EFocusCause  InCause 
)
pure virtual

Sets the focus for all users to the specified widget. The widget must be allowed to receive focus.

Parameters
InFocusPathWidgetPath to the Widget to being focused.
InCauseThe reason that focus is changing.

Implemented in FSlateApplication.

◆ SetAllUserFocusAllowingDescendantFocus()

virtual void FSlateApplicationBase::SetAllUserFocusAllowingDescendantFocus ( const FWidgetPath InFocusPath,
const EFocusCause  InCause 
)
pure virtual

Sets the focus for all users to the specified widget unless that user is focused on a descendant. The widget must be allowed to receive focus.

Parameters
InWidgetWidgetPath to the Widget to being focused.
InCauseThe reason that focus is changing.

Implemented in FSlateApplication.

◆ SetCustomSafeZone()

void FSlateApplicationBase::SetCustomSafeZone ( const FMargin InSafeZone)

◆ SetKeyboardFocus()

virtual bool FSlateApplicationBase::SetKeyboardFocus ( const FWidgetPath InFocusPath,
const EFocusCause  InCause 
)
pure virtual

Sets keyboard focus to the specified widget. The widget must be allowed to receive keyboard focus.

Parameters
InFocusPathWidgetPath to the Widget to being focused
InCauseThe reason that keyboard focus is changing
Returns
true if the widget is now focused, false otherwise.

Implemented in FSlateApplication.

◆ SetUserFocus()

virtual bool FSlateApplicationBase::SetUserFocus ( const uint32  InUserIndex,
const FWidgetPath InFocusPath,
const EFocusCause  InCause 
)
pure virtual

Sets user focus to the specified widget. The widget must be allowed to receive focus.

Parameters
InUserIndexIndex of the user that we want to change the focus of.
InFocusPathWidgetPath to the Widget to being focused.
InCauseThe reason that focus is changing.
Returns
true if the widget is now focused, false otherwise.

Implemented in FSlateApplication.

◆ SetUserFocusAllowingDescendantFocus()

virtual bool FSlateApplicationBase::SetUserFocusAllowingDescendantFocus ( const uint32  InUserIndex,
const FWidgetPath InFocusPath,
const EFocusCause  InCause 
)
pure virtual

Sets the focus for the specified user to the specified widget unless that user is focused on a descendant. The widget must be allowed to receive focus.

Parameters
InUserIndexIndex of the user that we want to change the focus of.
InFocusPathWidgetPath to the Widget to being focused.
InCauseThe reason that focus is changing.
Returns
true if the widget or a descendant is now focused, false otherwise.

Implemented in FSlateApplication.

◆ ShowUserFocus()

virtual bool FSlateApplicationBase::ShowUserFocus ( const TSharedPtr< const SWidget Widget) const
protectedpure virtual

Gets whether or not a particular widget should show user focus.

Returns
True if we should show user focus

Implemented in FSlateApplication.

◆ ToggleGlobalInvalidation()

void FSlateApplicationBase::ToggleGlobalInvalidation ( bool  bIsGlobalInvalidationEnabled)

◆ UpdateAnyActiveTimersArePending()

void FSlateApplicationBase::UpdateAnyActiveTimersArePending ( )
protected

Used to determine if any active timer handles are ready to fire. Means we need to tick slate even if no user interaction.

◆ UpdateCustomSafeZone()

void FSlateApplicationBase::UpdateCustomSafeZone ( const FMargin NewSafeZoneRatio,
bool  bShouldRecacheMetrics 
)
protected

Friends And Related Symbol Documentation

◆ FHitTesting

friend class FHitTesting
friend
Returns
a hittesting object that can perform hittests agains widgets. Only certain classes can make use of FHitTesting

◆ SWidget

friend class SWidget
friend

Member Data Documentation

◆ ActiveTimerCS

FCriticalSection FSlateApplicationBase::ActiveTimerCS
protected

Critical section for active timer registration as it can be called from the movie thread and the game thread

◆ bAnyActiveTimersPending

bool FSlateApplicationBase::bAnyActiveTimersPending = false
protected

Whether any active timers are pending for this Slate tick. Updated once a tick in AnyActiveTimersArePending().

◆ bIsSlateAsleep

bool FSlateApplicationBase::bIsSlateAsleep
protected

◆ CachedDebugTitleSafeRatio

float FSlateApplicationBase::CachedDebugTitleSafeRatio
protected

◆ CachedDisplayMetrics

FDisplayMetrics FSlateApplicationBase::CachedDisplayMetrics
protected

◆ CurrentBaseApplication

TSharedPtr< FSlateApplicationBase > FSlateApplicationBase::CurrentBaseApplication = nullptr
staticprotected

◆ CursorPointerIndex

const uint32 FSlateApplicationBase::CursorPointerIndex = ETouchIndex::CursorPointerIndex
static

◆ CursorUserIndex

const uint32 FSlateApplicationBase::CursorUserIndex = 0
static

◆ CustomSafeZoneRatio

FMargin FSlateApplicationBase::CustomSafeZoneRatio
protected

Safe Zone ratio to override platform settings

◆ CustomSafeZoneState

ECustomSafeZoneState FSlateApplicationBase::CustomSafeZoneState
protected

If Safe Zone ratio has been manually set, unset, or set via debug

◆ HitTesting

FHitTesting FSlateApplicationBase::HitTesting
protected

◆ OnGlobalInvalidationToggledEvent

FOnGlobalInvalidationToggled FSlateApplicationBase::OnGlobalInvalidationToggledEvent
protected

◆ OnInvalidateAllWidgetsEvent

FOnInvalidateAllWidgets FSlateApplicationBase::OnInvalidateAllWidgetsEvent
protected

multicast delegate to broadcast when a global invalidate is requested

◆ PlatformApplication

TSharedPtr< GenericApplication > FSlateApplicationBase::PlatformApplication = nullptr
staticprotected

◆ Renderer

TSharedPtr<FSlateRenderer> FSlateApplicationBase::Renderer
protected

◆ SlateAppPrimaryPlatformUser

const FPlatformUserId FSlateApplicationBase::SlateAppPrimaryPlatformUser = FPlatformUserId::CreateFromInternalId(0)
static

The primary platform user for this application. They will own the mouse and cursor by default. Default ID is 0


The documentation for this class was generated from the following files: