Package de.intarsys.cwt.awt.environment

Examples of de.intarsys.cwt.awt.environment.CwtAwtGraphicsContext


        PDPage pdPage = pdfDoc.getPageTree().getPageAt(page - 1);
        Rectangle2D rect = pdPage.getCropBox().toNormalizedRectangle();

        retVal = new BufferedImage((int) rect.getWidth(), (int) rect.getHeight(), BufferedImage.TYPE_INT_RGB);
        Graphics2D g2 = (Graphics2D) retVal.getGraphics();
        graphics = new CwtAwtGraphicsContext(g2);
        // setup user space
        AffineTransform imgTransform = graphics.getTransform();
        imgTransform.scale(1, -1);
        imgTransform.translate(-rect.getMinX(), -rect.getMaxY());
        graphics.setTransform(imgTransform);
View Full Code Here


       
        int height = Math.round(((int) rect.getHeight())*(float)resizePercentage);
        int width = Math.round(((int) rect.getWidth())*(float)resizePercentage);
        BufferedImage imageInstance = new BufferedImage((int)recWidth, (int)rectHeight, BufferedImage.TYPE_INT_RGB);
        Graphics2D g2 = (Graphics2D) imageInstance.getGraphics();
        graphics = new CwtAwtGraphicsContext(g2);
        // setup user space
        AffineTransform imgTransform = graphics.getTransform();
        imgTransform.scale(1, -1);
        imgTransform.translate(-rect.getMinX(), -rect.getMaxY());
        graphics.setTransform(imgTransform);       
View Full Code Here

TOP

Related Classes of de.intarsys.cwt.awt.environment.CwtAwtGraphicsContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.