Collaborating on a spec would be great. Cascadenik is so much more legible
than SLD, but you're right, that's probably because I'm so comfortable with
CSS. One advantage to using JSON-compliant markup is that styles don't have
to be static. This works well for pure JavaScript/HTML renderers like
Cartagen and OpenLayers, but not as well for Mapnik... maybe there's a way
to gracefully degrade.
Example:
way: {
strokeStyle: function() {
return "#"+(parseInt((this.user),36).toString(16)+"000000").truncate(6,"")
},
lineWidth: 2,
fillStyle: "white"
}Kind of hacky, but it yields: http://map.cartagen.org/?gss=http://unterbahn.com/cartagen/style.gss ...that is, it colors ways by author name - i see a lot of "crschmidt" in there :-) I'm looking through the SLD spec and it looks like it does not specify event handlers, though of course OpenLayers has the Control class. It'd be great to preserve that kind of scripting power in a style standard. Another thing I was wondering about is whether there's a source for OSM data in GeoJSON? It would be great not to have to parse OSM xml into json for every request, so I'm considering running a weekly planet.osm source to serve GeoJSON... is that available already? Best, Jeff On Mon, Apr 27, 2009 at 11:11 AM, Chris Holmes <[email protected]> wrote: > > > Christopher Schmidt wrote: > >> On Sun, Apr 26, 2009 at 02:41:36PM -0400, Jeffrey Warren wrote: >> >>> Absolutely, Christopher - I'm a big admirer of the OpenLayers community, >>> and >>> the things you can do with it are impressive. Still, I haven't seen an >>> implementation of an entire map in vector on the client side - examples >>> such >>> as this: >>> http://openlayers.org/dev/examples/wfs-reprojection.html >>> >>> ...which are great, still use a pre-rendered tile base layer. What I'm >>> hoping is that by sending *only* vector data, mappers can completely >>> design >>> maps from the ground up with their own GSS stylesheets. >>> >> >> Like http://crschmidt.net/mapping/choropleth.html ? (Note that the >> styling suppot here was written before SLD support was implemented, and >> could now be done entirely using SLD instead of custom OpenLayers >> rules.) >> >> > Contributing to OpenLayers++ > > Cartagen looks to have some cool ideas, but it'd be really awesome if it > was done by improving OpenLayers core and being a thin layer on top that's > optimized for Android and iPhone. > > We've been thinking about GSS/Cascadenik type ideas, but having it go to > and from OpenLayers Style objects, as an alternative to SLD. See > http://opengeo.org/services/coredevelopment/openlayers/css_styling/ > > It'd be really great to have a web designer friendly alternative to SLD. > It may be a bit too early right now, but at some point we should start an > adhoc spec group, following on the successes of GeoRSS, GeoJSON, and WMS-C, > to make a standard for CSS for Map Styling. It'd be great to be able to > share styles between GeoServer, Mapnik and MapServer, and to use Openlayers > as a cross platform style editor (or the common basis for different > approaches to map styling). We'd be interested in collaborating on a spec, > and on implementations for OpenLayers and GeoServer. > > Chris. > > Regards, >> > > -- > Chris Holmes > OpenGeo - http://opengeo.org > Expert service straight from the developers. >
_______________________________________________ Geowanking mailing list [email protected] http://geowanking.org/mailman/listinfo/geowanking_geowanking.org
