package jalview.gui; import jalview.jbgui.*; import jalview.schemes.*; import jalview.bin.Cache; import javax.swing.*; import java.awt.event.ActionEvent; import java.awt.*; public class Preferences extends GPreferences { AlignViewport av; JInternalFrame frame; public Preferences(AlignViewport av) { this.av = av; frame = new JInternalFrame(); frame.setContentPane(this); Desktop.addInternalFrame(frame, "Preferences", 480,350 ); fullID.setSelected(av.getShowFullId()); String string = Cache.getProperty("SHOW_FULLSCREEN"); boolean value = false; if(string!=null) value = Boolean.valueOf(string).booleanValue(); fullScreen.setSelected(value); annotations.setSelected(av.getShowAnnotation()); conservation.setEnabled(av.getShowAnnotation()); quality.setEnabled(av.getShowAnnotation()); identity.setEnabled(av.getShowAnnotation()); conservation.setSelected(av.showConservation); quality.setSelected(av.showQuality); identity.setSelected(av.showIdentity); for(int i=0; i<12; i++) colour.addItem( ColourSchemeProperty.getColourName(i) ); string = Cache.getProperty("DEFAULT_COLOUR"); if(string!=null) colour.setSelectedItem( string ); else colour.setSelectedIndex( 11 ); String fonts[] = java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment().getAvailableFontFamilyNames(); for(int i=0; i