|
|
1.1 root 1: .if "\*(Bp"" .so /usr/lib/tmac/tmac.bits
2: .TH MBITS 6
3: .CT 1 writing_troff
4: .SH NAME
5: mbits \- macros to typeset bitmaps
6: .SH SYNOPSIS
7: .B troff
8: [
9: .I option ...
10: ]
11: .B -mbits
12: [
13: .I option ...
14: ]
15: .I file ...
16: .SH DESCRIPTION
17: These macros are used to typeset bitmaps.
18: They are compatible with other
19: .I troff
20: macro packages, so that bitmap figures may be included in documents.
21: .TP "\w'\f5.BM \fIf s dX dY\fR'u+1m"
22: \f5\&.BM \fIf\fR
23: Set the format for subsequent \&.BM requests to
24: .IR f .
25: The default is
26: .L b
27: for
28: .IR blitblt (9.1)
29: output.
30: The other possibility is
31: .L i
32: for faces and large icons in
33: .SM
34: ASCII
35: format.
36: .TP
37: \f5\&.BM \fIf s\fR
38: Insert the bitmap from file
39: .IR f ;
40: each pixel will be
41: .I s
42: basic units square.
43: The bitmap origin is placed at the current point, which
44: is left unchanged.
45: .TP
46: \f5\&.BM \fIf s dX dY\fR
47: Set the number registers
48: .IR dX " and " dY
49: to the width and height (in basic units) of the bitmap in file
50: .IR f ,
51: assuming pixel size
52: .IR s .
53: This form may be used to calculate positioning.
54: .SH EXAMPLES
55: .PP
56: This sequence centers the bitmap and spaces past it to continue
57: with the text:
58: .PP
59: .EX
60: \&.BM i
61: \&.BM /n/face/48x48x1/pjw 6 dX dY
62: \&.sp
63: \&.in (\en(.lu-\en(dXu)/2u
64: \&.BM /n/face/48x48x1/pjw 6
65: \&.in
66: \&.sp \en(dYu
67: .if n .ig
68: .sy echo >/tmp/pjw\n($$ -e '\
69: 0x0000,0x1FA0,0x0000,\\n0x0000,0x7FFC,0x0000,\\n0x0000,0xFEFF,0x0000,\\n\
70: 0x0001,0xBFBF,0xC000,\\n0x0001,0xEFFA,0xE000,\\n0x0002,0x00FF,0xF800,\\n\
71: 0x0002,0x007F,0xFF80,\\n0x0000,0x001F,0x7E00,\\n0x000C,0x001F,0xFFC0,'
72: .sy echo >>/tmp/pjw\n($$ -e '\
73: 0x0000,0x0015,0xFFC0,\\n0x0030,0x001F,0xFFF0,\\n0x0070,0x000F,0xFEB0,\\n\
74: 0x00C0,0x0007,0xFFF8,\\n0x00E0,0x0007,0xFFE8,\\n0x01E0,0x0003,0xFFF8,\\n\
75: 0x03C0,0x0001,0xFFF8,\\n0x03E0,0x0001,0xFFF8,\\n0x07C2,0x8000,0xFFF0,'
76: .sy echo >>/tmp/pjw\n($$ -e '\
77: 0x0FFA,0xF83F,0xBFF8,\\n0x0FE0,0x7C67,0xFFF8,\\n0x1FF1,0xEFF9,0x7FF8,\\n\
78: 0x1FF7,0xFFFF,0xFFF8,\\n0x1FF5,0xA4FF,0xFFF8,\\n0x1FD0,0x247F,0xFFF0,\\n\
79: 0x0FE0,0x8045,0xFFF0,\\n0x1FA0,0x0870,0x3FF0,\\n0x0320,0x0060,0xDFE0,'
80: .sy echo >>/tmp/pjw\n($$ -e '\
81: 0x0B80,0x1030,0x1F80,\\n0x0181,0x601F,0xF780,\\n0x0085,0x405A,0x5F00,\\n\
82: 0x0000,0x0BFB,0xFF00,\\n0x0180,0x1FE8,0xEE00,\\n0x0380,0x07F2,0xBE00,\\n\
83: 0x0182,0x03D5,0xEFC0,\\n0x0080,0x0075,0x7F80,\\n0x01C1,0xD5DD,0x4F80,'
84: .sy echo >>/tmp/pjw\n($$ -e '\
85: 0x00C1,0x57FF,0xFF80,\\n0x0040,0x0039,0x7F00,\\n0x0060,0x006B,0xCE00,\\n\
86: 0x0004,0x1FEB,0x6000,\\n0x0000,0x07FF,0xF800,\\n0x0002,0x0015,0xA000,\\n\
87: 0x0000,0x0057,0xC000,\\n0x0002,0x003F,0x4000,\\n0x0000,0x804B,0xC000,'
88: .sy echo >>/tmp/pjw\n($$ -e '\
89: 0x0002,0xBBFE,0x8000,\\n0x0000,0x8FFB,0xC000,\\n0x0001,0x7ABF,0xC000,'
90: .BM i
91: .BM /tmp/pjw\n($$ 6 dX dY
92: .sp
93: .in (\n(.lu-\n(dXu)/2u
94: .BM /tmp/pjw\n($$ 6
95: .sy rm -f /tmp/pjw\n($$
96: .in
97: .sp \n(dYu
98: ..
99: .EE
100: .SH FILES
101: .F /usr/lib/btroff
102: .SH SEE ALSO
103: .IR blitblt (9.1),
104: .IR troff (1),
105: .IR bitfile (9.5),
106: .IR ms (6)
107: .SH BUGS
108: At time of writing,
109: .I mbits
110: does not work with PostScript output devices.
111: See
112: .IR mpictures (6)
113: for an alternative.
114: .br
115: .B \&.BM
116: does not work inside a diversion.
117: .br
118: The concept of `pixel size' varies among typesetting devices.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.