From d704670a936df11fbaf75abbb6d07493d70993a9 Mon Sep 17 00:00:00 2001 From: jprocter Date: Fri, 9 Feb 2007 17:50:33 +0000 Subject: [PATCH] added 'show overview' preference. --- src/jalview/gui/AlignFrame.java | 5 +++++ src/jalview/gui/Preferences.java | 5 ++++- src/jalview/jbgui/GPreferences.java | 8 ++++++++ 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index b281767..b2d41e8 100755 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -145,6 +145,11 @@ public class AlignFrame wrapMenuItem_actionPerformed(null); } + if (jalview.bin.Cache.getDefault("SHOW_OVERVIEW",false)) + { + this.overviewMenuItem_actionPerformed(null); + } + addKeyListener(); } diff --git a/src/jalview/gui/Preferences.java b/src/jalview/gui/Preferences.java index e16aa42..e69492c 100755 --- a/src/jalview/gui/Preferences.java +++ b/src/jalview/gui/Preferences.java @@ -99,6 +99,7 @@ public class Preferences conservation.setSelected(Cache.getDefault("SHOW_CONSERVATION", true)); quality.setSelected(Cache.getDefault("SHOW_QUALITY", true)); identity.setSelected(Cache.getDefault("SHOW_IDENTITY", true)); + openoverv.setSelected(Cache.getDefault("SHOW_OVERVIEW", false)); for (int i = 0; i < 13; i++) { @@ -218,7 +219,9 @@ public class Preferences Cache.applicationProperties.setProperty("SHOW_FULLSCREEN", Boolean.toString(fullScreen. isSelected())); - + Cache.applicationProperties.setProperty("SHOW_OVERVIEW", + Boolean.toString(openoverv. + isSelected())); Cache.applicationProperties.setProperty("SHOW_ANNOTATIONS", Boolean. toString(annotations.isSelected())); diff --git a/src/jalview/jbgui/GPreferences.java b/src/jalview/jbgui/GPreferences.java index f5e6604..dad0f7f 100755 --- a/src/jalview/jbgui/GPreferences.java +++ b/src/jalview/jbgui/GPreferences.java @@ -112,6 +112,7 @@ public class GPreferences protected JCheckBox wrap = new JCheckBox(); protected JCheckBox rightAlign = new JCheckBox(); protected JCheckBox idItalics = new JCheckBox(); + protected JCheckBox openoverv = new JCheckBox(); /** * Creates a new GPreferences object. */ @@ -394,6 +395,12 @@ public class GPreferences idItalics.setHorizontalAlignment(SwingConstants.RIGHT); idItalics.setHorizontalTextPosition(SwingConstants.LEADING); idItalics.setText("Sequence Name Italics"); + openoverv.setFont(new java.awt.Font("Verdana", Font.PLAIN, 11)); + openoverv.setActionCommand("Open Overview"); + openoverv.setHorizontalAlignment(SwingConstants.RIGHT); + openoverv.setHorizontalTextPosition(SwingConstants.LEADING); + openoverv.setText("Open Overview Window"); + openoverv.setBounds(new Rectangle(169, 17, 152, 23)); jPanel2.add(fullScreen); jPanel2.add(annotations); jPanel2.add(seqLimit); @@ -406,6 +413,7 @@ public class GPreferences jPanel2.add(colourLabel); jPanel2.add(sortLabel); jPanel2.add(startupCheckbox); + visualTab.add(openoverv); visualTab.add(startupFileTextfield); visualTab.add(sortby); visualTab.add(colour); -- 1.7.10.2