bug-texinfo
[Top][All Lists]
Advanced

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

Re: texinfo-6.8.90 pretest


From: Gavin Smith
Subject: Re: texinfo-6.8.90 pretest
Date: Thu, 20 Oct 2022 17:34:06 +0100

On Thu, Oct 20, 2022 at 04:42:45PM +0200, Patrice Dumas wrote:
> > Building the latest emacs master manuals with the latest texinfo
> > master gives the following warning which I donʼt see with texinfo 6.7:
> > 
> >     killing.texi:573: warning: @pxref should not appear in @w
> > 
> > The relevant source looks like this:
> > 
> >     platforms, Emacs can yank these objects with the @code{yank-media}
> >     command---but only in modes that have support for it (@w{@pxref{Yanking
> >     Media,,, elisp, The Emacs Lisp Reference Manual}}).
> > 
> > Is there a reason for this new warning?
> 
> Previously there were no check at all on @w content.  I assumed that @w
> could only contain "simple text" which meant all the inline @-commands
> except for 'titlefont', 'anchor', 'footnote', 'verb', 'xref', 'ref',
> 'pxref', 'inforef'.

I don't see any reason why @w shouldn't contain anything that
can be output inside a paragraph, except maybe for @footnote.  I
see it like @code, that @code is used only paragraphs, but

@code{aaa

bbb}

is incorrect.

In tp/Texinfo/XS/parsetexi/command_data.txt, @w is sui generis and it
would be a good simplification to eliminate the contain_simple_text
flag.

> Actually, for this specific example it seems to me that the code put on
> @w is too long to allow for correct display.  I checked in HTML, and
> indeed, the non breakable part seems to me to be too long to allow for
> good rendering, unless the browser width is within a specific range.
> Wouldn't you obtain the effect you want or even something better by
> simply using @w for the arguments of the @pxref instead, possible adding
> a third argument in @w?

I don't see the need to issue a new warning here, even if a document
has no real reason to be using @w.  There will likely be enough breakage
and inconvenience from the new release that we can't avoid, without
adding to it.  Fundamentally, it's clear what @pxref inside @w should
mean and as long as texi2any does it without any difficulty, we don't
need to worry about it.

However, there are problems with the output:

  platforms, Emacs can yank these objects with the @code{yank-media}
  command---but only in modes that have support for it (@w{@pxref{Yanking 
  Media,,, elisp, The Emacs Lisp Reference Manual}}).

(with a space after "Yanking", which may be lost in this email)

outputs an extra space between Yanking and Media:

  platforms, Emacs can yank these objects with the ‘yank-media’
  command—but only in modes that have support for it
  (*note (elisp)Yanking  Media::).

This is contrary to what texinfo.tex does, which doesn't treat
spaces specially in @w.

In theory there is a potential problem with a @footnote inside @w.
Should line breaks inside the @footnote be forbidden?  I would say
not.  texi2any.pl appears to do the right thing here.  However,
texinfo.tex does not - the footnote disappears completely!

  @w{aaa@footnote{ddd
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd  ddd dd dd dd 
  fwe}bbb}

I'm going to try to investigate these two issues.



reply via email to

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