Dear List,
I’d like to create a css styled line layer, based on attributes, with stroke symbols.
But, I can’t create two (or more) different types of lines in one style sheet. Somehow nth-stroke inherits its options.
Sorry I am newbie in css, please help how can I create great styled lines in Geoservers!
Here is my css code part:
/* @title Stream axis line*/
[Typ = 151][@scale < 50000]
- {
stroke: #646464, symbol(“shape://oarrow”);
stroke-width: 2m
}
:nth-stroke(2) {
size: 16;
stroke: #646464;
stroke-dasharray: 16 70;
stroke-width: 2m;
}
/* @title Channel axis line */
[Typ = 153][@scale < 50000]
- {
stroke: #646464, symbol(“shape://vertline”);
stroke-width: 3m
}
:nth-stroke(4) {
size: 4;
stroke: #646464;
stroke-dashoffset: 70;
stroke-width: 2m;
}
It would be nice to these settings look like this, but it looks like as in the 2nd picture. There are two different line-types, but the appearance of stroke-hatch dash-array is is the same.
How does :nth-stroke(n) works? What is ‘n’ ?
Thanks for advance:
Zsolt