printreviewdialog change default printer

This commit is contained in:
xiaoyifang 2022-03-12 18:31:21 +08:00
parent 156eca87d5
commit ab1b525f12

View file

@ -3333,8 +3333,8 @@ void MainWindow::on_pageSetup_triggered()
void MainWindow::on_printPreview_triggered()
{
QPrinter printer;
QPrintPreviewDialog dialog( &printer, this );
// QPrinter printer;
QPrintPreviewDialog dialog( &getPrinter(), this );
connect( &dialog, SIGNAL( paintRequested( QPrinter * ) ),
this, SLOT( printPreviewPaintRequested( QPrinter * ) ) );