3 ms·
It seems like the takeaway is that you should use a well-designed syntax highlighting scheme. You cannot expect everybody reading your code to be using a good s
by jwdunne 12y ago
It seems like the takeaway is that you should use a well-designed syntax highlighting scheme. You cannot expect everybody reading your code to be using a good syntax highlighting scheme. Either way, I think code should be readable independent of editor features.
I have noticed that, if you make code readable without syntax highlighting, it's always readable with syntax highlighting. The reverse is not true. I would even argue that the code readable without highlighting is more readable with highlighting than the code written just for highlighting.
I don't use vertical alignment. I do think that a long list of vars is harder to read and vertical alignment helps with that. Yet, the solution for me is to attack the core problem. I reduce the number of moving parts inside a procedure, which you can be sure variables are.
Perhaps the author should improve the trivial examples by showing the code with syntax highlighting and vertical alignment.
- kazagistar 12y agoSyntax highlighting is a much more common feature then vertical alignment in editors. People should be able to read your code, but they should also be able to edit it without hassle, and mismatching indentation, or doing it manually, is quite horrible. If you want vertical alignment, it seems easier to just align it vertically for yourself. Customize your presentation, but leave it generic for everyone else.