     len = @data.getLength @row
     maxcol = len - (if cursorOptions.pastEnd then 0 else 1)
     if @moveCol < 0
-      @col = Math.max(0, len + @moveCol + 1)
-    else
-      @col = Math.max(0, Math.min(maxcol, @moveCol))
+      col = Math.max(0, len + @moveCol + 1)
+    else
+      col = Math.max(0, Math.min(maxcol, @moveCol))
+    @_setCol col
     if not cursorOptions.keepProperties
       do @_getPropertiesFromContext
 

  #   - keepProperties:  for movement, whether we should keep italic/bold state

  set: (row, col, cursorOptions) ->
    @row = row
    @setCol col, cursorOptions

  setRow: (row, cursorOptions) ->
    @row = row
    @_fromMoveCol cursorOptions

  _setRow: (row) ->
    @row = row

  setCol: (moveCol, cursorOptions = {pastEnd: true}) ->
    @moveCol = moveCol

  clone: () ->
    return new Cursor @view, @row, @col, @moveCol

  _setRow: (row) ->
    @emit 'rowChange', @row, row
    @row = row

  _setCol: (col) ->
    @emit 'colChange', @col, col
    @col = col

  from: (other) ->
    @_setRow other.row
    @_setCol other.col
    @moveCol = other.moveCol

  # cursorOptions:
