From c3e1ffd685374b80ab91c99b960c83347c774ae7 Mon Sep 17 00:00:00 2001 From: ClemensFischer Date: Tue, 29 Nov 2022 23:50:06 +0100 Subject: [PATCH] Update MapGraticule.cs --- MapControl/Shared/MapGraticule.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/MapControl/Shared/MapGraticule.cs b/MapControl/Shared/MapGraticule.cs index 44276d06..51178ed3 100644 --- a/MapControl/Shared/MapGraticule.cs +++ b/MapControl/Shared/MapGraticule.cs @@ -114,9 +114,10 @@ namespace MapControl { if (!rotation.HasValue) { - location.Longitude += 10d / PixelPerLongitudeDegree(location); - - var pos = ParentMap.LocationToView(location); + // get rotation from second location with same latitude + // + var pos = ParentMap.LocationToView( + new Location(location.Latitude, location.Longitude + 10d / PixelPerLongitudeDegree(location))); if (MapProjection.IsValid(pos)) {