Add tab_modified indicator

Replaces #996.