Skip to content

Commit

Permalink
Merge commit 'd0fddc1135d0f4acbf439b0a703c3f0e7db05f84' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjgraph committed Nov 26, 2024
2 parents d1bb63c + d0fddc1 commit 9c10ae1
Show file tree
Hide file tree
Showing 4 changed files with 398 additions and 394 deletions.
2 changes: 1 addition & 1 deletion drawio
Submodule drawio updated 657 files
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"@electron/fuses": "^1.8.0",
"@electron/notarize": "^2.4.0",
"dotenv": "^16.4.5",
"electron": "32.0.1",
"electron": "^32.0.1",
"electron-builder": "^24.9.1",
"sumchecker": "^3.0.1"
}
Expand Down
11 changes: 9 additions & 2 deletions src/main/electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -1759,8 +1759,15 @@ function exportDiagram(event, args, directFinalize)
{
pdfOptions = {
scaleFactor: args.pageScale,
preferCSSPageSize: true,
printBackground: true
printBackground: true,
pageSize : {
width: args.pageWidth * MICRON_TO_PIXEL,
//This height adjustment fixes the output. TODO Test more cases
height: (args.pageHeight * 1.025) * MICRON_TO_PIXEL
},
margins: {
marginType: 'none' // no margin
}
};

contents.print(pdfOptions, (success, errorType) =>
Expand Down
Loading

0 comments on commit 9c10ae1

Please sign in to comment.