de.erichseifert.vectorgraphics2d
Class PDFGraphics2D

java.lang.Object
  extended by java.awt.Graphics
      extended by java.awt.Graphics2D
          extended by de.erichseifert.vectorgraphics2d.VectorGraphics2D
              extended by de.erichseifert.vectorgraphics2d.PDFGraphics2D

public class PDFGraphics2D
extends VectorGraphics2D

Graphics2D implementation that saves all operations to a string in the Portable Document Format (PDF).


Nested Class Summary
 
Nested classes/interfaces inherited from class de.erichseifert.vectorgraphics2d.VectorGraphics2D
VectorGraphics2D.FontRendering
 
Constructor Summary
PDFGraphics2D(double x, double y, double width, double height)
          Constructor that initializes a new PDFGraphics2D instance.
 
Method Summary
 byte[] getBytes()
          Encodes the painted data into a sequence of bytes.
 void setClip(java.awt.Shape clip)
           
 void setColor(java.awt.Color c)
           
 void setStroke(java.awt.Stroke s)
           
 java.lang.String toString()
           
 
Methods inherited from class de.erichseifert.vectorgraphics2d.VectorGraphics2D
addRenderingHints, clearRect, clip, clipRect, copyArea, create, dispose, draw, drawArc, drawGlyphVector, drawImage, drawImage, drawImage, drawImage, drawImage, drawImage, drawImage, drawImage, drawLine, drawOval, drawPolygon, drawPolyline, drawRect, drawRenderableImage, drawRenderedImage, drawRoundRect, drawString, drawString, drawString, drawString, fill, fillArc, fillOval, fillPolygon, fillRect, fillRoundRect, getBackground, getBounds, getClip, getClipBounds, getColor, getComposite, getDeviceConfiguration, getFont, getFontMetrics, getFontRenderContext, getFontRendering, getPaint, getRenderingHint, getRenderingHints, getStroke, getTransform, hit, rotate, rotate, scale, setBackground, setClip, setComposite, setFont, setFontRendering, setPaint, setPaintMode, setRenderingHint, setRenderingHints, setTransform, setXORMode, shear, transform, translate, translate
 
Methods inherited from class java.awt.Graphics2D
draw3DRect, fill3DRect
 
Methods inherited from class java.awt.Graphics
create, drawBytes, drawChars, drawPolygon, fillPolygon, finalize, getClipBounds, getClipRect, getFontMetrics, hitClip
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PDFGraphics2D

public PDFGraphics2D(double x,
                     double y,
                     double width,
                     double height)
Constructor that initializes a new PDFGraphics2D instance. The document dimension must be specified as parameters.

Method Detail

setStroke

public void setStroke(java.awt.Stroke s)
Overrides:
setStroke in class VectorGraphics2D

setColor

public void setColor(java.awt.Color c)
Overrides:
setColor in class VectorGraphics2D

setClip

public void setClip(java.awt.Shape clip)
Overrides:
setClip in class VectorGraphics2D

toString

public java.lang.String toString()
Overrides:
toString in class VectorGraphics2D

getBytes

public byte[] getBytes()
Description copied from class: VectorGraphics2D
Encodes the painted data into a sequence of bytes.

Overrides:
getBytes in class VectorGraphics2D
Returns:
A byte array containing the data in the current file format.


Copyright © 2010. All Rights Reserved.