Package org.locationtech.udig.project.ui

Examples of org.locationtech.udig.project.ui.BoundsStrategy


        buffered.getGraphics().draw3DRect(1,1,size.width-3,size.height-3,false);
       
        if (map2 != null) {
            ReferencedEnvelope world = map2.getBounds(new NullProgressMonitor());
            DrawMapParameter toDraw = new DrawMapParameter(buffered.createGraphics(),
                    new Dimension(size.width, size.height), map2, new BoundsStrategy(world),
                    dpi[0], SelectionStyle.IGNORE, monitor, true, false);
            ApplicationGIS.drawMap(toDraw);
        }
        getDisplay().syncExec(new Runnable(){
            public void run() {
View Full Code Here


            pattern = Messages.ExportMapToImageWizard_renderingTaskname;
            args = new Object[]{map.getName()};
            monitor.setTaskName(MessageFormat.format(pattern, args));
           
            int scaleDenom = MapSelectorPageWithScaleColumn.getScaleDenom(map);
            BoundsStrategy boundsStrategy = new BoundsStrategy(scaleDenom);
           
            //final Map mapCopy = (Map) EcoreUtil.copy((EObject) map);
            final Map mapCopy = (Map) ApplicationGIS.copyMap(map);
            List<Layer> layersInternal = mapCopy.getLayersInternal();           
            List<Layer> mapGraphics = prepareMapGraphics(mapCopy, contentDim, monitor);
View Full Code Here

      monitor.worked(1);
      pattern = Messages.ExportMapToImageWizard_renderingTaskname;
      args = new Object[]{map.getName()};
      monitor.setTaskName(MessageFormat.format(pattern, args));
      int scaleDenom = MapSelectorPageWithScaleColumn.getScaleDenom(map);
      BoundsStrategy boundsStrategy = new BoundsStrategy(scaleDenom);
     
      //final Map mapCopy = (Map) EcoreUtil.copy((EObject) map);
      final Map mapCopy = (Map) ApplicationGIS.copyMap(map);
       
      DrawMapParameter drawMapParameter =
View Full Code Here

            monitor.worked(2);
            pattern = Messages.ExportMapToImageWizard_renderingTaskname;
            args = new Object[]{map.getName()};
            monitor.setTaskName(MessageFormat.format(pattern, args));
            int scaleDenom = MapSelectorPageWithScaleColumn.getScaleDenom(map);
            BoundsStrategy boundsStrategy = new BoundsStrategy(scaleDenom);

            DrawMapParameter drawMapParameter = new DrawMapParameter(g, new java.awt.Dimension(
                    width, height), map, boundsStrategy, imageSettingsPage.getFormat().getDPI(),
                    imageSettingsPage.getSelectionHandling(), monitor);
View Full Code Here

            if (scaleDenom == -1) {
                //ApplicationGIS.drawMap(new DrawMapParameter(graphics, awtSize, getMap(), monitor, true));
                modifiedMap = ApplicationGIS.drawMap(new DrawMapParameter(graphics, awtSize, getMap(), null /*use current scale*/, 90, selectionStyle, monitor, true, true));
            }
            else {
                BoundsStrategy boundsStrategy = new BoundsStrategy(scaleDenom);
                modifiedMap = ApplicationGIS.drawMap(new DrawMapParameter(graphics, awtSize, getMap(), boundsStrategy, 90, selectionStyle, monitor, true, true));
            }

            //ApplicationGIS.drawMap makes a copy of the map, and may change its bounds.  If it does change
            //the bounds then update the original map to match (this will force the mapgraphics to update too)
View Full Code Here

       
        drawMapParameter =
            new DrawMapParameter(g,
                             new java.awt.Dimension(w, h),
                             mapWithRasterLayersOnly,
                             new BoundsStrategy(scaleDenom),
                             page1.getDpi(),
                             SelectionStyle.EXCLUSIVE_ALL,
                             null);

       
View Full Code Here

        Dimension size = info.getRight().getLeft();
        double scale = info.getRight().getRight();

        ViewportModel viewportModel = map.getViewportModelInternal();
        ReferencedEnvelope bounds = (ReferencedEnvelope) viewportModel.getBounds();
        BoundsStrategy boundsStrategy = new BoundsStrategy(scale);

        RenderContext context = null;
        if (inPreviewMode && !Float.isNaN(scaleFactor)) {
            float dpiFloat = (float) DEFAULTDPI * scaleFactor;
            context = ApplicationGIS.configureMapForRendering(map, size, (int) dpiFloat,
View Full Code Here

TOP

Related Classes of org.locationtech.udig.project.ui.BoundsStrategy

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.