JAL-3253-applet JAL-3383 Overview
[jalview.git] / src / jalview / api / FeatureRenderer.java
index cf3c8da..6caa1c7 100644 (file)
@@ -125,7 +125,7 @@ public interface FeatureRenderer
   List<String> getFeatureGroups();
 
   /**
-   * get groups that are visible/invisible
+   * get groups that are visible/invisible -- JalviewLite only?
    * 
    * @param visible
    * @return
@@ -133,7 +133,7 @@ public interface FeatureRenderer
   List<String> getGroups(boolean visible);
 
   /**
-   * Set visibility for a list of groups
+   * Set visibility for a list of groups -- JalviewLite only?
    * 
    * @param toset
    * @param visible
@@ -255,14 +255,29 @@ public interface FeatureRenderer
    * <p>
    * Returns null if
    * <ul>
-   * <li>feature type is not visible, or</li>
    * <li>feature group is not visible, or</li>
    * <li>feature values lie outside any colour threshold, or</li>
    * <li>feature is excluded by filter conditions</li>
    * </ul>
+   * This method does not check feature type visibility.
    * 
    * @param feature
    * @return
    */
   Color getColour(SequenceFeature feature);
+
+  /**
+   * Answers true if feature would be shown, else false. A feature is shown if
+   * <ul>
+   * <li>its feature type is set to visible</li>
+   * <li>its feature group is either null, or set to visible</li>
+   * <li>it is not excluded by a colour threshold on score or other numeric
+   * attribute</li>
+   * <li>it is not excluded by a filter condition</li>
+   * </ul>
+   * 
+   * @param feature
+   * @return
+   */
+  boolean isVisible(SequenceFeature feature);
 }