Add support for HiDPI displays

This is a fix for https://code.google.com/p/dygraphs/issues/detail?id=381.

Here's a shot of one of the examples with the existing code on my MBP:
![dygraph_before](https://f.cloud.github.com/assets/1622701/1026172/753f626a-0e59-11e3-98bc-0d077fe5e6df.png)

and with this fix:
![dygraph_after](https://f.cloud.github.com/assets/1622701/1026174/76ce18ec-0e59-11e3-8d47-7d609dc8a779.png)

Tested with Chrome, Firefox, Safari and Opera on OSX. I haven't tested IE as I don't have access to a Windows pc.

It's not quite ready though :/ there's a FIXME for the grid_per_axis.js test. I couldn't quite work out why it was failing. I suspect the coordinates computed for x/y using halfDown() are intended to land in the middle of the gridlines, but are slightly off when scaling up by the context ratio. I'll debug it a bit more.

The fix seems quite well covered by the existing tests that check imagedata (quite a few of them blew up before I fixed PixelSampler etc), but I'm happy to work on an additional set of tests if you think it would be worthwhile.