groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: code review and strategy for macros set?


From: Robert Thorsby
Subject: Re: code review and strategy for macros set?
Date: Tue, 11 Aug 2020 19:25:31 +1000

On 11/08/20 18:27:10, Marc Chantreux wrote:
i finally took some time to write some roff without the help of existing macros set so i could figure out how hard it would maintain my own page layout and macros set.
...
is there a good practice or a common strategy for this situation? are you maintaining your own macro set (at work or for your local clubs for example)?

G'day Marc,

Your question devolves into, "How long is a piece of string?".

It depends on what you intend to do. Like all markup languages *roff is almost purpose built for incorporating into one's favourite text processing application -- in my case, shell scripting with much heavy lifting by sed, awk and friends.

So, if you have a lot of boiler plate text (or boiler plate formatting, for that matter) you can use native *roff and use your application to do most of the "macro" work.

On the other hand, you can use just about any macro set to achieve what you want -- ranging to the old and venerable ms and me to the ultra-modern (in groff terms) mom.

To give you an idea of what can be achieved without a macro set, see the attached. [If you are a serious typesetter I recommend you have a stiff drink before opening the PDF file.] The CLI to create the file is:

groff -p -Tps -dpaper=a4 -P-pa4 model_details.gr | ps2pdf -sPAPERSIZE=a4 \ -sColorModel=Gray -dPDFSETTINGS=/prepress -dEmbedAllFonts=true - model_details.pdf

Cheers,
Robert

Attachment: model_details.pdf
Description: Adobe PDF document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]