UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FSlateTextRun Class Reference

#include <SlateTextRun.h>

+ Inheritance diagram for FSlateTextRun:

Public Member Functions

virtual ~FSlateTextRun ()
 
virtual SLATE_API FTextRange GetTextRange () const override
 
virtual SLATE_API void SetTextRange (const FTextRange &Value) override
 
virtual SLATE_API int16 GetBaseLine (float Scale) const override
 
virtual SLATE_API int16 GetMaxHeight (float Scale) const override
 
virtual SLATE_API FVector2D Measure (int32 StartIndex, int32 EndIndex, float Scale, const FRunTextContext &TextContext) const override
 
virtual SLATE_API int8 GetKerning (int32 CurrentIndex, float Scale, const FRunTextContext &TextContext) const override
 
virtual SLATE_API FVector2d GetOutlineSize (int32 StartIndex, int32 EndIndex, float Scale) const override
 
virtual SLATE_API FVector2d GetShadowSize (int32 StartIndex, int32 EndIndex, float Scale) const override
 
virtual SLATE_API TSharedRef< ILayoutBlockCreateBlock (int32 StartIndex, int32 EndIndex, FVector2D Size, const FLayoutBlockTextContext &TextContext, const TSharedPtr< IRunRenderer > &Renderer) override
 
virtual SLATE_API int32 OnPaint (const FPaintArgs &PaintArgs, const FTextArgs &TextArgs, const FGeometry &AllottedGeometry, const FSlateRect &MyCullingRect, FSlateWindowElementList &OutDrawElements, int32 LayerId, const FWidgetStyle &InWidgetStyle, bool bParentEnabled) const override
 
virtual SLATE_API const TArray< TSharedRef< SWidget > > & GetChildren () override
 
virtual SLATE_API void ArrangeChildren (const TSharedRef< ILayoutBlock > &Block, const FGeometry &AllottedGeometry, FArrangedChildren &ArrangedChildren) const override
 
virtual void BeginLayout () override
 
virtual void EndLayout () override
 
virtual SLATE_API int32 GetTextIndexAt (const TSharedRef< ILayoutBlock > &Block, const FVector2D &Location, float Scale, ETextHitPoint *const OutHitPoint=nullptr) const override
 
virtual SLATE_API FVector2D GetLocationAt (const TSharedRef< ILayoutBlock > &Block, int32 Offset, float Scale) const override
 
virtual SLATE_API void Move (const TSharedRef< FString > &NewText, const FTextRange &NewRange) override
 
virtual SLATE_API TSharedRef< IRunClone () const override
 
virtual SLATE_API void AppendTextTo (FString &Text) const override
 
virtual SLATE_API void AppendTextTo (FString &AppendToText, const FTextRange &PartialRange) const override
 
virtual SLATE_API const FRunInfoGetRunInfo () const override
 
virtual SLATE_API ERunAttributes GetRunAttributes () const override
 
SLATE_API void ApplyFontSizeMultiplierOnTextStyle (float FontSizeMultiplier)
 
- Public Member Functions inherited from IRun
virtual ~IRun ()
 
- Public Member Functions inherited from TSharedFromThis< FSlateTextRun >
TSharedRef< FSlateTextRun, Mode > AsShared ()
 
TSharedRef< FSlateTextRun const, Mode > AsShared () const
 
TSharedRef< SubobjectType, Mode > AsSharedSubobject (SubobjectType *SubobjectPtr) const
 
TWeakPtr< FSlateTextRun, Mode > AsWeak ()
 
TWeakPtr< FSlateTextRun const, Mode > AsWeak () const
 
TWeakPtr< SubobjectType, Mode > AsWeakSubobject (SubobjectType *SubobjectPtr) const
 
void UpdateWeakReferenceInternal (TSharedPtr< SharedPtrType, SharedPtrMode > const *InSharedPtr, OtherType *InObject) const
 
void UpdateWeakReferenceInternal (TSharedRef< SharedRefType, SharedPtrMode > const *InSharedRef, OtherType *InObject) const
 
UE_FORCEINLINE_HINT bool DoesSharedInstanceExist () const
 

