org.faceless.pdf2
Class PDFGlyphVector

java.lang.Object
  extended by org.faceless.pdf2.PDFGlyphVector

public abstract class PDFGlyphVector
extends Object

A PDFGlyphVector is a sequence of glyphs in a particular font. It's a very low-level class and most likely the LayoutBox is a better option, but if there's a requirement to get text onto the page as fast as possible without any layout then this class can be used. A quick example:

 PDFStyle style = ...
 PDFGlyphVector vector = style.createGlyphVector("Hello World", Locale.getDefault());
 canvas.drawGlyphVector(vector, x, y);
 

Since:
2.11.22
See Also:
PDFStyle.createGlyphVector(java.lang.String, java.util.Locale), PDFCanvas.drawGlyphVector(org.faceless.pdf2.PDFGlyphVector, float, float)

Method Summary
 int getNumGlyphs()
          Returns the number of glyphs in this PDFGlyphVector
 PDFStyle getStyle()
          Returns the style that created these glyphs.
 float getWidth()
          Returns the width of this PDFGlyphVector in points
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getStyle

public PDFStyle getStyle()
Returns the style that created these glyphs.


getNumGlyphs

public int getNumGlyphs()
Returns the number of glyphs in this PDFGlyphVector


getWidth

public float getWidth()
Returns the width of this PDFGlyphVector in points



Copyright © 2001-2013 Big Faceless Organization