File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
MapLibreSwiftDSL/Style Layers Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ import MapLibreSwiftMacros
77@MLNStyleProperty < UIColor > ( " lineColor " , supportsInterpolation: true )
88@MLNRawRepresentableStyleProperty < LineCap > ( " lineCap " )
99@MLNRawRepresentableStyleProperty < LineJoin > ( " lineJoin " )
10+ @MLNStyleProperty < [ Float ] > ( " lineDashPattern " )
1011@MLNStyleProperty < Float > ( " lineWidth " , supportsInterpolation: true )
1112public struct LineStyleLayer : SourceBoundVectorStyleLayerDefinition {
1213 public let identifier : String
@@ -75,7 +76,7 @@ private struct LineStyleLayerInternal: StyleLayer {
7576 result. lineCap = definition. lineCap
7677 result. lineWidth = definition. lineWidth
7778 result. lineJoin = definition. lineJoin
78-
79+ result . lineDashPattern = definition . lineDashPattern
7980 result. predicate = definition. predicate
8081
8182 return result
Original file line number Diff line number Diff line change @@ -30,7 +30,8 @@ struct PolylineMapView: View {
3030
3131 // Add an inner (blue) polyline
3232 LineStyleLayer ( identifier: " polyline-inner " , source: polylineSource)
33- . lineCap ( . round)
33+ . lineDashPattern ( [ 2.0 , 0.5 ] )
34+ . lineCap ( . butt)
3435 . lineJoin ( . round)
3536 . lineColor ( . systemBlue)
3637 . lineWidth ( interpolatedBy: . zoomLevel,
You can’t perform that action at this time.
0 commit comments