Changes between Version 47 and Version 48 of Help/Plugin/TurnRestrictions


Ignore:
Timestamp:
2021-08-23T19:44:24+02:00 (3 years ago)
Author:
skyper
Comment:

update to commonly used syntax; wikitr:; comment out shortcut section and new screenshot, see #21243

Legend:

Unmodified
Added
Removed
Modified
  • Help/Plugin/TurnRestrictions

    v47 v48  
    11[[TranslatedPages]]
    22[[PageOutline]]
     3
    34=  Plugin -> Turn Restrictions =
    4 [[Image(/pluginicon/turnrestrictions.jar/images/preferences/turnrestrictions.png)]]
     5
     6[[Image(source:osm/applications/editors/josm/plugins/turnrestrictions/images/preferences/turnrestrictions.png,48,link=,middle)]]
    57
    68== Introduction ==
    7 In OpenStreetMap a '''turn restriction''' limits navigation options. It represents the restriction that one cannot navigate from a [wiki:/Help/Concepts/Object#Ways way] to another way. For instance, the turn restriction depicted below forbids to drive straight. Vehicles have to turn left at the junction where the two ways meet (the so called via-node). Turn restrictions are important for routing and navigation software which are based on OSM data. 
     9In OpenStreetMap a **turn restriction** limits navigation options. It represents the restriction that one cannot navigate from a [wikitr:/Help/Concepts/Object#Ways way] to another way. For instance, the turn restriction depicted below forbids to drive straight. Vehicles have to turn left at the junction where the two ways meet (the so called via-node). Turn restrictions are important for routing and navigation software which are based on OSM data. 
    810
    9 [[Image(only_left_turn_sample.png)]]
     11[[Image(only_left_turn_sample.png,link=)]]
    1012
    11 The {{{turnrestrictions}}} plugin supports editing of turn restrictions. It consists of two major components:
     13The ''**turnrestrictions**'' plugin supports editing of turn restrictions. It consists of two major components:
    1214
    13  1. '''Turn Restriction Toggle Dialog''' - the turn restrictions toggle dialog is displayed on the right in the Toggle Dialogs Section. It displays the list of turn restrictions in the current data set and allows to create or delete turn restrictions, or to launch the Turn Restriction Editor to edit a turn restriction.
    14 
    15  2. '''Turn Restriction Editor''' - the Turn Restriction Editor is a special purpose editor for turn restrictions.
     151. **Turn Restriction Toggle Dialog** - the turn restrictions toggle dialog is displayed on the right in the Toggle Dialogs Section. It displays the list of turn restrictions in the current data set and allows to create or delete turn restrictions, or to launch the Turn Restriction Editor to edit a turn restriction.
     161. **Turn Restriction Editor** - the Turn Restriction Editor is a special purpose editor for turn restrictions.
    1617
    1718== Tagging model ==
    1819Turn restrictions a standard map feature decribed on the [osmwiki:Relation:restriction OSM wiki].
    1920
    20 Technically, a turn restriction is an OSM [wiki:/Help/Concepts/Object#Relations relation]. A turn restriction
     21Technically, a turn restriction is an OSM [wikitr:/Help/Concepts/Object#Relations relation]. A turn restriction
    2122
    22  * must have a relation member with role '''{{{from}}}''' referring to a [wiki:/Help/Concepts/Object#Ways way]. We call this way the '''''from'''''-'''way'''.
    23  * must have a relation member with role '''{{{to}}}''' referring to a [wiki:/Help/Concepts/Object#Ways way]. We call this way the '''''to'''''-'''way'''.
    24  * must have at least of relation member with role {{{via}}} referring to a [wiki:Concepts/Object#Nodes node] or [wiki:/Help/Concepts/Object#Ways way]. We call these objects '''''via'''''-'''object'''.
     23 * must have a relation member with role **`from`** referring to a [wikitr:/Help/Concepts/Object#Ways way]. We call this way the **''from**''-**way**.
     24 * must have a relation member with role **`to`** referring to a [wikitr:/Help/Concepts/Object#Ways way]. We call this way the **''to**''-**way**.
     25 * must have at least of relation member with role `via` referring to a [wikitr:/Help/Concepts/Object#Nodes node] or [wikitr:/Help/Concepts/Object#Ways way]. We call these objects **''via**''-**object**.
    2526
    26 {{{
    27 #!comment
    28 ***************************************************************************************************************************
    29 }}}
     27
     28
    3029== Use Cases ==
    3130=== Creating a turn restriction ===#CreateANewTurnRestriction
    3231There are several possibilities to create a new turn restriction. First, you can lauch the Turn Restriction Editor for a new turn restriction from the Turn Restriction Toggle Dialog:
    33  1. Click on [[JOSMImage(new,20)]] in the Turn Restriction Toggle Dialog. Alternatively, select [[JOSMImage(new,20)]]'''New''' from the popup menu.
     32 1. Click on [[JOSMImage(new,link=,24,middle)]] in the Turn Restriction Toggle Dialog. Alternatively, select [[JOSMImage(new,link=,24,middle)]] **New** from the popup menu.
    3433
    3534Alternatively, you can launch a new editor with a keyboard shortcut:
    36 1. Press the shortcut for creating or editing a turn restriction. On most platforms the shortcut is '''{{{Ctrl+Shift+T}}}'''.
     351. Press the shortcut for creating or editing a turn restriction. On most platforms the shortcut is **`Ctrl+Shift+T`**.
    37361. If objects in the current JOSM selection already participate in a turn restriction, the following window pops up.
    3837 
    39  [[Image(create-turn-restriction-popup.png)]] [[BR]]
    40  Just click on  [[JOSMImage(new,20)]] '''Create new turn restriction''' to launch the turn restriction editor for a new turn restriction. Alternatively, press the key '''{{{N}}}''' or hit '''{{{Enter}}}'''.
     38 [[Image(create-turn-restriction-popup.png,link=)]] \\
     39 Just click on  [[JOSMImage(new,link=,24,middle)]] **Create new turn restriction** to launch the turn restriction editor for a new turn restriction. Alternatively, press the key **`N`** or hit **`Enter`**.
    4140
    42 In both cases, the {{{turnrestrictions}}} plugin initializes the new turn restriction with objects from the current JOSM selection:
    43 1. The first selected way in the JOSM selection becomes the '''''from'''''-way.
    44 1. The last selected way in the JOSM selection becomes the '''''to'''''-way
    45 1. If the '''''from'''''- and '''''to'''''-way have a node in common, this node becomes a ''via''-object.
     41In both cases, the ''turnrestrictions'' plugin initializes the new turn restriction with objects from the current JOSM selection:
     421. The first selected way in the JOSM selection becomes the **''from**''-way.
     431. The last selected way in the JOSM selection becomes the **''to**''-way
     441. If the **''from**''- and **''to**''-way have a node in common, this node becomes a ''via''-object.
    4645
    4746A fast way to create a turn restriction is therefore to
    48 1. Select the '''''from'''''- and '''''to'''''-way in JOSM
    49 1. Press '''{{{Ctrl+Shift+T}}}'''
     471. Select the **''from**''- and **''to**''-way in JOSM
     481. Press **`Ctrl+Shift+T`**
    50491. Choose the type of the turn restriction and save it.   
    5150   
     
    5352There are several possible ways to launch a Turn Restriction Editor in order to edit a turn restriction. First, you can lauch the Turn Restriction Editor for an existing turn restriction from the Turn Restriction Toggle Dialog:
    54531. Select a turn restriction in the Turn Restriction Toggle Dialog
    55 1. Click on [[JOSMImage(dialogs/edit,20)]]. Alternatively, select [[JOSMImage(dialogs/edit,20)]]'''Edit''' from the popup menu.
     541. Click on [[JOSMImage(dialogs/edit,link=,24,middle)]]. Alternatively, select [[JOSMImage(dialogs/edit,link=,24,middle)]] **Edit** from the popup menu.
    5655
    5756Second, you can launch a new editor with a keyboard shortcut:
    58 1. Press the shortcut for creating or editing a turn restriction. On most platforms the shortcut is '''{{{Ctrl+Shift+T}}}'''.
     571. Press the shortcut for creating or editing a turn restriction. On most platforms the shortcut is **`Ctrl+Shift+T`**.
    59581. If objects in the current JOSM selection already participate in a turn restriction, the following window pops up.
    6059
    61  [[Image(create-turn-restriction-popup.png)]] [[BR]]
    62  Just double-click on the turn restriction you want to edit. Alternatively, for the top 9 turn restrictions displayed in the popup window you can use the shortcuts '''1''' to '''9''' to launch the Turn Restriction Editor. In the example above, you would press '''1''' to start editing.
     60 [[Image(create-turn-restriction-popup.png,link=)]] \\
     61 Just double-click on the turn restriction you want to edit. Alternatively, for the top 9 turn restrictions displayed in the popup window you can use the shortcuts **1** to **9** to launch the Turn Restriction Editor. In the example above, you would press **1** to start editing.
    6362
    6463A fast way to edit a turn restriction is therefore to
    65 1. Select the '''''from'''''- or '''''to'''''-way in JOSM
    66 1. Press '''{{{Ctrl+Shift+T}}}'''
    67 1. Type '''{{{1}}}''' to lauch the Turn Restriction Editor
     641. Select the **''from**''- or **''to**''-way in JOSM
     651. Press **`Ctrl+Shift+T`**
     661. Type **`1`** to lauch the Turn Restriction Editor
    6867 
    6968=== Deleting a turn restriction ===
    7069There are several possible ways to delete a turn restriction. First, you can delete it in the Turn Restriction Toggle Dialog:
    71701. Select a turn restriction in the Turn Restriction Toggle Dialog
    72 1. Press '''{{{DEL}}}''' or click on [[JOSMImage(dialogs/delete,20)]]. Alternatively, select [[JOSMImage(dialogs/delete,20)]]'''Delete''' from the popup menu.
     711. Press **`DEL`** or click on [[JOSMImage(dialogs/delete,link=,24,middle)]]. Alternatively, select [[JOSMImage(dialogs/delete,link=,24,middle)]] **Delete** from the popup menu.
    7372
    74 Alternatively, you can [#EditingATurnRestriction launch a Turn Restriction Editor] and click on  [[JOSMImage(dialogs/delete,20)]] in its toolbar.
    75 {{{
    76 #!comment
    77 *********************************************************************************************
    78 Turn Restriction Toggle Dialog                                                               
    79 *********************************************************************************************
    80 }}}
     73Alternatively, you can [#EditingATurnRestriction launch a Turn Restriction Editor] and click on  [[JOSMImage(dialogs/delete,link=,24,middle)]] in its toolbar.
     74
     75
     76
    8177== Turn Restriction Toggle Dialog == #TurnRestrictionToggleDialog
    8278The Turn Restriction Toggle Dialog helps you to keep track of the turn restrictions in the current edit layer.
    8379
    84 Here's a screenshot of the toggle dialog and its popup menu:[[br]]
    85 [[Image(toggle-dialog-screenshot.png)]]
     80Here's a screenshot of the toggle dialog and its popup menu: \\
     81[[Image(toggle-dialog-screenshot.png,link=)]]
    8682
    87 If you tick the checkbox '''Only participating in selection''' the dialog displays only turn restrictions in which objects from the current selection are participating. If the checkbox isn't selected, then all turn restrictions in the current edit layer are displayed.
     83If you tick the checkbox **Only participating in selection** the dialog displays only turn restrictions in which objects from the current selection are participating. If the checkbox isn't selected, then all turn restrictions in the current edit layer are displayed.
    8884
    8985You can apply some commands to the turn restrictions displayed in this dialog.
    90 ||'''Create''' a new turn restriction||Click [[JOSMImage(new,15)]] or select  [[JOSMImage(new,15)]]'''New''' from the popup menu||
    91 ||'''Edit''' a turn restriction||Select the turn restriction and click [[JOSMImage(dialogs/edit,15)]] or select  [[JOSMImage(dialogs/edit,15)]]'''Edit''' from the popup menu||
    92 ||'''Delete''' a turn restriction||Select one or more turn restrictions, press '''{{{DEL}}}''', or click on [[JOSMImage(dialogs/delete,15)]] or select [[JOSMImage(dialogs/delete,15)]]'''Delete''' from the popup menu.||
    93 ||'''Select''' the turn restriction||In order to select the turn restriction and its members in the current edit layer, first select the turn restriction in the list and then select [[JOSMImage(selectall,15)]]'''Select in current data layer''' from the popup menu.||
    94 ||'''Zoom''' to the turn restriction||Select the turn restriction in the list and then select [[JOSMImage(dialogs/autoscale/selection,15)]]'''Zoom to''' from the popup menu.||
     86||**Create** a new turn restriction||Click [[JOSMImage(new,link=,24,middle)]] or select  [[JOSMImage(new,link=,24,middle)]] **New** from the popup menu||
     87||**Edit** a turn restriction||Select the turn restriction and click [[JOSMImage(dialogs/edit,link=,24,middle)]] or select  [[JOSMImage(dialogs/edit,link=,24,middle)]] **Edit** from the popup menu||
     88||**Delete** a turn restriction||Select one or more turn restrictions, press **`DEL`**, or click on [[JOSMImage(dialogs/delete,link=,24,middle)]] or select [[JOSMImage(dialogs/delete,link=,24,middle)]] **Delete** from the popup menu.||
     89||**Select** the turn restriction||In order to select the turn restriction and its members in the current edit layer, first select the turn restriction in the list and then select [[JOSMImage(selectall,link=,24,middle)]] **Select in current data layer** from the popup menu.||
     90||**Zoom** to the turn restriction||Select the turn restriction in the list and then select [[JOSMImage(dialogs/autoscale/selection,link=,24,middle)]] **Zoom to** from the popup menu.||
    9591
    96 {{{
    97 #!comment
    98 *********************************************************************************************
    99 Turn Restriction Editor                                                               
    100 *********************************************************************************************
    101 }}}
     92
     93
    10294== Turn Restriction Editor ==#TurnRestrictionEditor
    10395The Turn Restriction Editor allows you to create and edit turn restriction. It provides two user interfaces:
    104 * a '''Basic Editor'''. This is a special purpose user interface for editing the properties of a turn restriction.
    105 * an '''Advanced Editor'''. This is a generic user interface for editing the raw data elements of the OSM relation which represents a turn restriction.
     96* a **Basic Editor**. This is a special purpose user interface for editing the properties of a turn restriction.
     97* an **Advanced Editor**. This is a generic user interface for editing the raw data elements of the OSM relation which represents a turn restriction.
    10698
    10799You can use either of these user interfaces. Regardless of whether you use the Basic Editor or the Advanced Editor you should make sure that the resulting turn restriction is valid. The turn restriction editor checks the turn restriction and shows error messages and warnings in a third user interface, i.e. the list of issues.
    108100
    109101=== Basic Editor === #BasicEditor
    110 The Basic Editor allows you to set the '''''from'''''-way, the '''''to'''''-way, and exceptions to the turn restriction for a selection of vehicle types.
     102The Basic Editor allows you to set the **''from**''-way, the **''to**''-way, and exceptions to the turn restriction for a selection of vehicle types.
    111103
    112 In order to set the '''''from'''''-way
     104In order to set the **''from**''-way
    1131051. Select a way in the current edit layer
    114 1. '''Drag''' it from the list of selected objects (on the left in the editor) onto the input field '''From:'''
     1061. **Drag** it from the list of selected objects (on the left in the editor) onto the input field **From:**
    115107
    116108Alternatively, you can
    1171091. Select a way in the current edit layer
    118 1. Copy  it (using '''{{{Ctrl+C}}}''' or [[JOSMImage(copy,20)]]'''Copy''' in the popup menu) in the list of selected objects on the right of the Turn Restriction Editor
    119 1. Click on the '''From:''' field and paste the copied way (using '''{{{Ctrl+V}}}''' or [[JOSMImage(paste,20)]]'''Paste''' from the popup menu)
     1101. Copy  it (using **`Ctrl+C`** or [[JOSMImage(copy,link=,24,middle)]] **Copy** in the popup menu) in the list of selected objects on the right of the Turn Restriction Editor
     1111. Click on the **From:** field and paste the copied way (using **`Ctrl+V`** or [[JOSMImage(paste,link=,24,middle)]] **Paste** from the popup menu)
    120112
    121 [[Image(sample-screen-shot-1.png)]]
     113[[Image(sample-screen-shot-1.png,link=)]]
    122114
    123115In the standard configuration, ''via''-objects aren't displayed in the Basic Editor. You have to switch to the [#AdvancedEditor Advanced Editor] to edit them. In the preferences for the turnrestrictions plugin you can change the default configuration, though. [#Preferences Launch the preference dialog] and [#ToggleEditingOfViaObjects enable displaying/editing of via-objects] in the Basic Editor.
     
    125117The following screen shot shows the Basic Editor configured to display/edit ''via''-objects too.
    126118
    127 [[Image(basic-editor-with-vias.png)]]
     119[[Image(basic-editor-with-vias.png,link=)]]
    128120
    129121=== Advanced Editor === #AdvancedEditor
    130122The Advanced Editor allows you to edit the raw OSM data, i.e. the tags and the relation members of the relation representing the turn restriction.
    131123
    132 [[Image(sample-screen-shot-2.png)]]
     124[[Image(sample-screen-shot-2.png,link=)]]
    133125
    134126==== Editing the tags ====
    135127In the upper half of the Advanced Editor you can edit the tags of the turn restriction. You can add tags with arbitrary keys and values but please note that some tags have a special meaning in turn restrictions:
    136128
    137 * {{{type=restriction}}}  - this is a required tag for a turn restriction.
    138 * {{{restriction=...}}}   - the value of this tag should be one of the [osmwiki:Relation:restriction supported types for turn restrictions]. Instead of editing the raw tag value you can also select a restriction type from the drop-down box in the [#BasicEditor Basic Editor].
    139 * {{{exception=...}}} -  the value of this tag should be a set of [osmwiki:Relation:restriction supported vehicle types]. Instead of editing the raw tag value you can also tick the respective vehicle types in the [#BasicEditor Basic Editor].
    140 * {{{day_on=...}}}, {{{day_off=...}}}, {{{hour_on=...}}} and {{{hour_off=...}}} can be used to specify when a turn restriction is actually in place, refer to the [osmwiki:Relation:restriction OSM wiki for more information].
     129* `type=restriction`  - this is a required tag for a turn restriction.
     130* `restriction=...`   - the value of this tag should be one of the [osmwiki:Relation:restriction supported types for turn restrictions]. Instead of editing the raw tag value you can also select a restriction type from the drop-down box in the [#BasicEditor Basic Editor].
     131* `exception=...` -  the value of this tag should be a set of [osmwiki:Relation:restriction supported vehicle types]. Instead of editing the raw tag value you can also tick the respective vehicle types in the [#BasicEditor Basic Editor].
     132* `day_on=...`, `day_off=...`, `hour_on=...` and `hour_off=...` can be used to specify when a turn restriction is actually in place, refer to the [osmwiki:Relation:restriction OSM wiki for more information].
    141133
    142134
     
    144136In the lower half of the Advanced Editor you can edit the members of the turn restriction relation.
    145137
    146 In addition to the ''from''-way and the ''to''-way, which you can edit in the  [#BasicEditor Basic Editor] too, you can also enter ''via''-object and a node with role {{{location_hint}}} (see  [osmwiki:Relation:restriction OSM wiki]).
     138In addition to the ''from''-way and the ''to''-way, which you can edit in the  [#BasicEditor Basic Editor] too, you can also enter ''via''-object and a node with role `location_hint` (see  [osmwiki:Relation:restriction OSM wiki]).
    147139
    148140To add members just drag-and-drop or copy/paste objects from the JOSM selection view on the right to the list of relation members.
    149141
    150 You can '''reorder''' the relation members:
     142You can **reorder** the relation members:
    1511431. Select one or more members
    152 1. Press '''Alt-Up''' to move them up by one position. Alternatively you can select '''Move up''' from the popup menu.
     1441. Press **Alt-Up** to move them up by one position. Alternatively you can select **Move up** from the popup menu.
    153145
    154  Press '''Alt-Down''' to move them down by one position. Alternatively you can select '''Move down''' from the popup menu.
     146 Press **Alt-Down** to move them down by one position. Alternatively you can select **Move down** from the popup menu.
    155147
    156148To edit the role of a relation member
    1571491. Double-click on the table cell with the role
    158 1. Edit the role and press '''ENTER'''
     1501. Edit the role and press **ENTER**
    159151
    160152=== Resolving Errors and Warnings === #ErrorsAndWarnings
    161 [[Image(sample-screen-shot-3.png)]]
     153[[Image(sample-screen-shot-3.png,link=)]]
    162154
    163 {{{
    164 #!comment
    165 *****************************************************************************************************
    166 }}}
     155
     156
    167157== Preferences ==#Preferences
    168158To launch the preferences panel for the turnrestrictions plugin:
    169159
    170 1. Click on [[JOSMImage(preference)]] in the JOSM toolbar or press '''{{{F10}}}'''.
    171 1. Click on [[Image(source:osm/applications/editors/josm/plugins/turnrestrictions/images/preferences/turnrestrictions.png,20)]] to display the preferences panel for the turnrestrictions plugin
     1601. Click on [[JOSMImage(preference)]] in the JOSM toolbar or press **`F10`**.
     1611. Click on [[Image(source:osm/applications/editors/josm/plugins/turnrestrictions/images/preferences/turnrestrictions.png,24,link=,middle)]] to display the preferences panel for the turnrestrictions plugin
    172162
    173 [[Image(preferences-screen-shot.png)]]
     163[[Image(ticket:21243:preferences-withoutShortCut.png,link=)]]
    174164
    175165=== Select icon set for road signs ===
     
    182172You can override the standard setting, though. If you tick the respective checkbox in the preferences (see screen shot above) the list of via-objects is displayed in the Basic Editor too.
    183173
     174{{{#!comment
     175Shortcut configuration does not work, atm, and will probably not be readded to the plugin preferences. See #21243
     176}}}
     177
     178{{{#!comment
    184179=== Configure shortcut for creating/editing a turn restriction ===
    185 In the preference dialog you can also configure the shortcut to create/edit a turn restriction. The default shortcut is '''{{{Ctrl+Shift+T}}}''' but you can change it to whatever shortcut you like.
     180In the preference dialog you can also configure the shortcut to create/edit a turn restriction. The default shortcut is **`Ctrl+Shift+T`** but you can change it to whatever shortcut you like.
    186181
    187 Be careful not to override already defined shortcuts, though. For instance, '''{{{Ctrl+S}}}''' is the defined shortcut for '''Save to file'''. If you set the turn restrictions shortcut to '''{{{Ctrl+S}}}''', then pressing '''{{{Ctrl+S}}}''' won't save the current layer any more. The turn restriction editor is launched instead.
     182Be careful not to override already defined shortcuts, though. For instance, **`Ctrl+S`** is the defined shortcut for **Save to file**. If you set the turn restrictions shortcut to **`Ctrl+S`**, then pressing **`Ctrl+S`** won't save the current layer any more. The turn restriction editor is launched instead.
     183}}}
    188184
    189185== See also ==
    190 
    191 * [https://wiki.openstreetmap.org/wiki/JOSM/Plugins/turnrestrictions Turnrestriction Plugin page] - Historic reference, development of this plugin in 2010-03 was sponsored by [http://www.skobbler.de/ skobbler GmbH]
     186* [osmwiki:JOSM/Plugins/turnrestrictions Turnrestriction Plugin page] - Historic reference, development of this plugin in 2010-03 was sponsored by [https://www.skobbler.de/ skobbler GmbH]
    192187
    193188----
    194 Back to [wiki:/Plugins#JOSMdocu Plugin Help][[BR]]
    195 Back to [wiki:/Help Main Help]
     189Back to [wikitr:/Plugins#JOSMdocu Plugin Help] \\
     190Back to [wikitr:/Help Main Help]