🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nn
Article #1628

YAER: flexible menu and header formats

#1628
From: Ray Davis
Date: Fri, 03 May 1991 14:53
91 lines
4398 bytes
Here's an enhancement that I doubt would be too difficult (well - maybe
a bit B-)), but would greatly enhance the flexibility of nn.  I've heard
from at least one other person in netland who agrees with this idea.

Rather than have a fixed number of menu layouts, why not have various
things that can be displayed and let each user decide what and where
to display it.  It could be a kind of modified printf format.  Given
the following definitions:

    %X	- article select letter
    %M	- seen/unseen/leave/etc mark
    %N  - name
    %L	- lines
    %S	- subject

We can then set them how we want to see them using a 'set menu-format'
(or something) command.  The the default menu line would look like:

    set menu-format "%X%M%3N%20L%24S"

Or something like that, where the numbers represent starting columns.
Maybe a better format could be represented, or even a real printf
format with a list of variables and sizes (name, name_size, subject, etc).

Other definitions could be defined:

    %D	- date posted
    %L	- login
    %E	- number of equal subjects (consolidated menus)
    %C	- size of article in chars

And of course there would have to be a sub-format for things like
date and login.  The date-formats could be like the date+ command
(similar to SystemV date):

    %S   seconds.
    %M   minutes.
    %H   hours.
    %T   time as HH:MM:SS.
    %d   day number within the month (01-31).
    %m   month number (01-12).
    %h   month name (3 character).
    %y   year number - 1900.
    %w   weekday number (0 is Sunday).
    %a   weekday name (3 character).
    %D   date as mm/dd/yy.
    %j   day number within the year (1-365).
    %Z   number of seconds since 00:00:00 GMT Jan 1, 1970.

And login-format might have:

    %L	- login id
    %H	- host

So, I might set these things something like this:

    set menu-format "%X%M%D%L%S%E"
    set date-format "%?h %d"	    # '?' means show once per page
    set login-format "%L@%.2H"	    # '.2' means only last 2 parts domain

And get menu lines something like:

a May 03 rdavis@convex.com       This is a subject line                       3
b.    25 youth@sonic.ny          Yet another subject line
c        foobar@mumble.de        Re: phoo                                    13
d Jun 12 pporizkova@feastable.ed YAER: flexible menu and header formats      69

Or to get a 'notes' style menu:

    set menu-format "%D%10X%M%14S%52E%55L"
    set date-format "%?y/%?m/%?d"   # mm/dd/yy or mm/dd or dd
    set login-format "%L@%H"

Which would look something like:

3/13/91  a   minimal sendmail                       3 nklein@convex1.convex.com
         b=  Any Checkpoint/Restart bugs            3 nklein@convex1.convex.com
         c=  Found the lost 4mb of root             1 freel@middlec.UUCP
         d.  Any Checkpoint/Restart Problems?       4 nklein@c1east.convex.com
3/14     e   Job limits under CXbatch               4 hardy@eurodem.convex.com
3/15     f.  GIP man page                             tchrist@pixel.UUCP
3/19     g.  9.0 nfs bugs?                          4 rdavis
         h   ranlib bug / patch                     2 suplick@mikey.UUCP

In addition to menu lines, a similar method could be used to define
the header line(s) and footer line in read mode.  You could also
set up different formats depending on screen width, so people with
workstations, x-terminals or 132 column displays could go crazy.

OK - it could start out much simpler that this and grow.
Does anyone else like this idea?
Technical Details
Message-ID: <rdavis.673282383@connie.convex.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!archive!mbox2nntp-news.software.nn.mbox.zip!gmdzi!unido!fauern!math.fu-berlin.de!fub!ox.com!caen!hellgate.utah.edu!csn!magnus.acs.ohio-state.edu!zaphod.mps.ohio-state.edu!rpi!crdgw1!uunet!convex!rdavis

Show Full Headers
Complete Article Headers
Message-ID: <rdavis.673282383@connie.convex.com>
Subject: YAER: flexible menu and header formats
Date: Fri, 03 May 1991 14:53:03 +0000
From: rdavis@convex.com (Ray Davis)
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!archive!mbox2nntp-news.software.nn.mbox.zip!gmdzi!unido!fauern!math.fu-berlin.de!fub!ox.com!caen!hellgate.utah.edu!csn!magnus.acs.ohio-state.edu!zaphod.mps.ohio-state.edu!rpi!crdgw1!uunet!convex!rdavis
Newsgroups: news.software.nn
Summary: Yet Another Enhancement Request for flexible display formats
Sender: usenet@convex.com (news access account)
Organization: CONVEX Computer Corporation, Richardson, Tx., USA
Lines: 91
Nntp-Posting-Host: connie.convex.com