preserving buffer so that we can take a screenshot out of it