Monday, February 08, 2010

Rectangle() and Circle() of V3

API v3.28 has new constructors

  new google.maps.Rectangle();
  new google.maps.Circle();

Dimensioning and positioning is set by bounds (Rectangle) or by center and radius (Circle). Circle radius is given in meters. Those can be set as options or by special methods setBounds(), setCenter() and setRadius().  They are documented already.

getBounds() for Circle would be a useful method that is missing.

Altogether those are very handy classes and we can forget my boundsbox.js library in most cases. Image overlaying is still a perfect task for boundsbox.

Quickly testing Rectangle().


1 comment:

Disha said...


I have contact list in my sql server table.In my page user will
enter zip code and depending on entered zip code I will search the
contact zip code in my sql server table and then I will generate xml
and show markes on googlemap with polyline/circle draw automatically depending upon search resulted data.

Or is there any way If I allow user to mark the from Locations and to locations on map or allow him to draw circle om map then dependent on draw circle area it will search in the
database and display marker of resulted data as available in Microsoft
MapPoint windows based application.

Is this possible?

Sorry to asking so many questions?

Ms Sonaly