     @ctx.translate(0,@canvas.height)
     @ctx.scale(1,-1)
 
-  toCanvasXCoord: (dataPoint) -> ((dataPoint - @smallestX) / (@largestX - @smallestX)) * @canvas.width
-
-  toDataXCoord: (canvasPoint) -> (canvasPoint / @canvas.width) * (@largestX - @smallestX)
+  toDataXCoord: (domCoord) -> ((domCoord - @canvas.getBoundingClientRect().left)/ @canvas.width) * (@largestX - @smallestX)
 
   # TODO: fix the math on this one....
-  toDomXCoord: (dataPoint) -> ((dataPoint / @canvas.width) * (@largestX - @smallestX) * @canvas.width) + @canvas.getBoundingClientRect().left
+  toDomXCoord: (dataPoint) -> ((dataPoint) * (@largestX - @smallestX)) + @canvas.getBoundingClientRect().left
 
 class Marks
   constructor: -> @all = []

  MAX_WIDTH = 150

  constructor: (e, @canvasGraph) ->
    #TODO: make an active state
    @canvas = @canvasGraph.canvas

    @element = document.createElement('div')

    @domXMin = markLeftX
    @domXMax = markRightX

    #data coords
    @dataXMin = @canvasGraph.toDataXCoord(@domXMin)
    @dataXMax = @canvasGraph.toDataXCoord(@domXMax)

  updateCursor: (e) ->
    if e.layerY < 15
