#include "wx/log.h"
// For compatibility
-#if (defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXPM__)) && wxUSE_POSTSCRIPT
+#if (defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXPM__) || defined(__WXMAC__)) && wxUSE_POSTSCRIPT
#define wxCOMPATIBILITY_WITH_PRINTSETUPDATA 1
#endif
#define pt2mm 0.352777777778
#endif // Mac
+#ifndef DMPAPER_USER
+ #define DMPAPER_USER 256
+#endif
+
// ============================================================================
// implementation
// ============================================================================
// DEVMODE is in tenths of a milimeter
devMode->dmPaperWidth = m_paperSize.x * 10;
devMode->dmPaperLength = m_paperSize.y * 10;
+ devMode->dmPaperSize = DMPAPER_USER;
devMode->dmFields |= DM_PAPERWIDTH;
devMode->dmFields |= DM_PAPERLENGTH;
}