Closed ChristinaKochan closed 7 years ago
GFMPOADU------- is antitank ditch under construction so the JSON shown has no fill color. Are you also getting no fill color for GFMPOADC------- ? When I run it with GeoJSON format I see fill color.
You're right, I copied the wrong JSON. But with the Complete JSON I still get unfilled triangles:
{
"type":"FeatureCollection",
"features":[
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-9.57538667,
24.40000275
],
[
-9.55140225,
24.59815967
],
[
-9.41900124,
24.44206149
],
[
-9.57538667,
24.40000275
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-9.73166723,
24.357944
],
[
-9.70794176,
24.55610092
],
[
-9.57538667,
24.40000275
],
[
-9.73166723,
24.357944
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-9.88784307,
24.31588525
],
[
-9.86437562,
24.51404217
],
[
-9.73166723,
24.357944
],
[
-9.88784307,
24.31588525
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.04391495,
24.27382649
],
[
-10.02070398,
24.47198342
],
[
-9.88784307,
24.31588525
],
[
-10.04391495,
24.27382649
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.19988304,
24.23176774
],
[
-10.17692761,
24.42992467
],
[
-10.04391495,
24.27382649
],
[
-10.19988304,
24.23176774
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.35574756,
24.18970901
],
[
-10.33304655,
24.38786591
],
[
-10.19988304,
24.23176774
],
[
-10.35574756,
24.18970901
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.51150899,
24.14765026
],
[
-10.48906137,
24.34580716
],
[
-10.35574756,
24.18970901
],
[
-10.51150899,
24.14765026
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.66716768,
24.1055915
],
[
-10.64497221,
24.30374841
],
[
-10.51150899,
24.14765026
],
[
-10.66716768,
24.1055915
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.82272407,
24.06353275
],
[
-10.80077963,
24.26168965
],
[
-10.66716768,
24.1055915
],
[
-10.82272407,
24.06353275
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-10.97817831,
24.021474
],
[
-10.95648379,
24.2196309
],
[
-10.82272407,
24.06353275
],
[
-10.97817831,
24.021474
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-11.13353096,
23.97941525
],
[
-11.11208513,
24.17757215
],
[
-10.97817831,
24.021474
],
[
-11.13353096,
23.97941525
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-11.28878216,
23.93735649
],
[
-11.26758411,
24.1355134
],
[
-11.13353096,
23.97941525
],
[
-11.28878216,
23.93735649
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"fillColor":"#00FF00",
"fillOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"Polygon",
"coordinates":[
[
[
-11.52138303,
23.89529774
],
[
-11.4586703,
24.08379129
],
[
-11.28878216,
23.93735649
],
[
-11.52138303,
23.89529774
]
]
]
}
},
{
"type":"Feature",
"properties":{
"label":"",
"strokeColor":"#00FF00",
"lineOpacity":1.0,
"strokeWidth":3,
"strokeWeight":3
},
"geometry":{
"type":"MultiLineString",
"coordinates":[
[
[
-11.52138303,
23.89529774
],
[
-11.4586703,
24.08379129
],
[
-11.28878216,
23.93735649
]
],
[
[
-11.28878216,
23.93735649
],
[
-11.26758411,
24.1355134
],
[
-11.13353096,
23.97941525
]
],
[
[
-11.13353096,
23.97941525
],
[
-11.11208513,
24.17757215
],
[
-10.97817831,
24.021474
]
],
[
[
-10.97817831,
24.021474
],
[
-10.95648379,
24.2196309
],
[
-10.82272407,
24.06353275
]
],
[
[
-10.82272407,
24.06353275
],
[
-10.80077963,
24.26168965
],
[
-10.66716768,
24.1055915
]
],
[
[
-10.66716768,
24.1055915
],
[
-10.64497221,
24.30374841
],
[
-10.51150899,
24.14765026
]
],
[
[
-10.51150899,
24.14765026
],
[
-10.48906137,
24.34580716
],
[
-10.35574756,
24.18970901
]
],
[
[
-10.35574756,
24.18970901
],
[
-10.33304655,
24.38786591
],
[
-10.19988304,
24.23176774
]
],
[
[
-10.19988304,
24.23176774
],
[
-10.17692761,
24.42992467
],
[
-10.04391495,
24.27382649
]
],
[
[
-10.04391495,
24.27382649
],
[
-10.02070398,
24.47198342
],
[
-9.88784307,
24.31588525
]
],
[
[
-9.88784307,
24.31588525
],
[
-9.86437562,
24.51404217
],
[
-9.73166723,
24.357944
]
],
[
[
-9.73166723,
24.357944
],
[
-9.70794176,
24.55610092
],
[
-9.57538667,
24.40000275
]
],
[
[
-9.57538667,
24.40000275
],
[
-9.55140225,
24.59815967
],
[
-9.41900124,
24.44206149
]
],
[
[
-11.52146976,
23.87426836
],
[
-11.28878216,
23.93735649
],
[
-11.13353096,
23.97941525
],
[
-10.97817831,
24.021474
],
[
-10.82272407,
24.06353275
],
[
-10.66716768,
24.1055915
],
[
-10.51150899,
24.14765026
],
[
-10.35574756,
24.18970901
],
[
-10.19988304,
24.23176774
],
[
-10.04391495,
24.27382649
],
[
-9.88784307,
24.31588525
],
[
-9.73166723,
24.357944
],
[
-9.37515374,
24.45384893
]
]
]
}
}
],
"properties":{
"id":"f764c60a-9ea8-49d1-a48b-9f71805e6a1b",
"name":"name",
"description":"GFMPOADC-------",
"symbolID":"GFMPOADC-------"
}
}
I tried your data for antitank ditch complete on this site: https://google-developers.appspot.com/maps/documentation/utils/geojson/ The triangles are filled.
I meant to also mention that you can see the fill color shown in the data for each triangle, e.g. "type":"Feature", "properties":{ "label":"", "fillColor":"#00FF00", "fillOpacity":1.0, "strokeWidth":3, "strokeWeight":3 }, "geometry":{ "type":"Polygon", "coordinates":[ [ [ -11.52138303, 23.89529774 ], [ -11.4586703, 24.08379129 ], [ -11.28878216, 23.93735649 ], [ -11.52138303, 23.89529774 ] ] ] } },
Well shoot, I don't know why one is filled and one isn't then. I'll have to play around with it some more and see if I can figure it out.
Thanks for your help, that GeoJSON editor is useful.
I found that if I include the last feature (the MultiLineString) that is a combination of all of the triangles and the control points line, my triangles are not filled correctly. If I ignore this last feature then everything looks pretty much as expected, although some of the triangles are a little wonky especially at larger scales. I'm not sure why this is, but I'm just manually dropping any MultiLineString features when I create my geometry on my Esri map and that seems to work.
The last feature is the outline. Notice it does not have any fill as do the all the other features. it should not affect the fill of the other features which are the triangles. I suppose you can display it the way you are doing.
I think it's something about the way the Esri renderer works. When I include that feature as part of Esri's Multipart Polygon created for this symbol, it does not render with the fill. When I don't include it, the fill works. The shape of the symbol seems to look more or less the same without it.
The shape of the symbol would look about the same without it. The end points might differ slightly, that's about it.
Would it be possible to have the Antitank Ditch (Complete) returned in the same way as the Antitank Ditch Reinforced with Antitank Mines? Currently the Reinforced AD returns as a collection of Polygons with fill colors, so the triangles and circles are displayed correctly with fills, but the Complete AD returns as a single MultiLineString without any fill color, so the triangles are not filled as they should be. This means the Complete AD looks just like the Under Construction AD, which is incorrect.
Example GFMPOADU------- JSON:
Example GFMPOAR-------- JSON: