NCCOOS Trac Projects: Top | Web | Platforms | Processing | Viz | Sprints | Sandbox | (Wind)

root/Chameleon/trunk/Chameleon/KeyMap/KeyMap.en-ca.doc.xml

Revision 13 (checked in by jcleary, 17 years ago)

Latest Chameleon code checkout from previous repository

Line 
1 <?xml version="1.0" encoding="UTF-8"?>
2 <ca:widgetdoc xmlns:ca="http://localhost/chameleon/utils/xml/schemas" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://localhost/chameleon/utils/xml/schemas ..\..\..\utils\xml\schemas\chameleon.xsd">
3   <ca:docinfo>
4     <ca:language>
5       <ca:value>en-ca</ca:value>
6     </ca:language>
7     <ca:docbuilddate>
8       <ca:value>1999-12-31</ca:value>
9     </ca:docbuilddate>
10     <ca:docversion>
11       <ca:value>$id:$</ca:value>
12     </ca:docversion>
13     <ca:authors>
14       <ca:person>
15         <ca:name>Doc_Builder</ca:name>
16         <ca:company>DM Solutions Group Inc.</ca:company>
17         <ca:contact>chameleon@lists.maptools.org</ca:contact>
18       </ca:person>
19     </ca:authors>
20     <ca:editors>
21       <ca:person>
22         <ca:name>Christopher R. Thorne</ca:name>
23         <ca:company>DM Solutions Group Inc.</ca:company>
24         <ca:contact>chameleon@lists.maptools.org</ca:contact>
25       </ca:person>
26       <ca:person>
27         <ca:name>Paul Spencer</ca:name>
28         <ca:company>DM Solutions Group Inc.</ca:company>
29         <ca:contact>chameleon@lists.maptools.org</ca:contact>
30       </ca:person>
31     </ca:editors>
32   </ca:docinfo>
33   <ca:identification>
34     <ca:name>
35       <ca:value>KeyMap</ca:value>
36     </ca:name>
37     <ca:chameleonpack>
38       <ca:value>TBD</ca:value>
39     </ca:chameleonpack>
40     <ca:parentgroup>
41       <ca:value>Map Widgets</ca:value>
42     </ca:parentgroup>
43     <ca:version>
44       <ca:value>2.0</ca:value>
45     </ca:version>
46     <ca:releasedate>
47       <ca:value>2005-01-10</ca:value>
48     </ca:releasedate>
49     <ca:maturitylevel>
50       <ca:value>TECHRELEASE</ca:value>
51     </ca:maturitylevel>
52     <ca:developers>
53       <ca:person>
54         <ca:name>Paul Spencer</ca:name>
55         <ca:company>DM Solutions Group Inc.</ca:company>
56         <ca:contact>chameleon@lists.maptools.org</ca:contact>
57       </ca:person>
58     </ca:developers>
59   </ca:identification>
60   <ca:descriptions>
61     <ca:description>
62       <ca:paras>
63         <ca:para>
64     The KeyMap widget is used to display a key map (or reference map) that displays the user's current extents within a larger reference frame, typically the "full" or default extents of the application.
65   </ca:para>
66   <ca:para>The KeyMap widget's attributes are based on the settings that can be used inside a MapServer MAP file REFERENCE object.  The KeyMap widget  uses the current MAP file's attributes as default values and overrides them with the attributes defined in the template.  It is a design choice whether the attributes should be defined in the MAP file or in the widget tag.  If the intention is to build a single template that can be reused for several applications with different map files and different spatial areas of interest, then it is preferable to let all the attributes be defined in the MAP file.  However, if a template is used for applications for a specific region of interest, and a standard look and feel is necessary, then it is better to define all of the attributes in the widget tag so that the KeyMap will appear the same regardless of the values in the MAP file.  Also, if when working with OGC Contexts, the attributes must be defined in the template as there is currently no support for reference maps in Context files.  Finally, if building an application that allows the user to change the projection of the map view on the fly, a projection must be defined in the KeyMap attributes in order for it to work correctly, as the MAP file does not have support for projections at this time.</ca:para>
67   <ca:para>The KeyMap's image attribute deserves some description.  Even though MapServer cannot handle remote images directly in its REFERENCE object, you can specify a URL to a KeyMap image in the widget.  Chameleon will download the image into a local temporary directory and then use that copy of the image with MapServer.  Valid ways to specify an image are by URL, by absolute file system path, or by relative file system path.  When using a relative file system path, the skinning rules are applied (see Application Developer's Guide to review relative image path searching rules).</ca:para>
68       </ca:paras>
69     </ca:description>
70     <ca:techrequirements title="Technical Requirements">
71       <ca:paras title="Valid Projection">
72         <ca:para>The MapServer file (*.map) and/or OGC Context file (*.cml) must have a defined projection. To obtain a valid projection, use EPSG projection codes. It is important to define the projection so that the extent values of both the KeyMap and main map have valid units (e.g., decimal degrees, meters, etc.), so that the map becomes geospatially significant within the application map view.</ca:para>
73       </ca:paras>
74       <ca:paras title="Same Full Map Extents">
75         <ca:para>The extents values defined in the MapServer file (*.map) and/or OGC Context file (*.xml) must equal the extents defined in the KeyMap widget tag. If they are not equal, then the key map extents rectangle and main map view will not match.</ca:para>
76       </ca:paras>     
77     </ca:techrequirements>   
78     <ca:dependancies>
79       <ca:dependancy type="None" title="">
80         <ca:para/>
81       </ca:dependancy>
82     </ca:dependancies>
83     <ca:sharedresources>
84       <ca:paras title="None Available.">
85         <ca:para/>
86       </ca:paras>
87     </ca:sharedresources>
88     <ca:embeddedhelp>
89       <ca:paras>
90         <ca:para>
91       The KeyMap widget displays a smaller image of an application's default view of the world and a red rectangle that shows the location of the main map's current view. Clicking on the key map recentres the map view at the point of the click while maintaining the current scale.
92   </ca:para>
93       </ca:paras>
94     </ca:embeddedhelp>
95     <ca:guinotes>
96       <ca:guinote type="Image" title="Base Map">
97         <ca:para>The key map is a static image defined by the designer of the application. For applications that allow uploading of arbitrary contexts, it is possible that the uploaded context could define a geographically different area than is represented by the key map.  In these cases, it is generally recommended that the key map represent the entire world.</ca:para>
98       </ca:guinote>     
99       <ca:guinote type="Image" title="Dynamic Spatial Referencing">
100         <ca:para>The key map is a very important tool to help users visually navigate within the map. It enriches users' knowledge of what they are seeing in the main map and also defines the map relationships between map layers. This is accomplished through a combination of the key map image and the rectangle that is dynamically calculated to represent the current extents of the main map.</ca:para>
101       </ca:guinote>   
102       <ca:guinote type="Selector" title="Quick Panning Navigation">
103         <ca:para>The key map has one more helpful feature - it can be used for map navigation. Unlike other navigation tools that operate only on the main map interface and are restricted to moving based on the current extents, selecting a point on the key map allows the user to rapidly move to a completely different area.</ca:para>
104       </ca:guinote>
105     </ca:guinotes>     
106   </ca:descriptions> 
107   <ca:tagstructures>
108     <ca:tagstructure title="Widget Syntax">
109       <ca:code>
110         <ca:codeblock bold="true">
111           <ca:line>&lt;CWC2 TYPE="KeyMap"</ca:line>
112         </ca:codeblock>
113         <ca:codeblock bold="false">
114           <ca:line>   ENABLED="[TRUE|FALSE]"</ca:line>
115           <ca:line>   FORMINDEX="[0 &lt; integer]"</ca:line>
116           <ca:line>   VISIBLE="[TRUE|FALSE]"</ca:line>
117           <ca:line/>
118           <ca:line>   &lt;!-- KeyMap Attributes--&gt;</ca:line>
119           <ca:line/>
120         </ca:codeblock>
121         <ca:codeblock bold="true">
122           <ca:line>   IMAGE=&quot;[path]&quot;</ca:line>         
123         </ca:codeblock>
124         <ca:codeblock bold="false">
125           <ca:line>   WIDTH ="[integer]"</ca:line>
126           <ca:line>   HEIGHT ="[integer]"</ca:line>
127           <ca:line>   COLOR ="[rgbcolor]"</ca:line>
128           <ca:line>   OUTLINECOLOR ="[rgbcolor]"</ca:line>
129           <ca:line>   MINX ="[float]"</ca:line>
130           <ca:line>   MINY ="[float]"</ca:line>
131           <ca:line>   MAXX ="[float]"</ca:line>
132           <ca:line>   MAXY ="[float]"</ca:line>
133           <ca:line>   SRS ="[string]"</ca:line>
134           <ca:line/>
135           <ca:line>   &lt;!-- Navigation Attribute Group --&gt;</ca:line>
136           <ca:line/>
137           <ca:line>   CURSORTYPE="[string]"</ca:line>
138           <ca:line>   DEFAULT="[TRUE|FALSE]"</ca:line>
139           <ca:line>   MAPID="[string]"</ca:line>
140           <ca:line>   WIDGETSTYLE="[string]" /&gt;</ca:line>         
141         </ca:codeblock>   
142       </ca:code>
143     </ca:tagstructure>
144   </ca:tagstructures>
145   <ca:examples>
146     <ca:widgetexamples>
147       <ca:example title="Example #1: Simple">
148         <ca:description>The following example assumes that the application is using a MapServer map file (*.map), as opposed to an OGC Context map file (*.cml), and that this map file contains the Reference Object which holds important key map reference information like: the path to the key map image, the size of the image (width and height, in pixels), the projection, and the extents of what the key map image represents.</ca:description>
149         <ca:code>
150           <ca:codeblock bold="false">
151             <ca:line>&lt;cwc2 type="KeyMap"/&gt;</ca:line> 
152           </ca:codeblock>
153         </ca:code>
154       </ca:example>
155       <ca:example title="Example #2: Advanced">
156         <ca:description>The following example assumes that no key map information is defined in the map file (*.map or *.cml) and that there are no default values for the color or outlinecolor attributes.</ca:description>
157         <ca:code>
158           <ca:codeblock bold="false">
159             <ca:line>&lt;cwc2 type="KeyMap"</ca:line>
160             <ca:line>   image="../htdocs/images/KeyMap.png" </ca:line>
161             <ca:line>   width="100" </ca:line>
162             <ca:line>   height="75" </ca:line>
163             <ca:line>   color="-1 -1 -1" </ca:line>
164             <ca:line>   outlinecolor="255 0 0" </ca:line>
165             <ca:line>   minx="-2594561" </ca:line>
166             <ca:line>   miny=" -712631" </ca:line>
167             <ca:line>   maxx="3467361" </ca:line>
168             <ca:line>   maxy="3840000" </ca:line>
169             <ca:line>   srs="epsg:42304"/&gt;</ca:line>
170           </ca:codeblock>
171         </ca:code>
172       </ca:example>
173     </ca:widgetexamples>
174     <ca:sharedresourceexamples>
175       <ca:example title="">
176         <ca:description/>
177         <ca:code>
178           <ca:codeblock bold="false">
179             <ca:line/>
180           </ca:codeblock>
181         </ca:code>
182       </ca:example>
183     </ca:sharedresourceexamples>
184     <ca:sampleapps>
185       <ca:sampleapp>
186         <ca:name>Hawaii Demo</ca:name>
187         <ca:appurl>www.mapsherpa.com/hawaii2/</ca:appurl>
188         <ca:description>The Hawaii Demo uses the latest 1.99 Chameleon version.</ca:description>
189       </ca:sampleapp>
190     </ca:sampleapps>
191     <ca:scriptexamples/>
192   </ca:examples>
193   <ca:attributegroups>
194     <ca:attributegroup>
195       <ca:name>Base</ca:name>
196       <ca:name>NavTool</ca:name>
197     </ca:attributegroup>
198   </ca:attributegroups>
199   <ca:widgettag>
200     <ca:attribute>
201       <ca:name>IMAGE</ca:name>
202       <ca:type>
203         <ca:value>path</ca:value>
204       </ca:type>
205       <ca:class>
206         <ca:value>Widget Only</ca:value>
207       </ca:class>
208      <ca:default>
209         <ca:value>NULL</ca:value>
210       </ca:default>
211       <ca:description>The path to the key map image (URL or directory path).</ca:description>     
212     </ca:attribute> 
213     <ca:attribute>
214       <ca:name>COLOR</ca:name>
215       <ca:type>
216         <ca:value>RGB color</ca:value>
217       </ca:type>
218       <ca:class>
219         <ca:value>Widget Only</ca:value>
220       </ca:class>
221       <ca:default>
222         <ca:value>-1 -1 -1</ca:value>
223         <ca:description>transparent</ca:description>
224       </ca:default>
225       <ca:description>The fill color for the box drawn to represent the current extents. The default is transparent.</ca:description>
226     </ca:attribute>
227     <ca:attribute>
228       <ca:name>HEIGHT</ca:name>
229       <ca:type>
230         <ca:value>integer</ca:value>
231       </ca:type>
232       <ca:class>
233         <ca:value>Widget Only</ca:value>
234       </ca:class>
235       <ca:default>
236         <ca:value>0</ca:value>
237         <ca:description>NULL</ca:description>
238       </ca:default>
239       <ca:possvalues type="range">
240         <ca:minimum>0</ca:minimum>
241         <ca:maximum>2147483647</ca:maximum>
242       </ca:possvalues>
243       <ca:description>The height (in pixels) of the key map image.</ca:description>
244     </ca:attribute>
245     <ca:attribute>
246       <ca:name>MAXX</ca:name>
247       <ca:type>
248         <ca:value>float</ca:value>
249       </ca:type>
250       <ca:class>
251         <ca:value>Widget Only</ca:value>
252       </ca:class>
253       <ca:default>
254         <ca:value>NULL</ca:value>
255       </ca:default>
256       <ca:possvalues type="range">
257         <ca:minimum>-1.#INF</ca:minimum>
258         <ca:maximum>1.#INF</ca:maximum>
259       </ca:possvalues>
260       <ca:description>The maximum X value (in geographic coordinates) that this image represents. If not set, uses the map extent defined in the map file.</ca:description>
261     </ca:attribute>
262     <ca:attribute>
263       <ca:name>MAXY</ca:name>
264       <ca:type>
265         <ca:value>float</ca:value>
266       </ca:type>
267       <ca:class>
268         <ca:value>Widget Only</ca:value>
269       </ca:class>
270       <ca:default>
271         <ca:value>NULL</ca:value>
272         <ca:description/>
273       </ca:default>
274       <ca:possvalues type="range">
275         <ca:minimum>-1.#INF</ca:minimum>
276         <ca:maximum>1.#INF</ca:maximum>
277       </ca:possvalues>
278       <ca:description>The maximum Y value (in geographic coordinates) that this image represents.  If not set, uses the map extent defined in the map file.</ca:description>
279     </ca:attribute>
280     <ca:attribute>
281       <ca:name>MINX</ca:name>
282       <ca:type>
283         <ca:value>float</ca:value>
284       </ca:type>
285       <ca:class>
286         <ca:value>Widget Only</ca:value>
287       </ca:class>
288       <ca:default>
289         <ca:value>NULL</ca:value>
290         <ca:description/>
291       </ca:default>
292       <ca:possvalues type="range">
293         <ca:minimum>-1.#INF</ca:minimum>
294         <ca:maximum>1.#INF</ca:maximum>
295       </ca:possvalues>
296       <ca:description>The minimum X value (in geographic coordinates) that this image represents. If not set, uses the map extent defined in the map file.</ca:description>
297     </ca:attribute>
298     <ca:attribute>
299       <ca:name>MINY</ca:name>
300       <ca:type>
301         <ca:value>float</ca:value>
302       </ca:type>
303       <ca:class>
304         <ca:value>Widget Only</ca:value>
305       </ca:class>
306       <ca:default>
307         <ca:value>NULL</ca:value>
308         <ca:description/>
309       </ca:default>
310       <ca:possvalues type="range">
311         <ca:minimum>-1.#INF</ca:minimum>
312         <ca:maximum>1.#INF</ca:maximum>
313       </ca:possvalues>
314       <ca:description>The minimum Y value (in geographic coordinates) that this image represents. If not set, uses the map extent defined in the map file.</ca:description>
315     </ca:attribute>
316     <ca:attribute>
317       <ca:name>OUTLINECOLOR</ca:name>
318       <ca:type>
319         <ca:value>RGB color</ca:value>
320       </ca:type>
321       <ca:class>
322         <ca:value>Widget Only</ca:value>
323       </ca:class>
324       <ca:default>
325         <ca:value>255 0 0</ca:value>
326         <ca:description>red</ca:description>
327       </ca:default>
328       <ca:description>The outline color for the box drawn to represent the current extents.</ca:description>
329     </ca:attribute>
330     <ca:attribute>
331       <ca:name>SRS</ca:name>
332       <ca:type>
333         <ca:value>string</ca:value>
334       </ca:type>
335       <ca:class>
336         <ca:value>Widget Only</ca:value>
337       </ca:class>
338       <ca:default>
339         <ca:value>NULL</ca:value>
340         <ca:description/>
341       </ca:default>
342       <ca:description>The projection in which the extents for this widget are defined. If not set, uses the map projection defined in the map file.  This is only required if the key map is in a different projection from the map or the application allows the user to change projections on the fly.</ca:description>
343     </ca:attribute>
344     <ca:attribute>
345       <ca:name>WIDTH</ca:name>
346       <ca:type>
347         <ca:value>integer</ca:value>
348       </ca:type>
349       <ca:class>
350         <ca:value>Widget Only</ca:value>
351       </ca:class>
352       <ca:default>
353         <ca:value>0</ca:value>
354         <ca:description>NULL</ca:description>
355       </ca:default>
356       <ca:possvalues type="range">
357         <ca:minimum>0</ca:minimum>
358         <ca:maximum>2147483647</ca:maximum>
359       </ca:possvalues>
360       <ca:description>The width (in pixels) of the key map image.</ca:description>
361     </ca:attribute>
362   </ca:widgettag>
363   <ca:formelements>
364     <ca:formelement>
365       <ca:name>NAV_CMD</ca:name>
366       <ca:type>
367         <ca:value>String</ca:value>
368       </ca:type>
369       <ca:description>The last command that was used to interact with the map.  This is set to NAV_KEYMAP if the user clicks on the key map image to recentre the map.</ca:description>
370     </ca:formelement>
371     <ca:formelement>
372       <ca:name>NAV_ALLOW_RECTANGLE</ca:name>
373       <ca:type>
374         <ca:value>Boolean</ca:value>
375       </ca:type>
376       <ca:description>Tracks whether the current navigation tool uses a rubber-banding box or not.  This is false if key map navigation is used.</ca:description>
377     </ca:formelement>
378     <ca:formelement>
379       <ca:name>NAV_INPUT_TYPE</ca:name>
380       <ca:type>
381         <ca:value>String</ca:value>
382       </ca:type>
383       <ca:description>The type of the last navigation command, either POINT or RECTANGLE.</ca:description>
384     </ca:formelement>
385     <ca:formelement>
386       <ca:name>NAV_INPUT_COORDINATES</ca:name>
387       <ca:type>
388         <ca:value>String</ca:value>
389       </ca:type>
390       <ca:description>The coordinates that the last command generated.  May be a single point or two points representing a rectangle. The coordinates are contained in a single string and are separated by commas.  For the key map, this is always a single point, measured in pixels from the top left corner of the image.</ca:description>
391     </ca:formelement>
392   </ca:formelements>
393   <ca:jsvariables>
394     <ca:jsvariable>
395       <ca:name>KeyMapWidget</ca:name>
396       <ca:type>
397         <ca:value>boolean</ca:value>
398       </ca:type>
399       <ca:scope>
400         <ca:value>Private</ca:value>
401       </ca:scope>
402       <ca:default>
403         <ca:value>[true|false]</ca:value>
404         <ca:description/>
405       </ca:default>
406       <ca:description>Ensure that mouse movement events are captured under Microsoft Internet Explorer.</ca:description>
407     </ca:jsvariable>
408     <ca:jsvariable>
409       <ca:name>gnMouseX</ca:name>
410       <ca:type>
411         <ca:value>float</ca:value>
412       </ca:type>
413       <ca:scope>
414         <ca:value>Private</ca:value>
415       </ca:scope>
416       <ca:default>
417         <ca:value>-1</ca:value>
418         <ca:description/>
419       </ca:default>
420       <ca:description>The current X position of the mouse over the key map.</ca:description>
421     </ca:jsvariable>
422     <ca:jsvariable>
423       <ca:name>gnMouseY</ca:name>
424       <ca:type>
425         <ca:value>float</ca:value>
426       </ca:type>
427       <ca:scope>
428         <ca:value>Private</ca:value>
429       </ca:scope>
430       <ca:default>
431         <ca:value>-1</ca:value>
432         <ca:description/>
433       </ca:default>
434       <ca:description>The current Y position of the mouse over the key map.</ca:description>
435     </ca:jsvariable>
436   </ca:jsvariables>
437   <ca:jsfunctions>
438     <ca:jsfunction>
439       <ca:name>KeyMapTrackMouseXY</ca:name>
440       <ca:scope>
441         <ca:value>Private</ca:value>
442       </ca:scope>
443       <ca:description>Called when the user moves the mouse.</ca:description>
444       <ca:parameters>
445         <ca:parameter>
446           <ca:name>e</ca:name>
447           <ca:type>
448             <ca:value>unknown</ca:value>
449           </ca:type>
450           <ca:required>
451             <ca:value>true</ca:value>
452           </ca:required>
453         </ca:parameter>
454       </ca:parameters>
455     </ca:jsfunction>
456     <ca:jsfunction>
457       <ca:name>KeyMapCaptureMouse</ca:name>
458       <ca:scope>
459         <ca:value>Private</ca:value>
460       </ca:scope>
461       <ca:description>This function captures the mouse position.</ca:description>
462     </ca:jsfunction>
463     <ca:jsfunction>
464       <ca:name>KeyMapReleaseMouse</ca:name>
465       <ca:scope>
466         <ca:value>Private</ca:value>
467       </ca:scope>
468       <ca:description>This function ends the tracking of the mouse position.</ca:description>
469     </ca:jsfunction>
470     <ca:jsfunction>
471       <ca:name>KeyMapClicked</ca:name>
472       <ca:scope>
473         <ca:value>Private</ca:value>
474       </ca:scope>
475       <ca:description>This function submits when the mouse is clicked.</ca:description>
476     </ca:jsfunction>
477   </ca:jsfunctions>
478 </ca:widgetdoc>
Note: See TracBrowser for help on using the browser.