From: Jim Procter Date: Thu, 11 Jul 2013 12:57:03 +0000 (+0100) Subject: JAL-1347 identify and set rendering settings for consensus annotation rows X-Git-Tag: Jalview_2_9~226^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=e66bdc1c0086ab56c56979d9dc6635e81503eb84;p=jalview.git JAL-1347 identify and set rendering settings for consensus annotation rows JAL-966 Note - should abstract this logic even further away in Jalview v3 --- diff --git a/src/jalview/renderer/AnnotationRenderer.java b/src/jalview/renderer/AnnotationRenderer.java index f492d9c..8f25e77 100644 --- a/src/jalview/renderer/AnnotationRenderer.java +++ b/src/jalview/renderer/AnnotationRenderer.java @@ -333,6 +333,26 @@ public class AnnotationRenderer for (int i = 0; i < aa.length; i++) { AlignmentAnnotation row = aa[i]; + { + // check if this is a consensus annotation row and set the display settings appropriately + // TODO: generalise this to have render styles for consensus/profile + // data + if (row.groupRef != null && row == row.groupRef.getConsensus()) + { + renderHistogram = row.groupRef.isShowConsensusHistogram(); + renderProfile = row.groupRef.isShowSequenceLogo(); + normaliseProfile = row.groupRef.isNormaliseSequenceLogo(); + } + else if (row == consensusAnnot) + { + renderHistogram = av_renderHistogram; + renderProfile = av_renderProfile; + normaliseProfile = av_normaliseProfile; + } else { + renderHistogram = true; + // don't need to set render/normaliseProfile since they are not currently used in any other annotation track renderer + } + } Annotation[] row_annotations = row.annotations; if (!row.visible) {