- alignFrame.parseFeaturesFile(textarea.getText(),
- jalview.io.AppletFormatAdapter.PASTE);
+ if (new AnnotationFile().readAnnotationFile(
+ alignFrame.viewport.getAlignment(), textarea.getText(),
+ jalview.io.AppletFormatAdapter.PASTE))
+ {
+ alignFrame.alignPanel.fontChanged();
+ alignFrame.alignPanel.setScrollValues(0, 0);
+ alignFrame.statusBar
+ .setText("Successfully pasted annotation to alignment.");
+
+ }
+ else
+ {
+ if (!alignFrame.parseFeaturesFile(textarea.getText(),
+ jalview.io.AppletFormatAdapter.PASTE))
+ {
+ alignFrame.statusBar.setText("Couldn't parse pasted text as a valid annotation, feature, GFF, or T-Coffee score file.");
+ }
+ }