-
Notifications
You must be signed in to change notification settings - Fork 176
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
weird spacing with reveal #151
Comments
I've already noticed some layout issues with images. Would you mind:
|
Should --screenshots make a screenshots directory if it doesn't exist?
|
Thanks. Indeed output directory has to exist. We need to produce a minimal test case, ideally removing Decktape from the equation, and submit an issue to the Puppeteer project. |
Doesn't look like it has anything to do with images. (I don't know anything about decktape or Puppateer, just download decktape today in hope of using it.) |
That's an improvement I want to do, though not high priority.
It's more related to the page layout. I faced some similar issues with absolute positioning. We need to find a minimal HTML page that reproduces the issue, like puppeteer/puppeteer#915. But you can try reporting the issue directly to Puppeteer and we'll progress /refine from there. |
I don't know javascript and don't use this software, so I'm not the best reporter for puppeteer. But hopefully my example gives you something to start with. |
No worries, I'll try to isolate the issue ASAP. |
I'm facing exactly the same issue. It seems to have something to do with using On one page I have code that looks like the following and the space appears between the
|
I observed the same issue. On some of my |
Same issue here. I can see it even when comparing the pdf rendering for the second page of the standard reveal.js demo. The arrow images at the "vertical slides" section are also very obviously wrongly positioned. mac OS X used here. |
Is there a workaround? Because besides decktape there is no alternative. reveal.js' |
I managed to workaround the issue by combining the use of latest decktape with decktape 1.0.0. Setup:
Render slides that look good with old decktape:
Render slides that look good with new decktape:
Combine everything:
Voilà! I also notice that I have complete sets of slides that still render properly with |
A workaround seems to be increasing (very much) the size. For example using |
Thanks, @hvwaldow, that was an easy fix for me! |
The workaround on increasing the size does not work for me, but using version 1.0.0 (which uses phantomjs instead of headless chrome and puppeteer) works fine: https://github.com/astefanutti/decktape/releases/tag/v1.0.0, so I would recommend just installing version 1.0 of decktape for anyone who needs to render reveal.js decks. |
Hello, I also have the same issue with reveal.js presentation. Using v1.0.0 to bypass the problem. Any news regarding fix in the latest version? |
@kzorba a minimal use case has to be built so that an issue can be reported in Chromium / Skia (the component used by the PDF engine). In the meantime, I'd be inclined to set the default size for Reveal.js to a larger value, as it seems to work-around the issue for some people. |
As of today it seems @hvwaldow's workaround works too. @astefanutti Can you help with creating a minimal reproducible example? I can create a reproducible example, but minimal as in puppeteer/puppeteer#915 is out of my reach with my limited JS/HTML/CSS knowledge. 😅 😇 |
I'm interested in this being fixed as well. For now the over-sizing workaround seems to be working for me. |
@angelocroatti it looks like that's the root of our issue... |
I had the same issue (with all the details and sample included), described in an reveal-md issue, to whom it may concern and help. |
As a variation of the aforementioned workaround via increasing the size option, I have found that not providing a size option at all can also be worth a trial. I do however set a screen size in my reveal.js configuration, though. |
In the meantime, is there a fix or other solutions? No workaround works for me. |
One option is to roll back to version 1.0, which is the last time decktape worked reliably for reveal.js slides: https://github.com/astefanutti/decktape/releases/tag/v1.0.0 This isn't @astefanutti's fault. It's a bug with Chromium that needs to be fixed by the Chromium developers, and there's nothing that decktape can do about it. Decktape needed to move to Chromium/Puppeteer because since 2018, PhantomJS is no longer maintained (ariya/phantomjs#15344), so the old version of decktape that relied of PhantomJS won't be stable. Basically, it's a bad situation, but there's not much any of us can do. |
Have you tried opening your reveal.js presentation in Chrome, adding |
Thanks for the feedback. I didn't mean to blame anyone. I am very happy that I can create a PDF at all with decktape. |
This actually saved my day. I had a very mixed presentation with backgrounds, footer and stuff, all I had was ?print-pdf and whatever combination I tried was useless (fixed one thing, two were broken), then I tried this, but the things that were broken magically went fixed, but other again went broken (like images pushed too low or too much space between some elements). By using Note: since most presentations are 16:9, to render them the right ratio I safely use I wish I had found this before! |
I've been able to mitigate spacing issues in the pdf output by switching from Changing:
To something like:
|
This should finally be fixed with the upgrade to Chromium 111, which contains support for printing via the new layout engine, a.k.a. LayoutNG, and some other related bug fixes: https://chromestatus.com/feature/5108105013100544 |
I've had a ton of spacing issues with |
The following command results in a PDF with too much spacing below the title in some slides.
decktape reveal -size 960x700 http://reagle.org/joseph/talks/2018/05-ica-lifehack.html test.pdf
For example, look at slide #5, "Genres". It's a 3 item numbered list, but item 3 is pushed off the bottom because of the spacing below "Genres".
test.pdf
The text was updated successfully, but these errors were encountered: