[Qt-interest] QPainter - is layout possible?

Ian Thomson Ian.Thomson at iongeo.com
Thu Apr 23 09:39:02 CEST 2009


Hi,

There is a function called QWidget::render which was introduced in Qt 
4.3 which would allow you to do roughly what you ask. Basically you can 
make a QPrinter and set it to output to a PDF file, then render the top 
level widget to it using that function.

As you are using an earlier version, I am not so sure it is possible. 
Can you upgrade?

Cheers,
Ian.


Ankit Agarwal wrote:
> Hi,
> I m using Qt4.2.2.
> I want to paint certain things on to a pdf. Is there some way i put 
> these things in a layout and then put the layout to the pdf, the way we 
> put items in an QWidget.
> Its just an idea that came to my mind and was thinking if its possible?
> 
> -- 
> Regards,
> Ankit Agarwal
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest




More information about the Qt-interest-old mailing list