[josm-dev] addr mask / last tag takeover / dysfunctional when building=yes on way

Florian Lohoff f at zz.de
Wed Jul 6 10:22:04 BST 2011


On Tue, Jul 05, 2011 at 05:02:25PM +0200, Florian Lohoff wrote:
> Hi,
> is there a rational behind the latest josm not taking over the last
> addr mask settings if there is a "building=yes" on the way you try
> to set the tags?
> 
> E.g. edit a way with addr:street/city/postcode/country, press "Apply",
> open an untagged way - edit address and all tags except housenumber
> get taken from the last edit. 
> 
> When there is a "building=yes" on the way the mask is empty ...
> 
> Bug or feature?

Okay - its simply a broken default

src/org/openstreetmap/josm/gui/tagging/TaggingPreset.java
 249             initAutoCompletionField(textField, key);
 250             if (usage.unused()){
 251                 if (!usage.hadKeys() || PROP_FILL_DEFAULT.get()) {
 252                     // selected osm primitives are untagged or filling default values feature is enabled
 253                     if (use_last_as_default && lastValue.containsKey(key)) {
 254                         textField.setText(lastValue.get(key));
 255                     } else {
 256                         textField.setText(default_);
 257                     }
 258                 } else {
 259                     // selected osm primitives are tagged and filling default values feature is disabled
 260                     textField.setText("");
 261                 }

 117     private static final BooleanProperty PROP_FILL_DEFAULT = new BooleanProperty("taggingpreset.fill-default-for-tagged-primitives", false);

The new introduced default is to NOT autofill those entries which is a change in behaviour.
I would rather change this to true.

Flo
-- 
Florian Lohoff                                                 f at zz.de
„Für eine ausgewogene Energiepolitik über das Jahr 2020 hinaus ist die
Nutzung von Atomenergie eine Brückentechnologie und unverzichtbar. Ein
Ausstieg in zehn Jahren, wie noch unter der rot-grünen Regierung
beschlossen, kommt für die nationale Energieversorgung zu abrupt.“
Angela Merkel CDU 30.8.2009
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 828 bytes
Desc: Digital signature
URL: <http://lists.openstreetmap.org/pipermail/josm-dev/attachments/20110706/2ec242c3/attachment.pgp>


More information about the josm-dev mailing list