Select to view content in your preferred language

Problem with overview map size

1244
4
01-29-2014 06:00 AM
PaulHuppé
Deactivated User
Hi,
I am trying to add the Overview Map Widgit to a specific DIV and to give it a specific size. Part of my code looks like this:

                            overviewMapDijit = new esri.dijit.OverviewMap(
                                {map: mymap,
                                baseLayer: bLayer,
                                height: 80,
                                width: 200},
                                ovDiv);
                        }
                        overviewMapDijit.startup();


But, instead of getting an Overview Map of 200x80 pixels, I get a 400x400 pixel Overview Map.  Why does it not respect the size I give it?  Here is a picture showing the elements.
[ATTACH=CONFIG]30934[/ATTACH]

Any ideas?
Thanks,
Paul
0 Kudos
4 Replies
PaulHuppé
Deactivated User
Hi,
I did not get any replies yet. BTW, I am using version 3.8 of the API.
Paul
0 Kudos
JeffPace
MVP Alum
Width of the overview map dijit in screen pixels. The default value is 1/4th the width of the map, unless the HTML element referred to by srcNodeRef has a valid size.



Do you have a size set on "ovDiv"
0 Kudos
PaulHuppé
Deactivated User
Yes, the size is set with the following class definitions:
.gcviz-overviewMap {
  width: 245px!important;
  height: 100px!important;
}
0 Kudos
PaulHuppé
Deactivated User
I set the class to "gcviz-overviewMap", but it gets replaced by the class "esriOverviewMap" when the widget is put in the DIV.
0 Kudos