[Mapcss] Subpart syntax

Sebastian Klein bastikln at googlemail.com
Thu Feb 3 18:46:09 GMT 2011

Richard Fairhurst wrote:
> Hello MapCSS list - it's been a while. :)
> I'm doing some work on Halcyon/P2's MapCSS implementation.
> Am I right in thinking that
> http://wiki.openstreetmap.org/wiki/Talk:MapCSS/0.2#Dealing_with_z-index_and_cascades_more_sensibly 
> is the current agreed subpart spec?

Its a draft, so if you have suggestions / criticism, we should discuss it.

Let me suggest to change the symbol from double colon to something 
unoccupied, e.g. a slash:

way[access=private]::access  --->   way[access=private]/access

The CSS spec has ::first_letter and ::before as examples for so called 
pseudo elements [1]. The first makes the rule apply only to the first 
letter and the latter inserts text like paragraph numbering into the 
document [2]

What we have in mapcss is actually more clear cut: Create an extra 
world/layer/cascade for each subpart, the individual layers are 
independent from each other. In the end, render all of them at once 
(respecting z-index).

This has not much to do with what CSS defines as pseudo element.

Shall we copy the draft from the Talk page to MapCSS/0.2? Do you prefer 
double colon or slash symbol?

[1] <http://www.w3.org/TR/2009/PR-css3-selectors-20091215/#pseudo-elements>
[2] <http://www.w3.org/TR/2009/CR-CSS2-20090908/generate.html>


More information about the Mapcss mailing list