Added proper tab handling in CodeMirror, fixes #145