[Cartoweb-users] recenter box and scale
giuseppe.derossi at email.it
giuseppe.derossi at email.it
Tue Mar 25 04:48:28 EDT 2008
Hi All,
I'd like to improve a feature of a plugin of mine. I need to center the map
in a point whose coordinates are red from a database and set the scale to a
fixed value.
Now the plugIn reads the coordinates (x1,y1) then given two quantities for
the sides, let me say, Dx and Dy, where Dx and Dy are the sides of the box I
want, the plugIn calculates:
xp1=x1-Dx/2 yp1=y1-Dy/2 and xp2=x1+Dx/2 yp2=y1+Dx/2 , the last operation is
a recenter in (xp1,yp1,xp2,yp2). I've set Dx and Dy in a rough way., If the
map size changes, the way I implemented, could give some blank space on a
side.
Is there a way my plgIn sets x1 and y1 as center point then zooms at a fixed
scale ?
thanks and best regards
Giu
--
Email.it, the professional e-mail, gratis per te: http://www.email.it/f
Sponsor:
Scopri le tue passioni con Leonardo.it!
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=7613&d=20080325
More information about the Cartoweb-users
mailing list