A document produced using Aspose.Cells 23.2 produces a document that has invalid dimensions on Aspose PDF 23.2.
I've created the following test case, which produces a document in memory:
var workbook = new Workbook();
var worksheetIndex = workbook.getWorksheets().add();
var worksheet = workbook.getWorksheets().get(worksheetIndex);
worksheet.getCells().get("E10").setValue("test");
worksheet.getPageSetup().setOrientation(PageOrientationType.LANDSCAPE);
workbook.save("test.pdf", new PdfSaveOptions());
var doc = new Document("test.pdf");
var page = doc.getPages().get_Item(1);
System.out.println(String.format("%f x %f", page.getPageRect(true).getWidth(), page.getPageRect(true).getHeight()));
System.out.println(String.format("%f x %f", page.getPageInfo().getWidth(), page.getPageInfo().getHeight()));
System.out.println(page.getRotate());
The document produces has PageRect properly set, but the PageInfo dimensions remain on Portrait mode. Even worse, the dimensions provided on both of them area different.
Output:
792.000000 x 612.000000
595.000000 x 842.000000
0
Is there a way to normalize the dimensions on the produced PDF?