From 7e062bb2764a87d98073a90ee65a234a2679f9c1 Mon Sep 17 00:00:00 2001 From: "Thomas E. Dickey" Date: Mon, 2 Oct 2023 00:24:04 +0000 Subject: [PATCH] ncurses 6.4 - patch 20231001 + modify setupterm to provide for using ANSI cursor-position report (in user6/user7 terminfo capabilities) to obtain screensize if neither environment variables or ioctl is used. The ncurses test-program with options "-E -T" demonstrates this feature. + improve error messages in tic (patch by Branden Robinson). + improve formatting/style of manpages (patches by Branden Robinson). + modify test/clip_printw.c to optionally test non-wrapped updates. + fix reallocation loop for vsnprintf() in _nc_sprintf_string() by copying the va_list variable (patch by Ian Abbott). --- NEWS | 13 +- VERSION | 2 +- dist.mk | 4 +- doc/html/man/adacurses6-config.1.html | 110 +-- doc/html/man/captoinfo.1m.html | 227 ++--- doc/html/man/clear.1.html | 117 ++- doc/html/man/curs_add_wch.3x.html | 10 +- doc/html/man/curs_add_wchstr.3x.html | 10 +- doc/html/man/curs_addch.3x.html | 10 +- doc/html/man/curs_addchstr.3x.html | 10 +- doc/html/man/curs_addstr.3x.html | 10 +- doc/html/man/curs_addwstr.3x.html | 10 +- doc/html/man/curs_attr.3x.html | 10 +- doc/html/man/curs_beep.3x.html | 8 +- doc/html/man/curs_bkgd.3x.html | 8 +- doc/html/man/curs_bkgrnd.3x.html | 8 +- doc/html/man/curs_border.3x.html | 10 +- doc/html/man/curs_border_set.3x.html | 8 +- doc/html/man/curs_clear.3x.html | 8 +- doc/html/man/curs_color.3x.html | 8 +- doc/html/man/curs_delch.3x.html | 8 +- doc/html/man/curs_deleteln.3x.html | 8 +- doc/html/man/curs_extend.3x.html | 20 +- doc/html/man/curs_get_wch.3x.html | 8 +- doc/html/man/curs_get_wstr.3x.html | 10 +- doc/html/man/curs_getcchar.3x.html | 10 +- doc/html/man/curs_getch.3x.html | 10 +- doc/html/man/curs_getstr.3x.html | 10 +- doc/html/man/curs_in_wch.3x.html | 10 +- doc/html/man/curs_in_wchstr.3x.html | 10 +- doc/html/man/curs_inch.3x.html | 19 +- doc/html/man/curs_inchstr.3x.html | 10 +- doc/html/man/curs_initscr.3x.html | 10 +- doc/html/man/curs_ins_wch.3x.html | 10 +- doc/html/man/curs_ins_wstr.3x.html | 10 +- doc/html/man/curs_insch.3x.html | 10 +- doc/html/man/curs_insstr.3x.html | 10 +- doc/html/man/curs_instr.3x.html | 10 +- doc/html/man/curs_inwstr.3x.html | 8 +- doc/html/man/curs_kernel.3x.html | 10 +- doc/html/man/curs_memleaks.3x.html | 10 +- doc/html/man/curs_move.3x.html | 8 +- doc/html/man/curs_opaque.3x.html | 64 +- doc/html/man/curs_outopts.3x.html | 12 +- doc/html/man/curs_overlay.3x.html | 8 +- doc/html/man/curs_printw.3x.html | 12 +- doc/html/man/curs_refresh.3x.html | 10 +- doc/html/man/curs_scanw.3x.html | 12 +- doc/html/man/curs_scr_dump.3x.html | 8 +- doc/html/man/curs_scroll.3x.html | 8 +- doc/html/man/curs_slk.3x.html | 8 +- doc/html/man/curs_sp_funcs.3x.html | 10 +- doc/html/man/curs_termattrs.3x.html | 8 +- doc/html/man/curs_termcap.3x.html | 10 +- doc/html/man/curs_terminfo.3x.html | 8 +- doc/html/man/curs_threads.3x.html | 1043 ++++++++++---------- doc/html/man/curs_trace.3x.html | 10 +- doc/html/man/curs_util.3x.html | 10 +- doc/html/man/curs_variables.3x.html | 237 +++-- doc/html/man/curs_window.3x.html | 12 +- doc/html/man/default_colors.3x.html | 18 +- doc/html/man/define_key.3x.html | 18 +- doc/html/man/form.3x.html | 10 +- doc/html/man/form_cursor.3x.html | 18 +- doc/html/man/form_data.3x.html | 18 +- doc/html/man/form_driver.3x.html | 24 +- doc/html/man/form_field.3x.html | 18 +- doc/html/man/form_field_attributes.3x.html | 22 +- doc/html/man/form_field_buffer.3x.html | 30 +- doc/html/man/form_field_info.3x.html | 26 +- doc/html/man/form_field_just.3x.html | 22 +- doc/html/man/form_field_new.3x.html | 18 +- doc/html/man/form_field_opts.3x.html | 18 +- doc/html/man/form_field_userptr.3x.html | 18 +- doc/html/man/form_field_validation.3x.html | 18 +- doc/html/man/form_fieldtype.3x.html | 18 +- doc/html/man/form_hook.3x.html | 18 +- doc/html/man/form_new.3x.html | 18 +- doc/html/man/form_new_page.3x.html | 22 +- doc/html/man/form_opts.3x.html | 18 +- doc/html/man/form_page.3x.html | 18 +- doc/html/man/form_post.3x.html | 18 +- doc/html/man/form_requestname.3x.html | 18 +- doc/html/man/form_userptr.3x.html | 18 +- doc/html/man/form_variables.3x.html | 16 +- doc/html/man/form_win.3x.html | 18 +- doc/html/man/infocmp.1m.html | 24 +- doc/html/man/infotocap.1m.html | 61 +- doc/html/man/key_defined.3x.html | 18 +- doc/html/man/keybound.3x.html | 18 +- doc/html/man/keyok.3x.html | 18 +- doc/html/man/legacy_coding.3x.html | 18 +- doc/html/man/menu.3x.html | 10 +- doc/html/man/menu_attributes.3x.html | 22 +- doc/html/man/menu_cursor.3x.html | 18 +- doc/html/man/menu_driver.3x.html | 18 +- doc/html/man/menu_format.3x.html | 18 +- doc/html/man/menu_hook.3x.html | 18 +- doc/html/man/menu_items.3x.html | 18 +- doc/html/man/menu_mark.3x.html | 18 +- doc/html/man/menu_new.3x.html | 18 +- doc/html/man/menu_opts.3x.html | 18 +- doc/html/man/menu_pattern.3x.html | 18 +- doc/html/man/menu_post.3x.html | 18 +- doc/html/man/menu_requestname.3x.html | 18 +- doc/html/man/menu_spacing.3x.html | 54 +- doc/html/man/menu_userptr.3x.html | 18 +- doc/html/man/menu_win.3x.html | 18 +- doc/html/man/mitem_current.3x.html | 18 +- doc/html/man/mitem_name.3x.html | 18 +- doc/html/man/mitem_new.3x.html | 18 +- doc/html/man/mitem_opts.3x.html | 18 +- doc/html/man/mitem_userptr.3x.html | 18 +- doc/html/man/mitem_value.3x.html | 18 +- doc/html/man/mitem_visible.3x.html | 18 +- doc/html/man/ncurses.3x.html | 178 ++-- doc/html/man/ncurses6-config.1.html | 61 +- doc/html/man/new_pair.3x.html | 18 +- doc/html/man/panel.3x.html | 20 +- doc/html/man/resizeterm.3x.html | 18 +- doc/html/man/scr_dump.5.html | 18 +- doc/html/man/tabs.1.html | 12 +- doc/html/man/term.5.html | 18 +- doc/html/man/term.7.html | 10 +- doc/html/man/term_variables.3x.html | 20 +- doc/html/man/terminfo.5.html | 10 +- doc/html/man/tic.1m.html | 22 +- doc/html/man/toe.1m.html | 197 ++-- doc/html/man/tput.1.html | 12 +- doc/html/man/tset.1.html | 10 +- doc/html/man/user_caps.5.html | 32 +- doc/html/man/wresize.3x.html | 18 +- man/MKada_config.in | 145 ++- man/MKncu_config.in | 66 +- man/captoinfo.1m | 179 ++-- man/clear.1 | 195 ++-- man/curs_add_wch.3x | 22 +- man/curs_add_wchstr.3x | 10 +- man/curs_addch.3x | 22 +- man/curs_addchstr.3x | 10 +- man/curs_addstr.3x | 8 +- man/curs_addwstr.3x | 10 +- man/curs_attr.3x | 17 +- man/curs_beep.3x | 6 +- man/curs_bkgd.3x | 13 +- man/curs_bkgrnd.3x | 8 +- man/curs_border.3x | 7 +- man/curs_border_set.3x | 12 +- man/curs_clear.3x | 12 +- man/curs_color.3x | 8 +- man/curs_delch.3x | 6 +- man/curs_deleteln.3x | 6 +- man/curs_extend.3x | 26 +- man/curs_get_wch.3x | 16 +- man/curs_get_wstr.3x | 11 +- man/curs_getcchar.3x | 13 +- man/curs_getch.3x | 22 +- man/curs_getstr.3x | 12 +- man/curs_in_wch.3x | 8 +- man/curs_in_wchstr.3x | 15 +- man/curs_inch.3x | 24 +- man/curs_inchstr.3x | 9 +- man/curs_initscr.3x | 18 +- man/curs_ins_wch.3x | 8 +- man/curs_ins_wstr.3x | 12 +- man/curs_insch.3x | 8 +- man/curs_insstr.3x | 12 +- man/curs_instr.3x | 6 +- man/curs_inwstr.3x | 10 +- man/curs_kernel.3x | 18 +- man/curs_memleaks.3x | 6 +- man/curs_move.3x | 7 +- man/curs_opaque.3x | 86 +- man/curs_outopts.3x | 19 +- man/curs_overlay.3x | 8 +- man/curs_printw.3x | 17 +- man/curs_refresh.3x | 10 +- man/curs_scanw.3x | 15 +- man/curs_scr_dump.3x | 16 +- man/curs_scroll.3x | 7 +- man/curs_slk.3x | 6 +- man/curs_sp_funcs.3x | 62 +- man/curs_termattrs.3x | 8 +- man/curs_termcap.3x | 14 +- man/curs_terminfo.3x | 24 +- man/curs_threads.3x | 502 +++++----- man/curs_trace.3x | 6 +- man/curs_util.3x | 20 +- man/curs_variables.3x | 297 ++++-- man/curs_window.3x | 40 +- man/default_colors.3x | 10 +- man/define_key.3x | 8 +- man/form.3x | 11 +- man/form_cursor.3x | 10 +- man/form_data.3x | 9 +- man/form_driver.3x | 21 +- man/form_field.3x | 9 +- man/form_field_attributes.3x | 11 +- man/form_field_buffer.3x | 10 +- man/form_field_info.3x | 10 +- man/form_field_just.3x | 10 +- man/form_field_new.3x | 9 +- man/form_field_opts.3x | 12 +- man/form_field_userptr.3x | 9 +- man/form_field_validation.3x | 14 +- man/form_fieldtype.3x | 12 +- man/form_hook.3x | 9 +- man/form_new.3x | 9 +- man/form_new_page.3x | 10 +- man/form_opts.3x | 9 +- man/form_page.3x | 10 +- man/form_post.3x | 10 +- man/form_requestname.3x | 9 +- man/form_userptr.3x | 9 +- man/form_variables.3x | 24 +- man/form_win.3x | 12 +- man/infocmp.1m | 27 +- man/infotocap.1m | 85 +- man/key_defined.3x | 8 +- man/keybound.3x | 8 +- man/keyok.3x | 8 +- man/legacy_coding.3x | 8 +- man/manhtml.aliases | 7 +- man/menu.3x | 9 +- man/menu_attributes.3x | 10 +- man/menu_cursor.3x | 9 +- man/menu_driver.3x | 12 +- man/menu_format.3x | 9 +- man/menu_hook.3x | 9 +- man/menu_items.3x | 10 +- man/menu_mark.3x | 9 +- man/menu_new.3x | 9 +- man/menu_opts.3x | 9 +- man/menu_pattern.3x | 9 +- man/menu_post.3x | 9 +- man/menu_requestname.3x | 9 +- man/menu_spacing.3x | 33 +- man/menu_userptr.3x | 9 +- man/menu_win.3x | 12 +- man/mitem_current.3x | 9 +- man/mitem_name.3x | 9 +- man/mitem_new.3x | 9 +- man/mitem_opts.3x | 9 +- man/mitem_userptr.3x | 10 +- man/mitem_value.3x | 9 +- man/mitem_visible.3x | 9 +- man/ncurses.3x | 18 +- man/new_pair.3x | 8 +- man/panel.3x | 13 +- man/resizeterm.3x | 8 +- man/scr_dump.5 | 10 +- man/tabs.1 | 15 +- man/term.5 | 10 +- man/term.7 | 8 +- man/term_variables.3x | 18 +- man/terminfo.tail | 25 +- man/tic.1m | 25 +- man/toe.1m | 285 +++--- man/tput.1 | 19 +- man/tset.1 | 25 +- man/user_caps.5 | 26 +- man/wresize.3x | 8 +- ncurses/base/safe_sprintf.c | 15 +- ncurses/tinfo/lib_setup.c | 160 ++- package/debian-mingw/changelog | 4 +- package/debian-mingw64/changelog | 4 +- package/debian/changelog | 4 +- package/mingw-ncurses.nsi | 4 +- package/mingw-ncurses.spec | 2 +- package/ncurses.spec | 2 +- package/ncursest.spec | 2 +- progs/tic.c | 14 +- test/clip_printw.c | 101 +- 273 files changed, 4164 insertions(+), 3619 deletions(-) diff --git a/NEWS b/NEWS index bd488aca..96ccb8f5 100644 --- a/NEWS +++ b/NEWS @@ -26,7 +26,7 @@ -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------- --- $Id: NEWS,v 1.4004 2023/09/23 23:48:03 tom Exp $ +-- $Id: NEWS,v 1.4009 2023/10/01 23:03:08 tom Exp $ ------------------------------------------------------------------------------- This is a log of changes that ncurses has gone through since Zeyd started @@ -46,6 +46,17 @@ See the AUTHORS file for the corresponding full names. Changes through 1.9.9e did not credit all contributions; it is not possible to add this information. +20231001 + + modify setupterm to provide for using ANSI cursor-position report (in + user6/user7 terminfo capabilities) to obtain screensize if neither + environment variables or ioctl is used. The ncurses test-program + with options "-E -T" demonstrates this feature. + + improve error messages in tic (patch by Branden Robinson). + + improve formatting/style of manpages (patches by Branden Robinson). + + modify test/clip_printw.c to optionally test non-wrapped updates. + + fix reallocation loop for vsnprintf() in _nc_sprintf_string() by + copying the va_list variable (patch by Ian Abbott). + 20230923 + improve formatting of manpages (patches by Branden Robinson). + amend change to delscreen() to limit the windows which it creates to diff --git a/VERSION b/VERSION index 4fa26f6d..374ea2b3 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -5:0:10 6.4 20230923 +5:0:10 6.4 20231001 diff --git a/dist.mk b/dist.mk index 0c503d68..bb6fc5c3 100644 --- a/dist.mk +++ b/dist.mk @@ -26,7 +26,7 @@ # use or other dealings in this Software without prior written # # authorization. # ############################################################################## -# $Id: dist.mk,v 1.1567 2023/09/23 09:27:19 tom Exp $ +# $Id: dist.mk,v 1.1569 2023/10/01 08:35:58 tom Exp $ # Makefile for creating ncurses distributions. # # This only needs to be used directly as a makefile by developers, but @@ -38,7 +38,7 @@ SHELL = /bin/sh # These define the major/minor/patch versions of ncurses. NCURSES_MAJOR = 6 NCURSES_MINOR = 4 -NCURSES_PATCH = 20230923 +NCURSES_PATCH = 20231001 # We don't append the patch to the version, since this only applies to releases VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR) diff --git a/doc/html/man/adacurses6-config.1.html b/doc/html/man/adacurses6-config.1.html index 21826623..96a9812f 100644 --- a/doc/html/man/adacurses6-config.1.html +++ b/doc/html/man/adacurses6-config.1.html @@ -27,110 +27,110 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: MKada_config.in,v 1.22 2023/09/17 08:29:17 tom Exp @ + * @Id: MKada_config.in,v 1.28 2023/09/30 23:55:34 tom Exp @ + * Start example. + * End example. --> -ADACURSES 1 2023-09-17 ncurses 6.4 User commands +adacurses6\-config 1 2023-09-30 ncurses 6.4 User commands -

