Package edu.uci.ics.jung.visualization.transform

Examples of edu.uci.ics.jung.visualization.transform.MutableTransformer.rotate()


            Point2D q = down;
            Point2D p = e.getPoint();
            Point2D v1 = new Point2D.Double(center.getX()-p.getX(), center.getY()-p.getY());
            Point2D v2 = new Point2D.Double(center.getX()-q.getX(), center.getY()-q.getY());
            double theta = angleBetween(v1, v2);
            modelTransformer.rotate(theta, vv.getRenderContext().getMultiLayerTransformer().inverseTransform(Layer.VIEW, center));
            down.x = e.getX();
            down.y = e.getY();
       
            e.consume();
        }
View Full Code Here


                Point2D q = down;
                Point2D p = e.getPoint();
                Point2D v1 = new Point2D.Double(center.getX()-p.getX(), center.getY()-p.getY());
                Point2D v2 = new Point2D.Double(center.getX()-q.getX(), center.getY()-q.getY());
                double theta = angleBetween(v1, v2);
                modelTransformerMaster.rotate(-theta,
                        vvMaster.getRenderContext().getMultiLayerTransformer().inverseTransform(Layer.VIEW, vvMaster.getCenter()));
                down.x = e.getX();
                down.y = e.getY();
            }
            e.consume();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.