From mboxrd@z Thu Jan 1 00:00:00 1970 From: lyndon@orthanc.ca (Lyndon Nerenberg) Date: Tue, 22 Mar 2011 11:21:55 -0700 Subject: [9fans] troff macros for typesetting books/longer texts In-Reply-To: References: Message-ID: Topicbox-Message-UUID: beaed704-ead6-11e9-9d60-3106f5b1d025 > Actually, I know of both mentioned places. But, as far as I know, the > very macros are not discussed anywhere. But I may be, of course, > wrong. My guess is these works fall into two categories: 1) the author uses (say) ms, and extends it with macros in the document source code to achieve the bits that pure ms doesn't provide. 2) the author starts with (say) ms, then customizes it for the specific task at hand. In either case, the customizations are locked in with the document source and don't get distributed. Or they are so tied in with a specific document that they're of no practical use as standalone tools. I've done both when writing documentation, and in all those years I've never come up with a macro package specifically for that task. The reason being there is too much variablity in what I need. The effort it would require to write a general purpose macro package to encompass all those variations would be self defeating. It's considerably faster (for me) to do these customizations on a per-document basis. Over the years I have developed patterns in how I design these one-offs, but the results are never quite the same between any two documents. I usually use ms as the scaffolding, writing additional macros to provide the higher level concepts (e.g. chapters). While it's possible to muck around inside the ms macros themselves, the result isn't portable. I've learned to be careful not to get too caught up in trying to make ms do things it doesn't want to. Sometimes it's easier to just write your own macro set for the specific task at hand. (Re-implementing basics like .LP, .PP, .IP, .SH, etc. is quite easy if you don't require all the generalizations ms provides.) --lyndon