Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Theme Google Maps for Android

I recently managed to get an Ingress invite, and love the way the maps are themed in that.

I know similar theming can be done for Google Maps in a browser, as shown here.

Does anybody know how Ingress themed the map on Android? Is this a feature only available to Google, or can we use it in our apps through the standard maps library?

enter image description here

like image 676
Raghav Sood Avatar asked Nov 20 '12 17:11

Raghav Sood


People also ask

Can you import themes in Google Maps?

You can customize the style or theme of the Google maps. Step 2 Select and click the theme you want to make change. Step 3 Copy that JSON code from left side. Step 4 Go to Add or Edit Map and Scroll down to 'Map Style Setting' section and paste it here to apply custom google maps skin.

How do I change the map style in Android?

To style your map, call GoogleMap. setMapStyle() passing a MapStyleOptions object that contains your style declarations in JSON format.


1 Answers

Honestly, this is a guess (a lot more of a guess for me than usual)

The MapView itself is a view. There's constructors to take in contexts and attributes. You might be able to play with a ContextThemeWrapper or extend the mapview and do things with onDraw().

like image 179
Joe Plante Avatar answered Sep 25 '22 23:09

Joe Plante