VisualU 1.2.1
Plugin for Unreal Engine 5 that brings core functionality for a widget-based visual novel game
 
Loading...
Searching...
No Matches
UVisualSocket Class Reference

Zero-size scale box that acts as a socket for other widgets with additional functionality for UVisualImage. More...

#include <VisualSocket.h>

Inheritance diagram for UVisualSocket:

Public Member Functions

 UVisualSocket (const FObjectInitializer &ObjectInitializer)
 
void SetSocketOffset (FVector2D InSocketPosition)
 Setter for UVisualSocket::SocketOffset.
 
void SetAutoPositioning (bool ShouldAutoPosition)
 Setter for UVisualSocket::bAutoPositioning.
 
void SetImageDesiredPosition (FVector2D Position)
 Setter for UVisualSocket::ImageDesiredPosition.
 
FORCEINLINE FVector2D GetSocketOffset () const
 
FORCEINLINE bool IsAutoPositioning () const
 
FORCEINLINE FVector2D GetImageDesiredPosition () const
 

Protected Member Functions

virtual void SynchronizeProperties () override
 Keeps C++ and derived blueprint classes synced in the widget designer.
 
virtual void ReleaseSlateResources (bool bReleaseChildren) override
 Releases memory allocated for slate widgets.
 
virtual TSharedRef< SWidget > RebuildWidget () override
 

Protected Attributes

FVector2D SocketOffset
 Offset of the child widget relative to the position of this socket.
 
bool bAutoPositioning
 When active, socket offset would reflect UVisualSocket::ImageDesiredPosition.
 
FVector2D ImageDesiredPosition
 Desired position, in slate units, of the center of child visual image.
 

Private Attributes

TSharedPtr< SVisualSocketSlateVisualSocket
 Underlying slate visual socket.
 

Detailed Description

Zero-size scale box that acts as a socket for other widgets with additional functionality for UVisualImage.

See also
SVisualSocket

Member Function Documentation

◆ GetImageDesiredPosition()

FORCEINLINE FVector2D UVisualSocket::GetImageDesiredPosition ( ) const
inline
Returns
desired position of child visual image

◆ GetSocketOffset()

FORCEINLINE FVector2D UVisualSocket::GetSocketOffset ( ) const
inline
Returns
socket offset of the child widget

◆ IsAutoPositioning()

FORCEINLINE bool UVisualSocket::IsAutoPositioning ( ) const
inline
Returns
auto positioning policy for child visual image

◆ RebuildWidget()

TSharedRef< SWidget > UVisualSocket::RebuildWidget ( )
overrideprotectedvirtual
Returns
underlying slate widget

◆ ReleaseSlateResources()

void UVisualSocket::ReleaseSlateResources ( bool bReleaseChildren)
overrideprotectedvirtual

Releases memory allocated for slate widgets.

Parameters
bReleaseChildrenshould memory of child widgets be released

◆ SetAutoPositioning()

void UVisualSocket::SetAutoPositioning ( bool ShouldAutoPosition)

Setter for UVisualSocket::bAutoPositioning.

Parameters
ShouldAutoPositionnew auto positioning policy

◆ SetImageDesiredPosition()

void UVisualSocket::SetImageDesiredPosition ( FVector2D Position)

Setter for UVisualSocket::ImageDesiredPosition.

Parameters
Positionnew visual image desired position

◆ SetSocketOffset()

void UVisualSocket::SetSocketOffset ( FVector2D InSocketPosition)

Setter for UVisualSocket::SocketOffset.

Parameters
InSocketPositionnew socket offset

Member Data Documentation

◆ bAutoPositioning

bool UVisualSocket::bAutoPositioning
protected

When active, socket offset would reflect UVisualSocket::ImageDesiredPosition.

Meaningless for child widget that is not visual image.

◆ ImageDesiredPosition

FVector2D UVisualSocket::ImageDesiredPosition
protected

Desired position, in slate units, of the center of child visual image.

Meaningless for child widget that is not visual image.

Note
UVisualSocket::bAutoPositioning must be enabled for this feature to work

◆ SlateVisualSocket

TSharedPtr<SVisualSocket> UVisualSocket::SlateVisualSocket
private

Underlying slate visual socket.

See also
UVisualSocket::RebuildWidget()

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