Modular Preference Panel (and supporting infrastructure)

Backport of main patch