I need to display only a single country in google map. I need to display only one country and the parts of other countries should not be there.. for example if I want to dis
I was looking for the same thing and ended up using polygon overlay.
Relevant code is under "here is the magic" comment.
Zoom out all the way and you will see the giant white square. This is the 0th index of the array in the json file (linked in map.data.loadGeoJson) "[[-147, 2], [-150, 70], [-20, 68], [-31, 5], [-147, 2]]", the next index is the border coordinate points of the region you're interested in.
Search for "kml {country/city/state/region name}" in google and you'll probably find all that data with the border outline points.
https://jsfiddle.net/jmao2o3o/3/
//here is the magic
map.data.loadGeoJson('https://bitbucket.org/dimaboychev/public/raw/9bb53aba0d70875a6d2d9bd2a1eec65671ce4ae3/dc.json');