I have an Ubuntu Linux development machine and a Macbook that I work on. On my laptop I use Textmate for PHP development on the go. The problem is that when I return to my Ubuntu dev machine and open my files in emacs, the formatting is off. I think it looks like one tab in Textmate is for some reason several tabs in emacs. So my code takes up the entire screen in emacs but only the left part of the screen in Textmate. Does anyone have any experience with this?
Share
Like Bears will eat you said, it seems like the two editors have differing opinions on how wide a tab is. Be default a tab character (
\t) is 8 spaces wide on emacs. Maybe TextMate shows a tab as 4 spaces in your configuration?You can set your tab-width in emacs (to 4 spaces in this case) by adding the following to your .emacs:
I don’t know anything about configuring TextMate.
Alternatively you can configure emacs to use spaces rather than tabs for indentation:
Again, I don’t know how you do that with TextMate.