-
Notifications
You must be signed in to change notification settings - Fork 537
Keep old entities when splitting lines/curves #1426
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
base: master
Are you sure you want to change the base?
Conversation
Keep old entities (and their constraints), and mark them as construction
This is documented here https://solvespace.com/ref.pl#Splitting in the last paragraph but it is not one of the "discoverable" features :-) Writing from a phone, my inclination would be to perhaps keep the extra coincident constraints you added, but leave the construction behaviour as it is. Of course the new coincident constraints will be created only if both entities are already construction (and thus kept). I'll look into it from a PC. |
|
Seems to work as advertised. I fear people might expect the new entities to follow the old construction ones the way it works when a point is turned into an arc, but that's non-trivial to make happen. OTOH people hit the like in this PR which doesn't happen very often ;-) What do you think @ruevs? |
|
I agree with @ruevs that even if old entities aren't kept by default, they should at least keep their endpoint constraints. (I still think they should be kept by default, but at least then it's two clicks and a keypress either way) It seems to work to just do this if you want to keep the old behavior, and let whatever code deletes the old entities remove the redundant constraints when the entities aren't kept? |
|
I need to play with this a little bit when I find some time. I'll try both variants. For now I can not give an opinion. The "pile of construction entities" after multiple splits worries me somewhat. |
|
@jkrei0 @phkahler I tried both. Definitely https://github.com/jkrei0/solvespace/tree/constrain-split-entities for me. The "piling" construction entities (when I did not intentionally do them) that this one creates truly bothers me.
Also this is not at all a problem at all in my opinion. Having the ends of the newly split entities is in many cases desirable. And it is much easier to add points coincident constraints than to remove them. |
|
It seems the constraints only version has a bug :( Not sure why, and I can't get a debug report for some reason (nor can I get a debugger to work)? |
Keep old entities (and their constraints), and mark them as construction
…space into keep-split-entities
I mostly did this as an exercise to introduce myself to working with Solvespace's code. I've probably managed to do something weird or overlook something, and I don't claim to know what other peoples' use cases are. No hard feelings if this isn't something you want merged :)
This fixes a couple issues I had with it:
Tangent arc at pointmarks old entities as construction, and this (new way) is more consistent with thattangent arc at point, or if you don't realize that you lose the old coincident constraints), you risk messing up your sketch/model.*This is somewhat off topic, but it feels way to easy to accidentally delete a group without realizing it, unless you're paying close attention to all the dialog boxes. Not sure what good solution there would be, though.
The problems I still have with the new approach:
And a weird thing, that happens (and should probably be its own issue), is that splines get split at their control points, no matter what. Or is that intentional/neccesary?