Skip to content
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

pagebreak breaks PowerPoint #11893

Open
arthurgailes opened this issue Jan 17, 2025 · 5 comments · May be fixed by #11896
Open

pagebreak breaks PowerPoint #11893

arthurgailes opened this issue Jan 17, 2025 · 5 comments · May be fixed by #11896
Assignees
Labels
enhancement New feature or request pptx issue with pptx format shortcodes issues related to shortcodes
Milestone

Comments

@arthurgailes
Copy link

Bug description

---
format: pptx
---

# A page
Some stuff


{{< pagebreak >}}

# Another page

some more stuff

This renders a PowerPoint that needs to be repaired, omitting the pagebreak does not. Hurts when rendering across formats, eg pdf and powerpoint.

Steps to reproduce

No response

Expected behavior

No response

Actual behavior

No response

Your environment

No response

Quarto check output


format: pptx

A page

Some stuff

{{< pagebreak >}}

Another page

some more stuff

@arthurgailes arthurgailes added the bug Something isn't working label Jan 17, 2025
@mcanouil
Copy link
Collaborator

mcanouil commented Jan 17, 2025

I am not sure the page break shortcode has the right OpenXML code for PowerPoint.

Word and PowerPoint don't use the same OpenXML code to do the same thing for some reason.

Could you also fill the issue template as requested and properly format your post as showed when filling the template?

See https://quarto.org/bug-reports.html#formatting-make-githubs-markdown-work-for-us.

@mcanouil mcanouil added pptx issue with pptx format shortcodes issues related to shortcodes labels Jan 17, 2025
@mcanouil
Copy link
Collaborator

mcanouil commented Jan 18, 2025

Why do you want to use this shortcode in PowerPoint instead of using what's described in the documentation?

https://quarto.org/docs/presentations/powerpoint.html

For instance, the headers level does not imply the same thing in presentation formats.

Project profile would be the way here as you might have some layout to tweak in PowerPoint while not needed in PDF.

Note that the shortcode documentation ever stated PowerPoint was supported, so this is not a bug, but an enhancement is possible.

https://quarto.org/docs/authoring/markdown-basics.html#page-breaks

@mcanouil mcanouil added enhancement New feature or request and removed bug Something isn't working labels Jan 18, 2025
@mcanouil mcanouil self-assigned this Jan 18, 2025
mcanouil added a commit to mcanouil/quarto-cli that referenced this issue Jan 18, 2025
@mcanouil
Copy link
Collaborator

mcanouil commented Jan 18, 2025

The issue is caused by the default value used by the shortcode which is a form feed character \f which appears to not be written properly (or not understood at all which makes sense) in a PowerPoint document.

@cderv cderv added this to the v1.7 milestone Jan 20, 2025
@cderv
Copy link
Collaborator

cderv commented Jan 20, 2025

Thanks @mcanouil ! Indeed \f does not seem appropriate for pptx output. I guess pagebreak shortcode was not expected to be used in pptx context.

This could be reported and fix upstream too :

And I'll do the same in rmarkdown:

@arthurgailes
Copy link
Author

arthurgailes commented Jan 21, 2025

Why do you want to use this shortcode in PowerPoint instead of using what's described in the documentation?

https://quarto.org/docs/presentations/powerpoint.html

For instance, the headers level does not imply the same thing in presentation formats.

I would like to output the same document in both PDF and Powerpoint, iteratively. In Psuedocode:

---
format: 
  pptx: true
  typst: true
---

## A title that works in both

Some text that works in both

{{< pagebreak >}}

## The title in both, but page divider only in ppt

If only I could use pagebreak, I'd be happy in `r params$state`.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request pptx issue with pptx format shortcodes issues related to shortcodes
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants