update pdf content and layout