|
@@ -473,9 +473,11 @@ extension KMMainViewController {
|
|
let page = listView.currentPage()
|
|
let page = listView.currentPage()
|
|
let copyPage : CPDFPage = page!.copy() as! CPDFPage
|
|
let copyPage : CPDFPage = page!.copy() as! CPDFPage
|
|
copyPage.setBounds(rect, for: .cropBox)
|
|
copyPage.setBounds(rect, for: .cropBox)
|
|
- let pdfDocument : CPDFDocument = CPDFDocument()
|
|
|
|
- pdfDocument.insertPageObject(copyPage, at: 0)
|
|
|
|
-
|
|
|
|
|
|
+ let image : NSImage = copyPage.thumbnail(of:(copyPage.bounds(for: .cropBox)).size)
|
|
|
|
+ let pdfDocument : PDFDocument = PDFDocument()
|
|
|
|
+ let newpage : PDFPage = PDFPage(image: image)!
|
|
|
|
+ pdfDocument.insert(newpage, at: 0)
|
|
|
|
+ KMPrintWindowController.openPrintView(document: pdfDocument)
|
|
KMPrintWindowController.openDocument(inputDocument: self.listView?.document, inputPageRange: KMPrintPageRange(type: .allPage, selectPages: []))
|
|
KMPrintWindowController.openDocument(inputDocument: self.listView?.document, inputPageRange: KMPrintPageRange(type: .allPage, selectPages: []))
|
|
}
|
|
}
|
|
|
|
|