groff
[Top][All Lists]
Advanced

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

Re: [Groff] Line fragments with .TS and .PSPIC


From: Ted Harding
Subject: Re: [Groff] Line fragments with .TS and .PSPIC
Date: Sat, 20 Aug 2005 15:52:42 +0100 (BST)

On 20-Aug-05 Werner LEMBERG wrote:
> 
>> I've been using groff and tbl with FreeBSD 4.2.  Whenever I insert
>> a table or an image, there seems to be a hard carriage return that
>> prints out a line fragment instead of carrying that text to be filled
>> with the next line of input after the table.  [...]
> 
> Small example, please.
> 
> 
>     Werner

I think what frank is referring to is the following sort of thing:
using   groff -t -Tlatin1 -ms   on

troff source
============

.LP
.2C
This text illustrate the problem of
inserting
.TS
centre tab(#);
c c.
Header1#Header2
.T&
l l.
_
Entry 1.1#Entry 1.2
Entry 2.1#Entry 2.2
=
.TE
a table in the middle of a line of text.
This text illustrate the problem of
inserting a table in the middle of a line of text.


gives the output
================

This   text  illustrate  the
problem of inserting

    Header1     Header2
   ----------------------
   Entry 1.1   Entry 1.2
   Entry 2.1   Entry 2.2
   ----------------------

a table in the middle  of  a
line  of  text.   This  text
illustrate  the  problem  of
inserting  a  table  in  the
middle of a line of text.

============================

showing that the output line is broken at the point
where the source code has ".TS", while what he would
really like is the output
=========================

This   text  illustrate  the
problem of inserting a table

    Header1     Header2
   ----------------------
   Entry 1.1   Entry 1.2
   Entry 2.1   Entry 2.2
   ----------------------

in  the  middle of a line of
text.  This text  illustrate
the  problem  of inserting a
table in  the  middle  of  a
line of text.

============================

without having to rearrange the input lines. This could
in principle be arranged by diverting the ".TS ... .TE"
(possibly with ".TS" and ".TE" re-defined) to a diversion
which planted a line trap relative to the current vertical
position, so that the tabular stuff was output once the
current output-line was completed by filling from the
input which follows the ".TS" block.

I've tried a few versions of this approach on the above
problem, without getting satisfactory results so far (but
I confess to finding the "trap" stuff obscure and confusing
-- I've often succeeded with it, but without ever being
quite sure why!).

Maybe others know better ...

Best wishes to all,
Ted.


--------------------------------------------------------------------
E-Mail: (Ted Harding) <address@hidden>
Fax-to-email: +44 (0)870 094 0861
Date: 20-Aug-05                                       Time: 15:51:56
------------------------------ XFMail ------------------------------




reply via email to

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