Change Widget API

This is a "half commit": big changes have been implemented and compiled, but not integrated yet.