<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://ojwiki.soldin.de/index.php?action=history&amp;feed=atom&amp;title=Beanshell%3AToggle_Layer_Visibility</id>
	<title>Beanshell:Toggle Layer Visibility - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://ojwiki.soldin.de/index.php?action=history&amp;feed=atom&amp;title=Beanshell%3AToggle_Layer_Visibility"/>
	<link rel="alternate" type="text/html" href="https://ojwiki.soldin.de/index.php?title=Beanshell:Toggle_Layer_Visibility&amp;action=history"/>
	<updated>2026-04-15T08:19:43Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.5</generator>
	<entry>
		<id>https://ojwiki.soldin.de/index.php?title=Beanshell:Toggle_Layer_Visibility&amp;diff=200&amp;oldid=prev</id>
		<title>Mentaer: Created page with &#039;The following script toggles the visibility of all layers (ie if not visible, make visible and vice versa).   {    import com.vividsolutions.jump.workbench.model.Layer;    Iterat…&#039;</title>
		<link rel="alternate" type="text/html" href="https://ojwiki.soldin.de/index.php?title=Beanshell:Toggle_Layer_Visibility&amp;diff=200&amp;oldid=prev"/>
		<updated>2009-10-11T23:53:16Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;#039;The following script toggles the visibility of all layers (ie if not visible, make visible and vice versa).   {    import com.vividsolutions.jump.workbench.model.Layer;    Iterat…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;The following script toggles the visibility of all layers (ie if not visible, make visible and vice versa).&lt;br /&gt;
&lt;br /&gt;
 {&lt;br /&gt;
   import com.vividsolutions.jump.workbench.model.Layer;&lt;br /&gt;
   Iterator iter= wc.getLayerManager().getLayers().iterator();  &lt;br /&gt;
   while (iter.hasNext()) {&lt;br /&gt;
     Layer layer = (Layer)iter.next();&lt;br /&gt;
     layer.setVisible ( ! layer.isVisible());&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This script will make a layer called &amp;quot;street&amp;quot; visibile.&lt;br /&gt;
&lt;br /&gt;
 {&lt;br /&gt;
   import com.vividsolutions.jump.workbench.model.Layer;&lt;br /&gt;
   Layer layer = wc.getLayerManager().getLayer(&amp;quot;street&amp;quot;);&lt;br /&gt;
   if (layer != null) {&lt;br /&gt;
     layer.setVisible(true);&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Mentaer</name></author>
	</entry>
</feed>