Hi
I'm new to QT, so be patient with me!
I want to print what is currently shown in a ListWidget but I have no idea how to do it.
Hope someone can help me
Hi
I'm new to QT, so be patient with me!
I want to print what is currently shown in a ListWidget but I have no idea how to do it.
Hope someone can help me
Do you want to print it to the printer ?
If yes, you will need to render your list widget to the printer.
Have a look at QWidget::render and for the paint device use QPrinter object.
Thanks for your reply
Yes I want to print to the printer. I have figured out that I should use QWidget::render and QPrinter but I cant figure out how to use them.
I have searched on different forums and on the Internet without finding something helpful.
Can someone write some examples that shows how to use QWidget::redner and QPrinter?
Something like -
Qt Code:
widget->render(&printer);To copy to clipboard, switch view to plain text mode
Also read - Printing with Qt in Assistant
Bookmarks