![]() |
#1 |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Jul 2013
Device: KPW
|
Help with detecting chapters
Hello,
I am quite new with writing codes, but I would like to use option for detecting chapters (Structure Detecting) with Calibre. My input us in docx file format. Can someone please help |
![]() |
![]() |
![]() |
#2 |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
The original, default in the distribution uses these keywords:
Code:
//*[((name()='h1' or name()='h2') and re:test(., '\s*((chapter|book|section|part)\s+)|((prolog|prologue|epilogue)(\s+|$))', 'i')) or @class = 'chapter'] |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Jul 2013
Device: KPW
|
What does it means?
|
![]() |
![]() |
![]() |
#4 |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
|
![]() |
![]() |
![]() |
#5 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
It matches an XPath to identify as a chapter. See the calibre xpath tutorial: http://manual.calibre-ebook.com/xpath.html
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Jul 2013
Device: KPW
|
|
![]() |
![]() |
![]() |
#7 | |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Jul 2013
Device: KPW
|
Quote:
|
|
![]() |
![]() |
![]() |
#8 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
We can help you come up with the right XPath, but you need to tell us how the input document is formatted.
![]() If Header styles were used in the DOCX, the default should work.... |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Aura Kobo Aura - chapters detecting | anthaet | Kobo Reader | 4 | 10-29-2014 03:41 PM |
detecting chapters with --markdown | p3aul | Conversion | 7 | 05-15-2011 11:01 AM |
Detecting bookmarks as chapters on a PDF | furius | Conversion | 3 | 04-13-2011 09:19 PM |
azw to mobi: Not detecting chapters/page break at chapters and no TOC | RachDvn | Calibre | 3 | 01-16-2011 09:53 AM |
Detecting chapters | Tibor | Calibre | 4 | 01-17-2009 01:25 PM |