using autoIndent and skip undo in insertText to try to reduce stuff in undo buffer