ADACURSES 1 2023-09-17 ncurses 6.4 User commands

+

adacurses6\-config 1 2023-09-30 ncurses 6.4 User commands

-ADACURSES(1)                     User commands                    ADACURSES(1)
+adacurses6-config(1)             User commands            adacurses6-config(1)
 
 
 
 
 

NAME

-       adacurses6-config - helper script for AdaCurses libraries
+       adacurses6-config - configuration helper for AdaCurses libraries
 
 
 

SYNOPSIS

-       adacurses6-config [options]
+       adacurses6-config [--cflags] [--libs]
+
+       adacurses6-config --version
+
+       adacurses6-config --help
 
 
 

DESCRIPTION

-       This  is  a shell script which simplifies configuring an application to
-       use the AdaCurses library binding to ncurses.
+       This  program  development  aid  simplifies  the process of configuring
+       applications to use the AdaCurses library binding to ncurses.
 
 
 

OPTIONS

-       --cflags
-              echos the gnat (Ada  compiler)  flags  needed  to  compile  with
-              AdaCurses.
+       --cflags   reports the GNAT (Ada compiler) flags needed to compile with
+                  AdaCurses.
 
-       --libs echos the gnat libraries needed to link with AdaCurses.
+       --libs     reports the GNAT libraries needed to link with AdaCurses.
 
