>There is now a new ShapeLab example for GeoTools 2.6.0 that avoids
>deprecated methods:
>http://geotools.org/examples/stylelab.html

Thanks - that example really helps.  I was able to get rid of all of the
deprecated methods, and I also have a greater understanding of how things
work now.

>> What I would like to do is find an easy and supported way of filling
>> individual shapes in the shapefile with a different fill color.
>> Is there an easy way to do what I am trying to accomplish? ?The ideal
end
>> state would be the ability to initialize (programmatically) each
>> SimpleFeature within a shapefile with a different fill color, then be 
>> able to dynamically change those individual fill colors as needed.

>I've just written an example of using a filter function to create a
>lookup table that matches unique values of some feature attribute to
>colours. The function can then be used to set fill and stroke
>properties of a rendering style.
>
>The example is here:
>
>http://svn.osgeo.org/geotools/branches/2.6.x/demo/example/src/main/java/o
rg>/geotools/demo/StyleFunctionLab.java
>
>I'm not sure if it's exactly what you were looking for but hopefully
>it's close enough to be useful.  I'm also not sure if the way that
>I've coded the example, with a custom filter function class, is the
>best way to do it.  Someone else here may be able to suggest an easier
>approach.
 
This does pretty much exactly what I wanted to do, and it is simple enough
for me.  I really appreciate your help.  I am now able to display a shape
layer in WW and dynamically change the styling of the features based on
the HASC codes in the shapefile.  Cool stuff.

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to