[Plugin] Turn Off Layer in All Scenes

[Plugin] Turn Off Layer in All Scenes

Postby oregon_cowboy » Thu Nov 17, 2016 8:55 pm

Hi All - I've been writing small, simple SketchUp plugins for several years for my own use and finally got the courage to share. So forgive me if I am breaking protocol on the best way to submit plugins to this site (please let me know how to do it correctly in the future).

I am starting with sharing this very simple plugin that turns off a selected layer in all scenes. I have seen a several requests in the past of turning off newly created layers in all scenes but hadn't found a direct way to do it (if I missed something, I apologize). There are some great plugins that allow work arounds including Layer Manager and Auto-Invisible Layer. But these are a bit different/more complex than what I wanted/needed. So I created my own simple plugin and am now sharing it here.

Without further ado....

# Name : Turn Layer OFF In All Scenes (TOLIAS)
# Description : Turns selected layer off in all scenes
# Usage : Select a layer in the standard layer window (selected, with the dot filled in).
# Activate plugin via Extensions >> TOLIAS. Confirm the layer you are turning off
# and press okay. Layer will be turned off in all existing scenes.

Its been tested extensively in SketchUp 2015, 2016, and 2017. But please feel free to let me know if you find any bugs.



Re: [Plugin] Turn Off Layer in All Scenes

Postby 0nomat0 » Fri May 31, 2019 4:09 pm

Excellent idea -- thank you! Seems to be working in SU 2019, although I haven't tested extensively.

Also, thanks for sharing the raw RB file, which is nicely commented. I'm looking at it trying to figure out how to make a version that turns ON a layer in all scenes (maybe I could just cut/paste-in-place the layer's contents). I'm quite new to Ruby, and this looks like a nice script to play with.

Users, note that you must set the target Layer as active -- not just highlight it. Also, using undo doesn't undo the TOLIAS operation -- I suppose because it only undoes the Layers operations, one per undo, without updating each scene again. This is typical SketchUp behavior -- undo doesn't undo Scene updates, unfortunately.


Re: [Plugin] Turn Off Layer in All Scenes

Postby HooCheong » Mon Aug 31, 2020 8:08 am

Working well in 2019. Thanks! :)


Re: [Plugin] Turn Off Layer in All Scenes

Postby Swissmountain » Wed Mar 30, 2022 7:59 pm

Hi there,

Thank you for this plug-in, it is very useful and works great in SKP2021

...I just wish it would also turn on Layers using the same method!

Can we hope that you will add this functionality?
Cogito ergo dum-di-dum
User avatar

Re: [Plugin] Turn Off Layer in All Scenes

Postby boofredlay » Fri Apr 29, 2022 8:49 pm

Thanks for this.
User avatar
Global Moderator

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago

Ad Machine 


Return to Extensions & Applications Discussions

Who is online

Users browsing this forum: No registered users and 4 guests