beginning to write to pdf