eacccd37472c20576b403b071cbf2781ec3d92d3
[platform/upstream/groff.git] / man / groff_diff.man
1 '\" e
2 .\" The above line should force the use of eqn as a preprocessor
3 .TH GROFF_DIFF @MAN7EXT@ "@MDATE@" "Groff Version @VERSION@"
4 .SH NAME
5 groff_diff \- differences between GNU troff and classical troff
6 .
7 .\" groff_diff.man:
8 .\" Source file position: <groff_source>/man/groff_diff.man
9 .\" Installed position: <prefix>/share/man/man7/groff_diff.7
10 .
11 .
12 .de co
13 Copyright \[co] 1989-2014 Free Software Foundation, Inc.
14 .
15 .P
16 This file is part of groff, the GNU roff type-setting system.
17 .
18 It is the source of the man-page groff_diff(7).
19 .P
20 Permission is granted to copy, distribute and/or modify this document
21 under the terms of the GNU Free Documentation License, Version 1.3 or
22 any later version published by the Free Software Foundation; with no
23 Front-Cover Texts, and with no Back-Cover Texts.
24 .P
25 A copy of the Free Documentation License is included as a file called
26 FDL in the main directory of the groff source package, it is also
27 available in the internet at
28 .UR http://\:www.gnu.org/\:copyleft/\:fdl.html
29 GNU FDL license
30 .UE .
31 ..
32 .
33 .de au
34 This document was written by
35 .MT jjc@jclark.com
36 James Clark
37 .ME ,
38 was modified by
39 .MT wl@gnu.org
40 Werner Lemberg
41 .ME
42 and
43 .MT groff-bernd.warken-72@web.de
44 Bernd Warken
45 .ME .
46 ..
47 .
48 .
49 .\" --------------------------------------------------------------------
50 .\" Local definitions
51 .\" --------------------------------------------------------------------
52 .
53 .\" define a string tx for the TeX logo
54 .ie t .ds tx T\h'-.1667m'\v'.224m'E\v'-.224m'\h'-.125m'X
55 .el   .ds tx TeX
56 .
57 .
58 .\" from old groff_out.man
59 .ie \n(.g \
60 .  ds ic \/
61 .el \
62 .  ds ic \^
63 .
64 .\" ellipsis
65 .ds ellipsis \&.\|.\|.\&
66 .
67 .
68 .\" --------------------------------------------------------------------
69 .SH DESCRIPTION
70 .\" --------------------------------------------------------------------
71 .
72 This manual page describes the language differences between
73 .IR groff ,
74 the GNU
75 .I roff
76 text processing system, and the classical
77 .I roff
78 formatter of the freely available Unix\~7 of the 1970s, documented in
79 the
80 .I Troff User\[aq]s Manual
81 by
82 .I Ossanna
83 and
84 .IR Kernighan .
85 .
86 This includes the roff language as well as the intermediate output
87 format (troff output).
88 .
89 .
90 .P
91 The section
92 .I SEE ALSO
93 gives pointers to both the classical
94 .I roff
95 and the modern
96 .I groff
97 documentation.
98 .
99 .
100 .\" --------------------------------------------------------------------
101 .SH "GROFF LANGUAGE"
102 .\" --------------------------------------------------------------------
103 .
104 In this section, all additional features of
105 .I groff
106 compared to the classical Unix\~7
107 .I troff
108 are described in detail.
109 .
110 .
111 .\" --------------------------------------------------------------------
112 .SS "Long names"
113 .\" --------------------------------------------------------------------
114 .
115 The names of number registers, fonts, strings/\:macros/\:diversions,
116 special characters (glyphs), and colors can be of any length.
117 .
118 In escape sequences, additionally to the classical
119 \[oq]\fB(\fP\fIxx\fP\[cq] construction for a two-character glyph name,
120 you can use \[oq]\fB[\fP\,\fIxxx\/\fP\fB]\fP\[cq] for a name of
121 arbitrary length.
122 .
123 .TP
124 .BI \[rs][ xxx ]
125 Print the special character (glyph) called
126 .IR xxx .
127 .
128 .TP
129 .BI \[rs][ "comp1 comp2 \*[ellipsis]" ]
130 Print composite glyph consisting of multiple components.
131 .
132 Example: \[oq]\[rs][A\~ho]\[cq] is capital letter A with ogonek which
133 finally maps to glyph name \[oq]u0041_0328\[cq].
134 .
135 See the
136 .I groff info file
137 for details how a glyph name for a composite glyph is constructed, and
138 .BR groff_char (@MAN7EXT@)
139 for a list of glyph name components used in composite glyph names.
140 .
141 .TP
142 .BI \[rs]f[ xxx ]
143 Set font
144 .IR xxx .
145 .
146 Additionally,
147 .B \[rs]f[]
148 is a new syntax form equal to
149 .BR \[rs]fP ,
150 i.e., to return to the previous font.
151 .
152 .TP
153 .BI \[rs]*[ "xxx arg1 arg2 \*[ellipsis]" ]
154 Interpolate string
155 .IR xxx ,
156 taking
157 .IR arg1 ,
158 .IR arg2 ,
159 .IR \*[ellipsis] ,
160 as arguments.
161 .
162 .TP
163 .BI \[rs]n[ xxx ]
164 Interpolate number register
165 .IR xxx .
166 .
167 .
168 .\" --------------------------------------------------------------------
169 .SS "Fractional point sizes"
170 .\" --------------------------------------------------------------------
171 .
172 A
173 .I scaled point
174 is equal to
175 .B 1/sizescale
176 points, where
177 .B sizescale
178 is specified in the
179 .B DESC
180 file (1 by default).
181 .
182 There is a new scale indicator\~\c
183 .B z
184 that has the effect of multiplying by sizescale.
185 .
186 Requests and escape sequences in troff interpret arguments that
187 represent a point size as being in units of scaled points, but they
188 evaluate each such argument using a default scale indicator of\~\c
189 .BR z .
190 Arguments treated in this way are the argument to the
191 .B ps
192 request, the third argument to the
193 .B cs
194 request, the second and fourth arguments to the
195 .B tkf
196 request, the argument to the
197 .B \[rs]H
198 escape sequence, and those variants of the
199 .B \[rs]s
200 escape sequence that take a numeric expression as their argument.
201 .
202 .
203 .P
204 For example, suppose sizescale is 1000; then a scaled point is
205 equivalent to a millipoint; the call
206 .B .ps\ 10.25
207 is equivalent to
208 .B .ps\ 10.25z
209 and so sets the point size to 10250 scaled points, which is equal to
210 10.25 points.
211 .
212 .
213 .P
214 The number register
215 .B \[rs]n[.s]
216 returns the point size in points as decimal fraction.
217 .
218 There is also a new number register
219 .B \[rs]n[.ps]
220 that returns the point size in scaled points.
221 .
222 .
223 .P
224 It would make no sense to use the
225 .BR z \~\c
226 scale indicator in a numeric expression whose default scale indicator
227 was neither
228 .B u
229 nor\~\c
230 .BR z ,
231 and so
232 .B troff
233 disallows this.
234 .
235 Similarly it would make no sense to use a scaling indicator other than
236 .B z
237 or\~\c
238 .B u
239 in a numeric expression whose default scale indicator was\~\c
240 .BR z ,
241 and so
242 .B troff
243 disallows this as well.
244 .
245 .P
246 There is also new scale indicator\~\c
247 .B s
248 which multiplies by the number of units in a scaled point.
249 .
250 So, for example,
251 .B \[rs]n[.ps]s
252 is equal to
253 .BR 1m .
254 Be sure not to confuse the
255 .B s
256 and
257 .BR z \~\c
258 scale indicators.
259 .
260 .
261 .\" --------------------------------------------------------------------
262 .SS "Numeric expressions"
263 .\" --------------------------------------------------------------------
264 .
265 Spaces are permitted in a number expression within parentheses.
266 .
267 .
268 .P
269 .B M
270 indicates a scale of 100ths of an em.
271 .B f
272 indicates a scale of 65536 units, providing fractions for color
273 definitions with the
274 .B defcolor
275 request.
276 .
277 For example, 0.5f = 32768u.
278 .
279 .TP
280 .IB e1 >? e2
281 The maximum of
282 .I e1
283 and
284 .IR e2 .
285 .
286 .TP
287 .IB e1 <? e2
288 The minimum of
289 .I e1
290 and
291 .IR e2 .
292 .
293 .TP
294 .BI ( c ; e )
295 Evaluate
296 .I e
297 using
298 .I c
299 as the default scaling indicator.
300 .
301 If
302 .I c
303 is missing, ignore scaling indicators in the evaluation of\~\c
304 .IR e .
305 .
306 .
307 .\" --------------------------------------------------------------------
308 .SS "New escape sequences"
309 .\" --------------------------------------------------------------------
310 .
311 .TP
312 .BI \[rs]A' anything '
313 This expands to
314 .B 1
315 or\~\c
316 .BR 0 ,
317 depending on whether
318 .I anything
319 is or is not acceptable as the name of a string, macro, diversion, number
320 register, environment, font, or color.
321 .
322 It returns\~\c
323 .B 0
324 if
325 .I anything
326 is empty.
327 .
328 This is useful if you want to look up user input in some sort of
329 associative table.
330 .
331 .TP
332 .BI \[rs]B' anything '
333 This expands to
334 .B 1
335 or\~\c
336 .BR 0 ,
337 depending on whether
338 .I anything
339 is or is not a valid numeric expression.
340 .
341 It returns\~\c
342 .B 0
343 if
344 .I anything
345 is empty.
346 .
347 .TP
348 .BI \[rs]C' xxx '
349 Typeset glyph named
350 .IR xxx .
351 Normally it is more convenient to use
352 .BI \[rs][ xxx ]\f[R].
353 But
354 .B \[rs]C
355 has the advantage that it is compatible with recent versions of
356 .SM UNIX
357 and is available in compatibility mode.
358 .
359 .TP
360 .B \[rs]E
361 This is equivalent to an escape character, but it is not interpreted in
362 copy mode.
363 .
364 For example, strings to start and end superscripting could be defined
365 like this
366 .
367 .RS
368 .IP
369 .EX
370 \&.ds { \[rs]v'\-.3m'\[rs]s'\[rs]En[.s]*6u/10u'
371 \&.ds } \[rs]s0\[rs]v'.3m'
372 .EE
373 .RE
374 .
375 .IP
376 The use of
377 .B \[rs]E
378 ensures that these definitions work even if
379 .B \[rs]*{
380 gets interpreted in copy mode (for example, by being used in a macro
381 argument).
382 .RE
383 .
384 .TP
385 .BI \[rs]F f
386 .TQ
387 .BI \[rs]F( fm
388 .TQ
389 .BI \[rs]F[ fam ]
390 Change font family.
391 .
392 This is the same as the
393 .B fam
394 request.
395 .
396 .B \[rs]F[]
397 switches back to the previous font family (note that
398 .B \[rs]FP
399 won\[aq]t work; it selects font family \[oq]P\[cq] instead).
400 .
401 .TP
402 .BI \[rs]m x
403 .TQ
404 .BI \[rs]m( xx
405 .TQ
406 .BI \[rs]m[ xxx ]
407 Set drawing color.
408 .B \[rs]m[]
409 switches back to the previous color.
410 .
411 .TP
412 .BI \[rs]M x
413 .TQ
414 .BI \[rs]M( xx
415 .TQ
416 .BI \[rs]M[ xxx ]
417 Set background color for filled objects drawn with the
418 .BI \[rs]D' \*[ellipsis] '
419 commands.
420 .B \[rs]M[]
421 switches back to the previous color.
422 .
423 .TP
424 .BI \[rs]N' n '
425 Typeset the glyph with index\~\c
426 .I n
427 in the current font.
428 .IR n \~\c
429 can be any integer.
430 .
431 Most devices only have glyphs with indices between 0 and 255.
432 .
433 If the current font does not contain a glyph with that code,
434 special fonts are
435 .I not
436 searched.
437 .
438 The
439 .B \[rs]N
440 escape sequence can be conveniently used in conjunction with the
441 .B char
442 request, for example
443 .
444 .RS
445 .IP
446 .EX
447 \&.char \[rs][phone] \[rs]f(ZD\[rs]N'37'
448 .EE
449 .RE
450 .
451 .IP
452 The index of each glyph is given in the fourth column in the font
453 description file after the
454 .B charset
455 command.
456 .
457 It is possible to include unnamed glyphs in the font description
458 file by using a name of
459 .BR \-\-\- ;
460 the
461 .B \[rs]N
462 escape sequence is the only way to use these.
463 .
464 .TP
465 .BI \[rs]O n
466 .TQ
467 .BI \[rs]O[ n ]
468 Suppress troff output.
469 .
470 The escapes
471 .BR \[rs]O2 ,
472 .BR \[rs]O3 ,
473 .BR \[rs]O4 ,
474 and
475 .B \[rs]O5
476 are intended for internal use by
477 .BR \%grohtml .
478 .
479 .RS
480 .TP
481 .B \[rs]O0
482 Disable any ditroff glyphs from being emitted to the device driver,
483 provided that the escape occurs at the outer level (see
484 .B \[rs]O3
485 and
486 .BR \[rs]O4 ).
487 .
488 .TP
489 .B \[rs]O1
490 Enable output of glyphs, provided that the escape occurs at the outer
491 level.
492 .IP
493 .B \[rs]O0
494 and
495 .B \[rs]O1
496 also reset the registers
497 .BR \[rs]n[opminx] ,
498 .BR \[rs]n[opminy] ,
499 .BR \[rs]n[opmaxx] ,
500 and
501 .B \[rs]n[opmaxy]
502 to\~\-1.
503 .
504 These four registers mark the top left and bottom right hand corners
505 of a box which encompasses all written glyphs.
506 .
507 .TP
508 .B \[rs]O2
509 Provided that the escape occurs at the outer level, enable output of
510 glyphs and also write out to stderr the page number and four registers
511 encompassing the glyphs previously written since the last call to
512 .BR \[rs]O .
513 .
514 .TP
515 .B \[rs]O3
516 Begin a nesting level.
517 .
518 At start-up,
519 .B troff
520 is at outer level.
521 .
522 This is really an internal mechanism for
523 .B \%grohtml
524 while producing images.
525 .
526 They are generated by running the troff source through
527 .B troff
528 to the postscript device and
529 .B ghostscript
530 to produce images in PNG format.
531 .
532 The
533 .B \[rs]O3
534 escape starts a new page if the device is not html (to reduce the
535 possibility of images crossing a page boundary).
536 .
537 .TP
538 .B \[rs]O4
539 End a nesting level.
540 .
541 .TP
542 .BI \[rs]O5[ Pfilename ]
543 This escape is
544 .B \%grohtml
545 specific.
546 .
547 Provided that this escape occurs at the outer nesting level, write
548 .I filename
549 to stderr.
550 .
551 The position of the image,
552 .IR P ,
553 must be specified and must be one of
554 .BR l ,
555 .BR r ,
556 .BR c ,
557 or
558 .B i
559 (left, right, centered, inline).
560 .
561 .I filename
562 is associated with the production of the next inline image.
563 .RE
564 .
565 .TP
566 .BI \[rs]R' name\ \[+-]n '
567 This has the same effect as
568 .
569 .RS
570 .IP
571 .BI .nr\  name\ \[+-]n
572 .RE
573 .
574 .TP
575 .BI \[rs]s( nn
576 .TQ
577 .BI \[rs]s\[+-]( nn
578 Set the point size to
579 .I nn
580 points;
581 .I nn
582 must be exactly two digits.
583 .
584 .TP
585 .BI \[rs]s[\[+-] n ]
586 .TQ
587 .BI \[rs]s\[+-][ n ]
588 .TQ
589 .BI \[rs]s'\[+-] n '
590 .TQ
591 .BI \[rs]s\[+-]' n '
592 Set the point size to
593 .I n
594 scaled points;
595 .I n
596 is a numeric expression with a default scale indicator of\~\c
597 .BR z .
598 .
599 .TP
600 .BI \[rs]V x
601 .TQ
602 .BI \[rs]V( xx
603 .TQ
604 .BI \[rs]V[ xxx ]
605 Interpolate the contents of the environment variable
606 .IR xxx ,
607 as returned by
608 .BR getenv (3).
609 .B \[rs]V
610 is interpreted in copy mode.
611 .
612 .TP
613 .BI \[rs]Y x
614 .TQ
615 .BI \[rs]Y( xx
616 .TQ
617 .BI \[rs]Y[ xxx ]
618 This is approximately equivalent to
619 .BI \[rs]X'\[rs]*[ xxx ]'\f[R].
620 However the contents of the string or macro
621 .I xxx
622 are not interpreted; also it is permitted for
623 .I xxx
624 to have been defined as a macro and thus contain newlines (it is not
625 permitted for the argument to
626 .B \[rs]X
627 to contain newlines).
628 .
629 The inclusion of newlines requires an extension to the UNIX troff
630 output format, and confuses drivers that do not know about this
631 extension.
632 .
633 .TP
634 .BI \[rs]Z' anything '
635 Print anything and then restore the horizontal and vertical position;
636 .I anything
637 may not contain tabs or leaders.
638 .
639 .TP
640 .B \[rs]$0
641 The name by which the current macro was invoked.
642 .
643 The
644 .B als
645 request can make a macro have more than one name.
646 .
647 .TP
648 .B \[rs]$*
649 In a macro or string, the concatenation of all the arguments separated
650 by spaces.
651 .
652 .TP
653 .B \[rs]$@
654 In a macro or string, the concatenation of all the arguments with each
655 surrounded by double quotes, and separated by spaces.
656 .
657 .TP
658 .B \[rs]$^
659 In a macro, the representation of all parameters as if they were an
660 argument to the
661 .B ds
662 request.
663 .
664 .TP
665 .BI \[rs]$( nn
666 .TQ
667 .BI \[rs]$[ nnn ]
668 In a macro or string, this gives the
669 .IR nn -th
670 or
671 .IR nnn -th
672 argument.
673 .
674 Macros and strings can have an unlimited number of arguments.
675 .
676 .TP
677 .BI \[rs]? anything \[rs]?
678 When used in a diversion, this transparently embeds
679 .I anything
680 in the diversion.
681 .I anything
682 is read in copy mode.
683 .
684 When the diversion is reread,
685 .I anything
686 is interpreted.
687 .I anything
688 may not contain newlines; use
689 .B \[rs]!\&
690 if you want to embed newlines in a diversion.
691 .
692 The escape sequence
693 .B \[rs]?\&
694 is also recognized in copy mode and turned into a single internal
695 code; it is this code that terminates
696 .IR anything .
697 Thus
698 .
699 .RS
700 .IP
701 .EX
702 .ne 14v+\n(.Vu
703 \&.nr x 1
704 \&.nf
705 \&.di d
706 \&\[rs]?\[rs]\[rs]?\[rs]\[rs]\[rs]\[rs]?\[rs]\[rs]\[rs]\[rs]\[rs]\[rs]\[rs]\c
707 \&\[rs]nx\[rs]\[rs]\[rs]\[rs]?\[rs]\[rs]?\[rs]?
708 \&.di
709 \&.nr x 2
710 \&.di e
711 \&.d
712 \&.di
713 \&.nr x 3
714 \&.di f
715 \&.e
716 \&.di
717 \&.nr x 4
718 \&.f
719 .EE
720 .RE
721 .
722 .IP
723 prints\~\c
724 .BR 4 .
725 .
726 .TP
727 .B \[rs]/
728 This increases the width of the preceding glyph so that the
729 spacing between that glyph and the following glyph is
730 correct if the following glyph is a roman glyph.
731 .
732 .if t \{\
733 .  nop For example, if an italic\~f is immediately followed by a roman
734 .  nop right parenthesis, then in many fonts the top right portion of
735 .  nop the\~f overlaps the top left of the right parenthesis
736 .  nop producing \f[I]f\f[R]), which is ugly.
737 .  nop Inserting
738 .  B \[rs]/
739 .  nop produces
740 .  ie \n(.g \f[I]f\/\f[R])
741 .  el       \f[I]f\|\f[R])
742 .  nop and avoids this problem.
743 .\}
744 It is a good idea to use this escape sequence whenever an italic
745 glyph is immediately followed by a roman glyph without any
746 intervening space.
747 .
748 .TP
749 .B \[rs],
750 This modifies the spacing of the following glyph so that the
751 spacing between that glyph and the preceding glyph is
752 correct if the preceding glyph is a roman glyph.
753 .
754 .if t \{\
755 .  nop For example, inserting
756 .  B \[rs],
757 .  nop between the parenthesis and the\~f changes
758 .  nop \f[R](\f[I]f\f[R] to
759 .  ie \n(.g \f[R](\,\f[I]f\f[R].
760 .  el       \f[R](\^\f[I]f\f[R].
761 .\}
762 It is a good idea to use this escape sequence whenever a roman
763 glyph is immediately followed by an italic glyph without any
764 intervening space.
765 .
766 .TP
767 .B \[rs])
768 Like
769 .B \[rs]&
770 except that it behaves like a character declared with the
771 .B cflags
772 request to be transparent for the purposes of end-of-sentence
773 recognition.
774 .
775 .TP
776 .B \[rs]\[ti]
777 This produces an unbreakable space that stretches like a normal
778 inter-word space when a line is adjusted.
779 .
780 .TP
781 .B \[rs]:
782 This causes the insertion of a zero-width break point.
783 .
784 It is equal to
785 .B \[rs]%
786 within a word but without insertion of a soft hyphen glyph.
787 .
788 .TP
789 .B \[rs]#
790 Everything up to and including the next newline is ignored.
791 .
792 This is interpreted in copy mode.
793 .
794 It is like
795 .B \[rs]"
796 except that
797 .B \[rs]"
798 does not ignore the terminating newline.
799 .
800 .
801 .\" --------------------------------------------------------------------
802 .SS "New requests"
803 .\" --------------------------------------------------------------------
804 .
805 .TP
806 .BI .aln\  xx\ yy
807 Create an alias
808 .I xx
809 for number register object named
810 .IR yy .
811 The new name and the old name are exactly equivalent.
812 .
813 If
814 .I yy
815 is undefined, a warning of type
816 .B reg
817 is generated, and the request is ignored.
818 .
819 .TP
820 .BI .als\  xx\ yy
821 Create an alias
822 .I xx
823 for request, string, macro, or diversion object named
824 .IR yy .
825 .
826 The new name and the old name are exactly equivalent (it is
827 similar to a hard rather than a soft link).
828 .
829 If
830 .I yy
831 is undefined, a warning of type
832 .B mac
833 is generated, and the request is ignored.
834 .
835 The
836 .BR de ,
837 .BR am ,
838 .BR di ,
839 .BR da ,
840 .BR ds ,
841 and
842 .B as
843 requests only create a new object if the name of the macro, diversion
844 or string is currently undefined or if it is defined to be a
845 request; normally they modify the value of an existing object.
846 .
847 .TP
848 .BI .am1\  xx\ yy
849 Similar to
850 .BR .am ,
851 but compatibility mode is switched off during execution.
852 .
853 To be more precise, a \[oq]compatibility save\[cq] token is inserted
854 at the beginning of the macro addition, and a \[oq]compatibility
855 restore\[cq] token at the end.
856 .
857 As a consequence, the requests
858 .BR am ,
859 .BR am1 ,
860 .BR de ,
861 and
862 .B de1
863 can be intermixed freely since the compatibility save/\:restore tokens
864 only affect the macro parts defined by
865 .B .am1
866 and
867 .BR .ds1 .
868 .
869 .TP
870 .BI .ami\  xx\ yy
871 Append to macro indirectly.
872 .
873 See the
874 .B dei
875 request below for more information.
876 .
877 .TP
878 .BI .ami1\  xx\ yy
879 Same as the
880 .B ami
881 request but compatibility mode is switched off during execution.
882 .
883 .TP
884 .BI .as1\  xx\ yy
885 Similar to
886 .BR .as ,
887 but compatibility mode is switched off during expansion.
888 .
889 To be more precise, a \[oq]compatibility save\[cq] token is inserted
890 at the beginning of the string, and a \[oq]compatibility restore\[cq]
891 token at the end.
892 .
893 As a consequence, the requests
894 .BR as ,
895 .BR as1 ,
896 .BR ds ,
897 and
898 .B ds1
899 can be intermixed freely since the compatibility save/\:restore tokens
900 only affect the (sub)strings defined by
901 .B as1
902 and
903 .BR ds1 .
904 .
905 .TP
906 .BI .asciify\  xx
907 This request \[oq]unformats\[cq] the diversion
908 .I xx
909 in such a way that
910 .SM ASCII
911 and space characters (and some escape sequences) that were formatted
912 and diverted into
913 .I xx
914 are treated like ordinary input characters when
915 .I xx
916 is reread.
917 Useful for diversions in conjunction with the
918 .B writem
919 request.
920 .
921 It can be also used for gross hacks; for example, this
922 .
923 .RS
924 .IP
925 .EX
926 .ne 7v+\n(.Vu
927 \&.tr @.
928 \&.di x
929 \&@nr n 1
930 \&.br
931 \&.di
932 \&.tr @@
933 \&.asciify x
934 \&.x
935 .EE
936 .RE
937 .
938 .IP
939 sets register\~\c
940 .B n
941 to\~1.
942 .
943 Note that glyph information (font, font size, etc.\&) is not preserved;
944 use
945 .B .unformat
946 instead.
947 .
948 .TP
949 .B .backtrace
950 Print a backtrace of the input stack on stderr.
951 .
952 .TP
953 .BI .blm\  xx
954 Set the blank line macro to
955 .IR xx .
956 If there is a blank line macro, it is invoked when a blank line
957 is encountered instead of the usual troff behaviour.
958 .
959 .TP
960 .BI .box\  xx
961 .TQ
962 .BI .boxa\  xx
963 These requests are similar to the
964 .B di
965 and
966 .B da
967 requests with the exception that a partially filled line does not
968 become part of the diversion (i.e., the diversion always starts with a
969 new line) but is restored after ending the diversion, discarding the
970 partially filled line which possibly comes from the diversion.
971 .
972 .TP
973 .B .break
974 Break out of a while loop.
975 .
976 See also the
977 .B while
978 and
979 .B continue
980 requests.
981 .
982 Be sure not to confuse this with the
983 .B br
984 request.
985 .
986 .TP
987 .B .brp
988 This is the same as
989 .BR \[rs]p .
990 .
991 .TP
992 .BI .cflags\  "n c1 c2 \*[ellipsis]"
993 Characters
994 .IR c1 ,
995 .IR c2 ,
996 .IR \*[ellipsis] ,
997 have properties determined by
998 .IR n ,
999 which is ORed from the following:
1000 .
1001 .RS
1002 .IP 1
1003 The character ends sentences (initially characters
1004 .B .?!\&
1005 have this property).
1006 .
1007 .IP 2
1008 Lines can be broken before the character (initially no characters have
1009 this property); a line is not broken at a character with this property
1010 unless the characters on each side both have non-zero hyphenation
1011 codes.
1012 This can be overridden with value 64.
1013 .
1014 .IP 4
1015 Lines can be broken after the character (initially characters
1016 .B \-\[rs][hy]\[rs][em]
1017 have this property); a line is not broken at a character with this
1018 property unless the characters on each side both have non-zero
1019 hyphenation codes.
1020 This can be overridden with value 64.
1021 .
1022 .IP 8
1023 The glyph associated with this character overlaps horizontally
1024 (initially characters
1025 .B \[rs][ul]\[rs][rn]\[rs][ru]\[rs][radicalex]\[rs][sqrtex]
1026 have this property).
1027 .
1028 .IP 16
1029 The glyph associated with this character overlaps vertically
1030 (initially glyph
1031 .B \[rs][br]
1032 has this property).
1033 .
1034 .IP 32
1035 An end-of-sentence character followed by any number of characters with
1036 this property is treated as the end of a sentence if followed by a
1037 newline or two spaces; in other words the character is transparent for
1038 the purposes of end-of-sentence recognition; this is the same as having
1039 a zero space factor in \*[tx] (initially characters
1040 .B \[dq]')]*\[rs][dg]\[rs][rq]\[rs][cq]
1041 have this property).
1042 .
1043 .IP 64
1044 Ignore hyphenation code values of the surrounding characters.
1045 Use this in combination with values 2 and\~4 (initially no characters
1046 have this property).
1047 .
1048 .IP 128
1049 Prohibit a line break before the character, but allow a line break after the
1050 character.
1051 This works only in combination with flags 256 and 512 and has no effect
1052 otherwise.
1053 .
1054 .IP 256
1055 Prohibit a line break after the character, but allow a line break before
1056 the character.
1057 This works only in combination with flags 128 and 512 and has no effect
1058 otherwise.
1059 .
1060 .IP 512
1061 Allow line break before or after the character.
1062 This works only in combination with flags 128 and 256 and has no effect
1063 otherwise.
1064 .RE
1065 .
1066 .IP
1067 Contrary to flag values 2 and\~4, the flags 128, 256, and 512 work
1068 pairwise.
1069 .
1070 If, for example, the left character has value 512, and the right
1071 character 128, no line break gets inserted.  If we use value\~6
1072 instead for the left character, a line break after the character
1073 can\[aq]t be suppressed since the right neighbour character
1074 doesn\[aq]t get examined.
1075 .
1076 .TP
1077 .BI .char\  c\ string
1078 [This request can both define characters and glyphs.]
1079 .
1080 .IP
1081 Define entity\~\c
1082 .I c
1083 to be
1084 .IR string .
1085 .
1086 To be more precise, define (or even override) a groff entity which
1087 can be accessed with name\~\c
1088 .I c
1089 on the input side, and which uses
1090 .I string
1091 on the output side.
1092 .
1093 Every time glyph\~\c
1094 .I c
1095 needs to be printed,
1096 .I string
1097 is processed in a temporary environment and the result is
1098 wrapped up into a single object.
1099 .
1100 Compatibility mode is turned off and the escape character is
1101 set to\~\c
1102 .B \[rs]
1103 while
1104 .I string
1105 is being processed.
1106 .
1107 Any emboldening, constant spacing or track kerning is applied to
1108 this object rather than to individual glyphs in
1109 .IR string .
1110 .
1111 .IP
1112 A groff object defined by this request can be used just like a
1113 normal glyph provided by the output device.
1114 .
1115 In particular other characters can be translated to it with the
1116 .B tr
1117 request; it can be made the leader glyph by the
1118 .B lc
1119 request; repeated patterns can be drawn with the glyph using the
1120 .B \[rs]l
1121 and
1122 .B \[rs]L
1123 escape sequences; words containing\~\c
1124 .I c
1125 can be hyphenated correctly, if the
1126 .B hcode
1127 request is used to give the object a hyphenation code.
1128 .
1129 .IP
1130 There is a special anti-recursion feature: Use of glyph within the
1131 glyph\[aq]s definition is handled like normal glyphs not defined with
1132 .BR char .
1133 .IP
1134 A glyph definition can be removed with the
1135 .B rchar
1136 request.
1137 .
1138 .TP
1139 .BI .chop\  xx
1140 Chop the last element off macro, string, or diversion
1141 .IR xx .
1142 This is useful for removing the newline from the end of diversions
1143 that are to be interpolated as strings.
1144 .
1145 .TP
1146 .BI .class\  "name c1 c2 \*[ellipsis]"
1147 Assign
1148 .I name
1149 to a set of characters
1150 .IR c1 ,
1151 .IR c2 ,
1152 .IR \*[ellipsis] ,
1153 so that they can be referred to from other requests easily (currently
1154 .B .cflags
1155 only).
1156 .
1157 Character ranges (indicated by an intermediate \[oq]\-\[cq]) and
1158 nested classes are possible also.
1159 .
1160 This is useful to assign properties to a large set of characters.
1161 .
1162 .TP
1163 .BI .close\  stream
1164 Close the stream named
1165 .IR stream ;
1166 .I stream
1167 will no longer be an acceptable argument to the
1168 .B write
1169 request.
1170 .
1171 See the
1172 .B open
1173 request.
1174 .
1175 .TP
1176 .BI .composite\  glyph1\ glyph2
1177 Map glyph name
1178 .I glyph1
1179 to glyph name
1180 .I glyph2
1181 if it is used in
1182 .BI \[rs][ \*[ellipsis] ]
1183 with more than one component.
1184 .
1185 .TP
1186 .B .continue
1187 Finish the current iteration of a while loop.
1188 .
1189 See also the
1190 .B while
1191 and
1192 .B break
1193 requests.
1194 .
1195 .TP
1196 .BI .color\  n
1197 If
1198 .I n
1199 is non-zero or missing, enable colors (this is the default), otherwise
1200 disable them.
1201 .
1202 .TP
1203 .BI .cp\  n
1204 If
1205 .I n
1206 is non-zero or missing, enable compatibility mode, otherwise disable
1207 it.
1208 .
1209 In compatibility mode, long names are not recognized, and the
1210 incompatibilities caused by long names do not arise.
1211 .
1212 .TP
1213 .BI .defcolor\  xxx\ scheme\ color_components
1214 Define color
1215 .IR xxx .
1216 .I scheme
1217 can be one of the following values:
1218 .B rgb
1219 (three components),
1220 .B cmy
1221 (three components),
1222 .B cmyk
1223 (four components), and
1224 .B gray
1225 or
1226 .B grey
1227 (one component).
1228 .
1229 Color components can be given either as a hexadecimal string or as
1230 positive decimal integers in the range 0\[en]65535.
1231 .
1232 A hexadecimal string contains all color components concatenated; it
1233 must start with either
1234 .B #
1235 or
1236 .BR ## .
1237 The former specifies hex values in the range 0\[en]255 (which are
1238 internally multiplied by\~257), the latter in the range 0\[en]65535.
1239 .
1240 Examples: #FFC0CB (pink), ##ffff0000ffff (magenta).
1241 .
1242 A new scaling indicator\~\c
1243 .B f
1244 has been introduced which multiplies its value by\~65536; this makes
1245 it convenient to specify color components as fractions in the range 0
1246 to\~1.
1247 .
1248 Example:
1249 .
1250 .RS
1251 .IP
1252 .EX
1253 \&.defcolor darkgreen rgb 0.1f 0.5f 0.2f
1254 .EE
1255 .RE
1256 .
1257 .IP
1258 Note that
1259 .B f
1260 is the default scaling indicator for the
1261 .B defcolor
1262 request, thus the above statement is equivalent to
1263 .
1264 .RS
1265 .IP
1266 .EX
1267 \&.defcolor darkgreen rgb 0.1 0.5 0.2
1268 .EE
1269 .RE
1270 .
1271 .IP
1272 The color named
1273 .B default
1274 (which is device-specific) can\[aq]t be redefined.
1275 .
1276 It is possible that the default color for
1277 .B \[rs]M
1278 and
1279 .B \[rs]m
1280 is not the same.
1281 .
1282 .TP
1283 .BI .de1\  xx\ yy
1284 Similar to
1285 .BR .de ,
1286 but compatibility mode is switched off during execution.
1287 .
1288 On entry, the current compatibility mode is saved and restored at exit.
1289 .
1290 .TP
1291 .BI .dei\  xx\ yy
1292 Define macro indirectly.
1293 .
1294 The following example
1295 .
1296 .RS
1297 .IP
1298 .ne 2v+\n(.Vu
1299 .EX
1300 \&.ds xx aa
1301 \&.ds yy bb
1302 \&.dei xx yy
1303 .EE
1304 .RE
1305 .
1306 .IP
1307 is equivalent to
1308 .
1309 .RS
1310 .IP
1311 .EX
1312 \&.de aa bb
1313 .EE
1314 .RE
1315 .
1316 .TP
1317 .BI .dei1\  xx\ yy
1318 Similar to the
1319 .B dei
1320 request but compatibility mode is switched off during execution.
1321 .
1322 .TP
1323 .BI .device\  anything
1324 This is (almost) the same as the
1325 .B \[rs]X
1326 escape.
1327 .I anything
1328 is read in copy mode; a leading\~\c
1329 .B \[dq]
1330 is stripped.
1331 .
1332 .TP
1333 .BI .devicem\  xx
1334 This is the same as the
1335 .B \[rs]Y
1336 escape (to embed the contents of a macro into the intermediate
1337 output preceded with \[oq]x\~X\[cq]).
1338 .
1339 .TP
1340 .BI .do\  xxx
1341 Interpret
1342 .I .xxx
1343 with compatibility mode disabled.
1344 .
1345 For example,
1346 .
1347 .RS
1348 .
1349 .IP
1350 .EX
1351 \&.do fam T
1352 .EE
1353 .
1354 .P
1355 would have the same effect as
1356 .
1357 .IP
1358 .EX
1359 \&.fam T
1360 .EE
1361 .
1362 .P
1363 except that it would work even if compatibility mode had been enabled.
1364 .
1365 Note that the previous compatibility mode is restored before any files
1366 sourced by
1367 .I xxx
1368 are interpreted.
1369 .
1370 .RE
1371 .
1372 .TP
1373 .BI .ds1\  xx\ yy
1374 Similar to
1375 .BR .ds ,
1376 but compatibility mode is switched off during expansion.
1377 .
1378 To be more precise, a \[oq]compatibility save\[cq] token is inserted
1379 at the beginning of the string, and a \[oq]compatibility restore\[cq]
1380 token at the end.
1381 .
1382 .TP
1383 .B .ecs
1384 Save current escape character.
1385 .
1386 .TP
1387 .B .ecr
1388 Restore escape character saved with
1389 .BR ecs .
1390 Without a previous call to
1391 .BR ecs ,
1392 .RB \[oq] \[rs] \[cq]
1393 will be the new escape character.
1394 .
1395 .TP
1396 .BI .evc\  xx
1397 Copy the contents of environment
1398 .I xx
1399 to the current environment.
1400 .
1401 No pushing or popping of environments is done.
1402 .
1403 .TP
1404 .BI .fam\  xx
1405 Set the current font family to
1406 .IR xx .
1407 The current font family is part of the current environment.
1408 If
1409 .I xx
1410 is missing, switch back to previous font family.
1411 .
1412 The value at start-up is \[oq]T\[cq].
1413 .
1414 See the description of the
1415 .B sty
1416 request for more information on font families.
1417 .
1418 .TP
1419 .BI .fchar\  c\ string
1420 Define fallback character (or glyph)\~\c
1421 .I c
1422 to be
1423 .IR string .
1424 .
1425 The syntax of this request is the same as the
1426 .B char
1427 request; the only difference is that a glyph defined with
1428 .B char
1429 hides the glyph with the same name in the current font, whereas a
1430 glyph defined with
1431 .B fchar
1432 is checked only if the particular glyph isn\[aq]t found in the current
1433 font.
1434 .
1435 This test happens before checking special fonts.
1436 .
1437 .TP
1438 .BI .fcolor\  c
1439 Set the fill color to\~\c
1440 .IR c .
1441 If
1442 .I c
1443 is missing,
1444 switch to the previous fill color.
1445 .
1446 .TP
1447 .BI .fschar\  f\ c\ string
1448 Define fallback character (or glyph)\~\c
1449 .I c
1450 for font\~\c
1451 .I f
1452 to be
1453 .IR string .
1454 .
1455 The syntax of this request is the same as the
1456 .B char
1457 request (with an additional argument to specify the font); a glyph
1458 defined with
1459 .B fschar
1460 is searched after the list of fonts declared with the
1461 .B fspecial
1462 request but before the list of fonts declared with
1463 .BR .special .
1464 .
1465 .TP
1466 .BI .fspecial\  "f s1 s2 \*[ellipsis]"
1467 When the current font is\~\c
1468 .IR f ,
1469 fonts
1470 .IR s1 ,
1471 .IR s2 ,
1472 .IR \*[ellipsis] ,
1473 are special, that is, they are searched for glyphs not in
1474 the current font.
1475 .
1476 Any fonts specified in the
1477 .B special
1478 request are searched after fonts specified in the
1479 .B fspecial
1480 request.
1481 .
1482 Without argument, reset the list of global special fonts to be empty.
1483 .
1484 .TP
1485 .BI .ftr\  f\ g
1486 Translate font\~\c
1487 .I f
1488 to\~\c
1489 .IR g .
1490 Whenever a font named\~\c
1491 .I f
1492 is referred to in an
1493 .B \[rs]f
1494 escape sequence, in the
1495 .B F
1496 and
1497 .B S
1498 conditional operators, or in the
1499 .BR ft ,
1500 .BR ul ,
1501 .BR bd ,
1502 .BR cs ,
1503 .BR tkf ,
1504 .BR special ,
1505 .BR fspecial ,
1506 .BR fp ,
1507 or
1508 .BR sty
1509 requests, font\~\c
1510 .I g
1511 is used.
1512 If
1513 .I g
1514 is missing, or equal to\~\c
1515 .I f
1516 then font\~\c
1517 .I f
1518 is not translated.
1519 .
1520 .TP
1521 .BI .fzoom\  f\ zoom
1522 Set zoom factor
1523 .I zoom
1524 for font\~\c
1525 .IR f .
1526 .I zoom
1527 must a non-negative integer multiple of 1/1000th.
1528 If it is missing or is equal to zero, it means the same as 1000, namely no
1529 magnification.
1530 .IR f \~\c
1531 must be a real font name, not a style.
1532 .
1533 .TP
1534 .BI .gcolor\  c
1535 Set the glyph color to\~\c
1536 .IR c .
1537 If
1538 .I c
1539 is missing,
1540 switch to the previous glyph color.
1541 .
1542 .TP
1543 .BI .hcode\  "c1 code1 c2 code2 \*[ellipsis]"
1544 Set the hyphenation code of character
1545 .I c1
1546 to
1547 .I code1
1548 and that of
1549 .I c2
1550 to
1551 .IR code2 ,
1552 and so on.
1553 A hyphenation code must be a single input character (not a special
1554 character) other than a digit or a space.
1555 .
1556 Initially each lower-case letter \%a\[en]z has a hyphenation code, which is
1557 itself, and each upper-case letter \%A\[en]Z has a hyphenation code which is
1558 the lower-case version of itself.
1559 .
1560 See also the
1561 .B hpf
1562 request.
1563 .
1564 .TP
1565 .BI .hla\  lang
1566 Set the current hyphenation language to
1567 .IR lang .
1568 Hyphenation exceptions specified with the
1569 .B hw
1570 request and hyphenation patterns specified with the
1571 .B hpf
1572 request are both associated with the current hyphenation language.
1573 .
1574 The
1575 .B hla
1576 request is usually invoked by the
1577 .B troffrc
1578 file to set up a default language.
1579 .
1580 .TP
1581 .BI .hlm\  n
1582 Set the maximum number of consecutive hyphenated lines to\~\c
1583 .IR n .
1584 If
1585 .I n
1586 is negative, there is no maximum.
1587 .
1588 The default value is\~\-1.
1589 .
1590 This value is associated with the current environment.
1591 .
1592 Only lines output from an environment count towards the maximum
1593 associated with that environment.
1594 .
1595 Hyphens resulting from
1596 .B \[rs]%
1597 are counted; explicit hyphens are not.
1598 .
1599 .TP
1600 .BI .hpf\  file
1601 Read hyphenation patterns from
1602 .IR file ;
1603 this is searched for in the same way that
1604 .IB name .tmac
1605 is searched for when the
1606 .BI \-m name
1607 option is specified.
1608 .
1609 It should have the same format as (simple) \*[tx] patterns files.
1610 .
1611 More specifically, the following scanning rules are implemented.
1612 .
1613 .RS
1614 .IP \[bu]
1615 A percent sign starts a comment (up to the end of the line) even if
1616 preceded by a backslash.
1617 .
1618 .IP \[bu]
1619 No support for \[oq]digraphs\[cq] like
1620 .BR \[rs]$ .
1621 .
1622 .IP \[bu]
1623 .BI ^^ xx
1624 .RI ( x
1625 is 0\[en]9 or a\[en]f) and
1626 .BI ^^ x
1627 (character code of\~\c
1628 .I x
1629 in the range 0\[en]127) are recognized; other use of\~\c
1630 .B ^
1631 causes an error.
1632 .
1633 .IP \[bu]
1634 No macro expansion.
1635 .
1636 .IP \[bu]
1637 .B hpf
1638 checks for the expression
1639 .BR \[rs]patterns{ \*[ellipsis] }
1640 (possibly with whitespace before and after the braces).
1641 .
1642 Everything between the braces is taken as hyphenation patterns.
1643 .
1644 Consequently,
1645 .BR { \~\c
1646 and\~\c
1647 .B }
1648 are not allowed in patterns.
1649 .
1650 .IP \[bu]
1651 Similarly,
1652 .BR \[rs]hyphenation{ \*[ellipsis] }
1653 gives a list of hyphenation exceptions.
1654 .
1655 .IP \[bu]
1656 .B \[rs]endinput
1657 is recognized also.
1658 .
1659 .IP \[bu]
1660 For backwards compatibility, if
1661 .B \[rs]patterns
1662 is missing, the whole file is treated as a list of hyphenation patterns
1663 (only recognizing the
1664 .BR % \~\c
1665 character as the start of a comment).
1666 .RE
1667 .
1668 .IP
1669 Use the
1670 .B hpfcode
1671 request to map the encoding used in hyphenation patterns files to
1672 .BR groff \[aq]s
1673 input encoding.
1674 .
1675 By default, everything maps to itself except letters \[oq]A\[cq] to
1676 \[oq]Z\[cq] which map to \[oq]a\[cq] to \[oq]z\[cq].
1677 .
1678 .IP
1679 The set of hyphenation patterns is associated with the current language
1680 set by the
1681 .B hla
1682 request.
1683 .
1684 The
1685 .B hpf
1686 request is usually invoked by the
1687 .B troffrc
1688 file; a second call replaces the old patterns with the new ones.
1689 .
1690 .TP
1691 .BI .hpfa\  file
1692 The same as
1693 .B hpf
1694 except that the hyphenation patterns from
1695 .I file
1696 are appended to the patterns already loaded in the current language.
1697 .
1698 .TP
1699 .BI .hpfcode\  "a b c d \*[ellipsis]"
1700 After reading a hyphenation patterns file with the
1701 .B hpf
1702 or
1703 .B hpfa
1704 request, convert all characters with character code\~\c
1705 .I a
1706 in the recently read patterns to character code\~\c
1707 .IR b ,
1708 character code\~\c
1709 .I c
1710 to\~\c
1711 .IR d ,
1712 etc.
1713 .
1714 Initially, all character codes map to themselves.
1715 .
1716 The arguments of
1717 .B hpfcode
1718 must be integers in the range 0 to\~255.
1719 .
1720 Note that it is even possible to use character codes which are invalid in
1721 .B groff
1722 otherwise.
1723 .
1724 .TP
1725 .BI .hym\  n
1726 Set the
1727 .I hyphenation margin
1728 to\~\c
1729 .IR n :
1730 when the current adjustment mode is not\~\c
1731 .BR b ,
1732 the line is not hyphenated if the line is no more than
1733 .I n
1734 short.
1735 .
1736 The default hyphenation margin is\~0.
1737 .
1738 The default scaling indicator for this request is\~\c
1739 .BR m .
1740 The hyphenation margin is associated with the current environment.
1741 .
1742 The current hyphenation margin is available in the
1743 .B \[rs]n[.hym]
1744 register.
1745 .
1746 .TP
1747 .BI .hys\  n
1748 Set the
1749 .I hyphenation space
1750 to\~\c
1751 .IR n :
1752 When the current adjustment mode is\~\c
1753 .B b
1754 don\[aq]t hyphenate the line if the line can be justified by adding no
1755 more than
1756 .I n
1757 extra space to each word space.
1758 .
1759 The default hyphenation space is\~0.
1760 .
1761 The default scaling indicator for this request is\~\c
1762 .BR m .
1763 The hyphenation space is associated with the current environment.
1764 .
1765 The current hyphenation space is available in the
1766 .B \[rs]n[.hys]
1767 register.
1768 .
1769 .TP
1770 .BI .itc\  n\ macro
1771 Variant of
1772 .B .it
1773 for which a line interrupted with
1774 .B \[rs]c
1775 counts as one input line.
1776 .
1777 .TP
1778 .BI .kern\  n
1779 If
1780 .I n
1781 is non-zero or missing, enable pairwise kerning, otherwise disable it.
1782 .
1783 .TP
1784 .BI .length\  xx\ string
1785 Compute the length of
1786 .I string
1787 and return it in the number register
1788 .I xx
1789 (which is not necessarily defined before).
1790 .
1791 .TP
1792 .BI .linetabs\  n
1793 If
1794 .I n
1795 is non-zero or missing, enable line-tabs mode, otherwise disable it
1796 (which is the default).
1797 .
1798 In line-tabs mode, tab distances are computed relative to the
1799 (current) output line.
1800 .
1801 Otherwise they are taken relative to the input line.
1802 .
1803 For example, the following
1804 .
1805 .RS
1806 .IP
1807 .ne 6v+\n(.Vu
1808 .EX
1809 \&.ds x a\[rs]t\[rs]c
1810 \&.ds y b\[rs]t\[rs]c
1811 \&.ds z c
1812 \&.ta 1i 3i
1813 \&\[rs]*x
1814 \&\[rs]*y
1815 \&\[rs]*z
1816 .EE
1817 .RE
1818 .
1819 .IP
1820 yields
1821 .
1822 .RS
1823 .IP
1824 .EX
1825 a         b         c
1826 .EE
1827 .RE
1828 .
1829 .IP
1830 In line-tabs mode, the same code gives
1831 .
1832 .RS
1833 .IP
1834 .EX
1835 a         b                   c
1836 .EE
1837 .RE
1838 .
1839 .IP
1840 Line-tabs mode is associated with the current environment; the
1841 read-only number register
1842 .B \[rs]n[.linetabs]
1843 is set to\~1 if in line-tabs mode, and 0 otherwise.
1844 .
1845 .TP
1846 .BI .lsm\  xx
1847 Set the leading spaces macro to
1848 .IR xx .
1849 If there are leading spaces in an input line, it is invoked instead of
1850 the usual troff behaviour; the leading spaces are removed.
1851 Registers
1852 .B \[rs]n[lsn]
1853 and
1854 .B \[rs]n[lss]
1855 hold the number of removed leading spaces and the corresponding
1856 horizontal space, respectively.
1857 .
1858 .TP
1859 .BI .mso\  file
1860 The same as the
1861 .B so
1862 request except that
1863 .I file
1864 is searched for in the same directories as macro files for the the
1865 .B \-m
1866 command line option.
1867 .
1868 If the file name to be included has the form
1869 .IB name .tmac
1870 and it isn\[aq]t found,
1871 .B mso
1872 tries to include
1873 .BI tmac. name
1874 instead and vice versa.
1875 .
1876 A warning of type
1877 .B file
1878 is generated if
1879 .I file
1880 can\[aq]t be loaded, and the request is ignored.
1881 .
1882 .TP
1883 .BI .nop \ anything
1884 Execute
1885 .IR anything .
1886 This is similar to \[oq].if\ 1\[cq].
1887 .
1888 .TP
1889 .B .nroff
1890 Make the
1891 .B n
1892 built-in condition true and the
1893 .B t
1894 built-in condition false.
1895 .
1896 This can be reversed using the
1897 .B troff
1898 request.
1899 .
1900 .TP
1901 .BI .open\  stream\ filename
1902 Open
1903 .I filename
1904 for writing and associate the stream named
1905 .I stream
1906 with it.
1907 .
1908 See also the
1909 .B close
1910 and
1911 .B write
1912 requests.
1913 .
1914 .TP
1915 .BI .opena\  stream\ filename
1916 Like
1917 .BR open ,
1918 but if
1919 .I filename
1920 exists, append to it instead of truncating it.
1921 .
1922 .TP
1923 .BI .output\  string
1924 Emit
1925 .I string
1926 directly to the intermediate output (subject to copy-mode interpretation);
1927 this is similar to
1928 .B \[rs]!\&
1929 used at the top level.
1930 .
1931 An initial double quote in
1932 .I string
1933 is stripped off to allow initial blanks.
1934 .
1935 .TP
1936 .B .pev
1937 Print the current environment and each defined environment state on
1938 stderr.
1939 .
1940 .TP
1941 .B .pnr
1942 Print the names and contents of all currently defined number registers
1943 on stderr.
1944 .
1945 .TP
1946 .BI .psbb \ filename
1947 Get the bounding box of a PostScript image
1948 .IR filename .
1949 .
1950 This file must conform to Adobe\[aq]s Document Structuring
1951 Conventions; the command looks for a
1952 .B \%%%BoundingBox
1953 comment to extract the bounding box values.
1954 .
1955 After a successful call, the coordinates (in PostScript units) of the
1956 lower left and upper right corner can be found in the registers
1957 .BR \[rs]n[llx] ,
1958 .BR \[rs]n[lly] ,
1959 .BR \[rs]n[urx] ,
1960 and
1961 .BR \[rs]n[ury] ,
1962 respectively.
1963 .
1964 If some error has occurred, the four registers are set to zero.
1965 .
1966 .TP
1967 .BI .pso \ command
1968 This behaves like the
1969 .B so
1970 request except that input comes from the standard output of
1971 .IR command .
1972 .
1973 .TP
1974 .B .ptr
1975 Print the names and positions of all traps (not including input line
1976 traps and diversion traps) on stderr.
1977 .
1978 Empty slots in the page trap list are printed as well, because they
1979 can affect the priority of subsequently planted traps.
1980 .
1981 .TP
1982 .BI .pvs \ \[+-]n
1983 Set the post-vertical line space to\~\c
1984 .IR n ;
1985 default scale indicator is\~\c
1986 .BR p .
1987 .
1988 This value is added to each line after it has been output.
1989 .
1990 With no argument, the post-vertical line space is set to its previous
1991 value.
1992 .
1993 .IP
1994 The total vertical line spacing consists of four components:
1995 .B .vs
1996 and
1997 .B \[rs]x
1998 with a negative value which are applied before the line is output, and
1999 .B .pvs
2000 and
2001 .B \[rs]x
2002 with a positive value which are applied after the line is output.
2003 .
2004 .TP
2005 .BI .rchar\  "c1 c2 \*[ellipsis]"
2006 Remove the definitions of glyphs
2007 .IR c1 ,
2008 .IR c2 ,
2009 .I \*[ellipsis]
2010 This undoes the effect of a
2011 .B char
2012 request.
2013 .
2014 .TP
2015 .B .return
2016 Within a macro, return immediately.
2017 .
2018 If called with an argument, return twice, namely from the current macro and
2019 from the macro one level higher.
2020 .
2021 No effect otherwise.
2022 .
2023 .TP
2024 .BI .rfschar\  "c1 c2 \*[ellipsis]"
2025 Remove the font-specific definitions of glyphs
2026 .IR c1 ,
2027 .IR c2 ,
2028 .I \*[ellipsis]
2029 This undoes the effect of a
2030 .B fschar
2031 request.
2032 .
2033 .TP
2034 .B .rj
2035 .TQ
2036 .BI .rj \~n
2037 Right justify the next
2038 .IR n \~\c
2039 input lines.
2040 .
2041 Without an argument right justify the next input line.
2042 .
2043 The number of lines to be right justified is available in the
2044 .B \[rs]n[.rj]
2045 register.
2046 .
2047 This implicitly does
2048 .BR .ce\~0 .
2049 The
2050 .B ce
2051 request implicitly does
2052 .BR .rj\~0 .
2053 .
2054 .TP
2055 .BI .rnn \ xx\ yy
2056 Rename number register
2057 .I xx
2058 to
2059 .IR yy .
2060 .
2061 .TP
2062 .BI .schar\  c\ string
2063 Define global fallback character (or glyph)\~\c
2064 .I c
2065 to be
2066 .IR string .
2067 .
2068 The syntax of this request is the same as the
2069 .B char
2070 request; a glyph defined with
2071 .B schar
2072 is searched after the list of fonts declared with the
2073 .B special
2074 request but before the mounted special fonts.
2075 .
2076 .TP
2077 .BI .shc\  c
2078 Set the soft hyphen character to\~\c
2079 .IR c .
2080 If
2081 .I c
2082 is omitted, the soft hyphen character is set to the default
2083 .BR \[rs][hy] .
2084 The soft hyphen character is the glyph which is inserted when
2085 a word is hyphenated at a line break.
2086 .
2087 If the soft hyphen character does not exist in the font of the
2088 glyph immediately preceding a potential break point, then the line
2089 is not broken at that point.
2090 .
2091 Neither definitions (specified with the
2092 .B char
2093 request) nor translations (specified with the
2094 .B tr
2095 request) are considered when finding the soft hyphen character.
2096 .
2097 .TP
2098 .BI .shift\  n
2099 In a macro, shift the arguments by
2100 .I n
2101 positions: argument\~\c
2102 .I i
2103 becomes argument
2104 .IR i \|\-\| n ;
2105 arguments 1 to\~\c
2106 .I n
2107 are no longer available.
2108 .
2109 If
2110 .I n
2111 is missing, arguments are shifted by\~1.
2112 .
2113 Shifting by negative amounts is currently undefined.
2114 .
2115 .TP
2116 .BI .sizes\  s1\ s2\ \*[ellipsis]\ sn\  [0]
2117 This command is similar to the
2118 .B sizes
2119 command of a
2120 .B DESC
2121 file.
2122 .
2123 It sets the available font sizes for the current font to
2124 .IR s1 ,
2125 .IR s2 ,
2126 .IR \*[ellipsis]\| ,\~ sn
2127 scaled points.
2128 .
2129 The list of sizes can be terminated by an optional\~\c
2130 .BR 0 .
2131 .
2132 Each
2133 .I si
2134 can also be a range of sizes
2135 .IR m \(en n .
2136 .
2137 Contrary to the font file command, the list can\[aq]t extend over more
2138 than a single line.
2139 .
2140 .TP
2141 .BI .special\  "s1 s2 \*[ellipsis]"
2142 Fonts
2143 .IR s1 ,
2144 .IR s2 ,
2145 .IR \*[ellipsis] ,
2146 are special and are searched for glyphs not in the current
2147 font.
2148 .
2149 Without arguments, reset the list of special fonts to be empty.
2150 .
2151 .TP
2152 .BI .spreadwarn\  limit
2153 Make
2154 .B troff
2155 emit a warning if the additional space inserted for each space between
2156 words in an output line is larger or equal to
2157 .IR limit .
2158 .
2159 A negative value is changed to zero; no argument toggles the warning on
2160 and off without changing
2161 .IR limit .
2162 .
2163 The default scaling indicator is\~\c
2164 .BR m .
2165 .
2166 At startup,
2167 .B spreadwarn
2168 is deactivated, and
2169 .I limit
2170 is set to 3m.
2171 .
2172 For example,
2173 .B .spreadwarn\ 0.2m
2174 causes a warning if
2175 .B troff
2176 must add 0.2m or more for each interword space in a line.
2177 .
2178 This request is active only if text is justified to both margins (using
2179 .BR .ad\ b ).
2180 .
2181 .TP
2182 .BI .sty\  n\ f
2183 Associate style\~\c
2184 .I f
2185 with font position\~\c
2186 .IR n .
2187 A font position can be associated either with a font or with a style.
2188 .
2189 The current font is the index of a font position and so is also either
2190 a font or a style.
2191 .
2192 When it is a style, the font that is actually used is the font the
2193 name of which is the concatenation of the name of the current family
2194 and the name of the current style.
2195 .
2196 For example, if the current font is\~1 and font position\~1 is
2197 associated with style\~\c
2198 .B R
2199 and the current font family is\~\c
2200 .BR T ,
2201 then font
2202 .BR TR
2203 is used.
2204 .
2205 If the current font is not a style, then the current family is ignored.
2206 .
2207 When the requests
2208 .BR cs ,
2209 .BR bd ,
2210 .BR tkf ,
2211 .BR uf ,
2212 or
2213 .B fspecial
2214 are applied to a style, then they are applied instead to the
2215 member of the current family corresponding to that style.
2216 .
2217 The default family can be set with the
2218 .B \-f
2219 command line option.
2220 .
2221 The
2222 .B styles
2223 command in the
2224 .SM DESC
2225 file controls which font positions (if any) are initially associated
2226 with styles rather than fonts.
2227 .
2228 .TP
2229 .BI .substring\  xx\ n1\  [ n2 ]
2230 Replace the string named
2231 .I xx
2232 with the substring defined by the indices
2233 .I n1
2234 and
2235 .IR n2 .
2236 The first character in the string has index\~0.
2237 .
2238 If
2239 .I n2
2240 is omitted, it is taken to be equal to the string\[aq]s length.
2241 .
2242 If the index value
2243 .I n1
2244 or
2245 .I n2
2246 is negative, it is counted from the end of the string,
2247 going backwards:
2248 .
2249 The last character has index\~\-1, the character before the last
2250 character has index\~\-2, etc.
2251 .
2252 .TP
2253 .BI .tkf\  f\ s1\ n1\ s2\ n2
2254 Enable track kerning for font\~\c
2255 .IR f .
2256 When the current font is\~\c
2257 .I f
2258 the width of every glyph is increased by an amount between
2259 .I n1
2260 and
2261 .IR n2 ;
2262 when the current point size is less than or equal to
2263 .I s1
2264 the width is increased by
2265 .IR n1 ;
2266 when it is greater than or equal to
2267 .I s2
2268 the width is increased by
2269 .IR n2 ;
2270 when the point size is greater than or equal to
2271 .I s1
2272 and less than or equal to
2273 .I s2
2274 the increase in width is a linear function of the point size.
2275 .
2276 .TP
2277 .BI .tm1\  string
2278 Similar to the
2279 .B tm
2280 request,
2281 .I string
2282 is read in copy mode and written on the standard error, but an initial
2283 double quote in
2284 .I string
2285 is stripped off to allow initial blanks.
2286 .
2287 .TP
2288 .BI .tmc\  string
2289 Similar to
2290 .B tm1
2291 but without writing a final newline.
2292 .
2293 .TP
2294 .BI .trf\  filename
2295 Transparently output the contents of file
2296 .IR filename .
2297 Each line is output as if preceded by
2298 .BR \[rs]! ;
2299 however, the lines are not subject to copy-mode interpretation.
2300 .
2301 If the file does not end with a newline, then a newline is added.
2302 .
2303 For example, you can define a macro\~\c
2304 .I x
2305 containing the contents of file\~\c
2306 .IR f ,
2307 using
2308 .
2309 .RS
2310 .IP
2311 .ne 2v+\n(.Vu
2312 .EX
2313 \&.di x
2314 \&.trf f
2315 \&.di
2316 .EE
2317 .RE
2318 .
2319 .IP
2320 Unlike with the
2321 .B cf
2322 request, the file cannot contain characters such as
2323 .SM NUL
2324 that are not valid troff input characters.
2325 .
2326 .TP
2327 .BI .trin\  abcd
2328 This is the same as the
2329 .B tr
2330 request except that the
2331 .B asciify
2332 request uses the character code (if any) before the character
2333 translation.
2334 .
2335 Example:
2336 .
2337 .RS
2338 .IP
2339 .EX
2340 \&.trin ax
2341 \&.di xxx
2342 \&a
2343 \&.br
2344 \&.di
2345 \&.xxx
2346 \&.trin aa
2347 \&.asciify xxx
2348 \&.xxx
2349 .EE
2350 .RE
2351 .
2352 .IP
2353 The result is
2354 .BR x\ a .
2355 .
2356 Using
2357 .BR tr ,
2358 the result would be
2359 .BR x\ x .
2360 .
2361 .TP
2362 .BI .trnt\  abcd
2363 This is the same as the
2364 .B tr
2365 request except that the translations do not apply to text that is
2366 transparently throughput into a diversion with
2367 .BR \[rs]! .
2368 For example,
2369 .
2370 .RS
2371 .IP
2372 .EX
2373 \&.tr ab
2374 \&.di x
2375 \&\[rs]!.tm a
2376 \&.di
2377 \&.x
2378 .EE
2379 .RE
2380 .
2381 .IP
2382 prints\~\c
2383 .BR b ;
2384 if
2385 .B trnt
2386 is used instead of
2387 .B tr
2388 it prints\~\c
2389 .BR a .
2390 .RE
2391 .
2392 .TP
2393 .B .troff
2394 Make the
2395 .B n
2396 built-in condition false, and the
2397 .B t
2398 built-in condition true.
2399 .
2400 This undoes the effect of the
2401 .B nroff
2402 request.
2403 .
2404 .TP
2405 .BI .unformat\  xx
2406 This request \[oq]unformats\[cq] the diversion
2407 .IR xx .
2408 .
2409 Contrary to the
2410 .B asciify
2411 request, which tries to convert formatted elements of the diversion
2412 back to input tokens as much as possible,
2413 .B .unformat
2414 only handles tabs and spaces between words (usually caused by spaces
2415 or newlines in the input) specially.
2416 .
2417 The former are treated as if they were input tokens, and the latter
2418 are stretchable again.
2419 .
2420 Note that the vertical size of lines is not preserved.
2421 .
2422 Glyph information (font, font size, space width, etc.\&) is retained.
2423 .
2424 Useful in conjunction with the
2425 .B box
2426 and
2427 .B boxa
2428 requests.
2429 .
2430 .TP
2431 .BI .vpt\  n
2432 Enable vertical position traps if
2433 .I n
2434 is non-zero, disable them otherwise.
2435 .
2436 Vertical position traps are traps set by the
2437 .B wh
2438 or
2439 .B dt
2440 requests.
2441 .
2442 Traps set by the
2443 .B it
2444 request are not vertical position traps.
2445 .
2446 The parameter that controls whether vertical position traps are
2447 enabled is global.
2448 .
2449 Initially vertical position traps are enabled.
2450 .
2451 .TP
2452 .BI .warn\  n
2453 Control warnings.
2454 .IR n \~\c
2455 is the sum of the numbers associated with each warning that is to be
2456 enabled; all other warnings are disabled.
2457 .
2458 The number associated with each warning is listed in
2459 .BR @g@troff (@MAN1EXT@).
2460 .
2461 For example,
2462 .B .warn\~0
2463 disables all warnings, and
2464 .B .warn\~1
2465 disables all warnings except that about missing glyphs.
2466 .
2467 If
2468 .I n
2469 is not given, all warnings are enabled.
2470 .
2471 .TP
2472 .BI .warnscale\  si
2473 Set the scaling indicator used in warnings to
2474 .IR si .
2475 .
2476 Valid values for
2477 .I si
2478 are
2479 .BR u ,
2480 .BR i ,
2481 .BR c ,
2482 .BR p ,
2483 and\~\c
2484 .BR P .
2485 .
2486 At startup, it is set to\~\c
2487 .BR i .
2488 .
2489 .TP
2490 .BI .while \ c\ anything
2491 While condition\~\c
2492 .I c
2493 is true, accept
2494 .I anything
2495 as input;
2496 .IR c \~\c
2497 can be any condition acceptable to an
2498 .B if
2499 request;
2500 .I anything
2501 can comprise multiple lines if the first line starts with
2502 .B \[rs]{
2503 and the last line ends with
2504 .BR \[rs]} .
2505 See also the
2506 .B break
2507 and
2508 .B continue
2509 requests.
2510 .
2511 .TP
2512 .BI .write\  stream\ anything
2513 Write
2514 .I anything
2515 to the stream named
2516 .IR stream .
2517 .I stream
2518 must previously have been the subject of an
2519 .B open
2520 request.
2521 .I anything
2522 is read in copy mode;
2523 a leading\~\c
2524 .B \[dq]
2525 is stripped.
2526 .
2527 .TP
2528 .BI .writec\  stream\ anything
2529 Similar to
2530 .B write
2531 but without writing a final newline.
2532 .
2533 .TP
2534 .BI .writem\  stream\ xx
2535 Write the contents of the macro or string
2536 .I xx
2537 to the stream named
2538 .IR stream .
2539 .I stream
2540 must previously have been the subject of an
2541 .B open
2542 request.
2543 .I xx
2544 is read in copy mode.
2545 .
2546 .
2547 .\" --------------------------------------------------------------------
2548 .SS "Extended escape sequences"
2549 .\" --------------------------------------------------------------------
2550 .
2551 .TP
2552 .BR \[rs]D' \*[ellipsis] '
2553 All drawing commands of groff\[aq]s intermediate output are accepted.
2554 .
2555 See subsection
2556 .B "Drawing Commands"
2557 below for more information.
2558 .
2559 .
2560 .\" --------------------------------------------------------------------
2561 .SS "Extended requests"
2562 .\" --------------------------------------------------------------------
2563 .
2564 .TP
2565 .BI .cf\  filename
2566 When used in a diversion, this embeds in the diversion an object
2567 which, when reread, will cause the contents of
2568 .I filename
2569 to be transparently copied through to the output.
2570 .
2571 In UNIX troff, the contents of
2572 .I filename
2573 is immediately copied through to the output regardless of whether
2574 there is a current diversion; this behaviour is so anomalous that it
2575 must be considered a bug.
2576 .
2577 .TP
2578 .BI .de\  xx\ yy
2579 .TQ
2580 .BI .am\  xx\ yy
2581 .TQ
2582 .BI .ds\  xx\ yy
2583 .TQ
2584 .BI .as\  xx\ yy
2585 In compatibility mode, these requests behaves similar to
2586 .BR .de1 ,
2587 .BR .am1 ,
2588 .BR .ds1 ,
2589 and
2590 .BR .as1 ,
2591 respectively: A \[oq]compatibility save\[cq] token is inserted at the
2592 beginning, and a \[oq]compatibility restore\[cq] token at the end,
2593 with compatibility mode switched on during execution.
2594 .
2595 .TP
2596 .BI .ev\  xx
2597 If
2598 .I xx
2599 is not a number, this switches to a named environment called
2600 .IR xx .
2601 The environment should be popped with a matching
2602 .B ev
2603 request without any arguments, just as for numbered environments.
2604 .
2605 There is no limit on the number of named environments; they are
2606 created the first time that they are referenced.
2607 .
2608 .TP
2609 .BI .ss\  m\ n
2610 When two arguments are given to the
2611 .B ss
2612 request, the second argument gives the
2613 .IR "sentence space size" .
2614 If the second argument is not given, the sentence space size
2615 is the same as the word space size.
2616 .
2617 Like the word space size, the sentence space is in units of
2618 one twelfth of the spacewidth parameter for the current font.
2619 .
2620 Initially both the word space size and the sentence
2621 space size are\~12.
2622 .
2623 Contrary to UNIX troff, GNU troff handles this request in nroff mode
2624 also; a given value is then rounded down to the nearest multiple
2625 of\~12.
2626 .
2627 The sentence space size is used in two circumstances.
2628 .
2629 If the end of a sentence occurs at the end of a line in fill mode,
2630 then both an inter-word space and a sentence space are added; if
2631 two spaces follow the end of a sentence in the middle of a line, then
2632 the second space is a sentence space.
2633 .
2634 Note that the behaviour of UNIX troff are exactly that exhibited
2635 by GNU troff if a second argument is never given to the
2636 .B ss
2637 request.
2638 .
2639 In GNU troff, as in UNIX troff, you should always follow a sentence
2640 with either a newline or two spaces.
2641 .
2642 .TP
2643 .BI .ta\  "n1 n2 \*[ellipsis] nn " "T " "r1 r2 \*[ellipsis] rn"
2644 Set tabs at positions
2645 .IR n1 ,
2646 .IR n2 ,
2647 .IR \*[ellipsis] ,
2648 .I nn
2649 and then set tabs at
2650 .IR nn \|+\| r1 ,
2651 .IR nn \|+\| r2 ,
2652 .IR \*[ellipsis] ,
2653 .IR nn \|+\| rn
2654 and then at
2655 .IR nn \|+\| rn \|+\| r1 ,
2656 .IR nn \|+\| rn \|+\| r2 ,
2657 .IR \*[ellipsis] ,
2658 .IR nn \|+\| rn \|+\| rn ,
2659 and so on.
2660 For example,
2661 .
2662 .RS
2663 .IP
2664 .EX
2665 \&.ta T .5i
2666 .EE
2667 .
2668 .P
2669 sets tabs every half an inch.
2670 .RE
2671 .
2672 .
2673 .\" --------------------------------------------------------------------
2674 .SS "New number registers"
2675 .\" --------------------------------------------------------------------
2676 .
2677 The following read-only registers are available:
2678 .
2679 .TP
2680 .B \[rs]n[.br]
2681 Within a macro call, it is set to\~1 if the macro is called with the
2682 \[oq]normal\[cq] control character (\[oq].\[cq] by default), and set
2683 to\~0 otherwise.
2684 .
2685 This allows to reliably modify requests.
2686 .
2687 .RS
2688 .IP
2689 .ne 6v+\n(.Vu
2690 .EX
2691 \&.als bp*orig bp
2692 \&.de bp
2693 \&.tm before bp
2694 \&.ie \[rs]\[rs]n[.br] .bp*orig
2695 \&.el 'bp*orig
2696 \&.tm after bp
2697 \&..
2698 .EE
2699 .RE
2700 .
2701 .IP
2702 Using this register outside of a macro makes no sense (it always returns
2703 zero in such cases).
2704 .
2705 .TP
2706 .B \[rs]n[.C]
2707 1\~if compatibility mode is in effect, 0\~otherwise.
2708 .
2709 .TP
2710 .B \[rs]n[.cdp]
2711 The depth of the last glyph added to the current environment.
2712 .
2713 It is positive if the glyph extends below the baseline.
2714 .
2715 .TP
2716 .B \[rs]n[.ce]
2717 The number of lines remaining to be centered, as set by the
2718 .B ce
2719 request.
2720 .
2721 .TP
2722 .B \[rs]n[.cht]
2723 The height of the last glyph added to the current environment.
2724 .
2725 It is positive if the glyph extends above the baseline.
2726 .
2727 .TP
2728 .B \[rs]n[.color]
2729 1\~if colors are enabled, 0\~otherwise.
2730 .
2731 .TP
2732 .B \[rs]n[.csk]
2733 The skew of the last glyph added to the current environment.
2734 .
2735 The
2736 .I skew
2737 of a glyph is how far to the right of the center of a glyph
2738 the center of an accent over that glyph should be placed.
2739 .
2740 .TP
2741 .B \[rs]n[.ev]
2742 The name or number of the current environment.
2743 .
2744 This is a string-valued register.
2745 .
2746 .TP
2747 .B \[rs]n[.fam]
2748 The current font family.
2749 .
2750 This is a string-valued register.
2751 .
2752 .TP
2753 .B \[rs]n[.fn]
2754 The current (internal) real font name.
2755 .
2756 This is a string-valued register.
2757 .
2758 If the current font is a style, the value of
2759 .B \[rs]n[.fn]
2760 is the proper concatenation of family and style name.
2761 .
2762 .TP
2763 .B \[rs]n[.fp]
2764 The number of the next free font position.
2765 .
2766 .TP
2767 .B \[rs]n[.g]
2768 Always\~1.
2769 .
2770 Macros should use this to determine whether they are running under GNU
2771 troff.
2772 .
2773 .TP
2774 .B \[rs]n[.height]
2775 The current height of the font as set with
2776 .BR \[rs]H .
2777 .
2778 .TP
2779 .B \[rs]n[.hla]
2780 The current hyphenation language as set by the
2781 .B hla
2782 request.
2783 .
2784 .TP
2785 .B \[rs]n[.hlc]
2786 The number of immediately preceding consecutive hyphenated lines.
2787 .
2788 .TP
2789 .B \[rs]n[.hlm]
2790 The maximum allowed number of consecutive hyphenated lines, as set by
2791 the
2792 .B hlm
2793 request.
2794 .
2795 .TP
2796 .B \[rs]n[.hy]
2797 The current hyphenation flags (as set by the
2798 .B hy
2799 request).
2800 .
2801 .TP
2802 .B \[rs]n[.hym]
2803 The current hyphenation margin (as set by the
2804 .B hym
2805 request).
2806 .
2807 .TP
2808 .B \[rs]n[.hys]
2809 The current hyphenation space (as set by the
2810 .B hys
2811 request).
2812 .
2813 .TP
2814 .B \[rs]n[.in]
2815 The indentation that applies to the current output line.
2816 .
2817 .TP
2818 .B \[rs]n[.int]
2819 Set to a positive value if last output line is interrupted (i.e., if
2820 it contains
2821 .BR \[rs]c ).
2822 .
2823 .TP
2824 .B \[rs]n[.kern]
2825 1\~if pairwise kerning is enabled, 0\~otherwise.
2826 .
2827 .TP
2828 .B \[rs]n[.lg]
2829 The current ligature mode (as set by the
2830 .B lg
2831 request).
2832 .
2833 .TP
2834 .B \[rs]n[.linetabs]
2835 The current line-tabs mode (as set by the
2836 .B linetabs
2837 request).
2838 .
2839 .TP
2840 .B \[rs]n[.ll]
2841 The line length that applies to the current output line.
2842 .
2843 .TP
2844 .B \[rs]n[.lt]
2845 The title length as set by the
2846 .B lt
2847 request.
2848 .
2849 .TP
2850 .B \[rs]n[.m]
2851 The name of the current drawing color.
2852 .
2853 This is a string-valued register.
2854 .
2855 .TP
2856 .B \[rs]n[.M]
2857 The name of the current background color.
2858 .
2859 This is a string-valued register.
2860 .
2861 .TP
2862 .B \[rs]n[.ne]
2863 The amount of space that was needed in the last
2864 .B ne
2865 request that caused a trap to be sprung.
2866 .
2867 Useful in conjunction with the
2868 .B \[rs]n[.trunc]
2869 register.
2870 .
2871 .TP
2872 .B \[rs]n[.ns]
2873 1\~if no-space mode is active, 0\~otherwise.
2874 .
2875 .TP
2876 .B \[rs]n[.O]
2877 The current output level as set with
2878 .BR \[rs]O .
2879 .
2880 .TP
2881 .B \[rs]n[.P]
2882 1\~if the current page is in the output list set with
2883 .BR \-o .
2884 .
2885 .TP
2886 .B \[rs]n[.pe]
2887 1\~during a page ejection caused by the
2888 .B bp
2889 request, 0\~otherwise.
2890 .
2891 .TP
2892 .B \[rs]n[.pn]
2893 The number of the next page, either the value set by a
2894 .B pn
2895 request, or the number of the current page plus\~1.
2896 .
2897 .TP
2898 .B \[rs]n[.ps]
2899 The current point size in scaled points.
2900 .
2901 .TP
2902 .B \[rs]n[.psr]
2903 The last-requested point size in scaled points.
2904 .
2905 .TP
2906 .B \[rs]n[.pvs]
2907 The current post-vertical line space as set with the
2908 .B pvs
2909 request.
2910 .
2911 .TP
2912 .B \[rs]n[.rj]
2913 The number of lines to be right-justified as set by the
2914 .B rj
2915 request.
2916 .
2917 .TP
2918 .B \[rs]n[.slant]
2919 The slant of the current font as set with
2920 .BR \[rs]S .
2921 .
2922 .TP
2923 .B \[rs]n[.sr]
2924 The last requested point size in points as a decimal fraction.
2925 .
2926 This is a string-valued register.
2927 .
2928 .TP
2929 .B \[rs]n[.ss]
2930 .TQ
2931 .B \[rs]n[.sss]
2932 These give the values of the parameters set by the first and second
2933 arguments of the
2934 .B ss
2935 request.
2936 .
2937 .TP
2938 .B \[rs]n[.sty]
2939 The current font style.
2940 .
2941 This is a string-valued register.
2942 .
2943 .TP
2944 .B \[rs]n[.tabs]
2945 A string representation of the current tab settings suitable for use
2946 as an argument to the
2947 .B ta
2948 request.
2949 .
2950 .TP
2951 .B \[rs]n[.trunc]
2952 The amount of vertical space truncated by the most recently sprung
2953 vertical position trap, or, if the trap was sprung by a
2954 .B ne
2955 request, minus the amount of vertical motion produced by the
2956 .B ne
2957 request.
2958 .
2959 In other words, at the point a trap is sprung, it represents the
2960 difference of what the vertical position would have been but for the
2961 trap, and what the vertical position actually is.
2962 .
2963 Useful in conjunction with the
2964 .B \[rs]n[.ne]
2965 register.
2966 .
2967 .TP
2968 .B \[rs]n[.U]
2969 Set to\~1 if in safer mode and to\~0 if in unsafe mode (as given with
2970 the
2971 .B \-U
2972 command line option).
2973 .
2974 .TP
2975 .B \[rs]n[.vpt]
2976 1\~if vertical position traps are enabled, 0\~otherwise.
2977 .
2978 .TP
2979 .B \[rs]n[.warn]
2980 The sum of the numbers associated with each of the currently enabled
2981 warnings.
2982 .
2983 The number associated with each warning is listed in
2984 .BR @g@troff (@MAN1EXT@).
2985 .
2986 .TP
2987 .B \[rs]n[.x]
2988 The major version number.
2989 .
2990 For example, if the version number is 1.03, then
2991 .B \[rs]n[.x]
2992 contains\~1.
2993 .
2994 .TP
2995 .B \[rs]n[.y]
2996 The minor version number.
2997 .
2998 For example, if the version number is 1.03, then
2999 .B \[rs]n[.y]
3000 contains\~03.
3001 .
3002 .TP
3003 .B \[rs]n[.Y]
3004 The revision number of groff.
3005 .
3006 .TP
3007 .B \[rs]n[.zoom]
3008 The zoom value of the current font, in multiples of 1/1000th.
3009 Zero if no magnification.
3010 .
3011 .TP
3012 .B \[rs]n[llx]
3013 .TQ
3014 .B \[rs]n[lly]
3015 .TQ
3016 .B \[rs]n[urx]
3017 .TQ
3018 .B \[rs]n[ury]
3019 These four read/\:write registers are set by the
3020 .B psbb
3021 request and contain the bounding box values (in PostScript units) of a
3022 given PostScript image.
3023 .
3024 .P
3025 The following read/\:write registers are set by the
3026 .B \[rs]w
3027 escape sequence:
3028 .
3029 .TP
3030 .B \[rs]n[rst]
3031 .TQ
3032 .B \[rs]n[rsb]
3033 Like the
3034 .B st
3035 and
3036 .B sb
3037 registers, but take account of the heights and depths of glyphs.
3038 .
3039 .TP
3040 .B \[rs]n[ssc]
3041 The amount of horizontal space (possibly negative) that should be
3042 added to the last glyph before a subscript.
3043 .
3044 .TP
3045 .B \[rs]n[skw]
3046 How far to right of the center of the last glyph in the
3047 .B \[rs]w
3048 argument, the center of an accent from a roman font should be placed
3049 over that glyph.
3050 .
3051 .P
3052 Other available read/write number registers are:
3053 .
3054 .TP
3055 .B \[rs]n[c.]
3056 The current input line number.
3057 .B \[rs]n[.c]
3058 is a read-only alias to this register.
3059 .
3060 .TP
3061 .B \[rs]n[hours]
3062 The number of hours past midnight.
3063 .
3064 Initialized at start-up.
3065 .
3066 .TP
3067 .B \[rs]n[hp]
3068 The current horizontal position at input line.
3069 .
3070 .TP
3071 .B \[rs]n[lsn]
3072 .TQ
3073 .B \[rs]n[lss]
3074 If there are leading spaces in an input line, these registers
3075 hold the number of leading spaces and the corresponding
3076 horizontal space, respectively.
3077 .
3078 .TP
3079 .B \[rs]n[minutes]
3080 The number of minutes after the hour.
3081 .
3082 Initialized at start-up.
3083 .
3084 .TP
3085 .B \[rs]n[seconds]
3086 The number of seconds after the minute.
3087 .
3088 Initialized at start-up.
3089 .
3090 .TP
3091 .B \[rs]n[systat]
3092 The return value of the system() function executed by the last
3093 .B sy
3094 request.
3095 .
3096 .TP
3097 .B \[rs]n[slimit]
3098 If greater than\~0, the maximum number of objects on the input stack.
3099 .
3100 If less than or equal to\~0, there is no limit on the number of
3101 objects on the input stack.
3102 .
3103 With no limit, recursion can continue until virtual memory is
3104 exhausted.
3105 .
3106 .TP
3107 .B \[rs]n[year]
3108 The current year.
3109 .
3110 Note that the traditional
3111 .B troff
3112 number register
3113 .B \[rs]n[yr]
3114 is the current year minus 1900.
3115 .
3116 .
3117 .\" --------------------------------------------------------------------
3118 .SS Miscellaneous
3119 .\" --------------------------------------------------------------------
3120 .
3121 .B @g@troff
3122 predefines a single (read/write) string-based register,
3123 .BR \[rs]*[.T] ,
3124 which contains the argument given to the
3125 .B \-T
3126 command line option, namely the current output device (for example,
3127 .I latin1
3128 or
3129 .IR ascii ).
3130 Note that this is not the same as the (read-only) number register
3131 .B \[rs]n[.T]
3132 which is defined to be\~1 if
3133 .B troff
3134 is called with the
3135 .B \-T
3136 command line option, and zero otherwise.
3137 .
3138 This behaviour is different to UNIX troff.
3139 .
3140 .P
3141 Fonts not listed in the
3142 .SM DESC
3143 file are automatically mounted on the next available font position
3144 when they are referenced.
3145 .
3146 If a font is to be mounted explicitly with the
3147 .B fp
3148 request on an unused font position, it should be mounted on the first
3149 unused font position, which can be found in the
3150 .B \[rs]n[.fp]
3151 register; although
3152 .B troff
3153 does not enforce this strictly, it does not allow a font to be mounted
3154 at a position whose number is much greater than that of any currently
3155 used position.
3156 .
3157 .P
3158 Interpolating a string does not hide existing macro arguments.
3159 .
3160 Thus in a macro, a more efficient way of doing
3161 .
3162 .IP
3163 .BI . xx\  \[rs]\[rs]$@
3164 .P
3165 is
3166 .
3167 .IP
3168 .BI \[rs]\[rs]*[ xx ]\[rs]\[rs]
3169 .
3170 .P
3171 If the font description file contains pairwise kerning information,
3172 glyphs from that font are kerned.
3173 .
3174 Kerning between two glyphs can be inhibited by placing a
3175 .B \[rs]&
3176 between them.
3177 .
3178 .P
3179 In a string comparison in a condition, characters that appear at
3180 different input levels to the first delimiter character are not
3181 recognized as the second or third delimiters.
3182 .
3183 This applies also to the
3184 .B tl
3185 request.
3186 .
3187 In a
3188 .B \[rs]w
3189 escape sequence, a character that appears at a different input level
3190 to the starting delimiter character is not recognized as the
3191 closing delimiter character.
3192 .
3193 The same is true for
3194 .BR \[rs]A ,
3195 .BR \[rs]b ,
3196 .BR \[rs]B ,
3197 .BR \[rs]C ,
3198 .BR \[rs]l ,
3199 .BR \[rs]L ,
3200 .BR \[rs]o ,
3201 .BR \[rs]X ,
3202 and
3203 .BR \[rs]Z .
3204 .
3205 When decoding a macro or string argument that is delimited by double
3206 quotes, a character that appears at a different input level to the starting
3207 delimiter character is not recognized as the closing delimiter
3208 character.
3209 .
3210 The implementation of
3211 .B \[rs]$@
3212 ensures that the double quotes surrounding an argument appear at the
3213 same input level, which is different to the input level of the
3214 argument itself.
3215 .
3216 In a long escape name
3217 .B ]
3218 is not recognized as a closing delimiter except when it occurs at
3219 the same input level as the opening\~\c
3220 .BR [ .
3221 .
3222 In compatibility mode, no attention is paid to the input-level.
3223 .
3224 .P
3225 There are some new types of condition:
3226 .
3227 .TP
3228 .BI .if\ r xxx
3229 True if there is a number register named
3230 .IR xxx .
3231 .
3232 .TP
3233 .BI .if\ d xxx
3234 True if there is a string, macro, diversion, or request named
3235 .IR xxx .
3236 .
3237 .TP
3238 .BI .if\ m xxx
3239 True if there is a color named
3240 .IR xxx .
3241 .
3242 .TP
3243 .BI .if\ c ch
3244 True if there is a character (or glyph)
3245 .IR ch
3246 available;
3247 .I ch
3248 is either an
3249 .SM ASCII
3250 character or a glyph (special character)
3251 .BI \[rs]N' xxx '\f[R],
3252 .BI \[rs]( xx
3253 or
3254 .BI \[rs][ xxx ]\f[R];
3255 the condition is also true if
3256 .I ch
3257 has been defined by the
3258 .B char
3259 request.
3260 .
3261 .TP
3262 .BI .if\ F f
3263 True if font\~\c
3264 .I f
3265 exists.
3266 .
3267 .BR f \~\c
3268 is handled as if it was opened with the
3269 .B ft
3270 request (this is, font translation and styles are applied), without
3271 actually mounting it.
3272 .
3273 .TP
3274 .BI .if\ S s
3275 True if style\~\c
3276 .I s
3277 has been registered.
3278 .
3279 Font translation is applied.
3280 .
3281 .P
3282 The
3283 .B tr
3284 request can now map characters onto
3285 .BR \[rs]\[ti] .
3286 .
3287 .P
3288 The space width emitted by the
3289 .B \[rs]|
3290 and
3291 .B \[rs]^
3292 escape sequences can be controlled on a per-font basis.
3293 If there is a glyph named
3294 .B \[rs]|
3295 or
3296 .BR \[rs]^ ,
3297 respectively (note the leading backslash), defined in the current font file,
3298 use this glyph\[aq]s width instead of the default value.
3299 .
3300 .P
3301 It is now possible to have whitespace between the first and second dot
3302 (or the name of the ending macro) to end a macro definition.
3303 .
3304 Example:
3305 .
3306 .IP
3307 .ne 6v+\n(.Vu
3308 .EX
3309 \&.if t \[rs]{\[rs]
3310 \&.  de bar
3311 \&.    nop Hello, I\[aq]m \[oq]bar\[cq].
3312 \&.  .
3313 \&.\[rs]}
3314 .EE
3315 .
3316 .
3317 .\" --------------------------------------------------------------------
3318 .SH "INTERMEDIATE OUTPUT FORMAT"
3319 .\" --------------------------------------------------------------------
3320 .
3321 This section describes the format output by GNU troff.
3322 .
3323 The output format used by GNU troff is very similar to that used
3324 by Unix device-independent troff.
3325 .
3326 Only the differences are documented here.
3327 .
3328 .
3329 .\" --------------------------------------------------------------------
3330 .SS "Units"
3331 .\" --------------------------------------------------------------------
3332 .
3333 The argument to the
3334 .BR s \~\c
3335 command is in scaled points (units of
3336 .RI points/ n ,
3337 where
3338 .I n
3339 is the argument to the
3340 .B sizescale
3341 command  in the DESC file).
3342 .
3343 The argument to the
3344 .B x\ Height
3345 command is also in scaled points.
3346 .
3347 .
3348 .\" --------------------------------------------------------------------
3349 .SS "Text Commands"
3350 .\" --------------------------------------------------------------------
3351 .
3352 .TP
3353 .BI N n
3354 Print glyph with index\~\c
3355 .I n
3356 (a non-negative integer) of the current font.
3357 .
3358 .P
3359 If the
3360 .B tcommand
3361 line is present in the DESC file, troff uses the following two
3362 commands.
3363 .
3364 .TP
3365 .BI t xxx
3366 .I xxx
3367 is any sequence of characters terminated by a space or a newline (to
3368 be more precise, it is a sequence of glyphs which are accessed with
3369 the corresponding characters); the first character should be printed at
3370 the current position, the current horizontal position should be increased
3371 by the width of the first character, and so on for each character.
3372 .
3373 The width of the glyph is that given in the font file,
3374 appropriately scaled for the current point size, and rounded so that
3375 it is a multiple of the horizontal resolution.
3376 .
3377 Special characters cannot be printed using this command.
3378 .
3379 .TP
3380 .BI u n\ xxx
3381 This is same as the
3382 .BR t \~\c
3383 command except that after printing each character, the current
3384 horizontal position is increased by the sum of the width of that
3385 character and\~\c
3386 .IR n .
3387 .
3388 .P
3389 Note that single characters can have the eighth bit set, as can the
3390 names of fonts and special characters.
3391 .
3392 .P
3393 The names of glyphs and fonts can be of arbitrary length; drivers
3394 should not assume that they are only two characters long.
3395 .
3396 .P
3397 When a glyph is to be printed, that glyph is always
3398 in the current font.
3399 .
3400 Unlike device-independent troff, it is not necessary for drivers to
3401 search special fonts to find a glyph.
3402 .
3403 .P
3404 For color support, some new commands have been added:
3405 .
3406 .TP
3407 \f[B]mc \f[I]cyan magenta yellow\f[R]
3408 .TQ
3409 \f[B]md\f[R]
3410 .TQ
3411 \f[B]mg \f[I]gray\f[R]
3412 .TQ
3413 \f[B]mk \f[I]cyan magenta yellow black\f[R]
3414 .TQ
3415 \f[B]mr \f[I]red green blue\f[R]
3416 Set the color components of the current drawing color, using various
3417 color schemes.
3418 .
3419 .B md
3420 resets the drawing color to the default value.
3421 .
3422 The arguments are integers in the range 0 to 65536.
3423 .
3424 .P
3425 The
3426 .BR x \~\c
3427 device control command has been extended.
3428 .
3429 .TP
3430 \f[B]x u \f[I]n\f[R]
3431 If
3432 .I n
3433 is\~1, start underlining of spaces.
3434 .
3435 If
3436 .I n
3437 is\~0, stop underlining of spaces.
3438 .
3439 This is needed for the
3440 .B cu
3441 request in nroff mode and is ignored otherwise.
3442 .
3443 .
3444 .\" --------------------------------------------------------------------
3445 .SS "Drawing Commands"
3446 .\" --------------------------------------------------------------------
3447 .
3448 The
3449 .B D
3450 drawing command has been extended.
3451 .
3452 These extensions are not used by GNU pic if the
3453 .B \-n
3454 option is given.
3455 .
3456 .TP
3457 \f[B]Df \f[I]n\/\f[R]\*[ic]\[rs]n
3458 Set the shade of gray to be used for filling solid objects to
3459 .IR n ;
3460 .I n
3461 must be an integer between 0 and 1000, where 0 corresponds solid white
3462 and 1000 to solid black, and values in between correspond to
3463 intermediate shades of gray.
3464 .
3465 This applies only to solid circles, solid ellipses and solid
3466 polygons.
3467 .
3468 By default, a level of 1000 is used.
3469 .
3470 Whatever color a solid object has, it should completely obscure
3471 everything beneath it.
3472 .
3473 A value greater than 1000 or less than\~0 can also be used: this means
3474 fill with the shade of gray that is currently being used for lines and
3475 text.
3476 .
3477 Normally this is black, but some drivers may provide a way of
3478 changing this.
3479 .
3480 .IP
3481 The corresponding
3482 .BI \[rs]D'f \*[ellipsis] '
3483 command shouldn\[aq]t be used since its argument is always rounded to an
3484 integer multiple of the horizontal resolution which can lead to
3485 surprising results.
3486 .
3487 .TP
3488 \f[B]DC \f[I]\/d\f[R]\*[ic]\[rs]n
3489 Draw a solid circle with a diameter of
3490 .I d
3491 with the leftmost point at the current position.
3492 .
3493 .TP
3494 \f[B]DE \f[I]dx dy\/\f[R]\*[ic]\[rs]n
3495 Draw a solid ellipse with a horizontal diameter of
3496 .I dx
3497 and a vertical diameter of
3498 .I dy
3499 with the leftmost point at the current position.
3500 .EQ
3501 delim $$
3502 .EN
3503 .
3504 .TP
3505 \f[B]Dp\f[R] $dx sub 1$ $dy sub 1$ $dx sub 2$ $dy sub 2$ $...$ $dx sub n$ $dy sub n$\[rs]n
3506 Draw a polygon with, for $i = 1 ,..., n+1$, the
3507 .IR i -th
3508 vertex at the current position
3509 .
3510 $+ sum from j=1 to i-1 ( dx sub j , dy sub j )$.
3511 .
3512 At the moment, GNU pic only uses this command to generate triangles
3513 and rectangles.
3514 .
3515 .TP
3516 \f[B]DP\f[R] $dx sub 1$ $dy sub 1$ $dx sub 2$ $dy sub 2$ $...$ $dx sub n$ $dy sub n$\[rs]n
3517 .
3518 Like
3519 .B Dp
3520 but draw a solid rather than outlined polygon.
3521 .
3522 .TP
3523 \f[B]Dt \f[I]n\/\f[R]\*[ic]\[rs]n
3524 Set the current line thickness to
3525 .IR n \~\c
3526 machine units.
3527 .
3528 Traditionally Unix troff drivers use a line thickness proportional to
3529 the current point size; drivers should continue to do this if no
3530 .B Dt
3531 command has been given, or if a
3532 .B Dt
3533 command has been given with a negative value of\~\c
3534 .IR n .
3535 A zero value of\~\c
3536 .I n
3537 selects the smallest available line thickness.
3538 .
3539 .P
3540 A difficulty arises in how the current position should be changed after
3541 the execution of these commands.
3542 .
3543 This is not of great importance since the code generated by GNU pic
3544 does not depend on this.
3545 .
3546 Given a drawing command of the form
3547 .IP
3548 \f[B]\[rs]D'\f[I]c\f[R] $x sub 1$ $y sub 1$ $x sub 2$ $y sub 2$ $...$ $x sub n$ $y sub n$\f[B]'\f[R]
3549 .
3550 .P
3551 where
3552 .I c
3553 is not one of
3554 .BR c ,
3555 .BR e ,
3556 .BR l ,
3557 .BR a ,
3558 or\~\c
3559 .BR \[ti] ,
3560 Unix troff treats each of the $x sub i$ as a horizontal quantity,
3561 and each of the $y sub i$ as a vertical quantity and assumes that
3562 the width of the drawn object is $sum from i=1 to n x sub i$,
3563 and that the height is $sum from i=1 to n y sub i$.
3564 .
3565 (The assumption about the height can be seen by examining the
3566 .B st
3567 and
3568 .B sb
3569 registers after using such a
3570 .BR D \~\c
3571 command in a
3572 .B \[rs]w
3573 escape sequence).
3574 .
3575 This rule also holds for all the original drawing commands with the
3576 exception of
3577 .BR De .
3578 For the sake of compatibility GNU troff also follows this rule, even
3579 though it produces an ugly result in the case of the
3580 .B Dt
3581 and
3582 .BR Df ,
3583 and, to a lesser extent,
3584 .B DE
3585 commands.
3586 .
3587 Thus after executing a
3588 .BR D \~\c
3589 command of the form
3590 .IP
3591 \f[B]D\f[I]c\f[R] $x sub 1$ $y sub 1$ $x sub 2$ $y sub 2$ $...$ $x sub n$ $y sub n$\[rs]n
3592 .
3593 .P
3594 the current position should be increased by
3595 .
3596 $( sum from i=1 to n x sub i , sum from i=1 to n y sub i )$.
3597 .
3598 .P
3599 Another set of extensions is
3600 .
3601 .TP
3602 \f[B]DFc \f[I]cyan magenta yellow\f[R]\*[ic]\[rs]n
3603 .TQ
3604 \f[B]DFd\f[R]\*[ic]\[rs]n
3605 .TQ
3606 \f[B]DFg \f[I]gray\/\f[R]\*[ic]\[rs]n
3607 .TQ
3608 \f[B]DFk \f[I]cyan magenta yellow black\f[R]\*[ic]\[rs]n
3609 .TQ
3610 \f[B]DFr \f[I]red green blue\f[R]\*[ic]\[rs]n
3611 Set the color components of the filling color similar to the
3612 .BR m \~\c
3613 commands above.
3614 .
3615 .P
3616 The current position isn\[aq]t changed by those colour commands
3617 (contrary to
3618 .BR Df ).
3619 .
3620 .
3621 .\" --------------------------------------------------------------------
3622 .SS "Device Control Commands"
3623 .\" --------------------------------------------------------------------
3624 .
3625 There is a continuation convention which permits the argument to the
3626 .B x\ X
3627 command to contain newlines: when outputting the argument to the
3628 .B x\ X
3629 command, GNU troff follows each newline in the argument with a
3630 .B +
3631 character (as usual, it terminates the entire argument with a
3632 newline); thus if the line after the line containing the
3633 .B x\ X
3634 command starts with
3635 .BR + ,
3636 then the newline ending the line containing the
3637 .B x\ X
3638 command should be treated as part of the argument to the
3639 .B x\ X
3640 command, the
3641 .B +
3642 should be ignored, and the part of the line following the
3643 .B +
3644 should be treated like the part of the line following the
3645 .B x\ X
3646 command.
3647 .
3648 .P
3649 The first three output commands are guaranteed to be:
3650 .IP
3651 .BI x\ T\  device
3652 .br
3653 .BI x\ res\  n\ h\ v
3654 .br
3655 .B x init
3656 .
3657 .
3658 .\" --------------------------------------------------------------------
3659 .SH INCOMPATIBILITIES
3660 .\" --------------------------------------------------------------------
3661 .
3662 In spite of the many extensions, groff has retained compatibility to
3663 classical troff to a large degree.
3664 .
3665 For the cases where the extensions lead to collisions, a special
3666 compatibility mode with the restricted, old functionality was created
3667 for groff.
3668 .
3669 .
3670 .\" --------------------------------------------------------------------
3671 .SS "Groff Language"
3672 .\" --------------------------------------------------------------------
3673 .
3674 .I groff
3675 provides a
3676 .B compatibility mode
3677 that allows to process roff code written for classical
3678 .B troff
3679 or for other implementations of roff in a consistent way.
3680 .
3681 .P
3682 Compatibility mode can be turned on with the
3683 .B \-C
3684 command line option, and turned on or off with the
3685 .B .cp
3686 request.
3687 .
3688 The number register
3689 .B \[rs]n(.C
3690 is\~1 if compatibility mode is on, 0\~otherwise.
3691 .
3692 .P
3693 This became necessary because the GNU concept for long names causes
3694 some incompatibilities.
3695 .I Classical troff
3696 interprets
3697 .IP
3698 .B .dsabcd
3699 .
3700 .P
3701 as defining a string
3702 .B ab
3703 with contents
3704 .BR cd .
3705 In
3706 .IR groff
3707 mode, this is considered as a call of a macro named
3708 .BR dsabcd .
3709 .
3710 .P
3711 Also
3712 .I classical troff
3713 interprets
3714 .B \[rs]*[
3715 or
3716 .B \[rs]n[
3717 as references to a string or number register called\~\c
3718 .B [
3719 while
3720 .I groff
3721 takes this as the start of a long name.
3722 .
3723 .P
3724 In
3725 .IR "compatibility mode" ,
3726 groff interprets these things in the traditional way; so long
3727 names are not recognized.
3728 .
3729 .P
3730 On the other hand, groff in
3731 .I GNU native mode
3732 does not allow to use the single-character escapes
3733 .B \[rs]\[rs]
3734 (backslash),
3735 .B \[rs]|
3736 (vertical bar),
3737 .B \[rs]^
3738 (caret),
3739 .B \[rs]&
3740 (ampersand),
3741 .B \[rs]{
3742 (opening brace),
3743 .B \[rs]}
3744 (closing brace),
3745 .RB \[oq] \[rs]\  \[cq]
3746 (space),
3747 .B \[rs]'
3748 (single quote),
3749 .B \[rs]`
3750 (backquote),
3751 .B \[rs]\-
3752 (minus),
3753 .B \[rs]_
3754 (underline),
3755 .B \[rs]!\&
3756 (bang),
3757 .B \[rs]%
3758 (percent),
3759 and
3760 .B \[rs]c
3761 (character\~c) in names of strings, macros, diversions, number
3762 registers, fonts or environments, whereas
3763 .I classical troff
3764 does.
3765 .
3766 .P
3767 The
3768 .B \[rs]A
3769 escape sequence can be helpful in avoiding these escape sequences in
3770 names.
3771 .
3772 .P
3773 Fractional point sizes cause one noteworthy incompatibility.
3774 .
3775 In
3776 .I classical
3777 .IR troff ,
3778 the
3779 .B ps
3780 request ignores scale indicators and so
3781 .RS
3782 .P
3783 .B .ps\~10u
3784 .RE
3785 .
3786 .P
3787 sets the point size to 10\~points, whereas in groff native mode the
3788 point size is set to 10\~scaled points.
3789 .
3790 .P
3791 In
3792 .IR groff ,
3793 there is a fundamental difference between unformatted input
3794 characters, and formatted output characters (glyphs).
3795 .
3796 Everything that affects how a glyph is output is
3797 stored with the glyph; once a glyph has been
3798 constructed it is unaffected by any subsequent requests that are
3799 executed, including the
3800 .BR bd ,
3801 .BR cs ,
3802 .BR tkf ,
3803 .BR tr ,
3804 or
3805 .B fp
3806 requests.
3807 .
3808 .P
3809 Normally glyphs are constructed from input characters at
3810 the moment immediately before the glyph is added to the current
3811 output line.
3812 .
3813 Macros, diversions and strings are all, in fact, the same type of
3814 object; they contain lists of input characters and glyphs
3815 in any combination.
3816 .
3817 .P
3818 Special characters can be both; before being added to the output, they
3819 act as input entities, afterwards they denote glyphs.
3820 .
3821 .P
3822 A glyph does not behave like an input character for the
3823 purposes of macro processing; it does not inherit any of the special
3824 properties that the input character from which it was constructed
3825 might have had.
3826 .
3827 The following example makes things clearer.
3828 .
3829 .P
3830 .RS
3831 .EX
3832 \&.di x
3833 \[rs]\[rs]\[rs]\[rs]
3834 \&.br
3835 \&.di
3836 \&.x
3837 .EE
3838 .RE
3839 .
3840 .P
3841 With
3842 .I GNU troff
3843 this is printed as
3844 .BR \[rs]\[rs] .
3845 So each pair of input backslashes \&\[oq]\[rs]\[rs]\[cq] is turned
3846 into a single output backslash glyph \&\[oq]\[rs]\[cq] and the
3847 resulting output backslashes are not interpreted as escape characters
3848 when they are reread.
3849 .
3850 .P
3851 .I Classical troff
3852 would interpret them as escape characters when they were reread and
3853 would end up printing a single backslash \[oq]\[rs]\[cq].
3854 .
3855 .P
3856 In GNU, the correct way to get a printable version of the backslash
3857 character \[cq]\[rs]\[cq]
3858 is the
3859 .B \[rs](rs
3860 escape sequence, but classical troff does not provide a clean feature
3861 for getting a non-syntactical backslash.
3862 .
3863 A close method is the printable version of the current escape
3864 character using the
3865 .B \[rs]e
3866 escape sequence; this works if the current escape character is not
3867 redefined.
3868 .
3869 It works in both GNU mode and compatibility mode, while dirty tricks
3870 like specifying a sequence of multiple backslashes do not work
3871 reliably; for the different handling in diversions, macro definitions,
3872 or text mode quickly leads to a confusion about the necessary number of
3873 backslashes.
3874 .
3875 .P
3876 To store an escape sequence in a diversion that is interpreted
3877 when the diversion is reread, either the traditional
3878 .B \[rs]!\&
3879 transparent output facility or the
3880 new
3881 .B \[rs]?\&
3882 escape sequence can be used.
3883 .
3884 .
3885 .\" --------------------------------------------------------------------
3886 .SS "Intermediate Output"
3887 .\" --------------------------------------------------------------------
3888 .
3889 The groff intermediate output format is in a state of evolution.
3890 .
3891 So far it has some incompatibilities, but it is intended to establish
3892 a full compatibility to the classical troff output format.
3893 .
3894 Actually the following incompatibilities exist:
3895 .
3896 .IP \[bu] 2m
3897 The positioning after the drawing of the polygons conflicts with the
3898 classical definition.
3899 .
3900 .IP \[bu] 2m
3901 The intermediate output cannot be rescaled to other devices as
3902 classical \[oq]device-independent\[cq] troff did.
3903 .
3904 .
3905 .\" --------------------------------------------------------------------
3906 .SH "SEE ALSO"
3907 .\" --------------------------------------------------------------------
3908 .
3909 The
3910 .I groff info
3911 .IR file ,
3912 cf.\&
3913 .BR info (1)
3914 presents all groff documentation within a single document.
3915 .
3916 .TP
3917 .BR groff (@MAN1EXT@)
3918 A list of all documentation around
3919 .IR groff .
3920 .
3921 .TP
3922 .BR groff (@MAN7EXT@)
3923 A description of the
3924 .I groff
3925 language, including a short, but complete reference of all predefined
3926 requests, registers, and escapes of plain
3927 .IR groff .
3928 From the command line, this is called using
3929 .
3930 .RS
3931 .IP
3932 .EX
3933 man 7 groff
3934 .EE
3935 .RE
3936 .
3937 .TP
3938 .BR roff (@MAN7EXT@)
3939 A survey of
3940 .I roff
3941 systems, including pointers to further historical documentation.
3942 .
3943 .TP
3944 .RI [ CSTR\~#54\/ ]
3945 The
3946 .I Nroff/\:Troff User\[aq]s Manual
3947 by
3948 .I J.\& F.\& Ossanna
3949 of 1976 in the revision of
3950 .I Brian Kernighan
3951 of 1992, being the
3952 .UR http://\:cm.bell-labs.com/\:cm/\:cs/\:cstr/\:54.ps.gz
3953 classical troff documentation
3954 .UE .
3955 .
3956 .
3957 .\" --------------------------------------------------------------------
3958 .SH COPYING
3959 .\" --------------------------------------------------------------------
3960 .co
3961 .\" --------------------------------------------------------------------
3962 .SH AUTHORS
3963 .\" --------------------------------------------------------------------
3964 .au
3965 .
3966 .
3967 .\" --------------------------------------------------------------------
3968 .\" Emacs variables
3969 .\" --------------------------------------------------------------------
3970 .
3971 .\" Local Variables:
3972 .\" mode: nroff
3973 .\" End: