Design fixes and enhancements.

see #585