Class SWTOutputDevice

All Implemented Interfaces:
OutputDevice

@NullUnmarked public class SWTOutputDevice extends AbstractOutputDevice
Implementation of OutputDevice for SWT.
  • Field Details

    • _gc

      private final org.eclipse.swt.graphics.GC _gc
    • _clippingPath

      private org.eclipse.swt.graphics.Path _clippingPath
    • _clippingArea

      private Area _clippingArea
    • _color

      private org.eclipse.swt.graphics.Color _color
    • _awt_color

      private Color _awt_color
    • _transform

      private org.eclipse.swt.graphics.Transform _transform
    • _stroke

      private Stroke _stroke
  • Constructor Details

    • SWTOutputDevice

      public SWTOutputDevice(org.eclipse.swt.graphics.GC gc)
  • Method Details

    • getGC

      public org.eclipse.swt.graphics.GC getGC()
      Returns:
      the Graphical Context associated with this OutputDevice
    • clean

      public void clean()
      Clean used resources.
    • clip

      public void clip(Shape s)
    • setClip

      public void setClip(Shape s)
    • getClip

      @CheckReturnValue public @Nullable Shape getClip()
    • drawLine

      protected void drawLine(int x1, int y1, int x2, int y2)
      Specified by:
      drawLine in class AbstractOutputDevice
    • drawBorderLine

      public void drawBorderLine(Shape bounds, int side, int lineWidth, boolean solid)
    • drawImage

      public void drawImage(FSImage image, int x, int y)
    • drawOval

      public void drawOval(int x, int y, int width, int height)
    • drawRect

      public void drawRect(int x, int y, int width, int height)
    • draw

      public void draw(Shape s)
    • fill

      public void fill(Shape s)
    • fillOval

      public void fillOval(int x, int y, int width, int height)
    • fillRect

      public void fillRect(int x, int y, int width, int height)
    • paintReplacedElement

      public void paintReplacedElement(RenderingContext c, BlockBox box)
    • setColor

      public void setColor(Color color)
    • setFont

      public void setFont(FSFont font)
    • setColor

      public void setColor(FSColor color)
    • getStroke

      public Stroke getStroke()
    • setStroke

      public void setStroke(Stroke s)
    • translate

      public void translate(double tx, double ty)
    • getRenderingHint

      @CheckReturnValue public @Nullable Object getRenderingHint(@NonNull RenderingHints.Key key)
    • setRenderingHint

      @NullMarked public void setRenderingHint(RenderingHints.Key key, Object value)
    • convertToPath

      private @Nullable org.eclipse.swt.graphics.Path convertToPath(Shape shape)
      Convert an AWT Shape to an SWT Path.
      Returns:
      the SWT Path or null if shape == null
    • drawSelection

      public void drawSelection(RenderingContext c, InlineText inlineText)
    • isSupportsSelection

      public boolean isSupportsSelection()
    • isSupportsCMYKColors

      public boolean isSupportsCMYKColors()