finding papersizes allows for 1 mm tolerance
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@20649 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -229,7 +229,8 @@ wxPrintPaperType *wxPrintPaperDatabase::FindPaperType(const wxSize& sz)
|
|||||||
while (node)
|
while (node)
|
||||||
{
|
{
|
||||||
wxPrintPaperType* paperType = (wxPrintPaperType*) node->GetData();
|
wxPrintPaperType* paperType = (wxPrintPaperType*) node->GetData();
|
||||||
if (paperType->GetSize() == sz)
|
wxSize paperSize = paperType->GetSize() ;
|
||||||
|
if ( abs( paperSize.x - sz.x ) < 10 && abs( paperSize.y - sz.y ) < 10 )
|
||||||
return paperType;
|
return paperType;
|
||||||
node = node->GetNext();
|
node = node->GetNext();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user