🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: bit.listserv.script-l
Article #5

Re: Waterloo SCRIPT output for on-line viewing

#5
From: Michael Friendly
Date: Fri, 30 Oct 1992 04:38
76 lines
3142 bytes
On Thu, 29 Oct 1992 10:27:46 EST Jeff Brooks said:
>We would like to use Waterloo SCRIPT to format documents for
>on-line viewing using Gopher or some other campus-wide information
>system.  We have the following problems:
>
> 1. Underscored/overstruck text is displayed using several output
>    lines per line of text.  This is fine for printer output, but
>    terribly confusing to on-line viewing.  We _could_ write dummy
>    tag code for every tag that produces emphasized text, but we
>    would still miss, e.g., places where a function was used to
>    select boldface text.
>
> 2. SCRIPT seems to append quite a number of blanks lines at the
>    end of each document.
>

A simple solution is to filter the listing file.  If you have
CMS pipes, here's a program that solves (1) and can be adjusted
to solve (2) [it was designed to mimic the page appearance of
the listing file, hence includes the blanks at the end of each
page - passing a pagesize argument of 0 should cure that.]

+========================================== Beginning of ASA2MEMO EXEC
/* convert listing file to memo file */
arg fn ft fm
'pipe disk' fn ft fm '| asa2memo | >' fn 'memo' fm
-================================================ End of ASA2MEMO EXEC
+========================================== Beginning of ASA2MEMO REXX
/* convert a listing file (ASA control chars) to memo file */
arg ps .
signal on error
lines=0
hexin = 'BFAFFA'x      ||,     /* underline, bullet, vert bar */
        'ACBCABBB'x    ||,     /* box corners                 */
        'CCCBEBEC'x
hexout= '-*|' || '++++++++'
if ps='' | datatype(ps,'w')=0 ,
   then pagesize = 56
   else pagesize = ps

do forever
  'readto record'
  parse var record 1 cc 2 rest
  rest=translate(rest,hexout,hexin)    /* translate fancy characters */
  select
     when cc='+'  then iterate         /* ignore this record */
     when cc=' '  then do
        'output' rest
        lines = lines+1
        end
     when cc='0'  then do
        'output  '
        'output' rest
        lines = lines+2
        end
     when cc='-'  then do
        'output  '
        'output  '
        'output' rest
        lines = lines+3
        end
     when cc='1'  then do
        if lines > 0 then do
           do l=lines to pagesize
              'output  '
              end
           'output' rest
           end
        lines = 0
        end
     otherwise 'output' rest
     end
  end

Error: exit RC*(RC^=12)
-================================================ End of ASA2MEMO REXX
Technical Details
Message-ID: <SCRIPT-L%92102922493015@RICEVM1.RICE.EDU>
Path: arc1-ca.pugleaf.net!sparky!uunet!news.centerline.com!noc.near.net!mars.caps.maine.edu!news.yale.edu!yale.edu!nigel.msen.com!emory!gatech!paladin.american.edu!auvm!VM1.YORKU.CA!FRIENDLY

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!news.centerline.com!noc.near.net!mars.caps.maine.edu!news.yale.edu!yale.edu!nigel.msen.com!emory!gatech!paladin.american.edu!auvm!VM1.YORKU.CA!FRIENDLY
From: FRIENDLY@VM1.YORKU.CA (Michael Friendly)
Newsgroups: bit.listserv.script-l
Subject: Re: Waterloo SCRIPT output for on-line viewing
Message-ID: <SCRIPT-L%92102922493015@RICEVM1.RICE.EDU>
Date: 30 Oct 92 04:38:28 GMT
Sender: "IBM vs Waterloo SCRIPT discussion group"
              <SCRIPT-L@RICEVM1.BITNET>
Lines: 76
Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU