Balance column and rescan revamp

A new Balance column is added to the transaction view. The
Balance column makes the transaction view look more like
a bank statement, showing the effect on your total balance
each transaction makes.

In order to get the Balance column to calculate the correct
balance, I needed to beef up the "-rescan" command line
option. There seems to be the possibility for allot of bogus
transactions in the wallet that don't get removed by the
old rescan. The new rescan purges all transactions from the
wallet. The new rescan also runs as a thread which uses the
QT progress bar. New progress messages go to the debug log
for the benefit of a non-QT yacoind build.

So, if your transaction view balance does not match your
overall balance, then use the new and improved "-rescan" to
fix it.
Balance column and rescan tweaks

Changes made mostly to handle shutting down client
while rescan is in progress. Also some performance tweaks
and comment changes.
Merge branch 'balances'