Code example for ShortBuffer

Methods: get

0
    if (!horizontal)
      return 0; 
 
    glyphIndex = Math.min(glyphIndex,
                          numLongHorizontalMetricsEntries - 1);
    return horizontalGlyphMetrics.get(glyphIndex << 1);
  } 
 
 
  /** 
   * Determines the advance width of a glyph, without considering 
   * hinting. 
   * 
   * @param glyphIndex the index of the glyph whose advance width is 
   * to be determined. 
   * 
   * @param horizontal <code>true</code> for horizontal line layout, 
   * <code>false</code> for vertical line layout. 
   * 
   * @return the advance width, in font units. 
   */