-       --version
-              echos  the  release+patchdate  version  of the ncurses libraries
-              used to configure and build AdaCurses.
+       --version  reports  the  release  and  patch  date  information  of the
+                  ncurses libraries used to configure and build AdaCurses  and
+                  exits successfully.
 
-       --help prints a list of the adacurses6-config script's options.
+       --help     issues a usage message and exits successfully.
 
-       If no options are given, adacurses6-config prints  the  combination  of
-       --cflags and --libs that gnatmake expects (see example).
+       Omitting options implies "--cflags --libs".
 
 
 

EXAMPLE

-       For  example,  supposing  that  you  want to compile the "Hello World!"
-       program for AdaCurses.  Make a file named "hello.adb":
-              with Terminal_Interface.Curses; use Terminal_Interface.Curses;
-
-              procedure Hello is
-
-                 Visibility : Cursor_Visibility := Invisible;
-                 done : Boolean := False;
-                 c : Key_Code;
+       Consider a program using AdaCurses to write the message "Hello, world!"
+       in the center of the screen and wait for the user to press the "q"  key
+       before exiting.  Populate a file hello.adb with the following.
 
-              begin
+           with Terminal_Interface.Curses; use Terminal_Interface.Curses;
 
-                 Init_Screen;
-                 Set_Echo_Mode (False);
+           procedure Hello is
+              Visibility : Cursor_Visibility := Invisible;
+              Message : constant String := "Hello, World!";
+              done : Boolean := False;
+              c : Key_Code;
+           begin
+              Init_Screen;
+              Set_Echo_Mode (False);
+              Set_Cursor_Visibility (Visibility);
+              Set_Timeout_Mode (Standard_Window, Non_Blocking, 0);
 
