home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d1xx / d101 / psintrp.lha / PsIntrp / psedit < prev    next >
Text File  |  1987-09-05  |  718b  |  50 lines

  1.  
  2. save
  3.  
  4. /infile  (%stdin)  (r) file def
  5. /conin   { infile read pop } def
  6.  
  7. /char 1 string def
  8. /buf  80 string def
  9.  
  10. /leftmargin 50 def
  11. /lineheight 20 def
  12. /cursorheight lineheight 5 sub def
  13.  
  14. /hpos 50 def
  15. /vpos 300 def
  16.  
  17. /cursoron {
  18.    currentpoint
  19.    3 pencolor 2 penmode
  20.    currentpoint cursorheight add
  21.    2 copy
  22.    exch 10 add exch lineheight sub
  23.    box
  24.    moveto
  25.    1 pencolor 1 penmode
  26. } def
  27.  
  28. /newline { currentpoint exch pop leftmargin exch
  29.            lineheight sub moveto } def
  30.  
  31. /edit {
  32. {
  33. newpath
  34. cursoron
  35. char 0 conin put
  36. cursoron
  37. char 0 get  27 eq {exit} if
  38. char 0 get  13 eq {newline} if
  39. char 0 get  32 ge {char show} if
  40. }
  41. loop
  42. } def
  43.  
  44.   /simplex findfont 15 scalefont setfont
  45.   hpos vpos moveto
  46.   edit
  47.  
  48. restore
  49.  
  50.