Set layers for nested objects
-
hello,
is there any way to set layers to all nested objects/groups/components in one group/component?
i have a file from multiple workers that i'm compiling and i would need to set everything to Layer0 so the only layering that occurs is the one on the top level (for easier editing).
thanks for any answers.
-
Would 'Put on Layer' do the job?
http://sketchucation.com/forums/viewtopic.php?p=89978#p89978 -
Not sure if I'm clear as to what you are asking, but if just need to move everything in multiple layers to a single layer then select all the layers you don't want and then hit the minus button in the layers window which will then say something like "there are objects on these layers, do you want to move them to default layer or delete..." which you then say you want to move the objects to the default layer (which should be layer zero).
But if you need to explode nested groups try looking at TIG's plugins called 'Explode All Groups', 'Explode Group to Layers' and 'Explode2Groups'. Each of these plugins explode and/or reorganize entities and groups to various capacities depending on what you want to accomplish.
Also note that there are a variety of other plugins as well for Layer management and exploding selections.
-
This one-liner, when run in the Ruby Console, assigns every entity inside every group/component definition to 'Layer0' - irrespective of the depth of the nesting - i.e. geometry, other instances/groups etc...
m=Sketchup.active_model;m.start_operation('!');m.definitions.each{|d|next if d.image?;d.entities.each{|e|e.layer=nil}};m.commit_operation
It is one step undo-able.
Objects within the model.entities itself are not changed...
Advertisement