Bug 155439

Summary: PDF images inserted in Writer document are lost in exported PDF
Product: LibreOffice Reporter: Emil Prpic <smayoo>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: minor CC: buzea.bogdan, miguelangelrv, notinteresting, struckkai
Priority: medium    
Version: 7.4.7.2 release   
Hardware: x86 (IA32)   
OS: macOS (All)   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=155440
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 103378    
Attachments: ODT document manifesting the bug
PDF generated by PDF export function of LibreOffice
PDF generated my macOS built-in functionality through print dialog
An example of single-page vector image in PDF format
Sample pdf file generated with LibreOffice.
PDF exported from Attachment 187442 using LO 6.4.4.2

Description Emil Prpic 2023-05-22 23:14:14 UTC
Description:
Vector images in single-page PDF format inserted into an ODT document (anchor to paragraph, no wrap, center aligned, cropped) are shown as blank space (of correct dimensions) in PDF generated by Export PDF function. In PDF generated by macOS system functionality (through print dialog, click on "PDF" in lower left corner), everything is fine.

Steps to Reproduce:
1.make some text in Writer
2.click insert / image 
3.choose a single page PDF generated by a vector drawing software (AutoCAD in my case, didn't try with others)
4.click PDF export icon on toolbar
5.open the created PDF and look for the image

Actual Results:
No image, just blank space

Expected Results:
There should be image that you inserted


Reproducible: Always


User Profile Reset: No

Additional Info:
https://git.libreoffice.org/core/+log/9f56dff12ba03b9acd7730a5a481eea045e468f3
Comment 1 Emil Prpic 2023-05-22 23:15:08 UTC
Created attachment 187442 [details]
ODT document manifesting the bug
Comment 2 Emil Prpic 2023-05-22 23:16:09 UTC
Created attachment 187443 [details]
PDF generated by PDF export function of LibreOffice

(no images, just blank space where they should be)
Comment 3 Emil Prpic 2023-05-22 23:17:02 UTC
Created attachment 187444 [details]
PDF generated my macOS built-in functionality through print dialog

images appear fine, as they should
Comment 4 Emil Prpic 2023-05-22 23:19:33 UTC
Created attachment 187445 [details]
An example of single-page vector image in PDF format

generated from AutoCAD by PDFwriter software
https://github.com/rodyager/RWTS-PDFwriter
Comment 5 Emil Prpic 2023-05-22 23:22:11 UTC
macOS data:
  System Version:	macOS 12.6.5 (21G531)
  Kernel Version:	Darwin 21.6.0
  Boot Mode:	Normal
  Secure Virtual Memory:	Enabled
  System Integrity Protection:	Enabled
  Time since boot:	26 days 15:09

Hardware:
 Model Name:	MacBook Pro
  Model Identifier:	MacBookPro16,1
  Processor Name:	6-Core Intel Core i7
  Processor Speed:	2,6 GHz
  Number of Processors:	1
  Total Number of Cores:	6
  L2 Cache (per Core):	256 KB
  L3 Cache:	12 MB
  Hyper-Threading Technology:	Enabled
  Memory:	16 GB
  System Firmware Version:	1968.100.17.0.0 (iBridge: 20.16.4252.0.0,0)
  OS Loader Version:	540.120.3~22
  Activation Lock Status:	Disabled
Comment 6 m_a_riosv 2023-05-22 23:36:41 UTC
Created attachment 187447 [details]
Sample pdf file generated with LibreOffice.

See the attached sample pdf generated with
Version: 7.5.3.2 (X86_64) / LibreOffice Community
Build ID: 9f56dff12ba03b9acd7730a5a481eea045e468f3
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: en-US Calc: CL threaded
There is on the second page.
Comment 7 Andrew Watson 2023-05-23 06:17:01 UTC
Exporting attachment 187442 [details] to PDF manifests the reported problem in:

Version: 7.4.7.2 / LibreOffice Community
Build ID: 723314e595e8007d3cf785c16538505a1c878ca5
CPU threads: 4; OS: Mac OS X 10.14.6; UI render: default; VCL: osx
Locale: en-GB (en_GB.UTF-8); UI: en-GB
Calc: threaded


When opening attachment 187442 [details] under:

Version: 6.4.4.2
Build ID: 3d775be2011f3886db32dfd395a6a6d1ca2630ff
CPU threads: 4; OS: Mac OS X 10.14.6; UI render: default; VCL: osx; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-GB
Calc: threaded

 ... the PDF images embedded in the document appear distorted in LO, and are present but very badly distorted in the exported PDF.

Set Status to NEW, earliest affected version to 7.4.7.2 (since thethere is a related bug in 6.4.4.2, but it's not identical).
Comment 8 Andrew Watson 2023-05-23 06:21:41 UTC
Created attachment 187451 [details]
PDF exported from Attachment 187442 [details] using LO 6.4.4.2

PDF exported from Attachment 187442 [details] using LO 6.4.4.2 under MacOS 10.14.6
Comment 9 Kai Struck 2023-05-25 21:40:03 UTC
Here are some more disappearing pdfs 
https://bugs.documentfoundation.org/show_bug.cgi?id=116254#c18