jgraph / drawio-desktop

Official electron build of draw.io

Home Page:https://www.diagrams.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

--crop parameter breaks export to pdf when there are clear pages

Korstek opened this issue · comments

Preflight Checklist

  • I agree to follow the Code of Conduct that this project adheres to.
  • I have searched the issue tracker for a feature request that matches the one I want to file, without success.

You must agree to search and the code of conduct. You must fill in this entire template. If you delete part/all or miss parts out your issue will be closed.

Describe the bug
In the command line --crop parameter breaks export to pdf when one of the pages is empty - this behaviour is understandable, but maybe add some kind of warning? Because I had to debug it myself by deleting page by page until I found this empty one was causing an issue.

To Reproduce
Steps to reproduce the behaviour:

  1. Create a new file
  2. Save it as test.drawio (without any shapes or objects inserted or with few filled pages, but also with at least one empty)
  3. Open the terminal in the file location
  4. Run draw.io --crop --export --format pdf --output all.pdf test.drawio
  5. Program returns "Error: Export failed: test.drawio"

Expected behavior
The best way would be to skip empty pages or export them in standard size (for example A4).
A simple warning would also be plenty enough.

Screenshots

draw.io version (In the Help->About menu of the draw.io editor):

  • draw.io version 24.0.4

Desktop (please complete the following information):

  • OS: Windows 10

Additional context