summaryrefslogtreecommitdiffstats
path: root/src/printsupport/dialogs
diff options
context:
space:
mode:
authorZhang Hao <zhanghao@uniontech.com>2022-01-27 11:20:57 +0800
committerZhang Hao <zhanghao@uniontech.com>2022-02-18 09:06:10 +0800
commit715ed74c89a7e6c64aa85e36682699d41c195a33 (patch)
treef6dc61b874d0334fa92053e1de6cd1fa95fccee4 /src/printsupport/dialogs
parent9e0f1b905a92fbdd0b04de4606659e60bbf55482 (diff)
Sync QPrinter orientation when PageSetup Orientation selected
QPrinter orientation will not effect when PageSetup Orientation selected Fix this by sync PageSetup orientation property to QPrinter. Fixes: QTBUG-100261 Pick-to: 5.15 6.2 6.3 Change-Id: I264852ea18317308dfcfb58c880f5e8ad8d299bd Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/printsupport/dialogs')
-rw-r--r--src/printsupport/dialogs/qpagesetupdialog_unix.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
index 739deaa6e1..a400ae3354 100644
--- a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
+++ b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
@@ -529,6 +529,7 @@ void QPageSetupWidget::updateWidget()
void QPageSetupWidget::setupPrinter() const
{
m_printer->setPageLayout(m_pageLayout);
+ m_printer->setPageOrientation(m_pageLayout.orientation());
#if QT_CONFIG(cups)
QCUPSSupport::PagesPerSheet pagesPerSheet = qvariant_cast<QCUPSSupport::PagesPerSheet>(m_ui.pagesPerSheetCombo->currentData()
);