       @activeEditSession.finalizeSelections()
       @syncCursorAnimations()
 
-  # Internal:
   afterAttach: (onDom) ->
     return unless onDom
     @redraw() if @redrawOnReattach

    @observeConfig 'editor.fontSize', (fontSize) => @setFontSize(fontSize)
    @observeConfig 'editor.fontFamily', (fontFamily) => @setFontFamily(fontFamily)

  # Internal: Responsible for handling events made to the editor.
  handleEvents: ->
    @on 'focus', =>
      @hiddenInput.focus()

  # iterator - A {Function} that's called on each match
  backwardsScanInBufferRange: (args...) -> @getBuffer().backwardsScanInRange(args...)

  ###
  # Internal #
  ###

  configure: ->
    @observeConfig 'editor.showLineNumbers', (showLineNumbers) => @gutter.setShowLineNumbers(showLineNumbers)
    @observeConfig 'editor.showInvisibles', (showInvisibles) => @setShowInvisibles(showInvisibles)
