Revision 42352 trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.symbology/org.gvsig.symbology.lib/org.gvsig.symbology.lib.impl/src/main/java/org/gvsig/symbology/fmap/mapcontext/rendering/symbol/line/impl/SimpleLineSymbol.java

View differences:

SimpleLineSymbol.java
64 64

  
65 65
	private static final Logger LOG = LoggerFactory.getLogger(SimpleLineSymbol.class);
66 66
    public static final String SIMPLE_LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME = "SimpleLineSymbol";
67
  
67

  
68 68
    private static final String SELECTION_SYMBOL = "symbolForSelection";
69 69

  
70 70
	SimpleLineSymbol symbolForSelection;
......
74 74
		super();
75 75
		setLineWidth(1d);
76 76
	}
77
	
77

  
78 78
	public ISymbol getSymbolForSelection() {
79 79
		if (symbolForSelection == null) {
80
			symbolForSelection = (SimpleLineSymbol) cloneForSelection();			
80
			symbolForSelection = (SimpleLineSymbol) cloneForSelection();
81 81
		}
82 82
		return symbolForSelection;
83 83
	}
......
98 98
				LOG.error("Creating a Surface", e);
99 99
			}
100 100
		}
101
		g.setColor(getColor());	
101
		g.setColor(getColor());
102 102
		g.draw(geomToDraw.getShape(affineTransform));
103 103

  
104 104
		ArrowDecoratorStyle arrowDecorator = (ArrowDecoratorStyle) getLineStyle().getArrowDecorator();
......
141 141

  
142 142
		return copy;
143 143
	}
144
	
144

  
145 145
    public void loadFromState(PersistentState state) throws PersistenceException {
146 146
        // Set parent style properties
147 147
        super.loadFromState(state);
......
170 170
						SimpleLineSymbol.class,
171 171
						SIMPLE_LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME,
172 172
						SIMPLE_LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME+" Persistence definition",
173
						null, 
173
						null,
174 174
						null
175 175
				);
176 176
				// Extend the LineSymbol base definition
177 177
				definition.extend(manager.getDefinition(LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME));
178
				
178

  
179 179
                definition.addDynFieldObject(SELECTION_SYMBOL).setClassOfValue(SimpleLineSymbol.class);
180 180

  
181 181
			}
182 182
			return Boolean.TRUE;
183 183
		}
184
		
184

  
185 185
	}
186 186

  
187 187
	public static class RegisterSymbol implements Callable {
......
191 191
			SymbolManager manager = MapContextLocator.getSymbolManager();
192 192

  
193 193
	        shapeTypes = new int[] { Geometry.TYPES.CURVE, Geometry.TYPES.ARC,
194
	                Geometry.TYPES.ELLIPTICARC, Geometry.TYPES.MULTICURVE };
194
	                Geometry.TYPES.MULTICURVE, Geometry.TYPES.CIRCUMFERENCE,
195
	                Geometry.TYPES.PERIELLIPSE, Geometry.TYPES.SPLINE,
196
	                Geometry.TYPES.LINE, Geometry.TYPES.MULTILINE};
195 197
	        manager.registerSymbol(ILineSymbol.SYMBOL_NAME,
196 198
	            shapeTypes,
197 199
	            SimpleLineSymbol.class);
198 200

  
199 201
			return Boolean.TRUE;
200 202
		}
201
		
203

  
202 204
	}
203 205

  
204 206
}

Also available in: Unified diff