Package org.locationtech.udig.ui.graphics

Examples of org.locationtech.udig.ui.graphics.ViewportGraphics.drawLine()


               
                //ticks along top and bottom
                if (j == 0) {
                    //draw top-most ticks
                    graphics.drawLine(thisPixel.x,
                            EDGE_WIDTH,
                            thisPixel.x,
                            EDGE_WIDTH + TICK_WIDTH);
                   
                    //draw bottom-most ticks
View Full Code Here


                            EDGE_WIDTH,
                            thisPixel.x,
                            EDGE_WIDTH + TICK_WIDTH);
                   
                    //draw bottom-most ticks
                    graphics.drawLine(thisPixel.x,
                            mapPixelHeight - EDGE_WIDTH,
                            thisPixel.x,
                            mapPixelHeight - EDGE_WIDTH - TICK_WIDTH);
                   
                }
View Full Code Here

                   
                }

                //draw crosses
                graphics.setColor(Color.YELLOW);
                graphics.drawLine(thisPixel.x - TICK_WIDTH/2,
                        thisPixel.y,
                        thisPixel.x + TICK_WIDTH/2,
                        thisPixel.y);
               
                graphics.drawLine(thisPixel.x,
View Full Code Here

                graphics.drawLine(thisPixel.x - TICK_WIDTH/2,
                        thisPixel.y,
                        thisPixel.x + TICK_WIDTH/2,
                        thisPixel.y);
               
                graphics.drawLine(thisPixel.x,
                        thisPixel.y - TICK_WIDTH/2,
                        thisPixel.x,
                        thisPixel.y + TICK_WIDTH/2);
            }
        } //end crosses and ticks
View Full Code Here

                0,
                mapPixelWidth-1,
                mapPixelHeight-1);
       
        //inner outline, extends to edges       
        graphics.drawLine(0, EDGE_WIDTH, mapPixelWidth, EDGE_WIDTH); //top
        graphics.drawLine(mapPixelWidth - EDGE_WIDTH, 0, mapPixelWidth - EDGE_WIDTH, mapPixelHeight); //right
        graphics.drawLine(0, mapPixelHeight - EDGE_WIDTH, mapPixelWidth, mapPixelHeight - EDGE_WIDTH); //bottom
        graphics.drawLine(EDGE_WIDTH, 0, EDGE_WIDTH, mapPixelHeight)//left

View Full Code Here

                mapPixelWidth-1,
                mapPixelHeight-1);
       
        //inner outline, extends to edges       
        graphics.drawLine(0, EDGE_WIDTH, mapPixelWidth, EDGE_WIDTH); //top
        graphics.drawLine(mapPixelWidth - EDGE_WIDTH, 0, mapPixelWidth - EDGE_WIDTH, mapPixelHeight); //right
        graphics.drawLine(0, mapPixelHeight - EDGE_WIDTH, mapPixelWidth, mapPixelHeight - EDGE_WIDTH); //bottom
        graphics.drawLine(EDGE_WIDTH, 0, EDGE_WIDTH, mapPixelHeight)//left


        //bottom left corner
View Full Code Here

                mapPixelHeight-1);
       
        //inner outline, extends to edges       
        graphics.drawLine(0, EDGE_WIDTH, mapPixelWidth, EDGE_WIDTH); //top
        graphics.drawLine(mapPixelWidth - EDGE_WIDTH, 0, mapPixelWidth - EDGE_WIDTH, mapPixelHeight); //right
        graphics.drawLine(0, mapPixelHeight - EDGE_WIDTH, mapPixelWidth, mapPixelHeight - EDGE_WIDTH); //bottom
        graphics.drawLine(EDGE_WIDTH, 0, EDGE_WIDTH, mapPixelHeight)//left


        //bottom left corner
        AffineTransform bottomleftTrans = graphics.getTransform();
View Full Code Here

       
        //inner outline, extends to edges       
        graphics.drawLine(0, EDGE_WIDTH, mapPixelWidth, EDGE_WIDTH); //top
        graphics.drawLine(mapPixelWidth - EDGE_WIDTH, 0, mapPixelWidth - EDGE_WIDTH, mapPixelHeight); //right
        graphics.drawLine(0, mapPixelHeight - EDGE_WIDTH, mapPixelWidth, mapPixelHeight - EDGE_WIDTH); //bottom
        graphics.drawLine(EDGE_WIDTH, 0, EDGE_WIDTH, mapPixelHeight)//left


        //bottom left corner
        AffineTransform bottomleftTrans = graphics.getTransform();
        bottomleftTrans.translate(0, mapPixelHeight - EDGE_WIDTH*2);
 
View Full Code Here

            if( (pixel.x>=mapPixelWidth && pixel.y>=mapPixelHeight) )
                break;
           
            //draw vertical lines and labels
            if( pixel.x<mapPixelWidth)
                graphics.drawLine(pixel.x,
                                  0,
                                  pixel.x,
                                  mapPixelHeight - BOTTOM_STRIP_HEIGHT + GRID_LINE_EXTENSION);
                if (showLabels) {
                    graphics.drawString((int)(coord.y)+"",
View Full Code Here

                                    ViewportGraphics.ALIGN_TOP);
                }
           
            //draw horizontal lines and labels
            if( pixel.y<mapPixelHeight)
                graphics.drawLine(0,
                                  pixel.y,
                                  mapPixelWidth - RIGHT_STRIP_WIDTH + GRID_LINE_EXTENSION,
                                  pixel.y);
                if (showLabels) {
                    graphics.drawString((int)(coord.x)+"",
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.