🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #49045

Re: thanks for support - Xnews 2.05.24 is out, btw

#49045
From: Erland Sommarskog
Date: Thu, 03 Jun 1999 00:00
35 lines
2486 bytes
Luu Tran (luu@xnews.3dnews.net.invalid) writes:
>Actually, there are 4, plus the popup hint
>
>function SmartDateFmt( DateTime: TDateTime):string; overload;
>var Diff:integer;
>begin
>  Diff:=Trunc( SysUtils.Now-DateTime);
>  if Diff<0 then Diff:=-Diff; // this should't happen, but...
>  if Diff=0 then Result:=FormatDateTime( 'hh:nna/p', DateTime)
>  else if Diff<7 then Result:=FormatDateTime( 'ddd dd', DateTime)
>  else if Diff<365 then Result:=FormatDateTime( 'mmm dd', DateTime)
>  else Result:=FormatDateTime( 'mm/dd/yyyy', DateTime);
>end;
>
>I don't feel like having 5 user date formats, so I'll stick with a simple 
>Use24hrclock toggle.

Personally I find that just too smart. I would prefer a consistent
date format, which presents the date in the same way, no matter how 
old or new the article is. And, yes, I think that should be configurable,
as mininum by looking at the regional settings.

Myself I have %#d/%#m %H:%M in News Express which results in
"4/6 00:03" for the current time. The formats that NX uses
appears to come right from strftime or some other C++ run-time
routine. It appears from your code snippet that FormatDateTime
is a similar routine in Delphi, and I'd be happy to feed it
with what ever it takes.

-- 
Erland Sommarskog, Stockholm, sommar@algonet.se
This could have been my two cents worth, but alas the Swedish
government has decided that I am not to have any cents.

Technical Details
Message-ID: <8DDB24AAYazorman@news.algonet.se>
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!not-for-mail
References: <8DD163DB9luutrangeocities@news.mindspring.com> <8DD285B2119990312175977@news.tue.nl> <8DD269DB8luutrangeocities@news.mindspring.com> <8DD374758haustintpgicomau@dnews.tpg.com.au> <8DD3EC7A2luutrangeocities@news.mindspring.com> <8DD49BFD519990312175977@news.tue.nl> <8DD442C41luutrangeocities@news.mindspring.com>

Show Full Headers
Complete Article Headers
Message-ID: <8DDB24AAYazorman@news.algonet.se>
Subject: Re: thanks for support - Xnews 2.05.24 is out, btw
Date: Thu, 03 Jun 1999 00:00:00 +0000
From: sommar@algonet.se (Erland Sommarskog)
References: <8DD163DB9luutrangeocities@news.mindspring.com> <8DD285B2119990312175977@news.tue.nl> <8DD269DB8luutrangeocities@news.mindspring.com> <8DD374758haustintpgicomau@dnews.tpg.com.au> <8DD3EC7A2luutrangeocities@news.mindspring.com> <8DD49BFD519990312175977@news.tue.nl> <8DD442C41luutrangeocities@news.mindspring.com>
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!not-for-mail
X-Deja-AN: 485433212
X-Complaints-To: abuse@algo.net
X-Trace: cubacola.tninet.se 928447719 18517 195.163.76.166 (3 Jun 1999 22:08:39 GMT)
Organization: BRF Beckasinen 13
User-Agent: Xnews/2.05.21
NNTP-Posting-Date: 3 Jun 1999 22:08:39 GMT
Newsgroups: news.software.readers