Fixed #21.
Fixed #20.
Fixed #14 and some other various minor bugs/formatting errors.