Map widget interacted with charting.
Support rendering Americas, AsiaPacific, ContinentalEurope, EuropeMiddleEastAfrica, USStates, WorldCountries, and WorldCountriesMercator by default.
Parameter | Type | Description |
---|---|---|
container | Node | map container html node/id. |
shapeData | String | Object | map shape data json object, or url to json file. |
See the dojox/geo/charting/Map reference documentation for more information.
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
stack to data range, e.g: [{name:'label 1', min:20, max:70, color:'#DDDDDD'},{...},...]
Parameter | Type | Description |
---|---|---|
markerData | undefined |
creates a transform animation object (between two transforms) used internally
Parameter | Type | Description |
---|---|---|
onShape | Object | The target shape. |
fromTransform | Object | the start transformation (when animation begins) |
toTransform | Object | the end transormation (when animation ends) |
onAnimationEnd | function | callback function to be executed when the animation completes. |
returns the bounds {x:, y:, w: ,h:} of the DOM node container in absolute coordinates
inits this Map component.
Parameter | Type | Description |
---|---|---|
shapeData | undefined |
tests whether the application is running on a mobile device (android or iOS)
sets ranges of data values (associated with label, color) to style map data values
Parameter | Type | Description |
---|---|---|
series | url | Object[] | Either an url or an array of range objects such as : [{name:'label 1', min:20, max:70, color:'#DDDDDD'},{...},...] |
set this component's transformation so that the specified area fits in the component (centered)
Parameter | Type | Description |
---|---|---|
mapArea | Object | the map area that needs to fill the component expressed as {x,y,w,h} |
pixelMargin | int | a margin (in pixels) from the borders of the Map component. |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
set this component's transformation so that the whole map data fits in the component (centered)
Parameter | Type | Description |
---|---|---|
pixelMargin | int | a margin (in pixels) from the borders of the Map component. |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
returns the map coordinates of the center of this Map component.
the center in map coordinates
returns the scale of this Map component.
the scale
converts map coordinates to screen coordinates given the current transform of this Map component
Parameter | Type | Description |
---|---|---|
mapX | Number | the x coordinate of the point to convert. |
mapY | Number | the y coordinate of the point to convert. |
{x:,y:} the screen coordinates corresponding to the specified map coordinates.
resize the underlying GFX surface to accommodate to parent DOM Node size change
Parameter | Type | Description |
---|---|---|
adjustMapCenter | boolean | keeps the center of the map when resizing the surface |
adjustMapScale | boolean | adjusts the map scale to keep the visible portion of the map as much as possible |
animate | boolean* |
converts screen coordinates to map coordinates given the current transform of this Map component
Parameter | Type | Description |
---|---|---|
screenX | Number | the x coordinate of the point to convert. |
screenY | Number | the y coordinate of the point to convert. |
the map coordinates corresponding to the specified screen coordinates.
sets the property name of the dataStore items to use as value (see Feature.setValue function)
Parameter | Type | Description |
---|---|---|
prop | String | the property |
sets the function that extracts values from dataStore items,to use as Feature values (see Feature.setValue function)
Parameter | Type | Description |
---|---|---|
valueFunction | function | the function |
populate data for each map feature from fetched data store
Parameter | Type | Description |
---|---|---|
dataStore | dojo/data/ItemFileReadStore | the dataStore to fetch the information from |
dataBindingProp | String | sets the property name of the dataStore items to use as value |
set this component's transformation so that the map is centered on the specified map coordinates
Parameter | Type | Description |
---|---|---|
centerX | float | the X coordinate (in map coordinates) of the new center |
centerY | float | the Y coordinate (in map coordinates) of the new center |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
set this component's transformation so that the map is centered on the specified map coordinates and scaled to the specified scale.
Parameter | Type | Description |
---|---|---|
centerX | float | the X coordinate (in map coordinates) of the new center |
centerY | float | the Y coordinate (in map coordinates) of the new center |
scale | float | the scale of the map |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
set this component's transformation so that the map is scaled to the specified scale.
Parameter | Type | Description |
---|---|---|
scale | Number | the scale ratio. |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
set this component's transformation so that the map is scaled to the specified scale, and the specified point (in map coordinates) stays fixed on this Map component
Parameter | Type | Description |
---|---|---|
scale | Number | the scale ratio. |
fixedMapX | float | the X coordinate (in map coordinates) of the fixed screen point |
fixedMapY | float | the Y coordinate (in map coordinates) of the fixed screen point |
animate | boolean | true if the transform change should be animated |
onAnimationEnd | function | a callback function to be executed when the animation completes (if animate set to true). |
import markers from outside file, associate with map feature by feature id which identified in map shape file, e.g: "NY":"New York"
Parameter | Type | Description |
---|---|---|
markerFile | String | outside marker data url, handled as json style. data format: {"NY":"New York",.....} |
Parameter | Type | Description |
---|---|---|
item | undefined |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
Parameter | Type | Description |
---|---|---|
newItem | undefined | |
parentItem | undefined |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
Parameter | Type | Description |
---|---|---|
item | undefined | |
attribute | undefined | |
oldValue | undefined | |
newValue | undefined |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
Invoked when the specified feature is clicked.
Parameter | Type | Description |
---|---|---|
feature | dojox/geo/charting/Feature | A Feature. |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
Invoked when the specified feature is hovered.
Parameter | Type | Description |
---|---|---|
feature | dojox/geo/charting/Feature | A Feature. |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>
Invoked when the specified feature has been zoomed.
Parameter | Type | Description |
---|---|---|
feature | dojox/geo/charting/Feature | A Feature. |
var usaMap = new dojox.geo.charting.Map(srcNode, "dojotoolkit/dojox/geo/charting/resources/data/USStates.json"); <div id="map" style="width:600px;height:400px;"></div>