final code structure for the pdf generation (printing language)