Package megamek.client.ui

Examples of megamek.client.ui.IDisplayable.draw()


        }

        // draw all the "displayables"
        for (int i = 0; i < displayables.size(); i++) {
            IDisplayable disp = displayables.get(i);
            disp.draw(backGraph, new Point(backSize.width, backSize.height), backSize);
        }

        // draw the back buffer onto the screen
        // first clear the entire view if the map has been zoomed
        if (scale < 1.00f) {
View Full Code Here


            IDisplayable disp = displayables.get(i);
            double width = Math.min(boardSize.getWidth(), scrollpane.getViewport().getSize().getWidth());
            double height = Math.min(boardSize.getHeight(), scrollpane.getViewport().getSize().getHeight());
            Dimension drawDimension = new Dimension();
            drawDimension.setSize(width, height);
            disp.draw(g,
                    new Point((int)Math.min(boardSize.getWidth(), -getBounds().getX()),
                            (int)Math.min(boardSize.getHeight(),-getBounds().getY())),
                            drawDimension);
        }
    }
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.