Start with a QTextEdit, and for the PDF export functionality, have a look at QPrinter - you can set the output type to PdfFormat.