Bug 127489 - Simple ODT with image saved to PDF adds blank page - only via Java API code, normal PDF export works
Summary: Simple ODT with image saved to PDF adds blank page - only via Java API code, ...
Status: RESOLVED DUPLICATE of bug 116924
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
6.3.0.4 release
Hardware: All All
: low minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-09-11 06:35 UTC by Paul
Modified: 2020-05-03 11:10 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
Simple Document that causes problem (26.60 KB, application/vnd.oasis.opendocument.text)
2019-09-11 06:35 UTC, Paul
Details
Java code to reproduce the problem. (4.58 KB, text/plain)
2019-09-11 06:36 UTC, Paul
Details
Example of a normal / correct export to PDF (24.99 KB, application/pdf)
2019-09-11 06:37 UTC, Paul
Details
Example of a failed / incorrect export to PDF with extra blank page (25.36 KB, application/pdf)
2019-09-11 06:38 UTC, Paul
Details
Test case with only tables (14.07 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-03-13 08:34 UTC, Mike
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Paul 2019-09-11 06:35:19 UTC
Created attachment 154090 [details]
Simple Document that causes problem

The attached document is a simple ODT which has an image in a table part way down the page.  When loaded and saved to PDF (using the Java API), a blank second page is randomly added.  If the image is removed, the blank page never occurs.  The page style is set to Default (and Default for next) so a simple case.

Attached is the Java code, and examples of expected and failed PDF output.

Testing on different platforms and different versions shows:

Windows (10):
 - 6.3.0.4 - fails frequently (sometimes 20% of documents have blank page)
 - 6.2.6.1 - fails frequently (sometimes 20% of documents have blank page)
 - 6.1.5.2 - fails occasionally (about 2% of documents have blank page)

Linux
 - 6.3.1.2 - fails occasionally (about 2% of documents have blank page)
 - 6.1.5.2 - fails occasionally (about 2% of documents have blank page)

The code runs 1000 loops of three steps:
  1) load the ODT file
  2) save as PDF
  3) check the size of the PDF (indicates when the number of pages is changing

The LibreOffice user settings were deleted before running the test to confirm this happens by default.
Comment 1 Paul 2019-09-11 06:36:37 UTC
Created attachment 154091 [details]
Java code to reproduce the problem.
Comment 2 Paul 2019-09-11 06:37:37 UTC
Created attachment 154092 [details]
Example of a normal / correct export to PDF
Comment 3 Paul 2019-09-11 06:38:17 UTC
Created attachment 154093 [details]
Example of a failed / incorrect export to PDF with extra blank page
Comment 4 Paul 2019-09-11 06:40:01 UTC
possibly related to 86126 and 116924
Comment 5 Mike 2020-03-13 08:34:02 UTC
Created attachment 158665 [details]
Test case with only tables

This example occasionally has an extra page in pdf output using same Java test code. About 0.1% occurrance so far.

Version: 6.2.5.2 (x64)
Build ID: 1ec314fa52f458adc18c4f025c545a4e8b22c159
CPU threads: 8; OS: Windows 10.0; UI render: GL; VCL: win; 
Locale: en-AU (en_AU); UI-Language: en-GB
Calc: CL
Comment 6 Timur 2020-05-03 11:10:33 UTC
I don't know why this is just related and not duplicated to Bug 116924, but I'll do it. If that one is resolved, this one should be checked.

*** This bug has been marked as a duplicate of bug 116924 ***