careteditor / issues

Caret issues
https://caret.io
326 stars 12 forks source link

Control PDF margins on export #901

Closed plagasul closed 4 years ago

plagasul commented 4 years ago

Great app, very excited about the new one, hopefully it will come out soon.

Meanwhile, is there any way to control the margins of the exported PDF's ? this is most prolly not done via CSS.

What does caret use to export to pdf anyway?

Thank you

plagasul commented 4 years ago

I should add I know this can be done via pandoc by, for example, setting a yaml header, but I believe Caret does not use pandoc under the hood for pdf conversion does it? If it does, would it respect a yaml header? I guess it would depend on the used template.

On my tests, setting a yaml header straight on the markdown document with something like

---
geometry: margin=10cm
---

... does not do anything

astoilkov commented 4 years ago

We don't use pandoc. We use https://www.electronjs.org/docs/api/web-contents#contentsprinttopdfoptions. In the current version of Caret it isn't possible to modify the margins of the generated PDF.