Die Flagge des Marasek



Current Texts Comic Imprint Calendar Search PHP-Classes Container-Wizard main.s21


Class Library
Global Politics
World Outlook

Hard Tabs vs. Soft Tabs

Previous: Klassen verf├╝gbarNext: Second Life - Second Capitalism
Assigned keywords: Computer, Foreign Language, Programmieren

Sometimes in life, a man has to step forward and stand firmly for his beliefs. And with all the flame wars going on in computer science, I've discovered a new one which I did not even thought of before: the war between the hard and soft tabbers.

It all began when I read the developer FAQ on PEAR, and they insisted on space-indentation in any contributed code.

The problem is as follows - in order to indent code, one can either press TAB to insert one \t or instead press space any number of times to get the same effect. Of course, modern editors can be configured to do the latter for you when pressing TAB.

I never really thought of using spaces instead of TAB. TAB is one character which gives an abstract information: indent by one level, with level being dependent on my editor and configuration. Also, it allows me to easily maneuver among indentation levels with the cursor keys and backspace.
Blanks, on the other hand, are much more a direct information: go x times right. When you want to delete those, you have to delete every one of them, and if you want to maneuver within this structure, you have to move one by one. Yuck. Also, it bars me from possibility to customize the view to my needs by simply telling the editor "render \t x spaces wide" and instead being at the mercy at whatever someone else considers to be an appropriate indentation width.

True enough, some of the examples in the FAQ make sense, as they show how certain statements would look with different tab width:



However, to make one thing clear: I'm not the kind of programmer which would spread a single command across several lines. Let's see how long I will stay on that side - I have a tendency to convert promptly, like I changed from underscore_style to CamelCaps within one day.


Please note: comments posted won't be visible immediately, as they will be checked for harmful content.

* Title  
* Nickname  
* Comment