diff --git a/uk/ac/sanger/artemis/components/BasePlotGroup.java b/uk/ac/sanger/artemis/components/BasePlotGroup.java index 0de7102b6827cd7b651a028c079437e783ea78db..0b2e6a56897b7318b1119ac05e98cd11dc16a54f 100644 --- a/uk/ac/sanger/artemis/components/BasePlotGroup.java +++ b/uk/ac/sanger/artemis/components/BasePlotGroup.java @@ -308,6 +308,24 @@ public class BasePlotGroup extends JPanel final Component base_plot = findPlotByAlgorithm(algorithm); return base_plot.isVisible (); } + + + /** + * Return the number of visible plots + * @return + */ + public int getVisibleCount() + { + int cnt = 0; + Component comp[] = getComponents(); + for(int i = 0 ; i<comp.length ; ++i) + if(comp[i] instanceof BasePlot) + { + if(comp[i].isVisible()) + cnt++; + } + return cnt; + } /** * Given an Algorithm, find and set the visibility of the corresponding