On Thu, 1 Feb 2024, RVP wrote:

 (xterm-direct analyzed this way also only reports

 xterm-direct|xterm with direct-color indexing,
 ...
    colors#0x7fff, cols#80, it#8, lines#24, pairs#0x7fff,
 ...
)

Same bug, I think: if any num. capability has a value >0x7fff
(INT16_MAX), then that terminfo entry should get "promoted" to use
32-bit integers. This isn't happening.


... is what I said, but, that's not right. Since this output is from
the _ncurses infocmp_ rather than the BSD one, that clamping is expected,
(so Tom Dickey told me), when ncurses isn't compiled with `--enable-widec'.

You can see this happening when you install ncurses:

```
$ make install
[...]
/bin/sh ./run_tic.sh
** Building terminfo database, please wait...
Running sh ../../ncurses-6.4/misc/shlib tic to install /tmp/N/share/terminfo ...

        You may see messages regarding extended capabilities, e.g., AX.
        These are extended terminal capabilities which are compiled
        using
                tic -x
        If you have ncurses 4.2 applications, you should read the INSTALL
        document, and install the terminfo without the -x option.

ncurses 6.4.20221231
"terminfo.tmp", line 1232, col 36, terminal 'fbterm': limiting value of `pairs' 
from 0x10000 to 0x7fff
"terminfo.tmp", line 5326, col 36, terminal 'xterm+256color': limiting value of 
`pairs' from 0x10000 to 0x7fff
"terminfo.tmp", line 5358, col 36, terminal 'xterm+256setaf': limiting value of 
`pairs' from 0x10000 to 0x7fff
"terminfo.tmp", line 5405, col 25, terminal 'xterm+direct2': limiting value of 
`colors' from 0x1000000 to 0x7fff
"terminfo.tmp", line 5405, col 40, terminal 'xterm+direct2': limiting value of 
`pairs' from 0x10000 to 0x7fff
"terminfo.tmp", line 5420, col 25, terminal 'xterm+direct': limiting value of 
`colors' from 0x1000000 to 0x7fff
"terminfo.tmp", line 5420, col 40, terminal 'xterm+direct': limiting value of 
`pairs' from 0x10000 to 0x7fff
"terminfo.tmp", line 5442, col 25, terminal 'xterm+indirect': limiting value of 
`colors' from 0x1000000 to 0x7fff
"terminfo.tmp", line 5442, col 40, terminal 'xterm+indirect': limiting value of 
`pairs' from 0x10000 to 0x7fff
"terminfo.tmp", line 8597, col 36, terminal 'dvtm-256color': limiting value of 
`pairs' from 0x10000 to 0x7fff
1814 entries written to /tmp/N/share/terminfo
[...]
$
```

Sorry for the mixup!

-RVP

Reply via email to