Hi,
I think there is a bug in ncurses 5.9 using xterm on Ubuntu
18.04.
address@hidden:~$ ll
/lib/x86_64-linux-gnu/libncurses.so.5*
lrwxrwxrwx 1 root root 17 May 23 10:08
/lib/x86_64-linux-gnu/libncurses.so.5 -> libncurses.so.5.9
-rw-r--r-- 1 root root 141248 May 23 10:08
/lib/x86_64-linux-gnu/libncurses.so.5.9
address@hidden:~$ uname -a
Linux OTDU-1U-ERIC 4.15.0-22-generic #24-Ubuntu SMP Wed May 16
12:15:17 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
address@hidden:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04 LTS
Release: 18.04
Codename: bionic
address@hidden:~$ cat curses_tst.c
#include <stdlib.h>
#include <curses.h>
int main(void)
{
initscr();
raw();
noecho();
mvaddstr(1, 0, "-");
mvaddstr(2, 0, "--");
mvaddstr(3, 0, "---");
mvaddstr(4, 0, "----");
mvaddstr(5, 0, "-----");
mvaddstr(6, 0, "------");
mvaddstr(7, 0, "-------");
mvaddstr(8, 0, "--------");
mvaddstr(10, 0, "Press a key ... ");
getch();
clear();
endwin();
return EXIT_SUCCESS;
}
address@hidden:~$ echo $TERM
xterm
address@hidden:~$ ./curses_tst
-
--
---
----
-----
------
-
-
Press a key ...
I get half a pine tree and not half a pyramid.
On the same PC, the same executable works fine on a VGA console
(TERM=linux) or serial console (TERM=vt220).
Best regards
Éric
--
Éric Lévénez, VIERLING Communication S.A.S.
1 rue Blaise Pascal, Parc d'activité de Pissaloup, 78190 Trappes, France
+33(0)1.30.81.26.10 address@hidden