Package org.nanograph.components.swing

Examples of org.nanograph.components.swing.SwingGraphicsAdapter


        BufferedImage myImage = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
        Graphics2D g = myImage.createGraphics();
      g.setPaint(Color.WHITE);
      g.fillRect(0,0, width, height);
       
        SwingGraphicsAdapter sg = new SwingGraphicsAdapter(g);
        double scale = getScale(nanograph, sg);
        g.scale(scale, scale);       
        paintImage(sg);
        try {
            JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(out);
View Full Code Here

TOP

Related Classes of org.nanograph.components.swing.SwingGraphicsAdapter

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.