On Mon, Oct 27, 2025 at 07:58:42PM -0500, G. Branden Robinson wrote:
> Hi Thomas,
> 
> At 2025-10-27T04:15:57-0400, Thomas Dickey wrote:
> > On Sun, Oct 26, 2025 at 10:26:27PM -0500, G. Branden Robinson wrote:
> > > What's wrong turns out to be straightforward, but not necessarily
> > > easy to fix.
> > > 
> > > The problem is use of the 'x' column modifier in tbl(1) tables.
> > > Solaris 10 tbl rejects it and "tbl quits".
> > > 
> > > Heirloom Doctools troff claims that 'x' is a GNU extension.  It's
> > > not.  But GNU tbl is probably how most people came to know of it,
> > > because I can't find a trace of it in any AT&T troff lineage except
> > > DWB 3.3.  It's not in Research Tenth Edition Unix tbl nor Plan 9 tbl
> > > despite some cross-pollination that happened between DWB and
> > > Research troffs.
> > > 
> > > I'm updating groff's tbl(1) page to clarify this point.
> > > 
> > > The question for ncurses is what to do about it.  It'll take me some
> > > time to ponder possibilities.
> > 
> > If it's "only" the s/Lx/L/g, then that could be done with a configure
> > check for the special case of antique nroff, and a substitution for
> > make-sed.sh
> 
> That's true.  In my opinion 'x' is too nice a feature to do without
> unless one has to, so it's worth complicating your CF_MAN_PAGES Autoconf
> macro to take care of it.
> 
> I have a little experience with Autoconf and m4 but it pales to yours.
> If you'd prefer I worked on this, just say so.  But if you'd prefer to
> do it yourself, here's a macro for testing a tbl program for this
> feature that's about as minimal as I can make it.

thanks - I can adapt this (use it as a starting point)
 
> AC_DEFUN([TBL_SUPPORTS_X_COLUMN_MODIFIER], [
>   tbl_supports_x_column_modifier=no
>   AC_MSG_CHECKING([whether 'tbl' program supports 'x' column modifier])
>   if ! command -v tbl > /dev/null 2>&1
>   then
>     AC_MSG_ERROR(['tbl' not available.], 1)
>   fi
>   if printf '.TS\nLx.\ntable cell\n.TE\n' | tbl > /dev/null 2>&1
>   then
>     tbl_supports_x_column_modifier=yes
>   fi
>   AC_MSG_RESULT([$tbl_supports_x_column_modifier])
> ])
> 
> Regards,
> Branden



-- 
Thomas E. Dickey <[email protected]>
https://invisible-island.net

Attachment: signature.asc
Description: PGP signature

Reply via email to