Modify

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#8204 closed defect (invalid)

Preset defaults and ways that have tags

Reported by: anonymous Owned by: team
Priority: normal Milestone:
Component: unspecified Version: tested
Keywords: preset defaults Cc: A_Pirard

Description

When I want to add a bridge to an existing way, I select the endpoints, press P, then select the newly separated way and select the preset "Bridge". The fields for the preset are all empty.

I would like the defaults to appear, which are "bridge=yes" and "layer=1". These defaults show up on ways that have no tags at all, but not on a way that has only a "highway=residental" tag. It looks as if any previously existing tag prevents the defaults to show up in the preset dialogue. This is a bug IMHO.

I'm running the stable version on Win7, 64 bit.

Attachments (0)

Change History (9)

comment:1 by stoecker, 12 years ago

Resolution: invalid
Status: newclosed

This is not a bug, but a wanted feature. Presets should not apply defaults to already existing objects to prevent accidentally modifying them.

comment:2 by anonymous, 12 years ago

Sorry, but I don't see your point.

Why would you choose a preset if you don't want to modify the way?
If it is the wrong preset, you would click "Cancel". If it is the right preset, you see the default values (or the previous values of the way), make changes if needed, and then click "Apply Preset".

Your point would be valid if it were simple to make a mistake and no chance of noticing that you've changed something. But the second click prevents accidents IMHO.

comment:3 by anonymous, 12 years ago

Resolution: invalid
Status: closedreopened

(reopened to make more visible, feel free to close again if you really don't agree)

comment:4 by stoecker, 12 years ago

Resolution: invalid
Status: reopenedclosed

Why would you choose a preset if you don't want to modify the way?

You can modify the way with the preset, but the defaults aren't applied. You simply need to select values yourself. If you want to enforce values, then use a preset which does not rely on defaults (like e.g. the OneClick presets).

comment:5 by anonymous, 12 years ago

I still don't get the logic behind not offering presets on existing ways. But it's OK -- the OneClick presets look great to me. I did not know about them, must have overlooked them in the list! Thank you for the tip!

in reply to:  5 comment:6 by skyper, 12 years ago

Replying to anonymous:

I still don't get the logic behind not offering presets on existing ways.

Wouldn't it be save to apply the defaults if the tags are not used, yet ?
At least in the bridge example it makes sense.

Presets do not check about other collisions. E.g. I can add barrier=wall to any highway=*.

comment:7 by stoecker, 12 years ago

We had these discussions years ago and the current solution is the one which was result of all that.

comment:8 by A_Pirard, 12 years ago

Presets should not apply defaults to already existing objects to prevent accidentally modifying them.

I was trying to use the following trivial preset to add missing speed limits, mostly 30 km/h

<combo key="maxspeed" default="30" values="30,50,70,90,120" />

30 never displays.

default="default_value"

The default value for the item. If not specified, the current value of the key is chosen as default (if applicable).

I spent more than one hour trying to find what I was doing wrong when trying to do exactly as it says..

In order to destroy maxspeed, if maxspeed exists just displays its value as the default (just as without default=).
Not destroying maxspeed is a matter of maxpeed not existing and not the object not existing.

If you want to avoid real destruction, better prevent to apply waterways on top of highways and get amphibians.

comment:9 by A_Pirard, 12 years ago

Cc: A_Pirard added

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.