From: amwaterhouse Date: Wed, 16 Nov 2005 17:02:14 +0000 (+0000) Subject: Highlight doesnt use offset X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=0ec05d5a2b604aaedcca284a696a4fc71707b444;p=jalview.git Highlight doesnt use offset --- diff --git a/src/MCview/AppletPDBCanvas.java b/src/MCview/AppletPDBCanvas.java index 1df39fa..4c62b60 100755 --- a/src/MCview/AppletPDBCanvas.java +++ b/src/MCview/AppletPDBCanvas.java @@ -99,7 +99,7 @@ public class AppletPDBCanvas extends Panel implements MouseListener, MouseMotion highlightBond1 = null; highlightBond2 = null; - int index = ii - mainchain.seqstart - mainchain.offset+1; + int index = ii - mainchain.seqstart; if(index <0 ) return; diff --git a/src/MCview/PDBCanvas.java b/src/MCview/PDBCanvas.java index f0806a8..33dfb8b 100755 --- a/src/MCview/PDBCanvas.java +++ b/src/MCview/PDBCanvas.java @@ -557,13 +557,13 @@ public class PDBCanvas extends JPanel implements MouseListener, MouseMotionListe if(highlightBond1!=null && highlightBond1==tmpBond) { - g.setColor(tmpBond.endCol.brighter().brighter().brighter()); + g.setColor(tmpBond.endCol.brighter().brighter().brighter().brighter()); drawLine(g, xmid, ymid, xend, yend); } if(highlightBond2!=null && highlightBond2==tmpBond) { - g.setColor(tmpBond.startCol.brighter().brighter().brighter()); + g.setColor(tmpBond.startCol.brighter().brighter().brighter().brighter()); drawLine(g, xstart, ystart, xmid, ymid); } @@ -846,7 +846,8 @@ public class PDBCanvas extends JPanel implements MouseListener, MouseMotionListe highlightBond1 = null; highlightBond2 = null; - int index = ii - mainchain.seqstart - mainchain.offset+1; + int index = ii - mainchain.seqstart; + if(index <0 ) return;