Article View: news.software.readers
Article #229189Re: [JR] Lou Gehrig's disease?
From: »Q«
Date: Tue, 20 Jan 2009 02:48
Date: Tue, 20 Jan 2009 02:48
95 lines
4778 bytes
4778 bytes
Relf wrote:
<quote>
I've been a regular poster to Usenet since 1991,
I'm not sure if I ever quoted lines using the “ > ” character.
My posts remain unblocked everywhere, all the time.
Killing all >quoted lines is easy, and
the “ ⏎. ” prefix in front of the original content
tells me that >quoted lines were killed. I love it ! ( so far )
Killing “ attribution Lines ” ( ALs ) is tricky.
If there are blank lines at the start of a post, they are removed.
The span of lines ( up to 5 lines ) from there to the next blank line,
or to >quoted line, may or may not be ALs.
If the span of lines ends in a >quoted line,
then X.EXE considers them ALs and remove them ( by not printing them ).
But, if they end in a blank line, then they are ALs
if-and-only-if they contain something like “ Left@Right. ”
and the begining of the line doesn't look like a link
( e.g. “ news:Left@Right.COM ” ).
The code ( from JeffRelf.F-M.FM/X.CPP ) looks like this:
// BB points to the body, an array of lines.
// P and B will point to the line ( a null terminated string )
PP = BB - 1 ; int SawQ = 0, Smelly = 0 ; const int MaxAttribLns = 5 ;
while ( ++ PP < EE && PP - BB <= MaxAttribLns && ( P = B = * PP ) ) {
WhileWhite;
// Ch is either null or the first black space in the line.
if ( >Quoted || Smelly && ! Ch ) {
// Make the body of the post start after the ALs.
BB = PP + 1, SawQ = 1 ; break ; }
if ( ! Ch )
// “ ! Ch ” is true so the line is blank, we're done.
// We found no ALs.
break ;
if ( Smelly || EqiN( L"news:", P, 5 ) || EqiN( L"Google.COM", P, 10 )
|| EqiN( L"www.", P, 4 ) || EqiN( L"http:", P, 5 ) )
// This line starts like it's a link, so ignore it.
continue ;
P = FromStart( P, '@' );
if ( ! P || P == B || ! Iden( P[ -1 ] ) || ! Iden( P[ 1 ] ) )
// No “ Left@Right ”, ignore the line.
continue ;
// “ ill ” has the “ . ” char and
// the list of invalid characters for a Right-ID
static LnP ill = L"@.,:;\"()<>[]\\"; P ++ ;
While( Ch > 32 && Ch < 127 ) {
// We're here while Right-ID has U.S. ASCII black space
LnP Svd = P ; int C = Ch ; P = ill ; While( C != Ch );
if ( Ch == '.' )
// Found the “ Left@Right. ”, we're in “ Smelly ” ALs.
Smelly = 1 ;
int Done = Ch ; P = Svd, Ch = 1 ; if ( Done ) break ; } }
.......
inline int Iden( wchar_t C ) {
return C == '_' || C >= 128 || Alpha_Numeric ( C ); }
#define >Quoted ( Ch == '>' || Ch == '|' )
#define EqiN ! wcsnicmp
#define While( Should_Loop ) Ch = 1 , P -- ; \
while ( Ch && ( Ch = * ++ P, Ch2 = ! Ch ? 0 : P[ 1 ], Should_Loop ) )
#define WhileWhite While ( Ch && ( Ch <= 32 || Ch == L'¸' ) )
</quote>
Thanks ever so much for explaining all that, Relf. I hope by quoting
it without the ">" characters you dislike, I've made it easier to read
your very important code snippet in the quoted text. I guess it could
be useful to any coders who haven't added the ability to hide quoted
text to their readers. (Though the only ones I can think of are MS
products and Thunderbird, which has an extension for it.)
Oh, and I think you'll find you *are* blocked quite a bit, but don't
let that bug you; Google Groups, the "gold standard" for Usenet, still
shows your posts to its iPhone users, which should be good enough.
--
»Q«
Kleeneness is next to Gödelness.
Technical Details
Message-ID:
<20090119204802.744a2417@prezmyra.remarqs.net>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!border1.nntp.ams.giganews.com!nntp.giganews.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mailReferences:
<80ab9vyazp.fsf@banana.shacknet.nu> <Jeff_Relf@Seattle.2009_Jan.15|3.57am|P> <slrngmuesk.9f.steve@news.mixmin.net> <80k58whdxv.fsf@banana.shacknet.nu> <Jeff_Relf@Seattle.2009_Jan.18|2.34am|t> <slrngn6jsi.gbb.steve@news.mixmin.net> <Jeff_Relf@Seattle.2009_Jan.19|0.31am|i>Show Full Headers
Complete Article Headers
Message-ID: <20090119204802.744a2417@prezmyra.remarqs.net> Subject: Re: [JR] Lou Gehrig's disease? Date: Mon, 19 Jan 2009 20:48:02 -0600 From: »Q« <boxcars@gmx.net> References: <80ab9vyazp.fsf@banana.shacknet.nu> <Jeff_Relf@Seattle.2009_Jan.15|3.57am|P> <slrngmuesk.9f.steve@news.mixmin.net> <80k58whdxv.fsf@banana.shacknet.nu> <Jeff_Relf@Seattle.2009_Jan.18|2.34am|t> <slrngn6jsi.gbb.steve@news.mixmin.net> <Jeff_Relf@Seattle.2009_Jan.19|0.31am|i> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!border1.nntp.ams.giganews.com!nntp.giganews.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Newsgroups: news.software.readers Organization: none Lines: 95 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: individual.net AoXYXthh+uvO1KNLD31EmQcqenQJBFm7738bXLtaQ/mA6bo3su X-Orig-Path: prezmyra.remarqs!not-for-mail Cancel-Lock: sha1:5UtXYhy2xdJ2ByQ5f1jsR5BLCo8= X-Newsreader: Claws Mail 3.6.1 (GTK+ 2.12.9; i486-slackware-linux-gnu)