Layer Visibility for Multiple Scenes
-
Is there a plugin to quickly set a layer's visibility in all the scenes in a model?
I typically create a model with many scenes. But, if I add a layer that might only need to be visible on 1 or 2 scenes it's tedious to go through each scene, set the layer visibility, then update the scene.
I haven't used layers very much; I normally just use the scenes and the plugin HideInOtherScenes to control visibility. This works fine for groups and components, since I can use the Outliner to temporarily unhide items, but finding text, dimensions, etc. can be challenging.
-
This one-liner copy+pasted into the Ruby Console + <enter> will make the named layer visible in all scenes... Edit the n="xxx" to suit the layer's name you wish to make visible...
n="MyLayerName";m=Sketchup.active_model;la=m.layers[n];m.pages.each{|p|p.set_visibility(la,true)}
Changing the vivibility option from 'true' to 'false' makes that named layer 'NOT visible' in all scenes, thus:
n="MyOtherLayerName";m=Sketchup.active_model;la=m.layers[n];m.pages.each{|p|p.set_visibility(la,false)}
-
Try this plugin:
Plugin: Add Hidden Layer
Update Apr 2014 - Version 1.0.1 Add a Layer to your SketchUp model and control its visibility on existing and new Scenes. Use Activa...
(sketchuptips.blogspot.com)
or this one, seems to be an evolution on the first plugin
http://sketchucation.com/forums/viewtopic.php?f=10&t=36583&p=322249&hilit=+add+hidden+layer+#p322249
-
Thanks, all - I've tested Add_Scene_Layer.rb and I think it will do the trick for me nicely. Maybe I'll even get to liking layers
-
http://www.srww.com/blog/?p=1205
Layers Management Ruby Script For SketchUp
Advertisement