}
if (Cache.getDefault("HIDE_INTRONS", true))
{
- af.avc.markColumnsContainingFeatures(true, false, false,
- SequenceOntologyI.EXON);
- af.getViewport().hideSelectedColumns();
+ hideIntronsIfPresent(af);
}
Desktop.addInternalFrame(af, title, AlignFrame.DEFAULT_WIDTH,
return al;
}
+ /**
+ * Hide columns not containing 'exon' features, provided there are exon
+ * features on the alignment
+ *
+ * @param af
+ */
+ public void hideIntronsIfPresent(AlignFrame af)
+ {
+ boolean hasExons = af.avc.markColumnsContainingFeatures(false, false,
+ false,
+ SequenceOntologyI.EXON);
+ if (hasExons)
+ {
+ af.avc.markColumnsContainingFeatures(true, false, true,
+ SequenceOntologyI.EXON);
+ af.getViewport().hideSelectedColumns();
+ }
+ }
+
void showErrorMessage(final String error)
{
resetDialog();