   
   
   func dimLineUnderLocation(location:CGPoint) {
-    //let currentLine = lineNumberUnderPoint(location)
-    let currentLine = Int((location.y / (font.lineHeight + lineSpacing)))
+    let currentLine = lineNumberUnderPoint(location)
     slightlyDimLineWhileDraggingOver(lineNumber: currentLine)
   }
   
   func slightlyDimLineWhileDraggingOver(#lineNumber:Int) {
-    //let FirstLineNumberRect = getLineNumberRect(lineNumber)
+    let FirstLineNumberRect = boundingRectForLineNumber(lineNumber)
     let LineHeight = font.lineHeight + lineSpacing
-    let FirstLineNumberRect = CGRect(
-      x: 0,
-      y: LineHeight * CGFloat(lineNumber ),
-      width: frame.width,
-      height: LineHeight)
     let HighlightingRect = CGRect(
       x: FirstLineNumberRect.origin.x,
       y: FirstLineNumberRect.origin.y,

            boundingRect = layoutManager.boundingRectForGlyphRange(layoutManager.glyphRangeForCharacterRange(paraRange, actualCharacterRange: nil), inTextContainer: textContainer)
            boundingRect!.origin.x = 0
            boundingRect!.size.width = frame.width
            stop.initialize(true)
          }
        } else {
          var characterRangeString = storage.string()!.substringWithRange(charRange).stringByTrimmingCharactersInSet(NSCharacterSet.newlineCharacterSet())
          if countElements(characterRangeString) > 0 {
            numberOfExtraLines++
          }
          
          
        }
    }
    layoutManager.enumerateLineFragmentsForGlyphRange(glyphsToShow,
      usingBlock: lineFragmentClosure)
    if  boundingRect == nil {
      println(lineNumber)
      println(numberOfExtraLines)
      let LineHeight = font.lineHeight + lineSpacing
      let LineNumberRect = CGRect(
        x: 0,
        y: LineHeight * CGFloat(lineNumber - numberOfExtraLines),
        width: frame.width,
        height: LineHeight)
      boundingRect = LineNumberRect
    }
    
    return boundingRect!

  
  func adjustLineViewsForDragLocation(loc:CGPoint) {
    //calculate which line the drag is currently on
    var lineNumber = lineNumberUnderPoint(loc)
    
    var maxLine = 1
    for key in dragOverlayLabels.keys {
