Class Java2DOutputDevice

java.lang.Object
com.openhtmltopdf.render.AbstractOutputDevice
com.openhtmltopdf.java2d.Java2DOutputDevice
All Implemented Interfaces:
com.openhtmltopdf.extend.OutputDevice

public class Java2DOutputDevice
extends com.openhtmltopdf.render.AbstractOutputDevice
implements com.openhtmltopdf.extend.OutputDevice
  • Constructor Details

    • Java2DOutputDevice

      public Java2DOutputDevice​(Graphics2D layoutGraphics)
  • Method Details

    • drawSelection

      @Deprecated public void drawSelection​(com.openhtmltopdf.render.RenderingContext c, com.openhtmltopdf.render.InlineText inlineText)
      Deprecated.
      Specified by:
      drawSelection in interface com.openhtmltopdf.extend.OutputDevice
    • drawBorderLine

      public void drawBorderLine​(Shape bounds, int side, int lineWidth, boolean solid)
      Specified by:
      drawBorderLine in interface com.openhtmltopdf.extend.OutputDevice
    • paintReplacedElement

      public void paintReplacedElement​(com.openhtmltopdf.render.RenderingContext c, com.openhtmltopdf.render.BlockBox box)
      Specified by:
      paintReplacedElement in interface com.openhtmltopdf.extend.OutputDevice
    • setColor

      public void setColor​(com.openhtmltopdf.css.parser.FSColor color)
      Specified by:
      setColor in interface com.openhtmltopdf.extend.OutputDevice
    • drawLine

      protected void drawLine​(int x1, int y1, int x2, int y2)
      Specified by:
      drawLine in class com.openhtmltopdf.render.AbstractOutputDevice
    • drawRect

      public void drawRect​(int x, int y, int width, int height)
      Specified by:
      drawRect in interface com.openhtmltopdf.extend.OutputDevice
    • fillRect

      public void fillRect​(int x, int y, int width, int height)
      Specified by:
      fillRect in interface com.openhtmltopdf.extend.OutputDevice
    • setClip

      @Deprecated public void setClip​(Shape s)
      Deprecated.
      Specified by:
      setClip in interface com.openhtmltopdf.extend.OutputDevice
    • getClip

      @Deprecated public Shape getClip()
      Deprecated.
      Specified by:
      getClip in interface com.openhtmltopdf.extend.OutputDevice
    • clip

      @Deprecated public void clip​(Shape s)
      Deprecated.
      Specified by:
      clip in interface com.openhtmltopdf.extend.OutputDevice
    • translate

      public void translate​(double tx, double ty)
      Specified by:
      translate in interface com.openhtmltopdf.extend.OutputDevice
    • getGraphics

      public Graphics2D getGraphics()
    • drawOval

      public void drawOval​(int x, int y, int width, int height)
      Specified by:
      drawOval in interface com.openhtmltopdf.extend.OutputDevice
    • fillOval

      public void fillOval​(int x, int y, int width, int height)
      Specified by:
      fillOval in interface com.openhtmltopdf.extend.OutputDevice
    • getRenderingHint

      public Object getRenderingHint​(RenderingHints.Key key)
      Specified by:
      getRenderingHint in interface com.openhtmltopdf.extend.OutputDevice
    • setRenderingHint

      public void setRenderingHint​(RenderingHints.Key key, Object value)
      Specified by:
      setRenderingHint in interface com.openhtmltopdf.extend.OutputDevice
    • setFont

      public void setFont​(com.openhtmltopdf.render.FSFont font)
      Specified by:
      setFont in interface com.openhtmltopdf.extend.OutputDevice
    • getFont

      public Java2DFont getFont()
    • setStroke

      public void setStroke​(Stroke s)
      Specified by:
      setStroke in interface com.openhtmltopdf.extend.OutputDevice
    • getStroke

      public Stroke getStroke()
      Specified by:
      getStroke in interface com.openhtmltopdf.extend.OutputDevice
    • fill

      public void fill​(Shape s)
      Specified by:
      fill in interface com.openhtmltopdf.extend.OutputDevice
    • draw

      public void draw​(Shape s)
      Specified by:
      draw in interface com.openhtmltopdf.extend.OutputDevice
    • drawImage

      public void drawImage​(com.openhtmltopdf.extend.FSImage image, int x, int y, boolean interpolate)
      Specified by:
      drawImage in interface com.openhtmltopdf.extend.OutputDevice
    • isSupportsSelection

      @Deprecated public boolean isSupportsSelection()
      Deprecated.
      Specified by:
      isSupportsSelection in interface com.openhtmltopdf.extend.OutputDevice
    • isSupportsCMYKColors

      public boolean isSupportsCMYKColors()
      Specified by:
      isSupportsCMYKColors in interface com.openhtmltopdf.extend.OutputDevice
    • drawWithGraphics

      public void drawWithGraphics​(float x, float y, float width, float height, com.openhtmltopdf.extend.OutputDeviceGraphicsDrawer renderer)
      Specified by:
      drawWithGraphics in interface com.openhtmltopdf.extend.OutputDevice
    • setPaint

      public void setPaint​(Paint paint)
      Specified by:
      setPaint in interface com.openhtmltopdf.extend.OutputDevice
    • pushTransforms

      @Deprecated public List<AffineTransform> pushTransforms​(List<AffineTransform> transforms)
      Deprecated.
      Specified by:
      pushTransforms in interface com.openhtmltopdf.extend.OutputDevice
    • popTransforms

      @Deprecated public void popTransforms​(List<AffineTransform> inverse)
      Deprecated.
      Specified by:
      popTransforms in interface com.openhtmltopdf.extend.OutputDevice
    • getAbsoluteTransformOriginX

      @Deprecated public float getAbsoluteTransformOriginX()
      Deprecated.
      Specified by:
      getAbsoluteTransformOriginX in interface com.openhtmltopdf.extend.OutputDevice
    • getAbsoluteTransformOriginY

      @Deprecated public float getAbsoluteTransformOriginY()
      Deprecated.
      Specified by:
      getAbsoluteTransformOriginY in interface com.openhtmltopdf.extend.OutputDevice
    • setBidiReorderer

      public void setBidiReorderer​(com.openhtmltopdf.bidi.BidiReorderer _reorderer)
    • setRenderingContext

      public void setRenderingContext​(com.openhtmltopdf.render.RenderingContext result)
    • setRoot

      public void setRoot​(com.openhtmltopdf.render.BlockBox _root)
    • initializePage

      public void initializePage​(Graphics2D pageGraphics)
    • finish

      public void finish​(com.openhtmltopdf.render.RenderingContext c, com.openhtmltopdf.render.BlockBox _root)
    • pushTransformLayer

      public void pushTransformLayer​(AffineTransform transform)
      Specified by:
      pushTransformLayer in interface com.openhtmltopdf.extend.OutputDevice
    • popTransformLayer

      public void popTransformLayer()
      Specified by:
      popTransformLayer in interface com.openhtmltopdf.extend.OutputDevice
    • popClip

      public void popClip()
      Specified by:
      popClip in interface com.openhtmltopdf.extend.OutputDevice
    • pushClip

      public void pushClip​(Shape s)
      Specified by:
      pushClip in interface com.openhtmltopdf.extend.OutputDevice
    • isFastRenderer

      public boolean isFastRenderer()
      Specified by:
      isFastRenderer in interface com.openhtmltopdf.extend.OutputDevice
    • startStructure

      public Object startStructure​(com.openhtmltopdf.extend.StructureType type, com.openhtmltopdf.render.Box box)
      Specified by:
      startStructure in interface com.openhtmltopdf.extend.OutputDevice
    • endStructure

      public void endStructure​(Object token)
      Specified by:
      endStructure in interface com.openhtmltopdf.extend.OutputDevice
    • drawLinearGradient

      public void drawLinearGradient​(com.openhtmltopdf.css.style.derived.FSLinearGradient lg, Shape bounds)
      Specified by:
      drawLinearGradient in interface com.openhtmltopdf.extend.OutputDevice