Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change Google Map V2 language for Android App

How could change language of Google Map V2 to Hindi or other language while using within Android app.

There are some queries on this but unable to get proper answer.

I have tried to change language of my phone to Hindi then Google map app in device started showing text in Hindi but the map in my android app is still showing text in English completely.

Update: I am able to change language of Google Map V2 to Japan and Korea using language code "ja" and "ko" as below,

Locale.setDefault(new Locale("ja"));

But not still able to change it to Hindi by using ("hi" or "hi_IN" or "hi-IN" or "hi-rIN"). Is there any other language code for Hindi in Android?

like image 746
Ajay Avatar asked Mar 18 '23 01:03

Ajay


2 Answers

It looks like Google Maps for Android was not available in Hindi until this summer (read here), so if you are using an outdated version of google maps you should update it first.

Once updated, you may change locale just like any other language.

like image 155
Joanvo Avatar answered Mar 31 '23 15:03

Joanvo


You are welcome to try Locale.setDefault(new Locale("hi", "IN")); per this answer.

However, please bear in mind that Google Maps data comes from another process, not yours, and you have no means of changing the Locale of another process. Your technique may not work for all languages and may not work in future versions of Google Play Services.

like image 22
CommonsWare Avatar answered Mar 31 '23 15:03

CommonsWare