[Chameleon] ROIFeatureTool

William Bronsema wbronsema at dmsolutions.ca
Fri Oct 5 09:51:32 EDT 2007


Hi Robert,

Sounds like everything is setup fine, you are just not getting anything
selected.  If nothing is selected however, you should get a note in the
upper left corner of the map image saying something like “no results”. 
Could it be that the feature that is being selected is so small that you are
not seeing it?

As for the buffer value, you need to set it first, then pick a feature on
the map.  i.e. if your map units are metres, set the buffer value in the box
to “5000”  to create a 5km buffer around the feature, then pick a feature on
the map.  If there is an issue with the feature being too small to see that
it is selected, setting a large buffer should help you see it.

Cheers,
Bill


William Bronsema
Senior Applications Specialist
DM Solutions Group Inc.

___________________________________
http://www.dmsolutions.ca

From: Buchholz, Robert [mailto:Robert.Buchholz at LUA.Brandenburg.de] 
Sent: Friday, October 05, 2007 9:36 AM
To: William Bronsema
Cc: chameleon at lists.maptools.org
Subject: AW: [Chameleon] ROIFeatureTool

 

Hi Bill 
 
I hope this is readable... 
 > Hi Robert,

 > In the Chameleon samples the “selected layer” is the one in the legend
that is has it’s radio button selected, not it’s checkbox.  The checkbox is
for layer  
> status.Unfortunately in the Chameleon ROI sample the feature ROI does not
work because all the layers are WMS and/or rasters.

1. Problem: No WMS displayed
2. Problem: Having integrated a .shp layer, set the radio button to
activate, selecting add mode, selecting rectangle, polygon and circle is
working. But Selecting existing features is not working. What mode do I have
to set for proper use of selecting by existing feature? I assume it schould
not matter.
 
 
 > As a bit of background, ROIs are regions of interest.  Take the rectangle
ROI for instance.  It will define a rectangle on the map as a region of
interest that other widgets 
>  can   work with.  If you pick “add mode” then as you add multiple
rectangles, they will accumulate on the map in an additive way.  If you pick
“replace mode” then when you 
>  create a second rectangle, it replaces the first only ever allowing you
to have a single rectangle region of interest.  “Subtract mode” allows you
to create holes in  
> your  region  
> of interest.  Create a rectangle with “add” or “replace” mode then switch
to “subtract” mode and draw a smaller rectangle inside the first.  You will
see a “hole” appear in  
> the   ROI.
3. Thanks for your explanation. It works!
 > Other shapes can be used and mixed and matched – circles, polygons, and
features.  The feature ROI only works on vector layers (ie. road
shapefile).   
> The feature ROI is just a click type tool, no dragging.  When you try to
drag, the black bar with circle is indicating that dragging is not possible.
4. AHA
 > The error report widget only reports errors with loading widgets. 
5. When I integrate to my sample_ogc.html this:
      <CWC2 TYPE="ErrorReport"
            POPUPWIDTH="500"
            POPUPHEIGHT="400"
            TOOLBAR="false"
            STATUS="false"
            MENUBAR="false"
            VISIBLE="false"
            IMAGE="images/icon_error.png"
            IMAGEWIDTH="18"
            IMAGEHEIGHT="18"
            IMAGETIP="Display Error Report"
            LABEL="Error Report"/>
The result is short appearance of the error window and it's dissolving.
(before it stays but always show: No Errors) 
>   It does not track any javascript or apache errors.  The Apache error you
are getting can be ignored, 
>  it is a common notice with the ms4w installation.

6. Good to know!
 > At this point I would try the app and be sure that the correct vector
layer is being selected in the legend via it’s radio button and make sure
you are in “add” or 
>  “replace” mode.  Be sure that you have the ROI feature tool selected,
then try to click on a feature on the map for the selected layer.
7.I have a correct vector layer, selected it by the radio button, add mode,
select ROI feature tool click on a feature....
The supposed layer get not selected (no highlighting)
Here is my widget:
  <td><CWC2 TYPE="ROIFeatureTool" Visible="true" styleresource="NavButtons"
Image="images/icon_roi_feature.png" ImageTip="Define an ROI by selecting
existing features" buffer="true" ToolSet="Navigation">
          <image state="normal"/>
          <image state="selected"/>
          <image state="hover"/>
      </cwc2></td>   
 
The buffer="true" shows a textbox with "0" at beginning. I can change the
value, press return and that's it. I assume: No buffer is drawn, because no
feature is selected.
 
Regards,
Robert

HTH

Cheers,
Bill

William Bronsema
Senior Applications Specialist
DM Solutions Group Inc.

___________________________________
http://www.dmsolutions.ca
________________________________________




More information about the Chameleon mailing list