Hello, I am using libreoffice to convert from .XLS to .PDF.
I am using the CLI command:
/usr/bin/libreoffice7.6 --headless --invisible --nodefault --view --nolockcheck --nologo --norestore --convert-to pdf:calc_pdf_Export --outdir /tmp /tmp/file.xls
If I open the file in MS Excel GUI and try to print it as a PDF, I get the correct formatting.
Whenever I try to use it through LibreOffice on my linux terminal, I get more pages because what I expected would fit into one page, does not fit (See image below).
On the left is exported using Excel, and on the right is the result of the LibreOffice conversion.
LibreOffice generated 8 pages instead of two, and this is because the content didn’t fit horizontally and vertically.
What might be going wrong here?
- Is it inherently the case that XLS files will never have the same “PDF export layout” in LibreOffice as they do in Windows?
- Are there settings or something I’m missing in LibreOffice terminal command?