On Mar 5, 2:18 pm, wang Chen <[email protected]> wrote:
> Hey,
>   I just start to learn Google Maps api. I copy the following code
> from Google Maps documents to set map bounds and add an alert
> statement to display the bounds I just set. However I find that the
> getBounds value is different from the value I send to fitBounds().
> The value I send to fitBounds() is ((-31.203405,125.244141),
> (-25.363882,131.044922))
> the value from getBounds is ((-33.13755108,117,86132837),
> (-23.28171906,138.4277346))
>
> Is it related to the zoom level set in the map option?

Yes.  fitBounds calculates the zoom level and center required to
display the argument bounds object.  Since zoom levels are integers,
the requested bounds may not be the same as the bounds of the
resulting map.

  -- Larry

> If so, how to control the bounds to latlng values as developers
> want?
>
> Thanks a lot.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Reply via email to