X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FAppVarna.java;fp=src%2Fjalview%2Fgui%2FAppVarna.java;h=ea16f2352e47138066e26be45d45b19003f3e124;hb=be762d8d9c71a7aa3121e845c45911c7192b7827;hp=079645fd3596fb69ba0fffc62cdf2c3640a9d398;hpb=d1bb7a31fc091606aedbc255a5766ac79e36fa91;p=jalview.git diff --git a/src/jalview/gui/AppVarna.java b/src/jalview/gui/AppVarna.java index 079645f..ea16f23 100644 --- a/src/jalview/gui/AppVarna.java +++ b/src/jalview/gui/AppVarna.java @@ -61,9 +61,9 @@ import fr.orsay.lri.varna.models.annotations.HighlightRegionAnnotation; import fr.orsay.lri.varna.models.rna.ModeleBase; import fr.orsay.lri.varna.models.rna.RNA; -public class AppVarna extends JInternalFrame implements SelectionListener, - SecondaryStructureListener, InterfaceVARNASelectionListener, - VamsasSource +public class AppVarna extends JInternalFrame + implements SelectionListener, SecondaryStructureListener, + InterfaceVARNASelectionListener, VamsasSource { private static final byte[] PAIRS = new byte[] { '(', ')', '[', ']', '{', '}', '<', '>' }; @@ -177,12 +177,15 @@ public class AppVarna extends JInternalFrame implements SelectionListener, { this(ap); - String sname = aa.sequenceRef == null ? "secondary structure (alignment)" + String sname = aa.sequenceRef == null + ? "secondary structure (alignment)" : seq.getName() + " structure"; String theTitle = sname - + (aa.sequenceRef == null ? " trimmed to " + seq.getName() : ""); + + (aa.sequenceRef == null ? " trimmed to " + seq.getName() + : ""); theTitle = MessageManager.formatMessage("label.varna_params", - new String[] { theTitle }); + new String[] + { theTitle }); setTitle(theTitle); String gappedTitle = sname + " (with gaps)"; @@ -190,7 +193,8 @@ public class AppVarna extends JInternalFrame implements SelectionListener, addModel(gappedModel, gappedTitle); String trimmedTitle = "trimmed " + sname; - RnaModel trimmedModel = new RnaModel(trimmedTitle, aa, seq, null, false); + RnaModel trimmedModel = new RnaModel(trimmedTitle, aa, seq, null, + false); addModel(trimmedModel, trimmedTitle); vab.setSelectedIndex(0); } @@ -424,8 +428,8 @@ public class AppVarna extends JInternalFrame implements SelectionListener, end = shift.shift(end); } selectionHighlighter.highlightRegion(rna, start, end); - selectionHighlighter.getLastHighlight().setOutlineColor( - seqsel.getOutlineColour()); + selectionHighlighter.getLastHighlight() + .setOutlineColor(seqsel.getOutlineColour()); // TODO - translate column markings to positions on structure if present. vab.updateSelectedRNA(rna); } @@ -460,7 +464,8 @@ public class AppVarna extends JInternalFrame implements SelectionListener, } @Override - public void onSelectionChanged(BaseList arg0, BaseList arg1, BaseList arg2) + public void onSelectionChanged(BaseList arg0, BaseList arg1, + BaseList arg2) { // TODO translate selected regions in VARNA to a selection on the // alignpanel. @@ -577,7 +582,8 @@ public class AppVarna extends JInternalFrame implements SelectionListener, { if (!model.ann.isValidStruc()) { - throw new IllegalArgumentException("Invalid RNA structure annotation"); + throw new IllegalArgumentException( + "Invalid RNA structure annotation"); } /* @@ -686,7 +692,8 @@ public class AppVarna extends JInternalFrame implements SelectionListener, { if (!model.ann.isValidStruc()) { - throw new IllegalArgumentException("Invalid RNA structure annotation"); + throw new IllegalArgumentException( + "Invalid RNA structure annotation"); } try