Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SpriteGlyph

Constructor for new sprite glyph.
Read time 1 minuteLast updated 13 days ago

Definition

SpriteGlyph()

Constructor for new sprite glyph.
public SpriteGlyph()

SpriteGlyph(uint, GlyphMetrics, GlyphRect, float, int)

Constructor for new sprite glyph.
public SpriteGlyph(uint index, GlyphMetrics metrics, GlyphRect glyphRect, float scale, int atlasIndex)

Parameters

index

Index of the sprite glyph.

Metrics which define the position of the glyph in the context of text layout.

glyphRect

GlyphRect which defines the coordinates of the glyph in the atlas texture.

scale

Scale of the glyph.

atlasIndex

Index of the atlas texture that contains the glyph.

SpriteGlyph(uint, GlyphMetrics, GlyphRect, float, int, Sprite)

Constructor for new sprite glyph.
public SpriteGlyph(uint index, GlyphMetrics metrics, GlyphRect glyphRect, float scale, int atlasIndex, Sprite sprite)

Parameters

index

Index of the sprite glyph.

Metrics which define the position of the glyph in the context of text layout.

glyphRect

GlyphRect which defines the coordinates of the glyph in the atlas texture.

scale

Scale of the glyph.

atlasIndex

Index of the atlas texture that contains the glyph.

sprite

A reference to the Unity Sprite representing this sprite glyph.