Package org.apache.fop.afp.svg
Class AFPTextHandler
java.lang.Object
org.apache.xmlgraphics.java2d.StrokingTextHandler
org.apache.fop.svg.FOPTextHandlerAdapter
org.apache.fop.afp.svg.AFPTextHandler
- All Implemented Interfaces:
FOPTextHandler
,org.apache.xmlgraphics.java2d.TextHandler
Specialized TextHandler implementation that the AFPGraphics2D class delegates to to paint text
using AFP GOCA text operations.
-
Field Summary
-
Constructor Summary
ConstructorDescriptionAFPTextHandler
(FontInfo fontInfo, AFPResourceManager resourceManager) Main constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
drawString
(Graphics2D g, String str, float x, float y) Add a text string to the current data object of the AFP datastream.Return the font information associated with this objectvoid
setOverrideFont
(Font overrideFont) Sets the overriding font.
-
Field Details
-
overrideFont
Overriding FontState
-
-
Constructor Details
-
AFPTextHandler
Main constructor.- Parameters:
fontInfo
- the AFPGraphics2D instanceresourceManager
- the AFPResourceManager instance
-
-
Method Details
-
getFontInfo
Return the font information associated with this object- Returns:
- the FontInfo object
-
drawString
Add a text string to the current data object of the AFP datastream. The text is painted using text operations.- Specified by:
drawString
in interfaceorg.apache.xmlgraphics.java2d.TextHandler
- Overrides:
drawString
in classorg.apache.xmlgraphics.java2d.StrokingTextHandler
-
setOverrideFont
Sets the overriding font.- Parameters:
overrideFont
- Overriding Font to set
-