-                 Set_Cursor_Visibility (Visibility);
-                 Set_Timeout_Mode (Standard_Window, Non_Blocking, 0);
+              Move_Cursor (Line => Lines / 2,
+                           Column => (Columns - Message'Length) / 2);
+              Add (Str => Message);
 
-                 Move_Cursor (Line => Lines / 2, Column => (Columns - 12) / 2);
-                 Add (Str => "Hello World!");
+              while not done loop
+                 c := Get_Keystroke (Standard_Window);
 
-                 while not done loop
+                 case c is
+                     when Character'Pos ('q') => done := True;
+                     when others => null;
+                 end case;
 
-                    c := Get_Keystroke (Standard_Window);
-                    case c is
-                    when Character'Pos ('q') => done := True;
-                    when others => null;
-                    end case;
+                 Nap_Milli_Seconds (50);
+              end loop;
 
-                    Nap_Milli_Seconds (50);
-                 end loop;
+              End_Windows;
 
-                 End_Windows;
-
-              end Hello;
+           end Hello;
 
        Then, using
-              gnatmake `adacurses-config --cflags`  hello  -largs  `adacurses-
-              config --libs`
-
-       or (simpler):
-              gnatmake hello `adacurses-config`
-
-       you will compile and link the program.
+           gnatmake `adacurses6-config --cflags` hello \
+               -largs `adacurses6-config --libs`
+       or, more simply,
+           gnatmake hello `adacurses6-config`
+       you can compile and link the program.
 
 
 

SEE ALSO

        curses(3x)
 
-       This describes ncurses version 6.4 (patch 20230923).
-
 
 
-ncurses 6.4                       2023-09-17                      ADACURSES(1)
+ncurses 6.4                       2023-09-30              adacurses6-config(1)