Re: 1.23 prints some strange error

2023-10-05 Thread Walter Alejandro Iglesias
On Wed, Oct 04, 2023 at 10:20:57PM +, Bjarni Ingi Gislason wrote:
>   Latin1 iacute has the utf8 code 'í'
> and the hexadecimal code is C3AD which is "LATIN CAPITAL LETTER A WITH
> TILDE" and "SOFT HYPHEN"
> 
> "groff" turns "soft hyphen" into "HYPHEN-MINUS" (0x2D)
> 
> More is in the attachment.

> file list.tr
> 
> .hw a-hÃ-
> .hw a-ño
> .hw ár-bol
> .hw cu-brÃ--a
> .hw e-té-re-o
> .hw ca-mión
> .hw ú-te-ro
> .hw pin-güi-no
> 
> Output from "preconv -e utf8  list.tr
> 
> .lf 1 list.tr
> .hw a-h\[uFFFD]-
> .hw a-\[u00F1]o
> .hw \[u00E1]r-bol
> .hw cu-br\[uFFFD]--a
> .hw e-t\[u00E9]-re-o
> .hw ca-mi\[u00F3]n
> .hw \[u00FA]-te-ro
> .hw pin-g\[u00FC]i-no
> 
> Translate "list.tr" to latin1
> 
> iconv -f utf8 -f latin1 list.tr
> 
> .hw a-h
> 
> iconv: illegal input sequence at position 7

The list.tr you're using in this example is already latin1.
Repeat what you did but this time with a UTF-8 list.tr. :-)


> 
> \[uFFFD] is called "replacement character".
> 
> -.-
> 
>   Latin1 iacute has the utf8 code 'í'
> and the hexadecimal code is C3AD which is "LATIN CAPITAL LETTER A WITH
> TILDE" and "SOFT HYPHEN"
> 
> "groff" turns "soft hyphen" into "HYPHEN-MINUS" (0x2D)

-- 
Walter



Re: 1.23 prints some strange error

2023-10-05 Thread Walter Alejandro Iglesias
On Thu, Oct 05, 2023 at 10:08:50AM +0200, Walter Alejandro Iglesias wrote:
> On Wed, Oct 04, 2023 at 10:20:57PM +, Bjarni Ingi Gislason wrote:
> >   Latin1 iacute has the utf8 code 'í'
> > and the hexadecimal code is C3AD which is "LATIN CAPITAL LETTER A WITH
> > TILDE" and "SOFT HYPHEN"
> > 
> > "groff" turns "soft hyphen" into "HYPHEN-MINUS" (0x2D)
> > 
> > More is in the attachment.
> 
> > file list.tr
> > 
> > .hw a-hÃ-
> > .hw a-ño
> > .hw ár-bol
> > .hw cu-brÃ--a
> > .hw e-té-re-o
> > .hw ca-mión
> > .hw ú-te-ro
> > .hw pin-güi-no
> > 
> > Output from "preconv -e utf8  list.tr
> > 
> > .lf 1 list.tr
> > .hw a-h\[uFFFD]-
> > .hw a-\[u00F1]o
> > .hw \[u00E1]r-bol
> > .hw cu-br\[uFFFD]--a
> > .hw e-t\[u00E9]-re-o
> > .hw ca-mi\[u00F3]n
> > .hw \[u00FA]-te-ro
> > .hw pin-g\[u00FC]i-no
> > 
> > Translate "list.tr" to latin1
> > 
> > iconv -f utf8 -f latin1 list.tr
> > 
> > .hw a-h
> > 
> > iconv: illegal input sequence at position 7
> 
> The list.tr you're using in this example is already latin1.
> Repeat what you did but this time with a UTF-8 list.tr. :-)

Now I realize you used a latin1 list.tr on purpose, right?  If that's
the case, sorry!

If I feed preconv with a file already in latin1 (using UTF-8 locales
here) ...

  $ preconv -e utf8 list_in_latin1.tr

... *all* non ASCII characters in the output are replaced by \[uFFFD].

It seems that when I call the file as a macro (using .mso list.tr) that
particular utf8 character (iacute) is read wrongly by groff, presumably
because of what you noticed.


> 
> 
> > 
> > \[uFFFD] is called "replacement character".
> > 
> > -.-
> > 
> >   Latin1 iacute has the utf8 code 'í'
> > and the hexadecimal code is C3AD which is "LATIN CAPITAL LETTER A WITH
> > TILDE" and "SOFT HYPHEN"
> > 
> > "groff" turns "soft hyphen" into "HYPHEN-MINUS" (0x2D)
> 


-- 
Walter



Re: [htmlxref.cnf] Please update link to the Groff manual

2023-10-05 Thread Ingo Schwarze
Hi Branden,

G. Branden Robinson wrote on Sun, Oct 01, 2023 at 06:53:30PM -0500:

> So while changing the name of the directory back to html_node will fix
> some broken link problems, it won't fix them all, and it won't be robust
> in the face of future development.  I'm fairly neutral on the
> "html_node" vs. "groff.html.node" naming issue, but I'm downright
> _opposed_ to limiting my (or future contributors') flexibility in
> updating, expanding, reducing, or otherwise mutating the node names of
> the groff Texinfo manual.  Those shackles are much too tight.

Agreed.  Of course changing the content of documentation must always
be possible, including removing obsolete content.  Renaming nodes
may occasionally make sense, too.

> A.  Put the groff 1.22.4 manual back online, probably as
> https://www.gnu.org/software/groff/manual/groff-1.22.4/html_node/

While that is unlikely to do much harm, i'm not sure it is needed.
I don't think we encourige using old versions of groff, so it is
unlikely to help normal users.  It may occasionally be useful for
people researching the history of groff, though not all that much
because git serves that purpose better.  It may occasionally
contribute to confusion when search engines return deep links
into old documentation to unsuspecting users.  Not a big deal
either way, i guess.

> ...and have
> https://www.gnu.org/software/groff/manual/html_node/
> symlink/redirect to it.

I don't really like that idea.

Many old web pages talk about groff in general rather than about
specific historical versions of groff.  So being pointed at the
current documentation is likely more useful for most users than
being pointed at documentation for some historical version.
Besides, even if a site talks about a definite version of groff,
that's unlikely to be specifically 1.22.4.

Even if a deep link from an old website dies because the content
of groff documentation changes, i don't think that is necessarly
a bad thing.  It may alert the user following the link that the
underlying functionality of groff in the region the website talks
about has likely evolved.

That doesn't mean links to the top level of the manual should break,
unless we are planning to abandon or rename groff as a whole.  ;-)

Please don't overthink all this.  Keeping links stable is good when
it is easily possible, but it's normal that substantially improving
the content of a website implies that *some* URIs occasionally break,
in particular deep links.

> Okay, I am reminded why the suits hate deep linking.  :-|

I don't think that's the reason.  The suits want visitors of their
company website to see the advertisements of the day on the start page,
both to drive marketing and sales and, as you pointed out, to boost
their personal ego.  They want visitors to use the navigation tools
provided by the website itself such that marketing can effectively
steer visitors to those products that generate the best profit - what
the visitors were actually looking for may sometimes be considered of
secondary importance at best.  Many suits care less about efficient
and reliable access to detailed and technical information.

The general rule "if you care about the reliability of your links,
don't link more deeply than you have good reasons to", on the other
hand, is not limited to suits.  I try to abide by that rule, too.

Yours,
  Ingo