Update to ensure conformity with coding guidelines

The python files were changed to ensure conformity to the Tryton
coding guidelines outlined in the document at
https://code.google.com/p/tryton/wiki/CodingGuidelines

The files were checked using pep8 with ignore=E123,E124,E126,E128
as recommended.