Added two new functions:

  insertLineBefore - adds a new line above the current one (or first in a selection) with the indentation of the current line.
  insertLineAfter - adds a new line below the current one (or last in a selection) with the indentation of the current line.

Updated the splitIntoLines function to work with multiple ranges.