diff --git a/API.md b/API.md index 3d13c1a..e0d6d55 100644 --- a/API.md +++ b/API.md @@ -1,5 +1,26 @@ # Flot Reference # +**Table of Contents** + +[Introduction](#introduction) +| [Data Format](#data-format) +| [Plot Options](#plot-options) +| [Customizing the legend](#customizing-the-legend) +| [Customizing the axes](#customizing-the-axes) +| [Multiple axes](#multiple-axes) +| [Time series data](#time-series-data) +| [Customizing the data series](#customizing-the-data-series) +| [Customizing the grid](#customizing-the-grid) +| [Specifying gradients](#specifying-gradients) +| [Plot Methods](#plot-methods) +| [Hooks](#hooks) +| [Plugins](#plugins) +| [Version number](#version-number) + +--- + +## Introduction ## + Consider a call to the plot function: ```js diff --git a/NEWS.md b/NEWS.md index ba811b3..ffe5e00 100644 --- a/NEWS.md +++ b/NEWS.md @@ -9,6 +9,24 @@ (patch by Karl Quinsland, pull request #1058, issue #1059, earlier patches by Jason Swank, issue #331, and Rene Pieter Kok, issue #344) + +## Flot 0.8.2 ## + +### Changes ### + + - Added a table of contents to the API documentation. + (patch by Brian Peiris, pull request #1064) + +### Bug fixes ### + + - Fixed a bug where the second axis in an xaxes/yaxes array incorrectly had + its 'innermost' property set to false or undefined, even if it was on the + other side of the plot from the first axis. This resulted in the axis bar + being visible when it shouldn't have been, which was especially obvious + when the grid had a left/right border width of zero. + (reported by Teq1, fix researched by ryleyb, issue #1056) + + ## Flot 0.8.1 ## ### Bug fixes ### diff --git a/examples/interacting/index.html b/examples/interacting/index.html index 19136df..15b2437 100644 --- a/examples/interacting/index.html +++ b/examples/interacting/index.html @@ -111,14 +111,14 @@

One of the goals of Flot is to support user interactions. Try pointing and clicking on the points.

- +

A tooltip is easy to build with a bit of jQuery code and the data returned from the plot.

-

+

diff --git a/jquery.flot.js b/jquery.flot.js index ad2ef5c..2ad93ab 100644 --- a/jquery.flot.js +++ b/jquery.flot.js @@ -425,7 +425,7 @@ Licensed under the MIT license. element: positions.length ? info.element.clone() : info.element, x: x, y: y - } + }; positions.push(position); @@ -1351,7 +1351,7 @@ Licensed under the MIT license. ticks = axis.ticks || [], labelWidth = opts.labelWidth || 0, labelHeight = opts.labelHeight || 0, - maxWidth = labelWidth || axis.direction == "x" ? Math.floor(surface.width / (ticks.length || 1)) : null; + maxWidth = labelWidth || axis.direction == "x" ? Math.floor(surface.width / (ticks.length || 1)) : null, legacyStyles = axis.direction + "Axis " + axis.direction + axis.n + "Axis", layer = "flot-" + axis.direction + "-axis flot-" + axis.direction + axis.n + "-axis " + legacyStyles, font = opts.font || "flot-tick-label tickLabel"; @@ -1396,13 +1396,13 @@ Licensed under the MIT license. if ($.inArray(axis, samePosition) == samePosition.length - 1) axisMargin = 0; // outermost + // Determine whether the axis is the first (innermost) on its side + + innermost = $.inArray(axis, samePosition) == 0; + // determine tick length - if we're innermost, we can use "full" - if (tickLength == null) { - var sameDirection = $.grep(all, function (a) { - return a && a.reserveSpace; - }); - innermost = $.inArray(axis, sameDirection) == 0; + if (tickLength == null) { if (innermost) tickLength = "full"; else diff --git a/jquery.flot.selection.js b/jquery.flot.selection.js old mode 100755 new mode 100644