New preferences dialog

Highly experimental