Feature request #699
problem when moving quickly a layer trough the legend
Status: | Closed | ||
---|---|---|---|
Priority: | Low | ||
Assignee: | Giuseppe Sucameli | ||
Category: | Map Legend | ||
Pull Request or Patch supplied: | Resolution: | fixed | |
Easy fix?: | No | Copied to github as #: | 10758 |
Description
QGIS 0.8.1 SVN 6834, built and and running against QT 4.2.3 (but the bugs have been present "since ever", I just did not have time to report them)
1. one can't move a layer to the top of the layer's list when there's a group present; to reproduce;
a) add a group
b) add a layer
c) move the group to the top of the list
d) now try moving the layer to the top of the list - you can't; instead, the layer gets included into the group, which you didn't want
2. you can't move the layer to the outside of the group when there is only 1 group and other layers or groups
3. changing layers' order, when there are expanded groups, changes the order of layers in the groups; to reproduce:
a) add a group
b) add layer called "l1" and layer called "l2" to that groupm, so that "l1" is on the top
c) add another layer, out of the group
d) move the newly added layer down - you'll notice that now "l2" comes first
Maciek
Associated revisions
applied patch to fix #699
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13641 c8812cc2-4d05-0410-92ff-de0c093fc19c
applied patch to fix #699
git-svn-id: http://svn.osgeo.org/qgis/trunk@13641 c8812cc2-4d05-0410-92ff-de0c093fc19c
History
#1 Updated by Marco Hugentobler about 17 years ago
to 1.: But you can move the group down. The point is that if you move a layer to a group, qgis cannot know if you want to insert the layer into the group or move the layer. On the other hand, if you move a group to a layer, it's clear that it is a move because groups cannot be inserted into layers.
Maybe a solution would be to have a key pressed so that qgis knows you want a move, not an insert. But I wonder how users should find out which key it is. Do you have a more usable solution?
to 2. Doesn't right click to legend and 'Make toplevel item' work for you in that situation?
to 3. Hm, for me, when I move a layer into a group, the moved layer comes at the last position, but the order of the already present layers is preserved.
Do you have a 0.9 version at hand to test if those problems are still present for you?
Marco
#2 Updated by Maciej Sieczka - about 17 years ago
to 1 and 2. 'Make toplevel item' is the solution. I did't use it, as I didn't know what it was for. Thanks for the hint.
to 3. I still can reproduce it. I forgot to mention that this issue is more likely to crop out if the layers in the group are collapsed and the one being added is not collapsed. More layers in the group could also help to spot it. More details how to reproduce:
1. add a group
2. add three or more layers, name them [F2] l1, l2, l3 respectively
3. collapse the layers
4. move the layers into the group, in order l1, l2, l3 etc
5. add a new layer (don't collapse it)
6. move the new layer slowly into the group
For me, in most cases then the order in the group becomes reverted (ie, "l3,l2,l1" instead of "l1,l2,l3".
Also, when there's a layer outside the group, on the bottom of the legend, and it's moved into the group subsequently, it usually doesn't come as the last, but the one before the last.
I'm convinced there is something wrong with ordering layers in the group. For example create a group with five layer called l1-l5, set them in descending order and start moving the first to the bottom and back, in random moves. Sooner or later the initial order is broken.
Checked in QGIS 0.9 SVN 7201 built and running against QT 4.3.1.
#3 Updated by Maciej Sieczka - over 16 years ago
This bug has been around for a very long time now and I can still reproduce it in trunk . The scenario in comment:2 is still valid (though it doesn't necessarily take using groups to reproduce the bug).
#4 Updated by Magnus Homann about 16 years ago
- Status changed from Open to In Progress
I fiddled a bit with the logic in the legend. Can you see if any of these issues still exists after acdbf8af (SVN r9548) ?
#5 Updated by paulp575 - about 16 years ago
Since I was one of the user who added comments to #825 (which was incorporated into #699 as a duplicate) I would like to try acdbf8af (SVN r9548), but have no idea what that is nor do I know how to find if and once I am pointed to it, what do I do with it?
Sorry, never been involved in development so this is new to me! I'm a user!
Thanks,
paulp575
#6 Updated by Magnus Homann about 16 years ago
See
http://wiki.qgis.org/qgiswiki/BuildingFromSource#head-8e1e1ff25b5e9f587393e0592c0ff34891ec07cc
If you check out trunk as mentioned in the above document, you'll be fine. No binaries available at this time.
#7 Updated by paulp575 - about 16 years ago
This is all greek to me!
I use windows and look for already compiled executables (I think that's what they are called).
Is there anything I can do to test this using Windows before the ticket is closed or fully incorporated into release 1.0.0?
Thanks,
paulp575
#8 Updated by Maciej Sieczka - about 16 years ago
Per request https://trac.osgeo.org/qgis/ticket/699#comment:4 - the bug is partly fixed for me. Details:
1. add a group
2. add three or more layers, name them [F2] l1, l2, l3 respectively
3. collapse the layers
4. move the layers into the group, in order l1, l2, l3 etc
5. add a new layer (don't collapse it)
6. move the new layer slowly into the groupFor me, in most cases then the order in the group becomes reverted (ie, "l3,l2,l1" instead of
"l1,l2,l3".
This one's gone...
Also, when there's a layer outside the group, on the bottom of the legend, and it's moved into
the group subsequently, it usually doesn't come as the last, but the one before the last.
Gone too.
Create a group with five layer called l1-l5, set them in descending order and start moving
the first to the bottom and back, in random moves. Sooner or later the initial order is broken.
Still present. Even 3 layers are enough to reproduce. The more of them, the easier though.
Debian testing amd64, QGIS SVN trunk 26ca54dc (SVN r9553), QT 4.4.3.
#9 Updated by Brendon Wolff-Piggott - almost 16 years ago
Replying to [comment:8 msieczka]:
Per request https://trac.osgeo.org/qgis/ticket/699#comment:4 - the bug is partly fixed for me. Details:
1. add a group
2. add three or more layers, name them [F2] l1, l2, l3 respectively
3. collapse the layers
4. move the layers into the group, in order l1, l2, l3 etc
5. add a new layer (don't collapse it)
6. move the new layer slowly into the groupFor me, in most cases then the order in the group becomes reverted (ie, "l3,l2,l1" instead of
"l1,l2,l3".This one's gone...
Also, when there's a layer outside the group, on the bottom of the legend, and it's moved into
the group subsequently, it usually doesn't come as the last, but the one before the last.Gone too.
Create a group with five layer called l1-l5, set them in descending order and start moving
the first to the bottom and back, in random moves. Sooner or later the initial order is broken.Still present. Even 3 layers are enough to reproduce. The more of them, the easier though.
Debian testing amd64, QGIS SVN trunk 26ca54dc (SVN r9553), QT 4.4.3.
On QGIS 1.0 Preview 2, Ubuntu 8.04 cannot reproduce these issues. Recommending closure.
#10 Updated by Maciej Sieczka - almost 16 years ago
Replying to [comment:9 brendonwp]:
On QGIS 1.0 Preview 2, Ubuntu 8.04 cannot reproduce these issues. Recommending closure.
For two years now I have been seeing this bug on various GNU/Linux Distros (successive Ubuntu editions, Debian) and Windows XP Home, various architectures and QT versions. And I still am seeing this bug in the latest SVN trunk fa808f6e (SVN r9726) on Debian testing amd64, QT 4.4.3.
The bug is very easy to reproduce. Again:
1. Add 5 Shapefile layers called l1-l5.
2. Set them in descending order.
3. Start moving the first to the bottom and back, in random moves.
4. Sooner or later the initial order is broken - e.g. l5 jumps to the top although you didn't move it yourself.
#11 Updated by John Tull over 15 years ago
This is still a problem. I do not recall this being an issue for me up to, perhaps including, version 1.0.0. With trunk build from 19 March, I simply cannot add a new layer item and move it without my layers being massively rearranged. I am using qt4.5-rc1, so perhaps that is to blame.
#12 Updated by paulp575 - over 15 years ago
I last saw this in version 0.11, but am unable to test it in version 1.0 under Windows as I don't see an executable I can download.
I use windows and look for already compiled executables (I think that's what they are called).
#13 Updated by Maciej Sieczka - over 15 years ago
I confirm this bug is still present on Debian too, as outlined in comment:10.
Very annoying, long lasting (2 years!) bug which breaks layers order in a unpredictable way. It should be fixed in the 1.0.x.
#14 Updated by Giovanni Manghi over 15 years ago
I cannot reproduce none of the described problems on QGIS 1.2 (rev. 10988 on ubuntu 9.04), everything seems to have been solved.
Closing?
#15 Updated by Giovanni Manghi over 15 years ago
- Resolution set to fixed
- Status changed from In Progress to Closed
Closing this ticket, reopen it if necessary.
#16 Updated by Magnus Homann over 15 years ago
- Status changed from Closed to Feedback
- Resolution deleted (
fixed)
I can still see this happening in .
I think the best bet to fix this once and for all, is to not move the actualy name around all the time, but use a 'divider' type of pointer that shows where the name should be inserted, when the button is released.
#17 Updated by Giovanni Manghi over 15 years ago
Hi,
I just compiled 6fbb9b44 (SVN r11148) and I cannot confirm again the problem. Almost.
Let see:
1) I cannot confirm, as I can move the layer to the top of the list without any problem
2) Almost confirmed: If there is just one group and one or more layers I can move the layers outside the group above it but not under it. If I add a second group under the first one, I can move the layers outside the group, above it, between the two groups or inside the last one.
3) I cannot confirm the behaviour
Tested on Ubuntu 9.04. I'll post a screencast in minutes.
#18 Updated by John Tull over 15 years ago
There seems to be a speed-sensitivity trigger that causes the legend mangling. If you move items quickly across groups, the error tends to arise. If you move items slowly, things are usually handled ok.
#19 Updated by Giovanni Manghi over 15 years ago
Here is the cast
http://www.faunalia.pt/downloads/699.mpeg
I agree that should be possible to put a layer outside/under a group even if there is only one group or if is the lower one. The other two issues seems that were already fixed(?).
#20 Updated by Magnus Homann over 15 years ago
The bug is very easy to reproduce. Again:
1. Add 5 Shapefile layers called l1-l5.
2. Set them in descending order.
3. Start moving the first to the bottom and back, in random moves.
4. Sooner or later the initial order is broken - e.g. l5 jumps to the top although you didn't move it yourself.
This is what I see, by moving one layer back and fort - without releasin the mouse button - I can change the order of other layers. This is with debug gompiled on, printing on the screen and slowing things down.
#21 Updated by Giovanni Manghi over 15 years ago
This is with debug gompiled on, printing on the screen and slowing things down.
there are no problems (on 1.2) also without the debug option.
#22 Updated by Giovanni Manghi over 15 years ago
Replying to [comment:18 jctull]:
There seems to be a speed-sensitivity trigger that causes the legend mangling. If you move items quickly across groups, the error tends to arise. If you move items slowly, things are usually handled ok.
Ok, now I understand when you say that you need to move fast the item across the legend. As a matter of fact this messes up the order, but to reproduce it I have to move the item really fast.
I would like them to try make a little order in this ticket.
Regarding the original description:
1) The problem is gone as already pointed by many here
2) Using 'Make toplevel item' works as supposed to move a layer outside the last group of the legend, so here too, no problem.
3) I cannot replicate the described problem at least when I move the layer down/up, inside/outside the group at a low speed BUT as a matter of fact the problem shows up if you move the mouse fast, like in the case you have along list of layers and you want to move to the top/bottom the one you have selected.
I guess that all we still have is the problem when moving fast a selected layer trough other layers/groups and the subsequent mess produced in the layers order.
I suggest to change the title, if someone does not agree with it just change it.
#23 Updated by Magnus Homann over 15 years ago
- Resolution set to fixed
- Status changed from Feedback to Closed
The messing up of order should be fixed in 97da8f50 (SVN r11234).
#24 Updated by Giovanni Manghi over 15 years ago
this is a major improvement to me. I guess we just miss multiple selections, than it would be perfect. Thanks a lot.
#25 Updated by Maciej Sieczka - over 14 years ago
- Status changed from Closed to Feedback
- Resolution deleted (
fixed)
Replying to [comment:23 homann]:
The messing up of order should be fixed in 97da8f50 (SVN r11234).
A similar bug is present again in trunk, at least as of 735f9e03 (SVN r13413) built from SVN, and in the package provided at http://debian.gfoss.it/pool/main/q/qgis/qgis_1.5.0~svn20100411+gfossit60-2_amd64.deb. Please move this report to another ticket if it's not related.
To reproduce:
1. Add 3 Shapefile layers.
2. Double-click them, move them around, then single-click on either. Sooner or later you'll notice they jump around on the list.
Debian testing amd64, built and running vs QT 4.6.2.
#26 Updated by Giuseppe Sucameli over 14 years ago
Replying to [comment:25 msieczka]:
A similar bug is present again in trunk, at least as of 735f9e03 (SVN r13413) built from SVN, and in the package provided at http://debian.gfoss.it/pool/main/q/qgis/qgis_1.5.0~svn20100411+gfossit60-2_amd64.deb. Please move this report to another ticket if it's not related.
It's present also on Ubuntu 9.04, both build from SVN 8fee8ed3 (SVN r13577) and QGis 1.4.0.
To reproduce it:
1. add 3 shapefiles
2. move very quickly the first layer on the bottom of the legend.
3. click on the new first layer.
I attached a patch to fix this bug (the same code resolves some crashes too, i.e. when you drop a layer in an invalid place).
#27 Updated by Giuseppe Sucameli over 14 years ago
- Status changed from Feedback to Open
#28 Updated by Giuseppe Sucameli over 14 years ago
- Status changed from Open to Closed
- Resolution set to fixed
Fixed by applying the attached patch (from 4c745d88 (SVN r13642)).