File: groff.info, Node: Differences from AT&T ms, Next: ms_Naming_Conventions.php">ms Naming Conventions, Prev: ms_Page_Layout.php">ms Page Layout, Up: ms 4.6.7 Differences from AT&T 'ms' -------------------------------- The 'groff' 'ms' macros are an independent reimplementation, using no AT&T code. Since they take advantage of the extended features of 'groff', they cannot be used with AT&T 'troff'. 'groff' 'ms' supports features described above as Berkeley and Tenth Edition Research Unix extensions, and adds several of its own. * The internals of 'groff' 'ms' differ from the internals of AT&T 'ms'. Documents that depend upon implementation details of AT&T 'ms' may not format properly with 'groff' 'ms'. Such details include macros whose function was not documented in the AT&T 'ms' manual.(1) (*note Differences from AT&T ms-Footnote-1::) * The error-handling policy of 'groff' 'ms' is to detect and report errors, rather than to ignore them silently. * Tenth Edition Research Unix supported 'P1'/'P2' macros to bracket code examples; 'groff' 'ms' does not. * 'groff' 'ms' does not work in GNU 'troff''s AT&T compatibility mode. If loaded when that mode is enabled, it aborts processing with a diagnostic message. * Multiple line spacing is not supported. Use a larger vertical spacing instead. * 'groff' 'ms' uses the same header and footer defaults in both 'nroff' and 'troff' modes as AT&T 'ms' does in 'troff' mode; AT&T's default in 'nroff' mode is to put the date, in U.S. traditional format (e.g., "January 1, 2021"), in the center footer (the 'CF' string). * Many 'groff' 'ms' macros, including those for paragraphs, headings, and displays, cause a reset of paragraph rendering parameters, and may change the indentation; they do so not by incrementing or decrementing it, but by setting it absolutely. This can cause problems for documents that define additional macros of their own that try to manipulate indentation. Use the 'ms' 'RS' and 'RE' macros instead of the 'in' request. * AT&T 'ms' interpreted the values of the registers 'PS' and 'VS' in points, and did not support the use of scaling units with them. 'groff' 'ms' interprets values of the registers 'PS', 'VS', 'FPS', and 'FVS' equal to or larger than 1,000 (one thousand) as decimal fractions multiplied by 1,000.(2) (*note Differences from AT&T ms-Footnote-2::) This threshold makes use of a scaling unit with these parameters practical for high-resolution devices while preserving backward compatibility. It also permits expression of non-integral type sizes. For example, 'groff -rPS=10.5p' at the shell prompt is equivalent to placing '.nr PS 10.5p' at the beginning of the document. * AT&T 'ms''s 'AU' macro supported arguments used with some document types; 'groff' 'ms' does not. * Right-aligned displays are available. The AT&T 'ms' manual observes that "it is tempting to assume that '.DS R' will right adjust lines, but it doesn't work". In 'groff' 'ms', it does. * To make 'groff' 'ms' use the default page offset (which also specifies the left margin), the 'PO' register must stay undefined until the first 'ms' macro is called. This implies that '\n[PO]' should not be used early in the document, unless it is changed also: accessing an undefined register automatically defines it. * 'groff' 'ms' supports the 'PN' register, but it is not necessary; you can access the page number via the usual '%' register and invoke the 'af' request to assign a different format to it if desired.(3) (*note Differences from AT&T ms-Footnote-3::) * The AT&T 'ms' manual documents registers 'CW' and 'GW' as setting the default column width and "intercolumn gap", respectively, and which applied when 'MC' was called with fewer than two arguments. 'groff' 'ms' instead treats 'MC' without arguments as synonymous with '2C'; there is thus no occasion for a default column width register. Further, the 'MINGW' register and the second argument to 'MC' specify a _minimum_ space between columns, not the fixed gutter width of AT&T 'ms'. * The AT&T 'ms' manual did not document the 'QI' register; Berkeley and 'groff' 'ms' do. -- Register: \n[GS] The register 'GS' is set to 1 by the 'groff' 'ms' macros, but is not used by the AT&T 'ms' package. Documents that need to determine whether they are being formatted with 'groff' 'ms' or another implementation should test this register. * Menu: * Missing Unix Version 7 ms Macros::