It might be that the File Type
event is only triggered when a filetype has actually been set, which, in your case, is the exact opposite. I would try something like:
autocmd BufEnter * if &filetype == "" | setlocal noxpandtab | setlocal noautoindent | endif
That should work, maybe you need some other event types than only BufEnter
. Also don't forget to wrap your autocmd's in an augroup
, or they might be executed multiple times, see http://learnvimscriptthehardway.stevelosh.com/chapters/14.html ;) good luck!