Class ExampleImageHandler

  • All Implemented Interfaces:

    public class ExampleImageHandler
    extends Object
    implements org.jpedal.external.ImageHandler
    example of adding in custom image code , replacing code with a blank image of correct size
    • Constructor Detail

      • ExampleImageHandler

        public ExampleImageHandler()
    • Method Detail

      • alwaysIgnoreGenericHandler

        public boolean alwaysIgnoreGenericHandler()
        Specified by:
        alwaysIgnoreGenericHandler in interface org.jpedal.external.ImageHandler
      • imageHasBeenScaled

        public boolean imageHasBeenScaled()
        tells JPedal not to scale image
        Specified by:
        imageHasBeenScaled in interface org.jpedal.external.ImageHandler
      • drawImageOnscreen

        public boolean drawImageOnscreen​(BufferedImage image,
                                         int optionsApplied,
                                         AffineTransform upside_down,
                                         String currentImageFile,
                                         Graphics2D g2,
                                         boolean renderDirect,
                                         boolean isPrinting)
        Description copied from interface: org.jpedal.external.ImageHandler
        Allow user to paint directly onto g2 for screen display
        Specified by:
        drawImageOnscreen in interface org.jpedal.external.ImageHandler
        image - - actual BufferedImage
        optionsApplied - - any options already done (ie 90 rotate) - values from org.jpedal.constants.PDFImageProcessing
        upside_down - - AffineTransform applied to page
        currentImageFile - - name of file stored on disk
        g2 - - Graphics2D render object
        renderDirect - -if being rendered straight to g2 (ie bufferedImage)
        objectStore - - JPedals class to access cached images
        true to ignore standard JPedal routines and false to use.
      • processImageData

        public BufferedImage processImageData​(org.jpedal.objects.GraphicsState gs,
                                              org.jpedal.objects.raw.PdfObject XObject)
        Specified by:
        processImageData in interface org.jpedal.external.ImageHandler