Static Public Member Functions

static SLATE_API TSharedRef< FSlateTextRunCreate (const FRunInfo &InRunInfo, const TSharedRef< const FString > &InText, const FTextBlockStyle &Style)
 
static SLATE_API TSharedRef< FSlateTextRunCreate (const FRunInfo &InRunInfo, const TSharedRef< const FString > &InText, const FTextBlockStyle &Style, const FTextRange &InRange)
 

Protected Member Functions

SLATE_API FSlateTextRun (const FRunInfo &InRunInfo, const TSharedRef< const FString > &InText, const FTextBlockStyle &InStyle)
 
SLATE_API FSlateTextRun (const FRunInfo &InRunInfo, const TSharedRef< const FString > &InText, const FTextBlockStyle &InStyle, const FTextRange &InRange)
 
SLATE_API FSlateTextRun (const FSlateTextRun &Run)
 
- Protected Member Functions inherited from TSharedFromThis< FSlateTextRun >
 TSharedFromThis ()
 
 TSharedFromThis (TSharedFromThis const &)
 
UE_FORCEINLINE_HINT TSharedFromThisoperator= (TSharedFromThis const &)
 
 ~TSharedFromThis ()
 

Protected Attributes

FRunInfo RunInfo
 
TSharedRef< const FString > Text
 
FTextBlockStyle Style
 
FTextRange Range
 

Additional Inherited Members

- Static Protected Member Functions inherited from TSharedFromThis< FSlateTextRun >
static UE_FORCEINLINE_HINT TSharedRef< OtherType, Mode > SharedThis (OtherType *ThisPtr)
 
static UE_FORCEINLINE_HINT TSharedRef< OtherType const, Mode > SharedThis (const OtherType *ThisPtr)
 

Constructor & Destructor Documentation

◆ ~FSlateTextRun()

virtual FSlateTextRun::~FSlateTextRun ( )
inlinevirtual

◆ FSlateTextRun() [1/3]

FSlateTextRun::FSlateTextRun ( const FRunInfo InRunInfo,
const TSharedRef< const FString > &  InText,
const FTextBlockStyle InStyle 
)
protected

◆ FSlateTextRun() [2/3]

FSlateTextRun::FSlateTextRun ( const FRunInfo InRunInfo,
const TSharedRef< const FString > &  InText,
const FTextBlockStyle InStyle,
const FTextRange InRange 
)
protected

◆ FSlateTextRun() [3/3]

FSlateTextRun::FSlateTextRun ( const FSlateTextRun Run)
protected

Member Function Documentation

◆ AppendTextTo() [1/2]

void FSlateTextRun::AppendTextTo ( FString &  AppendToText,
const FTextRange PartialRange 
) const
overridevirtual

Implements IRun.

◆ AppendTextTo() [2/2]

void FSlateTextRun::AppendTextTo ( FString &  Text) const
overridevirtual

Implements IRun.

◆ ApplyFontSizeMultiplierOnTextStyle()

void FSlateTextRun::ApplyFontSizeMultiplierOnTextStyle ( float  FontSizeMultiplier)

◆ ArrangeChildren()

void FSlateTextRun::ArrangeChildren ( const TSharedRef< ILayoutBlock > &  Block,
const FGeometry AllottedGeometry,
FArrangedChildren ArrangedChildren 
) const
overridevirtual

Implements ISlateRun.

◆ BeginLayout()

virtual void FSlateTextRun::BeginLayout ( )
inlineoverridevirtual

Implements IRun.

◆ Clone()

TSharedRef< IRun > FSlateTextRun::Clone ( ) const
overridevirtual

Implements IRun.

Reimplemented in FSlatePasswordRun.

◆ Create() [1/2]

TSharedRef< FSlateTextRun > FSlateTextRun::Create ( const FRunInfo InRunInfo,
const TSharedRef< const FString > &  InText,
const FTextBlockStyle Style 
)
static

◆ Create() [2/2]

TSharedRef< FSlateTextRun > FSlateTextRun::Create ( const FRunInfo InRunInfo,
const TSharedRef< const FString > &  InText,
const FTextBlockStyle Style,
const FTextRange InRange 
)
static

