2008/8/6 Brian Barker <[EMAIL PROTECTED]>:
> At 15:09 06/08/2008 +0300, Dotan Cohen wrote:
>>
>> Is there a way to highlight sentences longer than N words, N characters,
>> contain more than N commas, or that span more than N lines? I am
>> proofreading a document where the distinction between paragraph and sentence
>> is blurry at best (to put it mildly).
>
> You may be able to do some of these things using regular expressions and the
> same Search, Find All, Highlight sequence as for your double spaces.
>
> For example, to find sentences with at least 100 characters, tick on
> "Regular expressions" and search for
> [A-Z][^.]{99,}\.
> That's [A-Z] to match any capital letter, [^.] to match any character except
> full stop, {99,} to require the previous element to occur at least 99 times,
> and \. to match the terminating full stop. You'll have to enhance this
> expression if you want to cope with sentences that have internal full stops
> - perhaps in abbreviations - and those that end with some other punctuation,
> such as question marks or exclamation marks. Or you could simply use
> separate searches sequentially, of course.
>
> I trust this helps.
>
Thanks, Brian! I should have thought about using Regexes, I'm actually
surprised that I didn't. Though, of course, Jamie Zdawinsky's famous
quote may apply here:
Some people, when confronted with a problem, think "I know, I'll use
regular expressions." Now they have two problems.
--
Dotan Cohen
http://what-is-what.com
http://gibberish.co.il
א-ב-ג-ד-ה-ו-ז-ח-ט-י-ך-כ-ל-ם-מ-ן-נ-ס-ע-ף-פ-ץ-צ-ק-ר-ש-ת
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?