@robgrz Had an interesting problem this morning. It presented in a very complex situation but I spent about an hour playing with different variations until I got to the simplest example to show the root cause.
Turns out that the problem exists when you group objects from different layers. One of the layers’ content will be MOVED to the other layer!
Here’s the example:
Two objects on different layers:
In other drawing programs, this same thing happens — objects can’t exist on more than one layer at a time and a group can only be on one layer — some drawing programs handle this by having a preference for “Object remembers layers” which will cause the object(s) to go back to the original layer after ungrouping — this can be confusing for folks though.
Will…I get all of that…but you’re just ignoring the problem with the “Activate the layer you want them on and move them there”. That doesn’t fix the problem, that works around it. I know how (and already did) work around the problem for my application. I’m logging a defect.
I’d have to go through the code to remember the exact behavior, and whether or not there’s a bug in it but, going from memory, the intended logic is:
All items in a group must be moved to the same layer so there are no edge cases around selecting a group. For example, selecting a group, but part of the group is on a hidden layer that cannot be selected.
If any of the items are on the current active layer, they should all be moved to that layer.
If none of the items being grouped are on the active layer, it should move everything to the layer of the first item in the selection list.
I’d actually prefer that the logic be to move everything to the active layer if that seems more clear, and there’s no other edge case that doesn’t come to mind right now.
would it be worth considering using a slightly tweaked icon for cross-layer grouping to make it more clear that what you selected is in multiple layers?
(I’m still kind of wishing that the left icon bar would have an “embedded” layer list in it at the bottom… avoiding the need for the separate dialog for some of the common operations. and when you have that, you could show – during the selection process – which layers have something selected from them)
@robgrz The scenario that surfaced this for me might just be another issue that might be an extension of the “select all across hidden layers” problem that you just fixed:
I embedded a c2D with 2 layers, one of which was hidden. The layer imported as hidden - as were the objects within that layer, however, when it imported, all of the items were selected, including those on the hidden layer. When I grouped the objects on the screen after import (and only the non-hidden objects were visible), they ALL moved to the second layer…which was (coincidentally) the hidden layer, and they disappeared! I found them all by showing the hidden layer. If you’d like the c2ds, I can provide it.
Referring to your thoughts on logic…I think a single consistent result is better than a decision tree - so I really like your idea of just moving everything to the active layer. That would make sense to me and I can anticipate it.
We would still need to change the thing I just reported (one above this post) regarding the import “selecting” all items, including those not visible and then grouping grabbing invisible items.