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

page numbers are not correct if using custom cover page #458

Closed
igagis opened this issue May 26, 2016 · 7 comments
Closed

page numbers are not correct if using custom cover page #458

igagis opened this issue May 26, 2016 · 7 comments
Assignees
Labels

Comments

@igagis
Copy link

igagis commented May 26, 2016

The document uses :front-cover-image: instead of a title page and :notitle:, so the heading looks like:

= bla bla bla
//Name Surname <author@email.com>
:encoding: utf-8
:lang: en
:toc: macro
:pdf-style: pdf-theme.yml
:pdf-stylesdir: theme
:pdf-fontsdir: {pdf-stylesdir}
:toclevels: 3
:sectnums:
:doctype: article
:tabsize: 8
:front-cover-image: image:title_page.pdf[]
:notitle:
:stem:

then the generated PDF has wrong page numbers in PDF index. The table of contents still has correct page number. See attached screenshot.
incorrect page numbers

Introduction should be on page 1 but in PDF index on the left hand side it says page 2. And so on with other pages.

@mojavelinux mojavelinux added this to the v1.5.0.alpha.12 milestone May 26, 2016
@mojavelinux
Copy link
Member

I want to add that it happens only for the article doctype. If you use the book doctype, then it seems to be correct.

However, I noticed when you use the book doctype, the integer page numbers are correct, but the roman numeral pages are not correct.

(side rant: page calculations have proven extremely difficult to get right)

@mojavelinux mojavelinux self-assigned this May 26, 2016
@igagis
Copy link
Author

igagis commented May 26, 2016

ok, I'll try to fall back to book doctype for now

@igagis
Copy link
Author

igagis commented May 27, 2016

actually for book it is same, page numbers are not correct

@mojavelinux
Copy link
Member

mojavelinux commented Sep 6, 2016

This is going to be resolved as part of #383. The problem was that I did not have entries in the page labels table for all front matter pages, which caused some readers to assign incorrect numbers to the content pages.

mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 6, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 6, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 9, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 9, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 9, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 9, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Sep 9, 2016
- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
@igagis
Copy link
Author

igagis commented Sep 9, 2016

Great!

@mojavelinux
Copy link
Member

This change has been merged if you want to try it before I release alpha 13 over the weekend.

@igagis
Copy link
Author

igagis commented Sep 9, 2016

Thanks! I'll wait for alpha release.

fapdash pushed a commit to vogellacompany/asciidoctor-pdf that referenced this issue Dec 13, 2016
…idoctor#415)

- add support for recto/verso margins when attribute media=prepress
- introduce page_margin_inner and page_margin_outer keys to theme
- calculate page margin for recto and verso pages automatically
- add recto/verso support to running content
- start title page, toc, and content on recto page when media=prepress and doctype=book
- add set_page_margin helper
- add page_margin helper
- add page_side helper
- add recto_page? and verso_page? helpers
- resolve asciidoctor#458 add page labels for all front matter pages to fix page numbering in outline
- simplify toc page nums calculation
- document "prepress" publishing mode in theming guide
- use term "periphery" instead of "position" to refer to running content region
- fix some formatting and wording in theming guide
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants