Don Knuth's text-layout algorithm in TeX is highly regarded as one of the best.

It'd be pretty cool to have it hacked into a browser. I'd like to see what kind of impact that made on various popular websites.

I've read that the line-breaking algorithm in Safari is the most complex algorithm in the whole program..