summaryrefslogtreecommitdiffstats
path: root/src/printsupport/dialogs/qpagesetupdialog_unix_p.h
diff options
context:
space:
mode:
authorAlbert Astals Cid <albert.astals.cid@kdab.com>2017-12-20 10:41:33 +0100
committerAlbert Astals Cid <albert.astals.cid@kdab.com>2018-01-09 15:42:33 +0000
commitc1aaa13939f3f2fdc46bccf718dbd406c243f741 (patch)
treea581697a615810418567db345e761fdd09159189 /src/printsupport/dialogs/qpagesetupdialog_unix_p.h
parentbc632bc2bfe1a966bb187c20bb321d31fb8fe0b7 (diff)
Fix custom page size handling in the Unix print dialog
There were several problems that i've fixed in a single commit since they are very interwinded * The dialog used QPageSize::Custom for two things, the custom sizes coming from the printer and the "user can write whatever size they want" size. Now only the printer custom sizes use QPageSize::Custom and we use m_realCustomPageSizeIndex for the "user can write whatever size they want" one. * The dialog stored the QPageSize id as the combo userData, that doesn't work when the printer has multiple custom sizes since they all share QPageSize::Custom so now it stores the QPageSize itself Task-number: QTBUG-58733 Change-Id: Ie640a07bb5e24b753db83c091c836e8af4ff126c Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Diffstat (limited to 'src/printsupport/dialogs/qpagesetupdialog_unix_p.h')
-rw-r--r--src/printsupport/dialogs/qpagesetupdialog_unix_p.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/printsupport/dialogs/qpagesetupdialog_unix_p.h b/src/printsupport/dialogs/qpagesetupdialog_unix_p.h
index 5b77a73871..0b9723e05a 100644
--- a/src/printsupport/dialogs/qpagesetupdialog_unix_p.h
+++ b/src/printsupport/dialogs/qpagesetupdialog_unix_p.h
@@ -102,6 +102,7 @@ private:
QPageLayout m_pageLayout;
QPageLayout::Unit m_units;
bool m_blockSignals;
+ int m_realCustomPageSizeIndex;
};
QT_END_NAMESPACE