Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 01-01-2016, 10:13 PM   #1
MerlinMama
Evangelist
MerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beauty
 
MerlinMama's Avatar
 
Posts: 482
Karma: 32554
Join Date: May 2014
Location: Canada
Device: Kobo Sage
Finding lines with dropped opening quote

I have a particular epub that the author seems to have omitted a lot of the opening quotes at the beginning of a 'paragraph' (by this I mean right after a <p> tag). It's an intermittent problem though, not constant, which I think makes it more difficult.

An example is (this is made up text so no copyright issues)
  • <p>Let’s all run over the the store,” he said happily. "We can buy ice cream.”</p>

I did try a couple of option, but the only one that worked, would also pick up the following, which doesn't need changing:
  • <p>George called out to his friends, “Let's all run to the store and get some ice cream.”

Any ideas or suggestions would be appreciated. I know I'm probably just missing something obvious, but...
MerlinMama is offline   Reply With Quote
Old 01-01-2016, 11:17 PM   #2
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
I use a few for finding missing opening and closing quotes. They aren't perfect and I have to look at the matches before making changes.

Missing opening quote:
Code:
(<p>)([^“]*\”.*</p>)
With the replace:
Code:
\1“\2
Missing open quote between closes:
Code:
”([^“]*\”)
This doesn't have a replace string as I have to work out where the quote is missing. And in lot of cases, the wrong quote was used.

Missing closing quote:
Code:
“[^”]+?<p>“
Again, I have to work out where the missing quote should go. Or it it is needed when one persons dialog continues over multiple paragraphs.

These aren't perfect and I have to look at the matches before making changes.

There is a sticky thread in the Sigil forum with a lot of Regex example. It has a lot of good suggestions like this. I think the first one came from it.
davidfor is offline   Reply With Quote
Advert
Old 01-02-2016, 01:39 AM   #3
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,565
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by MerlinMama View Post
. . .
Any ideas or suggestions would be appreciated. I know I'm probably just missing something obvious, but...
Maybe the author followed the convention, in English, of not closing the quote marks at the end of paragraphs if the quote/speech is continued in the next paragraph - many (most ?) widely used style guides (for English) recommend this convention, and many publishers will mandate it.

Quote:
Originally Posted by Chicago Manual of Style
"If a passage consisting of more than one paragraph from the same source is quoted and is not set off as an excerpt, quotation marks are used at the beginning of each paragraph and at the end of the last paragraph."
See punctuation - Why does the multi-paragraph quotation rule exist?

BR
BetterRed is online now   Reply With Quote
Old 01-02-2016, 06:22 AM   #4
MerlinMama
Evangelist
MerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beautyMerlinMama does all things with Zen-like beauty
 
MerlinMama's Avatar
 
Posts: 482
Karma: 32554
Join Date: May 2014
Location: Canada
Device: Kobo Sage
@davidfor - I'll certainly give them a try. At worst, it might give me a starting point.

@BetterRed - No, this is only intermittent OPENING quotes and when I re-did some spot checks this morning to be sure, none I checked were part of continuing dialogs
MerlinMama is offline   Reply With Quote
Old 01-02-2016, 04:15 PM   #5
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,565
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by MerlinMama View Post
@BetterRed - No, this is only intermittent OPENING quotes and when I re-did some spot checks this morning to be sure, none I checked were part of continuing dialogs
- my eyes read OPENING but my brain registered CLOSING, probably because had recently responded to a similar query on another site about multi-paragraph quotations. But that's no excuse.

BR
BetterRed is online now   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Other Fiction Various: A Little Collection of Opening Lines from Various Novels v1. 6. Apr. 2015 Kasper Hviid ePub Books 1 04-09-2015 12:49 PM
K1 with lines on screen, wasn't dropped sneakyspider Kindle Developer's Corner 2 07-11-2013 03:18 PM
Kindle Literature Quiz Game - Quote for Quote glowingeyegames Self-Promotions by Authors and Publishers 0 07-16-2012 12:50 PM
What are your favorite opening lines to a sci/fi novel? wayspooled Reading Recommendations 76 11-06-2009 08:51 AM
Opening lines of classic novels HarryT Lounge 32 07-11-2009 07:01 PM


All times are GMT -4. The time now is 03:20 AM.


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