Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support cutting and pasting all but one groups in a set of linked groups #4261

Closed
hemebond opened this issue Jun 1, 2023 · 8 comments
Closed
Labels
Prio:3 Low priority: Minor problems and nice to have features Type:Enhancement New features
Milestone

Comments

@hemebond
Copy link
Contributor

hemebond commented Jun 1, 2023

System Information

TrenchBroom v2023.1-RC2 Release Linux-ubuntu-22.04
Qt 5.15.8

Expected Behavior

Cutting and pasting a linked group should retain its link to the other linked duplicates

Steps to Reproduce

  1. Create a group.
  2. Create a linked duplicate of the group
  3. Cut the new linked duplicate (Edit -> Cut)
  4. Paste the linked duplicate (Edit -> Paste)

The pasted group is still a group but is no longer a linked duplicate, and changes are not propagated to or from it.

@hemebond hemebond changed the title Cutting and pasting a linked group duplicate separates it Cutting and pasting a linked duplicate separates it Jun 1, 2023
@kduske
Copy link
Collaborator

kduske commented Jun 1, 2023

Why do you think it should behave that way?

@hemebond
Copy link
Contributor Author

hemebond commented Jun 1, 2023

Why do you think it should behave that way?

Ah, if this is the intended behaviour then i can close the issue. I thought it might have been a regression.

Normally if I'm moving something over long distances it's easier to cut+paste rather than drag it over, so that's why I noticed.

@eGax
Copy link
Contributor

eGax commented Jun 1, 2023

If you cut something from a linked group it's no longer part of that group. IMO this to me is expected and normal behavior.

More so when dealing with special group types like linked groups. I actually tend to cut a linked group off then turn around to paste it to make a brand new group variation. I don't want it be reconnected to the group I originally cut it from.

@kduske
Copy link
Collaborator

kduske commented Jun 1, 2023

First of all, we only get this problem if you cut and paste all but one of a set of linked groups. So let's say you have four linked groups, you select three of them, and cut and paste - the three pasted linked groups are still linked, but the fourth one that you left in the map is unlinked since TB cannot know if you're going to paste the other groups later.

Your case is a special case of this - the single group you cut and paste is unlinked - but not because you cut and pasted it. The reason is actually that if you cut all but one groups in a set of linked groups, the remaining group can by definition no longer be a linked group, so it gets unlinked.

I agree that it's quirky, but it kind of makes sense. Unfortunately there is no simple way to change this behavior.

@kduske kduske added Type:Enhancement New features Prio:3 Low priority: Minor problems and nice to have features labels Jun 1, 2023
@kduske kduske changed the title Cutting and pasting a linked duplicate separates it Support cutting and pasting all but one groups in a set of linked groups Jun 1, 2023
@hemebond
Copy link
Contributor Author

hemebond commented Jun 2, 2023

Oh, that is a bit weird. I just tested again, and yes, if you, e.g., cut+paste two linked duplicates out of a set of four, the links are maintained.

@eGax
Copy link
Contributor

eGax commented Jun 2, 2023

It is very weird.

@kduske
Copy link
Collaborator

kduske commented Jun 2, 2023

Yeah, it is. I think we can eliminate this, too.

@kduske kduske added this to the Next milestone Jun 2, 2023
@kduske
Copy link
Collaborator

kduske commented Feb 5, 2024

This has been fixed in 2024.1.

@kduske kduske closed this as completed Feb 5, 2024
@kduske kduske modified the milestones: Next, 2023.2 Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Prio:3 Low priority: Minor problems and nice to have features Type:Enhancement New features
Projects
None yet
Development

No branches or pull requests

3 participants