Skip to content

Commit

Permalink
KML load: Fix default line width
Browse files Browse the repository at this point in the history
  • Loading branch information
EosBandi authored and meee1 committed Nov 12, 2024
1 parent 0343fa5 commit 5f4296e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions GCSViews/FlightPlanner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5180,8 +5180,12 @@ private void processKML(Element Element, Document root = null)
// convert color from ABGR to ARGB
color = (int)((color & 0xFF00FF00) | ((color & 0x00FF0000) >> 16) | ((color & 0x000000FF) << 16));

// ABGR
return (Color.FromArgb(color), (int)((Style)style).Line.Width.Value);
if (((Style)style).Line.Width != null)
{
return (Color.FromArgb(color), (int)((Style)style).Line.Width.Value);
}
else
return (Color.FromArgb(color), 2);
}
}
}
Expand Down

0 comments on commit 5f4296e

Please sign in to comment.