APIdia Launch Partner
Top Methods
com.sun.javafx.scene.text

public Interface GlyphList

Known Direct Implementers
com.sun.javafx.text.TextRun
Imports
java.util.concurrent.atomic.AtomicBoolean, com.sun.javafx.geom.Point2D, .RectBounds

Method Summary

Modifier and TypeMethod and Description
public int
getCharOffset(int glyphIndex)

Maps the given glyph index to the char offset.

public int
getGlyphCode(int glyphIndex)

Returns the glyph code for the given glyphIndex.

public int
getGlyphCount()

Returns the number of glyphs in GlyphList.

public float
getHeight()

Returns the height of the GlyphList

public RectBounds
getLineBounds()

See TextLine#getBounds() (used outside text layout in rendering and span bounds)

public Point2D
getLocation()

The top-left location of the GlyphList relative to the origin of the Text Layout.

public int

Returns:

the glyph offset
getOffsetAtX
(float
the x coordinate
x
,
AtomicBoolean
the reference to hold the trailing flag
trailing
)

Gets the glyph offset at the specified x coordinate.

public float
getPosX(int glyphIndex)

The x position for the given glyphIndex relative the GlyphList.

public float
getPosY(int glyphIndex)

The y position for the given glyphIndex relative the GlyphList.

public int

Returns:

the start offset
getStart
()

Returns the start offset.

public TextSpan
getTextSpan()

Used during layout children (for rich text) can be null (for non-rich text) but never null for rich text.

public float
getWidth()

Returns the width of the GlyphList

public boolean
isComplex()

Means that this GlyphList was shaped using complex processing (ICU), either because it is complex script or because font features were requested.

public boolean

Returns:

whether this GlyphList is a line break
isLinebreak
()

Returns true if this GlyphList is a line break.

Method Detail

getCharOffsetback to summary
public int getCharOffset(int glyphIndex)

Maps the given glyph index to the char offset. (used during rendering (selection))

getGlyphCodeback to summary
public int getGlyphCode(int glyphIndex)

Returns the glyph code for the given glyphIndex.

getGlyphCountback to summary
public int getGlyphCount()

Returns the number of glyphs in GlyphList.

getHeightback to summary
public float getHeight()

Returns the height of the GlyphList

getLineBoundsback to summary
public RectBounds getLineBounds()

See TextLine#getBounds() (used outside text layout in rendering and span bounds)

getLocationback to summary
public Point2D getLocation()

The top-left location of the GlyphList relative to the origin of the Text Layout.

getOffsetAtXback to summary
public int getOffsetAtX(float x, AtomicBoolean trailing)

Gets the glyph offset at the specified x coordinate.

Parameters
x:float

the x coordinate

trailing:AtomicBoolean

the reference to hold the trailing flag

Returns:int

the glyph offset

getPosXback to summary
public float getPosX(int glyphIndex)

The x position for the given glyphIndex relative the GlyphList.

getPosYback to summary
public float getPosY(int glyphIndex)

The y position for the given glyphIndex relative the GlyphList.

getStartback to summary
public int getStart()

Returns the start offset.

Returns:int

the start offset

getTextSpanback to summary
public TextSpan getTextSpan()

Used during layout children (for rich text) can be null (for non-rich text) but never null for rich text.

getWidthback to summary
public float getWidth()

Returns the width of the GlyphList

isComplexback to summary
public boolean isComplex()

Means that this GlyphList was shaped using complex processing (ICU), either because it is complex script or because font features were requested. (used outside text layout in rendering)

isLinebreakback to summary
public boolean isLinebreak()

Returns true if this GlyphList is a line break.

Returns:boolean

whether this GlyphList is a line break