On Tue, Sep 29, 2026 at 08:28:54AM +0300, Eli Zaretskii wrote:
> Btw, where in the Texinfo sources and/or documentation can one find a
> comprehensive information about this quoting, which could then be used
> to implement its support in Emacs?  I found only two places in the
> Texinfo manual that talk about this:
> 
>    • Unfortunately, you cannot reliably use periods, commas, or colons
>      within a node name; these can confuse some Info readers.
>      ‘texi2any’ quotes problematic node names and labels by default, but
>      some Info readers do not recognize this syntax.  Node name and
>      label quoting causes ‘DEL’ characters (‘CTRL-?’, character number
>      127, often rendered as ‘^?’) to appear around the name.  To remove
>      node names and labels quoting, you can set the customization
>      variable ‘INFO_SPECIAL_CHARS_QUOTE’ to ‘0’ (*note Info and
>      Plaintext Customization Variables::).
> 
>      ‘texi2any’ warns about such problematic usage in node names, menu
>      items, and cross-references.  If you don't want to see the
>      warnings, you can set the customization variable
>      ‘INFO_SPECIAL_CHARS_WARNING’ to ‘0’ (*note Info and Plaintext
>      Customization Variables::).
>  [...]
>      If <label> contains a colon character (:), it should be surrounded
>   with a pair of <del> characters.  Likewise, quoting characters may be
>   used for the node name if it contains problematic characters; then a
>   terminating comma or period is not needed.  As stated earlier, this
>   quoting mechanism is not supported in all Info-reading programs.
> 
> Is this all that there is to know, or are there other aspects of this?

It is used in the node information line if the node name contains a
comma (possibly for other problematic characters also), and is also used
for pointers to nodes in the node information line if the name of the
referenced node contains a comma.

It's in this text in the manual:

  Regular nodes look like this:
  
           <node> =
       <separator>
       File: <fn>, Node: <id1>, (Next: <id2>, )? (Prev: <id3>, )? Up: <id4>
  
       <general text, until the next ^_ or end-of-file>
  
  At least one space or tab must be present after each colon and comma,
  but any number of spaces are ignored.  The <id> node identifiers have
  following format:
  
          <id> = (<lparen><infofile><rparen>)?<node-spec>?
          <node-spec> = <nodename> | <del><nodename><del>
          <del> = ^?

  ...

     Node names containing periods, commas, colons or parentheses can
  confuse Info readers.  If it is necessary to refer to a node whose name
  contains any of these, the <nodename> should be surrounded by a pair of
  ‘DEL’ characters (‘CTRL-?’, character number 127).  ‘makeinfo’ adds
  these characters when needed in the default case.  Note that not all
  Info readers recognize this syntax.  *Note Info Node Names
  Constraints::.

Info node "(texinfo)Info Format Regular Nodes".

Note also that the DEL-quoting mechanism is not used in the Tag Table
section of the Info file.

> Also, where in the stand-alone Info reader is this quoting handled?
> Is read_quoted_string the only place?

It's anywhere that INFO_QUOTE or INFO_QUOTE_STR (defined in scan.h) is
used.  It is nearly all in scan.c in the functions read_quoted_string,
scan_reference_label, scan_reference_target and scan_node_contents.  It
is also used in one place in indices.c (in format_reference) when
generating a node.



> 
> Thanks.
> 

Reply via email to