Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 05-08-2023, 09:06 AM   #1
Quoth
Still reading
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 14,056
Karma: 105092227
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper
Over enthusiastic "Chapter" detection?

Just yesterday I fixed an ebook conversion to epub from azw3 where every paragraph was a new page. The regular paragraphs had a class called "chapter"
Quote:
<p class="chapter">
and the first paragraph had a class called "chapter-first" which was OK
Quote:
<p class="chapter-first">
I renamed those in the azw3 file with a right-click rename which did enitire of all HTML files and CSS file in one go.
Reconverted the azw3 and it was fine.

Never saw this before on azw3 conversions to epub. I've not edited the Structure detection for ages:
Quote:
//*[((name()='h1' or name()='h2') and re:test(., '\s*((chapter|book|section|part)\s+)|((prolog|prol ogue|epilogue)(\s+|$))', 'i')) or @class = 'chapter']
How do I make it ignore @class = 'chapter' when it's the body paragraphs?
Quoth is offline   Reply With Quote
Old 05-08-2023, 01:07 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: 45,360
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
remove

or @class = 'chapter'
kovidgoyal is online now   Reply With Quote
Advert
Old 05-08-2023, 01:40 PM   #3
Quoth
Still reading
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 14,056
Karma: 105092227
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper
I thought that would work. Though that ignores non <p tags too

Thanks
Quoth is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Apple's Books/iBooks: "in this chapter" "in this book" display Hitch ePub 9 06-25-2020 09:30 PM
Duplicate Detection for "Add Books" is too weak nurbles62 Library Management 9 03-27-2020 10:20 PM
Language "detection" when adding books McGonigle Library Management 2 07-14-2014 06:26 AM
K3 Problems with metadata.calibre and "On Device" detection pchrist7 Devices 5 02-24-2011 10:14 AM
Calibre 0.7.9 Device Detection with Augen "The Book" ebsebs Calibre 1 07-23-2010 09:01 AM


All times are GMT -4. The time now is 09:55 PM.


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