Revision 29132
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/symbols/MultiLayerMarkerSymbol.java | ||
---|---|---|
245 | 245 |
} |
246 | 246 |
|
247 | 247 |
public boolean isSuitableFor(IGeometry geom) { |
248 |
return geom.getGeometryType() == FShape.POINT;
|
|
248 |
return (geom.getGeometryType()%FShape.Z) == FShape.POINT;
|
|
249 | 249 |
} |
250 | 250 |
|
251 | 251 |
|
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/symbols/MultiLayerFillSymbol.java | ||
---|---|---|
138 | 138 |
} |
139 | 139 |
|
140 | 140 |
public boolean isSuitableFor(IGeometry geom) { |
141 |
return geom.getGeometryType() == FShape.POLYGON;
|
|
141 |
return (geom.getGeometryType() % FShape.Z) == FShape.POLYGON;
|
|
142 | 142 |
} |
143 | 143 |
|
144 | 144 |
public void setFillColor(Color color) { |
... | ... | |
217 | 217 |
xml.putProperty("isShapeVisible", isShapeVisible()); |
218 | 218 |
xml.putProperty("referenceSystem", getReferenceSystem()); |
219 | 219 |
xml.putProperty("unit", getUnit()); |
220 |
|
|
220 |
|
|
221 | 221 |
for (int i = 0; i < layers.length; i++) { |
222 | 222 |
xml.addChild(layers[i].getXMLEntity()); |
223 | 223 |
} |
... | ... | |
240 | 240 |
for (int i = 0; i < xml.getChildrenCount(); i++) { |
241 | 241 |
addLayer((IFillSymbol) SymbologyFactory.createSymbolFromXML(xml.getChild(i), "layer" + i)); |
242 | 242 |
} |
243 |
|
|
243 |
|
|
244 | 244 |
if (xml.contains("unit")) { // remove this line when done |
245 | 245 |
// measure unit (for outline) |
246 | 246 |
setUnit(xml.getIntProperty("unit")); |
247 |
|
|
247 |
|
|
248 | 248 |
// reference system (for outline) |
249 | 249 |
setReferenceSystem(xml.getIntProperty("referenceSystem")); |
250 | 250 |
} |
... | ... | |
322 | 322 |
layers[i].setUnit(unitIndex); |
323 | 323 |
} |
324 | 324 |
} |
325 |
|
|
325 |
|
|
326 | 326 |
@Override |
327 | 327 |
public void setReferenceSystem(int system) { |
328 | 328 |
super.setReferenceSystem(system); |
... | ... | |
330 | 330 |
layers[i].setReferenceSystem(system); |
331 | 331 |
} |
332 | 332 |
} |
333 |
|
|
333 |
|
|
334 | 334 |
/** |
335 | 335 |
*Returns the transparency of the multi layer fill symbol created |
336 | 336 |
*/ |
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/symbols/MultiLayerLineSymbol.java | ||
---|---|---|
247 | 247 |
} |
248 | 248 |
|
249 | 249 |
public boolean isSuitableFor(IGeometry geom) { |
250 |
return geom.getGeometryType() == FShape.LINE;
|
|
250 |
return (geom.getGeometryType()%FShape.Z) == FShape.LINE;
|
|
251 | 251 |
} |
252 | 252 |
|
253 | 253 |
public String getClassName() { |
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/symbols/AbstractMarkerSymbol.java | ||
---|---|---|
183 | 183 |
} |
184 | 184 |
|
185 | 185 |
public boolean isSuitableFor(IGeometry geom) { |
186 |
return geom.getGeometryType() == FShape.POINT;
|
|
186 |
return (geom.getGeometryType()%FShape.Z) == FShape.POINT;
|
|
187 | 187 |
} |
188 | 188 |
|
189 | 189 |
public int getOnePointRgb() { |
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/symbols/AbstractFillSymbol.java | ||
---|---|---|
119 | 119 |
private ILineSymbol outline; |
120 | 120 |
|
121 | 121 |
public boolean isSuitableFor(IGeometry geom) { |
122 |
return geom.getGeometryType() == FShape.POLYGON;
|
|
122 |
return (geom.getGeometryType() % FShape.Z) == FShape.POLYGON;
|
|
123 | 123 |
} |
124 | 124 |
|
125 | 125 |
public int getOnePointRgb() { |
... | ... | |
162 | 162 |
if (color == null) return 255; |
163 | 163 |
return color.getAlpha(); |
164 | 164 |
} |
165 |
|
|
165 |
|
|
166 | 166 |
public void setCartographicSize(double cartographicSize, FShape shp) { |
167 | 167 |
if (getOutline() != null) { |
168 | 168 |
getOutline().setLineWidth(cartographicSize); |
... | ... | |
189 | 189 |
public void setHasFill(boolean hasFill) { |
190 | 190 |
this.hasFill = hasFill; |
191 | 191 |
} |
192 |
|
|
193 |
|
|
192 |
|
|
193 |
|
|
194 | 194 |
public boolean hasOutline() { |
195 | 195 |
return hasOutline; |
196 | 196 |
} |
... | ... | |
198 | 198 |
public void setHasOutline(boolean hasOutline) { |
199 | 199 |
this.hasOutline = hasOutline; |
200 | 200 |
} |
201 |
|
|
202 |
|
|
201 |
|
|
202 |
|
|
203 | 203 |
public double getCartographicSize(ViewPort viewPort, double dpi, FShape shp) { |
204 | 204 |
if (getOutline() != null) { |
205 | 205 |
return CartographicSupportToolkit. |
trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/core/SymbologyFactory.java | ||
---|---|---|
432 | 432 |
*/ |
433 | 433 |
public static IMultiLayerSymbol createEmptyMultiLayerSymbol(int shapeType) { |
434 | 434 |
IMultiLayerSymbol mSym; |
435 |
switch (shapeType) { |
|
435 |
switch (shapeType%FShape.Z) {
|
|
436 | 436 |
case FShape.POINT: |
437 | 437 |
mSym = new MultiLayerMarkerSymbol(); |
438 | 438 |
break; |
Also available in: Unified diff