Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 09-14-2021, 12:01 PM   #1
rjwse@aol.com
Addict
rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.
 
rjwse@aol.com's Avatar
 
Posts: 202
Karma: 2114178
Join Date: Dec 2013
Location: LaVernia, Texas
Device: kindle epub readers on android
printer offset in PDF conversion (revisited)

When converting EPUB to PDF using caliber while specifying (1) a one-inch printer margin and (1) half-inch printer offset, it is necessary to add one-half-inch to the width. If you want 6 x 9 you must specify 6.5 x 9. Otherwise the output will subtract the printer offset amount from the width. To state it again: if you put in 6 x 9 and if you put in half-inch offset, the output will end up one-inch inner, half-inch outer, but overall width is 5.5 x 9.

However, Okular reports correctly and Document Viewer does not. The example shown has 1 inch inner and half-inch outer and input is 6.5 x 9

I cannot find calibre documentation saying to add the offset to the desired width. Commercial printers prefer having the offset for inner margins so that the reader does not overly flatten the book in order to read the inner margin.

The example used is in public domain without any unusual stylesheet CSS to confuse the converter.

Best Regards, Pop
Attached Thumbnails
Click image for larger version

Name:	2021-09-14_09-05.png
Views:	47
Size:	416.8 KB
ID:	189241   Click image for larger version

Name:	2021-09-14_09-15.png
Views:	46
Size:	350.4 KB
ID:	189242  
rjwse@aol.com is offline   Reply With Quote
Old 09-14-2021, 12:47 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,020
Karma: 17765146
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
That looks like a bug in document viewer, given okular is reporting it correctly. Use the pdfinfo -box file.pdf tool to get more detailed info. Most likely document viewer is reporting one of the other boxes like the cropbox.
kovidgoyal is online now   Reply With Quote
Old 09-14-2021, 01:56 PM   #3
rjwse@aol.com
Addict
rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.rjwse@aol.com ought to be getting tired of karma fortunes by now.
 
rjwse@aol.com's Avatar
 
Posts: 202
Karma: 2114178
Join Date: Dec 2013
Location: LaVernia, Texas
Device: kindle epub readers on android
Thank you for that. May I suggest a sentence in calibre's user docs regarding offset explaining the usage, that if you want offset, then add that amount to width. It shifts left and right, but also subtracts width by that amount. That was not clear to me. I wrestled with it, further confused by incorrect Document Viewer width reporting. It works great, though, now that I understand.
Best Regard, Pop
rjwse@aol.com is offline   Reply With Quote
Old 09-14-2021, 11:56 PM   #4
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,020
Karma: 17765146
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
PDF page sizing in complex, there is nothing that is an actual page size in pdf. Every page can define its own size via several "boxes", see for example:
https://www.prepressure.com/pdf/basics/page-boxes

To understand what --pdf-odd-even-offset does, run:

ebook-convert demo.epub .pdf --paper-size=a4 --pdf-odd-even-offset=36

pdfinfo -f 2 -l 4 -box demo.pdf (starting from 2 as the first page is a cover)

This will show you the boxes for the first three pages. You will see that the
mediabox, which is the largest box is the same for all three pages and is A4 size as expected. The rest fo the boxes are adjusted to give you the offset effect.
kovidgoyal is online now   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ebook-convert changes width of pdf pdf-odd-even-offset and pdf-add-toc used both Lafisrap Conversion 4 09-04-2020 07:43 AM
calibre's new "printer's offset" for PDF rjwse@aol.com Calibre 0 12-05-2019 02:00 PM
print pdf with "inside" margin offset rjwse@aol.com Conversion 3 03-09-2017 09:17 AM
PDF printer driver mr ploppy PDF 10 07-21-2011 02:06 PM
try the Hanlin Conversion Software and Printer CommanderROR HanLin eBook 9 08-06-2008 07:42 AM


All times are GMT -4. The time now is 10:42 PM.


MobileRead.com is a privately owned, operated and funded community.