Revamped settings.
Merged from Github.