home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 1 / BBS in a box - Trilogy I.iso / Files / Publish / N / Nisus PostScript Macros / PostScript code (raw) < prev    next >
Encoding:
Text File  |  1993-05-17  |  2.6 KB  |  95 lines  |  [TEXT/NISI]

  1.  
  2. Below are the PostScript programs used in the backdrop and RRect Frame
  3. macros. It should be possible to use these programs in programs other 
  4. than nisus by pasting them to documents and then changing the font to
  5. PostScript Escape (paste them into the header if you want the effect 
  6. on every page). See the customization document for hints on changing 
  7. font sizes etc.
  8.  
  9. Of course if it doesn't work it ain't my fault :-).
  10.  
  11.  
  12.  
  13. % "backdrop" code -- prints CONFIDENTIAL diagonally across page
  14. %    in light grey.
  15. gsave
  16. initgraphics
  17. /width 612 def
  18. /height 792 def
  19. /Helvetica-Bold findfont 100 scalefont setfont 
  20. /center {dup stringwidth pop 2 div neg 0 rmoveto} def
  21. .90 setgray
  22. width 2 div height 2 div 36 sub moveto
  23. -55 rotate
  24. (CONFIDENTIAL) center show
  25. grestore
  26.  
  27.  
  28.  
  29.  
  30.  
  31. % "round rectangle" code -- prints a round rectangle with
  32. %    Title, name, and date (or any 3 text strings) inserted.
  33. %    Designed to be used as a poor man/woman's presentation
  34. %    program.
  35. gsave
  36. initgraphics
  37. %%%%%%%%%   Start User Customizable Section   %%%%%%%%%
  38. /title (My Test Presentation) def
  39. /name (Dale Southard Jr.) def
  40. /date (University of Toledo) def
  41. /titlefont /Helvetica-Bold def
  42. /namefont /Helvetica-Bold def
  43. /datefont /Helvetica-Bold def
  44. /titlesize 18 def
  45. /namesize 14 def
  46. /datesize 14 def
  47. /arcrad 36 def
  48. 2 setlinewidth
  49. /width 612 def
  50. /height 792 def
  51. /landscape true def
  52. /marg 72 def
  53. %%%%%%%%%%%  End User Customizable Section  %%%%%%%%%%%
  54. /center {dup stringwidth pop 2 div neg 0 rmoveto} bind def
  55. landscape true eq {height width /height exch def /width exch def
  56. 0 width translate -90 rotate} if
  57. /xto width marg sub def
  58. /yto height marg sub def
  59. marg dup arcrad add moveto
  60. marg yto xto yto arcrad arcto clear
  61. xto yto xto marg arcrad arcto clear
  62. xto marg dup dup arcrad arcto clear
  63. marg dup dup yto arcrad arcto clear
  64. 0 setgray
  65. stroke
  66. titlefont findfont titlesize scalefont setfont
  67. /slength title stringwidth pop def
  68. slength 0 ne {
  69.     /xcenter marg xto marg sub 2 div add def
  70.     xcenter yto moveto
  71.     slength titlesize add dup 2 div 0 rmoveto neg 0 rlineto
  72.     1 setgray stroke
  73.     xcenter yto titlesize 4 div sub moveto
  74.     0 setgray title center show
  75. } if
  76. namefont findfont namesize scalefont setfont
  77. /slength name stringwidth pop def
  78. slength 0 ne {
  79.     marg arcrad add marg moveto
  80.     slength namesize add 0 rlineto
  81.         1 setgray stroke
  82.     marg arcrad namesize 2 div add add marg namesize 4 div sub moveto
  83.         0 setgray name show
  84. } if
  85. datefont findfont datesize scalefont setfont
  86. /slength date stringwidth pop def
  87. slength 0 ne {
  88.     xto arcrad sub marg moveto
  89.     slength datesize add neg 0 rlineto
  90.         1 setgray stroke
  91.     xto arcrad slength datesize 2 div add add sub marg datesize 4 div sub moveto
  92.         0 setgray date show
  93. } if
  94. grestore
  95.