Make the settings menu actually work.

Fill settings with their stored values and make them set the stored
value when changed.

Also, the stylesheet links are now generated dynamically from config.js.

Settings are reserialized and saved in the cookie whenever they
change, rather than on page unloading. It would be surprising to
change a setting in one tab, then find it overwritten after a second
tab is closed.