   reloadGrammar: ->
     @displayBuffer.reloadGrammar()
 
-  ### Internal ###
-
+  # Private:
   shouldAutoIndent: ->
     config.get("editor.autoIndent")
 
+  # Public: Performs all editor actions from the given function within a single
+  # undo step.
+  #
+  # Useful for implementing complex operations while still ensuring that the
+  # undo stack remains relevant.
   transact: (fn) -> @buffer.transact(fn)
 
+  # Private:
   beginTransaction: -> @buffer.beginTransaction()
 
+  # Private:
   commitTransaction: -> @buffer.commitTransaction()
 
+  # Private:
   abortTransaction: -> @buffer.abortTransaction()
 
+  # Private:
   inspect: ->
     JSON.stringify @state.toObject()
 
+  # Private:
   logScreenLines: (start, end) -> @displayBuffer.logLines(start, end)
 
+  # Private:
   handleGrammarChange: ->
     @unfoldAll()
     @trigger 'grammar-changed'
 
+  # Private:
   handleMarkerCreated: (marker) =>
     if marker.matchesAttributes(@getSelectionMarkerAttributes())
       @addSelection(marker)
 
+  # Private:
   getSelectionMarkerAttributes: ->
     type: 'selection', editSessionId: @id, invalidation: 'never'
 
+  # Private:
   getDebugSnapshot: ->
     [
       @displayBuffer.getDebugSnapshot()

  # {Delegates to: TextBuffer.isModified}
  isModified: -> @buffer.isModified()

  # Identifies if the modified buffer should let you know if it's closing
  # without being saved.
  #
  # Returns a {Boolean}.
  shouldPromptToSave: -> @isModified() and not @buffer.hasMultipleEditors()

  # {Delegates to: DisplayBuffer.screenPositionForBufferPosition}


      @setSelectedBufferRange(selection.translate([-1]), preserveFolds: true)

  # Public: Moves the selected line down one row.
  moveLineDown: ->
    selection = @getSelectedBufferRange()
    lastRow = @buffer.getLastRow()
