Class ImageUtil

java.lang.Object
com.github.weisj.darklaf.util.ImageUtil

public final class ImageUtil extends Object
  • Method Details

    • imageFromComponent

      public static ScaledImage imageFromComponent(Component c)
      Create image from component.
      Parameters:
      c - the component.
      Returns:
      image of the component.
    • imageFromComponent

      public static ScaledImage imageFromComponent(Component c, Rectangle bounds)
      Create image from component.
      Parameters:
      c - the component.
      bounds - the bounds inside the component to capture.
      Returns:
      image containing the captured area.
    • imageFromComponent

      public static ScaledImage imageFromComponent(Component c, Rectangle bounds, boolean print)
      Create image from component.
      Parameters:
      c - the component.
      bounds - the bounds inside the component to capture.
      Returns:
      image containing the captured area.
    • scaledImageFromComponent

      public static ScaledImage scaledImageFromComponent(Component c)
      Create image from component.
      Parameters:
      c - the component.
      Returns:
      image of the component.
    • scaledImageFromComponent

      public static ScaledImage scaledImageFromComponent(Component c, Rectangle bounds)
      Create image from component.
      Parameters:
      c - the component.
      bounds - the bounds inside the component to capture.
      Returns:
      image containing the captured area.
    • scaledImageFromComponent

      public static ScaledImage scaledImageFromComponent(Component c, Rectangle bounds, boolean print)
      Create image from component.
      Parameters:
      c - the component.
      bounds - the bounds inside the component to capture.
      print - whether the component should be painted in printing mode or not.
      Returns:
      image containing the captured area.
    • scaledImageFromComponent

      public static ScaledImage scaledImageFromComponent(Component c, Rectangle bounds, double scalex, double scaley, boolean print)
      Create image from component.
      Parameters:
      c - the component.
      bounds - the bounds inside the component to capture.
      scalex - the x scale
      scaley - the y scale
      Returns:
      image containing the captured area.
    • createCompatibleImage

      public static BufferedImage createCompatibleImage(GraphicsConfiguration gc, int width, int height)
    • createCompatibleImage

      public static BufferedImage createCompatibleImage(int width, int height)
    • createCompatibleTransparentImage

      public static BufferedImage createCompatibleTransparentImage(GraphicsConfiguration gc, int width, int height)
    • createCompatibleTransparentImage

      public static BufferedImage createCompatibleTransparentImage(int width, int height)
    • createCompatibleTranslucentImage

      public static BufferedImage createCompatibleTranslucentImage(GraphicsConfiguration gc, int width, int height)
    • createCompatibleTranslucentImage

      public static BufferedImage createCompatibleTranslucentImage(int width, int height)