Is there a way to enable night mode on maps?

Using openstreetmaps tiles. 

<maps:MapTileLayer UrlTemplate="https://tile.openstreetmap.org/{z}/{x}/{y}.png" CanCacheTiles="True">

I tried setting theme to MaterialDark for the map control but it did not change the map itself.  

<syncTheme:SyncfusionThemeResourceDictionary VisualTheme="MaterialDark"/>

Is there a way to do this?

EDIT: I think the way with openstreetmaps is  vector tiles, but is it possible to use vector tiles here?


1 Reply

VO Vishal Omprasad Syncfusion Team September 4, 2024 12:38 PM UTC

Hi sjs,

As per the current implementation, in the .NET MAUI SfMaps control, the map tiles are static images fetched from external sources (like OpenStreetMap), and theming only affects the UI components, not the external tile images.

If you have any further questions or require assistance with any other aspect, please don't hesitate to let us know. We are here to help.

Regards,
Vishal O.


Loader.
Up arrow icon