[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Groff] Line fragments with .TS and .PSPIC
From: |
Werner LEMBERG |
Subject: |
Re: [Groff] Line fragments with .TS and .PSPIC |
Date: |
Mon, 22 Aug 2005 10:17:04 +0200 (CEST) |
Frank,
I take the liberty to CC the groff list.
> Thanks for your solution to the problem. As I played with it, I
> realized that the key was changing the environment. Without using
> any macro package, I found that the following also works if placed
> at the beginning of the text file:
>
> .de TS
> 'sp
> .ev here-table
> ..
> .de TE
> .ev
> 'sp
> ..
Yes, indeed, but I suggest that you don't omit the call to `.evc' to
make the new environment identical to the previous one.
Below is a simpler solution which happens to be even more generic (and
which no longer needs tbl's `nokeep' keyword). It is also more
careful which environment to copy.
Werner
======================================================================
.\" This call to .LP initializes .TS and .TE so that we can overwrite
.\" them safely.
.LP
.
.rn TS address@hidden
.rn TE address@hidden
.
.de TS
. nr here-table-ev \\n[.ev]
. ev here-table
. evc \\n[here-table-ev]
. address@hidden
..
.
.de TE
. address@hidden
. ev
..
.
.
This is the text that goes before the table.
This is some more text that goes before the table.
I suppose I could have used a larger point size to
make it easier but I didn't think of that until now.
.
.TS
l l
l l.
entry1 entry2
entry3 entry4
entry5 entry6
.TE
.
This text follows the table.
Here is some more text to follow the table.