dictionary - Swift MapKit Polygon overlay -


i have polygon on mapview, want add 2 1 in different color. there way todo so?

this mapview should 2. polygon overlay in different color enter image description here

   func addboundry()     {         var points=[                     cllocationcoordinate2dmake(51.711963, 8.738251),                     cllocationcoordinate2dmake(51.711963, 8.763717),                     cllocationcoordinate2dmake(51.718574, 8.763717),                     cllocationcoordinate2dmake(51.71855, 8.754448)]          let polygon = mkpolygon(coordinates: &points, count: points.count)          mapview.addoverlay(polygon)     }  func mapview(mapview: mkmapview!, rendererforoverlay overlay: mkoverlay!) -> mkoverlayrenderer! {     if overlay mkpolygon {         let polygonview = mkpolygonrenderer(overlay: overlay)         polygonview.fillcolor = uicolor(red: 0, green: 0.847, blue: 1, alpha: 0.25)          return polygonview     }      return nil } 

is there way todo so?

solved via .title use in if


Comments

Popular posts from this blog

javascript - Slick Slider width recalculation -

jsf - PrimeFaces Datatable - What is f:facet actually doing? -

angular2 services - Angular 2 RC 4 Http post not firing -