TanTayBui / flot

Automatically exported from code.google.com/p/flot
MIT License
0 stars 0 forks source link

flot 1.1 with jquery.flot.resize - resizing height forever #682

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
the bug appears in function resizeCanvas on line 714

function resizeCanvas(c) {
  if (c.width != canvasWidth)
    c.width = canvasWidth;

  if (c.height != canvasHeight)
    c.height = canvasHeight-4; // Included -4 resolve my bug

  var cctx = c.getContext("2d");
  cctx.restore();
  cctx.save();
}

probably not the best way.

Original issue reported on code.google.com by tonybol...@gmail.com on 26 Mar 2012 at 9:11

GoogleCodeExporter commented 9 years ago
I haven't been able to find any problems with the resize behavior.  Also I'm 
not sure what you mean by Flot 1.1; the current version is 0.7.  Could you 
provide more info on your setup, and a test case if possible?

Original comment by dnsch...@gmail.com on 9 May 2012 at 12:42

GoogleCodeExporter commented 9 years ago
Sorry, it would be "Flot v0.7", using "Flot.Resize v1.1", but the bug was found 
in the source of Flot.

Original comment by tonybol...@gmail.com on 9 May 2012 at 2:35

GoogleCodeExporter commented 9 years ago

Original comment by dnsch...@gmail.com on 4 Jun 2012 at 2:36

GoogleCodeExporter commented 9 years ago
I've spent some more time testing, and still can't reproduce this.  The code 
makes sense as written; I don't see what subtracting 4 is supposed to do.

Could you please provide a test case, or explain exactly how your fix solves 
the problem?  Do you have margins or padding on your container?  Thanks!

Original comment by dnsch...@gmail.com on 4 Jun 2012 at 4:47

GoogleCodeExporter commented 9 years ago

Original comment by dnsch...@gmail.com on 4 Jun 2012 at 4:58

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
ok, must be something specific to my system.

Original comment by tonybol...@gmail.com on 4 Jun 2012 at 8:36

GoogleCodeExporter commented 9 years ago

Original comment by dnsch...@gmail.com on 4 Jun 2012 at 8:44