zmjone2992
[H]ard|Gawd
- Joined
- Jul 3, 2007
- Messages
- 1,033
War? We don't go to war over spaces. You want war?
Emacs sucks. Vim forever.
god i hate vim. and all people who use it too
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
War? We don't go to war over spaces. You want war?
Emacs sucks. Vim forever.
Would you not have the same problem using tabs because different editors use different widths for tabs?
No, you wouldn't. If the \t character is in the file, the editor displays its version of \t. If 2, 3, or 4 spaces are in the file, it displays 2, 3, or 4 spaces. If everyone puts a tab in, everything lines up on their screen (probably, spacing beyond the first tab may be screwy if they use spaces there) If people put X spaces in, but X changes between people in one file, stuff doesn't line up anymore.
I still prefer spaces, but I work in console editors sometimes, so I like to restrict it to 80 chars, and I'm the only one working on my code (student) so yeah. Plus, it's the coding standard for my school.
How is it a problem if their editor displays the tab how they like to see the code?![]()
textarea.code, pre.code {
tab-display-width: 4sp; /* and other units */
}
var bagel = new Array('cream cheese',
'honey',
'sesame',
'toasted');
I should use soft tabs, but I don't. Most coding standards specify 4 spaces for indentation. But, I've just gotten used to it, so for me, using tabs is perfectly acceptable to indent code. However, the issue with using tabs is demonstrated in the following piece of code:
Code:var bagel = new Array('cream cheese', 'honey', 'sesame', 'toasted');
If that line had been indented, you'd need to use a mixture of tabs + spaces to align that code. If you use tabs alone, you will not be able to align it properly.
I have no idea why anyone would code in a variable width font, though. None of the characters would line up.
Code:var bagel = new Array('cream cheese', 'honey', 'sesame', 'toasted');
Soft tabs. Does that technically count for spaces or tabs in the poll? I think I hastily and incorrectly picked spaces.
think of it as:
"\t vs. space characters for indents?"
i think the poll is pretty much useless at this point do to this apparent misinterpretation
bagels and cream cheese ftw