- seqs = viewport.alignment.getSequences();\r
-\r
- /* Commented out regions below are partial implementation of todo above.\r
- * divide start,end into visible chunks, and for each:\r
- int diff=end-start+1;\r
- int diffmax=0;\r
- int dr[] = new int[seqs.size()];\r
- */\r
- for (int i = 0; i < seqs.size(); i++)\r
- {\r
- current = (SequenceI) seqs.elementAt(i);\r
- //dr[i]=\r
- current.removeGaps(start, end);\r
- /*if (d<diff) // can only shift\r
- diff=d;\r
- if (diffmax<d)\r
- diffmax=d;\r
- */\r
- }\r
- /* // after the end of each chunk -\r
- * if (diff>0) {\r
- // record shift for history.\r
- editgaps.addShift(start, diff);\r
- if (viewport.hasHiddenColumns && diffmax>diff) {\r
- // pad sequence\r
- StringBuffer gaps=new StringBuffer(diffmax);\r
- for (int i=0,j=diffmax-diff; i<j; i++)\r
- gaps.append(viewport.getGapCharacter());\r
- for (int i=0, j=seqs.size(); i<j; i++) {\r
- current = (SequenceI) seqs.elementAt(i);\r
- if (dr[i]-diff>0) {\r
- String sq = current.getSequence();\r
- current.setSequence(sq.substring(0, hcend-dr[i])+gaps.substring(0, dr[i]-diff)+sq.substring());\r
- }\r
- }\r
- }\r
- }*/\r
-\r
- viewport.setStartRes(seq.findIndex(startRes)-1);\r
- viewport.firePropertyChange("alignment", null, viewport.getAlignment().getSequences());\r
- }\r
-\r
- public void alignmentChanged()\r
- {\r
- viewport.alignment.padGaps();\r
- if(viewport.autocalculateConsensus)\r
- {\r
- viewport.updateConsensus();\r
- viewport.updateConservation();\r
- }\r
-\r
- resetAllColourSchemes();\r
- if(alignPanel.overviewPanel!=null)\r
- alignPanel.overviewPanel.updateOverviewImage();\r