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

#include <FontCacheFreeType.h>

Public Member Functions

 FFreeTypeFace (const FFreeTypeLibrary *InFTLibrary, FFontFaceDataConstRef InMemory, const int32 InFaceIndex, const EFontLayoutMethod InLayoutMethod)
 
 FFreeTypeFace (const FFreeTypeLibrary *InFTLibrary, const FString &InFilename, const int32 InFaceIndex, const EFontLayoutMethod InLayoutMethod)
 
 FFreeTypeFace (const EFontLayoutMethod InLayoutMethod)
 
 ~FFreeTypeFace ()
 
FORCEINLINE bool IsFaceValid () const
 
FORCEINLINE bool IsFaceLoading () const
 
FORCEINLINE bool SupportsSdf () const
 
FORCEINLINE const TSet< FName > & GetAttributes () const
 
FORCEINLINE EFontLayoutMethod GetLayoutMethod () const
 
SIZE_T GetAllocatedMemorySize () const
 
const UE::Slate::FPreprocessedFontGeometryGetPreprocessedFontGeometry () const
 
void OverrideAscent (bool InOverride, int32 Value=0)
 
void OverrideDescent (bool InOverride, int32 Value=0)
 
void FailAsyncLoad ()
 
void CompleteAsyncLoad (const FFreeTypeLibrary *InFTLibrary, FFontFaceDataConstRef InMemory, const int32 InFaceIndex)
 

Static Public Member Functions

static TArray< FString > GetAvailableSubFaces (const FFreeTypeLibrary *InFTLibrary, FFontFaceDataConstRef InMemory)
 
static TArray< FString > GetAvailableSubFaces (const FFreeTypeLibrary *InFTLibrary, const FString &InFilename)
 

Detailed Description

Wrapper around a FreeType face instance. It will either steal the given buffer, or stream the given file from disk.

Constructor & Destructor Documentation

◆ FFreeTypeFace() [1/3]

FFreeTypeFace::FFreeTypeFace ( const FFreeTypeLibrary InFTLibrary,
FFontFaceDataConstRef  InMemory,
const int32  InFaceIndex,
const EFontLayoutMethod  InLayoutMethod 
)

◆ FFreeTypeFace() [2/3]

FFreeTypeFace::FFreeTypeFace ( const FFreeTypeLibrary InFTLibrary,
const FString &  InFilename,
const int32  InFaceIndex,
const EFontLayoutMethod  InLayoutMethod 
)

◆ FFreeTypeFace() [3/3]

FFreeTypeFace::FFreeTypeFace ( const EFontLayoutMethod  InLayoutMethod)

◆ ~FFreeTypeFace()

FFreeTypeFace::~FFreeTypeFace ( )

Member Function Documentation

◆ CompleteAsyncLoad()

void FFreeTypeFace::CompleteAsyncLoad ( const FFreeTypeLibrary InFTLibrary,
FFontFaceDataConstRef  InMemory,
const int32  InFaceIndex 
)

◆ FailAsyncLoad()

void FFreeTypeFace::FailAsyncLoad ( )

◆ GetAllocatedMemorySize()

SIZE_T FFreeTypeFace::GetAllocatedMemorySize ( ) const

Gets the memory size of the loaded font or 0 if the font is streamed

◆ GetAttributes()

FORCEINLINE const TSet< FName > & FFreeTypeFace::GetAttributes ( ) const
inline

◆ GetAvailableSubFaces() [1/2]

TArray< FString > FFreeTypeFace::GetAvailableSubFaces ( const FFreeTypeLibrary InFTLibrary,
const FString &  InFilename 
)
static

◆ GetAvailableSubFaces() [2/2]

TArray< FString > FFreeTypeFace::GetAvailableSubFaces ( const FFreeTypeLibrary InFTLibrary,
FFontFaceDataConstRef  InMemory 
)
static

Get the available sub-face data from the given font. Typically there will only be one face unless this is a TTC/OTC font. The index of the returned entry can be passed as InFaceIndex to the FFreeTypeFace constructor.

◆ GetLayoutMethod()

FORCEINLINE EFontLayoutMethod FFreeTypeFace::GetLayoutMethod ( ) const
inline

◆ GetPreprocessedFontGeometry()

const UE::Slate::FPreprocessedFontGeometry * FFreeTypeFace::GetPreprocessedFontGeometry ( ) const

Returns the preprocessed font geometry object associated with the font data if available. It can only be available if this was initialized with a FontFaceData object.

◆ IsFaceLoading()

FORCEINLINE bool FFreeTypeFace::IsFaceLoading ( ) const
inline

◆ IsFaceValid()

FORCEINLINE bool FFreeTypeFace::IsFaceValid ( ) const
inline

◆ OverrideAscent()

void FFreeTypeFace::OverrideAscent ( bool  InOverride,
int32  Value = 0 
)
inline

◆ OverrideDescent()

void FFreeTypeFace::OverrideDescent ( bool  InOverride,
int32  Value = 0 
)
inline

◆ SupportsSdf()

FORCEINLINE bool FFreeTypeFace::SupportsSdf ( ) const
inline

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