home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / bsd_srcs / usr.bin / groff / macros / tmac.ps < prev    next >
Encoding:
Text File  |  1991-04-30  |  2.9 KB  |  116 lines

  1. .nr _C \n(.C
  2. .cp 0
  3. .ftr AX ABI
  4. .ftr KR BMR
  5. .ftr KI BMI
  6. .ftr KB BMB
  7. .ftr KX BMBI
  8. .ftr CW CR
  9. .ftr CO CI
  10. .ftr CX CBI
  11. .ftr H HR
  12. .ftr HO HI
  13. .ftr HX HBI
  14. .ftr Hr HNR
  15. .ftr Hi HNI
  16. .ftr Hb HNB
  17. .ftr Hx HNBI
  18. .ftr NX NBI
  19. .ftr PA PR
  20. .ftr PX PBI
  21. .ftr ZI ZCMI
  22. .ftr C CR
  23. .char \(rn \h'-\w'\(sr'u'\(rn\h'\w'\(sr'u'
  24. .char \[parenlefttp] \[parenlefttp]\h'.016m'
  25. .char \[parenleftbt] \[parenleftbt]\h'.016m'
  26. .char \[parenleftex] \[parenleftex]\h'.016m'
  27. .char \[parenrighttp] \[parenrighttp]\h'.016m'
  28. .char \[parenrightbt] \[parenrightbt]\h'.016m'
  29. .char \[parenrightex] \[parenrightex]\h'.016m'
  30. .char \[ci] \v'-.25m'\h'.05m'\D'c .5m'\h'.05m'\v'.25m'
  31. .char \[sq] \h'.05m'\D'l .5m 0'\D'l 0 -.5m'\D'l -.5m 0'\D'l 0 .5m'\h'.55m'
  32. .char \[ru] \D'l .5m 0'
  33. .char \[ul] \v'.25m'\D'l .5m 0'\v'-.25m'
  34. .char \[br] \Z'\v'.25m'\D'l 0 -1m''
  35. .char \[or] \h'.1m'\Z'\D'l 0 -.675m''\h'.1m'
  36. .char \[12] \v'-.7m\s[\\n(.s*6u/10u]+.7m'1\v'-.7m\s0+.7m'\
  37. \(f/\s[\\n(.s*6u/10u]2\s0
  38. .char \[14] \v'-.7m\s[\\n(.s*6u/10u]+.7m'1\v'-.7m\s0+.7m'\
  39. \(f/\s[\\n(.s*6u/10u]4\s0
  40. .char \[34] \v'-.7m\s[\\n(.s*6u/10u]+.7m'3\v'-.7m\s0+.7m'\
  41. \(f/\s[\\n(.s*6u/10u]4\s0
  42. .char \[S1] \v'-.2m'\s-31\s+3\v'+.2m'
  43. .char \[S2] \v'-.2m'\s-32\s+3\v'+.2m'
  44. .char \[S3] \v'-.2m'\s-33\s+3\v'+.2m'
  45. .tr \[char178]\[S2]
  46. .tr \[char179]\[S3]
  47. .tr \[char185]\[S1]
  48. .tr \[char188]\[14]
  49. .tr \[char189]\[12]
  50. .tr \[char190]\[34]
  51. .char \[Fi] ffi
  52. .char \[Fl] ffl
  53. .char \[ff] ff
  54. .char \[ij] ij
  55. .char \[IJ] IJ
  56. .if !c\[tm] .char \[tm] \s-3\v'-.3m'TM\v'+.3m'\s+3
  57. .cp \n(_C
  58. .\" ignore the rest of the file in compatibility mode
  59. .if \n(.C .nx /dev/null
  60. .de ps-achar
  61. .char \\$1 \\$3\
  62. \k[acc]\
  63. \h'(u;-\w'\\$2'-\w'\\$3'/2+\\\\n[skw]+(\w'x'*0)-\\\\n[skw])'\
  64. \v'(u;\w'x'*0+\\\\n[rst]+(\w'\\$3'*0)-\\\\n[rst])'\
  65. \\$2\
  66. \v'(u;\w'x'*0-\\\\n[rst]+(\w'\\$3'*0)+\\\\n[rst])'\
  67. \h'|\\\\n[acc]u'
  68. .ie '\\$3'\(.i' .hcode \\$1i
  69. .el .hcode \\$1\\$3
  70. ..
  71. .if !c\['y] \{\
  72. .ps-achar \['y] \[aa] y
  73. .tr \[char253]\['y]
  74. .\}
  75. .if !c\['Y] \{\
  76. .ps-achar \['Y] \[aa] Y
  77. .tr \[char221]\['Y]
  78. .\}
  79. .if !c\['c] .ps-achar \['c] \[aa] c
  80. .if !c\['C] .ps-achar \['C] \[aa] C
  81. .de ps-bb
  82. .nr ps-nargs \\n[.$]
  83. .if \\n[ps-nargs]=4 \{\
  84. .    nr ps-llx 0\\$1
  85. .    nr ps-lly 0\\$2
  86. .    nr ps-urx 0\\$3
  87. .    nr ps-ury 0\\$4
  88. .\}
  89. ..
  90. .de PSPIC
  91. .sy echo .ps-bb `psbb \\$1` >/tmp/psbb\\n[$$]
  92. .so /tmp/psbb\\n[$$]
  93. .if \\n[ps-nargs]=4 \{\
  94. .    nr ps-wid (\\n[ps-urx]-\\n[ps-llx])
  95. .    nr ps-ht (\\n[ps-ury]-\\n[ps-lly])
  96. .    if \\n[ps-wid]<0 .nr ps-wid 0-\\n[ps-wid]
  97. .    if \\n[ps-ht]<0 .nr ps-ht 0-\\n[ps-ht]
  98. .    ie \\n[.$]>=2 .nr ps-deswid (i;\\$2)
  99. .    el .nr ps-deswid \\n[.l]-\\n[.i]<?\\n[ps-wid]p
  100. .    ie \\n[.$]>=3 .nr ps-desht (i;\\$3)
  101. .    el .nr ps-desht \\n[ps-deswid]*1000+(\\n[ps-wid]/2)/\\n[ps-wid]\
  102. *\\n[ps-ht]+500/1000
  103. .    ne \\n[ps-desht]u+1v
  104. .    sp \\n[ps-desht]u
  105. .    nr ps-offset \\n[.l]-\\n[.i]-\\n[ps-deswid]/2
  106. .    ie \\n[.$]>=3 \
  107. \h'\\n[ps-offset]u'\X'ps: import \\$1 \\n[ps-llx] \\n[ps-lly] \\n[ps-urx] \
  108. \\n[ps-ury] \\n[ps-deswid] \\n[ps-desht]'
  109. .    el \
  110. \h'\\n[ps-offset]u'\X'ps: import \\$1 \\n[ps-llx] \\n[ps-lly] \\n[ps-urx] \
  111. \\n[ps-ury] \\n[ps-deswid]'
  112. .    br
  113. .\}
  114. .sy rm /tmp/psbb\\n[$$]
  115. ..
  116.