Skip to content

More than one page is displayed in the presentation mode #10907

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

Closed
radarfox opened this issue Jun 15, 2019 · 1 comment · Fixed by #14112
Closed

More than one page is displayed in the presentation mode #10907

radarfox opened this issue Jun 15, 2019 · 1 comment · Fixed by #14112
Labels

Comments

@radarfox
Copy link

Attach (recommended) or Link to PDF file here:

example-horizontal.pdf

Configuration:

  • Web browser and its version: Firefox 67, Chrome 75
  • Operating system and its version: Windows 10
  • PDF.js version: 2.1.266
  • Is a browser extension: no

Steps to reproduce the problem:

  1. Open a PDF with horizontal pages on the portrait orientated display.
  2. You can see one, two or even more pages at the same time, depends on the dimensions of the pages and the display.
  3. The problem is caused by the page separation which is done just by the simple margin-bottom: 100%; assigned to the .page elements. But the 100% is computed from the PDF page width, not from the height of the display. So when the sum of the PDF page width and height is greater than the height of the display, this error occurs.

What is the expected behavior? (add screenshot)

To display only one PDF page in the presentation mode.

What went wrong? (add screenshot)

Note the next page header displayed on the bottom of the following screenshot.

pdfjs-margin-bug

@radarfox
Copy link
Author

This problem might be related to #10906. If the vertical centering is done correctly, this problem would disappear.

@radarfox radarfox changed the title More then one page displayed in the presentation mode More than one page is displayed in the presentation mode Jun 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants