[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [Groff] Macros and Spaces
From: |
Ted Harding |
Subject: |
RE: [Groff] Macros and Spaces |
Date: |
Fri, 01 Aug 2003 22:18:21 +0100 (BST) |
On 01-Aug-03 Jeremy Cowgar wrote:
> I am curious, how can I create a macro that does not introduce a space?
> For instance, here is a small snipplet.
>
> .de verseId
> .nr bibleVerse \\$1
> .ps -3
> \\fB\\v'-0.10v'\\$1\\v'0.10v'\\h'-0.1m'\\fR
> .ps +3
> ..
>
> Hello, this is a verse,
> .verseId 2
> This is verse two.
>
> The problem is that between the 2 and the word "This" is a space, and
> it
> does get broken at bad places, such as at the end of a line, so the
> verse id is on the end of the line and the verse starts on the next.
>
> I tried adding a \~ to the end of \\fR with no luck.
Try
\\fB\\v'-0.10v'\\$1\\v'0.10v'\\h'-0.1m'\\fR\~\c
You get your stretchable unbreakable space (though with your "\\h'-0.1m'"
it doesn't particularly show), and the \c ("continuation") eliminates the
space that is normally output following the end of an input line -- i.e.
the next input line is treated as a continuation of the current one, as
if it had been typed on the same line.
Ted.
--------------------------------------------------------------------
E-Mail: (Ted Harding) <address@hidden>
Fax-to-email: +44 (0)870 167 1972
Date: 01-Aug-03 Time: 22:18:21
------------------------------ XFMail ------------------------------