Ben,
Are you trying to restrict the map from "zooming" to a particular scale? Or
are you wanting to restrict a particular layer from rendering/generating at
or past a particular scale?
If the second is true, you can override the layer's "generate" method and
get the scale from the projection and limit there... Something like this...
if (proj.getScale() > minScale) {
super.generate(proj);
}
The same would suffice for a custom layer as well. Hope this helps.
-Adam
-- W. Adam Brightwell Software Engineer, MTCSC Certified Scrum Master Email: wbrightwell@mtcsc.com DCO: william.brightwell@chat.dco.dod.mil Office: 843-856-1935/1985 x51632 Cell: 843-810-8701 > From: "Kacirek, Benjamin P CIV US USA TRADOC" <ben.kacirek@us.army.mil> > Date: Thu, 6 Jan 2011 10:13:48 -0600 > To: <openmap-users@bbn.com> > Subject: [OpenMap Users] Setting minimum scale for open map (UNCLASSIFIED) > > Classification: UNCLASSIFIED > Caveats: NONE > > I am trying to set the minimum scale for openmap. Right now when I > scroll in using the mouse wheel the scale stops at 1:500. The minimum > scale needs to be higher for my needs. I was hoping to set the minimum > scale in the openmap.properties but I could not find any documentation > on how to do so. Can this be done in the openmap.properties file? For > example, I tried layerName.minscale = 3000 and layerName.min.scale = > 3000 but neither worked in the file. Any info is appreciated. > > Thanks, > > Ben > > Classification: UNCLASSIFIED > Caveats: NONE > > > -- > [To unsubscribe to this list send an email to "majdart@bbn.com" > with the following text in the BODY of the message "unsubscribe > openmap-users"] -- [To unsubscribe to this list send an email to "majdart@bbn.com" with the following text in the BODY of the message "unsubscribe openmap-users"]Received on Thu Jan 6 11:57:43 2011
This archive was generated by hypermail 2.1.8 : Thu Jan 06 2011 - 11:57:44 EST