Hi Ben,
I started a new project, added only the latest ThinkGeo.UI.Wpf (13.2.0-beta007), and tried to mimic your implementation. I think the only difference now is that I’m using InMemoryFeatureLayer instead of the ShapeFileFeatureLayer in your example. Could that be the issue? Or the vector overlay?
private void wpfMap_Loaded(object sender, RoutedEventArgs e)
{
LoadMapOverlays();
}
private void LoadMapOverlays()
{
WpfMap.MapUnit = GeographyUnit.Meter;
// Create the background world maps using vector tiles requested from the ThinkGeo Cloud Service and add it to the map
ThinkGeoCloudVectorMapsOverlay thinkGeoCloudVectorMapsOverlay = new(ClientId, ClientSecret, ThinkGeoCloudVectorMapsMapType.Light);
WpfMap.Overlays.Add(thinkGeoCloudVectorMapsOverlay);
double x = -10776836.12;
double y = 3912348.04;
LayerOverlay overlay1 = new LayerOverlay();
overlay1.TileType = TileType.SingleTile;
InMemoryFeatureLayer featureLayer1 = new InMemoryFeatureLayer();
featureLayer1.InternalFeatures.Add(new Feature(x, y));
overlay1.Layers.Add(featureLayer1);
WpfMap.Overlays.Add(overlay1);
PointStyle pointStyle = new PointStyle(new GeoImage(@"./ArrowUp.png"))
{
ImageScale = 1
};
featureLayer1.ZoomLevelSet.ZoomLevel01.CustomStyles.Clear();
featureLayer1.ZoomLevelSet.ZoomLevel01.CustomStyles.Add(pointStyle);
pointStyle.RotationAngle = 10;
featureLayer1.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20;
overlay1.Refresh();
}
Thanks,
Jarno