What’s New in 2018 Volume 3: Xamarin.Forms Maps | Syncfusion Blogs
Live Chat Icon For mobile
Live Chat Icon
Popular Categories.NET  (180).NET Core  (28).NET MAUI  (225)Angular  (113)ASP.NET  (49)ASP.NET Core  (81)ASP.NET MVC  (87)Azure  (41)Black Friday Deal  (1)Blazor  (234)BoldSign  (14)DocIO  (24)Essential JS 2  (110)Essential Studio  (199)File Formats  (72)Flutter  (136)JavaScript  (226)Microsoft  (121)PDF  (83)Python  (1)React  (105)Streamlit  (1)Succinctly series  (131)Syncfusion  (962)TypeScript  (33)Uno Platform  (3)UWP  (3)Vue  (46)Webinar  (53)Windows Forms  (59)WinUI  (72)WPF  (163)Xamarin  (159)XlsIO  (38)Other CategoriesBarcode  (5)BI  (29)Bold BI  (8)Bold Reports  (2)Build conference  (10)Business intelligence  (55)Button  (4)C#  (163)Chart  (145)Chart of the week  (57)Cloud  (15)Company  (440)Dashboard  (8)Data Science  (3)Data Validation  (8)DataGrid  (73)Development  (677)Doc  (7)DockingManager  (1)eBook  (99)Enterprise  (22)Entity Framework  (7)Essential Tools  (13)Excel  (43)Extensions  (23)File Manager  (7)Gantt  (21)Gauge  (12)Git  (5)Grid  (31)HTML  (13)Installer  (2)Knockout  (2)Language  (1)LINQPad  (1)Linux  (2)M-Commerce  (1)Metro Studio  (11)Mobile  (521)Mobile MVC  (9)OLAP server  (2)Open source  (1)Orubase  (12)Partners  (21)PDF viewer  (45)Performance  (13)PHP  (2)PivotGrid  (5)Predictive Analytics  (6)Report Server  (3)Reporting  (8)Reporting / Back Office  (9)Rich Text Editor  (12)Road Map  (12)Scheduler  (54)Security  (5)SfDataGrid  (9)Silverlight  (21)Sneak Peek  (32)Solution Services  (4)Spreadsheet  (11)SQL  (15)Stock Chart  (1)Surface  (4)Tablets  (5)Theme  (12)Tips and Tricks  (113)UI  (403)Uncategorized  (68)Unix  (2)User interface  (68)Visual State Manager  (2)Visual Studio  (31)Visual Studio Code  (19)Web  (625)What's new  (339)Windows 8  (19)Windows App  (2)Windows Phone  (15)Windows Phone 7  (9)WinRT  (26)
Xamarin.Forms Maps what's new tile image

What’s New in 2018 Volume 3: Xamarin.Forms Maps Updates

We are excited to announce updates for our popular Xamarin maps control in the 2018 Volume 3 release. This release, we have mainly focused on adding usability-related features and improving product stability. In this blog, we are going to walk you through the following important Xamarin.Forms maps features one by one:

  • Access to imagery layer’s tile images from the application cache to improve performance.
  • Color mapping support for bubbles.
  • Sublayers support.
  • Smart data label alignment support

Access to imagery layer’s tile images from application cache

One of the most important features in the Xamarin maps control is  built-in online map provider support. Using this feature, you can render OpenStreetMap, Bing maps, or maps from other providers. Maps control uses the imagery layer to display tile images from the map provider service. When loading and zooming maps, we have to access the map’s tile images every time from an online service, which causes some performance delay. To overcome this problem, we have provided an option to cache downloaded tile images in an application cache memory. With this support, we can avoid accessing tile images from online services every time and improve performance while loading and zooming maps.

Maps caching support for OSM/Bing maps

If you want to clear existing cached tile images in the application memory, you can invoke the following method.


Color mapping support for maps bubbles

Color mapping support is used to categorize bubbles by customizing their color based on the underlying data values. Colors can be applied to bubbles by comparing their values with desired numeric ranges. For example, colors can be applied to countries based on their population density. The following code shows the top 30 countries by world population percentage by applying range color mapping in bubbles.


     <maps:BubbleMarkerSetting  ValuePath="Percent" ColorValuePath="Percent" >


               <maps:RangeColorMapping Color="#2E769F" From="4" To="20" LegendLabel="Above 4%" />

               <maps:RangeColorMapping Color="#D84444" To="4" From="2" LegendLabel="4% - 2%"  />

               <maps:RangeColorMapping Color="#816F28" To="2" From="1" LegendLabel="2% - 1% "  />

               <maps:RangeColorMapping Color="#7F38A0" To="1" From="0" LegendLabel="Below 1%"  />




Maps color mapping support


Sublayers is one of the most requested features from our customers. It allows users to load multiple shape files in a single map view. For example, you can add a sublayer over a main shape layer to view the geographic features of a country such as rivers, valleys, and cities in maps.


     <maps:ShapeFileLayer Uri="Texas.shp">


               <maps:ShapeSetting ShapeFill="#B1D8F5" ShapeStroke="#8DCCF4" ShapeStrokeThickness="1" />



               <maps:MapMarker Latitude="30.267153" Longitude="-97.7430608"/>



     <maps:ShapeFileLayer x:Name="subLayer1" Uri="California.shp">


                <maps:ShapeSetting ShapeFill="#B1D8F5" ShapeStroke="#8DCCF4" ShapeStrokeThickness="1" />



                <maps:MapMarker Latitude="37.3382082" Longitude="-121.8863286"/>




Maps sublayer

Smart label alignment

Map shapes can be easily annotated with data labels to improve the readability of shapes’ names. Sometimes, labels may overlap with other labels or other shapes if the label length is too long. For example, in the following image, due to label collision, state names are not clearly readable.

Maps label collisionTo overcome this problem, we have provided two options to trim or hide the labels that are either overflowing the shape boundaries or overlapping with each other.

Trim or hide overflowing labels

Just by setting the SmartLabelMode property to either Hide or Trim, you can avoid overflowing labels.

Maps label smart mode as trim

Maps labels smart mode as hide

Trim or hide overlapping labels

By using the IntersectionAction property, you can trim or hide the overlapping labels.

Maps label over lapping action as trim

Maps label overlapping action as hide

The following code shows how to set SmartLabelMode and IntersectionAction.


     <maps:DataLabelSetting  SmartLabelMode="None" IntersectionAction="Hide"/>


And more

Other than this feature set, we have a few more improvements: adding images to marker icons, legend customization, rendering corresponding shape layers from a layers collection by setting BaseMapIndex, exposed events for ZoomLevelChanging, ShapeSelectionChanged, and stability improvement.

We hope that you will enjoy these new features in maps. Check the full release notes for more details, browse complete example code in GitHub, and definitely explore the maps samples available on Google Play and the Microsoft Store.

If you are an existing customer, please download the new version from the License and Downloads page and try the new features for yourself. If you are a new customer, you can try our 30-day free trial to check out these features.

If you have any questions or require clarification, let us know in the comments section. You can also contact us through our support forum or Direct-Trac.


Want to learn more? Check out these other posts and free resources:


Share this post:

Comments (2)

[…] What’s New in 2018 Volume 3: Xamarin.Forms Maps Updates (Sheik Syed) […]

[…] What’s New in 2018 Volume 3: Xamarin.Forms Maps Updates (Sheik Syed) […]

Comments are closed.

Popular Now

Be the first to get updates

Subscribe RSS feed

Be the first to get updates

Subscribe RSS feed