Boost logo

Boost :

From: David Abrahams (abrahams_at_[hidden])
Date: 2000-03-14 20:22:56

beman dawes <bema-_at_[hidden]> wrote:
original article:
> I would be interested in hearing some details of how you use
> proportional fonts. I have tried a couple of times and was very
> unhappy with the results.

For what it's worth, I used proportional fonts for many years in my old
company. Then I switched to a project where everyone was using
fixed-width. I was basically unable to program until I switched my
editor to use my proportional font. After a little while, odd
alignments in other peoples' code (we all used tabs - these occurred
after the first non-whitespace) began to irk me, and I was able to
switch back to the fixed-width font, and found two things:

1. I needed to adopt the project's convention of adding whitespace
within parens. Don't ask me why (I don't do it anymore), but I was much
more comfortable writing:

  if ( x != 0 )
     foo( x + 1 );


  if (x != 0)
     foo(x + 1);

2. The other thing I found was more interesting: my use of proportional
fonts had been a crutch. I had been packing way too much stuff too
densely together. Making code look readable with a fixed-width font
forced me to refactor things much sooner, before they got out of hand.
I imagine an 80-character line restriction might have the same effect.


Boost list run by bdawes at, gregod at, cpdaniel at, john at