PDA

View Full Version : How to convert QTextDocument to PNG file?



Gonzalez
31st January 2006, 13:45
I store in QTextDocument some images and text , i use the function print , to print this document into a paper.

I try to make a PDF file with the new function in QPrinter , setOutputFormat(QPrinter::PdfFormat) , but it doesn't work.

I also would like to make a PNG file of this document.

My question is , How to convert QTextDocument to PNG file?

Everall
2nd February 2006, 15:46
I store in QTextDocument some images and text , i use the function print , to print this document into a paper.

I try to make a PDF file with the new function in QPrinter , setOutputFormat(QPrinter::PdfFormat) , but it doesn't work.


Did you use
void QPrinter::setOutputFileName ( const QString & fileName ) ?

I don't know a solution for your second question.

Cheers