[mapguide-users] AJAX viewer zoom slider
Jason Birch
Jason.Birch at nanaimo.ca
Fri Apr 7 13:50:05 EDT 2006
Thanks Alain.
Should I be placing this in an onload handler for the main frame, or is
there an event that fires when the map is initialized that I can respond
to? The developer guide seems to be focussed mostly on interacting with
the task frame; I couldn't figure it out from that.
Jason
-----Original Message-----
From: Alain Lebatard [mailto:alain.lebatard at autodesk.com]
Sent: Friday, April 07, 2006 09:39
To: users at mapguide.osgeo.org
Subject: RE: [mapguide-users] AJAX viewer zoom slider
Jason,
You can workaround this for now by setting the 'scales' array to a new
value after the map is initialized. For example this will change the
slider to zoom between scales 1:2000 and roughly 1:300000
scales = new Array();
scale = 2000;
for(var i=0; i < 20; i++) {
scales[i] = scale;
scale *= 1.3;
}
mapFrame.scales = scales;
You're free to define the number of scales in the array to make the
slider smoother and to define the increment between scales.
Alain
-----Original Message-----
From: Jason Birch [mailto:Jason.Birch at nanaimo.ca]
Sent: Friday, April 07, 2006 8:12 AM
To: users at mapguide.osgeo.org
Subject: [mapguide-users] AJAX viewer zoom slider
Is it just me, or does having a zoom slider where the top 1/3 is
dedicated to scales greater than 1:1 not make any sense? This appears
to be the case in the maps that I have made that don't have base layers.
The slider function itself appears to use a pretty good algorithm to
zoom progressively, but I think that it might be more useful if:
- It was integer-based, and/or
- It was possible to specify min/max scales for a given map
I put in a defect report for this a while back:
https://mapguide.osgeo.org/servlets/Scarab?id=MG146
In the meantime, can anyone suggest a workaround?
Thanks,
Jason
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org
More information about the Mapguide-users
mailing list