Bjørn

I have used { set .minor_road } a lot in a paint style I use in JOSM, and I 
have plans for the same in Mapnik via pgmapcss, but until now have not have had 
opportunity to actually test it with pgmacss

Quick example:
way[highway=trunk] {
    color:  red;
    set .trunk_road;
}
way.trunk_road {
    width:   10;
}

I hope pgmapcss accepts { set tag=value; } as I can see its uses in a 
rendering, (setting default values where values are missing, etc), but this is 
for obvious reasons discouraged in an editor such as JOSM.

Aun Johnsen

> On May 11, 2017, at 21:05, Bjoern Hassler <[email protected]> wrote:
> 
> Hello all,
> 
> Would somebody be able to give an example, ideally in overpass-turbo, for the 
> following:
> 
>  Declarations may also be used to set the value of certain tags on an object:
>  { set tag=value; }   /* set a tag */
>  { set tag; }         /* set a tag to 'yes' */
> 
> and
> 
>  You can set tags beginning with a full-stop to simulate classes:
>  { set .minor_road; }
>  You can then use the .minor_road test (as above) in the selector:
>  way.minor_road
> 
> It's not really clear to me how these work. See also here 
> https://wiki.openstreetmap.org/wiki/Talk:MapCSS/0.2#Example_for_.22set.22 
> <https://wiki.openstreetmap.org/wiki/Talk:MapCSS/0.2#Example_for_.22set.22>
> if you prefer to answer on the wiki!
> 
> Many thanks!
> Bjoern
> _______________________________________________
> Mapcss mailing list
> [email protected]
> https://lists.openstreetmap.org/listinfo/mapcss

_______________________________________________
Mapcss mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/mapcss

Reply via email to