Don't end up with an empty layout or view.

When changing the setting for views or layout, if we're not yet running an app,
we store the new value as the default configuration.  If we're in an app, we
still do that, but we also change the value of the template engine for those
settings.

Closes #326