astefanutti / decktape

PDF exporter for HTML presentations
MIT License
2.17k stars 175 forks source link

Add an option to toggle rendering fragments "all in one" or "one for each" slide(s) #24

Open astefanutti opened 8 years ago

astefanutti commented 8 years ago

Ideally, that should be a global option supported for all presentation backends.

riezebosch commented 8 years ago

For reveal.js this is possible by turning fragments via the url: http://yourpresentation/**?fragments=false**

astefanutti commented 8 years ago

The fragments option has been set to false in the reveal.js plugin a768e10e25af2d91111d055422794d1163317285.

jroper commented 7 years ago

The title of this issue should be renamed now - it should be "add option to allow creating one slide per fragment". In my presentations, I often use fragments to "animate" images, with sequences of images, each being a new fragment rendered over the old, progressing through the animation. The PDF is useless if it doesn't have these.

astefanutti commented 7 years ago

@jroper thanks for the feedback. I infer you're exporting reveal.js presentations for which I assumed passing fragments=true in the URL query string would force the fragments to be rendered one per slide. Though it happens the query string parameter does not take precedence over the globally configured fragments option.

So I've just pushed 9e1ad32, that should enable you to export one slide per fragment by adding ?fragments=true to your presentation URLs, until a consistent solution across all the supported presentation frameworks is worked out. In the meantime, I'm renaming this issue.

mfhepp commented 4 years ago

This would really be a very useful improvement - I am using fragments a lot to improve the flow of argument in lectures, but it is painful for students to have PDFs one per each additional fragment. Manual removal in the post-processing would also add a lot of manual work per each release. So I would really love to see this issue fixed - adding the fragments=false parameter to the notebook URI does not work on my system.

astefanutti commented 4 years ago

@mfhepp what presentation framework do you use?

mfhepp commented 4 years ago

@astefanutti I am using RISE 5.5.1 with Jupyter Notebooks 5.7.4 from the Anaconda distribution.

bdamele commented 4 years ago

It would be great to have it supported for remarkjs too by checking the value of countIncrementalSlide in the remarkjs' presentation HTML passed to decktape

// Disable counting of incremental slides in the slide counting
countIncrementalSlides: false,
cgadal commented 4 months ago

@jroper thanks for the feedback. I infer you're exporting reveal.js presentations for which I assumed passing fragments=true in the URL query string would force the fragments to be rendered one per slide. Though it happens the query string parameter does not take precedence over the globally configured fragments option.

So I've just pushed 9e1ad32, that should enable you to export one slide per fragment by adding ?fragments=true to your presentation URLs, until a consistent solution across all the supported presentation frameworks is worked out. In the meantime, I'm renaming this issue.

Could you add this info somewhere in the Readme? It took me so long to find it and figure out how to keep the fragments using decktape!

astefanutti commented 2 months ago

Could you add this info somewhere in the Readme? It took me so long to find it and figure out how to keep the fragments using decktape!

Options have been explicitly added to the reveal plugin so they now appear when printing the CLI usage:

$ decktape reveal -h

Usage: decktape reveal [options] <url> <filename>

url          URL of the slides deck
filename     Filename of the output PDF file

Options:

   --fragments                     Enable or disable fragments  [false]
   --progress                      Enable or disable progress bar  [false]