Flat-UI support

This adds drop-in support for Flat-UI, with no downsides besides a slight API change.