Extract the granularity-picking code of the date ticker into a new function.
Keep the X axis ticks when logscale is set globally.

Currently, setting {logscale: true} at the toplevel options with a
numeric X axis attempts to use logarithmic ticks for the X axis too,
with strange results since the X values aren't scaled logarithmically.
This resulted in tests/logscale.html skipping the "6" and "8" numbers on
the ticker, and the modified demo with a large X value shows the effect
more clearly.

This change wraps the numericTicks generator as numericLinearTicks,
ignoring 'logscale' in its axis options, and uses that for the X axis
numeric ticker. Arguably doing it the other way around would be clearer,
but that would be a much larger refactoring.

(Note that date-valued X axes as used in the stock demo weren't affected
by this issue.)
Fix highlighting for zoomed graphs

The code wasn't correctly applying the left boundary offset when converting a row index in the pruned data to/from a row index for the full data set.

Add a getLeftBoundary_ helper method and replace the existing loops that attempted to find the first defined record. Not sure why it saves multiple boundaryIds anyway, the code assumes it can just use the first one.

Also fix an apparently-invalid usage in getSelection().
Add closest-series highlighting demo to gallery

This is a port of tests/series-highlight.html.
Merge pull request #138 from klausw-g/highlight-series-gallery

Pulled this in, thanks! (Dan, do lmk if this is an issue)
Add closest-series highlighting demo to gallery
Merge branch 'master' into highlight-stacked
Fix connectSeparatedPoints, add test

The original connectSeparatedPoints code renumbered points within series, with the effect that 'row' as used in setSelection didn't work as expected - it selects unrelated points.

This change keeps the point numbering intact, and instead moves the logic to skip missing points to the canvas renderer and setSelection().

A new auto_test confirms this behavior.
Fix a bug involving calls to updateOptions() while panning.

This showed up with data that gets updated periodically, i.e. the once/second
updates in dynamic-update.html. Previously the chart would disappear whenever
an update occurred.
Merge branch 'master' of github.com:danvk/dygraphs
Merge pull request #137 from klausw-g/highlight-stacked

Fix highlighting for zoomed graphs
Merge pull request #136 from klausw-g/non-logscale-x

Keep the X axis ticks when logscale is set globally.
Add some missing context.restore() calls
Check for balanced context.save() and context.restore() calls
Merged from upstream
Fix NaN handling for stacked graphs.

Dygraph was handling NaNs inconsistently, drawing lines and shaded areas
for values encountered while stacking until it ran into a NaN, then
stopping at that point due to NaN contagion, with the effect that it
drew some lines and partial gaps.

Change this to create a clean gap in the data by propagatng the NaN contagion
in both directions.

Note that users can preprocess the data to replace NaNs with zeros if
they prefer that, but this should not happen by default since it's
irreversible and can lead to confusing graphs that don't match actual
data.
Merge pull request #139 from klausw-g/stacked-NaN

Fix NaN handling for stacked graphs.
Fix issue 255: date supplied as YYYY-MM-DD shows previous day's date...

JavaScript date parsing is stunningly complex. This was broken by
https://github.com/danvk/dygraphs/commit/769e8bc7b8799385e2677b26a5c0a72e839f44ca

The underlying issue is that new Date("YYYY-MM-DD") parses the date in
UTC, but new Date("YYYY/MM/DD") parses it in the local time zone.
Merge branch 'master' of github.com:danvk/dygraphs
Fix error when labelsDiv=null (was affecting unboxed-spark test)
Fix unboxed-spark test.

display: "inline" elements cannot have an explicit width/height, but
"inline-block" elements can.