10-20-2023, 05:04 AM | #1 |
Member
Posts: 10
Karma: 10
Join Date: Dec 2013
Device: kindle3
|
caliber does not convert docx to epub
caliber does not convert docx to epub:
Spoiler:
Last edited by theducks; 10-20-2023 at 12:02 PM. Reason: spoilered log |
10-20-2023, 06:40 AM | #2 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
what version of calibre is this?
|
Advert | |
|
10-20-2023, 09:38 AM | #3 |
the rook, bossing Never.
Posts: 11,651
Karma: 87590587
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
Don't enable
heuristics Flatten epub |
10-21-2023, 01:45 AM | #4 |
want to learn what I want
Posts: 1,046
Karma: 6422750
Join Date: Sep 2020
Device: Calibre E-book viewer
|
hmm, just curious, what's meant by flatten epub?
Off-topic: Today I found a kludgy way to correct the structure detection of some series of biweekly issued .docx documents I will need to consult often, which are quite non-standardly outlined this way, with numerous small topics: Topic 1 Topic 2 Topic 3 ... Each "Topic" is underlined as they're hyperlinks to online resources, but unfortunately there aren't any headings in the docx structure! I wanted to insert page breaks before each one and have an EPUB with a TOC. The problem was that I couldn't figure the Xpath expression to make Calibre detect those .docx "Chapters". Eventually I decided to convert the .docx to HTMLZ, extract the 'index.html' inside that format and see what tag the 'Topic' links had, only to find they're plain paragraphs <p>. Fortunately, I found that Calibre is adding this class in one of the series of docs' paragraphs: calibre_pb_1. For the other one, it uses block_2. So all i have to do is to click the Xpath wizard and fill in the fields accordingly, then convert HTMLZ to EPUB. Now I'd guess there are other ways to accomplish this; for instance, instead of converting to HTMLZ, I could just edit the EPUB converted using the default Xpath expression, then look for the needed classes in the split index htm files. HTMLZ gave me one single index file in this case... Last edited by Comfy.n; 10-21-2023 at 06:58 AM. |
10-21-2023, 06:58 AM | #5 |
the rook, bossing Never.
Posts: 11,651
Karma: 87590587
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
I always convert docx to epub2 first, then to whatever else. Never had a problem, not even with ToC, unless the docx was broken.
Heuristics is extra stuff to try and convert broken source. Better turned off and fix source. Kovid has a few times told people to turn it off. I don't know what flatten epub does, but as all conversions of unbroken html, txt, docx, mobi,epubx and azw3 work without it for me, I suggested turning it off. Similarly unless you have crazy images, "tablet" profile is best even for 4.3″ screen epub or 6″ ancient mobi Kindles (167dpi?). |
Advert | |
|
10-21-2023, 07:05 AM | #6 | |
the rook, bossing Never.
Posts: 11,651
Karma: 87590587
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
Quote:
Then at start Insert Auto inline Contents/Index with settings changed (delete tabs & page numbers, set suitable paragraph & heading styles). This is all easier in any version of LO Writer since at least 5.x (now on 7.x) than Word 2007. Note in LO Writer only edit/save odt and do an extra save in docx for Calibre as the odt conversion isn't as good. Never use predefined Headings in LO, make your own or you might get list formatting! Since I got more clued on LO headings in custom paragraph styles and either insert contents, or manually add a bookmark at each start of new page/heading style and then a manual list of contents page with links to bookmarks (Copy & past auto contents to text editor and copy/paste back as KDP prefers manually done contents/index even on epub upload. Calibre doesn't care. More flexible). So now I never edit xpath unless it's some mad mobi / azw3 / epub being converted, but even then better to edit the azw3/epub (not an option for mobi, but convert to epub, edit, convert epub to epub and page breaks appear!) Last edited by Quoth; 10-21-2023 at 07:11 AM. |
|
10-21-2023, 07:40 AM | #7 |
want to learn what I want
Posts: 1,046
Karma: 6422750
Join Date: Sep 2020
Device: Calibre E-book viewer
|
Just found the Flatten epub option under EPUB output settings in the conversion dialog. According to the tooltips:
This option is needed only if you intend to use the EPUB with FBReaderJ. It will flatten the file system inside the EPUB, putting all files into the top level. As for LO Writer, I know from many posts here in MR it can be very useful for fixing conversion issues, but in this case I needed steps that could be replicated easily on a batch of files - so the Xpath Wizard method seems to be OK, as long as the classes are the same in each docx... |
10-21-2023, 08:55 AM | #8 |
the rook, bossing Never.
Posts: 11,651
Karma: 87590587
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
I'll avoid FBreaderJ then.
|
10-22-2023, 10:09 AM | #9 |
Member
Posts: 10
Karma: 10
Join Date: Dec 2013
Device: kindle3
|
Last edited by theducks; 10-22-2023 at 11:47 AM. Reason: spoilered log |
10-22-2023, 10:15 AM | #10 |
Resident Curmudgeon
Posts: 74,618
Karma: 130140792
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
10-22-2023, 10:16 AM | #11 |
Resident Curmudgeon
Posts: 74,618
Karma: 130140792
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
10-22-2023, 11:48 AM | #12 |
Well trained by Cats
Posts: 29,973
Karma: 56143930
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
|
10-22-2023, 01:07 PM | #13 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
is this with a particular docx or all of them?
|
10-22-2023, 01:54 PM | #14 |
Member
Posts: 10
Karma: 10
Join Date: Dec 2013
Device: kindle3
|
|
10-22-2023, 04:46 PM | #15 |
null operator (he/him)
Posts: 20,677
Karma: 26966376
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Convert form Zip including Docx files to EPUB | The_book | Conversion | 1 | 03-22-2022 12:45 PM |
Can't convert DOCX to anything | hal@scogginsweb | Conversion | 3 | 09-02-2019 05:39 PM |
DOCX Identation - Ebook-Convert | tafr | Conversion | 8 | 08-01-2018 05:33 AM |
Convert EPUB to DOCX [Change Default Margins] | Lassox | Conversion | 3 | 04-12-2017 10:03 PM |
Newbie question: mobi convert to sony with Caliber | MaxwellBeckett | Sony Reader | 3 | 05-07-2009 12:46 PM |