make sure that highlights are removed on moving to another window