fix problem with mm printer measurements

This commit is contained in:
Matthew Flatt 2011-01-14 15:51:05 -07:00
parent b10ad75d11
commit 06e5d7d6c8

View File

@ -142,20 +142,18 @@
(begin
(show-print-setup #f #t)
(send (current-ps-setup) get-native))))
(define-values (page-width page-height)
(let ([scale (if (zero? (bitwise-and (PAGESETUPDLG-Flags page-setup)
PSD_INTHOUSANDTHSOFINCHES))
;; 100ths of mm
(/ SCREEN-DPI (/ 10.0 2.54))
(/ SCREEN-DPI (* 10.0 2.54))
;; 1000ths of in
(/ SCREEN-DPI 1000.0))])
(values
(* scale (POINT-x (PAGESETUPDLG-ptPaperSize page-setup)))
(* scale (POINT-y (PAGESETUPDLG-ptPaperSize page-setup))))))
(define/override (get-size) (values page-width page-height))
(define start-doc-message #f)