11-18-2014, 11:19 AM | #1 |
Random Member
Posts: 3
Karma: 10
Join Date: Nov 2014
Location: London
Device: Nook
|
html to pdf, TOC Page# trouble from CSS...
We are using //h:h1 etc for level 1 TOC.
When we have a style that includes a negative left or right margin on the h1, e.g. margin-left: -1em; then the page numbering on the TOC goes wrong. The obvious workaround is to not use negative values for margin-left and margin-right, especially with TOC-level elements. I have included a zip file that demonstrates the behaviour. Line 270 of the style.css file switches the behaviour on and off. We would love to have the ability to resolve this, but we know no python - we are merely humble users (and fans) of Calibre. |
11-18-2014, 11:30 AM | #2 |
creator of calibre
Posts: 43,850
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Your zip file is missing style.css
|
11-18-2014, 12:33 PM | #3 |
Random Member
Posts: 3
Karma: 10
Join Date: Nov 2014
Location: London
Device: Nook
|
missing style..
so sorry!!
|
11-18-2014, 10:19 PM | #4 |
creator of calibre
Posts: 43,850
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
I tried running convert.sh on my system with calibre 2.10 and I saw nothing wrong in the output PDF file, see attached.
|
11-19-2014, 07:08 AM | #5 |
Random Member
Posts: 3
Karma: 10
Join Date: Nov 2014
Location: London
Device: Nook
|
That is interesting. We are using calibre 2.10 also - but on mac os x / Yosemite.
Note in the pdf (sent in the first zip bundle) the page numbers for The Project A, The Project B, and Post launch services are 8,2,3 respectively rather than 1,2,3. Also, the pdf you attach looks very different indeed - I'm wondering if we are doing something wrong, or is it that different os will produce different results? BTW, thanks for your near instant support. |
11-19-2014, 07:29 AM | #6 |
creator of calibre
Posts: 43,850
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
The biggest difference in PDF output comes from fonts. Make sure your style file specifies proper font-families that are available on your system.
|
Tags |
bug, css, pdf-output, toc pages |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
calibre EPUB->PDF: page numbers in printed TOC? | dancal | Conversion | 13 | 06-13-2013 08:32 PM |
HTML to PDF, printing page numbers | jbuckh | Calibre | 3 | 12-12-2012 02:33 PM |
Removing TOC page numbers in MobiPocket Creator HTML Editor | pstjmack | Kindle Formats | 0 | 10-29-2012 09:19 AM |
Converting to PDF help? Bad page breaks and no TOC produced. | Jokerfwb | Conversion | 6 | 07-24-2012 10:36 PM |
PDF to HTML page break questions | michaelbr | 3 | 01-27-2011 08:49 PM |