Opened 9 years ago
Last modified 9 years ago
#12579 new defect
Add inner polygons when using Tools → Create multipolygon
Reported by: | Penegal | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core multipoly | Version: | tested |
Keywords: | default create multipolygon inner outer tool | Cc: |
Description
Hello.
Often, I use Tools → Create multipolygon to create landuse multipolygons; mines always have inner
polygons, often already drawn when I use this tool, and I think this occurs, at least occasionally for most landuse mappers. It would be very useful that this tool automagically add inner
polygons, either by default or by selection, to the created relation: if a selected polygon totally contains other ones, then the container would be included in the relation with the outer
role, and the contained ones with the inner
role. In order to avoid unnecessary huge multipolygon monsters, this mode could be non default, enabled from the preferences with a warning that the use of this mode should be reasonable; you should prefer fragmenting the huge polygons over making multipolygon monsters whenever possible.
Regards.
Attachments (4)
Change History (18)
comment:1 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | new → needinfo |
follow-up: 3 comment:2 by , 9 years ago
Well, the inner ways are attributed the outer
role; AFAIK, the inner ways should have the inner
role, or did I misunderstood the wiki?
comment:3 by , 9 years ago
Replying to penegal@…:
the inner ways should have the
inner
role
Yes. And this way the josm tool works.
comment:4 by , 9 years ago
What steps will reproduce the problem?
- I select two polygons, the first totally overlapping the second.
- I use Tools → Create a multipolygon.
What is the expected result?
A multipolygon relation should be created with the first polygon in outer
role, the second in inner
role.
What happens instead?
A multipolygon relation is created with both polygons in outer
role.
Please provide any additional information below. Attach a screenshot if possible.
URL:http://josm.openstreetmap.de/svn/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2016-02-28 14:07:49 +0100 (Sun, 28 Feb 2016) Build-Date:2016-02-28 22:44:23 Revision:9900 Relative:URL: ^/trunk Identification: JOSM/1.5 (9900 fr) Windows Vista 32-Bit Memory Usage: 180 MB / 989 MB (36 MB allocated, but free) Java version: 1.8.0_45-b14, Oracle Corporation, Java HotSpot(TM) Client VM VM arguments: [-Djosm.home=E:\JOSM] Dataset consistency test: No problems found Plugins: - apache-commons (31895) - cadastre-fr (32060) - contourmerge (1014) - download_along (31772) - ejml (31895) - geotools (31895) - jts (31772) - opendata (32071) - utilsplugin2 (32018) Last errors/warnings: - W: Invalid jar file ''E:\JOSM\plugins\opendata.jar.new'' (exists: false, canRead: false) - W: Invalid jar file ''E:\JOSM\plugins\cadastre-fr.jar.new'' (exists: false, canRead: false) - W: Echec de l'ajout de resource://data/validator/power.mapcss au vérificateur d'attribut - W: java.io.IOException: L’ouverture du flux d’entrée pour la ressource 'resource://data/validator/power.mapcss' a échoué
comment:6 by , 9 years ago
Summary: | Add inner polygons when using Tools -> Create multipolygon → Add inner polygons when using Tools → Create multipolygon |
---|
Here it comes; the only actions performed between the two files is selecting only the meadow polygon #392210844 and the forest #356350457 polygon, the first totally overlapping the second, and clicking on Tools → Create a multipolygon. The resulting multipolygon relation has the two members in the outer
role, whereas, in this case, the overlapped #356350457 polygon should have the inner
role. This is what I expect in such a situation: I know no situation where the current result could be useful, although there should be some, but, IMHO, the overlapped polygons should always have the inner
role, at least by default. Tagging of the created relation should reflect that, by taking tags away from the outer polygon, as it is currently the case when you select a single polygon to create a multipolygon.
comment:7 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | needinfo → new |
Type: | enhancement → defect |
I don't know what goes wrong here. For me this works fine. Forest gets inner role and landuse=meadow tag is moved from outer way to the relation.
by , 9 years ago
Attachment: | Sans titre.png added |
---|
Screenshot of the resulting relation, with both polygons in the outer role
comment:8 by , 9 years ago
Well, there must be a problem with my eyes, because, when I open the After.osm
file and look at the resulting relation, as on the attached screenshot, both polygons have the outer
role in the created multipolygon relation, and the relation has no tags inherited from the polygons, only the type=multipolygon
tag.
comment:9 by , 9 years ago
I see that too. I just said that I cannot reproduce this problem with my pc.
comment:10 by , 9 years ago
Oh. Then, would you like some additional data about my config? A screencast? I must add that the problem rose on 2 different platforms, with two different versions of Java, and with 2 different jOSM home directories. In addition, the problem was already present before the current tested version, at least with the previous one.
comment:11 by , 9 years ago
Please try with a fresh config, see Help/CommandLineOptions how to use josm.home
comment:12 by , 9 years ago
You got it: a fresh config made the tool working as expected; should I append the old preferences.xml
or a part of it to diagnose the problem?
comment:13 by , 9 years ago
Only after ensuring that no personal data (especially OSM credentials) is contained in preferences.xml
. You could also test with your old preferences.xml
, but all plugins disabled: specify --skip-plugins
on the command line.
by , 9 years ago
Attachment: | preferences.xml added |
---|
Sample preferences file with which the problem appears
comment:14 by , 9 years ago
Here comes the preferences file. I tried using this file with --skip-plugins
, but the problem is still there.
This works fine for me. When I select all member ways and use tools -> create multipolygon, then the roles inner and outer are automatically set. This even works with splitted ways.
Please describe in more detail the steps you do and add your statusreport as asked on newticket.