package jalview.viewmodel.seqfeatures;
import jalview.api.AlignViewportI;
+import jalview.api.FeatureColourI;
import jalview.api.FeaturesDisplayedI;
import jalview.datamodel.AlignmentI;
import jalview.datamodel.SequenceFeature;
protected Object currentColour;
/*
- * ordering of rendering, where last means on top
+ * feature types in ordering of rendering, where last means on top
*/
protected String[] renderOrder;
// Object c = featureColours.get(featureType);
// if (c == null || c instanceof Color || (c instanceof GraduatedColor &&
// !((GraduatedColor)c).getMaxColor().equals(_col)))
+ if (col instanceof FeatureColourI)
{
- featureColours.put(featureType, col);
+ if (((FeatureColourI) col).isGraduatedColour())
+ {
+ col = new GraduatedColor((FeatureColourI) col);
+ }
+ else
+ {
+ col = ((FeatureColourI) col).getColour();
+ }
}
+ featureColours.put(featureType, col);
}
public void setTransparency(float value)