Template talk:TagDef

From OpenStreetMap Wiki
Jump to navigation Jump to search

Usage

{{TagDef
   |key=
   |label=
   |state=
   |rendered_value=
   |description=
   |onnode=
   |onarea=
   |onway=
   |onrelation=
   |imgname_rendering=
   |imgname_photo=
   |dorender=   
}}
  • key (mandatory): the key of the tag, i.e. highway or leisure
  • label (optional): the predefined value of the tag, i.e. residential or park. Can bei omitted, if no label is defined, i.e. for a tag like name or maxheight
  • state (optional): one of four states in the life cycle of a tag: proposed, rejected, accepted or deprecated. Default is accepted.
  • rendered_value (optional): the text to be displayed on the wiki as value. Can be used for tag declarations which include value descriptions whithout formally definiting them as labels. Examples:
    • the tag access describes its labels as "yes / designated / private / permissive / destination / unknown / no" without formally definiting each label.
    • the tag maxheight describes its value as "Number"
If both label and rendered_value are present, rendered_value is displayed on the wiki.
  • description (optional): the tag description. This description is rendered on the wiki in the column description. And becomes the localized description for the OSM tag.
  • onnode (optional): either yes (tag is applicable on OSM nodes) or no (tag isn't applicable on OSM nodes). Default value is no.
  • onarea (optional): either yes (tag is applicable on OSM areas) or no (tag isn't applicable on OSM areas). Default value is no.
  • onway (optional): either yes (tag is applicable on OSM way) or no (tag isn't applicable on OSM way). Default value is no.
  • onrelation (optional): either yes (tag is applicable on OSM relation) or no (tag isn't applicable on OSM relation). Default value is no.
  • imgname_rendering (optional): the name of the image to be displayed in the column rendering. If omitted, no image is displayed.
  • imgname_photo (optional): the name of the photo to be displayed in the column "photo". If omitted, no image is displayed.
  • dorender (optional): either yes (render this OSM tag definition on the wiki) or no (don't render this OSM tag definition on the wiki). Default value is yes.

Examples =

Declaring name=*

{{TagDef
   |key=name
   |type=string
   |rendered_value=User Defined
   |description=Roads accessing or around residential areas but which are not a classified or unclassified highway. 
   |onnode=yes
   |onarea=yes
   |onway=yes
   |onrelation=yes
}}

Declaring highway=residential

{{TagDef
   |key=highway
   |label=residential
   |description=The common default name. (Note: For disputed areas, please use the name as displayed on e.g. street signs for the name tag. Put all alternatives into either localized name tags (e.g. name:tr/name:el) or the variants (e.g. loc_name/old_name/alt_name)
   |onway=yes
   |imagename_rendering=Rendering-highway residential.png
   |imagename_photo=Residential.jpg
}}