UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FShapedGlyphEntry Struct Reference

#include <FontCache.h>

Public Member Functions

SLATECORE_API bool HasValidGlyph () const
 
SLATECORE_API float GetBitmapRenderScale () const
 

Public Attributes

TSharedPtr< FShapedGlyphFaceDataFontFaceData
 
uint32 GlyphIndex = 0
 
int32 SourceIndex = 0
 
int16 XAdvance = 0
 
int16 YAdvance = 0
 
int16 XOffset = 0
 
int16 YOffset = 0
 
int8 Kerning = 0
 
uint8 NumCharactersInGlyph = 0
 
uint8 NumGraphemeClustersInGlyph = 0
 
TextBiDi::ETextDirection TextDirection = TextBiDi::ETextDirection::LeftToRight
 
bool bIsVisible = false
 

Friends

class FSlateFontCache
 

Detailed Description

Information for rendering one glyph in a shaped text sequence

Member Function Documentation

◆ GetBitmapRenderScale()

float FShapedGlyphEntry::GetBitmapRenderScale ( ) const

Get any additional scale that should be applied when rendering this glyph

◆ HasValidGlyph()

bool FShapedGlyphEntry::HasValidGlyph ( ) const

Check whether this entry contains a valid glyph (non-zero, and not the SlateFontRendererUtils::InvalidSubChar glyph)

Friends And Related Symbol Documentation

◆ FSlateFontCache

friend class FSlateFontCache
friend

Member Data Documentation

◆ bIsVisible

bool FShapedGlyphEntry::bIsVisible = false

True if this is a visible glyph that should be drawn. False if the glyph is invisible (eg, whitespace or a control code) and should skip drawing, but still include its advance amount.

◆ FontFaceData

TSharedPtr<FShapedGlyphFaceData> FShapedGlyphEntry::FontFaceData

Provides access to the FreeType face for this glyph (not available publicly)

◆ GlyphIndex

uint32 FShapedGlyphEntry::GlyphIndex = 0

The index of this glyph in the FreeType face

◆ Kerning

int8 FShapedGlyphEntry::Kerning = 0

The "kerning" between this glyph and the next one in the sequence

Note
This value is included in the XAdvance so you never usually need it unless you're manually combining two sets of glyphs together.
This value isn't strictly the kerning value - it's simply the difference between the glyphs horizontal advance, and the shaped horizontal advance (so will contain any accumulated advance added by the shaper)

◆ NumCharactersInGlyph

uint8 FShapedGlyphEntry::NumCharactersInGlyph = 0

The number of source characters represented by this glyph This is typically 1, however will be greater for ligatures, or may be 0 if a single character produces multiple glyphs

◆ NumGraphemeClustersInGlyph

uint8 FShapedGlyphEntry::NumGraphemeClustersInGlyph = 0

The number of source grapheme clusters represented by this glyph This is typically 1, however will be greater for ligatures, or may be 0 if a single character produces multiple glyphs

◆ SourceIndex

int32 FShapedGlyphEntry::SourceIndex = 0

The index of this glyph from the source text. The source indices may skip characters if the sequence contains ligatures, additionally, some characters produce multiple glyphs leading to duplicate source indices

◆ TextDirection

The reading direction of the text this glyph was shaped from

◆ XAdvance

int16 FShapedGlyphEntry::XAdvance = 0

The amount to advance in X before drawing the next glyph in the sequence

◆ XOffset

int16 FShapedGlyphEntry::XOffset = 0

The offset to apply in X when drawing this glyph

◆ YAdvance

int16 FShapedGlyphEntry::YAdvance = 0

The amount to advance in Y before drawing the next glyph in the sequence

◆ YOffset

int16 FShapedGlyphEntry::YOffset = 0

The offset to apply in Y when drawing this glyph


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