Windows: Fix assignment of margins in QPageSetupDialog.

Task-number: QTBUG-40061
Change-Id: Id5c952a7d6280f2ab7180bff01911d6cffe57034
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
This commit is contained in:
Friedemann Kleint 2014-07-22 14:14:22 +02:00
parent b0d0a2680a
commit fac1d4d17e

View File

@ -137,9 +137,8 @@ int QPageSetupDialog::exec()
QDialog::setVisible(false); QDialog::setVisible(false);
if (result) { if (result) {
engine->setGlobalDevMode(psd.hDevNames, psd.hDevMode); engine->setGlobalDevMode(psd.hDevNames, psd.hDevMode);
d->printer->setPageMargins(QMarginsF(psd.rtMargin.left / multiplier, psd.rtMargin.right / multiplier, const QMarginsF margins(psd.rtMargin.left, psd.rtMargin.top, psd.rtMargin.right, psd.rtMargin.bottom);
psd.rtMargin.top / multiplier, psd.rtMargin.bottom / multiplier), d->printer->setPageMargins(margins / multiplier, layout.units());
layout.units());
// copy from our temp DEVMODE struct // copy from our temp DEVMODE struct
if (!engine->globalDevMode() && hDevMode) { if (!engine->globalDevMode() && hDevMode) {