+ public Color getSequenceColour(SequenceI seq)
+ {
+ if(sequenceColours==null || !sequenceColours.containsKey(seq))
+ {
+ return Color.white;
+ }
+ else
+ {
+ return (Color)sequenceColours.get(seq);
+ }
+ }
+
+ public void setSequenceColour(SequenceI seq, Color col)
+ {
+ if(sequenceColours==null)
+ {
+ sequenceColours = new Hashtable();
+ }
+
+ if(col == null)
+ {
+ sequenceColours.remove(seq);
+ }
+ else
+ {
+ sequenceColours.put(seq, col);
+ }
+ }
+ /**
+ * returns the visible column regions of the alignment
+ * @param selectedRegionOnly true to just return the contigs intersecting with the selected area
+ * @return
+ */
+ public int[] getViewAsVisibleContigs(boolean selectedRegionOnly) {
+ int[] viscontigs=null;
+ int start = 0, end = 0;
+ if(selectedRegionOnly && selectionGroup!=null)
+ {
+ start = selectionGroup.getStartRes();
+ end = selectionGroup.getEndRes()+1;
+ }
+ else
+ {
+ end = alignment.getWidth();
+ }
+ viscontigs = colSel.getVisibleContigs(start, end);
+ return viscontigs;
+ }
+