
org.apache.fop.svg
Class PDFTextPainter
java.lang.Object
org.apache.fop.svg.PDFTextPainter
- All Implemented Interfaces:
- org.apache.batik.gvt.TextPainter
- public class PDFTextPainter
- extends java.lang.Object
- implements org.apache.batik.gvt.TextPainter
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)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
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.
- Specified by:
paint in interface org.apache.batik.gvt.TextPainter
- Parameters:
node - the TextNode to paintg2d - the Graphics2D to use
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)
- Specified by:
getMark in interface org.apache.batik.gvt.TextPainter
selectAt
public org.apache.batik.gvt.text.Mark selectAt(double x,
double y,
org.apache.batik.gvt.TextNode node)
- Specified by:
selectAt in interface org.apache.batik.gvt.TextPainter
selectTo
public org.apache.batik.gvt.text.Mark selectTo(double x,
double y,
org.apache.batik.gvt.text.Mark beginMark)
- Specified by:
selectTo in interface org.apache.batik.gvt.TextPainter
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)
- Specified by:
selectFirst in interface org.apache.batik.gvt.TextPainter
selectLast
public org.apache.batik.gvt.text.Mark selectLast(org.apache.batik.gvt.TextNode node)
- Specified by:
selectLast in interface org.apache.batik.gvt.TextPainter
getSelected
public int[] getSelected(org.apache.batik.gvt.text.Mark start,
org.apache.batik.gvt.text.Mark finish)
- Specified by:
getSelected in interface org.apache.batik.gvt.TextPainter
getHighlightShape
public java.awt.Shape getHighlightShape(org.apache.batik.gvt.text.Mark beginMark,
org.apache.batik.gvt.text.Mark endMark)
- Specified by:
getHighlightShape in interface org.apache.batik.gvt.TextPainter
getBounds2D
public java.awt.geom.Rectangle2D getBounds2D(org.apache.batik.gvt.TextNode node)
- Specified by:
getBounds2D in interface org.apache.batik.gvt.TextPainter
getGeometryBounds
public java.awt.geom.Rectangle2D getGeometryBounds(org.apache.batik.gvt.TextNode node)
- Specified by:
getGeometryBounds in interface org.apache.batik.gvt.TextPainter
getOutline
public java.awt.Shape getOutline(org.apache.batik.gvt.TextNode node)
- Specified by:
getOutline in interface org.apache.batik.gvt.TextPainter
Copyright © 1999-2004 Apache XML Project. All Rights Reserved.
Stylus Studio's advanced XSL:FO editor features integrated development support for Apache FOP.