private void toggleControls(){
		String[] controls = new String[]{"Dir", "Orient", "Reflect", "XFact"};
		boolean[] constate = new boolean[controls.length];
		for(int abc = 0; abc < controls.length; abc++){
			constate[abc]  = gonzo.getControls(controls[abc]);}
			
						bdlabel.setVisible(false);
						for(int def = 0; def < orients.length; def++)
						{orients[def].setVisible(false); orients[def].setEnabled(false);} 
						option[0].setVisible(false); option[0].setEnabled(false); 
						xfs.setVisible(false); xfs.setEnabled(false); xflab.setVisible(false); 
			if(constate[0]){bdlabel.setVisible(true);
						for(int def = 0; def < orients.length; def++)
						{orients[def].setVisible(true); orients[def].setEnabled(true);} 
						orients[0].setSelected(true); brushdir = 0;
						option[0].setVisible(false); option[0].setEnabled(false);
						} 
			if(constate[1]){ bdlabel.setVisible(true); boolean sig;
						for(int def = 0; def < orients.length; def++)
						{if(def < 4){sig = true;}else{sig = false;}
						orients[def].setVisible(sig); orients[def].setEnabled(sig);} 
						orients[0].setSelected(true); brushdir = 0;
						option[0].setVisible(false); option[0].setEnabled(false);
						}
			 if(constate[2]){option[0].setVisible(true); option[0].setEnabled(true);
						}
			 if(constate[3]){xfs.setEnabled(true);xfs.setVisible(true);/*xfs.setValue(1);*/xflab.setVisible(true);}
			
		gonzo = null;
	}