home *** CD-ROM | disk | FTP | other *** search
/ Best Objectech Shareware Selections / UNTITLED.iso / boss / word / text / 019 / man.sl < prev    next >
Text File  |  1993-01-19  |  900b  |  37 lines

  1. ;;
  2. ;;  execute man then remove backspaces
  3. ;;
  4.  
  5. ( [clean buf cmd subj ctrl_h] "*manual-entry*" =buf
  6.   "Cleaning man page..." =clean
  7.   
  8.   "man:" "" read_mini =subj
  9.   subj strlen {return} !if
  10.   
  11.   "man " subj strcat " 2> /dev/null" strcat =cmd
  12.   buf pop2buf
  13.   erase_buffer
  14.   "Getting man page..." message flush
  15.   cmd shell_cmd
  16.   clean message flush
  17.   8 char =ctrl_h
  18.   bob "_" ctrl_h strcat "" 0 replace     ;; remove _^H combinations
  19.   bob  {ctrl_h fsearch} {del del} while  ;; remove remaining overstrikes
  20.   ;;
  21.   ;;  remove multiple blank lines--- should make this standalone
  22.   ;;
  23.   bob {"\n" looking_at}{del} while
  24.   {1 down} {
  25.     eol bolp 
  26.       { 1 down {break} !if
  27.         {{eol bolp}{eobp 0 ==} andelse} {del} while
  28.       } if
  29.   } while
  30.   bob
  31.   ;;
  32.   ;;  set buffer no modified
  33.   ;;
  34.   getbuf_info pop 0 setbuf_info
  35.   clean "done" strcat message flush
  36. ) unix_man
  37.