Package com.badlogic.gdx.graphics.g2d
Class GlyphLayout.GlyphRun
- java.lang.Object
-
- com.badlogic.gdx.graphics.g2d.GlyphLayout.GlyphRun
-
- All Implemented Interfaces:
Pool.Poolable
- Enclosing class:
- GlyphLayout
public static class GlyphLayout.GlyphRun extends java.lang.Object implements Pool.Poolable
Stores glyphs and positions for a line of text.
-
-
Field Summary
Fields Modifier and Type Field Description Array<BitmapFont.Glyph>glyphsfloatwidthfloatxFloatArrayxAdvancesContains glyphs.size+1 entries:
The first entry is the X offset relative to the drawing position.
Subsequent entries are the X advance relative to previous glyph position.
The last entry is the width of the last glyph.floaty
-
Constructor Summary
Constructors Constructor Description GlyphRun()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidreset()Resets the object for reuse.java.lang.StringtoString()
-
-
-
Field Detail
-
glyphs
public Array<BitmapFont.Glyph> glyphs
-
xAdvances
public FloatArray xAdvances
Contains glyphs.size+1 entries:
The first entry is the X offset relative to the drawing position.
Subsequent entries are the X advance relative to previous glyph position.
The last entry is the width of the last glyph.
-
x
public float x
-
y
public float y
-
width
public float width
-
-
Method Detail
-
reset
public void reset()
Description copied from interface:Pool.PoolableResets the object for reuse. Object references should be nulled and fields may be set to default values.- Specified by:
resetin interfacePool.Poolable
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-