Renamed flush_space to more appropriate flush_location. Added smarter flushing in UI. It will now only flush areas that drew something. This still should be improved, though, to more efficiently handle cases where some things overlap.