refactoring of display, cache flushing enabled