public void draw(boolean showSequenceFeatures, boolean showAnnotation,
FeatureRenderer transferRenderer)
{
- // System.out.println(this.getHeight());
- // setPreferredSize(new Dimension(od.getWidth(), od.getHeight()));
-
miniMe = null;
veryLastMiniMe = lastMiniMe;
@Override
public void paintComponent(Graphics g)
{
-
if (restart)
{
if (lastMiniMe == null)
}
else if (lastMiniMe != null)
{
+ // is this a resize?
if ((getWidth() > 0) && (getHeight() > 0)
&& ((getWidth() != od.getWidth())
|| (getHeight() != od.getHeight())))
{
- // scale the alignment and annotation separately *** if there is
- // annotation ***
+ // if there is annotation, scale the alignment and annotation separately
if (od.getGraphHeight() > 0)
{
BufferedImage topImage = lastMiniMe.getSubimage(0, 0,
}
else
{
- System.out.println("Resetting height from/to: " + od.getHeight()
- + " " + getHeight());
od.setWidth(getWidth());
od.setHeight(getHeight());
}
od.setBoxPosition(av.getAlignment().getHiddenSequences(),
av.getAlignment().getHiddenColumns());
}
- else
+ else // not a resize
{
if (alpha != 0) // this is a timer triggered dissolve
{
g2d.dispose();
}
- /* else if (lastMiniMe != miniMe)
- {
- g.drawImage(lastMiniMe, 0, 0, getWidth(), getHeight(), this);
- g.setColor(TRANS_GREY);
- g.fillRect(0, 0, getWidth(), getHeight());
- }*/
else
{
// fall back to normal behaviour
g.drawImage(lastMiniMe, 0, 0, getWidth(), getHeight(), this);
}
-
}
-
}
// draw the box