From: Vadim Zeitlin Date: Tue, 2 Apr 2002 10:20:52 +0000 (+0000) Subject: fixed paper size calculation (convert from 10ths of mm to mm correctly) X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/01cf2f9512e90d1c70e9423f5b099fe5624bcc1b fixed paper size calculation (convert from 10ths of mm to mm correctly) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14904 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/cmndata.cpp b/src/common/cmndata.cpp index eaf2321f5e..2fe0f2ff51 100644 --- a/src/common/cmndata.cpp +++ b/src/common/cmndata.cpp @@ -1512,12 +1512,9 @@ void wxPageSetupDialogData::CalculatePaperSizeFromId() wxSize sz = wxThePrintPaperDatabase->GetSize(m_printData.GetPaperId()); - if (sz.x != 0) - { - // sz is in 10ths of a mm, so multiply by 10. - m_paperSize.x = sz.x * 10; - m_paperSize.y = sz.y * 10; - } + // sz is in 10ths of a mm, while paper size is in mm + m_paperSize.x = sz.x / 10; + m_paperSize.y = sz.y / 10; } #endif // wxUSE_PRINTING_ARCHITECTURE