10-12-2018, 09:33 AM | #1 |
Junior Member
Posts: 2
Karma: 10
Join Date: Oct 2018
Device: none
|
Line Numbering possible?
Hello dear forum users,
I am a teacher and had the idea of printing some short stories (from the Projekt Gutenberg) for my students. I have used this site to extract epubs quickly and imported those into my Calibre library. Is there a way to add line numbering in Calibre itself? I have tried to search the forum, but couldn't find a thread that had answers to my question. The line numbers essential for the intended use in school. I would deeply appreciate any advice on this subject. |
10-12-2018, 10:11 AM | #2 |
Wizard
Posts: 3,305
Karma: 10259306
Join Date: May 2016
Device: kobo forma, Kobo Libra, Huawei media Tab, fire HD10, PW3 HDX8.9,
|
much depends on how you define a " line". because different device settings will change how many words appear in a "line" on the screen.
if you need to preserve the word count per line from some original source, you'd arguably be better of with non re-flowable pdf, not epub ssame issue will of course apply to " page" both line and page make not a lot of sense on an e-reader where everything can be scaled up or down by each user |
10-12-2018, 05:31 PM | #3 | ||
null operator (he/him)
Posts: 20,565
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Quote:
Quote:
Paragraph numbers would be a more sensible option than line or page numbers. The calibre viewer will display them if the Reference mode button is pressed, see attachment. I am not aware of any way to get paragraph numbers injected into the epub itself, but that doesn't mean there isn't a way. BR |
||
10-12-2018, 05:58 PM | #4 |
Not Quite Dead
Posts: 194
Karma: 654170
Join Date: Jul 2015
Device: Paperwhite 4; Galaxy Tab
|
"Line" does not seem to have a practical definition for an e-book except as a paragraph. If that is what you mean, then there are 2 fairly simple ways to produce a number before every paragraph which will also be visible printed:
1) Edit the Calibre regex-function "Auto-Number." I have tested this and it works fine and is best if you want the numbering to go from 1 to the very last paragraph. 2) The easiest is to use the auto-numbering capabilities of CSS. This will do the numbering by chapter, which is how it is usually done. The other advantage is that the number can be styled to stand out. Add to your stylesheet: Code:
body { counter-reset: para; /* Set a counter named 'para' */ } p::before { counter-increment: para; /* Increment value by 1 */ content: counter(para) " "; /* Display value with space */ font-weight: bold; } |
10-19-2018, 11:31 AM | #5 | |
Junior Member
Posts: 2
Karma: 10
Join Date: Oct 2018
Device: none
|
Quote:
This solution has indeed added numbers to the paragraphs which seem to correspond to the lines. Then I converted the epub to doc for printing and there are no numbers visible. Shouldn't there be some at this point? |
|
10-19-2018, 01:27 PM | #6 | |
Not Quite Dead
Posts: 194
Karma: 654170
Join Date: Jul 2015
Device: Paperwhite 4; Galaxy Tab
|
Quote:
If you have an ePub book that you judge to be ready for print, open the ePub in the Calibre viewer and select the "Print to PDF" tool. Then open the .pdf file created and print with whatever options your pdf viewer allows. The line numbers will be in place, just as they were in the original ePub book. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
italic at end of line causes next line to start with a space | ebookreadr | Sigil | 29 | 03-20-2017 11:25 AM |
Auto-numbering | Mondriaan | Calibre | 3 | 07-12-2015 07:20 AM |
Glo Page Numbering | dixieknits | Kobo Reader | 3 | 01-06-2013 04:43 PM |
Series Numbering | adrian1944 | Calibre | 3 | 10-17-2010 01:59 PM |