Changes between Initial Version and Version 1 of Nb:Styles/HealthBoundary


Ignore:
Timestamp:
2025-03-15T22:50:50+01:00 (11 months ago)
Author:
paleid
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Nb:Styles/HealthBoundary

    v1 v1  
     1[[TranslatedPages(revision=10)]]
     2
     3= [[Image(Styles/HealthBoundary:health_boundaries_icon.svg,36,middle,inline)]] Helse Grenser =
     4[[PageOutline(2-9)]]
     5
     6== Beskrivelse ==
     7
     8Stilen "Helse Grenser" hjelper til med å overvåke og redigere grensepolygoner. Ved å zoome ut er det enkelt å overvåke områder som allerede er dekket, med skjulte noder og tynne linjer. Redigering er forenklet med fremhevede tilkoblingsnoder, uåpnede polygoner, osv. Områdenavn er også fremhevet.
     9
     10=== Stilinnstillinger ===
     11Det finnes '''5 stilinnstillinger''' for å velge hvilke Helsenivåer som skal vises. En eller flere Helsenivåer kan velges samtidig. Du kan endre alternativene i [wiki:Help/Dialog/MapPaint/StyleSettings Kartstil-dialogvinduet] i sidepanelet til høyre. Hvis dialogvinduet ikke vises, kan du aktivere det i menyen ''Vinduer''. I ''Kartstil-dialogvinduet'', høyreklikk på ''Helse Grenser'' og pek deretter på ''Stilinnstillinger''. Etter at du har endret en innstilling, oppdateres kartstilen automatisk.
     12
     13{{{
     14#!style type="mapcss"
     15
     16meta {
     17  title: "Helse Grenser";
     18  version: "1.[[revision]]_[[date]]";
     19  description: "Farger Helse Grense Polygoner og noder. Den hjelper til med å overvåke og redigere Grenser. Parameteralternativer lar deg velge Helsenivåer som skal vises.";
     20  icon: "health_boundaries_icon.svg";
     21  author: "pierzen";
     22  link: "https://josm.openstreetmap.de/wiki/Styles/HealthBoundary";
     23}
     24
     25canvas {
     26    fill-color: #ffffea;
     27        default-points: false;
     28        default-lines: false;
     29}
     30
     31/* Innstillingsalternativer - Velg Territorielag (ja/nei) */
     32
     33setting::allow_health_level_4 {
     34  type: boolean;
     35  label: tr("tillat health_level=4");
     36  default: false;
     37}
     38setting::allow_health_level_5 {
     39  type: boolean;
     40  label: tr("tillat health_level=5");
     41  default: true;
     42}
     43setting::allow_health_level_6 {
     44  type: boolean;
     45  label: tr("tillat health_level=6");
     46  default: false;
     47}
     48setting::allow_health_level_8 {
     49  type: boolean;
     50  label: tr("tillat health_level=8");
     51  default: true;
     52}
     53setting::allow_health_level_10 {
     54  type: boolean;
     55  label: tr("tillat health_level=10");
     56  default: false;
     57}
     58
     59/*------------------------------------------------------------------------
     60 Først: minimaliser utseende for områder, veier og noder
     61 ------------------------------------------------------------------------*/
     62
     63area {
     64        z-index: -1;
     65        fill-color: #FFFFAA; fill-opacity:0;
     66        text-color: #FFBBAA; opacity: 0; text-opacity: 0;
     67}
     68way {
     69        z-index: -1;
     70    width: 0.1; casing-width:0; casing-opacity: 0;
     71        color: #FFFFAA; opacity:0;
     72}
     73node {
     74        z-index: -1;
     75    symbol-shape: square; symbol-size: 0; symbol-stroke-width:0.1 ;
     76        symbol-stroke-color: #FFFFAA; symbol-stroke-opacity:0;
     77        symbol-fill-opacity:0; icon-opacity: 0;
     78}
     79
     80/*------------------------------------------------------------------------
     81 definerer helse grenser pseudo-lag ::layer
     82 + forskjellige farger for hvert health_level
     83 + sett health_way_selected
     84 ------------------------------------------------------------------------*/
     85
     86area[boundary][setting("allow_health_level_10")][health_level=10]::health_level,
     87area[boundary][setting("allow_health_level_10")][health_level=10] >way::health_level
     88{       
     89   set health_area_selected;
     90   z-index: 11;
     91   fill-color:green; fill-opacity:0.2;
     92   font-size: 1;
     93   text-color: white;
     94   text: name;
     95   text-position: center;
     96   font-size:1;
     97   width:2;
     98   color:green;
     99   opacity: 1; text-opacity: 1;
     100  } 
     101area|z12-[health_level=10]::health_level {      font-size: 14; opacity: 1;}
     102
     103area[boundary][setting("allow_health_level_8")][health_level=8]::health_level,
     104area[boundary][setting("allow_health_level_8")][health_level=8] > way::health_level
     105{
     106   set health_area_selected;
     107   z-index: 13;
     108   fill-color:blue; fill-opacity:0.2;
     109   font-size: 1;
     110   text-color: navy;
     111   text: name;
     112   text-position: center;
     113   width:3;
     114   color:navy;
     115   opacity: 1; text-opacity: 1;
     116 } 
     117area|z10-[health_layer=8]::health_level {       font-size: 14;}
     118 
     119area[boundary][setting("allow_health_level_6")][health_level=6]::health_level,
     120area[boundary][setting("allow_health_level_6")][health_level=6] > way::health_level
     121{
     122    set health_area_selected;
     123        z-index: 15;
     124   fill-color:darkcyan; fill-opacity:0.2;
     125   font-size: 15;
     126   text-color: blue;
     127   text: name;
     128   text-position: center;
     129   width: 3;
     130   color:blue;
     131   opacity: 1; text-opacity: 1;
     132   }
     133area[boundary][setting("allow_health_level_5")][health_level=5]::health_level,
     134area[boundary][setting("allow_health_level_5")][health_level=5] > way::health_level
     135{
     136   set health_area_selected;
     137   z-index: 16;
     138   fill-color:lightcoral; fill-opacity:0.2;
     139   font-size: 18;
     140   text-color: brown;
     141   text: name;
     142   text-position: center;
     143   width: 4;
     144   color: brown;
     145   opacity: 1; text-opacity: 1;
     146  }
     147
     148area[boundary][setting("allow_health_level_4")][health_level=4]::health_level,
     149area[boundary][setting("allow_health_level_4")][health_level=4]> way::health_level
     150{
     151   set health_area_selected;
     152   z-index: 20;
     153   fill-color:crimson; fill-opacity:0.2;
     154   font-size: 20;
     155   text-color: rose;
     156   text: name;
     157   text-position: center;
     158   width:  5;
     159   color: crimson;
     160   opacity: 1; text-opacity: 1;
     161}
     162
     163/*------------------------------------------------------------------------
     164 veier - definerer helse grenser pseudo-lag ::layer
     165 + forskjellige farger for hvert health_level
     166 + sett health_way_selected
     167 ------------------------------------------------------------------------*/
     168
     169way[boundary][setting("allow_health_level_10")][health_level=10]::health_level {       
     170   set health_way_selected;
     171        width:2;
     172        color:green;
     173        opacity: 1;
     174        casing-color: yellow;
     175        casing-width: 3;
     176        casing-opacity: 0.7;
     177  } 
     178
     179way[boundary][setting("allow_health_level_8")][health_level=8]::health_level
     180{
     181   set health_way_selected;
     182        width:3;
     183        color:navy;
     184        opacity: 1;
     185        casing-color: yellow;
     186        casing-width: 3;
     187        casing-opacity: 0.7;
     188  } 
     189 
     190way[boundary][setting("allow_health_level_6")][health_level=6]::health_level
     191{
     192   set health_way_selected;
     193   text-position: center;
     194   width: 3;
     195   color:blue;
     196        opacity: 1;
     197   casing-color: yellow;
     198   casing-width: 3;
     199   casing-opacity: 0.7;
     200   }
     201
     202way[boundary][setting("allow_health_level_5")][health_level=5]::health_level
     203{
     204   set health_way_selected;
     205        width: 4;
     206        color: brown;
     207        opacity: 1;
     208        opacity:0.3;
     209        casing-color: yellow;
     210        casing-width: 3;
     211        casing-opacity: 0.7;
     212  }
     213
     214way[boundary][setting("allow_health_level_4")][health_level=4]::health_level
     215{
     216    set health_way_selected;
     217        width:  5;
     218        color: crimson;
     219        opacity: 1;
     220        casing-color: yellow;
     221        casing-width: 3;
     222        casing-opacity: 0.7;
     223}
     224
     225/*------------------------------------------------------------------------
     226 noder - legg til helse grenser pseudo-lag ::layer
     227 + sett health_nodes_selected
     228 ------------------------------------------------------------------------*/
     229
     230area[boundary][setting("allow_health_level_10")][health_level=10] > node::health_level,
     231area[boundary][setting("allow_health_level_8")][health_level=8] > node::health_level,
     232area[boundary][setting("allow_health_level_6")][health_level=6] > node::health_level,
     233area[boundary][setting("allow_health_level_5")][health_level=5] > node::health_level,
     234area[boundary][setting("allow_health_level_4")][health_level=4] > node::health_level { 
     235   set health_nodes_selected;
     236  } 
     237
     238/*------------------------------------------------------------------------
     239 helse grenser pseudo-lag ::layer
     240 områder - veier   ------------------------------------------------------------------------*/
     241       
     242area[boundary=health][!name]:closed::health_level
     243{
     244        text-color:yellow;
     245        text: eval("name ?");
     246        text-opacity: 1;
     247        font-opacity: 1;
     248        fill-opacity: 0.4;
     249        }
     250
     251area[boundary=health]:selected::health_level
     252{
     253  casing-width: 6; casing-color:red; casing-opacity:0.8;
     254}       
     255
     256
     257area|z12-[boundary=health]:unclosed_multipolygon::health_level
     258{
     259  text: name;
     260  text-halo-radius: 10;
     261  text-halo-color: yellow;
     262  text-halo-opacity: 0.3;
     263  font-size: 14;
     264  text-opacity: 1;
     265        }
     266
     267area[boundary=health]:unclosed_multipolygon::health_level > way
     268{
     269  text:"";
     270  casing-width:6;
     271  casing-dashes: 10,10;
     272  casing-color:yellow;
     273  casing-opacity:1; 
     274        }
     275       
     276/*------------------------------------------------------------------------
     277 helse grenser
     278 fargelegg
     279 ------------------------------------------------------------------------*/
     280
     281area::health_layer > node|z1-13 {
     282        symbol-size:0.01;
     283        symbol-shape: square;
     284        symbol-stroke-color: #00ffff;
     285        symbol-stroke-width: 0.01;
     286        symbol-fill-color: #00FFFF;
     287        symbol-fill-opacity:0;
     288        symbol-stroke-opacity: 0;
     289}
     290
     291node|z14-[(parent_tag(health_level))]::health_level
     292{
     293        symbol-size:4;
     294        symbol-shape: square;
     295        symbol-stroke-color: #00ffff;
     296        symbol-stroke-width: 1;
     297        symbol-fill-color: #FFAAFF;
     298        symbol-fill-opacity:0.8;
     299        symbol-stroke-opacity: 0.8;
     300}
     301
     302
     303node|z12-[(parent_tag(health_level))]:connection::health_level {
     304        symbol-size:10;
     305        symbol-shape: circle;
     306        symbol-stroke-color: #00ffff;
     307        symbol-stroke-width: 2;
     308        symbol-stroke-opacity: 1;
     309        symbol-fill-color: crimson;
     310        symbol-fill-opacity:1;
     311        opacity: 1;
     312}
     313
     314/* tilkoblingsnoder - uåpnede områder */
     315
     316area|z11-!:closed[boundary=health]::health_level >[index=1] node!:connection,
     317area|z11-!:closed[boundary=health]::health_level >[index=-1] node!:connection
     318{
     319        symbol-fill-color: yellow;
     320        symbol-stroke-color: crimson;
     321        symbol-stroke-width: 4;
     322        symbol-shape: triangle;
     323        symbol-size: 30;
     324        symbol-stroke-opacity:1;
     325        symbol-fill-opacity:1;
     326}
     327}}}