From: gmungoc Date: Tue, 14 Mar 2017 09:42:40 +0000 (+0000) Subject: JAL-2438 comment/Javadoc tidies X-Git-Tag: Release_2_10_2~3^2~164 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=17bea66b37be69a173f6b1ea73c8544bd4c6e2b1;p=jalview.git JAL-2438 comment/Javadoc tidies --- diff --git a/src/jalview/renderer/seqfeatures/FeatureRenderer.java b/src/jalview/renderer/seqfeatures/FeatureRenderer.java index 7915fd0..f826a88 100644 --- a/src/jalview/renderer/seqfeatures/FeatureRenderer.java +++ b/src/jalview/renderer/seqfeatures/FeatureRenderer.java @@ -320,10 +320,7 @@ public class FeatureRenderer extends FeatureRendererModel Color drawnColour = null; /* - * iterate over features in ordering of their rendering; - * if drawing a range of columns, use render order to ensure last is on top - * if drawing a single column (as in findFeatureColour), with no - * transparency, work backwards to find the topmost rendered feature colour + * iterate over features in ordering of their rendering (last is on top) */ for (int renderIndex = 0; renderIndex < renderOrder.length; renderIndex++) { @@ -343,15 +340,18 @@ public class FeatureRenderer extends FeatureRendererModel continue; } + /* + * a feature type may be flagged as shown but the group + * an instance of it belongs to may be hidden + */ if (featureGroupNotShown(sequenceFeature)) { continue; } /* - * check feature overlaps the visible part of the alignment, - * unless doing offscreenRender (to the Overview window or a - * structure viewer) which is not limited + * check feature overlaps the target range + * TODO: efficient retrieval of features overlapping a range */ if (sequenceFeature.getBegin() > endPos || sequenceFeature.getEnd() < startPos) diff --git a/src/jalview/viewmodel/seqfeatures/FeatureRendererModel.java b/src/jalview/viewmodel/seqfeatures/FeatureRendererModel.java index 085743f..100b58f 100644 --- a/src/jalview/viewmodel/seqfeatures/FeatureRendererModel.java +++ b/src/jalview/viewmodel/seqfeatures/FeatureRendererModel.java @@ -550,11 +550,12 @@ public abstract class FeatureRendererModel implements } /** - * calculate the render colour for a specific feature using current feature - * settings. + * Returns the configured colour for a specific feature using current feature + * settings. This does not include any consideration of feature visibility, + * colour transparency, graduated colour shading etc. * * @param feature - * @return render colour for the given feature + * @return */ public Color getColour(SequenceFeature feature) { @@ -586,11 +587,13 @@ public abstract class FeatureRendererModel implements featureColours.put(featureType, col); } + @Override public void setTransparency(float value) { transparency = value; } + @Override public float getTransparency() { return transparency;