salvadordf / CEF4Delphi

CEF4Delphi is an open source project to embed Chromium-based browsers in applications made with Delphi or Lazarus/FPC for Windows, Linux and MacOS.
https://www.briskbard.com/forum/
Other
1.2k stars 365 forks source link

PrintToPDF (portrait and landscape) #455

Closed xelnaga64 closed 1 year ago

xelnaga64 commented 1 year ago

I use Chromium1.PrintToPDF(filename) to save the page as PDF file. Is it possible to choose portrait or landscape modes?

salvadordf commented 1 year ago

Yes. Add this line before the PrintToPDF call : Chromium1.PDFPrintOptions.Landscape := True;

Please, use our forums for more questions : https://www.briskbard.com/forum/