🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #69348

Re: [slrn] Sorting

#69348
From: Slawomir Szczyrba
Date: Mon, 18 Dec 2000 17:49
87 lines
4092 bytes
Per aspera ad Guenter Resch :
> Highlighting it with this neat exclamation mark? Nevertheless, I'd like
> to see those threads in chronological order ...
> 
Try this :

#v+
diff -Naru src/art.c src.highlight/art.c
--- src/art.c	Mon Jan 31 15:04:03 2000
+++ src.highlight/art.c	Mon Jan 31 15:01:08 2000
@@ -7531,9 +7531,18 @@
 	  }
 	else
 	  {
+	     if ((h->score > 0)&&(h->score<10))
+	      {
+	       slrn_set_color (HIGH_SCORE_COLOR + 38 + h->score);
+   	       SLsmg_printf ("#%c",
+			   ((flags & HEADER_TAGGED) ? '*': ' '));
+	      }
+	     else
+	      {
 	     slrn_set_color (0);
 	     SLsmg_printf (" %c",
 			   ((flags & HEADER_TAGGED) ? '*': ' '));
+	      }
 	  }
      }
    slrn_set_color (0);
diff -Naru src/startup.c src.highlight/startup.c
--- src/startup.c	Mon Jan 31 15:04:03 2000
+++ src.highlight/startup.c	Mon Jan 31 15:02:40 2000
@@ -762,6 +762,12 @@
 	return 0;
      }
 
+   if (0 == strncmp (name, "high_score", 10))
+     {
+	SLtt_set_color (HIGH_SCORE_COLOR + 38 + atoi (name+10), name, fg, bg);
+	return 0;
+     }
+
    slrn_error ("%s is not a color object", name);
    return -1;
 }
@@ -1159,6 +1165,11 @@
      {
 	SLtt_set_color (QUOTE_COLOR + i, NULL, "red", DEF_BG);
 	SLtt_set_mono (QUOTE_COLOR + i, NULL, 0);
+     }
+   for (i = 1; i < 10; i++)
+     {
+	SLtt_set_color (HIGH_SCORE_COLOR + 38 + i, NULL, "red", "red");
+	SLtt_set_mono (HIGH_SCORE_COLOR + 38 + i, NULL, 0);
      }
 
 #if !defined(IBMPC_SYSTEM)

#v-

In .slrnrc :

#v+
set min_high_score 10
...
color high_score1       "red"		"red"
color high_score2       "blue"		"blue"
color high_score3       "green"		"green"
color high_score4       "lightgray"	"lightgray"
color high_score5       "brown"		"brown"
color high_score6       "blue"		"blue"
color high_score7       "magenta"	"magenta"
color high_score8       "brightgreen"	"brightgreen"
color high_score9       "yellow"	"yellow"
#v-

And you can mark your favourite news with score 1..9

> 	Guenter

Slawek
-- 
  ________ 
_/ __/ __/ Death is a nonmaskable interrupt.
 \__ \__ \_______________________________________________________________
 /___/___/ S�awomir Szczyrba                              steev(AT)hot.pl
Technical Details
Message-ID: <slrn93sjgm.2lp.steev@hot.pl>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!supernews.google.com!sn-xit-02!supernews.com!216.227.56.88.MISMATCH!telocity-west!TELOCITY!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.tele.dk!195.158.233.21!news1.ebone.net!news.ebone.net!news.ipartners.pl!news.internetia.pl!news.tpi.pl!news.icm.edu.pl!news.home.net.pl!Shodan!steev
References: <32ug19.d02.ln@rpc1.imb.oeaw.ac.at> <161220002321096397%adamb@lull.org> <co7i19.gv6.ln@rpc1.imb.oeaw.ac.at> <slrn93psaf.957.adamb@typhoon.xnet.com> <vj8j19.d31.ln@rpc1.imb.oeaw.ac.at>

Show Full Headers
Complete Article Headers
Message-ID: <slrn93sjgm.2lp.steev@hot.pl>
Subject: Re: [slrn] Sorting
Date: Mon, 18 Dec 2000 17:49:10 +0000
From: Slawomir Szczyrba <steev@hot.pl>
References: <32ug19.d02.ln@rpc1.imb.oeaw.ac.at> <161220002321096397%adamb@lull.org> <co7i19.gv6.ln@rpc1.imb.oeaw.ac.at> <slrn93psaf.957.adamb@typhoon.xnet.com> <vj8j19.d31.ln@rpc1.imb.oeaw.ac.at>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!supernews.google.com!sn-xit-02!supernews.com!216.227.56.88.MISMATCH!telocity-west!TELOCITY!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.tele.dk!195.158.233.21!news1.ebone.net!news.ebone.net!news.ipartners.pl!news.internetia.pl!news.tpi.pl!news.icm.edu.pl!news.home.net.pl!Shodan!steev
Newsgroups: news.software.readers
Organization: HomeNet News Server
Lines: 86
Reply-To: steev@hot.pl
NNTP-Posting-Host: news.home.net.pl
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-2
Content-Transfer-Encoding: 8bit
X-Trace: sunsite.icm.edu.pl 977165444 11887 212.85.112.42 (18 Dec 2000 18:50:44 GMT)
X-Complaints-To: abuse@icm.edu.pl
NNTP-Posting-Date: Mon, 18 Dec 2000 18:50:44 +0000 (UTC)
X-Geek: GCS/CM d- s++:++ a? C+++ UH++++ P++ L++ W N++ w++ PGP- tv b+++@ D+ e+++
X-Original-NNTP-Posting-Host: pf47.katowice.cvx.ppp.tpnet.pl
X-Info: Sygnaturka i pierwsza linia postu są generowane losowo.
X-Authenticated-User: steev.hot
X-Original-Trace: 18 Dec 2000 19:52:16 +0100, pf47.katowice.cvx.ppp.tpnet.pl
X-Notice1: This post has been postprocessed on the news.icm.edu.pl server.
X-RLU: #165379
X-Notice2: Subject line has been filtered and any Odp: strings removed.
User-Agent: slrn/0.9.6.3+ (Linux)