Increase Python 3 compatibility.

* add shebangs ("#!")
* add source code encodings
* add module docstrings
* add "from __future__" imports to increase Python 3 compatibility
* use absolute imports in the settings files.

I have imported practically everything from __future__. Absolute imports
are necessary in order for the imports to work correctly in a cross-version
compatible way. Print and division should be harmless enough.
The only thing that I am not really sure about is the unicode_literals.

Some times this import can cause problems, for example `str.join(" ", my_list)`
results in an exception because join() expects a string and it receives a
unicode.