◆ CreateBlock()

TSharedRef< ILayoutBlock > FSlateTextRun::CreateBlock ( int32  StartIndex,
int32  EndIndex,
FVector2D  Size,
const FLayoutBlockTextContext TextContext,
const TSharedPtr< IRunRenderer > &  Renderer 
)
overridevirtual

Implements IRun.

◆ EndLayout()

virtual void FSlateTextRun::EndLayout ( )
inlineoverridevirtual

Implements IRun.

◆ GetBaseLine()

int16 FSlateTextRun::GetBaseLine ( float  Scale) const
overridevirtual

Implements IRun.

◆ GetChildren()

const TArray< TSharedRef< SWidget > > & FSlateTextRun::GetChildren ( )
overridevirtual

Implements ISlateRun.

◆ GetKerning()

int8 FSlateTextRun::GetKerning ( int32  CurrentIndex,
float  Scale,
const FRunTextContext TextContext 
) const
overridevirtual

Implements IRun.

Reimplemented in FSlatePasswordRun.

◆ GetLocationAt()

FVector2D FSlateTextRun::GetLocationAt ( const TSharedRef< ILayoutBlock > &  Block,
int32  Offset,
float  Scale 
) const
overridevirtual

Implements IRun.

Reimplemented in FSlatePasswordRun.

◆ GetMaxHeight()

int16 FSlateTextRun::GetMaxHeight ( float  Scale) const
overridevirtual

Implements IRun.

◆ GetOutlineSize()

FVector2d FSlateTextRun::GetOutlineSize ( int32  StartIndex,
int32  EndIndex,
float  Scale 
) const
overridevirtual

Reimplemented from IRun.

◆ GetRunAttributes()

ERunAttributes FSlateTextRun::GetRunAttributes ( ) const
overridevirtual

Implements IRun.

◆ GetRunInfo()

const FRunInfo & FSlateTextRun::GetRunInfo ( ) const
overridevirtual

Implements IRun.

◆ GetShadowSize()

FVector2d FSlateTextRun::GetShadowSize ( int32  StartIndex,
int32  EndIndex,
float  Scale 
) const
overridevirtual

Reimplemented from IRun.

◆ GetTextIndexAt()

int32 FSlateTextRun::GetTextIndexAt ( const TSharedRef< ILayoutBlock > &  Block,
const FVector2D Location,
float  Scale,
ETextHitPoint *const  OutHitPoint = nullptr 
) const
overridevirtual

Implements IRun.

Reimplemented in FSlatePasswordRun.

◆ GetTextRange()

FTextRange FSlateTextRun::GetTextRange ( ) const
overridevirtual

Implements IRun.

◆ Measure()

FVector2D FSlateTextRun::Measure ( int32  StartIndex,
int32  EndIndex,
float  Scale,
const FRunTextContext TextContext 
) const
overridevirtual

Implements IRun.

Reimplemented in FSlatePasswordRun.

◆ Move()

void FSlateTextRun::Move ( const TSharedRef< FString > &  NewText,
const FTextRange NewRange 
)
overridevirtual

Implements IRun.

◆ OnPaint()

int32 FSlateTextRun::OnPaint ( const FPaintArgs PaintArgs,
const FTextArgs TextArgs,
const FGeometry AllottedGeometry,
const FSlateRect MyCullingRect,
FSlateWindowElementList OutDrawElements,
int32  LayerId,
const FWidgetStyle InWidgetStyle,
bool  bParentEnabled 
) const
overridevirtual

Implements ISlateRun.

Reimplemented in FSlatePasswordRun.

◆ SetTextRange()

void FSlateTextRun::SetTextRange ( const FTextRange Value)
overridevirtual

Implements IRun.

Member Data Documentation

◆ Range

FTextRange FSlateTextRun::Range
protected

◆ RunInfo

FRunInfo FSlateTextRun::RunInfo
protected

◆ Style

FTextBlockStyle FSlateTextRun::Style
protected

◆ Text

TSharedRef< const FString > FSlateTextRun::Text
protected

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