Package org.xhtmlrenderer.swing
Class Java2DOutputDevice
- java.lang.Object
-
- org.xhtmlrenderer.render.AbstractOutputDevice
-
- org.xhtmlrenderer.swing.Java2DOutputDevice
-
- All Implemented Interfaces:
OutputDevice
public class Java2DOutputDevice extends AbstractOutputDevice implements OutputDevice
-
-
Constructor Summary
Constructors Constructor Description Java2DOutputDevice(Graphics2D graphics)Java2DOutputDevice(BufferedImage outputImage)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclip(Shape s)voiddraw(Shape s)voiddrawBorderLine(Shape bounds, int side, int lineWidth, boolean solid)voiddrawImage(FSImage image, int x, int y)protected voiddrawLine(int x1, int y1, int x2, int y2)voiddrawOval(int x, int y, int width, int height)voiddrawRect(int x, int y, int width, int height)voiddrawSelection(RenderingContext c, InlineText inlineText)voidfill(Shape s)voidfillOval(int x, int y, int width, int height)voidfillRect(int x, int y, int width, int height)ShapegetClip()Graphics2DgetGraphics()ObjectgetRenderingHint(RenderingHints.Key key)StrokegetStroke()booleanisSupportsCMYKColors()booleanisSupportsSelection()voidpaintReplacedElement(RenderingContext c, BlockBox box)voidsetClip(Shape s)voidsetColor(FSColor color)voidsetFont(FSFont font)voidsetRenderingHint(RenderingHints.Key key, Object value)voidsetStroke(Stroke s)voidtranslate(double tx, double ty)-
Methods inherited from class org.xhtmlrenderer.render.AbstractOutputDevice
drawDebugOutline, drawText, drawTextDecoration, drawTextDecoration, getFontSpecification, paintBackground, paintBackground, paintBorder, paintBorder, paintCollapsedBorder, setFontSpecification
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.xhtmlrenderer.extend.OutputDevice
drawDebugOutline, drawText, drawTextDecoration, drawTextDecoration, paintBackground, paintBackground, paintBorder, paintBorder, paintCollapsedBorder
-
-
-
-
Constructor Detail
-
Java2DOutputDevice
public Java2DOutputDevice(Graphics2D graphics)
-
Java2DOutputDevice
public Java2DOutputDevice(BufferedImage outputImage)
-
-
Method Detail
-
drawSelection
public void drawSelection(RenderingContext c, InlineText inlineText)
- Specified by:
drawSelectionin interfaceOutputDevice
-
drawBorderLine
public void drawBorderLine(Shape bounds, int side, int lineWidth, boolean solid)
- Specified by:
drawBorderLinein interfaceOutputDevice
-
paintReplacedElement
public void paintReplacedElement(RenderingContext c, BlockBox box)
- Specified by:
paintReplacedElementin interfaceOutputDevice
-
setColor
public void setColor(FSColor color)
- Specified by:
setColorin interfaceOutputDevice
-
drawLine
protected void drawLine(int x1, int y1, int x2, int y2)- Specified by:
drawLinein classAbstractOutputDevice
-
drawRect
public void drawRect(int x, int y, int width, int height)- Specified by:
drawRectin interfaceOutputDevice
-
fillRect
public void fillRect(int x, int y, int width, int height)- Specified by:
fillRectin interfaceOutputDevice
-
setClip
public void setClip(Shape s)
- Specified by:
setClipin interfaceOutputDevice
-
getClip
public Shape getClip()
- Specified by:
getClipin interfaceOutputDevice
-
clip
public void clip(Shape s)
- Specified by:
clipin interfaceOutputDevice
-
translate
public void translate(double tx, double ty)- Specified by:
translatein interfaceOutputDevice
-
getGraphics
public Graphics2D getGraphics()
-
drawOval
public void drawOval(int x, int y, int width, int height)- Specified by:
drawOvalin interfaceOutputDevice
-
fillOval
public void fillOval(int x, int y, int width, int height)- Specified by:
fillOvalin interfaceOutputDevice
-
getRenderingHint
public Object getRenderingHint(RenderingHints.Key key)
- Specified by:
getRenderingHintin interfaceOutputDevice
-
setRenderingHint
public void setRenderingHint(RenderingHints.Key key, Object value)
- Specified by:
setRenderingHintin interfaceOutputDevice
-
setFont
public void setFont(FSFont font)
- Specified by:
setFontin interfaceOutputDevice
-
setStroke
public void setStroke(Stroke s)
- Specified by:
setStrokein interfaceOutputDevice
-
getStroke
public Stroke getStroke()
- Specified by:
getStrokein interfaceOutputDevice
-
fill
public void fill(Shape s)
- Specified by:
fillin interfaceOutputDevice
-
draw
public void draw(Shape s)
- Specified by:
drawin interfaceOutputDevice
-
drawImage
public void drawImage(FSImage image, int x, int y)
- Specified by:
drawImagein interfaceOutputDevice
-
isSupportsSelection
public boolean isSupportsSelection()
- Specified by:
isSupportsSelectionin interfaceOutputDevice
-
isSupportsCMYKColors
public boolean isSupportsCMYKColors()
- Specified by:
isSupportsCMYKColorsin interfaceOutputDevice
-
-