org.apache.fop.svg
Class PDFTextPainter
org.apache.fop.svg.PDFTextPainter
- public class PDFTextPainter
Renders the attributed character iterator of a TextNode.
- Version:
- $Id: PDFTextPainter.java,v 1.7.2.4 2003/02/25 15:08:11 jeremias Exp $
- Author:
- Keiron Liddle
Field Summary |
protected static org.apache.batik.gvt.TextPainter |
PROXY_PAINTER
Use the stroking text painter to get the bounds and shape. |
Method Summary |
java.awt.geom.Rectangle2D |
getBounds2D(org.apache.batik.gvt.TextNode node)
|
java.awt.geom.Rectangle2D |
getGeometryBounds(org.apache.batik.gvt.TextNode node)
|
java.awt.Shape |
getHighlightShape(org.apache.batik.gvt.text.Mark beginMark,
org.apache.batik.gvt.text.Mark endMark)
|
org.apache.batik.gvt.text.Mark |
getMark(org.apache.batik.gvt.TextNode node,
int pos,
boolean all)
|
java.awt.Shape |
getOutline(org.apache.batik.gvt.TextNode node)
|
int[] |
getSelected(org.apache.batik.gvt.text.Mark start,
org.apache.batik.gvt.text.Mark finish)
|
float |
getStringWidth(java.lang.String str)
|
protected java.lang.String |
getText(java.text.AttributedCharacterIterator aci)
|
void |
paint(org.apache.batik.gvt.TextNode node,
java.awt.Graphics2D g2d)
Paints the specified attributed character iterator using the
specified Graphics2D and context and font context. |
protected java.awt.geom.Point2D |
paintACI(java.text.AttributedCharacterIterator aci,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
|
protected java.awt.geom.Point2D |
paintTextRun(org.apache.batik.gvt.renderer.StrokingTextPainter.TextRun run,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
|
protected void |
paintTextRuns(java.util.List textRuns,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
|
org.apache.batik.gvt.text.Mark |
selectAll(double x,
double y,
org.apache.batik.gvt.TextNode node)
|
org.apache.batik.gvt.text.Mark |
selectAt(double x,
double y,
org.apache.batik.gvt.TextNode node)
|
org.apache.batik.gvt.text.Mark |
selectFirst(org.apache.batik.gvt.TextNode node)
|
org.apache.batik.gvt.text.Mark |
selectLast(org.apache.batik.gvt.TextNode node)
|
org.apache.batik.gvt.text.Mark |
selectTo(double x,
double y,
org.apache.batik.gvt.text.Mark beginMark)
|
PROXY_PAINTER
protected static final org.apache.batik.gvt.TextPainter PROXY_PAINTER
- Use the stroking text painter to get the bounds and shape.
Also used as a fallback to draw the string with strokes.
PDFTextPainter
public PDFTextPainter(FontState fs)
paint
public void paint(org.apache.batik.gvt.TextNode node,
java.awt.Graphics2D g2d)
- Paints the specified attributed character iterator using the
specified Graphics2D and context and font context.
- Parameters:
node
- the TextNode to paintg2d
- the Graphics2D to usecontext
- the rendering context.
paintTextRuns
protected void paintTextRuns(java.util.List textRuns,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
paintTextRun
protected java.awt.geom.Point2D paintTextRun(org.apache.batik.gvt.renderer.StrokingTextPainter.TextRun run,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
getText
protected java.lang.String getText(java.text.AttributedCharacterIterator aci)
paintACI
protected java.awt.geom.Point2D paintACI(java.text.AttributedCharacterIterator aci,
java.awt.Graphics2D g2d,
java.awt.geom.Point2D loc)
getStringWidth
public float getStringWidth(java.lang.String str)
getMark
public org.apache.batik.gvt.text.Mark getMark(org.apache.batik.gvt.TextNode node,
int pos,
boolean all)
selectAt
public org.apache.batik.gvt.text.Mark selectAt(double x,
double y,
org.apache.batik.gvt.TextNode node)
selectTo
public org.apache.batik.gvt.text.Mark selectTo(double x,
double y,
org.apache.batik.gvt.text.Mark beginMark)
selectAll
public org.apache.batik.gvt.text.Mark selectAll(double x,
double y,
org.apache.batik.gvt.TextNode node)
selectFirst
public org.apache.batik.gvt.text.Mark selectFirst(org.apache.batik.gvt.TextNode node)
selectLast
public org.apache.batik.gvt.text.Mark selectLast(org.apache.batik.gvt.TextNode node)
getSelected
public int[] getSelected(org.apache.batik.gvt.text.Mark start,
org.apache.batik.gvt.text.Mark finish)
getHighlightShape
public java.awt.Shape getHighlightShape(org.apache.batik.gvt.text.Mark beginMark,
org.apache.batik.gvt.text.Mark endMark)
getBounds2D
public java.awt.geom.Rectangle2D getBounds2D(org.apache.batik.gvt.TextNode node)
getGeometryBounds
public java.awt.geom.Rectangle2D getGeometryBounds(org.apache.batik.gvt.TextNode node)
getOutline
public java.awt.Shape getOutline(org.apache.batik.gvt.TextNode node)
Copyright ? 1999-2003 Apache Software Foundation. All Rights Reserved.