Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Moved clearRect  one pixel to the left to match lineWidth. Made clearRect 2px wide to make sure both sides of the line path are cleared.
  • Loading branch information
Fransan committed Aug 3, 2017
1 parent df0dded commit ae82377
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/plugins/crosshair.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ Flotr.addPlugin('crosshair', {

if (position) {
context.clearRect(
Math.round(position.relX) + plotOffset.left,
Math.round(position.relX) + plotOffset.left - 1,
plotOffset.top,
1,
2,
this.plotHeight + 1
);
context.clearRect(
Expand Down

0 comments on commit ae82377

Please sign in to comment.