Server IP : 103.169.32.36 / Your IP : 216.73.216.202 Web Server : Apache System : Linux web.dpmptsp 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : apache ( 48) PHP Version : 5.6.40 Disable Function : NONE MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/share/groff/1.22.2/tmac/ |
Upload File : |
| Current File : /usr/share/groff/1.22.2/tmac/pspic.tmac |
.\" pspic.tmac
.\"
.\" Define the PSPIC macro.
.\"
.\" When used other than with -Tps, -Tdvi, -Thtml, or -Txhtml it draws a box
.\" around where the picture would go.
.\"
.\" Usage:
.\"
.\" .PSPIC [-L|-R|-C|-I <indent>] <file> [<width> [<height>]]
.
.do if d PSPIC .nx
.
.nr _C \n(.C
.cp 0
.
.de PSPIC
. nr ps-offset-mode 0
. \" left-aligned?
. ie '\\$1'-L' \{\
. nr ps-offset-mode 1
. shift
. HTML-DO-IMAGE \\$1 l
. \}
. el \{\
. \" right-aligned?
. ie '\\$1'-R' \{\
. nr ps-offset-mode 2
. shift
. HTML-DO-IMAGE \\$1 r
. \}
. el \{\
. \" indented?
. ie '\\$1'-I' \{\
. nr ps-offset-mode 3
. nr ps-offset (m;\\$2)
. shift 2
. HTML-DO-IMAGE \\$1 i
. \}
. el \{\
. \" centered is the default
. if '\\$1'-C' \
. shift
. HTML-DO-IMAGE \\$1 c
. \}
. \}
. \}
.
. br
.
. \" get bounding box
. psbb \\$1
. if (\\n[llx] : \\n[lly] : \\n[urx] : \\n[ury]) \{\
. nr ps-wid (\\n[urx] - \\n[llx])
. nr ps-ht (\\n[ury] - \\n[lly])
. if (\\n[ps-wid] < 0) \
. nr ps-wid (-\\n[ps-wid])
. if (\\n[ps-ht] < 0) \
. nr ps-ht (-\\n[ps-ht])
.
. \" if we have a <width> parameter, use it as the final
. \" image width; otherwise we use the image's natural width
. \" or the current line length, whatever is smaller
. ie (\\n[.$] >= 2) \
. nr ps-deswid (i;\\$2)
. el \
. nr ps-deswid ((\\n[.l] - \\n[.i]) <? \\n[ps-wid]p)
.
. \" compute the final image height (with proper rounding),
. \" based on the image's aspect
. nr ps-desht (\\n[ps-deswid] * 1000 + (\\n[ps-wid] / 2) \
/ \\n[ps-wid] * \\n[ps-ht] \
+ 500 / 1000)
.
. \" if we have a <height> parameter, use it as the final
. \" image height in case it is smaller than the height
. \" value we have just computed
. if ((\\n[.$] >= 3) & (\\n[ps-desht] > (i;0\\$3))) \{\
. nr ps-desht (i;\\$3)
. \" recompute the final image width since we always
. \" keep the correct image aspect
. nr ps-deswid (\\n[ps-desht] * 1000 + (\\n[ps-ht] / 2) \
/ \\n[ps-ht] * \\n[ps-wid] \
+ 500 / 1000)
. \}
.
. \" reserve vertical space for image
. ne (\\n[ps-desht]u + 1v)
.
. \" compute image offset w.r.t. the current left margin
. if (\\n[ps-offset-mode] == 0) \
. nr ps-offset (\\n[.l] - \\n[.i] - \\n[ps-deswid] / 2)
. if (\\n[ps-offset-mode] == 1) \
. nr ps-offset 0
. if (\\n[ps-offset-mode] == 2) \
. nr ps-offset (\\n[.l] - \\n[.i] - \\n[ps-deswid])
.
. ie '\*[.T]'dvi' \{\
. \" prepare values for \special{psfile=...} as needed by dvips
. ie (\\n[ps-wid]p == \\n[ps-deswid]) \{\
. ds ps-scale \" empty
. ds ps-hoffset hoffset=-\\n[llx]
. ds ps-voffset voffset=-\\n[lly]
. \}
. el \{\
. nr ps-scale (\\n[ps-deswid] * 100 / \\n[ps-wid]p)
. nr ps-hoffset (-\\n[llx] * \\n[ps-scale] / 100)
. nr ps-voffset (-\\n[lly] * \\n[ps-scale] / 100)
. ds ps-scale hscale=\\n[ps-scale] vscale=\\n[ps-scale]
. ds ps-hoffset hoffset=\\n[ps-hoffset]
. ds ps-voffset voffset=\\n[ps-voffset]
. \}
.
\h'\\n[ps-offset]u'\
\v'\\n[ps-desht]u'\
\X'psfile=\\$1 \\*[ps-hoffset] \\*[ps-voffset] \\*[ps-scale]'
. \}
. el \{\
. ie '\*[.T]'ps' \{\
. \" prepare values for grops; the `ps-invis' and `ps-endinvis' escapes
. \" are for groff's -X switch to provide a PS preview with xditview:
. \" it uses -Tps for formatting but xditview can't handle EPS files,
. \" thus alternative code is enclosed between those two escapes
. ds ps-invis \X'ps: invis'
. ds ps-endinvis \X'ps: endinvis'
. ds ps-import \X'ps: import \E$1 \En[llx] \En[lly] \En[urx] \En[ury] \
\En[ps-deswid] \E*[ps-desht]'
. \}
. el \{\
. ds ps-invis
. ds ps-endinvis
. ds ps-import
. \}
.
. ie (\\n[.$] >= 3) \
. ds ps-desht \\n[ps-desht]
. el \
. ds ps-desht \" empty
.
\h'\\n[ps-offset]u'\
\\*[ps-invis]\
\# horizontally, the rectangle is slightly smaller than the image
\# to compensate the line thickness (especially needed for TTY devices)
\Z'\D'p 0 \\n[ps-desht]u \
(\\n[ps-deswid]u - \\n[.H]u) 0 \
0 -\\n[ps-desht]u''\
\# for convenience we also display the image file name (centered vertically);
\Z'\v'((\\n[ps-desht]u / 2u) \
+ (\w'\\$1'u * 0) \
+ ((\\n[rst]u + \\n[rsb]u) / 2u))'\h'1m'\\$1'\
\\*[ps-endinvis]\
\v'\\n[ps-desht]u'\
\\*[ps-import]
. \}
.
. br
. sp \\n[ps-desht]u
. \}
. HTML-IMAGE-END
..
.
.cp \n[_C]
.
.\" end of pspic.tmac
| N4m3 |
5!z3 |
L45t M0d!f!3d |
0wn3r / Gr0up |
P3Rm!55!0n5 |
0pt!0n5 |
| .. |
-- |
December 20 2023 04:35:50 |
0 / 0 |
0755 |
|
| mdoc |
-- |
December 20 2023 04:35:50 |
0 / 0 |
0755 |
|
| | | | | |
| an-ext.tmac |
3.421 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| an-old.tmac |
13.991 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| an.tmac |
0.034 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| andoc.tmac |
1.816 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| composite.tmac |
0.524 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| cp1047.tmac |
2.124 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| cs.tmac |
4.462 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| de.tmac |
4.493 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| den.tmac |
0.992 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| devtag.tmac |
3.692 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| doc-old.tmac |
35.439 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| doc.tmac |
72.077 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| eqnrc |
1.372 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| europs.tmac |
1.628 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| fallbacks.tmac |
1.33 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| fr.tmac |
5.175 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| html-end.tmac |
0.408 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| html.tmac |
16.017 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| hyphen.cs |
20.726 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphen.den |
37.473 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphen.det |
36.432 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphen.fr |
27.351 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphen.sv |
33.766 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphen.us |
27.207 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphenex.cs |
0.284 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphenex.det |
118.133 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| hyphenex.us |
15.311 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| ja.tmac |
1.656 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| latin1.tmac |
2.197 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| latin2.tmac |
2.285 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| latin5.tmac |
2.204 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| latin9.tmac |
2.197 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| man.tmac |
0.035 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| mandoc.tmac |
0.038 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| mdoc.tmac |
0.034 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| papersize.tmac |
3.97 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| pic.tmac |
0.114 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| ps.tmac |
20.073 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| psatk.tmac |
1.055 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| psold.tmac |
1.764 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| pspic.tmac |
4.618 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| safer.tmac |
0.191 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| sv.tmac |
4.036 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|
| trans.tmac |
4.442 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| troffrc |
1.354 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| troffrc-end |
1.118 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| tty-char.tmac |
5.062 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| tty.tmac |
1.516 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| unicode.tmac |
0.069 KB |
June 09 2014 20:17:14 |
0 / 0 |
0644 |
|
| www.tmac |
39.771 KB |
June 09 2014 20:17:15 |
0 / 0 |
0644 |
|