Reducing line length to within 80 chars

This is supposedly recommended by the Python coding standards.  In some
cases this made the code a bit easier to read in that some long parts were
turned into variables which could then be given descriptive names.