-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Simple external_img() pptx creation works but powerpoint reports 'problem with content' #613
Comments
Can you please provide a fully reproducible example, i.e. including the PDF files? |
Sorry, should have done that the first time! Please see files attached.
Leo
From: Mark Heckmann ***@***.***>
Date: Monday, 30 September 2024 at 13:35
To: davidgohel/officer ***@***.***>
Cc: Schalkwyk, Leonard ***@***.***>, Author ***@***.***>
Subject: Re: [davidgohel/officer] Simple external_img() pptx creation works but powerpoint reports 'problem with content' (Issue #613)
CAUTION: This email originated from outside our organisation. Do not click links or open attachments unless you recognise the sender and know the content is safe. If you are not sure it is safe, please contact the IT Helpdesk.
Can you please provide a fully reproducible example, i.e. including the PDF files?
—
Reply to this email directly, view it on GitHub<#613 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFJVOHGV73TEVET7MF73BWDZZFAQVAVCNFSM6AAAAABPDDZQ6CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOBTGA3DKNRQG4>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
I cannot find an attachment in the reply you sent via email. Could you please check directly on GitHub? |
I don't think that officer can handle PDF files as image input. However, I cannot find any suffix checks that prevent this. |
Thanks Mark:
I couldn’t find anything in the documents about what kind of files are supported and was pleasantly surprised to see that pdf files sort of work. The ‘repaired’ pptx file does seem to treat the pdf images as vector graphics, they seem to zoom and zoom. When I unzip the pptx file from officer I can find the unchanged pdfs inside, and in the version repaired by Powerpoint there are versions converted to emf.
To me It's a valuable (if accidental) feature of officer to be able to embed vector graphics in powerpoint files. I think it’s clear that the officer output is fairly correct but Powerpoint raises a warning because MS engineers are wary about processing arbitrary vector graphics.
Thanks for your help.
LEo
From: Mark Heckmann ***@***.***>
Date: Monday, 30 September 2024 at 15:50
To: davidgohel/officer ***@***.***>
Cc: Schalkwyk, Leonard ***@***.***>, Author ***@***.***>
Subject: Re: [davidgohel/officer] Simple external_img() pptx creation works but powerpoint reports 'problem with content' (Issue #613)
CAUTION: This email originated from outside our organisation. Do not click links or open attachments unless you recognise the sender and know the content is safe. If you are not sure it is safe, please contact the IT Helpdesk.
I don't think that officer can handle PDF files as image input. However, I cannot find any suffix checks that prevent this.
I guess, the easiest fix would be to convert the PDFs to JPEG or PNG before adding them.
—
Reply to this email directly, view it on GitHub<#613 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFJVOHBWY3CRXMFFDFUISY3ZZFQLJAVCNFSM6AAAAABPDDZQ6CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOBTGQZTCMJXGI>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm making a pptx version of beamer slides, where I have sliced up the beamer pdf with gs.
The code below works and would of course be easy to loop over all slides. Powerpoint says "PowerPoint found a problem with content in pr.pptx.
PowerPoint can attempt to repair the presentation.
If you trust the source of this presentation, click Repair."
and then displays the slides correctly.
(Microsoft Powerpoint for Mac v 16.83)
Matrix products: default
BLAS: /opt/homebrew/Cellar/openblas/0.3.27/lib/libopenblasp-r0.3.27.dylib
LAPACK: /opt/homebrew/Cellar/r/4.4.0/lib/R/lib/libRlapack.dylib; LAPACK version 3.12.0
locale:
[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8
time zone: Europe/London
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] officer_0.6.6
loaded via a namespace (and not attached):
[1] compiler_4.4.0 R6_2.5.1 cli_3.6.3 ragg_1.3.2
[5] tools_4.4.0 uuid_1.2-1 xml2_1.3.6 zip_2.3.1
[9] textshaping_0.4.0 lifecycle_1.0.4 rlang_1.1.4 systemfonts_1.1.0
[13] openssl_2.2.0 askpass_1.2.0
The text was updated successfully, but these errors were encountered: