}
public AlignFrame(AlignmentI al, SequenceI[] hiddenSeqs,
- HiddenColumns hidden, JalviewLite applet,
- String title, boolean embedded)
+ HiddenColumns hidden, JalviewLite applet, String title,
+ boolean embedded)
{
this(al, hiddenSeqs, hidden, applet, title, embedded, true);
}
public AlignFrame(AlignmentI al, SequenceI[] hiddenSeqs,
- HiddenColumns hidden, JalviewLite applet,
- String title, boolean embedded, boolean addToDisplay)
+ HiddenColumns hidden, JalviewLite applet, String title,
+ boolean embedded, boolean addToDisplay)
{
if (applet != null)
{
createAlignFrameWindow(embedded);
validate();
alignPanel.adjustAnnotationHeight();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
}
public AlignViewport getAlignViewport()
{
Map<String, FeatureColourI> colours = alignPanel.seqPanel.seqCanvas
.getFeatureRenderer().getFeatureColours();
- boolean relaxedIdMatching = viewport.applet.getDefaultParameter(
- "relaxedidmatch", false);
+ boolean relaxedIdMatching = viewport.applet
+ .getDefaultParameter("relaxedidmatch", false);
featuresFile = new FeaturesFile(file, sourceType).parse(
viewport.getAlignment(), colours, true, relaxedIdMatching);
} catch (Exception ex)
{
viewport.featureSettings.refreshTable();
}
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
statusBar.setText(MessageManager
.getString("label.successfully_added_features_alignment"));
}
ViewportRanges ranges = viewport.getRanges();
if (viewport.cursorMode
- && ((evt.getKeyCode() >= KeyEvent.VK_0 && evt.getKeyCode() <= KeyEvent.VK_9) || (evt
- .getKeyCode() >= KeyEvent.VK_NUMPAD0 && evt
- .getKeyCode() <= KeyEvent.VK_NUMPAD9))
+ && ((evt.getKeyCode() >= KeyEvent.VK_0
+ && evt.getKeyCode() <= KeyEvent.VK_9)
+ || (evt.getKeyCode() >= KeyEvent.VK_NUMPAD0
+ && evt.getKeyCode() <= KeyEvent.VK_NUMPAD9))
&& Character.isDigit(evt.getKeyChar()))
{
alignPanel.seqPanel.numberPressed(evt.getKeyChar());
case KeyEvent.VK_F2:
viewport.cursorMode = !viewport.cursorMode;
- statusBar.setText(MessageManager.formatMessage(
- "label.keyboard_editing_mode",
- new String[] { (viewport.cursorMode ? "on" : "off") }));
+ statusBar.setText(MessageManager
+ .formatMessage("label.keyboard_editing_mode", new String[]
+ { (viewport.cursorMode ? "on" : "off") }));
if (viewport.cursorMode)
{
alignPanel.seqPanel.seqCanvas.cursorX = ranges.getStartRes();
break;
}
- alignPanel.paintAlignment(true);
+ // TODO: repaint flags set only if the keystroke warrants it
+ alignPanel.paintAlignment(true, true);
}
/**
// Hide everything by the current selection - this is a hack - we do the
// invert and then hide
// first check that there will be visible columns after the invert.
- if (viewport.hasSelectedColumns()
- || (sg != null && sg.getSize() > 0 && sg.getStartRes() <= sg
- .getEndRes()))
+ if (viewport.hasSelectedColumns() || (sg != null && sg.getSize() > 0
+ && sg.getStartRes() <= sg.getEndRes()))
{
// now invert the sequence set, if required - empty selection implies
// that no hiding is required.
{
boolean newState = sortAnnBySequence.getState();
sortAnnByLabel.setState(false);
- setAnnotationSortOrder(newState ? SequenceAnnotationOrder.SEQUENCE_AND_LABEL
- : SequenceAnnotationOrder.NONE);
+ setAnnotationSortOrder(
+ newState ? SequenceAnnotationOrder.SEQUENCE_AND_LABEL
+ : SequenceAnnotationOrder.NONE);
setViewportAnnotationOrder();
}
else if (source == sortAnnByLabel)
{
boolean newState = sortAnnByLabel.getState();
sortAnnBySequence.setState(false);
- setAnnotationSortOrder(newState ? SequenceAnnotationOrder.LABEL_AND_SEQUENCE
- : SequenceAnnotationOrder.NONE);
+ setAnnotationSortOrder(
+ newState ? SequenceAnnotationOrder.LABEL_AND_SEQUENCE
+ : SequenceAnnotationOrder.NONE);
setViewportAnnotationOrder();
}
else if (source == showAutoFirst)
{
applyAutoAnnotationSettings_actionPerformed();
}
- alignPanel.paintAlignment(true);
+ // TODO: repaint flags set only if warranted
+ alignPanel.paintAlignment(true, true);
}
/**
else if (source == invertColSel)
{
viewport.invertColumnSelection();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(false, false);
viewport.sendSelection();
}
else if (source == remove2LeftMenuItem)
else if (source == showColumns)
{
viewport.showAllHiddenColumns();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
viewport.sendSelection();
}
else if (source == showSeqs)
{
viewport.showAllHiddenSeqs();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
// uncomment if we want to slave sequence selections in split frame
// viewport.sendSelection();
}
else if (source == hideColumns)
{
viewport.hideSelectedColumns();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
viewport.sendSelection();
}
else if (source == hideSequences
&& viewport.getSelectionGroup() != null)
{
viewport.hideAllSelectedSeqs();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
// uncomment if we want to slave sequence selections in split frame
// viewport.sendSelection();
}
else if (source == hideAllButSelection)
{
toggleHiddenRegions(false, false);
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
viewport.sendSelection();
}
else if (source == hideAllSelection)
viewport.expandColSelection(sg, false);
viewport.hideAllSelectedSeqs();
viewport.hideSelectedColumns();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
viewport.sendSelection();
}
else if (source == showAllHidden)
{
viewport.showAllHiddenColumns();
viewport.showAllHiddenSeqs();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
viewport.sendSelection();
}
else if (source == showGroupConsensus)
cap.setText(contents.toString());
Frame frame = new Frame();
frame.add(cap);
- jalview.bin.JalviewLite.addFrame(frame, MessageManager.formatMessage(
- "label.alignment_properties", new String[] { getTitle() }),
- 400, 250);
+ jalview.bin.JalviewLite.addFrame(frame, MessageManager
+ .formatMessage("label.alignment_properties", new String[]
+ { getTitle() }), 400, 250);
}
else if (source == overviewMenuItem)
{
CutAndPasteTransfer cap = new CutAndPasteTransfer(true, this);
Frame frame = new Frame();
frame.add(cap);
- JalviewLite.addFrame(frame, MessageManager.formatMessage(
- "label.alignment_output_command",
- new Object[] { e.getActionCommand() }), 600, 500);
-
- FileFormatI fileFormat = FileFormats.getInstance().forName(
- e.getActionCommand());
- cap.setText(new AppletFormatAdapter(alignPanel).formatSequences(
- fileFormat, viewport.getAlignment(),
- viewport.getShowJVSuffix()));
+ JalviewLite.addFrame(frame, MessageManager
+ .formatMessage("label.alignment_output_command", new Object[]
+ { e.getActionCommand() }), 600, 500);
+
+ FileFormatI fileFormat = FileFormats.getInstance()
+ .forName(e.getActionCommand());
+ cap.setText(
+ new AppletFormatAdapter(alignPanel).formatSequences(fileFormat,
+ viewport.getAlignment(), viewport.getShowJVSuffix()));
}
public void loadAnnotations()
return null;
}
+ private List<String> getDisplayedFeatureGroups()
+ {
+ if (alignPanel.getFeatureRenderer() != null
+ && viewport.getFeaturesDisplayed() != null)
+ {
+ return alignPanel.getFeatureRenderer().getDisplayedFeatureGroups();
+
+ }
+ return null;
+ }
+
public String outputFeatures(boolean displayTextbox, String format)
{
String features;
if (format.equalsIgnoreCase("Jalview"))
{
features = formatter.printJalviewFormat(viewport.getAlignment()
- .getSequencesArray(), getDisplayedFeatureCols());
+ .getSequencesArray(), getDisplayedFeatureCols(),
+ getDisplayedFeatureGroups(), true);
}
else
{
features = formatter.printGffFormat(viewport.getAlignment()
- .getSequencesArray(), getDisplayedFeatureCols());
+ .getSequencesArray(), getDisplayedFeatureCols(),
+ getDisplayedFeatureGroups(), true);
}
if (displayTextbox)
: "?";
url.append(firstSep);
- url.append("open="
- + appendProtocol(viewport.applet.getParameter("file")));
+ url.append(
+ "open=" + appendProtocol(viewport.applet.getParameter("file")));
if (viewport.applet.getParameter("features") != null)
{
if (viewport.applet.getParameter("annotations") != null)
{
url.append("&annotations=");
- url.append(appendProtocol(viewport.applet.getParameter("annotations")));
+ url.append(
+ appendProtocol(viewport.applet.getParameter("annotations")));
}
if (viewport.applet.getParameter("jnetfile") != null
|| viewport.applet.getParameter("jpredfile") != null)
{
url.append("&annotations=");
- url.append(appendProtocol(viewport.applet.getParameter("jnetfile") != null ? viewport.applet
- .getParameter("jnetfile") : viewport.applet
- .getParameter("jpredfile")));
+ url.append(appendProtocol(
+ viewport.applet.getParameter("jnetfile") != null
+ ? viewport.applet.getParameter("jnetfile")
+ : viewport.applet.getParameter("jpredfile")));
}
if (viewport.applet.getParameter("defaultColour") != null)
{
- url.append("&colour="
- + removeWhiteSpace(viewport.applet
- .getParameter("defaultColour")));
+ url.append("&colour=" + removeWhiteSpace(
+ viewport.applet.getParameter("defaultColour")));
}
if (viewport.applet.getParameter("userDefinedColour") != null)
{
- url.append("&colour="
- + removeWhiteSpace(viewport.applet
- .getParameter("userDefinedColour")));
+ url.append("&colour=" + removeWhiteSpace(
+ viewport.applet.getParameter("userDefinedColour")));
}
if (viewport.applet.getParameter("tree") != null)
{
{
System.exit(0);
}
- else
+
+ viewport = null;
+ if (alignPanel != null && alignPanel.overviewPanel != null)
{
+ alignPanel.overviewPanel.dispose();
}
- viewport = null;
alignPanel = null;
this.dispose();
}
{
undoMenuItem.setEnabled(true);
CommandI command = viewport.getHistoryList().peek();
- undoMenuItem.setLabel(MessageManager.formatMessage(
- "label.undo_command",
- new Object[] { command.getDescription() }));
+ undoMenuItem.setLabel(MessageManager
+ .formatMessage("label.undo_command", new Object[]
+ { command.getDescription() }));
}
else
{
redoMenuItem.setEnabled(true);
CommandI command = viewport.getRedoList().peek();
- redoMenuItem.setLabel(MessageManager.formatMessage(
- "label.redo_command",
- new Object[] { command.getDescription() }));
+ redoMenuItem.setLabel(MessageManager
+ .formatMessage("label.redo_command", new Object[]
+ { command.getDescription() }));
}
else
{
// viewport.getColumnSelection().getHiddenColumns()
// != null;
updateEditMenuBar();
- originalSource.firePropertyChange("alignment", null, originalSource
- .getAlignment().getSequences());
+ originalSource.firePropertyChange("alignment", null,
+ originalSource.getAlignment().getSequences());
}
/**
// != null;
updateEditMenuBar();
- originalSource.firePropertyChange("alignment", null, originalSource
- .getAlignment().getSequences());
+ originalSource.firePropertyChange("alignment", null,
+ originalSource.getAlignment().getSequences());
}
AlignmentViewport getOriginatingSource(CommandI command)
{
EditCommand editCommand = (EditCommand) command;
al = editCommand.getAlignment();
- Vector comps = (Vector) PaintRefresher.components.get(viewport
- .getSequenceSetId());
+ Vector comps = PaintRefresher.components
+ .get(viewport.getSequenceSetId());
for (int i = 0; i < comps.size(); i++)
{
if (comps.elementAt(i) instanceof AlignmentPanel)
}
viewport.getAlignment().moveSelectedSequencesByOne(sg,
up ? null : viewport.getHiddenRepSequences(), up);
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
/*
* Also move cDNA/protein complement sequences
viewport, complement);
complement.getAlignment().moveSelectedSequencesByOne(mappedSelection,
up ? null : complement.getHiddenRepSequences(), up);
- getSplitFrame().getComplement(this).alignPanel.paintAlignment(true);
+ getSplitFrame().getComplement(this).alignPanel.paintAlignment(true,
+ false);
}
}
List<SequenceI> sg = new Vector<>();
if (viewport.cursorMode)
{
- sg.add(viewport.getAlignment().getSequenceAt(
- alignPanel.seqPanel.seqCanvas.cursorY));
+ sg.add(viewport.getAlignment()
+ .getSequenceAt(alignPanel.seqPanel.seqCanvas.cursorY));
}
else if (viewport.getSelectionGroup() != null
&& viewport.getSelectionGroup().getSize() != viewport
.getAlignment().getHeight())
{
- sg = viewport.getSelectionGroup().getSequences(
- viewport.getHiddenRepSequences());
+ sg = viewport.getSelectionGroup()
+ .getSequences(viewport.getHiddenRepSequences());
}
if (sg.size() < 1)
SequenceI[] seqs1 = sg.toArray(new SequenceI[sg.size()]);
- SequenceI[] seqs2 = invertGroup.toArray(new SequenceI[invertGroup
- .size()]);
+ SequenceI[] seqs2 = invertGroup
+ .toArray(new SequenceI[invertGroup.size()]);
for (int i = 0; i < invertGroup.size(); i++)
{
seqs2[i] = invertGroup.elementAt(i);
SlideSequencesCommand ssc;
if (right)
{
- ssc = new SlideSequencesCommand("Slide Sequences", seqs2, seqs1,
- size, viewport.getGapCharacter());
+ ssc = new SlideSequencesCommand("Slide Sequences", seqs2, seqs1, size,
+ viewport.getGapCharacter());
}
else
{
- ssc = new SlideSequencesCommand("Slide Sequences", seqs1, seqs2,
- size, viewport.getGapCharacter());
+ ssc = new SlideSequencesCommand("Slide Sequences", seqs1, seqs2, size,
+ viewport.getGapCharacter());
}
int groupAdjustment = 0;
if (historyList != null && historyList.size() > 0
&& historyList.peek() instanceof SlideSequencesCommand)
{
- appendHistoryItem = ssc
- .appendSlideCommand((SlideSequencesCommand) historyList
- .peek());
+ appendHistoryItem = ssc.appendSlideCommand(
+ (SlideSequencesCommand) historyList.peek());
}
if (!appendHistoryItem)
endRes += seq.getStart() - 1;
}
- copiedSequences.append(seq.getName()
- + "\t"
- + startRes
- + "\t"
- + endRes
- + "\t"
- + seq.getSequenceAsString(sg.getStartRes(),
- sg.getEndRes() + 1) + "\n");
+ copiedSequences.append(seq.getName() + "\t" + startRes + "\t" + endRes
+ + "\t" + seq.getSequenceAsString(sg.getStartRes(),
+ sg.getEndRes() + 1)
+ + "\n");
}
}
}
else
{
- newtitle = newtitle.concat(MessageManager.formatMessage(
- "label.from_msname", new String[] { getTitle() }));
+ newtitle = newtitle.concat(MessageManager
+ .formatMessage("label.from_msname", new String[]
+ { getTitle() }));
}
AlignFrame af = new AlignFrame(new Alignment(newSeqs),
viewport.applet, newtitle, false);
viewport.getRanges().setEndSeq(viewport.getAlignment().getHeight());
viewport.getAlignment().getWidth();
- viewport.firePropertyChange("alignment", null, viewport.getAlignment()
- .getSequences());
+ viewport.firePropertyChange("alignment", null,
+ viewport.getAlignment().getSequences());
}
*/
if (sg.getSize() == viewport.getAlignment().getHeight())
{
- boolean isEntireAlignWidth = (((sg.getEndRes() - sg.getStartRes()) + 1) == viewport
- .getAlignment().getWidth()) ? true : false;
+ boolean isEntireAlignWidth = (((sg.getEndRes() - sg.getStartRes())
+ + 1) == viewport.getAlignment().getWidth()) ? true : false;
if (isEntireAlignWidth)
{
String title = MessageManager.getString("label.delete_all");
Panel infoPanel = new Panel();
infoPanel.setLayout(new FlowLayout());
- infoPanel
- .add(new Label(MessageManager.getString("warn.delete_all")));
+ infoPanel.add(
+ new Label(MessageManager.getString("warn.delete_all")));
final JVDialog dialog = new JVDialog(this, title, true, 400, 200);
dialog.setMainPanel(infoPanel);
viewport.setSelectionGroup(null);
viewport.getAlignment().deleteGroup(sg);
- viewport.firePropertyChange("alignment", null, viewport.getAlignment()
- .getSequences());
+ viewport.firePropertyChange("alignment", null,
+ viewport.getAlignment().getSequences());
if (viewport.getAlignment().getHeight() < 1)
{
{
PaintRefresher.Refresh(this, viewport.getSequenceSetId());
alignPanel.updateAnnotation();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
}
}
// JAL-2034 - should delegate to
// alignPanel to decide if overview needs
// updating.
- alignPanel.paintAlignment(false);
+ alignPanel.paintAlignment(false, false);
PaintRefresher.Refresh(alignPanel, viewport.getSequenceSetId());
viewport.sendSelection();
}
// JAL-2034 - should delegate to
// alignPanel to decide if overview needs
// updating.
- alignPanel.paintAlignment(false);
+ alignPanel.paintAlignment(false, false);
PaintRefresher.Refresh(alignPanel, viewport.getSequenceSetId());
viewport.sendSelection();
}
public void invertColSel_actionPerformed()
{
viewport.invertColumnSelection();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
PaintRefresher.Refresh(alignPanel, viewport.getSequenceSetId());
viewport.sendSelection();
}
SequenceI[] seqs;
if (viewport.getSelectionGroup() != null)
{
- seqs = viewport.getSelectionGroup().getSequencesAsArray(
- viewport.getHiddenRepSequences());
+ seqs = viewport.getSelectionGroup()
+ .getSequencesAsArray(viewport.getHiddenRepSequences());
}
else
{
column, al);
}
- statusBar.setText(MessageManager.formatMessage(
- "label.removed_columns",
- new String[] { Integer.valueOf(trimRegion.getSize())
- .toString() }));
+ statusBar.setText(MessageManager
+ .formatMessage("label.removed_columns", new String[]
+ { Integer.valueOf(trimRegion.getSize()).toString() }));
addHistoryItem(trimRegion);
for (SequenceGroup sg : al.getGroups())
SequenceI[] seqs;
if (viewport.getSelectionGroup() != null)
{
- seqs = viewport.getSelectionGroup().getSequencesAsArray(
- viewport.getHiddenRepSequences());
+ seqs = viewport.getSelectionGroup()
+ .getSequencesAsArray(viewport.getHiddenRepSequences());
start = viewport.getSelectionGroup().getStartRes();
end = viewport.getSelectionGroup().getEndRes();
}
addHistoryItem(removeGapCols);
- statusBar.setText(MessageManager.formatMessage(
- "label.removed_empty_columns",
- new String[] { Integer.valueOf(removeGapCols.getSize())
- .toString() }));
+ statusBar.setText(MessageManager
+ .formatMessage("label.removed_empty_columns", new String[]
+ { Integer.valueOf(removeGapCols.getSize()).toString() }));
// This is to maintain viewport position on first residue
// of first sequence
SequenceI[] seqs;
if (viewport.getSelectionGroup() != null)
{
- seqs = viewport.getSelectionGroup().getSequencesAsArray(
- viewport.getHiddenRepSequences());
+ seqs = viewport.getSelectionGroup()
+ .getSequencesAsArray(viewport.getHiddenRepSequences());
start = viewport.getSelectionGroup().getStartRes();
end = viewport.getSelectionGroup().getEndRes();
}
SequenceI seq = al.getSequenceAt(0);
int startRes = seq.findPosition(ranges.getStartRes());
- addHistoryItem(new RemoveGapsCommand("Remove Gaps", seqs, start, end,
- al));
+ addHistoryItem(
+ new RemoveGapsCommand("Remove Gaps", seqs, start, end, al));
ranges.setStartRes(seq.findIndex(startRes) - 1);
if (viewport.getAlignment().getAlignmentAnnotation() != null)
{
- for (int i = 0; i < viewport.getAlignment().getAlignmentAnnotation().length; i++)
+ for (int i = 0; i < viewport.getAlignment()
+ .getAlignmentAnnotation().length; i++)
{
- if (!viewport.getAlignment().getAlignmentAnnotation()[i].autoCalculated)
+ if (!viewport.getAlignment()
+ .getAlignmentAnnotation()[i].autoCalculated)
{
- newal.addAnnotation(viewport.getAlignment()
- .getAlignmentAnnotation()[i]);
+ newal.addAnnotation(
+ viewport.getAlignment().getAlignmentAnnotation()[i]);
}
}
}
PaintRefresher.Register(newaf.alignPanel.seqPanel.seqCanvas,
newaf.alignPanel.av.getSequenceSetId());
- Vector comps = (Vector) PaintRefresher.components.get(viewport
- .getSequenceSetId());
+ Vector comps = PaintRefresher.components
+ .get(viewport.getSequenceSetId());
int viewSize = -1;
for (int i = 0; i < comps.size(); i++)
{
{
viewport.setShowJVSuffix(seqLimits.getState());
alignPanel.fontChanged();
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
}
protected void colourTextMenuItem_actionPerformed()
{
viewport.setColourText(colourTextMenuItem.getState());
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(false, false);
}
protected void displayNonconservedMenuItem_actionPerformed()
{
viewport.setShowUnconserved(displayNonconservedMenuItem.getState());
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(false, false);
}
protected void wrapMenuItem_actionPerformed()
scaleAbove.setEnabled(wrapMenuItem.getState());
scaleLeft.setEnabled(wrapMenuItem.getState());
scaleRight.setEnabled(wrapMenuItem.getState());
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
}
public void overviewMenuItem_actionPerformed()
final OverviewPanel overview = new OverviewPanel(alignPanel);
frame.add(overview);
// +50 must allow for applet frame window
- jalview.bin.JalviewLite.addFrame(frame, MessageManager.formatMessage(
- "label.overview_params", new String[] { this.getTitle() }),
- overview.getPreferredSize().width,
+ jalview.bin.JalviewLite.addFrame(frame, MessageManager
+ .formatMessage("label.overview_params", new String[]
+ { this.getTitle() }), overview.getPreferredSize().width,
overview.getPreferredSize().height + 50);
frame.pack();
{
viewport.setGlobalColourScheme(cs);
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, true);
}
protected void modifyPID_actionPerformed()
public void sortPairwiseMenuItem_actionPerformed()
{
SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray();
- AlignmentSorter.sortByPID(viewport.getAlignment(), viewport
- .getAlignment().getSequenceAt(0));
+ AlignmentSorter.sortByPID(viewport.getAlignment(),
+ viewport.getAlignment().getSequenceAt(0));
addHistoryItem(new OrderCommand("Pairwise Sort", oldOrder,
viewport.getAlignment()));
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
}
public void sortIDMenuItem_actionPerformed()
{
SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray();
AlignmentSorter.sortByID(viewport.getAlignment());
- addHistoryItem(new OrderCommand("ID Sort", oldOrder,
- viewport.getAlignment()));
- alignPanel.paintAlignment(true);
+ addHistoryItem(
+ new OrderCommand("ID Sort", oldOrder, viewport.getAlignment()));
+ alignPanel.paintAlignment(true, false);
}
public void sortLengthMenuItem_actionPerformed()
AlignmentSorter.sortByLength(viewport.getAlignment());
addHistoryItem(new OrderCommand("Length Sort", oldOrder,
viewport.getAlignment()));
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
}
public void sortGroupMenuItem_actionPerformed()
AlignmentSorter.sortByGroup(viewport.getAlignment());
addHistoryItem(new OrderCommand("Group Sort", oldOrder,
viewport.getAlignment()));
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
}
SequenceI current;
int Width = viewport.getAlignment().getWidth();
- for (int i = 0; i < viewport.getAlignment().getSequences().size(); i++)
+ for (int i = 0; i < viewport.getAlignment().getSequences()
+ .size(); i++)
{
current = viewport.getAlignment().getSequenceAt(i);
current.insertCharAt(Width - 1, viewport.getGapCharacter());
}
}
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(false, false);
}
if ((viewport.getSelectionGroup() != null
- && viewport.getSelectionGroup().getSize() < 4 && viewport
- .getSelectionGroup().getSize() > 0)
+ && viewport.getSelectionGroup().getSize() < 4
+ && viewport.getSelectionGroup().getSize() > 0)
|| viewport.getAlignment().getHeight() < 4)
{
return;
protected void njTreeBlosumMenuItem_actionPerformed()
{
- newTreePanel(TreeBuilder.NEIGHBOUR_JOINING, ScoreModels.getInstance()
- .getBlosum62().getName(),
+ newTreePanel(TreeBuilder.NEIGHBOUR_JOINING,
+ ScoreModels.getInstance().getBlosum62().getName(),
"Neighbour joining tree using BLOSUM62");
}
protected void avTreeBlosumMenuItem_actionPerformed()
{
- newTreePanel(TreeBuilder.AVERAGE_DISTANCE, ScoreModels.getInstance()
- .getBlosum62().getName(),
+ newTreePanel(TreeBuilder.AVERAGE_DISTANCE,
+ ScoreModels.getInstance().getBlosum62().getName(),
"Average distance tree using BLOSUM62");
}
SequenceI current;
int Width = viewport.getAlignment().getWidth();
- for (int i = 0; i < viewport.getAlignment().getSequences().size(); i++)
+ for (int i = 0; i < viewport.getAlignment().getSequences()
+ .size(); i++)
{
current = viewport.getAlignment().getSequenceAt(i);
current.insertCharAt(Width - 1, viewport.getGapCharacter());
}
}
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(false, false);
}
- if ((viewport.getSelectionGroup() != null && viewport
- .getSelectionGroup().getSize() > 1)
+ if ((viewport.getSelectionGroup() != null
+ && viewport.getSelectionGroup().getSize() > 1)
|| (viewport.getAlignment().getHeight() > 1))
{
final TreePanel tp = new TreePanel(alignPanel, type, pwType);
public void sortByTree(TreePanel treePanel, String title)
{
SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray();
- AlignmentSorter
- .sortByTree(viewport.getAlignment(), treePanel.getTree());
+ AlignmentSorter.sortByTree(viewport.getAlignment(),
+ treePanel.getTree());
// addHistoryItem(new HistoryItem("Sort", viewport.alignment,
// HistoryItem.SORT));
- addHistoryItem(new OrderCommand(MessageManager.formatMessage(
- "label.order_by_params", new String[] { title }), oldOrder,
- viewport.getAlignment()));
- alignPanel.paintAlignment(true);
+ addHistoryItem(new OrderCommand(MessageManager
+ .formatMessage("label.order_by_params", new String[]
+ { title }), oldOrder, viewport.getAlignment()));
+ alignPanel.paintAlignment(true, false);
}
/**
addHistoryItem(new OrderCommand(undoname, oldOrder,
viewport.getAlignment()));
}
- alignPanel.paintAlignment(true);
+ alignPanel.paintAlignment(true, false);
return true;
}
// TODO: update this text for each release or centrally store it for
// lite and application
g.setFont(new Font("Helvetica", Font.BOLD, 14));
- g.drawString(MessageManager.formatMessage(
- "label.jalviewLite_release", new String[] { version }), x,
- y += fh);
+ g.drawString(MessageManager
+ .formatMessage("label.jalviewLite_release", new String[]
+ { version }), x, y += fh);
g.setFont(new Font("Helvetica", Font.BOLD, 12));
- g.drawString(MessageManager.formatMessage(
- "label.jaview_build_date", new String[] { builddate }), x,
- y += fh);
+ g.drawString(MessageManager.formatMessage("label.jaview_build_date",
+ new String[]
+ { builddate }), x, y += fh);
g.setFont(new Font("Helvetica", Font.PLAIN, 12));
- g.drawString(MessageManager.getString("label.jalview_authors_1"),
- x, y += fh * 1.5);
+ g.drawString(MessageManager.getString("label.jalview_authors_1"), x,
+ y += fh * 1.5);
g.drawString(MessageManager.getString("label.jalview_authors_2"),
x + 50, y += fh + 8);
- g.drawString(
- MessageManager.getString("label.jalview_dev_managers"), x,
- y += fh);
+ g.drawString(MessageManager.getString("label.jalview_dev_managers"),
+ x, y += fh);
g.drawString(MessageManager
.getString("label.jalview_distribution_lists"), x, y += fh);
g.drawString(MessageManager.getString("label.jalview_please_cite"),
x, y += fh + 8);
g.drawString(
- MessageManager.getString("label.jalview_cite_1_authors"),
- x, y += fh);
- g.drawString(
- MessageManager.getString("label.jalview_cite_1_title"), x,
+ MessageManager.getString("label.jalview_cite_1_authors"), x,
y += fh);
+ g.drawString(MessageManager.getString("label.jalview_cite_1_title"),
+ x, y += fh);
g.drawString(MessageManager.getString("label.jalview_cite_1_ref"),
x, y += fh);
}
}
Frame frame = new Frame();
- frame.add(new AboutPanel(JalviewLite.getVersion(), JalviewLite
- .getBuildDate()));
+ frame.add(new AboutPanel(JalviewLite.getVersion(),
+ JalviewLite.getBuildDate()));
jalview.bin.JalviewLite.addFrame(frame,
MessageManager.getString("label.jalview"), 580, 220);
pasteNew.addActionListener(this);
pasteThis.setLabel(MessageManager.getString("label.to_this_alignment"));
pasteThis.addActionListener(this);
- remove2LeftMenuItem.setLabel(MessageManager
- .getString("action.remove_left"));
+ remove2LeftMenuItem
+ .setLabel(MessageManager.getString("action.remove_left"));
remove2LeftMenuItem.addActionListener(this);
- remove2RightMenuItem.setLabel(MessageManager
- .getString("action.remove_right"));
+ remove2RightMenuItem
+ .setLabel(MessageManager.getString("action.remove_right"));
remove2RightMenuItem.addActionListener(this);
- removeGappedColumnMenuItem.setLabel(MessageManager
- .getString("action.remove_empty_columns"));
+ removeGappedColumnMenuItem.setLabel(
+ MessageManager.getString("action.remove_empty_columns"));
removeGappedColumnMenuItem.addActionListener(this);
- removeAllGapsMenuItem.setLabel(MessageManager
- .getString("action.remove_all_gaps"));
+ removeAllGapsMenuItem
+ .setLabel(MessageManager.getString("action.remove_all_gaps"));
removeAllGapsMenuItem.addActionListener(this);
- removeRedundancyMenuItem.setLabel(MessageManager
- .getString("action.remove_redundancy"));
+ removeRedundancyMenuItem
+ .setLabel(MessageManager.getString("action.remove_redundancy"));
removeRedundancyMenuItem.addActionListener(this);
/*
findMenuItem.addActionListener(this);
selectAllSequenceMenuItem.addActionListener(this);
deselectAllSequenceMenuItem.addActionListener(this);
- invertSequenceMenuItem.setLabel(MessageManager
- .getString("action.invert_sequence_selection"));
+ invertSequenceMenuItem.setLabel(
+ MessageManager.getString("action.invert_sequence_selection"));
invertSequenceMenuItem.addActionListener(this);
- invertColSel.setLabel(MessageManager
- .getString("action.invert_column_selection"));
+ invertColSel.setLabel(
+ MessageManager.getString("action.invert_column_selection"));
invertColSel.addActionListener(this);
- deleteGroups.setLabel(MessageManager
- .getString("action.undefine_groups"));
+ deleteGroups
+ .setLabel(MessageManager.getString("action.undefine_groups"));
deleteGroups.addActionListener(this);
- grpsFromSelection.setLabel(MessageManager
- .getString("action.make_groups_selection"));
+ grpsFromSelection.setLabel(
+ MessageManager.getString("action.make_groups_selection"));
grpsFromSelection.addActionListener(this);
createGroup.setLabel(MessageManager.getString("action.create_group"));
createGroup.addActionListener(this);
unGroup.setLabel(MessageManager.getString("action.remove_group"));
unGroup.addActionListener(this);
- annotationColumnSelection.setLabel(MessageManager
- .getString("action.select_by_annotation"));
+ annotationColumnSelection.setLabel(
+ MessageManager.getString("action.select_by_annotation"));
annotationColumnSelection.addActionListener(this);
/*
Menu hideMenu = new Menu(MessageManager.getString("action.hide"));
hideColumns
.setLabel(MessageManager.getString("label.selected_columns"));
- hideSequences.setLabel(MessageManager
- .getString("label.selected_sequences"));
- hideAllButSelection.setLabel(MessageManager
- .getString("label.all_but_selected_region"));
- hideAllSelection.setLabel(MessageManager
- .getString("label.selected_region"));
- showAllHidden.setLabel(MessageManager
- .getString("label.all_sequences_columns"));
+ hideSequences
+ .setLabel(MessageManager.getString("label.selected_sequences"));
+ hideAllButSelection.setLabel(
+ MessageManager.getString("label.all_but_selected_region"));
+ hideAllSelection
+ .setLabel(MessageManager.getString("label.selected_region"));
+ showAllHidden.setLabel(
+ MessageManager.getString("label.all_sequences_columns"));
showColumns.addActionListener(this);
showSeqs.addActionListener(this);
hideColumns.addActionListener(this);
hideAllButSelection.addActionListener(this);
hideAllSelection.addActionListener(this);
showAllHidden.addActionListener(this);
- featureSettings.setLabel(MessageManager
- .getString("action.feature_settings"));
+ featureSettings
+ .setLabel(MessageManager.getString("action.feature_settings"));
featureSettings.addActionListener(this);
- sequenceFeatures.setLabel(MessageManager
- .getString("label.show_sequence_features"));
+ sequenceFeatures.setLabel(
+ MessageManager.getString("label.show_sequence_features"));
sequenceFeatures.addItemListener(this);
sequenceFeatures.setState(false);
- followMouseOverFlag.setLabel(MessageManager
- .getString("label.automatic_scrolling"));
+ followMouseOverFlag.setLabel(
+ MessageManager.getString("label.automatic_scrolling"));
followMouseOverFlag.addItemListener(this);
alProperties.addActionListener(this);
- overviewMenuItem.setLabel(MessageManager
- .getString("label.overview_window"));
+ overviewMenuItem
+ .setLabel(MessageManager.getString("label.overview_window"));
overviewMenuItem.addActionListener(this);
/*
* Configure Annotations menu items and actions
*/
- annotationPanelMenuItem.setLabel(MessageManager
- .getString("label.show_annotations"));
+ annotationPanelMenuItem
+ .setLabel(MessageManager.getString("label.show_annotations"));
annotationPanelMenuItem.addItemListener(this);
- showGroupConsensus.setLabel(MessageManager
- .getString("label.group_consensus"));
- showGroupConservation.setLabel(MessageManager
- .getString("label.group_conservation"));
- showConsensusHistogram.setLabel(MessageManager
- .getString("label.show_consensus_histogram"));
- showSequenceLogo.setLabel(MessageManager
- .getString("label.show_consensus_logo"));
- normSequenceLogo.setLabel(MessageManager
- .getString("label.norm_consensus_logo"));
- applyAutoAnnotationSettings.setLabel(MessageManager
- .getString("label.apply_all_groups"));
+ showGroupConsensus
+ .setLabel(MessageManager.getString("label.group_consensus"));
+ showGroupConservation
+ .setLabel(MessageManager.getString("label.group_conservation"));
+ showConsensusHistogram.setLabel(
+ MessageManager.getString("label.show_consensus_histogram"));
+ showSequenceLogo.setLabel(
+ MessageManager.getString("label.show_consensus_logo"));
+ normSequenceLogo.setLabel(
+ MessageManager.getString("label.norm_consensus_logo"));
+ applyAutoAnnotationSettings
+ .setLabel(MessageManager.getString("label.apply_all_groups"));
applyAutoAnnotationSettings.setState(true);
Menu autoAnnMenu = new Menu(
MessageManager.getString("label.autocalculated_annotation"));
viewTextMenuItem.setLabel(MessageManager.getString("action.text"));
viewTextMenuItem.setState(true);
viewTextMenuItem.addItemListener(this);
- colourTextMenuItem.setLabel(MessageManager
- .getString("label.colour_text"));
+ colourTextMenuItem
+ .setLabel(MessageManager.getString("label.colour_text"));
colourTextMenuItem.addItemListener(this);
- displayNonconservedMenuItem.setLabel(MessageManager
- .getString("label.show_non_conserved"));
+ displayNonconservedMenuItem
+ .setLabel(MessageManager.getString("label.show_non_conserved"));
displayNonconservedMenuItem.addItemListener(this);
wrapMenuItem.setLabel(MessageManager.getString("action.wrap"));
wrapMenuItem.addItemListener(this);
- renderGapsMenuItem.setLabel(MessageManager
- .getString("action.show_gaps"));
+ renderGapsMenuItem
+ .setLabel(MessageManager.getString("action.show_gaps"));
renderGapsMenuItem.setState(true);
renderGapsMenuItem.addItemListener(this);
- centreColumnLabelFlag.setLabel(MessageManager
- .getString("label.centre_column_labels"));
+ centreColumnLabelFlag.setLabel(
+ MessageManager.getString("label.centre_column_labels"));
centreColumnLabelFlag.addItemListener(this);
seqLimits.setState(true);
- seqLimits.setLabel(MessageManager
- .getString("label.show_sequence_limits"));
+ seqLimits.setLabel(
+ MessageManager.getString("label.show_sequence_limits"));
seqLimits.addItemListener(this);
/*
* Configure Colour menu items and actions
*/
- applyToAllGroups.setLabel(MessageManager
- .getString("label.apply_colour_to_all_groups"));
+ applyToAllGroups.setLabel(
+ MessageManager.getString("label.apply_colour_to_all_groups"));
applyToAllGroups.setState(true);
applyToAllGroups.addItemListener(this);
- clustalColour.setLabel(MessageManager
- .getString("label.colourScheme_clustal"));
+ clustalColour.setLabel(
+ MessageManager.getString("label.colourScheme_clustal"));
clustalColour.addActionListener(this);
- zappoColour.setLabel(MessageManager
- .getString("label.colourScheme_zappo"));
+ zappoColour
+ .setLabel(MessageManager.getString("label.colourScheme_zappo"));
zappoColour.addActionListener(this);
- taylorColour.setLabel(MessageManager
- .getString("label.colourScheme_taylor"));
+ taylorColour.setLabel(
+ MessageManager.getString("label.colourScheme_taylor"));
taylorColour.addActionListener(this);
- hydrophobicityColour.setLabel(MessageManager
- .getString("label.colourScheme_hydrophobic"));
+ hydrophobicityColour.setLabel(
+ MessageManager.getString("label.colourScheme_hydrophobic"));
hydrophobicityColour.addActionListener(this);
helixColour.setLabel(MessageManager
.getString("label.colourScheme_helix_propensity"));
strandColour.setLabel(MessageManager
.getString("label.colourScheme_strand_propensity"));
strandColour.addActionListener(this);
- turnColour.setLabel(MessageManager
- .getString("label.colourScheme_turn_propensity"));
+ turnColour.setLabel(
+ MessageManager.getString("label.colourScheme_turn_propensity"));
turnColour.addActionListener(this);
- buriedColour.setLabel(MessageManager
- .getString("label.colourScheme_buried_index"));
+ buriedColour.setLabel(
+ MessageManager.getString("label.colourScheme_buried_index"));
buriedColour.addActionListener(this);
purinePyrimidineColour.setLabel(MessageManager
.getString("label.colourScheme_purine/pyrimidine"));
// RNAInteractionColour.setLabel(MessageManager
// .getString("label.rna_interaction"));
// RNAInteractionColour.addActionListener(this);
- RNAHelixColour.setLabel(MessageManager
- .getString("label.colourScheme_rna_helices"));
+ RNAHelixColour.setLabel(
+ MessageManager.getString("label.colourScheme_rna_helices"));
RNAHelixColour.addActionListener(this);
- userDefinedColour.setLabel(MessageManager
- .getString("action.user_defined"));
+ userDefinedColour
+ .setLabel(MessageManager.getString("action.user_defined"));
userDefinedColour.addActionListener(this);
- PIDColour.setLabel(MessageManager
- .getString("label.colourScheme_%_identity"));
+ PIDColour.setLabel(
+ MessageManager.getString("label.colourScheme_%_identity"));
PIDColour.addActionListener(this);
- BLOSUM62Colour.setLabel(MessageManager
- .getString("label.colourScheme_blosum62"));
+ BLOSUM62Colour.setLabel(
+ MessageManager.getString("label.colourScheme_blosum62"));
BLOSUM62Colour.addActionListener(this);
- tcoffeeColour.setLabel(MessageManager
- .getString("label.colourScheme_t-coffee_scores"));
+ tcoffeeColour.setLabel(
+ MessageManager.getString("label.colourScheme_t-coffee_scores"));
// it will be enabled only if a score file is provided
tcoffeeColour.setEnabled(false);
tcoffeeColour.addActionListener(this);
- conservationMenuItem.setLabel(MessageManager
- .getString("action.by_conservation"));
+ conservationMenuItem
+ .setLabel(MessageManager.getString("action.by_conservation"));
conservationMenuItem.addItemListener(this);
noColourmenuItem.setLabel(MessageManager.getString("label.none"));
noColourmenuItem.addActionListener(this);
- abovePIDThreshold.setLabel(MessageManager
- .getString("label.above_identity_threshold"));
+ abovePIDThreshold.setLabel(
+ MessageManager.getString("label.above_identity_threshold"));
abovePIDThreshold.addItemListener(this);
- nucleotideColour.setLabel(MessageManager
- .getString("label.colourScheme_nucleotide"));
+ nucleotideColour.setLabel(
+ MessageManager.getString("label.colourScheme_nucleotide"));
nucleotideColour.addActionListener(this);
- modifyPID.setLabel(MessageManager
- .getString("label.modify_identity_threshold"));
+ modifyPID.setLabel(
+ MessageManager.getString("label.modify_identity_threshold"));
modifyPID.setEnabled(abovePIDThreshold.getState());
modifyPID.addActionListener(this);
modifyConservation.setLabel(MessageManager
.getString("label.modify_conservation_threshold"));
modifyConservation.setEnabled(conservationMenuItem.getState());
modifyConservation.addActionListener(this);
- annotationColour.setLabel(MessageManager
- .getString("action.by_annotation"));
+ annotationColour
+ .setLabel(MessageManager.getString("action.by_annotation"));
annotationColour.addActionListener(this);
/*
* Configure Calculate menu items and actions
*/
- sortPairwiseMenuItem.setLabel(MessageManager
- .getString("action.by_pairwise_id"));
+ sortPairwiseMenuItem
+ .setLabel(MessageManager.getString("action.by_pairwise_id"));
sortPairwiseMenuItem.addActionListener(this);
sortIDMenuItem.setLabel(MessageManager.getString("action.by_id"));
sortIDMenuItem.addActionListener(this);
- sortLengthMenuItem.setLabel(MessageManager
- .getString("action.by_length"));
+ sortLengthMenuItem
+ .setLabel(MessageManager.getString("action.by_length"));
sortLengthMenuItem.addActionListener(this);
sortGroupMenuItem.setLabel(MessageManager.getString("action.by_group"));
sortGroupMenuItem.addActionListener(this);
- pairwiseAlignmentMenuItem.setLabel(MessageManager
- .getString("action.pairwise_alignment"));
+ pairwiseAlignmentMenuItem.setLabel(
+ MessageManager.getString("action.pairwise_alignment"));
pairwiseAlignmentMenuItem.addActionListener(this);
- PCAMenuItem.setLabel(MessageManager
- .getString("label.principal_component_analysis"));
+ PCAMenuItem.setLabel(
+ MessageManager.getString("label.principal_component_analysis"));
PCAMenuItem.addActionListener(this);
autoCalculate = new CheckboxMenuItem(
- MessageManager.getString("label.autocalculate_consensus"), true);
- averageDistanceTreeMenuItem.setLabel(MessageManager
- .getString("label.average_distance_identity"));
+ MessageManager.getString("label.autocalculate_consensus"),
+ true);
+ averageDistanceTreeMenuItem.setLabel(
+ MessageManager.getString("label.average_distance_identity"));
averageDistanceTreeMenuItem.addActionListener(this);
- neighbourTreeMenuItem.setLabel(MessageManager
- .getString("label.neighbour_joining_identity"));
+ neighbourTreeMenuItem.setLabel(
+ MessageManager.getString("label.neighbour_joining_identity"));
neighbourTreeMenuItem.addActionListener(this);
- avDistanceTreeBlosumMenuItem.setLabel(MessageManager
- .getString("label.average_distance_blosum62"));
+ avDistanceTreeBlosumMenuItem.setLabel(
+ MessageManager.getString("label.average_distance_blosum62"));
avDistanceTreeBlosumMenuItem.addActionListener(this);
- njTreeBlosumMenuItem.setLabel(MessageManager
- .getString("label.neighbour_blosum62"));
+ njTreeBlosumMenuItem
+ .setLabel(MessageManager.getString("label.neighbour_blosum62"));
njTreeBlosumMenuItem.addActionListener(this);
- sortByTreeMenu.setLabel(MessageManager
- .getString("action.by_tree_order"));
+ sortByTreeMenu
+ .setLabel(MessageManager.getString("action.by_tree_order"));
Menu sortMenu = new Menu(MessageManager.getString("action.sort"));
Menu calculateTreeMenu = new Menu(
MessageManager.getString("action.calculate_tree"));
theApplet.add(embeddedMenu, BorderLayout.NORTH);
theApplet.add(statusBar, BorderLayout.SOUTH);
// TODO should size be left to the layout manager?
- alignPanel.setSize(theApplet.getSize().width,
- theApplet.getSize().height - embeddedMenu.getHeight()
- - statusBar.getHeight());
+ alignPanel.setSize(theApplet.getSize().width, theApplet.getSize().height
+ - embeddedMenu.getHeight() - statusBar.getHeight());
theApplet.add(alignPanel, BorderLayout.CENTER);
final AlignFrame me = this;
theApplet.addFocusListener(new FocusListener()
viewer = (Viewer) jmolviewer;
} catch (ClassCastException ex)
{
- System.err.println("Unsupported viewer object :"
- + jmolviewer.getClass());
+ System.err.println(
+ "Unsupported viewer object :" + jmolviewer.getClass());
}
if (viewer == null)
{
}
// resolve data source
// TODO: this code should be a refactored to an io package
- DataSourceType protocol = AppletFormatAdapter.resolveProtocol(
- pdbFile, FileFormat.PDB);
+ DataSourceType protocol = AppletFormatAdapter.resolveProtocol(pdbFile,
+ FileFormat.PDB);
if (protocol == null)
{
return false;
{
if (seqs[i] != null)
{
- sequences.addElement(new Object[] { seqs[i],
- (chains != null) ? chains[i] : null });
+ sequences
+ .addElement(new Object[]
+ { seqs[i], (chains != null) ? chains[i] : null });
}
}
seqs = new SequenceI[sequences.size()];
chains = (String[]) sqch[1];
if (seqs == null || seqs.length == 0)
{
- System.err
- .println("JalviewLite.AlignFrame:newStructureView: No sequence to bind structure to.");
+ System.err.println(
+ "JalviewLite.AlignFrame:newStructureView: No sequence to bind structure to.");
}
if (protocol == null)
{
{
// register the association(s) and quit, don't create any windows.
if (StructureSelectionManager.getStructureSelectionManager(applet)
- .setMapping(seqs, chains, pdb.getFile(), protocol) == null)
+ .setMapping(seqs, chains, pdb.getFile(), protocol, null) == null)
{
System.err.println("Failed to map " + pdb.getFile() + " ("
+ protocol + ") to any sequences");
}
if (ajm != null)
{
- System.err
- .println("Incremental adding and aligning structure to existing Jmol view not yet implemented.");
+ System.err.println(
+ "Incremental adding and aligning structure to existing Jmol view not yet implemented.");
// try and add the pdb structure
// ajm.addS
ajm = null;
// otherwise, create a new window
if (applet.jmolAvailable)
{
- new AppletJmol(pdb, seqs, chains, alignPanel,
- protocol);
+ new AppletJmol(pdb, seqs, chains, alignPanel, protocol);
applet.lastFrameX += 40;
applet.lastFrameY += 40;
}
*/
AlignmentI aln;
if ((aln = viewport.getAlignment()) != null
- && (aln.getHeight() != file.getHeight() || aln.getWidth() != file
- .getWidth()))
+ && (aln.getHeight() != file.getHeight()
+ || aln.getWidth() != file.getWidth()))
{
// TODO: raise a dialog box here rather than bomb out.
- System.err
- .println("The scores matrix does not match the alignment dimensions");
+ System.err.println(
+ "The scores matrix does not match the alignment dimensions");
}