Examples of StyleBlackboard


Examples of org.locationtech.udig.project.internal.StyleBlackboard

    private BoxPart owner;
    private StyleBlackboard original;

    public Command getCommand() {
        final StyleBlackboard originalStyleBlackboard = this.original;
        this.original = null;
       
        final Layer layer = getSelectedLayer();
        final StyleBlackboard newBlackboard = layer.getStyleBlackboard();
       
        return new Command(){
            @Override
            public String getLabel() {
                return "Change Style";
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

        parent.setLayout(gridLayout);

        if (editorSupported) {
            colorRulesEditor = new CoverageColorEditor(parent, SWT.NONE);

            StyleBlackboard styleBlackboard = layer.getStyleBlackboard();

            Style style = (Style) styleBlackboard.get(SLDContent.ID);
            if (style == null) {
                style = createDefaultStyle();

                // put style back on blackboard
                styleBlackboard.put(SLDContent.ID, style);
                styleBlackboard.setSelected(new String[]{SLDContent.ID});
            }
            style.setName(layer.getName());
            ArrayList<CoverageRule> listOfRules = new ArrayList<CoverageRule>();
            // Rule ruleToUpdate = SLDs.getRasterSymbolizerRule(style);
            RasterSymbolizer rasterSymbolizer = SLDs.rasterSymbolizer(style);
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

                Style newStyle = SLD.wrapSymbolizers(rasterSym);
                Layer selLayer = getSelectedLayer();
                newStyle.setName(selLayer.getName());

                StyleBlackboard styleBlackboard = layer.getStyleBlackboard();

                // put style back on blackboard
                styleBlackboard.put(SLDContent.ID, newStyle);
                styleBlackboard.setSelected(new String[]{SLDContent.ID});
            }
        } catch (Exception e) {
            e.printStackTrace();
            String message = Messages.CoverageStyleEditorPage_2;
            ExceptionDetailsDialog.openError(null, message, IStatus.ERROR, StylePlugin.PLUGIN_ID, e);
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

            }
          }
         
          if (fstyle != null) {
            fstyle.setName(type.getName().getLocalPart());
            StyleBlackboard styleBlackboard = (StyleBlackboard) layer.getStyleBlackboard();
                    styleBlackboard.put(SLDContent.ID, style);
              styleBlackboard.setSelected(new String[]{SLDContent.ID});

//            //force a rerender, TODO: blackboard events
//            layer.getMap().getRenderManager().refresh(
//              layer, resource.getInfo(m).getBounds() 
//            );
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

        noFeatureLabel.setText(Messages.SimplePointEditorPage_0);

        StyleLayer layer = getSelectedLayer();
        IGeoResource resource = layer.getGeoResource();
        if (resource.canResolve(FeatureSource.class)) {
            StyleBlackboard styleBlackboard = layer.getStyleBlackboard();
            oldStyle = (Style) styleBlackboard.get(SLDContent.ID);
            if (oldStyle == null) {
                oldStyle = Utilities.createDefaultPointStyle();
            }
           
            DuplicatingStyleVisitor dsv = new DuplicatingStyleVisitor();
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

       
        newStyle.setName(layer.getName());

        setStyle(newStyle);

        StyleBlackboard styleBlackboard = layer.getStyleBlackboard();
        styleBlackboard.put(SLDContent.ID, newStyle);
    }
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

        IGeoResource resource = layer.getGeoResource();
        if (!resource.canResolve(FeatureSource.class)) {
            return;
        }

        StyleBlackboard styleBlackboard = layer.getStyleBlackboard();
        oldStyle = (Style) styleBlackboard.get(SLDContent.ID);
        if (oldStyle == null) {
            oldStyle = Utilities.createDefaultPointStyle();
        }
        DuplicatingStyleVisitor dsv = new DuplicatingStyleVisitor();
        dsv.visit(oldStyle);
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

        return applyCurrentStyle();
    }

    private boolean applyCurrentStyle() {

        StyleBlackboard styleBlackboard = getSelectedLayer().getStyleBlackboard();

        if (colorMaskButton.getSelection()) {
            Color maskColor = maskColorEditor.getColor();
            String colorStr = maskColor.getRed() + ":" + maskColor.getGreen() + ":" + maskColor.getBlue(); //$NON-NLS-1$ //$NON-NLS-2$
            styleBlackboard.putString(COVERAGE_COLORMASK_ID, colorStr);
        } else {
            styleBlackboard.remove(COVERAGE_COLORMASK_ID);
        }
        return true;
    }
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

        noFeatureLabel.setText(Messages.SimplePolygonEditorPage_0);

        StyleLayer layer = getSelectedLayer();
        IGeoResource resource = layer.getGeoResource();
        if (resource.canResolve(FeatureSource.class)) {
            StyleBlackboard styleBlackboard = layer.getStyleBlackboard();
            style = (Style) styleBlackboard.get(SLDContent.ID);
            if (style == null) {
                style = Utilities.createDefaultPolygonStyle();
            }
           
            DuplicatingStyleVisitor dsv = new DuplicatingStyleVisitor();
View Full Code Here

Examples of org.locationtech.udig.project.internal.StyleBlackboard

       
        newStyle.setName(layer.getName());

        setStyle(newStyle);

        StyleBlackboard styleBlackboard = layer.getStyleBlackboard();
        styleBlackboard.put(SLDContent.ID, newStyle);
    }
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.