Cleaning and fixing in the settings widget

This fixes #197