Should you require direct access to the canvas or the 2D rendering context, if you wanted to do your own drawing or whatnot, you can access those elements through the following global variables: g_map_canvas g_map_context If you want to stop or restart the interval timer which governs the rendering of the map you can access it through g_map_renderInterval ---------------------------------------------------------------------------- Each state object also has a property called myClickCallback which is a function that will be invoked when that state gets a click event. The default is null, and nothing is done when a state is clicked. EXAMPLE: when Texas is clicked, display a message function show_a_message() { var example = "TX stands for " + g_map_stateMap["TX"].myCapsName; alert(example); } // and then within the hook function inside MapConfig.js map_userSetup() { ... g_map_stateMap["TX"].myClickCallback = show_a_message; ... } ---------------------------------------------------------------------------- Let's say that somewhere in your code perhaps in a state click-callback, or perhaps by some other event you've customized on your page, you have modified the color settings for a state or many states. You need to tell the map that you've changed a state's colors so that it can render the transition to those new colors. You do this by calling the updateColor() method for each state that was modified. updateColor(highlight) takes one argument that tells the map to transition to the highlighted color or the base color. If highlight=true the state in question will end up filled with the highlight color. This should be the call you make if you alter the colors from within a click callback. Otherwise (say you just recolored the whole map) you should call the method with highlight=false. The default if you supply no arguments is false. EXAMPLE: change all states to dark gray base and light gray highlight var i = 0; for ( var abbrev in g_map_stateMap ) { var state = g_map_stateMap[abbrev]; state.myBaseRGB = [128,128,128]; state.myHighlightRGB = [200,200,200]; state.updateColor(); } EXAMPLE: change the base color of Texas to dark red, and the highlight color of Texas to light red, and do this when Texas is clicked and ensure that it is currently highlighted. function changeTexas() { g_map_stateMap["TX"].state.myBaseRGB = [200,0,0]; g_map_stateMap["TX"].state.myHighlightRGB = [255,0,0]; state.updateColor(true); } // somewhere in map_userSetup() // g_map_stateMap["TX"].myClickCallback = changeTexas;