Interface IImagePainter


  • public interface IImagePainter
    The ImagePainter converts rendering data into images in view e.g. for integration into .docx exports.
    • Method Detail

      • prepareImage

        void prepareImage​(int width,
                          int height,
                          float dpi)
        Invoked before starting to draw an image. This call is meant to enable preparation of the image destination in memory (e.g. memory allocation).
        Parameters:
        width - the image width.
        height - the image height.
        dpi - the resolution of the image in dots per inch.
      • saveImage

        void saveImage​(@NotNull
                       @NotNull java.lang.String path)
                throws java.io.IOException
        Invoked once image drawing is over. Requests saving the image to disk.
        Parameters:
        path - the image destination.
        Throws:
        java.io.IOException - when an I/O operation fails.
      • createCanvas

        ICanvas createCanvas()
        Creates a canvas to draw the image.
        Returns:
        a canvas to draw the image.
        Since:
        2.0