[Top][All Lists]

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

Re: .SPACE in mom

From: Ulrich Lauther
Subject: Re: .SPACE in mom
Date: Thu, 11 Nov 2021 23:05:37 +0100

Here is a macro to be used with mom, that moves to a distance down from top or
up from bottom, depending on the sign of the argument:

.\" Goto position relative to top or bottom of page depending
.\" on sign of argument, respecting margins with parameter "m"
.\" Examples: .Goto -3c / .Goto 3c m
.  ie \\$1<0 \{\
.    nr tmp \\n[#PAGE_LENGTH]+\\$1-\\n[#LEAD]
.    if '\\$2'm' .nr tmp \\n[tmp]-\\n[#B_MARGIN]
.  \}
.  el \{\
.    nr tmp \\$1
.    if '\\$2'm' .nr tmp \\n[tmp]+\\n[#T_MARGIN]
.  vpt 0
.  SP |\\n[tmp]u
.  vpt

Have fun,


reply via email to

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