             tooltipFormatter: @tooltipFormatter,
             binTooltipFormatter: @binTooltipFormatter
 
-        # TODO: apply margin?
+        @drawHighlights()
+
         [ start, end ] = @scales.x.domain()
-
         # repaint the datasets
         # First paint lines and ticks
         for datasetId of @datasets

d3 = require 'd3'
{ split, intersects, merged, after, subtract, parseDuration, offsetDate, centerTooltipOn } = require './utils.coffee'
EventEmitter = require './event-emitter.coffee'

RecordDataset = require './datasets/record-dataset.coffee'


    setBinTooltipFormatter: (@binTooltipFormatter) ->

    setHighlightInterval: (start, end, fillColor, strokeColor, outsideColor) ->
      if start and end
          @highlightInterval =
              start: start
              end: end
              fillColor: fillColor
              strokeColor: strokeColor
              outsideColor: outsideColor
      else
          @highlightInterval = null

      @redraw()


# Interface for a source
class Source
