{
Dimension d = ap.annotationScroller.getPreferredSize();
int dif = evt.getY() - oldY;
+ dif -= dif % ap.av.getCharHeight();
- dif /= ap.av.getCharHeight();
- dif *= ap.av.getCharHeight();
+ // don't allow setting an annotation panel height larger than visible
+ // (otherwise you can't get back)
+ if (d.height - dif > ap.idPanelHolder.getHeight()
+ - ap.getIdSpaceFillerPanel1().getHeight())
+ {
+ return;
+ }
if ((d.height - dif) > 20)
{
hscrollHolder.add(hscrollFillerPanel, BorderLayout.WEST);
this.add(sequenceHolderPanel, BorderLayout.CENTER);
}
+
+ public JPanel getIdSpaceFillerPanel1()
+ {
+ return idSpaceFillerPanel1;
+ }
}