The somewhat lengthy discussion is here. If you haven't taken part in it, well, your bad - it's more or less closed now (I hope).

Tabs are faster for editing. Consider assembly:gerryg400 wrote:I just can't understand the tab versus space thing. Lots of people have given reasons for using spaces instead of tabs. But, has anyone been able to provide a single reason for using tabs ?
Code: Select all
mov foo, bar ;Comment
I hold the option key, press the right arrow key then press the left arrow key. I'm using eclipse but even editors as old as vi have that type of navigation facility.Imagine your cursor is at the end of "bar" and you want to move the cursor to the start of the comment.
You press 'w' exactly once.Brendan wrote:Imagine your cursor is at the end of "bar" and you want to move the cursor to the start of the comment. In a perfect world it'd be like modern wordprocessors, with tab stops at arbitrary positions (recorded in the file's header), and you'd only need to press "right cursor" key once. Unfortunately the plain text file format has no header so a text editor can't support that; and you end up with maybe 5 tabs where you have to press the "right cursor" key 5 times. It's crappy, but it could be worse...Code: Select all
mov foo, bar ;Comment
gerryg400 wrote:I hold the option key, press the right arrow key then press the left arrow key. I'm using eclipse but even editors as old as vi have that type of navigation facility.
So, is the standard for all text editing (including all text editors, all word-processors, text input boxes in web browsers, etc) "hold the option key, press the right arrow key then press the left arrow key" or is the standard "press 'w' exactly once"? I tried both methods in Kwrite and neither worked; then I tried both methods in notepad++ and neither worked; therefore you're both wrong.Kevin wrote:You press 'w' exactly once.
Code: Select all
struct mystruct
{
<tab>int myvar;<sssppppaaacccceee>// Always 0.
<tab>int my_long_named_var;<space>// Never 0.
};
Code: Select all
foo = func ( para1,
para2,
para3 );
Chandra, doesn't your editor have a mode where it will enter 4 (or the appropriate number for alignment) spaces when you press the tab key ?Chandra wrote:Personally, I'd invest time getting myself a cup of coffee, than having required to type 4 spaces for indentation
That's why I use tabs for indentation, but spaces for alignment:bluemoon wrote:With space it's always aligned, not always for TAB.
Code: Select all
<tab>foo = func ( para1,
<tab><ssppaaaccee>para2,
<tab><ssppaaaccee>para3 );