[Chameleon] Scalebar and Cursorpos widgets
Bart van den Eijnden
BEN at Syncera-ITSolutions.NL
Fri Jul 22 10:12:43 EDT 2005
Kevin,
1)
do you mean embedding the scalebar into your map image? Don't use the widget then, just use the SCALEBAR in your MAP file and set STATUS EMBED.
2)
I use them next to each other, eg you can use a table like I am doing here below:
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><span class="label">Afstand:</span><cwc2 type="RulerResult" visible="true" widgetclass="inputBox"/></td>
<td><span class="label">X:</span><cwc2 type="Cursorpos" axis="X" widgetclass="inputBox"></cwc2></td>
<td><span class="label">Y:</span><cwc2 type="Cursorpos" axis="Y" widgetclass="inputBox"></cwc2></td>
<td><span class="label">Schaal: </span><cwc2 type="Scale" SUBMITONKEYPRESS="true" widgetclass="inputBox" /></td>
<td><cwc2 type="Scalebar" units="KILOMETERS" visible="true" width="200" height="3"></cwc2></td>
<td><span CLASS="label">Straal [m]: </span><input CLASS="inputBox" type="text" name="RADIUS" value="0"></td>
</tr>
</table>
Best regards,
Bart
Bart van den Eijnden
Syncera IT Solutions
Postbus 270
2600 AG DELFT
tel.nr.: 015-7512436
email: BEN at Syncera-ITSolutions.nl
>>> <kgrootendorst at baird.com> 07/22/05 03:57pm >>>
Hi,
Can somebody tell me how I embed the scalebar within my map frame?
My widget syntax is
<cwc2 type="Scalebar"
imagetype="PNG"
units="meters"
visible="true"
width="150"
height="3"
intervals="2"
backgroundcolor="255 255 255"
outlinecolor="0 0 0" <!--0 0 0 is black-->
labelcolor="0 0 0"
color="255 255 255"
transparent="true">
</cwc2>
In my .map file I don't have the SCALEBAR object - seems the widget
overrides the scalebar syntax from the .map anyway.
Also, can you have widgets displayed 'side by side'? For example,
displaying the cursor x and y position uses the following widgets:
<cwc2 type="Cursorpos" axis="X" label="Easting: " labelposition="8"
labelvalign="middle" labelclass="label" widgetclass="inputBox"></cwc2>
<cwc2 type="Cursorpos" axis="Y" label="Northing: " labelposition="8"
labelvalign="middle" labelclass="label" widgetclass="inputBox"></cwc2>
And the result reads something like:
Easting: ####
Northing: #####
I would like to display the result as Easting: #### Northing: #####
Any ideas?
Thanks.
Kevin
More information about the Chameleon
mailing list