Interface Font.Glyph

  • Enclosing interface:
    Font

    public static interface Font.Glyph
    Glyph for font http://developer.apple.com/textfonts/TTRefMan/RM06/Chap6cmap.html http://developer.apple.com/textfonts/TTRefMan/RM06/Chap6glyf.html http://www.microsoft.com/typography/otspec/glyf.htm
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int ID_UNKNOWN  
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      String fullString()
      Returns all glyph details as string.
      float getAdvanceWidth()
      Returns advance in font em-size [0..1], sourced from `hmtx` table.
      int getAdvanceWidthFU()
      Returns advance in font units, sourced from `hmtx` table.
      com.jogamp.math.geom.AABBox getBounds()
      Returns the AABBox in font em-size [0..1], creating a new copy.
      com.jogamp.math.geom.AABBox getBounds​(com.jogamp.math.geom.AABBox dest)
      Returns the AABBox in font em-size [0..1], copying into given dest.
      com.jogamp.math.geom.AABBox getBoundsFU()
      Returns the AABBox in font-units, borrowing internal instance.
      com.jogamp.math.geom.AABBox getBoundsFU​(com.jogamp.math.geom.AABBox dest)
      Returns the AABBox in font-units, copying into given dest.
      char getCodepoint()
      Returns this glyph's mapped (unicode) `codepoint` symbol.
      Font getFont()
      Returns the Font owning this Font.Glyph.
      int getID()
      Returns this glyph's ID
      float getKerning​(int right_glyphid)
      Returns the optional kerning inter-glyph distance within words between this glyph and the given right glyph_id in fractional font em-size [0..1].
      int getKerningFU​(int right_glyphid)
      Returns the optional kerning inter-glyph distance within words between this glyph and the given right glyph_id in font-units.
      int getKerningPairCount()
      Returns the number of kerning values stored for this glyph, associated to a right hand glyph.
      float getLeftSideBearings()
      Returns leftSideBearings in font em-size [0..1], sourced from `hmtx` table.
      int getLeftSideBearingsFU()
      Returns leftSideBearings in font units, sourced from `hmtx` table.
      String getName()
      Returns the glyph's name, source from `post` table
      OutlineShape getShape()  
      int hashCode()  
      boolean isKerningCrossstream()
      True if kerning values are perpendicular to text flow, otherwise along with flow
      boolean isKerningHorizontal()
      True if kerning values are horizontal, otherwise vertical
      boolean isNonContour()
      Returns true if isWhitespace() or isUndefined().
      boolean isUndefined()
      Returns true if the Glyph denotes an undefined getID() symbol, determined as follows it's glyph index is ID_UNKNOWN, i.e.
      boolean isWhitespace()
      Returns true if the Glyph denotes a whitespace, determined as follows is not isUndefined() has no original underlying shape has an underlying shape with a zero sized area
      String toString()  
    • Method Detail

      • getCodepoint

        char getCodepoint()
        Returns this glyph's mapped (unicode) `codepoint` symbol.
      • getID

        int getID()
        Returns this glyph's ID
      • getName

        String getName()
        Returns the glyph's name, source from `post` table
      • getBoundsFU

        com.jogamp.math.geom.AABBox getBoundsFU()
        Returns the AABBox in font-units, borrowing internal instance.
      • getBoundsFU

        com.jogamp.math.geom.AABBox getBoundsFU​(com.jogamp.math.geom.AABBox dest)
        Returns the AABBox in font-units, copying into given dest.
        Parameters:
        dest - AABBox instance set to this metrics boundary in font-units
        Returns:
        the given and set AABBox 'dest' in font-units
      • getBounds

        com.jogamp.math.geom.AABBox getBounds​(com.jogamp.math.geom.AABBox dest)
        Returns the AABBox in font em-size [0..1], copying into given dest.
        Parameters:
        dest - AABBox instance set to this metrics boundary in font em-size [0..1]
        Returns:
        the given and set AABBox 'dest' in font em-size [0..1]
      • getBounds

        com.jogamp.math.geom.AABBox getBounds()
        Returns the AABBox in font em-size [0..1], creating a new copy.
      • getAdvanceWidthFU

        int getAdvanceWidthFU()
        Returns advance in font units, sourced from `hmtx` table.
      • getAdvanceWidth

        float getAdvanceWidth()
        Returns advance in font em-size [0..1], sourced from `hmtx` table.
      • getLeftSideBearingsFU

        int getLeftSideBearingsFU()
        Returns leftSideBearings in font units, sourced from `hmtx` table.
      • getLeftSideBearings

        float getLeftSideBearings()
        Returns leftSideBearings in font em-size [0..1], sourced from `hmtx` table.
      • isKerningHorizontal

        boolean isKerningHorizontal()
        True if kerning values are horizontal, otherwise vertical
      • isKerningCrossstream

        boolean isKerningCrossstream()
        True if kerning values are perpendicular to text flow, otherwise along with flow
      • getKerningPairCount

        int getKerningPairCount()
        Returns the number of kerning values stored for this glyph, associated to a right hand glyph.
      • getKerningFU

        int getKerningFU​(int right_glyphid)
        Returns the optional kerning inter-glyph distance within words between this glyph and the given right glyph_id in font-units.
        Parameters:
        right_glyphid - right glyph code id
        Returns:
        font-units
      • getKerning

        float getKerning​(int right_glyphid)
        Returns the optional kerning inter-glyph distance within words between this glyph and the given right glyph_id in fractional font em-size [0..1].
        Parameters:
        right_glyphid - right glyph code id
        Returns:
        fractional font em-size distance [0..1]
      • fullString

        String fullString()
        Returns all glyph details as string.