From 06078d3fa68db669ed37178c01873546b4b28745 Mon Sep 17 00:00:00 2001 From: "Thomas E. Dickey" Date: Sun, 19 Nov 2017 03:19:09 +0000 Subject: [PATCH] ncurses 6.0 - patch 20171118 + add a note to curs_addch.3x on portability. + add a note to curs_pad.3x on the origin and portability of pads. + improve manpage description of getattrs (report by Midolikawa H). + improve manpage macros (prompted by discussion in Debian #880551. + reviewed test-programs using KEY_RESIZE, made fixes to test/worm.c + add a "-d" option to picsmap for default-colors. + modify old terminology entry and a few other terminal emulators to account for xon -TD + correct sgr string for tmux, which used screen's "standout" code rather than the standard code (patch by Roman Kagan) + correct sgr/sgr0 strings in a few other cases reported by tic, making those correspond to the non-sgr settings where they differ, but otherwise use ECMA-48 consistently: jaixterm, aixterm, att5420_2, att4424, att500, decansi, d410-7b, dm80, hpterm, emu-220, hp2, iTerm2.app, mterm-ansi, ncrvt100an, st-0.7, vi603, vwmterm -TD + build-fix for diagnostics warning in lib_mouse.c for pre-5.0 versions of gcc which did not recognize the diagnostic "push" pragma (patch by Vassili Courzakis). --- MANIFEST | 1 + NEWS | 23 ++- VERSION | 2 +- dist.mk | 4 +- doc/html/man/adacurses6-config.1.html | 2 +- doc/html/man/captoinfo.1m.html | 2 +- doc/html/man/clear.1.html | 14 +- doc/html/man/curs_add_wch.3x.html | 2 +- doc/html/man/curs_add_wchstr.3x.html | 4 +- doc/html/man/curs_addch.3x.html | 53 +++++- doc/html/man/curs_addchstr.3x.html | 4 +- doc/html/man/curs_addstr.3x.html | 4 +- doc/html/man/curs_addwstr.3x.html | 4 +- doc/html/man/curs_attr.3x.html | 2 +- doc/html/man/curs_bkgd.3x.html | 4 +- doc/html/man/curs_bkgrnd.3x.html | 2 +- doc/html/man/curs_color.3x.html | 2 +- doc/html/man/curs_get_wch.3x.html | 4 +- doc/html/man/curs_getcchar.3x.html | 2 +- doc/html/man/curs_getch.3x.html | 4 +- doc/html/man/curs_inch.3x.html | 2 +- doc/html/man/curs_inchstr.3x.html | 2 +- doc/html/man/curs_initscr.3x.html | 2 +- doc/html/man/curs_instr.3x.html | 2 +- doc/html/man/curs_kernel.3x.html | 2 +- doc/html/man/curs_legacy.3x.html | 38 +++- doc/html/man/curs_mouse.3x.html | 26 +-- doc/html/man/curs_pad.3x.html | 93 ++++++++-- doc/html/man/curs_slk.3x.html | 2 +- doc/html/man/curs_termcap.3x.html | 2 +- doc/html/man/curs_terminfo.3x.html | 2 +- doc/html/man/curs_threads.3x.html | 4 +- doc/html/man/curs_touch.3x.html | 20 +-- doc/html/man/curs_trace.3x.html | 2 +- doc/html/man/curs_util.3x.html | 2 +- doc/html/man/curs_variables.3x.html | 4 +- doc/html/man/form.3x.html | 2 +- doc/html/man/form_driver.3x.html | 2 +- doc/html/man/form_field_buffer.3x.html | 4 +- doc/html/man/infocmp.1m.html | 4 +- doc/html/man/infotocap.1m.html | 2 +- doc/html/man/menu.3x.html | 2 +- doc/html/man/menu_driver.3x.html | 2 +- doc/html/man/ncurses.3x.html | 50 +++--- doc/html/man/ncurses6-config.1.html | 2 +- doc/html/man/new_pair.3x.html | 6 +- doc/html/man/panel.3x.html | 2 +- doc/html/man/resizeterm.3x.html | 2 +- doc/html/man/scr_dump.5.html | 240 ++++++++++++------------- doc/html/man/tabs.1.html | 14 +- doc/html/man/terminfo.5.html | 2 +- doc/html/man/tic.1m.html | 4 +- doc/html/man/toe.1m.html | 2 +- doc/html/man/tput.1.html | 4 +- doc/html/man/tset.1.html | 4 +- doc/html/man/user_caps.5.html | 2 +- man/clear.1 | 9 +- man/curs_add_wch.3x | 5 +- man/curs_add_wchstr.3x | 7 +- man/curs_addch.3x | 44 ++++- man/curs_addchstr.3x | 7 +- man/curs_addstr.3x | 7 +- man/curs_addwstr.3x | 7 +- man/curs_attr.3x | 5 +- man/curs_bkgd.3x | 7 +- man/curs_bkgrnd.3x | 5 +- man/curs_color.3x | 5 +- man/curs_get_wch.3x | 7 +- man/curs_getcchar.3x | 5 +- man/curs_getch.3x | 7 +- man/curs_inch.3x | 5 +- man/curs_inchstr.3x | 5 +- man/curs_initscr.3x | 5 +- man/curs_instr.3x | 5 +- man/curs_kernel.3x | 5 +- man/curs_legacy.3x | 83 ++++++--- man/curs_mouse.3x | 9 +- man/curs_pad.3x | 77 +++++++- man/curs_slk.3x | 5 +- man/curs_termcap.3x | 5 +- man/curs_terminfo.3x | 5 +- man/curs_threads.3x | 7 +- man/curs_touch.3x | 6 +- man/curs_trace.3x | 5 +- man/curs_util.3x | 5 +- man/curs_variables.3x | 7 +- man/form_driver.3x | 5 +- man/form_field_buffer.3x | 7 +- man/infocmp.1m | 5 +- man/menu_driver.3x | 5 +- man/ncurses.3x | 9 +- man/new_pair.3x | 9 +- man/resizeterm.3x | 5 +- man/scr_dump.5 | 9 +- man/tabs.1 | 11 +- man/tic.1m | 5 +- man/tput.1 | 5 +- man/tset.1 | 5 +- man/user_caps.5 | 9 +- misc/terminfo.src | 136 ++++++++------ ncurses/base/lib_mouse.c | 6 +- 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 +- test/picsmap.c | 100 +++++------ test/picsmap.h | 74 ++++++++ test/worm.c | 7 +- 110 files changed, 962 insertions(+), 532 deletions(-) create mode 100644 test/picsmap.h diff --git a/MANIFEST b/MANIFEST index a5b6aac7e..7a785cda5 100644 --- a/MANIFEST +++ b/MANIFEST @@ -1173,6 +1173,7 @@ ./test/package/ncurses-examples.spec ./test/padview.c ./test/picsmap.c +./test/picsmap.h ./test/popup_msg.c ./test/popup_msg.h ./test/programs diff --git a/NEWS b/NEWS index 401484d69..683354ab2 100644 --- a/NEWS +++ b/NEWS @@ -25,7 +25,7 @@ -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------- --- $Id: NEWS,v 1.2998 2017/11/11 20:35:53 tom Exp $ +-- $Id: NEWS,v 1.3004 2017/11/19 01:32:47 tom Exp $ ------------------------------------------------------------------------------- This is a log of changes that ncurses has gone through since Zeyd started @@ -45,6 +45,27 @@ 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. +20171118 + + add a note to curs_addch.3x on portability. + + add a note to curs_pad.3x on the origin and portability of pads. + + improve manpage description of getattrs (report by Midolikawa H). + + improve manpage macros (prompted by discussion in Debian #880551. + + reviewed test-programs using KEY_RESIZE, made fixes to test/worm.c + + add a "-d" option to picsmap for default-colors. + + modify old terminology entry and a few other terminal emulators to + account for xon -TD + + correct sgr string for tmux, which used screen's "standout" code + rather than the standard code (patch by Roman Kagan) + + correct sgr/sgr0 strings in a few other cases reported by tic, making + those correspond to the non-sgr settings where they differ, but + otherwise use ECMA-48 consistently: + jaixterm, aixterm, att5420_2, att4424, att500, decansi, d410-7b, + dm80, hpterm, emu-220, hp2, iTerm2.app, mterm-ansi, ncrvt100an, + st-0.7, vi603, vwmterm -TD + + build-fix for diagnostics warning in lib_mouse.c for pre-5.0 versions + of gcc which did not recognize the diagnostic "push" pragma (patch by + Vassili Courzakis). + 20171111 + add "op" to xterm+256setaf -TD + reviewed terminology 1.0.0 -TD diff --git a/VERSION b/VERSION index 1407c7b8f..29ad3b14c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -5:0:9 6.0 20171111 +5:0:9 6.0 20171118 diff --git a/dist.mk b/dist.mk index 1bd77efce..3c07d12c1 100644 --- a/dist.mk +++ b/dist.mk @@ -25,7 +25,7 @@ # use or other dealings in this Software without prior written # # authorization. # ############################################################################## -# $Id: dist.mk,v 1.1191 2017/11/05 11:30:20 tom Exp $ +# $Id: dist.mk,v 1.1192 2017/11/12 15:22:04 tom Exp $ # Makefile for creating ncurses distributions. # # This only needs to be used directly as a makefile by developers, but @@ -37,7 +37,7 @@ SHELL = /bin/sh # These define the major/minor/patch versions of ncurses. NCURSES_MAJOR = 6 NCURSES_MINOR = 0 -NCURSES_PATCH = 20171111 +NCURSES_PATCH = 20171118 # 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 3b1cb2607..0b62be533 100644 --- a/doc/html/man/adacurses6-config.1.html +++ b/doc/html/man/adacurses6-config.1.html @@ -125,7 +125,7 @@

ADACURSES 1 User Commands

SEE ALSO

        curses(3x)
 
-       This describes ncurses version 6.0 (patch 20171028).
+       This describes ncurses version 6.0 (patch 20171118).
 
 
 
diff --git a/doc/html/man/captoinfo.1m.html b/doc/html/man/captoinfo.1m.html
index a435d3952..7a2cdb5f9 100644
--- a/doc/html/man/captoinfo.1m.html
+++ b/doc/html/man/captoinfo.1m.html
@@ -190,7 +190,7 @@ 

captoinfo 1m

SEE ALSO

        infocmp(1m), curses(3x), terminfo(5)
 
-       This describes ncurses version 6.0 (patch 20171028).
+       This describes ncurses version 6.0 (patch 20171118).
 
 
 

AUTHOR

diff --git a/doc/html/man/clear.1.html b/doc/html/man/clear.1.html
index 2f499b75b..0c2acec55 100644
--- a/doc/html/man/clear.1.html
+++ b/doc/html/man/clear.1.html
@@ -26,7 +26,7 @@
   * sale, use or other dealings in this Software without prior written       *
   * authorization.                                                           *
   ****************************************************************************
-  * @Id: clear.1,v 1.18 2017/10/07 21:30:17 tom Exp @
+  * @Id: clear.1,v 1.19 2017/11/18 23:51:59 tom Exp @
   * these would be fallbacks for DS/DE,
   * but groff changed the meaning of the macros.
 -->
@@ -90,13 +90,13 @@ 

clear 1

(tput), and used this to replace the clear command with a shell script which calls tput clear, e.g., - /usr/bin/tput ${1:+-T$1} clear 2> /dev/null - exit + /usr/bin/tput ${1:+-T$1} clear 2> /dev/null + exit In 1989, when Keith Bostic revised the BSD tput command to make it sim- ilar to the AT&T tput, he added a shell script for the clear command: - exec tput clear + exec tput clear The remainder of the script in each case is a copyright notice. @@ -109,11 +109,11 @@

clear 1

sequence for clearing the screen. Rather than clearing just the visible part of the screen using - printf '\033[2J' + printf '\033[2J' one could clear the scrollback using - printf '\033[3J' + printf '\033[3J' This is documented in XTerm Control Sequences as a feature origi- nating with xterm. @@ -148,7 +148,7 @@

clear 1

SEE ALSO

        tput(1), terminfo(5)
 
-       This describes ncurses version 6.0 (patch 20171028).
+       This describes ncurses version 6.0 (patch 20171118).
 
 
 
diff --git a/doc/html/man/curs_add_wch.3x.html b/doc/html/man/curs_add_wch.3x.html
index d4f741d95..03e957d46 100644
--- a/doc/html/man/curs_add_wch.3x.html
+++ b/doc/html/man/curs_add_wch.3x.html
@@ -26,7 +26,7 @@
   * sale, use or other dealings in this Software without prior written       *
   * authorization.                                                           *
   ****************************************************************************
-  * @Id: curs_add_wch.3x,v 1.23 2017/05/20 14:45:24 Sven.Joachim Exp @
+  * @Id: curs_add_wch.3x,v 1.24 2017/11/18 23:47:37 tom Exp @
 -->
 
 
diff --git a/doc/html/man/curs_add_wchstr.3x.html b/doc/html/man/curs_add_wchstr.3x.html
index ed9a3f20b..d40da9efc 100644
--- a/doc/html/man/curs_add_wchstr.3x.html
+++ b/doc/html/man/curs_add_wchstr.3x.html
@@ -1,6 +1,6 @@
 
 
 
diff --git a/doc/html/man/curs_addch.3x.html b/doc/html/man/curs_addch.3x.html
index c0af2f68e..fbacde1ef 100644
--- a/doc/html/man/curs_addch.3x.html
+++ b/doc/html/man/curs_addch.3x.html
@@ -27,7 +27,7 @@
   * sale, use or other dealings in this Software without prior written       *
   * authorization.                                                           *
   ****************************************************************************
-  * @Id: curs_addch.3x,v 1.41 2017/05/05 18:15:29 tom Exp @
+  * @Id: curs_addch.3x,v 1.43 2017/11/19 01:54:00 tom Exp @
 -->
 
 
@@ -182,6 +182,8 @@ 

curs_addch 3x

The defaults specified for forms-drawing characters apply in the POSIX locale. + +

ACS Symbols

        X/Open Curses states that the ACS_ definitions are char constants.  For
        the wide-character implementation (see curs_add_wch), there are  analo-
        gous WACS_ definitions which are cchar_t constants.
@@ -205,11 +207,46 @@ 

curs_addch 3x

acters except by using UTF-8 (see the discussion of NCURSES_NO_UTF8_ACS in ncurses(3x)). - The TABSIZE variable is implemented in some versions of curses, but is + +

Character Set

+       X/Open Curses assumes that the parameter passed to  waddch  contains  a
+       single  character.   As  discussed in curs_attr(3x), that character may
+       have been more than eight bits in an SVr3 or SVr4  implementation,  but
+       in  the  X/Open Curses model, the details are not given.  The important
+       distinction between SVr4 curses and X/Open Curses is that the non-char-
+       acter information (attributes and color) was separated from the charac-
+       ter information which is packed in a chtype to pass to waddch.
+
+       In this implementation, chtype holds eight bits.   But  ncurses  allows
+       multibyte  characters  to be passed in a succession of calls to waddch.
+       The other implementations do not do  this;  a  call  to  waddch  passes
+       exactly one character which may be rendered as one or more cells on the
+       screen depending on whether it is printable.
+
+       Depending on the locale settings, ncurses will inspect the byte  passed
+       in  each  call  to waddch, and check if the latest call will continue a
+       multibyte sequence.  When a character is complete, ncurses displays the
+       character and moves to the next position in the screen.
+
+       If  the  calling  application  interrupts  the succession of bytes in a
+       multibyte character by moving the current location (e.g., using wmove),
+       ncurses discards the partially built character, starting over again.
+
+       For  portability to other implementations, do not rely upon this behav-
+       ior:
+
+       o   check if a character can be represented as a  single  byte  in  the
+           current locale before attempting call waddch, and
+
+       o   call wadd_wch for characters which cannot be handled by waddch.
+
+
+

TABSIZE

+       The  TABSIZE variable is implemented in some versions of curses, but is
        not part of X/Open curses.
 
        If ch is a carriage return, the cursor is moved to the beginning of the
-       current row of the window.  This is true of other implementations,  but
+       current  row of the window.  This is true of other implementations, but
        is not documented.
 
 
@@ -217,7 +254,7 @@ 

curs_addch 3x

curses(3x), curs_attr(3x), curs_clear(3x), curs_inch(3x), curs_out- opts(3x), curs_refresh(3x), curs_variables(3x), putc(3). - Comparable functions in the wide-character (ncursesw) library are + Comparable functions in the wide-character (ncursesw) library are described in curs_add_wch(3x). @@ -237,7 +274,13 @@

curs_addch 3x

  • RETURN VALUE
  • NOTES
  • -
  • PORTABILITY
  • +
  • PORTABILITY + +
  • SEE ALSO
  • diff --git a/doc/html/man/curs_addchstr.3x.html b/doc/html/man/curs_addchstr.3x.html index 3d01f9d8d..d17c64f51 100644 --- a/doc/html/man/curs_addchstr.3x.html +++ b/doc/html/man/curs_addchstr.3x.html @@ -1,6 +1,6 @@ diff --git a/doc/html/man/curs_addstr.3x.html b/doc/html/man/curs_addstr.3x.html index a72e71b0a..0b6b4cafc 100644 --- a/doc/html/man/curs_addstr.3x.html +++ b/doc/html/man/curs_addstr.3x.html @@ -1,6 +1,6 @@ diff --git a/doc/html/man/curs_addwstr.3x.html b/doc/html/man/curs_addwstr.3x.html index 28ddce3b7..d10a23e7c 100644 --- a/doc/html/man/curs_addwstr.3x.html +++ b/doc/html/man/curs_addwstr.3x.html @@ -1,6 +1,6 @@ diff --git a/doc/html/man/curs_attr.3x.html b/doc/html/man/curs_attr.3x.html index 56844fd73..1bf181d17 100644 --- a/doc/html/man/curs_attr.3x.html +++ b/doc/html/man/curs_attr.3x.html @@ -27,7 +27,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_attr.3x,v 1.60 2017/10/14 20:01:13 tom Exp @ + * @Id: curs_attr.3x,v 1.61 2017/11/18 23:47:37 tom Exp @ * --------------------------------------------------------------------------- * attr_get * .br diff --git a/doc/html/man/curs_bkgd.3x.html b/doc/html/man/curs_bkgd.3x.html index 04e8f3212..f48decaf5 100644 --- a/doc/html/man/curs_bkgd.3x.html +++ b/doc/html/man/curs_bkgd.3x.html @@ -1,6 +1,6 @@ diff --git a/doc/html/man/curs_bkgrnd.3x.html b/doc/html/man/curs_bkgrnd.3x.html index 75dc74a4b..b3b03f62e 100644 --- a/doc/html/man/curs_bkgrnd.3x.html +++ b/doc/html/man/curs_bkgrnd.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_bkgrnd.3x,v 1.7 2017/03/25 21:49:00 tom Exp @ + * @Id: curs_bkgrnd.3x,v 1.8 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_color.3x.html b/doc/html/man/curs_color.3x.html index c117f4830..6c9baba0d 100644 --- a/doc/html/man/curs_color.3x.html +++ b/doc/html/man/curs_color.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_color.3x,v 1.51 2017/08/12 21:40:14 tom Exp @ + * @Id: curs_color.3x,v 1.52 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_get_wch.3x.html b/doc/html/man/curs_get_wch.3x.html index d50cce313..2fcb5db57 100644 --- a/doc/html/man/curs_get_wch.3x.html +++ b/doc/html/man/curs_get_wch.3x.html @@ -1,6 +1,6 @@ diff --git a/doc/html/man/curs_getcchar.3x.html b/doc/html/man/curs_getcchar.3x.html index da37720b9..34d4aae0e 100644 --- a/doc/html/man/curs_getcchar.3x.html +++ b/doc/html/man/curs_getcchar.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_getcchar.3x,v 1.18 2017/03/31 10:50:54 tom Exp @ + * @Id: curs_getcchar.3x,v 1.19 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_getch.3x.html b/doc/html/man/curs_getch.3x.html index 9fa11b687..c84a03dec 100644 --- a/doc/html/man/curs_getch.3x.html +++ b/doc/html/man/curs_getch.3x.html @@ -1,7 +1,7 @@ diff --git a/doc/html/man/curs_inch.3x.html b/doc/html/man/curs_inch.3x.html index c1c25140c..c55eae8e9 100644 --- a/doc/html/man/curs_inch.3x.html +++ b/doc/html/man/curs_inch.3x.html @@ -27,7 +27,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_inch.3x,v 1.19 2017/10/28 20:16:52 Sven.Joachim Exp @ + * @Id: curs_inch.3x,v 1.20 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_inchstr.3x.html b/doc/html/man/curs_inchstr.3x.html index bcc7edac8..da37afa0b 100644 --- a/doc/html/man/curs_inchstr.3x.html +++ b/doc/html/man/curs_inchstr.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_inchstr.3x,v 1.16 2017/04/29 21:31:17 tom Exp @ + * @Id: curs_inchstr.3x,v 1.17 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_initscr.3x.html b/doc/html/man/curs_initscr.3x.html index 77a1b64e5..9d8496d64 100644 --- a/doc/html/man/curs_initscr.3x.html +++ b/doc/html/man/curs_initscr.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_initscr.3x,v 1.28 2017/05/30 21:12:51 tom Exp @ + * @Id: curs_initscr.3x,v 1.29 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_instr.3x.html b/doc/html/man/curs_instr.3x.html index e63a980b2..894bb4764 100644 --- a/doc/html/man/curs_instr.3x.html +++ b/doc/html/man/curs_instr.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_instr.3x,v 1.17 2017/04/29 21:37:55 tom Exp @ + * @Id: curs_instr.3x,v 1.18 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_kernel.3x.html b/doc/html/man/curs_kernel.3x.html index a7303ec54..af428386c 100644 --- a/doc/html/man/curs_kernel.3x.html +++ b/doc/html/man/curs_kernel.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_kernel.3x,v 1.22 2017/01/07 19:25:15 tom Exp @ + * @Id: curs_kernel.3x,v 1.23 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/curs_legacy.3x.html b/doc/html/man/curs_legacy.3x.html index 66a9f4b24..b0b8c7515 100644 --- a/doc/html/man/curs_legacy.3x.html +++ b/doc/html/man/curs_legacy.3x.html @@ -1,6 +1,6 @@ @@ -64,18 +64,34 @@

    curs_legacy 3x

    DESCRIPTION

    -       The getbegy and getbegx functions return the same data as getbegyx.
    +       These  legacy functions are simpler to use than the X/Open Curses func-
    +       tions:
     
    -       The getcury and getcurx functions return the same data as getyx.
    +       o   The getattrs function returns the same attribute data as wattr_get.
     
    -       The getmaxy and getmaxx functions return the same data as getmaxyx.
    +           However, getattrs returns an integer  (actually  a  chtype),  while
    +           wattr_get  returns  the current color pair in a separate parameter.
    +           In the wide-character library configuration, color  pairs  may  not
    +           fit into a chtype, so wattr_get is the only way to obtain the color
    +           information.
     
    -       The getpary and getparx functions return the same data as getparyx.
    +           Because getattrs returns the attributes in a single  parameter,  it
    +           would  not  be possible for an application to distinguish that from
    +           ERR (a -1).  If the window  parameter  is  null,  getattrs  returns
    +           A_NORMAL (zero).
    +
    +       o   The getbegy and getbegx functions return the same data as getbegyx.
    +
    +       o   The getcury and getcurx functions return the same data as getyx.
    +
    +       o   The getmaxy and getmaxx functions return the same data as getmaxyx.
    +
    +       o   The getpary and getparx functions return the same data as getparyx.
     
     
     

    RETURN VALUE

    -       These  functions  return  an integer, or ERR if the window parameter is
    -       null.
    +       Except  as noted, these functions return an integer, or ERR if the win-
    +       dow parameter is null.
     
     
     

    NOTES

    @@ -89,7 +105,11 @@ 

    curs_legacy 3x

    PORTABILITY

            These  functions were supported on Version 7, BSD or System V implemen-
    -       tations.
    +       tations.  None of those implementations checked the window parameter.
    +
    +       The getattrs function and macro are defined to return a (signed)  inte-
    +       ger  for  compatibility with those implementations although an unsigned
    +       type would have been more appropriate.
     
     
     

    SEE ALSO

    diff --git a/doc/html/man/curs_mouse.3x.html b/doc/html/man/curs_mouse.3x.html
    index 9fe803056..296d50fd6 100644
    --- a/doc/html/man/curs_mouse.3x.html
    +++ b/doc/html/man/curs_mouse.3x.html
    @@ -27,7 +27,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_mouse.3x,v 1.46 2017/05/20 14:42:41 Sven.Joachim Exp @
    +  * @Id: curs_mouse.3x,v 1.47 2017/11/18 23:52:45 tom Exp @
     -->
     
     
    @@ -250,21 +250,21 @@ 

    curs_mouse 3x

    o the "libcurses" manual page lists functions for this feature which are prototyped in curses.h: - extern int mouse_set(long int); - extern int mouse_on(long int); - extern int mouse_off(long int); - extern int request_mouse_pos(void); - extern int map_button(unsigned long); - extern void wmouse_position(WINDOW *, int *, int *); - extern unsigned long getmouse(void), getbmap(void); + extern int mouse_set(long int); + extern int mouse_on(long int); + extern int mouse_off(long int); + extern int request_mouse_pos(void); + extern int map_button(unsigned long); + extern void wmouse_position(WINDOW *, int *, int *); + extern unsigned long getmouse(void), getbmap(void); o the "terminfo" manual page lists capabilities for the feature - buttons btns BT Number of buttons on the mouse - get_mouse getm Gm Curses should get button events - key_mouse kmous Km 0631, Mouse event has occurred - mouse_info minfo Mi Mouse status information - req_mouse_pos reqmp RQ Request mouse position report + buttons btns BT Number of buttons on the mouse + get_mouse getm Gm Curses should get button events + key_mouse kmous Km 0631, Mouse event has occurred + mouse_info minfo Mi Mouse status information + req_mouse_pos reqmp RQ Request mouse position report o the interface made assumptions (as does ncurses) about the escape sequences sent to and received from the terminal. diff --git a/doc/html/man/curs_pad.3x.html b/doc/html/man/curs_pad.3x.html index fa9c5a45d..1a6e159b3 100644 --- a/doc/html/man/curs_pad.3x.html +++ b/doc/html/man/curs_pad.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: curs_pad.3x,v 1.19 2017/01/07 19:25:15 tom Exp @ + * @Id: curs_pad.3x,v 1.23 2017/11/19 01:29:46 tom Exp @ --> @@ -74,8 +74,10 @@

    curs_pad 3x

    screen. Pads can be used when a large window is needed, and only a part of the window will be on the screen at one time. Automatic re- freshes of pads (e.g., from scrolling or echoing of input) do not oc- - cur. It is not legal to call wrefresh with a pad as an argument; the - routines prefresh or pnoutrefresh should be called instead. Note that + cur. + + It is not legal to call wrefresh with a pad as an argument; the rou- + tines prefresh or pnoutrefresh should be called instead. Note that these routines require additional parameters to specify the part of the pad to be displayed and the location on the screen to be used for the display. @@ -95,15 +97,19 @@

    curs_pad 3x

    The prefresh and pnoutrefresh routines are analogous to wrefresh and wnoutrefresh except that they relate to pads instead of windows. The additional parameters are needed to indicate what part of the pad and - screen are involved. The pminrow and pmincol parameters specify the - upper left-hand corner of the rectangle to be displayed in the pad. - The sminrow, smincol, smaxrow, and smaxcol parameters specify the edges - of the rectangle to be displayed on the screen. The lower right-hand - corner of the rectangle to be displayed in the pad is calculated from - the screen coordinates, since the rectangles must be the same size. - Both rectangles must be entirely contained within their respective - structures. Negative values of pminrow, pmincol, sminrow, or smincol - are treated as if they were zero. + screen are involved. + + o The pminrow and pmincol parameters specify the upper left-hand cor- + ner of the rectangle to be displayed in the pad. + + o The sminrow, smincol, smaxrow, and smaxcol parameters specify the + edges of the rectangle to be displayed on the screen. + + The lower right-hand corner of the rectangle to be displayed in the pad + is calculated from the screen coordinates, since the rectangles must be + the same size. Both rectangles must be entirely contained within their + respective structures. Negative values of pminrow, pmincol, sminrow, + or smincol are treated as if they were zero.

    pechochar

    @@ -154,7 +160,68 @@ 

    curs_pad 3x

    PORTABILITY

    -       The XSI Curses standard, Issue 4 describes these functions.
    +       BSD curses has no pad feature.
    +
    +       SVr2 curses (1986) provided the newpad and related functions, document-
    +       ing  them  in  a single line each.  SVr3 (1987) provided more extensive
    +       documentation.
    +
    +       The documentation does not explain the term pad.  However,  the  Apollo
    +       Aegis workstation operating system supported a graphical pad feature:
    +
    +       o   These  graphical pads could be much larger than the computer's dis-
    +           play.
    +
    +       o   The read-only output from a command could be scrolled back  to  in-
    +           spect, and select text from the pad.
    +
    +       The two uses may be related.
    +
    +       The  XSI  Curses  standard,  Issue 4 describes these functions, without
    +       significant change from the SVr3 documentation.  It describes no  error
    +       conditions.   The  behavior of subpad if the parent window is not a pad
    +       is undocumented, and is not checked by the vendor Unix implementations:
    +
    +       o   SVr4 curses sets a flag in the WINDOW  structure  in  newpad  which
    +           tells if the window is a pad.
    +
    +           However, it uses this information only in wscrl, and does not check
    +           in wrefresh to ensure that the pad is refreshed properly.
    +
    +       o   Solaris X/Open Curses checks if a window is a pad in  wnoutrefresh,
    +           returning ERR in that case.
    +
    +           However,  it only sets the flag for subwindows if the parent window
    +           is a pad.  Its newpad function does not set this information.  Con-
    +           sequently, the check will never fail.
    +
    +           It  makes no comparable check in pnoutrefresh, though interestingly
    +           enough, a comment in the source code states  that  the  lack  of  a
    +           check was an MKS extension.
    +
    +       o   NetBSD  7 curses sets a flag in the WINDOW structure for newpad and
    +           subpad, using this to help with the  distinction  between  wnoutre-
    +           fresh and pnoutrefresh.
    +
    +           It  does  not  check for the case where a subwindow is created in a
    +           pad using subwin or derwin.
    +
    +           The dupwin function returns a regular  window  when  duplicating  a
    +           pad.   Likewise,  getwin always returns a window, even if the saved
    +           data was from a pad.
    +
    +       This implementation
    +
    +       o   sets a flag in the WINDOW structure for newpad and subpad,
    +
    +       o   allows a subwin or derwin call to succeed having a  pad  parent  by
    +           forcing the subwindow to be a pad,
    +
    +       o   checks  in  both  wnoutrefresh and pnoutrefresh to ensure that pads
    +           and windows are handled distinctly, and
    +
    +       o   ensures that dupwin and getwin treat pads  versus  windows  consis-
    +           tently.
     
     
     

    SEE ALSO

    diff --git a/doc/html/man/curs_slk.3x.html b/doc/html/man/curs_slk.3x.html
    index 4b617ab4e..ecb768d2e 100644
    --- a/doc/html/man/curs_slk.3x.html
    +++ b/doc/html/man/curs_slk.3x.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_slk.3x,v 1.31 2017/03/31 11:09:28 tom Exp @
    +  * @Id: curs_slk.3x,v 1.32 2017/11/18 23:47:37 tom Exp @
     -->
     
     
    diff --git a/doc/html/man/curs_termcap.3x.html b/doc/html/man/curs_termcap.3x.html
    index e079c4b19..e1abd8c06 100644
    --- a/doc/html/man/curs_termcap.3x.html
    +++ b/doc/html/man/curs_termcap.3x.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_termcap.3x,v 1.33 2017/01/07 19:25:15 tom Exp @
    +  * @Id: curs_termcap.3x,v 1.34 2017/11/18 23:47:37 tom Exp @
     -->
     
     
    diff --git a/doc/html/man/curs_terminfo.3x.html b/doc/html/man/curs_terminfo.3x.html
    index a10c39e7c..087822378 100644
    --- a/doc/html/man/curs_terminfo.3x.html
    +++ b/doc/html/man/curs_terminfo.3x.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_terminfo.3x,v 1.55 2017/03/31 15:16:15 tom Exp @
    +  * @Id: curs_terminfo.3x,v 1.56 2017/11/18 23:47:37 tom Exp @
       * ***************************************************************************
       * ***************************************************************************
       * ***************************************************************************
    diff --git a/doc/html/man/curs_threads.3x.html b/doc/html/man/curs_threads.3x.html
    index 11b85c812..7c1bf2a9a 100644
    --- a/doc/html/man/curs_threads.3x.html
    +++ b/doc/html/man/curs_threads.3x.html
    @@ -1,6 +1,6 @@
     
    diff --git a/doc/html/man/curs_touch.3x.html b/doc/html/man/curs_touch.3x.html
    index d63e4de8d..5b4d8212d 100644
    --- a/doc/html/man/curs_touch.3x.html
    +++ b/doc/html/man/curs_touch.3x.html
    @@ -1,6 +1,6 @@
     
     
     
    @@ -89,15 +89,15 @@ 

    curs_touch 3x

    X/Open does not define any error conditions. In this implementation - is_linetouched - returns an error if the window pointer is null, or if the - line number is outside the window. Note that ERR is dis- - tinct from TRUE and FALSE, which are the normal return val- - ues of this function. + is_linetouched + returns an error if the window pointer is null, or if the line + number is outside the window. Note that ERR is distinct from + TRUE and FALSE, which are the normal return values of this + function. - wtouchln - returns an error if the window pointer is null, or if the - line number is outside the window. + wtouchln + returns an error if the window pointer is null, or if the line + number is outside the window.

    PORTABILITY

    diff --git a/doc/html/man/curs_trace.3x.html b/doc/html/man/curs_trace.3x.html
    index af3a377cf..7cb64bd4c 100644
    --- a/doc/html/man/curs_trace.3x.html
    +++ b/doc/html/man/curs_trace.3x.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_trace.3x,v 1.18 2017/01/14 19:46:40 tom Exp @
    +  * @Id: curs_trace.3x,v 1.19 2017/11/18 23:47:37 tom Exp @
     -->
     
     
    diff --git a/doc/html/man/curs_util.3x.html b/doc/html/man/curs_util.3x.html
    index f7ee7b399..a9fcb5f92 100644
    --- a/doc/html/man/curs_util.3x.html
    +++ b/doc/html/man/curs_util.3x.html
    @@ -27,7 +27,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: curs_util.3x,v 1.51 2017/10/07 21:47:25 tom Exp @
    +  * @Id: curs_util.3x,v 1.52 2017/11/18 23:47:37 tom Exp @
     -->
     
     
    diff --git a/doc/html/man/curs_variables.3x.html b/doc/html/man/curs_variables.3x.html
    index d8a810dca..4045e26e4 100644
    --- a/doc/html/man/curs_variables.3x.html
    +++ b/doc/html/man/curs_variables.3x.html
    @@ -1,6 +1,6 @@
     
     
     
    diff --git a/doc/html/man/form.3x.html b/doc/html/man/form.3x.html
    index 68632a19c..b8d40012e 100644
    --- a/doc/html/man/form.3x.html
    +++ b/doc/html/man/form.3x.html
    @@ -234,7 +234,7 @@ 

    form 3x

    curses(3x) and related pages whose names begin "form_" for detailed descriptions of the entry points. - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118). diff --git a/doc/html/man/form_driver.3x.html b/doc/html/man/form_driver.3x.html index 3840fae15..6c6a89415 100644 --- a/doc/html/man/form_driver.3x.html +++ b/doc/html/man/form_driver.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: form_driver.3x,v 1.27 2017/06/23 22:56:39 tom Exp @ + * @Id: form_driver.3x,v 1.28 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/form_field_buffer.3x.html b/doc/html/man/form_field_buffer.3x.html index 55eb6998c..2a82fc51f 100644 --- a/doc/html/man/form_field_buffer.3x.html +++ b/doc/html/man/form_field_buffer.3x.html @@ -1,7 +1,7 @@ diff --git a/doc/html/man/infocmp.1m.html b/doc/html/man/infocmp.1m.html index cee761d94..a6964dc6a 100644 --- a/doc/html/man/infocmp.1m.html +++ b/doc/html/man/infocmp.1m.html @@ -27,7 +27,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: infocmp.1m,v 1.66 2017/08/13 00:21:55 tom Exp @ + * @Id: infocmp.1m,v 1.67 2017/11/18 23:51:17 tom Exp @ --> @@ -476,7 +476,7 @@

    infocmp 1m

    http://invisible-island.net/ncurses/tctest.html - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118).

    AUTHOR

    diff --git a/doc/html/man/infotocap.1m.html b/doc/html/man/infotocap.1m.html
    index a8e213f56..270626cfe 100644
    --- a/doc/html/man/infotocap.1m.html
    +++ b/doc/html/man/infotocap.1m.html
    @@ -85,7 +85,7 @@ 

    infotocap 1m

    SEE ALSO

            curses(3x), tic(1m), infocmp(1m), terminfo(5)
     
    -       This describes ncurses version 6.0 (patch 20171028).
    +       This describes ncurses version 6.0 (patch 20171118).
     
     
     

    AUTHOR

    diff --git a/doc/html/man/menu.3x.html b/doc/html/man/menu.3x.html
    index 3013aac05..a911b01d0 100644
    --- a/doc/html/man/menu.3x.html
    +++ b/doc/html/man/menu.3x.html
    @@ -210,7 +210,7 @@ 

    menu 3x

    curses(3x) and related pages whose names begin "menu_" for detailed descriptions of the entry points. - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118). diff --git a/doc/html/man/menu_driver.3x.html b/doc/html/man/menu_driver.3x.html index 95ef082bc..3f24f7f9b 100644 --- a/doc/html/man/menu_driver.3x.html +++ b/doc/html/man/menu_driver.3x.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: menu_driver.3x,v 1.21 2017/01/07 19:25:15 tom Exp @ + * @Id: menu_driver.3x,v 1.22 2017/11/18 23:47:37 tom Exp @ --> diff --git a/doc/html/man/ncurses.3x.html b/doc/html/man/ncurses.3x.html index 86378eb9e..a0526f2c6 100644 --- a/doc/html/man/ncurses.3x.html +++ b/doc/html/man/ncurses.3x.html @@ -27,7 +27,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: ncurses.3x,v 1.135 2017/08/12 22:27:43 tom Exp @ + * @Id: ncurses.3x,v 1.136 2017/11/18 23:48:44 tom Exp @ --> @@ -59,7 +59,7 @@

    ncurses 3x

    method of updating character screens with reasonable optimization. This implementation is "new curses" (ncurses) and is the approved replacement for 4.4BSD classic curses, which has been discontinued. - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118). The ncurses library emulates the curses library of System V Release 4 UNIX, and XPG4 (X/Open Portability Guide) curses (also known as XSI @@ -92,7 +92,7 @@

    ncurses 3x

    The library uses the locale which the calling program has initialized. That is normally done with setlocale: - setlocale(LC_ALL, ""); + setlocale(LC_ALL, ""); If the locale is not initialized, the library assumes that characters are printable as in ISO-8859-1, to work with certain legacy programs. @@ -108,13 +108,13 @@

    ncurses 3x

    screen oriented programs want this), the following sequence should be used: - initscr(); cbreak(); noecho(); + initscr(); cbreak(); noecho(); Most programs would additionally use the sequence: - nonl(); - intrflush(stdscr, FALSE); - keypad(stdscr, TRUE); + nonl(); + intrflush(stdscr, FALSE); + keypad(stdscr, TRUE); Before a curses program is run, the tab stops of the terminal should be set and its initialization strings, if defined, must be output. This @@ -176,17 +176,17 @@

    ncurses 3x

    standard place. For example, if TERM is set to att4424, then the com- piled terminal definition is found in - /usr/share/terminfo/a/att4424. + /usr/share/terminfo/a/att4424. (The a is copied from the first letter of att4424 to avoid creation of huge directories.) However, if TERMINFO is set to $HOME/myterms, curses first checks - $HOME/myterms/a/att4424, + $HOME/myterms/a/att4424, and if that fails, it then checks - /usr/share/terminfo/a/att4424. + /usr/share/terminfo/a/att4424. This is useful for developing experimental definitions or when write permission in /usr/share/terminfo is not available. @@ -835,8 +835,8 @@

    ncurses 3x

    Tells ncurses where your home directory is. That is where it may read and write auxiliary terminal descriptions: - $HOME/.termcap - $HOME/.terminfo + $HOME/.termcap + $HOME/.terminfo

    LINES

    @@ -849,9 +849,9 @@ 

    ncurses 3x

    tons on the mouse. OS/2 numbers a 3-button mouse inconsistently from other platforms: - 1 = left - 2 = right - 3 = middle. + 1 = left + 2 = right + 3 = middle. This variable lets you customize the mouse. The variable must be three numeric digits 1-3 in any order, e.g., 123 or 321. If it is not speci- @@ -1047,11 +1047,11 @@

    ncurses 3x

    o If ncurses is built to use hashed databases, then each entry in this list may be the path of a hashed database file, e.g., - /usr/share/terminfo.db + /usr/share/terminfo.db rather than - /usr/share/terminfo/ + /usr/share/terminfo/ The hashed database uses less disk-space and is a little faster than the directory tree. However, some applications assume the @@ -1066,8 +1066,8 @@

    ncurses 3x

    the remainder of that variable as a compiled terminal description. You might produce the base64 format using infocmp(1m): - TERMINFO="$(infocmp -0 -Q2 -q)" - export TERMINFO + TERMINFO="$(infocmp -0 -Q2 -q)" + export TERMINFO The compiled description is used if it corresponds to the terminal identified by the TERM variable. @@ -1112,7 +1112,7 @@

    ncurses 3x

    If the TERMPATH environment variable is not set, ncurses looks in the files - /etc/termcap, /usr/share/misc/termcap and $HOME/.termcap, + /etc/termcap, /usr/share/misc/termcap and $HOME/.termcap, in that order. @@ -1120,7 +1120,7 @@

    ncurses 3x

    the current user is the superuser (root), or if the application uses setuid or setgid permissions: - $TERMINFO, $TERMINFO_DIRS, $TERMPATH, as well as $HOME. + $TERMINFO, $TERMINFO_DIRS, $TERMPATH, as well as $HOME.

    ALTERNATE CONFIGURATIONS

    @@ -1132,14 +1132,14 @@ 

    ncurses 3x

    --disable-overwrite The standard include for ncurses is as noted in SYNOPSIS: - #include <curses.h> + #include <curses.h> This option is used to avoid filename conflicts when ncurses is not the main implementation of curses of the computer. If ncurses is installed disabling overwrite, it puts its headers in a subdi- rectory, e.g., - #include <ncurses/curses.h> + #include <ncurses/curses.h> It also omits a symbolic link which would allow you to use -lcurses to build executables. @@ -1150,11 +1150,11 @@

    ncurses 3x

    ent subdirectory. All of the library names have a "w" appended to them, i.e., instead of - -lncurses + -lncurses you link with - -lncursesw + -lncursesw You must also define _XOPEN_SOURCE_EXTENDED when compiling for the wide-character library to use the extended (wide-character) func- diff --git a/doc/html/man/ncurses6-config.1.html b/doc/html/man/ncurses6-config.1.html index e44bcdb5f..f6ed90f2f 100644 --- a/doc/html/man/ncurses6-config.1.html +++ b/doc/html/man/ncurses6-config.1.html @@ -112,7 +112,7 @@

    ncurses6-config 1

    SEE ALSO

            curses(3x)
     
    -       This describes ncurses version 6.0 (patch 20171028).
    +       This describes ncurses version 6.0 (patch 20171118).
     
     
     
    diff --git a/doc/html/man/new_pair.3x.html b/doc/html/man/new_pair.3x.html
    index ffe64cac4..bc11784ac 100644
    --- a/doc/html/man/new_pair.3x.html
    +++ b/doc/html/man/new_pair.3x.html
    @@ -27,7 +27,7 @@
       * authorization.                                                           *
       ****************************************************************************
       * Author: Thomas E. Dickey
    -  * @Id: new_pair.3x,v 1.9 2017/03/13 21:21:34 tom Exp @
    +  * @Id: new_pair.3x,v 1.10 2017/11/18 23:48:44 tom Exp @
     -->
     
     
    @@ -81,12 +81,12 @@ 

    new_pair 3x

    tions, it is convenient to use the maximum number of combinations as the limit on color pairs: - COLORS * COLORS + COLORS * COLORS o Terminals which support default colors distinct from "ANSI colors" add to the possible combinations, producing this total: - ( COLORS + 1 ) * ( COLORS + 1 ) + ( COLORS + 1 ) * ( COLORS + 1 ) o An application might use up to a few dozen color pairs to implement a predefined color scheme. diff --git a/doc/html/man/panel.3x.html b/doc/html/man/panel.3x.html index 014d58e04..7cc983403 100644 --- a/doc/html/man/panel.3x.html +++ b/doc/html/man/panel.3x.html @@ -194,7 +194,7 @@

    panel 3x

    SEE ALSO

            curses(3x), curs_variables(3x),
     
    -       This describes ncurses version 6.0 (patch 20171028).
    +       This describes ncurses version 6.0 (patch 20171118).
     
     
     

    AUTHOR

    diff --git a/doc/html/man/resizeterm.3x.html b/doc/html/man/resizeterm.3x.html
    index aa4e2fab7..33b6f339a 100644
    --- a/doc/html/man/resizeterm.3x.html
    +++ b/doc/html/man/resizeterm.3x.html
    @@ -27,7 +27,7 @@
       * authorization.                                                           *
       ****************************************************************************
       * Author: Thomas E. Dickey 1996-on
    -  * @Id: resizeterm.3x,v 1.23 2017/05/30 21:08:21 tom Exp @
    +  * @Id: resizeterm.3x,v 1.24 2017/11/18 23:47:37 tom Exp @
     -->
     
     
    diff --git a/doc/html/man/scr_dump.5.html b/doc/html/man/scr_dump.5.html
    index ed7a18f84..811ac6524 100644
    --- a/doc/html/man/scr_dump.5.html
    +++ b/doc/html/man/scr_dump.5.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: scr_dump.5,v 1.10 2017/04/29 20:53:55 tom Exp @
    +  * @Id: scr_dump.5,v 1.11 2017/11/18 23:51:59 tom Exp @
     -->
     
     
    @@ -75,22 +75,22 @@ 

    scr_dump 5

    ber was unused by other applications. This 16-bit number was unused: - 0x8888 (octal "\210\210") + 0x8888 (octal "\210\210") but to be more certain, this 32-bit number was chosen: - 0x88888888 (octal "\210\210\210\210") + 0x88888888 (octal "\210\210\210\210") This is the pattern submitted to the maintainers of the file pro- gram: - # - # ncurses5 (and before) did not use a magic number, - # making screen dumps "data". - # - # ncurses6 (2015) uses this format, ignoring byte-order - 0 string \210\210\210\210ncurses ncurses6 screen image - # + # + # ncurses5 (and before) did not use a magic number, + # making screen dumps "data". + # + # ncurses6 (2015) uses this format, ignoring byte-order + 0 string \210\210\210\210ncurses ncurses6 screen image + # o The screen dumps are written in textual form, so that internal data sizes are not directly related to the dump-format, and enabling the @@ -171,26 +171,26 @@

    scr_dump 5

    The Solaris curses source has these definitions: - /* terminfo magic number */ - #define MAGNUM 0432 + /* terminfo magic number */ + #define MAGNUM 0432 - /* curses screen dump magic number */ - #define SVR2_DUMP_MAGIC_NUMBER 0433 - #define SVR3_DUMP_MAGIC_NUMBER 0434 + /* curses screen dump magic number */ + #define SVR2_DUMP_MAGIC_NUMBER 0433 + #define SVR3_DUMP_MAGIC_NUMBER 0434 That is, the feature was likely introduced in SVr2 (1984), and improved in SVr3 (1987). The Solaris curses source has no magic number for SVr4 (1989). Other operating systems (AIX and HPUX) use a magic number which would correspond to this definition: - /* curses screen dump magic number */ - #define SVR4_DUMP_MAGIC_NUMBER 0435 + /* curses screen dump magic number */ + #define SVR4_DUMP_MAGIC_NUMBER 0435 That octal number in bytes is 001, 035. Because most Unix vendors use big-endian hardware, the magic number is written with the high-order byte first, e.g., - 01 35 + 01 35 After the magic number, the WINDOW structure and line-data are written in binary format. While the magic number used by the Unix systems can @@ -235,7 +235,7 @@

    scr_dump 5

    but begins the file with its three-byte identifier "PDC", followed by a one-byte version, e.g., - "PDC\001" + "PDC\001"

    NetBSD

    @@ -260,55 +260,55 @@ 

    scr_dump 5

    Given a simple program which writes text to the screen (and for the sake of example, limiting the screen-size to 10x20): - #include <curses.h> - - int - main(void) - { - putenv("LINES=10"); - putenv("COLUMNS=20"); - initscr(); - start_color(); - init_pair(1, COLOR_WHITE, COLOR_BLUE); - init_pair(2, COLOR_RED, COLOR_BLACK); - bkgd(COLOR_PAIR(1)); - move(4, 5); - attron(A_BOLD); - addstr("Hello"); - move(5, 5); - attroff(A_BOLD); - attrset(A_REVERSE | COLOR_PAIR(2)); - addstr("World!"); - refresh(); - scr_dump("foo.out"); - endwin(); - return 0; - } + #include <curses.h> + + int + main(void) + { + putenv("LINES=10"); + putenv("COLUMNS=20"); + initscr(); + start_color(); + init_pair(1, COLOR_WHITE, COLOR_BLUE); + init_pair(2, COLOR_RED, COLOR_BLACK); + bkgd(COLOR_PAIR(1)); + move(4, 5); + attron(A_BOLD); + addstr("Hello"); + move(5, 5); + attroff(A_BOLD); + attrset(A_REVERSE | COLOR_PAIR(2)); + addstr("World!"); + refresh(); + scr_dump("foo.out"); + endwin(); + return 0; + } When run using ncurses6, the output looks like this: - \210\210\210\210ncurses 6.0.20170415 - _cury=5 - _curx=11 - _maxy=9 - _maxx=19 - _flags=14 - _attrs=\{REVERSE|C2} - flag=_idcok - _delay=-1 - _regbottom=9 - _bkgrnd=\{NORMAL|C1}\s - rows: - 1:\{NORMAL|C1}\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 2:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 3:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 4:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 5:\s\s\s\s\s\{BOLD}Hello\{NORMAL}\s\s\s\s\s\s\s\s\s\s - 6:\s\s\s\s\s\{REVERSE|C2}World!\{NORMAL|C1}\s\s\s\s\s\s\s\s\s - 7:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 8:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 9:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s - 10:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + \210\210\210\210ncurses 6.0.20170415 + _cury=5 + _curx=11 + _maxy=9 + _maxx=19 + _flags=14 + _attrs=\{REVERSE|C2} + flag=_idcok + _delay=-1 + _regbottom=9 + _bkgrnd=\{NORMAL|C1}\s + rows: + 1:\{NORMAL|C1}\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 2:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 3:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 4:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 5:\s\s\s\s\s\{BOLD}Hello\{NORMAL}\s\s\s\s\s\s\s\s\s\s + 6:\s\s\s\s\s\{REVERSE|C2}World!\{NORMAL|C1}\s\s\s\s\s\s\s\s\s + 7:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 8:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 9:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s + 10:\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s The first four octal escapes are actually nonprinting characters, while the remainder of the file is printable text. You may notice: @@ -326,39 +326,39 @@

    scr_dump 5

    Running the same program with Solaris xpg4 curses gives this dump: - MAX=10,20 - BEG=0,0 - SCROLL=0,10 - VMIN=1 - VTIME=0 - FLAGS=0x1000 - FG=0,0 - BG=0,0, - 0,0,0,1, - 0,19,0,0, - 1,0,0,1, - 1,19,0,0, - 2,0,0,1, - 2,19,0,0, - 3,0,0,1, - 3,19,0,0, - 4,0,0,1, - 4,5,0x20,0,Hello - 4,10,0,1, - 4,19,0,0, - 5,0,0,1, - 5,5,0x4,2,World! - 5,11,0,1, - 5,19,0,0, - 6,0,0,1, - 6,19,0,0, - 7,0,0,1, - 7,19,0,0, - 8,0,0,1, - 8,19,0,0, - 9,0,0,1, - 9,19,0,0, - CUR=11,5 + MAX=10,20 + BEG=0,0 + SCROLL=0,10 + VMIN=1 + VTIME=0 + FLAGS=0x1000 + FG=0,0 + BG=0,0, + 0,0,0,1, + 0,19,0,0, + 1,0,0,1, + 1,19,0,0, + 2,0,0,1, + 2,19,0,0, + 3,0,0,1, + 3,19,0,0, + 4,0,0,1, + 4,5,0x20,0,Hello + 4,10,0,1, + 4,19,0,0, + 5,0,0,1, + 5,5,0x4,2,World! + 5,11,0,1, + 5,19,0,0, + 6,0,0,1, + 6,19,0,0, + 7,0,0,1, + 7,19,0,0, + 8,0,0,1, + 8,19,0,0, + 9,0,0,1, + 9,19,0,0, + CUR=11,5 Solaris getwin requires that all parameters are present, and in the same order. The xpg4 curses library does not know about the bce (back @@ -368,28 +368,28 @@

    scr_dump 5

    ground color. However, its screen dumps are in binary. Here is the corresponding dump (using "od -t x1"): - 0000000 1c 01 c3 d6 f3 58 05 00 0b 00 0a 00 14 00 00 00 - 0000020 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 - 0000040 00 00 b8 1a 06 08 cc 1a 06 08 00 00 09 00 10 00 - 0000060 00 00 00 80 00 00 20 00 00 00 ff ff ff ff 00 00 - 0000100 ff ff ff ff 00 00 00 00 20 80 00 00 20 80 00 00 - 0000120 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 - * - 0000620 20 80 00 00 20 80 00 00 20 80 00 00 48 80 00 04 - 0000640 65 80 00 04 6c 80 00 04 6c 80 00 04 6f 80 00 04 - 0000660 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 - * - 0000740 20 80 00 00 20 80 00 00 20 80 00 00 57 00 81 00 - 0000760 6f 00 81 00 72 00 81 00 6c 00 81 00 64 00 81 00 - 0001000 21 00 81 00 20 80 00 00 20 80 00 00 20 80 00 00 - 0001020 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 - * - 0001540 20 80 00 00 20 80 00 00 00 00 f6 d1 01 00 f6 d1 - 0001560 08 00 00 00 40 00 00 00 00 00 00 00 00 00 00 07 - 0001600 00 04 00 01 00 01 00 00 00 01 00 00 00 00 00 00 - 0001620 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 - * - 0002371 + 0000000 1c 01 c3 d6 f3 58 05 00 0b 00 0a 00 14 00 00 00 + 0000020 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 + 0000040 00 00 b8 1a 06 08 cc 1a 06 08 00 00 09 00 10 00 + 0000060 00 00 00 80 00 00 20 00 00 00 ff ff ff ff 00 00 + 0000100 ff ff ff ff 00 00 00 00 20 80 00 00 20 80 00 00 + 0000120 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 + * + 0000620 20 80 00 00 20 80 00 00 20 80 00 00 48 80 00 04 + 0000640 65 80 00 04 6c 80 00 04 6c 80 00 04 6f 80 00 04 + 0000660 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 + * + 0000740 20 80 00 00 20 80 00 00 20 80 00 00 57 00 81 00 + 0000760 6f 00 81 00 72 00 81 00 6c 00 81 00 64 00 81 00 + 0001000 21 00 81 00 20 80 00 00 20 80 00 00 20 80 00 00 + 0001020 20 80 00 00 20 80 00 00 20 80 00 00 20 80 00 00 + * + 0001540 20 80 00 00 20 80 00 00 00 00 f6 d1 01 00 f6 d1 + 0001560 08 00 00 00 40 00 00 00 00 00 00 00 00 00 00 07 + 0001600 00 04 00 01 00 01 00 00 00 01 00 00 00 00 00 00 + 0001620 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 + * + 0002371

    SEE ALSO

    diff --git a/doc/html/man/tabs.1.html b/doc/html/man/tabs.1.html
    index 8ce3ea256..1354f6c55 100644
    --- a/doc/html/man/tabs.1.html
    +++ b/doc/html/man/tabs.1.html
    @@ -1,6 +1,6 @@
     
     
     
    @@ -59,7 +59,7 @@ 

    tabs 1

    absent, tabs is unable to clear/set tab-stops. The terminal should be configured to use hard tabs, e.g., - stty tab0 + stty tab0 Like clear(1), tabs writes to the standard output. You can redirect the standard output to a file (which prevents tabs from actually chang- @@ -107,13 +107,13 @@

    tabs 1

    greater than zero. They are separated by a comma or a blank, for exam- ple, - tabs 1,6,11,16,21 - tabs 1 6 11 16 21 + tabs 1,6,11,16,21 + tabs 1 6 11 16 21 Use a "+" to treat a number as an increment relative to the previous value, e.g., - tabs 1,+5,+5,+5,+5 + tabs 1,+5,+5,+5,+5 which is equivalent to the 1,6,11,16,21 example. @@ -164,7 +164,7 @@

    tabs 1

    SEE ALSO

            tset(1), infocmp(1m), curses(3x), terminfo(5).
     
    -       This describes ncurses version 6.0 (patch 20171028).
    +       This describes ncurses version 6.0 (patch 20171118).
     
     
     
    diff --git a/doc/html/man/terminfo.5.html b/doc/html/man/terminfo.5.html
    index e4202c536..864745d4d 100644
    --- a/doc/html/man/terminfo.5.html
    +++ b/doc/html/man/terminfo.5.html
    @@ -74,7 +74,7 @@ 

    terminfo 5 File Formats

    Terminfo describes terminals by giving a set of capabilities which they have, by specifying how to perform screen operations, and by specifying padding requirements and initialization sequences. This describes - ncurses version 6.0 (patch 20171028). + ncurses version 6.0 (patch 20171118).

    Terminfo Entry Syntax

    diff --git a/doc/html/man/tic.1m.html b/doc/html/man/tic.1m.html
    index 960c27111..83ba73f13 100644
    --- a/doc/html/man/tic.1m.html
    +++ b/doc/html/man/tic.1m.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: tic.1m,v 1.65 2017/07/08 19:48:37 tom Exp @
    +  * @Id: tic.1m,v 1.66 2017/11/18 23:51:17 tom Exp @
     -->
     
     
    @@ -364,7 +364,7 @@ 

    tic 1m

    infocmp(1m), captoinfo(1m), infotocap(1m), toe(1m), curses(3x), term(5). terminfo(5). - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118).

    AUTHOR

    diff --git a/doc/html/man/toe.1m.html b/doc/html/man/toe.1m.html
    index d6f6307ff..a3d4d69a2 100644
    --- a/doc/html/man/toe.1m.html
    +++ b/doc/html/man/toe.1m.html
    @@ -113,7 +113,7 @@ 

    toe 1m

    tic(1m), infocmp(1m), captoinfo(1m), infotocap(1m), curses(3x), ter- minfo(5). - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118). diff --git a/doc/html/man/tput.1.html b/doc/html/man/tput.1.html index 50b7a8967..558c39cc4 100644 --- a/doc/html/man/tput.1.html +++ b/doc/html/man/tput.1.html @@ -27,7 +27,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: tput.1,v 1.55 2017/08/19 14:26:42 tom Exp @ + * @Id: tput.1,v 1.56 2017/11/18 23:51:17 tom Exp @ --> @@ -482,7 +482,7 @@

    tput 1

    SEE ALSO

            clear(1), stty(1), tabs(1), tset(1), terminfo(5), curs_termcap(3x).
     
    -       This describes ncurses version 6.0 (patch 20171028).
    +       This describes ncurses version 6.0 (patch 20171118).
     
     
     
    diff --git a/doc/html/man/tset.1.html b/doc/html/man/tset.1.html
    index 24a58a802..729cc0661 100644
    --- a/doc/html/man/tset.1.html
    +++ b/doc/html/man/tset.1.html
    @@ -26,7 +26,7 @@
       * sale, use or other dealings in this Software without prior written       *
       * authorization.                                                           *
       ****************************************************************************
    -  * @Id: tset.1,v 1.49 2017/04/16 21:30:15 tom Exp @
    +  * @Id: tset.1,v 1.50 2017/11/18 23:51:17 tom Exp @
     -->
     
     
    @@ -389,7 +389,7 @@ 

    tset 1

    csh(1), sh(1), stty(1), curs_terminfo(3x), tty(4), terminfo(5), ttys(5), environ(7) - This describes ncurses version 6.0 (patch 20171028). + This describes ncurses version 6.0 (patch 20171118). diff --git a/doc/html/man/user_caps.5.html b/doc/html/man/user_caps.5.html index 5dcaa9e4c..cc9e398b4 100644 --- a/doc/html/man/user_caps.5.html +++ b/doc/html/man/user_caps.5.html @@ -26,7 +26,7 @@ * sale, use or other dealings in this Software without prior written * * authorization. * **************************************************************************** - * @Id: user_caps.5,v 1.2 2017/09/04 19:27:24 tom Exp @ + * @Id: user_caps.5,v 1.3 2017/11/18 23:51:59 tom Exp @ --> diff --git a/man/clear.1 b/man/clear.1 index 16914dbb9..2c4fb22af 100644 --- a/man/clear.1 +++ b/man/clear.1 @@ -26,14 +26,14 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: clear.1,v 1.18 2017/10/07 21:30:17 tom Exp $ +.\" $Id: clear.1,v 1.19 2017/11/18 23:51:59 tom Exp $ .TH @CLEAR@ 1 "" .\" these would be fallbacks for DS/DE, .\" but groff changed the meaning of the macros. .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier @@ -48,7 +48,8 @@ .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .SH NAME diff --git a/man/curs_add_wch.3x b/man/curs_add_wch.3x index ed97099f6..1c50b2cd9 100644 --- a/man/curs_add_wch.3x +++ b/man/curs_add_wch.3x @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_add_wch.3x,v 1.23 2017/05/20 14:45:24 Sven.Joachim Exp $ +.\" $Id: curs_add_wch.3x,v 1.24 2017/11/18 23:47:37 tom Exp $ .TH curs_add_wch 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBadd_wch\fP, diff --git a/man/curs_add_wchstr.3x b/man/curs_add_wchstr.3x index 37e3df614..a7729b903 100644 --- a/man/curs_add_wchstr.3x +++ b/man/curs_add_wchstr.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2002-2010,2012 Free Software Foundation, Inc. * +.\" Copyright (c) 2002-2012,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_add_wchstr.3x,v 1.10 2012/11/03 22:54:43 tom Exp $ +.\" $Id: curs_add_wchstr.3x,v 1.11 2017/11/18 23:56:00 tom Exp $ .TH curs_add_wchstr 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_addch.3x b/man/curs_addch.3x index 151c3160c..69a59d603 100644 --- a/man/curs_addch.3x +++ b/man/curs_addch.3x @@ -27,14 +27,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_addch.3x,v 1.41 2017/05/05 18:15:29 tom Exp $ +.\" $Id: curs_addch.3x,v 1.43 2017/11/19 01:54:00 tom Exp $ .TH curs_addch 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBaddch\fR, @@ -175,6 +176,7 @@ Note that \fBaddch\fR, \fBmvaddch\fR, \fBmvwaddch\fR, and .SH PORTABILITY All these functions are described in the XSI Curses standard, Issue 4. The defaults specified for forms-drawing characters apply in the POSIX locale. +.SS ACS Symbols .LP X/Open Curses states that the \fIACS_\fP definitions are \fBchar\fP constants. For the wide-character implementation (see \fBcurs_add_wch\fP), @@ -205,6 +207,44 @@ whether the \fIlocale\fP uses UTF-8 encoding. In certain cases, the terminal is unable to display line-drawing characters except by using UTF-8 (see the discussion of \fBNCURSES_NO_UTF8_ACS\fP in ncurses(3X)). +.SS Character Set +X/Open Curses assumes that the parameter passed to \fBwaddch\fP contains +a single character. +As discussed in \fBcurs_attr(3X)\fP, that character may have been +more than eight bits in an SVr3 or SVr4 implementation, +but in the X/Open Curses model, the details are not given. +The important distinction between SVr4 curses and X/Open Curses is +that the non-character information (attributes and color) was +separated from the character information which is packed in a \fBchtype\fP +to pass to \fBwaddch\fP. +.PP +In this implementation, \fBchtype\fP holds eight bits. +But ncurses allows multibyte characters to be passed in a succession +of calls to \fBwaddch\fP. +The other implementations do not do this; +a call to \fBwaddch\fP passes exactly one character +which may be rendered as one or more cells on the screen +depending on whether it is printable. +.PP +Depending on the locale settings, +ncurses will inspect the byte passed in each call to \fBwaddch\fP, +and check if the latest call will continue a multibyte sequence. +When a character is \fIcomplete\fP, +ncurses displays the character and moves to the next position in the screen. +.PP +If the calling application interrupts the succession of bytes in +a multibyte character by moving the current location (e.g., using \fBwmove\fP), +ncurses discards the partially built character, +starting over again. +.PP +For portability to other implementations, +do not rely upon this behavior: +.bP +check if a character can be represented as a single byte in the current locale +before attempting call \fBwaddch\fP, and +.bP +call \fBwadd_wch\fP for characters which cannot be handled by \fBwaddch\fP. +.SS TABSIZE .LP The \fBTABSIZE\fR variable is implemented in some versions of curses, but is not part of X/Open curses. diff --git a/man/curs_addchstr.3x b/man/curs_addchstr.3x index 08536e330..44d1b79f3 100644 --- a/man/curs_addchstr.3x +++ b/man/curs_addchstr.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 1998-2010,2012 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2012,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_addchstr.3x,v 1.16 2012/11/03 22:54:43 tom Exp $ +.\" $Id: curs_addchstr.3x,v 1.17 2017/11/18 23:56:00 tom Exp $ .TH curs_addchstr 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_addstr.3x b/man/curs_addstr.3x index b1cb1cc25..67a57785f 100644 --- a/man/curs_addstr.3x +++ b/man/curs_addstr.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 1998-2010,2012 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2012,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_addstr.3x,v 1.17 2012/11/03 22:57:31 tom Exp $ +.\" $Id: curs_addstr.3x,v 1.18 2017/11/18 23:56:00 tom Exp $ .TH curs_addstr 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_addwstr.3x b/man/curs_addwstr.3x index 835cb3401..3a59a848f 100644 --- a/man/curs_addwstr.3x +++ b/man/curs_addwstr.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2002-2010,2012 Free Software Foundation, Inc. * +.\" Copyright (c) 2002-2012,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_addwstr.3x,v 1.11 2012/11/03 22:57:31 tom Exp $ +.\" $Id: curs_addwstr.3x,v 1.12 2017/11/18 23:56:00 tom Exp $ .TH curs_addwstr 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_attr.3x b/man/curs_attr.3x index c3113e151..611df4b36 100644 --- a/man/curs_attr.3x +++ b/man/curs_attr.3x @@ -27,14 +27,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_attr.3x,v 1.60 2017/10/14 20:01:13 tom Exp $ +.\" $Id: curs_attr.3x,v 1.61 2017/11/18 23:47:37 tom Exp $ .TH curs_attr 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_bkgd.3x b/man/curs_bkgd.3x index ef00f7e7b..757186cf5 100644 --- a/man/curs_bkgd.3x +++ b/man/curs_bkgd.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 1998-2010,2015 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2015,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,9 +26,10 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_bkgd.3x,v 1.24 2015/11/21 01:53:42 tom Exp $ +.\" $Id: curs_bkgd.3x,v 1.25 2017/11/18 23:56:00 tom Exp $ .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .TH curs_bkgd 3X "" .SH NAME diff --git a/man/curs_bkgrnd.3x b/man/curs_bkgrnd.3x index f9b4f4196..1a6b0e840 100644 --- a/man/curs_bkgrnd.3x +++ b/man/curs_bkgrnd.3x @@ -26,9 +26,10 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_bkgrnd.3x,v 1.7 2017/03/25 21:49:00 tom Exp $ +.\" $Id: curs_bkgrnd.3x,v 1.8 2017/11/18 23:47:37 tom Exp $ .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .TH curs_bkgrnd 3X "" .SH NAME diff --git a/man/curs_color.3x b/man/curs_color.3x index c0bc51010..da1d8c96d 100644 --- a/man/curs_color.3x +++ b/man/curs_color.3x @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_color.3x,v 1.51 2017/08/12 21:40:14 tom Exp $ +.\" $Id: curs_color.3x,v 1.52 2017/11/18 23:47:37 tom Exp $ .TH curs_color 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .na diff --git a/man/curs_get_wch.3x b/man/curs_get_wch.3x index fd55b374b..6732a4eb0 100644 --- a/man/curs_get_wch.3x +++ b/man/curs_get_wch.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2002-2012,2016 Free Software Foundation, Inc. * +.\" Copyright (c) 2002-2016,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,12 +26,13 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_get_wch.3x,v 1.9 2016/05/15 01:12:50 tom Exp $ +.\" $Id: curs_get_wch.3x,v 1.10 2017/11/18 23:56:00 tom Exp $ .TH curs_get_wch 3X "" .na .hy 0 .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBget_wch\fR, diff --git a/man/curs_getcchar.3x b/man/curs_getcchar.3x index a106a2230..e70e09523 100644 --- a/man/curs_getcchar.3x +++ b/man/curs_getcchar.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_getcchar.3x,v 1.18 2017/03/31 10:50:54 tom Exp $ +.\" $Id: curs_getcchar.3x,v 1.19 2017/11/18 23:47:37 tom Exp $ .TH curs_getcchar 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBgetcchar\fP, diff --git a/man/curs_getch.3x b/man/curs_getch.3x index b8d6a82b0..ce4b959ea 100644 --- a/man/curs_getch.3x +++ b/man/curs_getch.3x @@ -1,6 +1,6 @@ '\" t .\"*************************************************************************** -.\" Copyright (c) 1998-2015,2016 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2016,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -27,12 +27,13 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_getch.3x,v 1.49 2016/10/15 16:44:01 tom Exp $ +.\" $Id: curs_getch.3x,v 1.50 2017/11/18 23:56:00 tom Exp $ .TH curs_getch 3X "" .na .hy 0 .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBgetch\fR, diff --git a/man/curs_inch.3x b/man/curs_inch.3x index 3386900ad..97eb981f4 100644 --- a/man/curs_inch.3x +++ b/man/curs_inch.3x @@ -27,10 +27,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_inch.3x,v 1.19 2017/10/28 20:16:52 Sven.Joachim Exp $ +.\" $Id: curs_inch.3x,v 1.20 2017/11/18 23:47:37 tom Exp $ .TH curs_inch 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBinch\fR, diff --git a/man/curs_inchstr.3x b/man/curs_inchstr.3x index 0f2a91343..853c2421e 100644 --- a/man/curs_inchstr.3x +++ b/man/curs_inchstr.3x @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_inchstr.3x,v 1.16 2017/04/29 21:31:17 tom Exp $ +.\" $Id: curs_inchstr.3x,v 1.17 2017/11/18 23:47:37 tom Exp $ .TH curs_inchstr 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_initscr.3x b/man/curs_initscr.3x index 0082b03e8..f692535f7 100644 --- a/man/curs_initscr.3x +++ b/man/curs_initscr.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_initscr.3x,v 1.28 2017/05/30 21:12:51 tom Exp $ +.\" $Id: curs_initscr.3x,v 1.29 2017/11/18 23:47:37 tom Exp $ .TH curs_initscr 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ie \n(.g .ds `` \(lq .el .ds `` `` diff --git a/man/curs_instr.3x b/man/curs_instr.3x index bb6435b19..6d64353ae 100644 --- a/man/curs_instr.3x +++ b/man/curs_instr.3x @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_instr.3x,v 1.17 2017/04/29 21:37:55 tom Exp $ +.\" $Id: curs_instr.3x,v 1.18 2017/11/18 23:47:37 tom Exp $ .TH curs_instr 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBinstr\fR, diff --git a/man/curs_kernel.3x b/man/curs_kernel.3x index 505ea1eee..502dd469c 100644 --- a/man/curs_kernel.3x +++ b/man/curs_kernel.3x @@ -26,9 +26,10 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_kernel.3x,v 1.22 2017/01/07 19:25:15 tom Exp $ +.\" $Id: curs_kernel.3x,v 1.23 2017/11/18 23:47:37 tom Exp $ .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .TH curs_kernel 3X "" .na diff --git a/man/curs_legacy.3x b/man/curs_legacy.3x index 6ffac25d3..fa0930fe3 100644 --- a/man/curs_legacy.3x +++ b/man/curs_legacy.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2007-2010,2015 Free Software Foundation, Inc. * +.\" Copyright (c) 2007-2015,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,57 +26,82 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_legacy.3x,v 1.6 2015/12/05 20:33:14 tom Exp $ +.\" $Id: curs_legacy.3x,v 1.7 2017/11/19 00:23:58 tom Exp $ +.de bP +.ie n .IP \(bu 4 +.el .IP \(bu 2 +.. .TH curs_legacy 3X "" .SH NAME -curs_legacy \- get \fBcurses\fR cursor and window coordinates, attributes +curs_legacy \- get \fBcurses\fP cursor and window coordinates, attributes .SH SYNOPSIS -\fB#include \fR +\fB#include \fP .sp -\fBint getattrs(WINDOW *win);\fR +\fBint getattrs(WINDOW *win);\fP .br -\fBint getbegx(WINDOW *win);\fR +\fBint getbegx(WINDOW *win);\fP .br -\fBint getbegy(WINDOW *win);\fR +\fBint getbegy(WINDOW *win);\fP .br -\fBint getcurx(WINDOW *win);\fR +\fBint getcurx(WINDOW *win);\fP .br -\fBint getcury(WINDOW *win);\fR +\fBint getcury(WINDOW *win);\fP .br -\fBint getmaxx(WINDOW *win);\fR +\fBint getmaxx(WINDOW *win);\fP .br -\fBint getmaxy(WINDOW *win);\fR +\fBint getmaxy(WINDOW *win);\fP .br -\fBint getparx(WINDOW *win);\fR +\fBint getparx(WINDOW *win);\fP .br -\fBint getpary(WINDOW *win);\fR +\fBint getpary(WINDOW *win);\fP .br .SH DESCRIPTION -The \fBgetbegy\fR and \fBgetbegx\fR functions return the same -data as \fBgetbegyx\fR. -.PP -The \fBgetcury\fR and \fBgetcurx\fR functions return the same -data as \fBgetyx\fR. -.PP -The \fBgetmaxy\fR and \fBgetmaxx\fR functions return the same -data as \fBgetmaxyx\fR. -.PP -The \fBgetpary\fR and \fBgetparx\fR functions return the same -data as \fBgetparyx\fR. +These legacy functions are simpler to use than the X/Open Curses functions: +.bP +The \fBgetattrs\fP function returns the same attribute data as \fBwattr_get\fP. +.IP +However, \fBgetattrs\fP returns an integer (actually a \fBchtype\fP), +while \fBwattr_get\fP returns the current color pair in a separate parameter. +In the wide-character library configuration, +color pairs may not fit into a \fBchtype\fP, +so \fBwattr_get\fP is the only way to obtain the color information. +.IP +Because \fBgetattrs\fP returns the attributes in a single parameter, +it would not be possible for an application to distinguish that from +\fBERR\fP (a \fI-1\fP). +If the window parameter is null, \fBgetattrs\fP returns \fBA_NORMAL\fP (zero). +.bP +The \fBgetbegy\fP and \fBgetbegx\fP functions return the same +data as \fBgetbegyx\fP. +.bP +The \fBgetcury\fP and \fBgetcurx\fP functions return the same +data as \fBgetyx\fP. +.bP +The \fBgetmaxy\fP and \fBgetmaxx\fP functions return the same +data as \fBgetmaxyx\fP. +.bP +The \fBgetpary\fP and \fBgetparx\fP functions return the same +data as \fBgetparyx\fP. .SH RETURN VALUE -These functions return an integer, +Except as noted, +these functions return an integer, or ERR if the window parameter is null. .SH NOTES All of these interfaces are provided as macros and functions. The macros are suppressed (and only the functions provided) -when \fBNCURSES_OPAQUE\fR is defined. +when \fBNCURSES_OPAQUE\fP is defined. The standard forms such as \fBgetyx\fP must be implemented as macros, and (in this implementation) are defined in terms of the functions described here, to avoid reliance on internal details of the WINDOW structure. .SH PORTABILITY These functions were supported on Version 7, BSD or System V implementations. +None of those implementations checked the window parameter. +.PP +The \fBgetattrs\fP function and macro are defined to return a (signed) integer +for compatibility with those implementations +although an unsigned type would have been more appropriate. .SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_getyx\fR(3X), -\fBcurs_opaque\fR(3X) +\fBcurses\fP(3X), +\fBcurs_getyx\fP(3X), +\fBcurs_opaque\fP(3X) diff --git a/man/curs_mouse.3x b/man/curs_mouse.3x index 2a34e930f..7e15f3ae1 100644 --- a/man/curs_mouse.3x +++ b/man/curs_mouse.3x @@ -27,15 +27,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_mouse.3x,v 1.46 2017/05/20 14:42:41 Sven.Joachim Exp $ +.\" $Id: curs_mouse.3x,v 1.47 2017/11/18 23:52:45 tom Exp $ .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier @@ -46,7 +46,8 @@ .in -4 .. .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .TH curs_mouse 3X "" .na diff --git a/man/curs_pad.3x b/man/curs_pad.3x index 1b427e100..495fc7b1d 100644 --- a/man/curs_pad.3x +++ b/man/curs_pad.3x @@ -26,7 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_pad.3x,v 1.19 2017/01/07 19:25:15 tom Exp $ +.\" $Id: curs_pad.3x,v 1.23 2017/11/19 01:29:46 tom Exp $ +.de bP +.ie n .IP \(bu 4 +.el .IP \(bu 2 +.. .TH curs_pad 3X "" .na .hy 0 @@ -68,6 +72,7 @@ Pads can be used when a large window is needed, and only a part of the window will be on the screen at one time. Automatic refreshes of pads (e.g., from scrolling or echoing of input) do not occur. +.PP It is not legal to call \fBwrefresh\fR with a \fIpad\fR as an argument; the routines \fBprefresh\fR or \fBpnoutrefresh\fR should be called instead. @@ -93,12 +98,15 @@ The \fBprefresh\fR and \fBpnoutrefresh\fR routines are analogous to of windows. The additional parameters are needed to indicate what part of the pad and screen are involved. +.bP The \fIpminrow\fR and \fIpmincol\fR parameters specify the upper left-hand corner of the rectangle to be displayed in the pad. +.bP The \fIsminrow\fR, \fIsmincol\fR, \fIsmaxrow\fR, and \fIsmaxcol\fR parameters specify the edges of the rectangle to be displayed on the screen. +.PP The lower right-hand corner of the rectangle to be displayed in the pad is calculated from the screen coordinates, since the rectangles must be the same size. @@ -157,6 +165,71 @@ to \fBwecho_wchar\fP returns an error. .SH NOTES Note that \fBpechochar\fR may be a macro. .SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. +BSD curses has no \fIpad\fP feature. +.PP +SVr2 curses (1986) provided the \fBnewpad\fP and related functions, +documenting them in a single line each. +SVr3 (1987) provided more extensive documentation. +.PP +The documentation does not explain the term \fIpad\fP. +However, the Apollo \fIAegis\fP workstation operating system +supported a graphical \fIpad\fP feature: +.bP +These graphical pads could be much larger than the computer's display. +.bP +The read-only output from a command could be scrolled back to inspect, +and select text from the pad. +.PP +The two uses may be related. +.PP +The XSI Curses standard, Issue 4 describes these functions, +without significant change from the SVr3 documentation. +It describes no error conditions. +The behavior of \fBsubpad\fP if the parent window is not +a pad is undocumented, +and is not checked by the vendor Unix implementations: +.bP +SVr4 curses sets a flag in the \fBWINDOW\fP structure in \fBnewpad\fP +which tells if the window is a \fIpad\fP. +.IP +However, it uses this information only in \fBwscrl\fP, +and does not check in \fBwrefresh\fP to ensure that the pad +is refreshed properly. +.bP +Solaris X/Open Curses checks if a window is a pad in \fBwnoutrefresh\fP, +returning \fBERR\fP in that case. +.IP +However, it only sets the flag for subwindows if the parent window is a pad. +Its \fBnewpad\fP function does not set this information. +Consequently, the check will never fail. +.IP +It makes no comparable check in \fBpnoutrefresh\fP, +though interestingly enough, a comment in the source code +states that the lack of a check was an MKS extension. +.bP +NetBSD 7 curses +sets a flag in the \fBWINDOW\fP structure for \fBnewpad\fP and \fBsubpad\fP, +using this to help with the distinction between \fBwnoutrefresh\fP +and \fBpnoutrefresh\fP. +.IP +It does not check for the case where a subwindow is created in +a pad using \fBsubwin\fP or \fBderwin\fP. +.IP +The \fBdupwin\fP function returns a regular window when duplicating a pad. +Likewise, \fBgetwin\fP always returns a window, even if the saved +data was from a pad. +.PP +This implementation +.bP +sets a flag in the \fBWINDOW\fP structure for \fBnewpad\fP and \fBsubpad\fP, +.bP +allows a \fBsubwin\fP or \fBderwin\fP call to succeed having a pad parent by +forcing the subwindow to be a pad, +.bP +checks in both \fBwnoutrefresh\fP and \fBpnoutrefresh\fP to ensure +that pads and windows are handled distinctly, and +.bP +ensures that \fBdupwin\fP and \fBgetwin\fP treat +pads versus windows consistently. .SH SEE ALSO \fBcurses\fR(3X), \fBcurs_refresh\fR(3X), \fBcurs_touch\fR(3X), \fBcurs_addch\fR(3X). diff --git a/man/curs_slk.3x b/man/curs_slk.3x index 0b9b1d0b8..8024b06bc 100644 --- a/man/curs_slk.3x +++ b/man/curs_slk.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_slk.3x,v 1.31 2017/03/31 11:09:28 tom Exp $ +.\" $Id: curs_slk.3x,v 1.32 2017/11/18 23:47:37 tom Exp $ .TH curs_slk 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_termcap.3x b/man/curs_termcap.3x index d3c974bc3..a0800c1bb 100644 --- a/man/curs_termcap.3x +++ b/man/curs_termcap.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_termcap.3x,v 1.33 2017/01/07 19:25:15 tom Exp $ +.\" $Id: curs_termcap.3x,v 1.34 2017/11/18 23:47:37 tom Exp $ .TH curs_termcap 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_terminfo.3x b/man/curs_terminfo.3x index 0b75f564c..01772467c 100644 --- a/man/curs_terminfo.3x +++ b/man/curs_terminfo.3x @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_terminfo.3x,v 1.55 2017/03/31 15:16:15 tom Exp $ +.\" $Id: curs_terminfo.3x,v 1.56 2017/11/18 23:47:37 tom Exp $ .TH curs_terminfo 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .na diff --git a/man/curs_threads.3x b/man/curs_threads.3x index 350d5eea2..c2847f96c 100644 --- a/man/curs_threads.3x +++ b/man/curs_threads.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2008-2014,2015 Free Software Foundation, Inc. * +.\" Copyright (c) 2008-2015,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_threads.3x,v 1.23 2015/12/05 18:47:04 tom Exp $ +.\" $Id: curs_threads.3x,v 1.24 2017/11/18 23:56:00 tom Exp $ .TH curs_threads 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_touch.3x b/man/curs_touch.3x index aa2ba5bf6..d576fe5d7 100644 --- a/man/curs_touch.3x +++ b/man/curs_touch.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 1998-2010,2015 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2015,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,7 +26,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_touch.3x,v 1.16 2015/12/05 23:43:00 tom Exp $ +.\" $Id: curs_touch.3x,v 1.17 2017/11/18 23:40:19 tom Exp $ .TH curs_touch 3X "" .na .hy 0 @@ -84,7 +84,7 @@ preceding routine descriptions. .PP X/Open does not define any error conditions. In this implementation -.RS +.RS 3 .TP 5 \fBis_linetouched\fP returns an error diff --git a/man/curs_trace.3x b/man/curs_trace.3x index 64d4c18ad..792b7e95a 100644 --- a/man/curs_trace.3x +++ b/man/curs_trace.3x @@ -26,9 +26,10 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_trace.3x,v 1.18 2017/01/14 19:46:40 tom Exp $ +.\" $Id: curs_trace.3x,v 1.19 2017/11/18 23:47:37 tom Exp $ .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .TH curs_trace 3X "" .na diff --git a/man/curs_util.3x b/man/curs_util.3x index 6901dd7ae..1f22dff10 100644 --- a/man/curs_util.3x +++ b/man/curs_util.3x @@ -27,14 +27,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_util.3x,v 1.51 2017/10/07 21:47:25 tom Exp $ +.\" $Id: curs_util.3x,v 1.52 2017/11/18 23:47:37 tom Exp $ .TH curs_util 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .na .hy 0 diff --git a/man/curs_variables.3x b/man/curs_variables.3x index 1bd0f335e..811edaf84 100644 --- a/man/curs_variables.3x +++ b/man/curs_variables.3x @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2010-2013,2015 Free Software Foundation, Inc. * +.\" Copyright (c) 2010-2015,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: curs_variables.3x,v 1.8 2015/08/22 23:33:22 tom Exp $ +.\" $Id: curs_variables.3x,v 1.9 2017/11/18 23:56:00 tom Exp $ .TH curs_variables 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .na diff --git a/man/form_driver.3x b/man/form_driver.3x index 75c0a7b75..a40be36ef 100644 --- a/man/form_driver.3x +++ b/man/form_driver.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: form_driver.3x,v 1.27 2017/06/23 22:56:39 tom Exp $ +.\" $Id: form_driver.3x,v 1.28 2017/11/18 23:47:37 tom Exp $ .TH form_driver 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBform_driver\fR, diff --git a/man/form_field_buffer.3x b/man/form_field_buffer.3x index b4ff8cb76..9ecb191b1 100644 --- a/man/form_field_buffer.3x +++ b/man/form_field_buffer.3x @@ -1,6 +1,6 @@ '\" t .\"*************************************************************************** -.\" Copyright (c) 1998-2008,2010 Free Software Foundation, Inc. * +.\" Copyright (c) 1998-2010,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -27,10 +27,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: form_field_buffer.3x,v 1.19 2010/12/04 18:38:55 tom Exp $ +.\" $Id: form_field_buffer.3x,v 1.20 2017/11/18 23:56:00 tom Exp $ .TH form_field_buffer 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBform_field_buffer\fR \- field buffer control diff --git a/man/infocmp.1m b/man/infocmp.1m index 807dc08e4..16ceb07fd 100644 --- a/man/infocmp.1m +++ b/man/infocmp.1m @@ -27,7 +27,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: infocmp.1m,v 1.66 2017/08/13 00:21:55 tom Exp $ +.\" $Id: infocmp.1m,v 1.67 2017/11/18 23:51:17 tom Exp $ .TH @INFOCMP@ 1M "" .ie \n(.g .ds `` \(lq .el .ds `` `` @@ -35,7 +35,8 @@ .el .ds '' '' .ds n 5 .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds d @TERMINFO@ .SH NAME diff --git a/man/menu_driver.3x b/man/menu_driver.3x index 835d67517..7612eeb84 100644 --- a/man/menu_driver.3x +++ b/man/menu_driver.3x @@ -26,10 +26,11 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: menu_driver.3x,v 1.21 2017/01/07 19:25:15 tom Exp $ +.\" $Id: menu_driver.3x,v 1.22 2017/11/18 23:47:37 tom Exp $ .TH menu_driver 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBmenu_driver\fR \- command-processing loop of the menu system diff --git a/man/ncurses.3x b/man/ncurses.3x index 6114ee283..e73543edc 100644 --- a/man/ncurses.3x +++ b/man/ncurses.3x @@ -27,7 +27,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: ncurses.3x,v 1.135 2017/08/12 22:27:43 tom Exp $ +.\" $Id: ncurses.3x,v 1.136 2017/11/18 23:48:44 tom Exp $ .hy 0 .TH ncurses 3X "" .ie \n(.g .ds `` \(lq @@ -35,12 +35,13 @@ .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier diff --git a/man/new_pair.3x b/man/new_pair.3x index 8bd40202c..e39351904 100644 --- a/man/new_pair.3x +++ b/man/new_pair.3x @@ -28,19 +28,20 @@ .\" .\" Author: Thomas E. Dickey .\" -.\" $Id: new_pair.3x,v 1.9 2017/03/13 21:21:34 tom Exp $ +.\" $Id: new_pair.3x,v 1.10 2017/11/18 23:48:44 tom Exp $ .TH new_pair 3X "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier diff --git a/man/resizeterm.3x b/man/resizeterm.3x index be0756cee..c2e553c4f 100644 --- a/man/resizeterm.3x +++ b/man/resizeterm.3x @@ -28,10 +28,11 @@ .\" .\" Author: Thomas E. Dickey 1996-on .\" -.\" $Id: resizeterm.3x,v 1.23 2017/05/30 21:08:21 tom Exp $ +.\" $Id: resizeterm.3x,v 1.24 2017/11/18 23:47:37 tom Exp $ .TH resizeterm 3X "" .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fBis_term_resized\fR, diff --git a/man/scr_dump.5 b/man/scr_dump.5 index 88c427bca..fe3bd56c0 100644 --- a/man/scr_dump.5 +++ b/man/scr_dump.5 @@ -26,16 +26,16 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: scr_dump.5,v 1.10 2017/04/29 20:53:55 tom Exp $ +.\" $Id: scr_dump.5,v 1.11 2017/11/18 23:51:59 tom Exp $ .TH scr_dump 5 .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier @@ -46,7 +46,8 @@ .in -4 .. .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .ds d @TERMINFO@ diff --git a/man/tabs.1 b/man/tabs.1 index 5cb0e3fa5..6f973a618 100644 --- a/man/tabs.1 +++ b/man/tabs.1 @@ -1,5 +1,5 @@ .\"*************************************************************************** -.\" Copyright (c) 2008-2013,2016 Free Software Foundation, Inc. * +.\" Copyright (c) 2008-2016,2017 Free Software Foundation, Inc. * .\" * .\" Permission is hereby granted, free of charge, to any person obtaining a * .\" copy of this software and associated documentation files (the * @@ -26,7 +26,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: tabs.1,v 1.15 2016/12/31 16:07:39 tom Exp $ +.\" $Id: tabs.1,v 1.16 2017/11/18 23:56:00 tom Exp $ .TH @TABS@ 1 "" .ds n 5 .ie \n(.g .ds `` \(lq @@ -34,12 +34,13 @@ .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier diff --git a/man/tic.1m b/man/tic.1m index c3322e670..cd1fd4f95 100644 --- a/man/tic.1m +++ b/man/tic.1m @@ -26,7 +26,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: tic.1m,v 1.65 2017/07/08 19:48:37 tom Exp $ +.\" $Id: tic.1m,v 1.66 2017/11/18 23:51:17 tom Exp $ .TH @TIC@ 1M "" .ie \n(.g .ds `` \(lq .el .ds `` `` @@ -35,7 +35,8 @@ .ds n 5 .ds d @TERMINFO@ .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fB@TIC@\fR \- the \fIterminfo\fR entry-description compiler diff --git a/man/tput.1 b/man/tput.1 index 0f984a743..72e08311a 100644 --- a/man/tput.1 +++ b/man/tput.1 @@ -27,7 +27,7 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: tput.1,v 1.55 2017/08/19 14:26:42 tom Exp $ +.\" $Id: tput.1,v 1.56 2017/11/18 23:51:17 tom Exp $ .TH @TPUT@ 1 "" .ds d @TERMINFO@ .ds n 1 @@ -36,7 +36,8 @@ .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fB@TPUT@\fR, \fBreset\fR \- initialize a terminal or query terminfo database diff --git a/man/tset.1 b/man/tset.1 index c011f792c..1c27efa45 100644 --- a/man/tset.1 +++ b/man/tset.1 @@ -26,14 +26,15 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: tset.1,v 1.49 2017/04/16 21:30:15 tom Exp $ +.\" $Id: tset.1,v 1.50 2017/11/18 23:51:17 tom Exp $ .TH @TSET@ 1 "" .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .SH NAME \fB@TSET@\fR, \fB@RESET@\fR \- terminal initialization diff --git a/man/user_caps.5 b/man/user_caps.5 index 0f20dad1c..21e079fe8 100644 --- a/man/user_caps.5 +++ b/man/user_caps.5 @@ -26,16 +26,16 @@ .\" authorization. * .\"*************************************************************************** .\" -.\" $Id: user_caps.5,v 1.2 2017/09/04 19:27:24 tom Exp $ +.\" $Id: user_caps.5,v 1.3 2017/11/18 23:51:59 tom Exp $ .TH user_caps 5 .ie \n(.g .ds `` \(lq .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' .de NS -.ie \n(.sp +.ie n .sp .el .sp .5 -.ie \n(.in +4 +.ie n .in +4 .el .in +2 .nf .ft C \" Courier @@ -46,7 +46,8 @@ .in -4 .. .de bP -.IP \(bu 4 +.ie n .IP \(bu 4 +.el .IP \(bu 2 .. .ds n 5 .SH NAME diff --git a/misc/terminfo.src b/misc/terminfo.src index e3a6079e8..4b3313fe8 100644 --- a/misc/terminfo.src +++ b/misc/terminfo.src @@ -6,8 +6,8 @@ # Report bugs and new terminal descriptions to # bug-ncurses@gnu.org # -# $Revision: 1.623 $ -# $Date: 2017/11/11 20:24:40 $ +# $Revision: 1.644 $ +# $Date: 2017/11/18 21:38:11 $ # # The original header is preserved below for reference. It is noted that there # is a "newer" version which differs in some cosmetic details (but actually @@ -1450,16 +1450,18 @@ iTerm2.app|iterm2|terminal emulator for Mac OS X, kf15=\E[1;2R, kf16=\E[1;2S, kf17=\E[15;2~, kf18=\E[17;2~, kf19=\E[18;2~, kf2=\EOQ, kf20=\E[19;2~, kf21=\E[20;2~, kf22=\E[21;2~, kf23=\E[23;2~, kf24=\E[24;2~, - kind=\E[1;2B, kri=\E[1;2A, kDN3=\E\E[B, kDN4=\E[1;10B, - kDN5=\E[1;5B, kDN6=\E[1;6B, kEND3=\E[1;9F, - kEND4=\E[1;10F, kEND6=\E[1;6F, kEND7=\E[1;13F, - kEND8=\E[1;14F, kHOM3=\E[1;9H, kHOM4=\E[1;10H, - kHOM6=\E[1;6H, kHOM7=\E[1;13H, kHOM8=\E[1;14H, - kLFT3=\E\E[D, kLFT4=\E[1;10D, kLFT5=\E[1;5D, - kLFT6=\E[1;6D, kNXT3=\E\E[6~, kPRV3=\E\E[5~, - kRIT3=\E\E[C, kRIT4=\E[1;10C, kRIT5=\E[1;5C, - kRIT6=\E[1;6C, kUP3=\E\E[A, kUP4=\E[1;10A, kUP5=\E[1;5A, - kUP6=\E[1;6A, use=ecma+italics, use=iterm, + kind=\E[1;2B, kri=\E[1;2A, + sgr=\E[0%?%p6%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%? + %p5%t;2%;m%?%p9%t\016%e\017%;, + kDN3=\E\E[B, kDN4=\E[1;10B, kDN5=\E[1;5B, kDN6=\E[1;6B, + kEND3=\E[1;9F, kEND4=\E[1;10F, kEND6=\E[1;6F, + kEND7=\E[1;13F, kEND8=\E[1;14F, kHOM3=\E[1;9H, + kHOM4=\E[1;10H, kHOM6=\E[1;6H, kHOM7=\E[1;13H, + kHOM8=\E[1;14H, kLFT3=\E\E[D, kLFT4=\E[1;10D, + kLFT5=\E[1;5D, kLFT6=\E[1;6D, kNXT3=\E\E[6~, + kPRV3=\E\E[5~, kRIT3=\E\E[C, kRIT4=\E[1;10C, + kRIT5=\E[1;5C, kRIT6=\E[1;6C, kUP3=\E\E[A, kUP4=\E[1;10A, + kUP5=\E[1;5A, kUP6=\E[1;6A, use=ecma+italics, use=iterm, # xnuppc - Darwin PowerPC Console (a.k.a. "darwin") # @@ -3970,7 +3972,7 @@ putty+fnkeys+sco|SCO fn-keys for PuTTY, # "resize -s"), though it does not pass SIGWINCH to the application if the # user resizes the window with the mouse. teraterm2.3|Tera Term Pro, - km, xon@, + km, ncv#43, vt@, acsc=+\020\,\021-\030.^Y0\333`\004a\261f\370g\361h\260i \316j\331k\277l\332m\300n\305o~p\304q\304r\304s_t\303u @@ -3979,7 +3981,7 @@ teraterm2.3|Tera Term Pro, cnorm=\E[?25h, cuf1=\E[C, cup=\E[%i%p1%d;%p2%dH, cuu1=\E[A, dch=\E[%p1%dP, dch1=\E[P, dl=\E[%p1%dM, dl1=\E[M, ech=\E[%p1%dX, ed=\E[J, el=\E[K, el1=\E[1K, - flash=\E[?5h\E[?5l$<200/>, hpa=\E[%i%p1%dG, + flash=\E[?5h$<200/>\E[?5l, hpa=\E[%i%p1%dG, il=\E[%p1%dL, il1=\E[L, kdch1=\E[3~, kf1=\E[11~, kf10=\E[21~, kf11=\E[23~, kf12=\E[24~, kf13=\E[25~, kf14=\E[26~, kf15=\E[28~, kf16=\E[29~, kf17=\E[31~, @@ -5685,7 +5687,7 @@ xiterm|internationalized terminal emulator for X, # from BSD termcap. (hpterm: added empty , we have no idea what ACS # chars look like --esr) hpterm|X-hpterm|hp X11 terminal emulator, - am, da, db, mir, xhp, + am, da, db, mir, xhp, xon, cols#80, lh#2, lines#24, lm#0, lw#8, nlab#8, pb#9600, xmc#0, acsc=, bel=^G, bold=\E&dB, cbt=\Ei, clear=\E&a0y0C\EJ, cr=\r, cub1=^H, cud1=\EB, cuf1=\EC, cup=\E&a%p1%dy%p2%dC, @@ -5704,8 +5706,9 @@ hpterm|X-hpterm|hp X11 terminal emulator, rmul=\E&d@, sgr=\E&d%?%p7%t%{115}%c%;%p1%p3%|%p6%|%{2}%*%p2%{4}%*%+%p4%+ %p5%{8}%*%+%{64}%+%c%?%p9%t%'\016'%c%e%'\017'%c%;, - sgr0=\E&d@, smacs=^N, smir=\EQ, smkx=\E&s1A, smln=\E&jB, - smso=\E&dJ, smul=\E&dD, tbc=\E3, vpa=\E&a%p1%dY, + sgr0=\E&d@\017, smacs=^N, smir=\EQ, smkx=\E&s1A, + smln=\E&jB, smso=\E&dJ, smul=\E&dD, tbc=\E3, + vpa=\E&a%p1%dY, # HPUX 11 provides a color version. hpterm-color|HP X11 terminal emulator with color, ccc, @@ -5777,7 +5780,7 @@ emu-220|Emu-220 (vt200-7bit mode), rs2=\E[4l\E[34l\E[?1l\E[?3l\E[?5l\E[?7h, sc=\E7, sgr=\E[0%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p5%t; 2%;%?%p6%t;1%;%?%p7%t;8%;m%?%p9%t\016%e\017%;, - sgr0=\E[m, smacs=^N, smcup=\E[?1l\E=, smkx=\E=, + sgr0=\E[m\017, smacs=^N, smcup=\E[?1l\E=, smkx=\E=, smso=\E[0;7m, smul=\E[0;4m, tbc=\E[3g, #### MVTERM @@ -5792,7 +5795,7 @@ emu-220|Emu-220 (vt200-7bit mode), # apparently implements alternate screen like xterm # does not use padding, of course. mvterm|vv100|SwitchTerm aka mvTERM, - am, eslok, hs, km, mir, msgr, xenl, + am, eslok, hs, km, mir, msgr, xenl, xon, colors#8, cols#80, it#8, lines#24, pairs#64, acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~, bel=^G, blink=\E[5m, bold=\E[1m, clear=\E[H\E[2J, cr=\r, @@ -5837,8 +5840,8 @@ mterm-ansi|ANSI emulation, rmul=\E[24m, sgr=\E[0%?%p6%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%? %p5%t;2%;%?%p7%t;8%;m%?%p9%t\016%e\017%;, - sgr0=\E[m, smacs=^N, smir=\E[4h, smso=\E[7m, smul=\E[4m, - vpa=\E[%i%p1%dd, + sgr0=\E[m\017, smacs=^N, smir=\E[4h, smso=\E[7m, + smul=\E[4m, vpa=\E[%i%p1%dd, # mterm normally sets $TERM to "mterm" mterm|mouse-sun|Der Mouse term, am, bw, mir, @@ -5876,7 +5879,7 @@ decansi|ANSI emulation with DEC compatibility hacks, setab=\E[4%p1%dm, setaf=\E[3%p1%dm, sgr=\E[0%?%p6%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%? %p5%t;2%;%?%p7%t;8%;m%?%p9%t\016%e\017%;, - sgr0=\E[m, smacs=^N, smam=\E[?7h, smir=\E[4h, + sgr0=\E[m\017, smacs=^N, smam=\E[?7h, smir=\E[4h, smkx=\E[?1h\E=, smso=\E[7m, smul=\E[4m, u6=\E[%i%d;%dR, u7=\E[6n, vpa=\E[%i%p1%dd, @@ -5903,8 +5906,8 @@ vwmterm|(vwm term), khome=\E[1~, knp=\E[6~, kpp=\E[5~, rev=\E[7m, rmacs=\E[10m, rmam=\E[?7l, rmcup=\E[?1049l, rs1=\E[H\E[J\E[m\Ec, setab=\E[4%p1%dm, setaf=\E[3%p1%dm, - sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6 - %t;1%;%?%p7%t;8%;%?%p9%t;11%;m, + sgr=\E[0;10%?%p1%t;3%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p5 + %t;2%;%?%p6%t;1%;%?%p7%t;8%;%?%p9%t;11%;m, sgr0=\E[0;10m, smacs=\E[11m, smam=\E[?7h, smcup=\E[?1049h, smso=\E[3m, smul=\E[4m, @@ -5916,7 +5919,7 @@ vwmterm|(vwm term), # mgr|Bellcore MGR (non X) window system terminal emulation, - am, km, + am, km, xon, bel=^G, bold=\E2n, civis=\E9h, clear=^L, cnorm=\Eh, cr=\r, csr=\E%p1%d;%p2%dt, cub1=^H, cud1=\Ef, cuf1=\Er, cup=\E%p2%d;%p1%dM, cuu1=\Eu, cvvis=\E0h, @@ -5963,6 +5966,8 @@ st-0.7|simpleterm 0.7, %=%t3%e%p1%d%;m, setf=\E[3%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6} %=%t3%e%p1%d%;m, + sgr=%?%p9%t\E(0%e\E(B%;\E[0%?%p6%t;1%;%?%p2%t;4%;%?%p1%p3%| + %t;7%;%?%p4%t;5%;%?%p5%t;2%;%?%p7%t;8%;m, Ss=\E]52;%p1%s;%p2%s\007, kDN3=\E[1;3B, kDN5=\E[1;5B, kLFT3=\E[1;3D, kLFT5=\E[1;5D, kNXT3=\E[6;3~, kNXT5=\E[6;5~, kPRV3=\E[5;3~, kPRV5=\E[5;5~, @@ -6224,7 +6229,7 @@ terminator|Terminator no line wrap, # does not handle combinations of modifiers - but listing them all would # involve more effort than its developers spent -TD terminology-0.6.1|EFL-based terminal emulator, - mc5i@, xon@, + mc5i@, blink@, ed@, el@, el1@, invis=\E[8m, kLFT=\E[1;2D, kRIT=\E[1;2C, kf10=\E[21~, kf11=\E[23~, kf12=\E[24~, kf5=\E[15~, kf6=\E[17~, kf7=\E[18~, kf8=\E[19~, kf9=\E[20~, @@ -6660,9 +6665,13 @@ screen3|older VT 100/ANSI X3.64 virtual terminal, # tmux is compatible with screen, but has support for italics, and some of the # xterm cursor bits. tmux|tmux terminal multiplexer, - rmso=\E[27m, smso=\E[7m, use=ecma+italics, - use=ecma+strikeout, use=xterm+edit, use=xterm+pcfkeys, - use=xterm+sl, use=xterm+tmux, use=screen, + rmso=\E[27m, + sgr=\E[0%?%p6%t;1%;%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t; + \s\s\s\s\s\s\s\s\s\s\s\s5%;%?%p5%t;2%;m%?%p9%t\016%e + \017%;, + smso=\E[7m, use=ecma+italics, use=ecma+strikeout, + use=xterm+edit, use=xterm+pcfkeys, use=xterm+sl, + use=xterm+tmux, use=screen, tmux-256color|tmux with 256 colors, use=xterm+256setaf, use=tmux, @@ -8420,8 +8429,8 @@ hp2|hpex2|hewlett-packard extended capabilities newer version, rmln=\E&j@, rmso=\E&d@, rmul=\E&d@, sgr=\E&d%?%p7%t%{115}%c%;%p1%p3%|%p6%|%{2}%*%p2%{4}%*%+%p4%+ %p5%{8}%*%+%{64}%+%c%?%p9%t%'\016'%c%e%'\017'%c%;, - sgr0=\E&d@, smir=\EQ, smkx=\E&s1A, smln=\E&jB, smso=\E&dB, - smul=\E&dD, tbc=\E3, vpa=\E&a%p1%dY, + sgr0=\E&d@\017, smir=\EQ, smkx=\E&s1A, smln=\E&jB, + smso=\E&dB, smul=\E&dD, tbc=\E3, vpa=\E&a%p1%dY, # HP 236 console # From: @@ -10318,8 +10327,8 @@ vi603|visual603|visual 603, dsl=\EP2;1~\E\\, ed=\E[J, el=\E[K, fsl=\E\\, il1=\E[L, ind=\ED, is1=\E>\E[?3l\E[?4l\E[?7h\E[?8h\E[1;24r, rev=\E[7m, ri=\EM, rmir=\E[4l, rmso=\E[27m, rmul=\E[24m, - sgr0=\E[m, smir=\E[4h, smso=\E[7m, smul=\E[4m, tsl=\EP2~, - use=vt100+4bsd, + sgr0=\E[m\017$<2>, smir=\E[4h, smso=\E[7m, smul=\E[4m, + tsl=\EP2~, use=vt100+4bsd, #### Wyse (wy) # @@ -12182,7 +12191,7 @@ att5420_2|AT&T 5420 model 2 80 cols, rmln=\E|, rmso=\E[m, rmul=\E[m, rs2=\Ec\E[?3l\E[2;0y, sc=\E7, sgr=\E[0%?%p1%p5%|%t;2%;%?%p2%p6%|%t;4%;%?%p4%t;5%;%?%p3%p1 - %|%p6%|%t;7%;%?%p7%t;8%;m%?%p9%t\016%e\017%;, + %|%p6%|%t;7%;%?%p7%t;8%;m%?%p9%t\016%e\017%;%?%p8%t\EV%;, sgr0=\E[m\017, smacs=^N, smkx=\E[19;1j, smln=\E~, smso=\E[7m, smul=\E[4m, tbc=\E[3g, tsl=\E7\E[25;%p1%{8}%+%dH, vpa=\E[%p1%{1}%+%dd, @@ -12257,8 +12266,8 @@ att4424|tty4424|teletype 4424, kcuu1=\E[A, kf1=\EOP, kf2=\EOQ, kf3=\EOR, kf4=\EOS, khome=\E[H, nel=\EE, rev=\E}, ri=\ET, rmacs=\E(B, rmso=\E~, rmul=\EZ, - sgr=\E[%?%p1%t7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p6%p4%| - %t;5%;%?%p5%t;0%;m, + sgr=\EX\E~\EZ\E4\E(B%?%p1%p3%|%t\E}%;%?%p2%t\E\\%;%?%p4%p6%| + %t\E3%;%?%p5%t\EW%;%?%p9%t\E(0%;, sgr0=\EX\E~\EZ\E4\E(B, smacs=\E(0, smso=\E}, smul=\E\\, tbc=\EF, @@ -12479,7 +12488,7 @@ att500|att513|AT&T 513 using page mode, rs1=\E?\E[3;3|\E[10;0|\E[21;1|\212\E[6;1|\E[1{\E[?99l\E[2;0| \E[6;1|\E[8;0|\E[19;0|\E[1{\E[?99l, rs2=\E[5;0|, sc=\E7, - sgr=\E[0%?%p1%p5%|%t;2%;%?%p2%p6%|%t;4%;%?%p4%t;5%;%?%p3%p1 + sgr=\E[0%?%p1%p5%|%p6%|%t;2%;%?%p2%t;4%;%?%p4%t;5%;%?%p3%p1 %|%p6%|%t;7%;%?%p7%t;8%;m%?%p9%t\016%e\017%;, sgr0=\E[m\017, smacs=^N, smir=\E[4h, smkx=\E[19;1|\E[21;4|\Eent, smln=\E?, smso=\E[7m, @@ -15180,8 +15189,8 @@ d410-7b|d411-7b|d460-7b|d461-7b|Data General DASHER D410/D460 series in 7 bit mo km@, enacs=\E)6, is2=\E[3;2;2;0;1;0v\E(0\017, rmacs=^O, rs2=\E[4;0;2;0;1;0v\E(0, - sgr=\E[%?%p1%p3%|%p6%|%t7;%;%?%p4%t5;%;%?%p2%p6%|%t4;%;%?%p1 - %p5%|%t2;%;m%?%p9%t\016%e\017%;, + sgr=\E[%?%p1%p5%|%t2;%;%?%p2%p6%|%t4;%;%?%p1%p3%|%p6%|%t7;%; + %?%p4%t5;%;m%?%p9%t\016%e\017%;, sgr0=\E[m\017, smacs=^N, use=dgkeys+7b, use=d410, d410-dg|d460-dg|d411-dg|d461-dg|Data General DASHER D410/D460 series in DG mode, @@ -15512,8 +15521,8 @@ dm80|dmdt80|dt80|datamedia dt80/1, clear=\E[2J\E[H, cud1=\n, cuf1=\E[C, cup=%i\E[%p1%d;%p2%dH, cuu1=\E[A, ed=\E[J, el=\E[K, home=\E[H, mc0=\E[0i, mc4=\E[4i, mc5=\E[5i, ri=\EM, - rmso=\E[m, rmul=\E[m, sgr0=\E[m, smso=\E[7m, smul=\E[4m, - use=vt100+4bsd, + rmso=\E[m, rmul=\E[m, sgr0=\E[m\017$<2>, smso=\E[7m, + smul=\E[4m, use=vt100+4bsd, # except in 132 column mode, where it needs a little padding. # This is still less padding than the vt100, and you can always turn on # the ^S/^Q handshaking, so you can use vt100 flavors for things like @@ -16428,31 +16437,40 @@ ibm8514-c|IBM 8514 color display with standout and underline, # # AIX entries. IBM ships these with AIX 3.2.5. # -- added rc, sc based on manpage -TD +# -- added rmacs, smacs based on manpage -TD # Note that we could use ibm+16color, but that is not how IBM defines this one. aixterm|IBM Aixterm Terminal Emulator, eslok, hs, acsc=jjkkllmmnnqqttuuvvwwxx, bold=\E[1m, dsl=\E[?E, - fsl=\E[?F, rc=\E8, ri@, s0ds=\E(B, s1ds=\E(0, sc=\E7, - sgr=\E[%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1 - %;%?%p7%t;8%;m%?%p9%t\E(0%e\E(B%;, - sgr0=\E[0;10m\E(B, tsl=\E[?%p1%dT, use=ibm6154, + fsl=\E[?F, rc=\E8, ri@, rmacs=\E(B, s0ds=\E(B, s1ds=\E(0, + sc=\E7, + sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p7 + %t;8%;m%?%p9%t\E(0%e\E(B%;, + sgr0=\E[0;10m\E(B, smacs=\E(0, tsl=\E[?%p1%dT, + use=ibm6154, aixterm-m|IBM AIXterm Monochrome Terminal Emulator, eslok, hs, acsc=jjkkllmmnnqqttuuvvwwxx, bold=\E[1m, dsl=\E[?E, fsl=\E[?F, ri@, s0ds=\E(B, s1ds=\E(0, - sgr=\E[%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1 - %;m, + sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p7 + %t;8%;m%?%p9%t\E(0%e\E(B%;, sgr0=\E[0;10m\E(B, tsl=\E[?%p1%dT, use=ibm6153, aixterm-m-old|old IBM AIXterm Monochrome Terminal Emulator, eslok, hs, bold=\E[1m, dsl=\E[?E, fsl=\E[?F, ri@, - sgr=\E[%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1 - %;m, + sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p7 + %t;8%;m, tsl=\E[?%p1%dT, use=ibm6153, jaixterm|IBM Kanji Aixterm Terminal Eemulator, - acsc@, use=aixterm, + acsc@, rmacs@, + sgr=\E[%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p7%t;8 + %;m, + sgr0=\E[m, smacs@, use=aixterm, jaixterm-m|IBM Kanji AIXterm Monochrome Terminal Emulator, - acsc@, use=aixterm-m, + acsc@, rmacs@, + sgr=\E[%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p6%t;1%;%?%p7%t;8 + %;m, + sgr0=\E[m, smacs@, use=aixterm-m, # This flavor is adapted from xterm, in turn from aixterm documentation -TD aixterm-16color|IBM Aixterm Terminal Emulator with 16 colors, @@ -17911,8 +17929,8 @@ ncrvt100an|ncrvt100pp|NCR vt100 for the 2900 terminal, rs2=\Ec\E[12;31h\E[?3;4;5;10l\E[?6;7;19;25h\E[33;34l\E[0m\E( B\E)0\E%/0n\E[P\031$<200>, sc=\E7, - sgr=\E[0%?%p1%p6%|%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5 - %;m%?%p9%t\016%e\017%;$<100>, + sgr=%?%p9%t\016%e\017%;\E[0%?%p1%p6%|%t;1%;%?%p2%t;4%;%?%p1 + %p3%|%t;7%;%?%p4%t;5%;m$<100>, sgr0=\017\E[0m$<120>, smacs=\016$<90>, smir=\E[4h$<80>, smso=\E[7m$<30>, smul=\E[4m$<30>, tbc=\E[3g$<40>, tsl=\E[>+1$<70>, @@ -25307,4 +25325,16 @@ v3220|LANPAR Vision II model 3220/3221/3222, # + reviewed terminology 1.0.0 -TD # + reviewed st 0.7 -TD # +# 2017-11-18 +# + modify old terminology entry and a few other terminal emulators to +# account for xon -TD +# + correct sgr string for tmux, which used screen's "standout" code +# rather than the standard code (patch by Roman Kagan) +# + correct sgr/sgr0 strings in a few other cases reported by tic, making +# those correspond to the non-sgr settings where they differ, but +# otherwise use ECMA-48 consistently: +# jaixterm, aixterm, att5420_2, att4424, att500, decansi, d410-7b, +# dm80, hpterm, emu-220, hp2, iTerm2.app, mterm-ansi, ncrvt100an, +# st-0.7, vi603, vwmterm -TD +# ######## SHANTIH! SHANTIH! SHANTIH! diff --git a/ncurses/base/lib_mouse.c b/ncurses/base/lib_mouse.c index 61ec3c8b7..8a0e4c1f3 100644 --- a/ncurses/base/lib_mouse.c +++ b/ncurses/base/lib_mouse.c @@ -84,7 +84,7 @@ #define CUR SP_TERMTYPE #endif -MODULE_ID("$Id: lib_mouse.c,v 1.175 2017/06/17 22:05:15 tom Exp $") +MODULE_ID("$Id: lib_mouse.c,v 1.176 2017/11/18 22:12:06 Vassili.Courzakis Exp $") #include @@ -486,15 +486,17 @@ load_gpm_library(SCREEN *sp) { sp->_mouse_gpm_found = FALSE; if ((sp->_dlopen_gpm = dlopen(LIBGPM_SONAME, my_RTLD)) != 0) { -#pragma GCC diagnostic push #if (defined(__GNUC__) && (__GNUC__ >= 5)) || defined(__clang__) +#pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wpedantic" #endif if (GET_DLSYM(gpm_fd) == 0 || GET_DLSYM(Gpm_Open) == 0 || GET_DLSYM(Gpm_Close) == 0 || GET_DLSYM(Gpm_GetEvent) == 0) { +#if (defined(__GNUC__) && (__GNUC__ >= 5)) || defined(__clang__) #pragma GCC diagnostic pop +#endif T(("GPM initialization failed: %s", dlerror())); unload_gpm_library(sp); } else { diff --git a/package/debian-mingw/changelog b/package/debian-mingw/changelog index 12d032337..7f1788f69 100644 --- a/package/debian-mingw/changelog +++ b/package/debian-mingw/changelog @@ -1,8 +1,8 @@ -ncurses6 (6.0+20171111) unstable; urgency=low +ncurses6 (6.0+20171118) unstable; urgency=low * latest weekly patch - -- Thomas E. Dickey Sun, 05 Nov 2017 06:30:20 -0500 + -- Thomas E. Dickey Sun, 12 Nov 2017 10:22:04 -0500 ncurses6 (5.9-20131005) unstable; urgency=low diff --git a/package/debian-mingw64/changelog b/package/debian-mingw64/changelog index 12d032337..7f1788f69 100644 --- a/package/debian-mingw64/changelog +++ b/package/debian-mingw64/changelog @@ -1,8 +1,8 @@ -ncurses6 (6.0+20171111) unstable; urgency=low +ncurses6 (6.0+20171118) unstable; urgency=low * latest weekly patch - -- Thomas E. Dickey Sun, 05 Nov 2017 06:30:20 -0500 + -- Thomas E. Dickey Sun, 12 Nov 2017 10:22:04 -0500 ncurses6 (5.9-20131005) unstable; urgency=low diff --git a/package/debian/changelog b/package/debian/changelog index 5c97579d4..618ac697f 100644 --- a/package/debian/changelog +++ b/package/debian/changelog @@ -1,8 +1,8 @@ -ncurses6 (6.0+20171111) unstable; urgency=low +ncurses6 (6.0+20171118) unstable; urgency=low * latest weekly patch - -- Thomas E. Dickey Sun, 05 Nov 2017 06:30:20 -0500 + -- Thomas E. Dickey Sun, 12 Nov 2017 10:22:04 -0500 ncurses6 (5.9-20120608) unstable; urgency=low diff --git a/package/mingw-ncurses.nsi b/package/mingw-ncurses.nsi index 5814aabe6..a80963a5e 100644 --- a/package/mingw-ncurses.nsi +++ b/package/mingw-ncurses.nsi @@ -1,4 +1,4 @@ -; $Id: mingw-ncurses.nsi,v 1.239 2017/11/05 11:30:20 tom Exp $ +; $Id: mingw-ncurses.nsi,v 1.240 2017/11/12 15:22:04 tom Exp $ ; TODO add examples ; TODO bump ABI to 6 @@ -10,7 +10,7 @@ !define VERSION_MAJOR "6" !define VERSION_MINOR "0" !define VERSION_YYYY "2017" -!define VERSION_MMDD "1111" +!define VERSION_MMDD "1118" !define VERSION_PATCH ${VERSION_YYYY}${VERSION_MMDD} !define MY_ABI "5" diff --git a/package/mingw-ncurses.spec b/package/mingw-ncurses.spec index 3db1ce765..89436cf54 100644 --- a/package/mingw-ncurses.spec +++ b/package/mingw-ncurses.spec @@ -3,7 +3,7 @@ Summary: shared libraries for terminal handling Name: mingw32-ncurses6 Version: 6.0 -Release: 20171111 +Release: 20171118 License: X11 Group: Development/Libraries Source: ncurses-%{version}-%{release}.tgz diff --git a/package/ncurses.spec b/package/ncurses.spec index 8117b1670..5800b562a 100644 --- a/package/ncurses.spec +++ b/package/ncurses.spec @@ -1,7 +1,7 @@ Summary: shared libraries for terminal handling Name: ncurses6 Version: 6.0 -Release: 20171111 +Release: 20171118 License: X11 Group: Development/Libraries Source: ncurses-%{version}-%{release}.tgz diff --git a/test/picsmap.c b/test/picsmap.c index 47a9388bd..be8903ab3 100644 --- a/test/picsmap.c +++ b/test/picsmap.c @@ -26,7 +26,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: picsmap.c,v 1.103 2017/09/06 09:21:38 tom Exp $ + * $Id: picsmap.c,v 1.108 2017/11/19 02:56:12 tom Exp $ * * Author: Thomas E. Dickey * @@ -78,38 +78,7 @@ #define RGB_PATH "/etc/X11/rgb.txt" -typedef int NUM_COLOR; -typedef unsigned short NUM_COUNT; - -typedef struct { - char ch; /* nominal character to display */ - NUM_COLOR fg; /* foreground color */ -} PICS_CELL; - -typedef struct { - NUM_COLOR fgcol; - NUM_COUNT count; -} FG_NODE; - -typedef struct { - char *name; - short high; - short wide; - int colors; - FG_NODE *fgcol; - PICS_CELL *cells; -} PICS_HEAD; - -typedef struct { - const char *name; - int value; -} RGB_NAME; - -typedef struct { - short red; - short green; - short blue; -} RGB_DATA; +#include typedef struct { size_t file; @@ -528,7 +497,10 @@ usage(void) ,"Read/display one or more xbm/xpm files (possibly use \"convert\")" ,"" ,"Options:" - ," -d add debugging information to logfile" +#if HAVE_USE_DEFAULT_COLORS + ," -d invoke use_default_colors" +#endif + ," -L add debugging information to logfile" ," -l logfile write informational messages to logfile" ," -p palette color-palette file (default \"$TERM.dat\")" ," -q less verbose" @@ -653,17 +625,19 @@ init_palette(const char *palette_file) { if (palette_file != 0) { char **data = read_palette(palette_file); - int cp; all_colors = typeMalloc(RGB_DATA, (unsigned) COLORS); how_much.data += (sizeof(RGB_DATA) * (unsigned) COLORS); #if HAVE_COLOR_CONTENT - for (cp = 0; cp < COLORS; ++cp) { - color_content((short) cp, - &all_colors[cp].red, - &all_colors[cp].green, - &all_colors[cp].blue); + { + int cp; + for (cp = 0; cp < COLORS; ++cp) { + color_content((short) cp, + &all_colors[cp].red, + &all_colors[cp].green, + &all_colors[cp].blue); + } } #else memset(all_colors, 0, sizeof(RGB_DATA) * (size_t) COLORS); @@ -1463,6 +1437,29 @@ dump_picture(PICS_HEAD * pics) } } +#ifndef USE_DISPLAY_DRIVER +static void +init_display(const char *palette_path, int opt_d) +{ + if (isatty(fileno(stdout))) { + in_curses = TRUE; + initscr(); + cbreak(); + noecho(); + curs_set(0); + if (has_colors()) { + start_color(); +#if HAVE_USE_DEFAULT_COLORS + if (opt_d) + use_default_colors(); +#endif + init_palette(palette_path); + } + scrollok(stdscr, FALSE); + exit_curses(); + } +} + static void show_picture(PICS_HEAD * pics) { @@ -1537,6 +1534,7 @@ show_picture(PICS_HEAD * pics) if (!quiet) endwin(); } +#endif static int compare_fg_counts(const void *a, const void *b) @@ -1635,12 +1633,18 @@ int main(int argc, char *argv[]) { int n; + int opt_d = FALSE; const char *palette_path = 0; const char *rgb_path = "/etc/X11/rgb.txt"; - while ((n = getopt(argc, argv, "dl:p:qr:s:x:")) != -1) { + while ((n = getopt(argc, argv, "dLl:p:qr:s:x:")) != -1) { switch (n) { +#if HAVE_USE_DEFAULT_COLORS case 'd': + opt_d = TRUE; + break; +#endif + case 'L': debugging = TRUE; break; case 'l': @@ -1691,19 +1695,7 @@ main(int argc, char *argv[]) if (rgb_data) rgb_table = parse_rgb(rgb_data); - if (isatty(fileno(stdout))) { - in_curses = TRUE; - initscr(); - cbreak(); - noecho(); - curs_set(0); - if (has_colors()) { - start_color(); - init_palette(palette_path); - } - scrollok(stdscr, FALSE); - exit_curses(); - } + init_display(palette_path, opt_d); if (optind >= argc) giveup("expected at least one image filename"); diff --git a/test/picsmap.h b/test/picsmap.h new file mode 100644 index 000000000..511ae7aa9 --- /dev/null +++ b/test/picsmap.h @@ -0,0 +1,74 @@ +/**************************************************************************** + * Copyright (c) 2017 Free Software Foundation, Inc. * + * * + * Permission is hereby granted, free of charge, to any person obtaining a * + * copy of this software and associated documentation files (the * + * "Software"), to deal in the Software without restriction, including * + * without limitation the rights to use, copy, modify, merge, publish, * + * distribute, distribute with modifications, sublicense, and/or sell * + * copies of the Software, and to permit persons to whom the Software is * + * furnished to do so, subject to the following conditions: * + * * + * The above copyright notice and this permission notice shall be included * + * in all copies or substantial portions of the Software. * + * * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * + * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * + * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * + * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * + * THE USE OR OTHER DEALINGS IN THE SOFTWARE. * + * * + * Except as contained in this notice, the name(s) of the above copyright * + * holders shall not be used in advertising or otherwise to promote the * + * sale, use or other dealings in this Software without prior written * + * authorization. * + ****************************************************************************/ + +/**************************************************************************** + * Author: Thomas E. Dickey * + ****************************************************************************/ +/* $Id: picsmap.h,v 1.3 2017/11/18 22:37:00 tom Exp $ */ + +#ifndef PICSMAP_H_INCL +#define PICSMAP_H_INCL 1 + +typedef int NUM_COLOR; +typedef unsigned short NUM_COUNT; + +typedef struct { + char ch; /* nominal character to display */ + NUM_COLOR fg; /* foreground color */ +} PICS_CELL; + +typedef struct { + NUM_COLOR fgcol; + NUM_COUNT count; +} FG_NODE; + +typedef struct { + char *name; + short high; + short wide; + int colors; + FG_NODE *fgcol; + PICS_CELL *cells; +} PICS_HEAD; + +typedef struct { + const char *name; + int value; +} RGB_NAME; + +typedef struct { + short red; + short green; + short blue; +} RGB_DATA; + +static void init_display(const char *, int); + +static void show_picture(PICS_HEAD * pics); + +#endif /* PICSMAP_H_INCL */ diff --git a/test/worm.c b/test/worm.c index 70c92a216..2e31638d3 100644 --- a/test/worm.c +++ b/test/worm.c @@ -52,7 +52,7 @@ traces will be dumped. The program stops and waits for one character of input at the beginning and end of the interval. - $Id: worm.c,v 1.75 2017/09/08 20:00:50 tom Exp $ + $Id: worm.c,v 1.76 2017/11/18 22:41:08 tom Exp $ */ #include @@ -97,6 +97,7 @@ static unsigned long sequence = 0; static bool quitting = FALSE; static WORM worm[MAX_WORMS]; +static int max_refs; static int **refs; static int last_x, last_y; @@ -290,6 +291,7 @@ draw_worm(WINDOW *win, void *data) switch (op->nopts) { case 0: done = TRUE; + Trace(("done - draw_worm")); break; case 1: w->orientation = op->opts[0]; @@ -404,6 +406,7 @@ update_refs(WINDOW *win) if (last_y != LINES - 1) { for (y = LINES; y <= last_y; y++) free(refs[y]); + max_refs = LINES; refs = typeRealloc(int *, (size_t) LINES, refs); for (y = last_y + 1; y < LINES; y++) { refs[y] = typeMalloc(int, (size_t) COLS); @@ -455,7 +458,6 @@ main(int argc, char *argv[]) struct worm *w; int *ip; bool done = FALSE; - int max_refs; #if HAVE_USE_DEFAULT_COLORS bool opt_d = FALSE; #endif @@ -616,6 +618,7 @@ main(int argc, char *argv[]) if (ch == 'q') { quitting = TRUE; done = TRUE; + Trace(("done - quitting")); continue; } else if (ch == 's') { nodelay(stdscr, FALSE);