View Single Post
Old 02-23-2012, 03:04 PM   #4
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,137
Karma: 60406498
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by cybmole View Post
I suspect there is no easy answer to this but I will ask anyway.

given a book which uses capitalisation in lieu of scene breaks, with all paragraphs sharing the same CSS i.e.

THIS IS HOW THE 1st paragraphs starts.......blah blah
but not the next paragraph...
Or the one after that......
....
YET SOME TIME LATER THERE is another instance
...

I want to pick out those capitalised starts in order to assign a unique CSS class.

but devising a rule is very hard.

testing that 2nd letter of a paragraph is capitalised works most times but will miss
I CANNOT GET THIS one... and will miss A TOUGH ACT TO follow
and will mis-classify
"I don't want this one"

any better methods, anyone ?
Code:
([A-Z]* ){2,}
Case sensitive
find 1 or more Upper followed by a space, 2 or more times
theducks is offline   Reply With Quote