How to change the parent of a feature?

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Post Reply
lvella
Posts: 2
Joined: Tue Jan 28, 2014 8:18 pm

How to change the parent of a feature?

Post by lvella »

Or, could also be called: "How to insert retroactive features in some point in the middle of the feature chain/tree"?

This is my first time with this software, and I managed to do what I needed so far (some pieces to be 3D printed), but now I need to poke some wholes that pierces all the other pokets I have already created. I tried to poket on the base Pad of the part I am designing, but it simply created a new branch, that has no effect on the other chained features. How can I append the following features on my newly created poket, so that all bellow are affected? It seems to me it would be a simple matter of changing the parent feature of the one I want to be next, but I could not find that property.
Last edited by lvella on Wed Jan 29, 2014 2:43 am, edited 1 time in total.
User avatar
tanderson69
Veteran
Posts: 1626
Joined: Thu Feb 18, 2010 1:07 am

Re: How to change the parent of a feature?

Post by tanderson69 »

unfortunately, we can't do this yet.
User avatar
shoogen
Veteran
Posts: 2823
Joined: Thu Dec 01, 2011 5:24 pm

Re: How to change the parent of a feature?

Post by shoogen »

There is the Replace Object command in the OpenSCAD Workbench. It is intended to work with Part features only.
lvella
Posts: 2
Joined: Tue Jan 28, 2014 8:18 pm

Re: How to change the parent of a feature?

Post by lvella »

And how to use that Replace Object thing? I must select 3 nodes, then it turns clickable, then I click and nothing happens.
User avatar
NormandC
Veteran
Posts: 18589
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: How to change the parent of a feature?

Post by NormandC »

I'm surprised no one told you you forgot to do a mandatory thing.

That is

Image
User avatar
shoogen
Veteran
Posts: 2823
Joined: Thu Dec 01, 2011 5:24 pm

Re: How to change the parent of a feature?

Post by shoogen »

lvella wrote:And how to use that Replace Object thing? I must select 3 nodes, then it turns clickable, then I click and nothing happens.
You need to have three objects. The old (child), the new (child) and the parent.
Since an object may have more then one parent feature, it is necessary to select all of them in the right order (old,new,parent).
Maybe you have to click on the recompute button (F5 or Ctrl-R) left of the workbench comboBox.
The replace object command messes with the properties of Features in a cruel matter. It doesn't support the undo system. And i don't know if it ever will. It's known to create cyclic dependencies in the graph if used the wrong way. It only changes the Reference to the child feature, not to any linked subgeometry. (So it won't work on draft dimensions)
It might just not work with the type of features you use or simply breaks the whole file. Use it carefully. If it doesn't work, don't expect this to change in the foreseeable future.
We might create a python Macro that helps for special object (like some of those in part design who link sub-geometry). But generally messing with the parent child relations is a dangerous thing.

And now the simple way:
How to change the parent of a feature?
Delete the old one and create a new one.
Post Reply