wiki:Styles/sac_scale

Languages:

Icon sac_scale

Description

The mappaint style "sac_scale" displays the value of sac_scale=* coloured.

Additional it reports wrong values of sac_scale and displayes black circles on the waynodes if the ways is tagged with highway=via_ferrata or via_ferrata=yes. See following example screenshots.

You can adjust the colours in the preference window of JOSM.

You can use the sac_scale mappaint style together with the default JOSM internal mappaint style. You can disable the names of highways in the style settings of the internal style if they bother you.

For ideas/questions/bugs/suggestions or similar please write a message to Klumbumbus.

Feel free to translate this wiki page into more languages. Already translated languages see top right.

(NOZIP)

(NOZIP)

(data used for image ©OpenStreetMap contributors ODbL)

Code

meta
{
        title: "sac_scale";
        version: "1.013_2015-12-28";
        description: "Displays sac_scale=* coloured.";
        icon: "sac_scale_icon.svg";
        author: "Klumbumbus";
        link: "http://josm.openstreetmap.de/wiki/Styles/sac_scale";
        watch-modified: true;
        /* min-josm-version: "????"; not sure if there is one */
}

meta[lang=de]
{
        title: "sac_scale";
        description: "Zeigt sac_scale=* farbig an.";
        link: "http://josm.openstreetmap.de/wiki/De:Styles/sac_scale";
}

/* disable tiger layer from default internal mappaint style */
way["tiger:reviewed"=no]::core_tiger
{
        opacity: 0;
}

/* display sac_scale on ways */
way["sac_scale"="hiking"]::sac_scale,
way["sac_scale"="mountain_hiking"]::sac_scale,
way["sac_scale"="demanding_mountain_hiking"]::sac_scale,
way["sac_scale"="alpine_hiking"]::sac_scale,
way["sac_scale"="demanding_alpine_hiking"]::sac_scale,
way["sac_scale"="difficult_alpine_hiking"]::sac_scale
{
        set correct_value;
        opacity: 0.8;
        width: 10;
        z-index: -1;
}
way|z17["sac_scale"="hiking"]::sac_scale,
way|z17["sac_scale"="mountain_hiking"]::sac_scale,
way|z17["sac_scale"="demanding_mountain_hiking"]::sac_scale,
way|z17["sac_scale"="alpine_hiking"]::sac_scale,
way|z17["sac_scale"="demanding_alpine_hiking"]::sac_scale,
way|z17["sac_scale"="difficult_alpine_hiking"]::sac_scale
{
        width: 8;
}
way|z-16["sac_scale"="hiking"]::sac_scale,
way|z-16["sac_scale"="mountain_hiking"]::sac_scale,
way|z-16["sac_scale"="demanding_mountain_hiking"]::sac_scale,
way|z-16["sac_scale"="alpine_hiking"]::sac_scale,
way|z-16["sac_scale"="demanding_alpine_hiking"]::sac_scale,
way|z-16["sac_scale"="difficult_alpine_hiking"]::sac_scale
{
        width: 5;
}
way["sac_scale"="hiking"]::sac_scale
{
        color: hiking#ffee00; /* yellow */
}
way["sac_scale"="mountain_hiking"]::sac_scale
{
        color: mountain_hiking#FF9714; /* orange */
}
way["sac_scale"="demanding_mountain_hiking"]::sac_scale
{
        color: demanding_mountain_hiking#FF0000; /* red */
}
way["sac_scale"="alpine_hiking"]::sac_scale
{
        color: alpine_hiking#6fedfb; /* light blue */
}
way["sac_scale"="demanding_alpine_hiking"]::sac_scale
{
        color: demanding_alpine_hiking#2437ff; /* blue */
}
way["sac_scale"="difficult_alpine_hiking"]::sac_scale
{
        color: difficult_alpine_hiking#6b4eb1; /* purple */
}

/* display via_ferrata circles */
way["via_ferrata"="yes"] > node|z16-::via_ferrata,
way["highway"="via_ferrata"] > node|z16-::via_ferrata
{
        symbol-shape: circle;
        symbol-stroke-color: black;
        symbol-size: 15;
        symbol-stroke-width: 1;
}

/* report wrong value of sac_scale */
way["sac_scale"]!.correct_value::sac_scale
{
        color: yellow;
        dashes-background-color: red;
        dashes: 4,24;
        opacity: 1;
        width: 5;
        text: tr("no correct value for sac_scale!");
        text-color: black;
        font-size: 11;
        text-halo-color: red;
        text-halo-radius: 2;
        casing-width: 1;
        casing-color: yellow;
}

Styles_sac_scale-style.mapcss, Styles_sac_scale.zip

Last modified 21 months ago Last modified on 2015-12-29T00:18:37+01:00

Attachments (3)

Download all attachments as: .zip