On Tue, Jul 12, 2022 at 08:32:42AM -0500, Eric Blake wrote: > On Thu, Jun 09, 2022 at 07:26:10PM +0100, Gavin Smith wrote: > > My preferred solution for this at the moment is to add a new command, > > akin to @deftypefnnewline, which would toggle whether a space was > > output after the definition name. It would be included in Texinfo > > source files if required. This would be fairly straightforward to > > implement. In texinfo.tex, the space is output in \defname, and this > > could easily be made conditional: > > Adding a new command to suppress the space after \defname sounds > reasonable. I'd be happy to test how that looks in the m4 manual, > although I'm not a texinfo.tex expert to write such a patch myself.
With the patch below, you need to add @clear txidefnamespace early in the manual. I checked briefly with the m4 manual source from https://www.gnu.org/software/m4/manual/ and the results looked good. This follows the pattern of a few other options being controlled with @set flags with names beginning "txi", which allows it to be implemented in an backwards-compatible way. It would be easy to change the name of this option or to change it to a @set rather than a @clear, if there was a better suggestion. Once I get some feedback on this, I'll commit the change and start work on making the change in texi2any. I think this is a very important change to make for the sake of m4 where the space is incorrect! diff --git a/doc/texinfo.tex b/doc/texinfo.tex index a2bcf60e49..c0e33f1780 100644 --- a/doc/texinfo.tex +++ b/doc/texinfo.tex @@ -7835,12 +7835,16 @@ might help (with 'rm \jobname.?? \jobname.??s')% \fi % no return type #3% output function name }% - {\rm\enskip}% hskip 0.5 em of \rmfont + \expandafter\ifx\csname SETtxidefnamespace\endcsname\relax\else + {\rm\enskip} % hskip 0.5 em of \rmfont + \fi % \boldbrax % arguments will be output next, if any. } +\set txidefnamespace + % Print arguments in slanted roman (not ttsl), inconsistently with using % tt for the name. This is because literal text is sometimes needed in % the argument list (groff manual), and ttsl and tt are not very