com.lowagie.text.pdf.codec.postscript
Class PAPencil

java.lang.Object
  extended bycom.lowagie.text.pdf.codec.postscript.PAPencil

public class PAPencil
extends Object


Nested Class Summary
protected static class PAPencil.State
           
 
Field Summary
protected  HashMap fonts
          The font hashtable with postscript names as keys
 Graphics2D graphics
          The current graphics device
protected  Stack gStack
          The stack of graphic states.
protected  Dimension size
          The canvas size.
protected  PAPencil.State state
          The current graphics state.
 
Constructor Summary
PAPencil(Component component)
           
PAPencil(Graphics graphics, Dimension size)
           
 
Method Summary
 void arc(double cx, double cy, double r, double ang1, double ang2)
           
 void arcn(double cx, double cy, double r, double ang1, double ang2)
           
 void charpath(String aString, boolean adjustForStroking)
           
 void clip()
           
 void clippath()
           
 void closepath()
           
 void curveto(double x1, double y1, double x2, double y2, double x3, double y3)
           
 void eofill()
           
 void erasepage()
           
 void fill()
           
 Font findFont(String fontname)
           
 void grestore()
           
 void grestoreall()
           
 void gsave()
           
 void initgraphics()
           
 void lineto(double x, double y)
           
 void lineto(Point2D p)
           
 void moveto(double x, double y)
           
 void moveto(Point2D p)
           
 void newpath()
           
 void rcurveto(double dx1, double dy1, double dx2, double dy2, double dx3, double dy3)
           
 void rectfill(double x, double y, double width, double height)
           
 void rectfill(Rectangle2D rect)
           
 void rectpath(double x, double y, double width, double height)
           
 void rectstroke(double x, double y, double width, double height)
           
 void rectstroke(Rectangle2D rect)
           
 void rlineto(double dx, double dy)
           
 void rmoveto(double dx, double dy)
           
 void show(String string)
           
 void showpage()
           
 void stroke()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

size

protected Dimension size
The canvas size.


state

protected PAPencil.State state
The current graphics state.


gStack

protected Stack gStack
The stack of graphic states.


fonts

protected HashMap fonts
The font hashtable with postscript names as keys


graphics

public Graphics2D graphics
The current graphics device

Constructor Detail

PAPencil

public PAPencil(Component component)

PAPencil

public PAPencil(Graphics graphics,
                Dimension size)
Method Detail

gsave

public void gsave()

grestore

public void grestore()

grestoreall

public void grestoreall()

initgraphics

public void initgraphics()

newpath

public void newpath()

moveto

public void moveto(double x,
                   double y)

moveto

public void moveto(Point2D p)

rmoveto

public void rmoveto(double dx,
                    double dy)
             throws PainterException
Throws:
PainterException

lineto

public void lineto(double x,
                   double y)
            throws PainterException
Throws:
PainterException

lineto

public void lineto(Point2D p)
            throws PainterException
Throws:
PainterException

rlineto

public void rlineto(double dx,
                    double dy)
             throws PainterException
Throws:
PainterException

arc

public void arc(double cx,
                double cy,
                double r,
                double ang1,
                double ang2)
Parameters:
cx - double Centerpoint x
cy - double Centerpoint y
r - double Radius r
ang1 - double first angle
ang2 - double second angle

arcn

public void arcn(double cx,
                 double cy,
                 double r,
                 double ang1,
                 double ang2)

curveto

public void curveto(double x1,
                    double y1,
                    double x2,
                    double y2,
                    double x3,
                    double y3)
             throws PainterException
Throws:
PainterException

rcurveto

public void rcurveto(double dx1,
                     double dy1,
                     double dx2,
                     double dy2,
                     double dx3,
                     double dy3)
              throws PainterException
Throws:
PainterException

closepath

public void closepath()

clippath

public void clippath()

clip

public void clip()

erasepage

public void erasepage()

charpath

public void charpath(String aString,
                     boolean adjustForStroking)

showpage

public void showpage()

show

public void show(String string)
          throws PainterException
Throws:
PainterException

fill

public void fill()

eofill

public void eofill()

stroke

public void stroke()

rectfill

public void rectfill(double x,
                     double y,
                     double width,
                     double height)

rectfill

public void rectfill(Rectangle2D rect)

rectstroke

public void rectstroke(double x,
                       double y,
                       double width,
                       double height)

rectstroke

public void rectstroke(Rectangle2D rect)

rectpath

public void rectpath(double x,
                     double y,
                     double width,
                     double height)

findFont

public Font findFont(String fontname)