Vendor import ncurses 6.2-20210220
This commit is contained in:
parent
72c3fc31f5
commit
bf0ab54638
@ -1,6 +1,6 @@
|
||||
# $Id: Makefile.in,v 1.23 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.26 2021/01/23 20:34:50 tom Exp $
|
||||
##############################################################################
|
||||
# Copyright 2020 Thomas E. Dickey #
|
||||
# Copyright 2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1998-2010,2015 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -31,7 +31,7 @@
|
||||
# Author: Juergen Pfeifer, 1996
|
||||
#
|
||||
# Version Control
|
||||
# $Revision: 1.23 $
|
||||
# $Revision: 1.26 $
|
||||
#
|
||||
SHELL = @SHELL@
|
||||
VPATH = @srcdir@
|
||||
@ -39,7 +39,7 @@ THIS = Makefile
|
||||
|
||||
SUBDIRS = @ADA_SUBDIRS@
|
||||
|
||||
CF_MFLAGS = @cf_cv_makeflags@
|
||||
TOP_MFLAGS = @cf_cv_makeflags@ DESTDIR="$(DESTDIR)" RPATH_LIST="$(RPATH_LIST)"
|
||||
@SET_MAKE@
|
||||
|
||||
all \
|
||||
@ -50,19 +50,19 @@ install.libs \
|
||||
uninstall \
|
||||
uninstall.libs ::
|
||||
for d in $(SUBDIRS); do \
|
||||
(cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\
|
||||
( cd $$d && $(MAKE) $(TOP_MFLAGS) $@ ) ;\
|
||||
done
|
||||
|
||||
clean \
|
||||
mostlyclean ::
|
||||
for d in $(SUBDIRS); do \
|
||||
(cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\
|
||||
( cd $$d && $(MAKE) $(TOP_MFLAGS) $@ ) ;\
|
||||
done
|
||||
|
||||
distclean \
|
||||
realclean ::
|
||||
for d in $(SUBDIRS); do \
|
||||
(cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\
|
||||
( cd $$d && $(MAKE) $(TOP_MFLAGS) $@ ) ;\
|
||||
done
|
||||
rm -rf lib
|
||||
for lib_kind in static dynamic; do \
|
||||
|
858
Ada95/aclocal.m4
vendored
858
Ada95/aclocal.m4
vendored
File diff suppressed because it is too large
Load Diff
8497
Ada95/configure
vendored
8497
Ada95/configure
vendored
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,5 @@
|
||||
dnl***************************************************************************
|
||||
dnl Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
dnl Copyright 2018-2020,2021 Thomas E. Dickey *
|
||||
dnl Copyright 2010-2016,2018 Free Software Foundation, Inc. *
|
||||
dnl *
|
||||
dnl Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -29,7 +29,7 @@ dnl***************************************************************************
|
||||
dnl
|
||||
dnl Author: Thomas E. Dickey
|
||||
dnl
|
||||
dnl $Id: configure.in,v 1.76 2020/02/08 21:03:20 tom Exp $
|
||||
dnl $Id: configure.in,v 1.82 2021/01/09 11:20:33 tom Exp $
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
dnl
|
||||
dnl For additional information, see
|
||||
@ -38,7 +38,7 @@ dnl https://invisible-island.net/autoconf/my-autoconf.html
|
||||
dnl
|
||||
dnl ---------------------------------------------------------------------------
|
||||
AC_PREREQ(2.52.20200111)
|
||||
AC_REVISION($Revision: 1.76 $)
|
||||
AC_REVISION($Revision: 1.82 $)
|
||||
AC_INIT(gen/gen.c)
|
||||
AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
|
||||
|
||||
@ -353,18 +353,10 @@ CF_HELP_MESSAGE(Testing/development Options:)
|
||||
### use option --disable-echo to suppress full display compiling commands
|
||||
CF_DISABLE_ECHO
|
||||
|
||||
### use option --enable-warnings to turn on all gcc warnings
|
||||
AC_MSG_CHECKING(if you want to see compiler warnings)
|
||||
AC_ARG_ENABLE(warnings,
|
||||
[ --enable-warnings build: turn on GCC compiler warnings],
|
||||
[with_warnings=$enableval])
|
||||
AC_MSG_RESULT($with_warnings)
|
||||
|
||||
if test "x$with_warnings" = "xyes"; then
|
||||
CF_ENABLE_WARNINGS(Wno-unknown-pragmas Wswitch-enum,yes)
|
||||
if test "x$enable_warnings" = "xyes"; then
|
||||
CF_ADD_ADAFLAGS(-gnatg)
|
||||
CF_GCC_WARNINGS(Wno-unknown-pragmas Wswitch-enum)
|
||||
fi
|
||||
CF_GCC_ATTRIBUTES
|
||||
|
||||
### use option --enable-assertions to turn on generation of assertion code
|
||||
AC_MSG_CHECKING(if you want to enable runtime assertions)
|
||||
@ -549,9 +541,6 @@ SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
|
||||
|
||||
AC_DEFINE_UNQUOTED(NCURSES_PATHSEP,'$PATH_SEPARATOR',[Define to override ':' as the library path-separator])
|
||||
|
||||
### Now that we're done running tests, add the compiler-warnings, if any
|
||||
CF_ADD_CFLAGS($EXTRA_CFLAGS)
|
||||
|
||||
################################################################################
|
||||
|
||||
TEST_ARG2=
|
||||
@ -615,6 +604,8 @@ NCURSES_MAJOR="$NCURSES_MAJOR"
|
||||
NCURSES_MINOR="$NCURSES_MINOR"
|
||||
NCURSES_PATCH="$NCURSES_PATCH"
|
||||
USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
|
||||
cf_cv_VERSION_GNATMAKE=$cf_cv_VERSION_GNATMAKE
|
||||
cf_cv_VERSION_GPRBUILD=$cf_cv_VERSION_GPRBUILD
|
||||
cf_cv_abi_version="$cf_cv_abi_version"
|
||||
cf_cv_rel_version="$cf_cv_rel_version"
|
||||
cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
|
||||
|
@ -1,6 +1,6 @@
|
||||
# $Id: Makefile.in,v 1.7 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.8 2021/01/23 20:42:08 tom Exp $
|
||||
##############################################################################
|
||||
# Copyright 2019,2020 Thomas E. Dickey #
|
||||
# Copyright 2019-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 2011-2015,2018 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -69,7 +69,7 @@ uninstall uninstall.man :
|
||||
|
||||
# HTML documentation is optional, usually in a separate package.
|
||||
install.html : $(DOCDIR)
|
||||
cd $(srcdir) && tar -cf - *.htm* ada | tar -C $(DOCDIR) -xf -
|
||||
( cd $(srcdir) && tar -cf - *.htm* ada | tar -C $(DOCDIR) -xf - )
|
||||
|
||||
uninstall.html :
|
||||
-rm -rf $(DOCDIR)
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright 2019,2020 Thomas E. Dickey #
|
||||
# Copyright 2019-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1998-2015,2018 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -28,8 +28,9 @@
|
||||
##############################################################################
|
||||
#
|
||||
# Author: Juergen Pfeifer, 1996
|
||||
# and: Thomas E. Dickey, 1997
|
||||
#
|
||||
# $Id: Makefile.in,v 1.90 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.96 2021/01/23 20:42:08 tom Exp $
|
||||
#
|
||||
.SUFFIXES:
|
||||
|
||||
@ -57,7 +58,7 @@ LN_S = @LN_S@
|
||||
CC = @CC@
|
||||
HOST_CC = @BUILD_CC@
|
||||
|
||||
CFLAGS = @CFLAGS@
|
||||
CFLAGS = @CFLAGS@ @EXTRA_CFLAGS@
|
||||
HOST_CFLAGS = @BUILD_CFLAGS@
|
||||
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
@ -65,9 +66,9 @@ HOST_CPPFLAGS = @ACPPFLAGS@ @BUILD_CPPFLAGS@ \
|
||||
-DHAVE_CONFIG_H -I$(srcdir)
|
||||
|
||||
CCFLAGS = $(HOST_CPPFLAGS) $(HOST_CFLAGS)
|
||||
CFLAGS_NORMAL = $(CCFLAGS)
|
||||
CFLAGS_DEBUG = $(CCFLAGS) @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -pg
|
||||
CFLAGS_NORMAL = $(CCFLAGS) -DNCURSES_STATIC
|
||||
CFLAGS_DEBUG = $(CCFLAGS) -DNCURSES_STATIC @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -DNCURSES_STATIC -pg
|
||||
CFLAGS_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@
|
||||
|
||||
CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
|
||||
@ -167,7 +168,7 @@ gen.o: $(srcdir)/gen.c
|
||||
$(HOST_CC) $(CFLAGS_NORMAL) -c -o $@ $(srcdir)/gen.c
|
||||
|
||||
$(ADA_SRCDIR)/$(ABASE)_constants.ads: $(PROG_GENERATE)
|
||||
$(WRAPPER) "$(GENERATE)" >$@
|
||||
$(WRAPPER) "$(GENERATE) $@"
|
||||
################################################################################
|
||||
$(ADA_SRCDIR)/$(ABASE).ads: $(srcdir)/$(ABASE).ads.m4 \
|
||||
$(srcdir)/normal.m4
|
||||
@ -310,7 +311,7 @@ adahtml:
|
||||
test -n "$(GNATHTML)" || exit 1
|
||||
@find $(HTML_DIR) -type f -exec rm -f {} \;
|
||||
@mkdir -p $(HTML_DIR)
|
||||
cp -p ../src/*.ad[sb] . && chmod +w *.ad[sb]
|
||||
( cp -p ../src/*.ad[sb] . && chmod +w *.ad[sb] )
|
||||
@USE_OLD_MAKERULES@ ln -sf ../src/*.ali .
|
||||
@USE_GNAT_PROJECTS@ ln -sf ../static-ali/*.ali .
|
||||
@echo "Filtering generated files"
|
||||
|
208
Ada95/gen/gen.c
208
Ada95/gen/gen.c
@ -29,11 +29,13 @@
|
||||
|
||||
/****************************************************************************
|
||||
* Author: Juergen Pfeifer, 1996 *
|
||||
* and: Thomas E. Dickey, 1998 *
|
||||
* and: Nicolas Boulenguez, 2011 *
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
Version Control
|
||||
$Id: gen.c,v 1.71 2020/02/02 23:34:34 tom Exp $
|
||||
$Id: gen.c,v 1.77 2020/08/16 18:05:05 tom Exp $
|
||||
--------------------------------------------------------------------------*/
|
||||
/*
|
||||
This program prints on its standard output the source for the
|
||||
@ -55,9 +57,11 @@
|
||||
|
||||
#undef UCHAR
|
||||
#undef UINT
|
||||
#undef ULONG
|
||||
|
||||
typedef unsigned char UCHAR;
|
||||
typedef unsigned int UINT;
|
||||
typedef unsigned long ULONG;
|
||||
|
||||
/* These global variables will be set by main () */
|
||||
static int little_endian;
|
||||
@ -71,19 +75,36 @@ my_error(const char *message)
|
||||
}
|
||||
|
||||
static void
|
||||
print_constant(const char *name,
|
||||
print_constant(FILE * fp,
|
||||
const char *name,
|
||||
UINT value)
|
||||
{
|
||||
fprintf(fp, " %-28s : constant := %u;\n", name, value);
|
||||
}
|
||||
|
||||
static void
|
||||
print_long_val(FILE * fp,
|
||||
const char *name,
|
||||
long value)
|
||||
{
|
||||
printf(" %-28s : constant := %ld;\n", name, value);
|
||||
fprintf(fp, " %-28s : constant := %ld;\n", name, value);
|
||||
}
|
||||
|
||||
static void
|
||||
print_size_of(FILE * fp,
|
||||
const char *name,
|
||||
size_t value)
|
||||
{
|
||||
fprintf(fp, " %-28s : constant := %lu;\n", name, value);
|
||||
}
|
||||
|
||||
#define PRINT_NAMED_CONSTANT(name) \
|
||||
print_constant (#name, name)
|
||||
print_long_val (fp, #name, name)
|
||||
|
||||
static void
|
||||
print_comment(const char *message)
|
||||
print_comment(FILE * fp, const char *message)
|
||||
{
|
||||
printf("\n -- %s\n\n", message);
|
||||
fprintf(fp, "\n -- %s\n\n", message);
|
||||
}
|
||||
|
||||
/*
|
||||
@ -142,8 +163,8 @@ find_pos(const UCHAR * const data,
|
||||
c_type mask = (mask_macro); \
|
||||
if (!find_pos ((UCHAR *)&mask, sizeof (mask), &first, &last)) \
|
||||
my_error ("failed to locate " ada_name); \
|
||||
print_constant (ada_name "_First", first); \
|
||||
print_constant (ada_name "_Last", last); \
|
||||
print_constant (fp, ada_name "_First", first); \
|
||||
print_constant (fp, ada_name "_Last", last); \
|
||||
}
|
||||
|
||||
#define PRINT_NAMED_BITMASK(c_type, mask_macro) \
|
||||
@ -157,8 +178,8 @@ find_pos(const UCHAR * const data,
|
||||
memset (&mask.field, 0xff, sizeof(mask.field)); \
|
||||
if (!find_pos ((UCHAR *)&mask, sizeof (mask), &first, &last)) \
|
||||
my_error ("failed to locate" #record "_" #field); \
|
||||
print_constant (#record "_" #field "_First", first); \
|
||||
print_constant (#record "_" #field "_Last", last); \
|
||||
print_constant (fp, #record "_" #field "_First", first); \
|
||||
print_constant (fp, #record "_" #field "_Last", last); \
|
||||
}
|
||||
|
||||
/*--------------------*/
|
||||
@ -168,6 +189,7 @@ find_pos(const UCHAR * const data,
|
||||
int
|
||||
main(int argc, const char *argv[])
|
||||
{
|
||||
FILE *fp = 0;
|
||||
const int x = 0x12345678;
|
||||
|
||||
little_endian = (*((const char *)&x) == 0x78);
|
||||
@ -177,40 +199,61 @@ main(int argc, const char *argv[])
|
||||
if (KEY_MIN == 256)
|
||||
my_error("unexpected value for KEY_MIN: 256");
|
||||
|
||||
if (argc != 2)
|
||||
my_error("Only one argument expected (DFT_ARG_SUFFIX)");
|
||||
if (argc == 3)
|
||||
{
|
||||
fp = fopen(argv[2], "wb");
|
||||
}
|
||||
else if (argc == 2)
|
||||
{
|
||||
fp = stdout;
|
||||
}
|
||||
else
|
||||
{
|
||||
my_error("Only one or two arguments expected (DFT_ARG_SUFFIX)");
|
||||
}
|
||||
|
||||
printf("-- Generated by the C program %s (source " __FILE__ ").\n",
|
||||
my_program_invocation_name);
|
||||
printf("-- Do not edit this file directly.\n");
|
||||
printf("-- The values provided here may vary on your system.\n");
|
||||
printf("\n");
|
||||
printf("with System;\n");
|
||||
printf("package Terminal_Interface.Curses_Constants is\n");
|
||||
printf(" pragma Pure;\n");
|
||||
printf("\n");
|
||||
if ((strlen(argv[0]) + strlen(__FILE__)) > 25)
|
||||
{
|
||||
fprintf(fp, "-- Generated by the C program %.40s.\n",
|
||||
my_program_invocation_name);
|
||||
}
|
||||
else
|
||||
{
|
||||
fprintf(fp, "-- Generated by the C program %s (source %s).\n",
|
||||
my_program_invocation_name,
|
||||
__FILE__);
|
||||
}
|
||||
fprintf(fp, "-- Do not edit this file directly.\n");
|
||||
fprintf(fp, "-- The values provided here may vary on your system.\n");
|
||||
fprintf(fp, "\n");
|
||||
fprintf(fp, "with System;\n");
|
||||
fprintf(fp, "package Terminal_Interface.Curses_Constants is\n");
|
||||
fprintf(fp, " pragma Pure;\n");
|
||||
fprintf(fp, "\n");
|
||||
|
||||
printf(" DFT_ARG_SUFFIX : constant String := \"%s\";\n", argv[1]);
|
||||
printf(" Bit_Order : constant System.Bit_Order := System.%s_Order_First;\n",
|
||||
little_endian ? "Low" : "High");
|
||||
print_constant("Sizeof_Bool", 8 * sizeof(bool));
|
||||
fprintf(fp, " DFT_ARG_SUFFIX : constant String := \"%s\";\n", argv[1]);
|
||||
fprintf(fp,
|
||||
" Bit_Order : constant System.Bit_Order := System.%s_Order_First;\n",
|
||||
little_endian ? "Low" : "High");
|
||||
print_size_of(fp, "Sizeof_Bool", 8 * sizeof(bool));
|
||||
|
||||
PRINT_NAMED_CONSTANT(OK);
|
||||
PRINT_NAMED_CONSTANT(ERR);
|
||||
printf(" pragma Warnings (Off); -- redefinition of Standard.True and False\n");
|
||||
fprintf(fp,
|
||||
" pragma Warnings (Off); -- redefinition of Standard.True and False\n");
|
||||
PRINT_NAMED_CONSTANT(TRUE);
|
||||
PRINT_NAMED_CONSTANT(FALSE);
|
||||
printf(" pragma Warnings (On);\n");
|
||||
fprintf(fp, " pragma Warnings (On);\n");
|
||||
|
||||
print_comment("Version of the ncurses library from extensions(3NCURSES)");
|
||||
print_comment(fp, "Version of the ncurses library from extensions(3NCURSES)");
|
||||
PRINT_NAMED_CONSTANT(NCURSES_VERSION_MAJOR);
|
||||
PRINT_NAMED_CONSTANT(NCURSES_VERSION_MINOR);
|
||||
printf(" Version : constant String := \"%d.%d\";\n",
|
||||
NCURSES_VERSION_MAJOR, NCURSES_VERSION_MINOR);
|
||||
fprintf(fp, " Version : constant String := \"%d.%d\";\n",
|
||||
NCURSES_VERSION_MAJOR, NCURSES_VERSION_MINOR);
|
||||
|
||||
print_comment("Character non-color attributes from attr(3NCURSES)");
|
||||
printf(" -- attr_t and chtype may be signed in C.\n");
|
||||
printf(" type attr_t is mod 2 ** %lu;\n", (long unsigned)(8 * sizeof(attr_t)));
|
||||
print_comment(fp, "Character non-color attributes from attr(3NCURSES)");
|
||||
fprintf(fp, " -- attr_t and chtype may be signed in C.\n");
|
||||
fprintf(fp, " type attr_t is mod 2 ** %lu;\n", (long unsigned)(8 * sizeof(attr_t)));
|
||||
PRINT_NAMED_BITMASK(attr_t, A_CHARTEXT);
|
||||
PRINT_NAMED_BITMASK(attr_t, A_COLOR);
|
||||
PRINT_BITMASK(attr_t, "Attr", A_ATTRIBUTES & ~A_COLOR);
|
||||
@ -229,9 +272,9 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_BITMASK(attr_t, A_RIGHT);
|
||||
PRINT_NAMED_BITMASK(attr_t, A_TOP);
|
||||
PRINT_NAMED_BITMASK(attr_t, A_VERTICAL);
|
||||
print_constant("chtype_Size", 8 * sizeof(chtype));
|
||||
print_size_of(fp, "chtype_Size", 8 * sizeof(chtype));
|
||||
|
||||
print_comment("predefined color numbers from color(3NCURSES)");
|
||||
print_comment(fp, "predefined color numbers from color(3NCURSES)");
|
||||
PRINT_NAMED_CONSTANT(COLOR_BLACK);
|
||||
PRINT_NAMED_CONSTANT(COLOR_RED);
|
||||
PRINT_NAMED_CONSTANT(COLOR_GREEN);
|
||||
@ -241,7 +284,7 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_CONSTANT(COLOR_CYAN);
|
||||
PRINT_NAMED_CONSTANT(COLOR_WHITE);
|
||||
|
||||
print_comment("ETI return codes from ncurses.h");
|
||||
print_comment(fp, "ETI return codes from ncurses.h");
|
||||
PRINT_NAMED_CONSTANT(E_OK);
|
||||
PRINT_NAMED_CONSTANT(E_SYSTEM_ERROR);
|
||||
PRINT_NAMED_CONSTANT(E_BAD_ARGUMENT);
|
||||
@ -258,14 +301,14 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_CONSTANT(E_INVALID_FIELD);
|
||||
PRINT_NAMED_CONSTANT(E_CURRENT);
|
||||
|
||||
print_comment("Input key codes not defined in any ncurses manpage");
|
||||
print_comment(fp, "Input key codes not defined in any ncurses manpage");
|
||||
PRINT_NAMED_CONSTANT(KEY_MIN);
|
||||
PRINT_NAMED_CONSTANT(KEY_MAX);
|
||||
#ifdef KEY_CODE_YES
|
||||
PRINT_NAMED_CONSTANT(KEY_CODE_YES);
|
||||
#endif
|
||||
|
||||
print_comment("Input key codes from getch(3NCURSES)");
|
||||
print_comment(fp, "Input key codes from getch(3NCURSES)");
|
||||
PRINT_NAMED_CONSTANT(KEY_BREAK);
|
||||
PRINT_NAMED_CONSTANT(KEY_DOWN);
|
||||
PRINT_NAMED_CONSTANT(KEY_UP);
|
||||
@ -274,30 +317,31 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_CONSTANT(KEY_HOME);
|
||||
PRINT_NAMED_CONSTANT(KEY_BACKSPACE);
|
||||
PRINT_NAMED_CONSTANT(KEY_F0);
|
||||
print_constant("KEY_F1", KEY_F(1));
|
||||
print_constant("KEY_F2", KEY_F(2));
|
||||
print_constant("KEY_F3", KEY_F(3));
|
||||
print_constant("KEY_F4", KEY_F(4));
|
||||
print_constant("KEY_F5", KEY_F(5));
|
||||
print_constant("KEY_F6", KEY_F(6));
|
||||
print_constant("KEY_F7", KEY_F(7));
|
||||
print_constant("KEY_F8", KEY_F(8));
|
||||
print_constant("KEY_F9", KEY_F(9));
|
||||
print_constant("KEY_F10", KEY_F(10));
|
||||
print_constant("KEY_F11", KEY_F(11));
|
||||
print_constant("KEY_F12", KEY_F(12));
|
||||
print_constant("KEY_F13", KEY_F(13));
|
||||
print_constant("KEY_F14", KEY_F(14));
|
||||
print_constant("KEY_F15", KEY_F(15));
|
||||
print_constant("KEY_F16", KEY_F(16));
|
||||
print_constant("KEY_F17", KEY_F(17));
|
||||
print_constant("KEY_F18", KEY_F(18));
|
||||
print_constant("KEY_F19", KEY_F(19));
|
||||
print_constant("KEY_F20", KEY_F(20));
|
||||
print_constant("KEY_F21", KEY_F(21));
|
||||
print_constant("KEY_F22", KEY_F(22));
|
||||
print_constant("KEY_F23", KEY_F(23));
|
||||
print_constant("KEY_F24", KEY_F(24));
|
||||
#define PRINT_NAMED_FUNC_KEY(name) print_constant(fp, "KEY_F"#name, KEY_F(name))
|
||||
PRINT_NAMED_FUNC_KEY(1);
|
||||
PRINT_NAMED_FUNC_KEY(2);
|
||||
PRINT_NAMED_FUNC_KEY(3);
|
||||
PRINT_NAMED_FUNC_KEY(4);
|
||||
PRINT_NAMED_FUNC_KEY(5);
|
||||
PRINT_NAMED_FUNC_KEY(6);
|
||||
PRINT_NAMED_FUNC_KEY(7);
|
||||
PRINT_NAMED_FUNC_KEY(8);
|
||||
PRINT_NAMED_FUNC_KEY(9);
|
||||
PRINT_NAMED_FUNC_KEY(10);
|
||||
PRINT_NAMED_FUNC_KEY(11);
|
||||
PRINT_NAMED_FUNC_KEY(12);
|
||||
PRINT_NAMED_FUNC_KEY(13);
|
||||
PRINT_NAMED_FUNC_KEY(14);
|
||||
PRINT_NAMED_FUNC_KEY(15);
|
||||
PRINT_NAMED_FUNC_KEY(16);
|
||||
PRINT_NAMED_FUNC_KEY(17);
|
||||
PRINT_NAMED_FUNC_KEY(18);
|
||||
PRINT_NAMED_FUNC_KEY(19);
|
||||
PRINT_NAMED_FUNC_KEY(20);
|
||||
PRINT_NAMED_FUNC_KEY(21);
|
||||
PRINT_NAMED_FUNC_KEY(22);
|
||||
PRINT_NAMED_FUNC_KEY(23);
|
||||
PRINT_NAMED_FUNC_KEY(24);
|
||||
PRINT_NAMED_CONSTANT(KEY_DL);
|
||||
PRINT_NAMED_CONSTANT(KEY_IL);
|
||||
PRINT_NAMED_CONSTANT(KEY_DC);
|
||||
@ -382,8 +426,8 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_CONSTANT(KEY_MOUSE);
|
||||
PRINT_NAMED_CONSTANT(KEY_RESIZE);
|
||||
|
||||
print_comment("alternate character codes (ACS) from addch(3NCURSES)");
|
||||
#define PRINT_ACS(name) print_constant (#name, &name - &acs_map[0])
|
||||
print_comment(fp, "alternate character codes (ACS) from addch(3NCURSES)");
|
||||
#define PRINT_ACS(name) print_size_of (fp, #name, (size_t)(&name - &acs_map[0]))
|
||||
PRINT_ACS(ACS_ULCORNER);
|
||||
PRINT_ACS(ACS_LLCORNER);
|
||||
PRINT_ACS(ACS_URCORNER);
|
||||
@ -417,20 +461,20 @@ main(int argc, const char *argv[])
|
||||
PRINT_ACS(ACS_NEQUAL);
|
||||
PRINT_ACS(ACS_STERLING);
|
||||
|
||||
print_comment("Menu_Options from opts(3MENU)");
|
||||
print_comment(fp, "Menu_Options from opts(3MENU)");
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_ONEVALUE);
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_SHOWDESC);
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_ROWMAJOR);
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_IGNORECASE);
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_SHOWMATCH);
|
||||
PRINT_NAMED_BITMASK(Menu_Options, O_NONCYCLIC);
|
||||
print_constant("Menu_Options_Size", 8 * sizeof(Menu_Options));
|
||||
print_size_of(fp, "Menu_Options_Size", 8 * sizeof(Menu_Options));
|
||||
|
||||
print_comment("Item_Options from menu_opts(3MENU)");
|
||||
print_comment(fp, "Item_Options from menu_opts(3MENU)");
|
||||
PRINT_NAMED_BITMASK(Item_Options, O_SELECTABLE);
|
||||
print_constant("Item_Options_Size", 8 * sizeof(Item_Options));
|
||||
print_size_of(fp, "Item_Options_Size", 8 * sizeof(Item_Options));
|
||||
|
||||
print_comment("Field_Options from field_opts(3FORM)");
|
||||
print_comment(fp, "Field_Options from field_opts(3FORM)");
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_VISIBLE);
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_ACTIVE);
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_PUBLIC);
|
||||
@ -441,27 +485,27 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_NULLOK);
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_PASSOK);
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_STATIC);
|
||||
print_constant("Field_Options_Size", 8 * sizeof(Field_Options));
|
||||
print_size_of(fp, "Field_Options_Size", 8 * sizeof(Field_Options));
|
||||
|
||||
print_comment("Field_Options from opts(3FORM)");
|
||||
print_comment(fp, "Field_Options from opts(3FORM)");
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_NL_OVERLOAD);
|
||||
PRINT_NAMED_BITMASK(Field_Options, O_BS_OVERLOAD);
|
||||
/* Field_Options_Size is defined below */
|
||||
|
||||
print_comment("MEVENT structure from mouse(3NCURSES)");
|
||||
print_comment(fp, "MEVENT structure from mouse(3NCURSES)");
|
||||
STRUCT_OFFSET(MEVENT, id);
|
||||
STRUCT_OFFSET(MEVENT, x);
|
||||
STRUCT_OFFSET(MEVENT, y);
|
||||
STRUCT_OFFSET(MEVENT, z);
|
||||
STRUCT_OFFSET(MEVENT, bstate);
|
||||
print_constant("MEVENT_Size", 8 * sizeof(MEVENT));
|
||||
print_size_of(fp, "MEVENT_Size", 8 * sizeof(MEVENT));
|
||||
|
||||
print_comment("mouse events from mouse(3NCURSES)");
|
||||
print_comment(fp, "mouse events from mouse(3NCURSES)");
|
||||
{
|
||||
mmask_t all_events;
|
||||
|
||||
#define PRINT_MOUSE_EVENT(event) \
|
||||
print_constant (#event, event); \
|
||||
print_constant (fp, #event, event); \
|
||||
all_events |= event
|
||||
|
||||
all_events = 0;
|
||||
@ -473,7 +517,7 @@ main(int argc, const char *argv[])
|
||||
#ifdef BUTTON1_RESERVED_EVENT
|
||||
PRINT_MOUSE_EVENT(BUTTON1_RESERVED_EVENT);
|
||||
#endif
|
||||
print_constant("all_events_button_1", (long)all_events);
|
||||
print_constant(fp, "all_events_button_1", (UINT) all_events);
|
||||
|
||||
all_events = 0;
|
||||
PRINT_MOUSE_EVENT(BUTTON2_RELEASED);
|
||||
@ -484,7 +528,7 @@ main(int argc, const char *argv[])
|
||||
#ifdef BUTTON2_RESERVED_EVENT
|
||||
PRINT_MOUSE_EVENT(BUTTON2_RESERVED_EVENT);
|
||||
#endif
|
||||
print_constant("all_events_button_2", (long)all_events);
|
||||
print_constant(fp, "all_events_button_2", (UINT) all_events);
|
||||
|
||||
all_events = 0;
|
||||
PRINT_MOUSE_EVENT(BUTTON3_RELEASED);
|
||||
@ -495,7 +539,7 @@ main(int argc, const char *argv[])
|
||||
#ifdef BUTTON3_RESERVED_EVENT
|
||||
PRINT_MOUSE_EVENT(BUTTON3_RESERVED_EVENT);
|
||||
#endif
|
||||
print_constant("all_events_button_3", (long)all_events);
|
||||
print_constant(fp, "all_events_button_3", (UINT) all_events);
|
||||
|
||||
all_events = 0;
|
||||
PRINT_MOUSE_EVENT(BUTTON4_RELEASED);
|
||||
@ -506,7 +550,7 @@ main(int argc, const char *argv[])
|
||||
#ifdef BUTTON4_RESERVED_EVENT
|
||||
PRINT_MOUSE_EVENT(BUTTON4_RESERVED_EVENT);
|
||||
#endif
|
||||
print_constant("all_events_button_4", (long)all_events);
|
||||
print_constant(fp, "all_events_button_4", (UINT) all_events);
|
||||
}
|
||||
PRINT_NAMED_CONSTANT(BUTTON_CTRL);
|
||||
PRINT_NAMED_CONSTANT(BUTTON_SHIFT);
|
||||
@ -514,7 +558,7 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_CONSTANT(REPORT_MOUSE_POSITION);
|
||||
PRINT_NAMED_CONSTANT(ALL_MOUSE_EVENTS);
|
||||
|
||||
print_comment("trace selection from trace(3NCURSES)");
|
||||
print_comment(fp, "trace selection from trace(3NCURSES)");
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_TIMES);
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_TPUTS);
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_UPDATE);
|
||||
@ -528,8 +572,8 @@ main(int argc, const char *argv[])
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_CCALLS);
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_DATABASE);
|
||||
PRINT_NAMED_BITMASK(UINT, TRACE_ATTRS);
|
||||
print_constant("Trace_Size", 8 * sizeof(UINT));
|
||||
print_size_of(fp, "Trace_Size", 8 * sizeof(UINT));
|
||||
|
||||
printf("end Terminal_Interface.Curses_Constants;\n");
|
||||
fprintf(fp, "end Terminal_Interface.Curses_Constants;\n");
|
||||
exit(EXIT_SUCCESS);
|
||||
}
|
||||
|
@ -1 +1 @@
|
||||
9
|
||||
10
|
||||
|
@ -1,14 +1,15 @@
|
||||
Upstream source https://invisible-island.net/ncurses/ncurses-examples.html
|
||||
Upstream source https://invisible-island.net/ncurses/Ada95.html
|
||||
|
||||
Current ncurses maintainer: Thomas Dickey <dickey@invisible-island.net>
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Files: *
|
||||
Copyright: 1998-2019,2020 Free Software Foundation, Inc.
|
||||
Copyright: 2017-2020,2021 by Thomas E. Dickey
|
||||
Copyright: 1998-2016,2017 Free Software Foundation, Inc.
|
||||
Licence: X11
|
||||
|
||||
Files: aclocal.m4 package
|
||||
Copyright: 2010-2019,2020 by Thomas E. Dickey
|
||||
Copyright: 2010-2020,2021 by Thomas E. Dickey
|
||||
Licence: X11
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright 2018-2019,2020 Thomas E. Dickey #
|
||||
# Copyright 2018-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1998-2015,2018 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -29,7 +29,7 @@
|
||||
#
|
||||
# Author: Juergen Pfeifer, 1996
|
||||
#
|
||||
# $Id: Makefile.in,v 1.59 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.62 2021/01/23 20:42:08 tom Exp $
|
||||
#
|
||||
.SUFFIXES:
|
||||
|
||||
@ -55,16 +55,16 @@ AWK = @AWK@
|
||||
LN_S = @LN_S@
|
||||
|
||||
CC = @CC@
|
||||
CFLAGS = @CFLAGS@
|
||||
CFLAGS = @CFLAGS@ @EXTRA_CFLAGS@
|
||||
|
||||
CPPFLAGS = @ACPPFLAGS@ \
|
||||
-DHAVE_CONFIG_H -I$(srcdir)
|
||||
|
||||
CCFLAGS = $(CPPFLAGS) $(CFLAGS)
|
||||
|
||||
CFLAGS_NORMAL = $(CCFLAGS)
|
||||
CFLAGS_DEBUG = $(CCFLAGS) @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -pg
|
||||
CFLAGS_NORMAL = $(CCFLAGS) -DNCURSES_STATIC
|
||||
CFLAGS_DEBUG = $(CCFLAGS) -DNCURSES_STATIC @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -DNCURSES_STATIC -pg
|
||||
CFLAGS_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@
|
||||
|
||||
CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
|
||||
@ -131,7 +131,7 @@ install.examples :: $(MY_DATADIR)
|
||||
$(INSTALL_DATA) explain.txt $(MY_DATADIR)
|
||||
|
||||
uninstall.examples ::
|
||||
-cd $(BINDIR) && rm -f $(PROGS)
|
||||
-( cd $(BINDIR) && rm -f $(PROGS) )
|
||||
-rmdir $(BINDIR)
|
||||
-rm -f $(MY_DATADIR)/explain.txt
|
||||
-rmdir $(MY_DATADIR)
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright 2018-2019,2020 Thomas E. Dickey #
|
||||
# Copyright 2018-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1999-2016,2018 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -29,7 +29,7 @@
|
||||
#
|
||||
# Author: Juergen Pfeifer, 1996
|
||||
#
|
||||
# $Id: Makefile.in,v 1.89 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.95 2021/01/23 20:42:08 tom Exp $
|
||||
#
|
||||
.SUFFIXES:
|
||||
|
||||
@ -64,16 +64,16 @@ AWK = @AWK@
|
||||
LN_S = @LN_S@
|
||||
|
||||
CC = @CC@
|
||||
CFLAGS = @CFLAGS@
|
||||
CFLAGS = @CFLAGS@ @EXTRA_CFLAGS@
|
||||
|
||||
CPPFLAGS = @ACPPFLAGS@ @CPPFLAGS@ \
|
||||
-DHAVE_CONFIG_H -I$(srcdir)
|
||||
|
||||
CCFLAGS = $(CPPFLAGS) $(CFLAGS)
|
||||
|
||||
CFLAGS_NORMAL = $(CCFLAGS)
|
||||
CFLAGS_DEBUG = $(CCFLAGS) @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -pg
|
||||
CFLAGS_NORMAL = $(CCFLAGS) -DNCURSES_STATIC
|
||||
CFLAGS_DEBUG = $(CCFLAGS) -DNCURSES_STATIC @CC_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -DNCURSES_STATIC -pg
|
||||
CFLAGS_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@
|
||||
|
||||
CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
|
||||
@ -184,7 +184,7 @@ $(BUILD_DIR_LIB) :
|
||||
mkdir -p $@
|
||||
|
||||
$(GENERATED_SOURCES) :
|
||||
cd ../gen; $(MAKE) $(ADA_MFLAGS)
|
||||
( cd ../gen; $(MAKE) $(ADA_MFLAGS) )
|
||||
|
||||
sources : $(GENERATED_SOURCES)
|
||||
@echo made $@
|
||||
@ -195,6 +195,7 @@ install.libs :: \
|
||||
$(BUILD_DIR_LIB)/$(STATIC_LIBNAME)
|
||||
@echo made $(STATIC_LIBNAME)
|
||||
|
||||
#OLD:BEGIN
|
||||
install \
|
||||
install.libs :: \
|
||||
$(BUILD_DIR_LIB)/$(STATIC_LIBNAME) \
|
||||
@ -206,6 +207,7 @@ install.libs :: \
|
||||
uninstall \
|
||||
uninstall.libs ::
|
||||
@rm -f $(ADA_OBJECTS)/$(STATIC_LIBNAME)
|
||||
#OLD:END
|
||||
|
||||
mostlyclean ::
|
||||
rm -f *.o *.ali b_t*.* *.s $(PROGS) a.out core b_*_test.c *.xr[bs] *.a
|
||||
@ -273,23 +275,71 @@ STATIC_DIRS = \
|
||||
@USE_GNAT_PROJECTS@ $(STATIC_DIRS)
|
||||
@USE_GNAT_PROJECTS@ @cf_ada_config@gprconfig --batch --config=Ada --config=C,,,,@cf_ada_config_C@
|
||||
@USE_GNAT_PROJECTS@ -rm -f $(GNAT_PROJECT)
|
||||
@USE_GNAT_PROJECTS@ $(SHELL) $(srcdir)/library-cfg.sh static $(srcdir)/library.gpr $(CFLAGS_NORMAL) >$(GNAT_PROJECT)
|
||||
@USE_GNAT_PROJECTS@ $(SHELL) $(srcdir)/library-cfg.sh static library.gpr $(CFLAGS_NORMAL) >$(GNAT_PROJECT)
|
||||
@USE_GNAT_PROJECTS@ @echo "Using GNAT Project:"
|
||||
@USE_GNAT_PROJECTS@ @-$(SHELL) -c "diff -c $(srcdir)/library.gpr $(GNAT_PROJECT); exit 0"
|
||||
@USE_GNAT_PROJECTS@ $(ADAMAKE) $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
@USE_GNAT_PROJECTS@ $(AR) $(ARFLAGS) $@ $(STATIC_C_OBJS)
|
||||
@USE_GNAT_PROJECTS@ -rm -f $(GNAT_PROJECT)
|
||||
@USE_GNAT_PROJECTS@
|
||||
@USE_GNAT_MAKE_GPR@ @-$(SHELL) -c "diff -c $(srcdir)/library.gpr $(GNAT_PROJECT); exit 0"
|
||||
@USE_GNAT_MAKE_GPR@ $(ADAMAKE) $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
@USE_GNAT_MAKE_GPR@ $(AR) $(ARFLAGS) $@ $(STATIC_C_OBJS)
|
||||
@USE_GNAT_MAKE_GPR@ -rm -f $(GNAT_PROJECT)
|
||||
@USE_GNAT_GPRBUILD@ @-$(SHELL) -c "diff -c library.gpr $(GNAT_PROJECT); exit 0"
|
||||
@USE_GNAT_GPRBUILD@ gprbuild -p $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
@USE_GNAT_GPRBUILD@ -rm -f $(GNAT_PROJECT)
|
||||
|
||||
#OLD:BEGIN
|
||||
@USE_GNAT_LIBRARIES@install \
|
||||
@USE_GNAT_LIBRARIES@install.libs :: \
|
||||
@USE_GNAT_LIBRARIES@ $(ADA_OBJECTS)
|
||||
@USE_GNAT_LIBRARIES@ $(INSTALL_LIB) \
|
||||
@USE_GNAT_LIBRARIES@ $(BUILD_DIR)/static-ali/*.ali \
|
||||
@USE_GNAT_LIBRARIES@ $(ADA_OBJECTS)
|
||||
#OLD:END
|
||||
# While gprinstall is the "recommended" tool, it is rather brittle, with
|
||||
# hardcoded assumptions about the use of the install-name which prevent using
|
||||
# that tool to make the directory layout of older versions of the AdaCurses
|
||||
# package.
|
||||
#
|
||||
# In principle, one might just do
|
||||
# --install-name=""
|
||||
# and in dry-run mode, gprinstall pretends to handle it properly (trimming the
|
||||
# empty directory level), but without the dry-run option, it fails (tested
|
||||
# with gnat 10.1.1).
|
||||
#NEW:BEGIN
|
||||
#@USE_GNAT_LIBRARIES@install \
|
||||
#@USE_GNAT_LIBRARIES@install.libs ::
|
||||
#@USE_GNAT_LIBRARIES@ @cf_ada_config@gprconfig --batch --config=Ada --config=C,,,,@cf_ada_config_C@
|
||||
#@USE_GNAT_LIBRARIES@ -rm -f $(GNAT_PROJECT)
|
||||
#@USE_GNAT_LIBRARIES@ $(SHELL) $(srcdir)/library-cfg.sh static library.gpr $(CFLAGS_NORMAL) >$(GNAT_PROJECT)
|
||||
#@USE_GNAT_LIBRARIES@ @echo "Using GNAT Project:"
|
||||
#@USE_GNAT_LIBRARIES@ @-$(SHELL) -c "diff -c library.gpr $(GNAT_PROJECT); exit 0"
|
||||
#@USE_GNAT_LIBRARIES@
|
||||
#@USE_GNAT_LIBRARIES@ gprinstall -m -v -f -p \
|
||||
#@USE_GNAT_LIBRARIES@ --prefix="$(DESTDIR)$(prefix)" \
|
||||
#@USE_GNAT_LIBRARIES@ $(ADAMAKEFLAGS) -XLIB_KIND=static \
|
||||
#@USE_GNAT_LIBRARIES@ --lib-subdir="$(DESTDIR)$(prefix)"/lib \
|
||||
#@USE_GNAT_LIBRARIES@ --ali-subdir="$(DESTDIR)$(prefix)"/lib/ada/adalib \
|
||||
#@USE_GNAT_LIBRARIES@ --sources-subdir="$(DESTDIR)$(prefix)"/share/ada/adainclude
|
||||
#@USE_GNAT_LIBRARIES@
|
||||
#@USE_GNAT_LIBRARIES@ -rm -f $(GNAT_PROJECT)
|
||||
#NEW:END
|
||||
|
||||
#OLD:BEGIN
|
||||
uninstall \
|
||||
uninstall.libs ::
|
||||
@rm -f $(ADA_OBJECTS)/$(STATIC_LIBNAME)
|
||||
#OLD:END
|
||||
#NEW:BEGIN
|
||||
#@USE_GNAT_LIBRARIES@uninstall \
|
||||
#@USE_GNAT_LIBRARIES@uninstall.libs ::
|
||||
#@USE_GNAT_LIBRARIES@ @cf_ada_config@gprconfig --batch --config=Ada --config=C,,,,@cf_ada_config_C@
|
||||
#@USE_GNAT_LIBRARIES@ -rm -f $(GNAT_PROJECT)
|
||||
#@USE_GNAT_LIBRARIES@ $(SHELL) $(srcdir)/library-cfg.sh static library.gpr $(CFLAGS_NORMAL) >$(GNAT_PROJECT)
|
||||
#@USE_GNAT_LIBRARIES@ @echo "Using GNAT Project:"
|
||||
#@USE_GNAT_LIBRARIES@ @-$(SHELL) -c "diff -c library.gpr $(GNAT_PROJECT); exit 0"
|
||||
#@USE_GNAT_LIBRARIES@
|
||||
#@USE_GNAT_LIBRARIES@ gprinstall -v -f --prefix="$(DESTDIR)$(prefix)" --uninstall $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
#@USE_GNAT_LIBRARIES@
|
||||
#@USE_GNAT_LIBRARIES@ -rm -f $(GNAT_PROJECT)
|
||||
#NEW:END
|
||||
|
||||
@USE_GNAT_LIBRARIES@uninstall \
|
||||
@USE_GNAT_LIBRARIES@uninstall.libs ::
|
||||
@ -311,9 +361,9 @@ SHARED_DIRS = \
|
||||
@MAKE_ADA_SHAREDLIB@ cp $(SHARED_OBJS) $(BUILD_DIR)/dynamic-obj/
|
||||
@MAKE_ADA_SHAREDLIB@ @cf_ada_config@gprconfig --batch --config=Ada --config=C,,,,@cf_ada_config_C@
|
||||
@MAKE_ADA_SHAREDLIB@ -rm -f $(GNAT_PROJECT)
|
||||
@MAKE_ADA_SHAREDLIB@ $(SHELL) $(srcdir)/library-cfg.sh dynamic $(srcdir)/library.gpr $(CFLAGS_SHARED) >$(GNAT_PROJECT)
|
||||
@MAKE_ADA_SHAREDLIB@ $(SHELL) $(srcdir)/library-cfg.sh dynamic library.gpr $(CFLAGS_SHARED) >$(GNAT_PROJECT)
|
||||
@MAKE_ADA_SHAREDLIB@ @echo "Making Ada shared-lib:"
|
||||
@MAKE_ADA_SHAREDLIB@ @-$(SHELL) -c "diff -c $(srcdir)/library.gpr $(GNAT_PROJECT); exit 0"
|
||||
@MAKE_ADA_SHAREDLIB@ @-$(SHELL) -c "diff -c library.gpr $(GNAT_PROJECT); exit 0"
|
||||
@MAKE_ADA_SHAREDLIB@ $(ADAMAKE) $(ADAMAKEFLAGS) -XLIB_KIND=dynamic
|
||||
@MAKE_ADA_SHAREDLIB@ -rm -f $(GNAT_PROJECT)
|
||||
|
||||
@ -341,7 +391,7 @@ uninstall.libs ::
|
||||
@MAKE_ADA_SHAREDLIB@ $(INSTALL_LIB) \
|
||||
@MAKE_ADA_SHAREDLIB@ $(BUILD_DIR_LIB)/$(SHARED_LIBNAME) \
|
||||
@MAKE_ADA_SHAREDLIB@ $(LIBDIR)
|
||||
@MAKE_ADA_SHAREDLIB@ cd $(LIBDIR) && $(LN_S) $(SHARED_LIBNAME) $(SHARED_SYMLINK)
|
||||
@MAKE_ADA_SHAREDLIB@ ( cd $(LIBDIR) && $(LN_S) $(SHARED_LIBNAME) $(SHARED_SYMLINK) )
|
||||
@MAKE_ADA_SHAREDLIB@
|
||||
@MAKE_ADA_SHAREDLIB@uninstall \
|
||||
@MAKE_ADA_SHAREDLIB@uninstall.libs ::
|
||||
@ -352,8 +402,13 @@ uninstall.libs ::
|
||||
@MAKE_ADA_SHAREDLIB@ rm -f $(LIBDIR)/$(SHARED_SYMLINK)
|
||||
@MAKE_ADA_SHAREDLIB@ rm -f $(LIBDIR)/$(SHARED_LIBNAME)
|
||||
|
||||
#rm-docs :
|
||||
# gnatdoc --enable-build $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
|
||||
clean ::
|
||||
-rm -f default.cgpr
|
||||
-rm -rf $(BUILD_DIR)/*-ali
|
||||
-rm -rf $(BUILD_DIR)/*-obj
|
||||
-rm -rf $(BUILD_DIR_LIB)
|
||||
#@USE_GNAT_PROJECTS@ gprclean $(ADAMAKEFLAGS) -XLIB_KIND=static
|
||||
#@MAKE_ADA_SHAREDLIB@ gprclean $(ADAMAKEFLAGS) -XLIB_KIND=dynamic
|
||||
|
@ -25,7 +25,7 @@
|
||||
-- sale, use or other dealings in this Software without prior written --
|
||||
-- authorization. --
|
||||
------------------------------------------------------------------------------
|
||||
-- $Id: library.gpr.in,v 1.2 2020/02/02 23:34:34 tom Exp $
|
||||
-- $Id: library.gpr.in,v 1.3 2020/06/27 20:47:40 tom Exp $
|
||||
-- http://gcc.gnu.org/onlinedocs/gnat_ugn_unw/Library-Projects.html
|
||||
-- http://www.adaworld.com/debian/debian-ada-policy.html
|
||||
project AdaCurses is
|
||||
@ -48,10 +48,24 @@ project AdaCurses is
|
||||
for Default_Switches ("Ada") use
|
||||
("-g",
|
||||
"-O2",
|
||||
"-Wall",
|
||||
"-gnatafno",
|
||||
"-gnatVa", -- All validity checks
|
||||
"-gnatwa"); -- Activate all optional errors
|
||||
-- for Default_Switches ("C") use (CFLAGS)
|
||||
end Compiler;
|
||||
for Languages use ("C", "Ada");
|
||||
package Install is
|
||||
for Install_Name use "adacurses";
|
||||
-- for Artifacts ("share/doc/adacurses") use ("../doc/Ada95.html", "../doc/ada");
|
||||
-- for Artifacts ("share/doc/adacurses/adacurses_rm") use ("../" & Kind & "-obj" & "/gnatdoc/*");
|
||||
for Artifacts ("lib/ada/adalib") use
|
||||
("../src/*.ali");
|
||||
for Artifacts ("share/ada/adainclude") use
|
||||
("../src/*.ad?");
|
||||
-- for Artifacts ("share/examples/adacurses") use
|
||||
-- ("../samples/*.ad?", "../samples/explain.txt", "../samples/Makefile", "../samples/README");
|
||||
-- for Artifacts ("share/man/man1") use ("../doc/adacurses-config.1");
|
||||
for Artifacts ("bin") use ("../gen/adacurses-config");
|
||||
end Install;
|
||||
end AdaCurses;
|
||||
|
@ -36,8 +36,8 @@
|
||||
------------------------------------------------------------------------------
|
||||
-- Author: Juergen Pfeifer, 1996
|
||||
-- Version Control:
|
||||
-- $Revision: 1.27 $
|
||||
-- $Date: 2020/02/02 23:34:34 $
|
||||
-- $Revision: 1.28 $
|
||||
-- $Date: 2020/06/27 18:50:44 $
|
||||
-- Binding Version 01.00
|
||||
------------------------------------------------------------------------------
|
||||
with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux;
|
||||
@ -147,6 +147,7 @@ package body Terminal_Interface.Curses.Mouse is
|
||||
Button := Button4;
|
||||
end if;
|
||||
if Button in Real_Buttons then
|
||||
State := Released; -- preset to non real button;
|
||||
L := 2 ** (6 * Mouse_Button'Pos (Button));
|
||||
for I in Button_State'Range loop
|
||||
if (Mask and L) /= 0 then
|
||||
|
4
COPYING
4
COPYING
@ -1,4 +1,4 @@
|
||||
Copyright 2018-2019,2020 Thomas E. Dickey
|
||||
Copyright 2018-2020,2021 Thomas E. Dickey
|
||||
Copyright 1998-2017,2018 Free Software Foundation, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a
|
||||
@ -26,4 +26,4 @@ sale, use or other dealings in this Software without prior written
|
||||
authorization.
|
||||
|
||||
-- vile:txtmode fc=72
|
||||
-- $Id: COPYING,v 1.9 2020/02/08 13:34:12 tom Exp $
|
||||
-- $Id: COPYING,v 1.10 2021/01/01 09:54:30 tom Exp $
|
||||
|
114
INSTALL
114
INSTALL
@ -26,7 +26,7 @@
|
||||
-- sale, use or other dealings in this Software without prior written --
|
||||
-- authorization. --
|
||||
-------------------------------------------------------------------------------
|
||||
-- $Id: INSTALL,v 1.217 2020/02/15 13:39:30 tom Exp $
|
||||
-- $Id: INSTALL,v 1.226 2020/09/06 23:41:16 tom Exp $
|
||||
---------------------------------------------------------------------
|
||||
How to install Ncurses/Terminfo on your system
|
||||
---------------------------------------------------------------------
|
||||
@ -41,7 +41,7 @@ including `c++', `form', `man', `menu', 'misc', `ncurses', `panel', `progs',
|
||||
and `test'. See the README file for a roadmap to the package.
|
||||
|
||||
If you are a distribution integrator or packager, please read and act on the
|
||||
section titled IF YOU ARE A SYSTEM INTEGRATOR below.
|
||||
section titled FOR SYSTEM INTEGRATORS below.
|
||||
|
||||
If you are converting from BSD curses and do not have root access, be sure
|
||||
to read the BSD CONVERSION NOTES section below.
|
||||
@ -49,11 +49,7 @@ to read the BSD CONVERSION NOTES section below.
|
||||
If you are trying to build applications using gpm with ncurses,
|
||||
read the USING NCURSES WITH GPM section below.
|
||||
|
||||
If you are running over the Andrew File System see the note below on
|
||||
USING NCURSES WITH AFS.
|
||||
|
||||
If you are cross-compiling, see the note below on BUILDING NCURSES WITH A
|
||||
CROSS-COMPILER.
|
||||
If you are cross-compiling, see the note below on BUILDING WITH A CROSS-COMPILER.
|
||||
|
||||
If you want to build the Ada95 binding, go to the Ada95 directory and
|
||||
follow the instructions there. The Ada95 binding is not covered below.
|
||||
@ -270,8 +266,8 @@ INSTALLATION PROCEDURE:
|
||||
YOU MAY NOT BE ABLE TO COMPILE (OR RUN) NCURSES APPLICATIONS WITH C++.
|
||||
|
||||
|
||||
SUMMARY OF CONFIGURE OPTIONS:
|
||||
----------------------------
|
||||
CONFIGURE OPTIONS:
|
||||
-----------------
|
||||
|
||||
The configure script provides a short list of its options when you type
|
||||
|
||||
@ -439,6 +435,31 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
Without some special effort, it will either fail to compile at all,
|
||||
or the compiler may find a different unctrl.h file.
|
||||
|
||||
In addition to the curses library, a system may provide its own
|
||||
versions of the add-on libraries (form, menu, panel), which would
|
||||
not be compatible with ncurses. These options allow you to rename
|
||||
ncurses' add-on libraries to avoid conflicts when linking:
|
||||
|
||||
--with-form-libname=XXX
|
||||
--with-menu-libname=XXX
|
||||
--with-panel-libname=XXX
|
||||
|
||||
Rather than renaming them abitrarily, a prefix or suffix is
|
||||
recommended. An "n" prefix provides consistency with ncurses versus
|
||||
curses, i.e.,
|
||||
|
||||
--with-form-libname=nform
|
||||
--with-menu-libname=nmenu
|
||||
--with-panel-libname=npanel
|
||||
|
||||
--disable-pkg-ldflags
|
||||
Omit options in $EXTRA_LDFLAGS from the pkg-config ".pc" and
|
||||
corresponding ncurses*-config script which normally are listed via
|
||||
the "--libs" option. These options are normally used to facilitate
|
||||
linking to ncurses when it was configured to use the rpath feature.
|
||||
|
||||
See also --enable-rpath and --disable-rpath-hack.
|
||||
|
||||
--disable-relink
|
||||
If --enable-rpath is given, the generated makefiles normally will
|
||||
rebuild shared libraries during install. Use this option to simply
|
||||
@ -561,6 +582,9 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
For testing, generate functions for certain macros to make them visible
|
||||
as such to the debugger. See also the --disable-macros option.
|
||||
|
||||
--enable-exp-win32
|
||||
When configuring for MinGW, use the experimental Windows 10 driver.
|
||||
|
||||
--enable-ext-colors
|
||||
Extend the cchar_t structure to allow more than 16 colors to be
|
||||
encoded. This applies only to the wide-character (--enable-widec)
|
||||
@ -587,6 +611,12 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
ncurses. This does not change the ABI (the binary interface seen by
|
||||
calling applications).
|
||||
|
||||
--enable-fvisibility
|
||||
Use the gcc "-fvisibility=hidden" option to make symbols which are not
|
||||
explicitly exported, "hidden". Doing this may reduce the number of
|
||||
symbols exported in the C++ binding; it should have less effect on the
|
||||
C libraries when symbol-versioning is used.
|
||||
|
||||
--enable-getcap
|
||||
Use the 4.4BSD getcap code if available, or a bundled version of it to
|
||||
fetch termcap entries. Entries read in this way cannot use (make
|
||||
@ -864,6 +894,9 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
Specify a suffix for the ncursesw6-config file, etc., used to work
|
||||
around conflicts with packages.
|
||||
|
||||
--with-cxx-libname=NAME
|
||||
Override the basename of the ncurses++ library (default: "ncurses++")
|
||||
|
||||
--with-cxx-shared
|
||||
When --with-shared is set, build libncurses++ as a shared library.
|
||||
This implicitly relies upon building with gcc/g++, since other
|
||||
@ -909,6 +942,9 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
|
||||
See also "--with-tic-path" and "--with-infocmp-path".
|
||||
|
||||
--with-form-libname=NAME
|
||||
Override the basename of the form library (default: "form")
|
||||
|
||||
--with-gpm
|
||||
use Alessandro Rubini's GPM library to provide mouse support on the
|
||||
Linux console. Prior to ncurses 5.5, this introduced a dependency on
|
||||
@ -1043,6 +1079,9 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
by running them through tbl to generate tables understandable by
|
||||
nroff.
|
||||
|
||||
--with-menu-libname=NAME
|
||||
Override the basename of the menu library (default: "menu")
|
||||
|
||||
--with-mmask-t=TYPE
|
||||
Override type of mmask_t, which stores the mouse mask. Prior to
|
||||
ncurses 5.5, this was always unsigned long, but with ncurses 5.5, it
|
||||
@ -1070,6 +1109,9 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
those using termcap, do not use the higher speeds. Your application
|
||||
(or system, in general) may or may not.
|
||||
|
||||
--with-panel-libname=NAME
|
||||
Override the basename of the panel library (default: "panel")
|
||||
|
||||
--with-pc-suffix=SUFFIX
|
||||
If ".pc" files are installed, optionally add a suffix to the files
|
||||
and corresponding package names to separate unusual configurations.
|
||||
@ -1328,8 +1370,8 @@ SUMMARY OF CONFIGURE OPTIONS:
|
||||
X11R5 and X11R6 xterm.
|
||||
|
||||
|
||||
COMPATIBILITY WITH OLDER VERSIONS OF NCURSES:
|
||||
--------------------------------------------
|
||||
COMPATIBILITY WITH OLDER RELEASES:
|
||||
---------------------------------
|
||||
|
||||
Because ncurses implements X/Open Curses, its interface is fairly stable.
|
||||
That does not mean the interface does not change. Changes are made to the
|
||||
@ -2053,8 +2095,8 @@ COMPATIBILITY WITH OLDER VERSIONS OF NCURSES:
|
||||
incorrect color scheme.
|
||||
|
||||
|
||||
IF YOU ARE A SYSTEM INTEGRATOR:
|
||||
------------------------------
|
||||
FOR SYSTEM INTEGRATORS:
|
||||
----------------------
|
||||
|
||||
Configuration and Installation:
|
||||
|
||||
@ -2130,7 +2172,7 @@ IF YOU ARE A SYSTEM INTEGRATOR:
|
||||
that will make users' lives easier rather than harder.
|
||||
|
||||
|
||||
RECENT XTERM VERSIONS:
|
||||
MODERN XTERM VERSIONS:
|
||||
---------------------
|
||||
|
||||
The terminfo database file included with this distribution assumes you
|
||||
@ -2146,9 +2188,13 @@ CONFIGURING FALLBACK ENTRIES:
|
||||
In order to support operation of ncurses programs before the terminfo
|
||||
tree is accessible (that is, in single-user mode or at OS installation
|
||||
time) the ncurses library can be compiled to include an array of
|
||||
pre-fetched fallback entries. This must be done on a machine which
|
||||
has ncurses' infocmp and terminfo database installed (as well as
|
||||
ncurses' tic and infocmp programs).
|
||||
pre-fetched fallback entries.
|
||||
|
||||
NOTE: This must be done on a machine which has ncurses' infocmp and
|
||||
terminfo database installed (as well as ncurses' tic and infocmp
|
||||
programs). That is because the fallback sources are generated and
|
||||
compiled into the library before the build-tree's copy of infocmp is
|
||||
available.
|
||||
|
||||
These entries are checked by setupterm() only when the conventional
|
||||
fetches from the terminfo tree and the termcap fallback (if configured)
|
||||
@ -2267,12 +2313,8 @@ terminfo directory directly.
|
||||
|
||||
------------------------------- CUT HERE --------------------------------
|
||||
|
||||
USING NCURSES WITH AFS:
|
||||
AFS treats each directory as a separate logical filesystem, you
|
||||
can't hard-link across them. The --enable-symlinks option copes
|
||||
with this by making tic use symbolic links.
|
||||
|
||||
USING NCURSES WITH GPM:
|
||||
USING GPM:
|
||||
---------
|
||||
Ncurses 4.1 and up can be configured to use GPM (General Purpose Mouse)
|
||||
which is used with Linux console. Be aware that GPM is commonly
|
||||
installed as a shared library which contains a wrapper for the curses
|
||||
@ -2291,7 +2333,9 @@ USING NCURSES WITH GPM:
|
||||
|
||||
https://invisible-island.net/ncurses/ncurses.faq.html#using_gpm_lib
|
||||
|
||||
BUILDING NCURSES WITH A CROSS-COMPILER
|
||||
|
||||
BUILDING WITH A CROSS-COMPILER:
|
||||
------------------------------
|
||||
Ncurses can be built with a cross-compiler. Some parts must be built
|
||||
with the host's compiler since they are used for building programs
|
||||
(e.g., ncurses/make_hash and ncurses/make_keys) that generate tables
|
||||
@ -2316,14 +2360,26 @@ BUILDING NCURSES WITH A CROSS-COMPILER
|
||||
When ncurses has been successfully cross-compiled, you may want to use
|
||||
"make install" (with a suitable target directory) to construct an
|
||||
install tree. Note that in this case (as with the --with-fallbacks
|
||||
option), ncurses uses the development platform's tic to do the
|
||||
"make install.data" portion.
|
||||
option), ncurses uses the development platform's tic to do the "make
|
||||
install.data" portion.
|
||||
|
||||
The system's tic program is used to install the terminal database,
|
||||
even for cross-compiles. For best results, the tic program should
|
||||
be from the most current version of ncurses.
|
||||
even for cross-compiles. For best results, the tic program should be
|
||||
from the most current version of ncurses.
|
||||
|
||||
BUGS:
|
||||
NOTE: the system's tic program may use a different terminfo database
|
||||
format than the target system. For instance, as described in term(5),
|
||||
the conventional terminfo layout uses a directory hierarchy with one
|
||||
letter names, while some platforms use two-letter names to work with
|
||||
case-insensitive filesystems. The configure script searches for a tic
|
||||
program using the AC_CHECK_TOOL macro, which will prefer programs
|
||||
using the canonical host prefix in their name. You can use this fact
|
||||
to provide a cross-compiler support utility tic, otherwise you can
|
||||
override the configure script's choice using --with-tic-path
|
||||
|
||||
|
||||
BUG REPORTS:
|
||||
-----------
|
||||
Send any feedback to the ncurses mailing list at
|
||||
bug-ncurses@gnu.org. To subscribe send mail to
|
||||
bug-ncurses-request@gnu.org with body that reads:
|
||||
|
11
MANIFEST
11
MANIFEST
@ -235,7 +235,6 @@
|
||||
./config.sub
|
||||
./configure
|
||||
./configure.in
|
||||
./convert_configure.pl
|
||||
./dist.mk
|
||||
./doc/hackguide.doc
|
||||
./doc/html/Ada95.html
|
||||
@ -547,6 +546,7 @@
|
||||
./include/MKterm.h.awk.in
|
||||
./include/Makefile.in
|
||||
./include/capdefaults.c
|
||||
./include/curses.events
|
||||
./include/curses.h.in
|
||||
./include/curses.tail
|
||||
./include/curses.wide
|
||||
@ -559,6 +559,7 @@
|
||||
./include/nc_string.h
|
||||
./include/nc_termios.h
|
||||
./include/nc_tparm.h
|
||||
./include/nc_win32.h
|
||||
./include/ncurses_cfg.hin
|
||||
./include/ncurses_defs
|
||||
./include/ncurses_dll.h.in
|
||||
@ -567,6 +568,7 @@
|
||||
./include/termcap.h.in
|
||||
./include/tic.h
|
||||
./include/unctrl.h.in
|
||||
./include/win32_curses.h
|
||||
./install-sh
|
||||
./man/MKada_config.in
|
||||
./man/MKncu_config.in
|
||||
@ -942,6 +944,8 @@
|
||||
./ncurses/tinfo/lib_tparm.c
|
||||
./ncurses/tinfo/lib_tputs.c
|
||||
./ncurses/tinfo/lib_ttyflags.c
|
||||
./ncurses/tinfo/lib_win32con.c
|
||||
./ncurses/tinfo/lib_win32util.c
|
||||
./ncurses/tinfo/make_hash.c
|
||||
./ncurses/tinfo/make_keys.c
|
||||
./ncurses/tinfo/name_match.c
|
||||
@ -998,6 +1002,7 @@
|
||||
./ncurses/widechar/widechars.c
|
||||
./ncurses/win32con/gettimeofday.c
|
||||
./ncurses/win32con/wcwidth.c
|
||||
./ncurses/win32con/win32_driver.c
|
||||
./ncurses/win32con/win_driver.c
|
||||
./package/debian-mingw/changelog
|
||||
./package/debian-mingw/compat
|
||||
@ -1089,6 +1094,7 @@
|
||||
./test/Makefile.in
|
||||
./test/README
|
||||
./test/aclocal.m4
|
||||
./test/back_ground.c
|
||||
./test/background.c
|
||||
./test/blue.c
|
||||
./test/bs.6
|
||||
@ -1123,6 +1129,7 @@
|
||||
./test/dots_xcurses.c
|
||||
./test/dump_window.c
|
||||
./test/dump_window.h
|
||||
./test/dup_field.c
|
||||
./test/echochar.c
|
||||
./test/edit_field.c
|
||||
./test/edit_field.h
|
||||
@ -1155,6 +1162,7 @@
|
||||
./test/mini.xterm_48x48.xpm
|
||||
./test/mk-test.awk
|
||||
./test/modules
|
||||
./test/move_field.c
|
||||
./test/movewindow.c
|
||||
./test/ncurses.c
|
||||
./test/ncurses_tst.hin
|
||||
@ -1212,6 +1220,7 @@
|
||||
./test/test_setupterm.c
|
||||
./test/test_sgr.c
|
||||
./test/test_termattrs.c
|
||||
./test/test_tparm.c
|
||||
./test/test_vid_puts.c
|
||||
./test/test_vidputs.c
|
||||
./test/testaddch.c
|
||||
|
469
NEWS
469
NEWS
@ -1,5 +1,5 @@
|
||||
-------------------------------------------------------------------------------
|
||||
-- Copyright 2018-2019,2020 Thomas E. Dickey --
|
||||
-- Copyright 2018-2020,2021 Thomas E. Dickey --
|
||||
-- Copyright 1998-2017,2018 Free Software Foundation, Inc. --
|
||||
-- --
|
||||
-- Permission is hereby granted, free of charge, to any person obtaining a --
|
||||
@ -26,7 +26,7 @@
|
||||
-- sale, use or other dealings in this Software without prior written --
|
||||
-- authorization. --
|
||||
-------------------------------------------------------------------------------
|
||||
-- $Id: NEWS,v 1.3450 2020/02/15 18:56:00 tom Exp $
|
||||
-- $Id: NEWS,v 1.3634 2021/02/21 00:18:55 tom Exp $
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
This is a log of changes that ncurses has gone through since Zeyd started
|
||||
@ -46,6 +46,469 @@ 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.
|
||||
|
||||
20210220
|
||||
+ improve tic warning when oc/op do not mention SGR 39/49 for xterm
|
||||
compatible XT flag.
|
||||
+ revert change to lib_addch.c in waddch_literal() from 20210130, since
|
||||
the followup fix in PutCharLR() actually corrects the problem while
|
||||
this change causes too-early filling/wrapping (report by Johannes
|
||||
Altmanninger).
|
||||
+ add/use vt220+pcedit and vt220+vtedit -TD
|
||||
+ add scrt/securecrt and absolute -TD
|
||||
+ add nel to xterm-new, though supported since X11R5 -TD
|
||||
+ add/use xterm+nofkeys -TD
|
||||
+ move use of ecma+italics from xterm-basic to xterm+nofkeys -TD
|
||||
|
||||
20210213
|
||||
+ add test/back_ground.c, to exercise the wide-character background
|
||||
functions.
|
||||
+ add a check in _nc_build_wch() in case the background character is a
|
||||
wide-character, rather than a new part of a multibyte character.
|
||||
+ improve tracemunch's coverage of form/menu/panel libraries.
|
||||
+ improve tracemunch's checking/reporting the type for the first
|
||||
parameter, e.g., "WINDOW*" rather than "#1".
|
||||
|
||||
20210206
|
||||
+ provide for wide-characters as background character in wbkgrnd
|
||||
(report/testcase by Anton Vidovic)
|
||||
+ add name for Fedora's pcre2 to configure check for "--with-pcre2"
|
||||
option, from xterm #363 -TD
|
||||
+ modify adjustment in PutCharLR to restore the cursor position before
|
||||
writing to the lower-right corner, rather than decrementing the
|
||||
cursor column, in case it was a double-width character (cf: 20210130).
|
||||
|
||||
20210130
|
||||
+ correct an off-by-one in comparison in waddch_literal() which caused
|
||||
scrolling when a double-cell character would not fit at the lower
|
||||
right corner of the screen (report by Benno Schulenberg).
|
||||
+ split-out att610+cvis, vt220+cvis, vt220+cvis8 -TD
|
||||
+ add vt220-base, for terminal emulators which generally have not
|
||||
supported att610's blinking cursor control -TD
|
||||
+ use vt220+cvis in vt220, etc -TD
|
||||
+ use att610+cvis, xterm+tmux and ansi+enq in kitty -TD
|
||||
+ use vt220+cvis in st, terminology, termite since they ignore
|
||||
blinking-cursor detail in att610+cvis -TD
|
||||
|
||||
20210123
|
||||
+ modify package/config scripts to provide an explicit -L option for
|
||||
cases when the loader search path has other directories preceding
|
||||
the one in which ncurses is installed (report by Yuri Victorovich).
|
||||
+ minor build-fixes in configure script and makefiles to work around
|
||||
quirks of pmake.
|
||||
|
||||
20210116
|
||||
+ add comment for linux2.6 regarding CONFIG_CONSOLE_TRANSLATIONS
|
||||
(report by Patrick McDermott) -TD
|
||||
+ make opts extension for getcchar work as documented for ncurses 6.1,
|
||||
adding "-g" flag to test/demo_new_pair to illustrate.
|
||||
|
||||
20210109
|
||||
+ fix errata in man/ncurses.3x from recent updates.
|
||||
+ improve quoting/escaping in configure script, uses some features of
|
||||
autoconf 2.52.20210105
|
||||
|
||||
20210102
|
||||
+ update man/curs_memleaks.3x, to include <term.h> which declares
|
||||
exit_terminfo.
|
||||
+ clarify man/curs_terminfo.3x, to mention why the macro setterm is
|
||||
defined in <curses.h>, and remove it from the list of prototypes
|
||||
(prompted by patch by Graeme McCutcheon).
|
||||
+ amend man/curs_terminfo.3x, to note that <curses.h> is required
|
||||
for certain functions, e.g., those using chtype or attr_t for
|
||||
types, as well as mvcur (cf: 20201031).
|
||||
+ use parameter-names in prototypes in curs_sp_funcs.3x, for
|
||||
consistency with other manpages.
|
||||
|
||||
20201227
|
||||
+ update terminology entry to 1.8.1 -TD
|
||||
+ fix some compiler-warnings which gcc8 reports incorrectly.
|
||||
|
||||
20201219
|
||||
+ suppress hyphenation in generated html for manpages, to address
|
||||
regression in upgrade of groff 1.22.2 to 1.22.3.
|
||||
+ fix inconsistent sort-order in see-also sections of manpages (report
|
||||
by Chris Bennett).
|
||||
|
||||
20201212
|
||||
+ improve manual pages for form field-types.
|
||||
|
||||
20201205
|
||||
+ amend build-fixes for gnat 10 to work with certain systems lacking
|
||||
gprbuild (cf: 20200627).
|
||||
+ eliminate an additional strlen and wsclen.
|
||||
+ eliminate an unnecessary strlen in waddnstr() (suggested by Benjamin
|
||||
Abendroth).
|
||||
+ modify inopts manpage, separating the items for nodelay and notimeout
|
||||
(patch by Benno Schulenberg).
|
||||
+ correct mlterm3 kf1-kf4 (Debian #975322) -TD
|
||||
+ add flash to mlterm3 -TD
|
||||
|
||||
20201128
|
||||
+ add Smulx to alacritty (Christian Duerr).
|
||||
+ add rep to PuTTY -TD
|
||||
+ add putty+keypad -TD
|
||||
+ add another fflush(stdout) in _nc_flush() to handle time-delays in
|
||||
the middle of strings such as flash when the application uses
|
||||
low-level calls rather than curses (cf: 20161217).
|
||||
+ modify configure check for c89/c99 aliases of clang to use its
|
||||
-std option instead, because some platforms, in particular macOS,
|
||||
do not provide workable c89/c99 aliases.
|
||||
|
||||
20201121
|
||||
+ fix some compiler-warnings in experimental Windows-10 driver.
|
||||
+ add the definitions needed in recent configure-check for clang
|
||||
(report by Steven Pitman).
|
||||
|
||||
20201114
|
||||
+ fix some compiler-warnings in experimental Windows-10 driver.
|
||||
+ modify a check for parameters in terminfo capabilities to handle the
|
||||
special case where short extended capability strings were not
|
||||
converted from terminfo to termcap format.
|
||||
+ modify CF_MIXEDCASE_FILENAMES macro, adding darwin as special case
|
||||
when cross-compiling (report by Eli Rykoff).
|
||||
|
||||
20201107
|
||||
+ update kitty+common -TD
|
||||
+ add putty+screen and putty-screen (suggested by Alexandre Montaron).
|
||||
+ explain in ncurses.3x that functions in the tinfo library do not rely
|
||||
upon wide-characters (prompted by discussion with Reuben Thomas).
|
||||
|
||||
20201031
|
||||
+ modify MKterm.h.in so that it is not necessary to include <curses.h>
|
||||
before <term.h> (prompted by discussion with Reuben Thomas).
|
||||
+ review/improve synopsis for curs_sp_funcs.3x (prompted by discussion
|
||||
with Reuben Thomas).
|
||||
+ improve format of output in tic's check_infotocap() function, to
|
||||
ensure that the messages contain only printable text.
|
||||
+ modify configure-check for clang to verify that -Qunused-arguments
|
||||
is supported. IBM's xlclang does not support it (report by Steven
|
||||
Pitman).
|
||||
|
||||
20201024
|
||||
+ provide workaround configure-check for bool when cross-compiling.
|
||||
+ fix a potential indexing error in _nc_parse_entry(), seen with
|
||||
Herlim's test data using address-sanitizer.
|
||||
+ change a null-pointer check in set_curterm to a valid-string check,
|
||||
needed in to tic's use-resolution when pad_char is cancelled
|
||||
(report/testcase by Robert Sebastian Herlim)
|
||||
+ improve tic's -c option to validate the number and type of parameters
|
||||
and compare against expected number/type before deciding which set of
|
||||
parameter-lists to use in tparm calls (report/testcase by Robert
|
||||
Sebastian Herlim).
|
||||
+ fix a link for tabs.1 manpage in announce.html.in (report by Nick
|
||||
Black), as well as some fixes via linklint.
|
||||
|
||||
20201017
|
||||
+ improve manpage typography.
|
||||
+ improve discussion in curs_addch.3x of the use of unctrl to display
|
||||
nonprintable characters.
|
||||
+ add a note in terminfo.5 explaining that no-parameter strings such
|
||||
as sgr0 or cnorm should not be used with tparm.
|
||||
|
||||
20201010
|
||||
+ correct sgr in aaa+rv (report by Florian Weimer) -TD
|
||||
+ fix some sgr inconsistencies in d230c, ibm6153, ibm6154,
|
||||
ncrvt100an -TD
|
||||
+ improve tic's check for errors detected in tparm (prompted by
|
||||
discussion with Florian Weimer).
|
||||
+ set output-mode to binary in experimental Windows-10 driver (Juergen
|
||||
Pfeifer).
|
||||
|
||||
20201003
|
||||
+ remove output-related checks for nl/nonl (report by Leon Winter).
|
||||
+ change tmux's kbs to ^? (report by Premysl Eric Janouch)
|
||||
+ simplify mlterm initialization with DECSTR -TD
|
||||
+ fix a typo in man/curs_terminfo.3 (Reuben Thomas).
|
||||
+ add tmux-direct (tmux #2370, Debian #895754)
|
||||
+ add user-defined capabilities from mintty to Caps-ncurses, for
|
||||
checking consistency with tic.
|
||||
|
||||
20200926
|
||||
+ correct configure-check for gnurx library.
|
||||
+ regenerate llib-* files.
|
||||
+ modify tracemunch and the panel library to show readable traces for
|
||||
panel- and user-pointers.
|
||||
|
||||
20200919
|
||||
+ update mlterm3 for 3.9.0 (report by Premysl Eric Janouch) -TD
|
||||
|
||||
20200918
|
||||
+ corrected condition for appending curses.events to the generated
|
||||
curses.h (report by Sven Joachim, Debian #970545).
|
||||
|
||||
20200912
|
||||
+ add configure-check for systre/tre with mingw configuration, to get
|
||||
the library-dependencies as seen in msys2 configuration for mingw64.
|
||||
+ build-fixes for the win32-driver configuration.
|
||||
+ use more defensive binary mode setting for Win32 (Juergen Pfeifer).
|
||||
|
||||
20200907
|
||||
+ fix regression in setupterm validating non-empty $TERM (report by
|
||||
Soren Tempel).
|
||||
|
||||
20200906
|
||||
+ merge/adapt in-progress work by Juergen Pfeifer for new version of
|
||||
win32-driver.
|
||||
+ correct description of vt330/vt340 (Ross Combs).
|
||||
|
||||
20200831
|
||||
+ build-fix for awk-scripts modified for win32-driver (report by Werner
|
||||
Fink).
|
||||
|
||||
20200829
|
||||
+ remove a redundant NCURSES_EXPORT as a build-fix for "Maarten
|
||||
Anonymous".
|
||||
+ merge/adapt in-progress work by Juergen Pfeifer for new version of
|
||||
win32-driver.
|
||||
+ modify configure script, moving gcc -Werror options to EXTRA_CFLAGS
|
||||
to avoid breaking configure-checks (adapted from ongoing work on
|
||||
mawk and lynx).
|
||||
> errata for terminfo.src (report by Florian Weimer):
|
||||
+ correct icl6404 csr
|
||||
+ correct ti916 cup
|
||||
+ improve ndr9500
|
||||
|
||||
20200822
|
||||
+ improve version-number extraction in MKlib_gen.sh
|
||||
+ make the test-package for manpages installable by adjusting the
|
||||
man_db.renames file.
|
||||
+ correct an off-by-one loop-limit in convert_strings function
|
||||
(report by Yue Tai).
|
||||
+ add CF_SHARED_OPTS cases for HPE NonStop systems (Randall S Becker).
|
||||
+ modify CF_SHARED_OPTS case for NetBSD to use the same "-shared"
|
||||
option for the non-rpath case as for the rpath case, to allow gcc to
|
||||
provide suitable runtime initialization (report by Rajeev V Pillai).
|
||||
|
||||
20200817
|
||||
+ reduce build-warnings by excluding ncurses-internals from deprecation
|
||||
warnings.
|
||||
+ mark wgetch-events feature as deprecated.
|
||||
+ add definition for $(LIBS) to ncurses/Makefile.in, to simplify builds
|
||||
using the string-hacks option.
|
||||
+ prevent KEY_EVENT from appearing in curses.h unless the configure
|
||||
option --enable-wgetch-events is used (report by Werner Fink).
|
||||
|
||||
20200816
|
||||
+ amend tic/infocmp check to allow for the respective tool's absence
|
||||
(report by Steve Wills, cf: 20200808).
|
||||
+ improved some of the build-scripts with shellcheck
|
||||
+ filter out -MT/-MD/-MTd/-MDd options in script for Visual Studio C++
|
||||
(discussion with "Maarten Anonymous").
|
||||
|
||||
20200808
|
||||
+ improve discussion of the system's tic utility when used as part
|
||||
of cross-compiling (discussion with Keith Marshall).
|
||||
+ modify configuration checks for build-time tic/infocmp to use
|
||||
AC_CHECK_TOOL. That can still be overridden by --with-tic-path and
|
||||
--with-infocmp-path when fallbacks are used, but even if not using
|
||||
fallbacks, the improved check may help with cross-compiling
|
||||
(discussion with Keith Marshall).
|
||||
+ other build-fixes for Ada95 with MinGW.
|
||||
+ modify Ada95 source-generation utility to write to a file given as
|
||||
parameter rather than to the standard output, allowing builds with
|
||||
MinGW.
|
||||
|
||||
20200801
|
||||
+ remove remaining parts of checks for ISC Unix (cf: 20121006).
|
||||
+ add user32.lib to LDFLAGS for Visual Studio C++ configuration
|
||||
(discussion with "Maarten Anonymous").
|
||||
+ modify MKkey_defs.sh to hide ncurses' definition of KEY_EVENTS to
|
||||
reduce Visual Studio C++ redefinition warnings.
|
||||
+ improve/update checks for external functions in test/configure
|
||||
|
||||
20200725
|
||||
+ set LINK_TESTS in CF_SHARED_OPTS for msvc (patch by
|
||||
"Maarten Anonymous")
|
||||
+ improved workaround for redefinition-warnings for KEY_EVENT.
|
||||
+ improve man/term.5 section on legacy storage format (report by
|
||||
Florian Weimer).
|
||||
|
||||
20200718
|
||||
+ reduce redefinition-warnings for KEY_EVENT when building with Visual
|
||||
Studio C++.
|
||||
+ define NCURSES_STATIC when compiling programs to link with static
|
||||
libraries, to work with MinGW vs Visual Studio C++.
|
||||
> additional changes for building with Visual Studio C++ and msys2
|
||||
(reports/patches by "Maarten Anonymous")
|
||||
+ modify c++/Makefile.in to set the current directory while compiling
|
||||
the main program, so the linker can find related objects.
|
||||
+ several changes to allow the c++/demo program to compile/link.
|
||||
+ change an ifdef in test-directory, to use VC++ wide-character funcs.
|
||||
|
||||
20200711
|
||||
+ fix pound-sign mapping in acsc of linux2.6 entry (report by Ingo
|
||||
Bruckl).
|
||||
+ additional changes for building with Visual Studio C++ and msys2
|
||||
(reports/patches by "Maarten Anonymous")
|
||||
+ build-improvements for Windows 10 and MinGW (patch by Juergen
|
||||
Pfeifer).
|
||||
+ fix a typo in curs_printw.3x (patch by William Pursell).
|
||||
+ fix two errors in infotocap which allowed indexing outside the
|
||||
buffer (report/testcases by Zhang Gan).
|
||||
+ update length of strings in infocmp's usage function to restore a
|
||||
trailing null on the longest string (report/testcase by Zhang Gen).
|
||||
|
||||
20200704
|
||||
+ modify version-check with Ada generics to use the same pattern as in
|
||||
the check for supported gnat versions (report by Pascal Pignard).
|
||||
> additional changes for building with Visual Studio C++ and msys2
|
||||
(patches by "Maarten Anonymous"):
|
||||
+ adjust headers/declarations to provide for "dllimport" vs "dllexport"
|
||||
declarations when constructing DLLs, to worko with Visual Studio C++.
|
||||
|
||||
20200627
|
||||
+ build-fixes for gnat 10.1.1, whose gnatmake drops integration with
|
||||
gprbuild.
|
||||
+ correct buffer-length in test/color_name.h
|
||||
|
||||
20200613
|
||||
+ update list of functions in ncurses.3x
|
||||
+ move dlclose() call from lib_mouse.c to delscreen() to avoid a case
|
||||
in the former which could be called from SIGTSTP handler (Debian
|
||||
#961097).
|
||||
|
||||
20200606
|
||||
+ add xterm+256color2, xterm+88color2, to deprecate nonstandard usage
|
||||
in xterm+256color, xterm+88color -TD
|
||||
+ add shifted Linux console keys in linux+sfkeys entry for
|
||||
screen.linux (report by Alexandre Montaron).
|
||||
+ use vt100+enq in screen (report by Alexandre Montaron).
|
||||
+ add screen.linux-s alias (suggested by Alexandre Montaron).
|
||||
|
||||
20200531
|
||||
+ correct configure version-check/warnng for g++ to allow for 10.x
|
||||
+ re-enable "bel" in konsole-base (report by Nia Huang)
|
||||
+ add linux-s entry (patch by Alexandre Montaron).
|
||||
+ drop long-obsolete convert_configure.pl
|
||||
+ add test/test_parm.c, for checking tparm changes.
|
||||
+ improve parameter-checking for tparm, adding function _nc_tiparm() to
|
||||
handle the most-used case, which accepts only numeric parameters
|
||||
(report/testcase by "puppet-meteor").
|
||||
+ use a more conservative estimate of the buffer-size in lib_tparm.c's
|
||||
save_text() and save_number(), in case the sprintf() function
|
||||
passes-through unexpected characters from a format specifier
|
||||
(report/testcase by "puppet-meteor").
|
||||
+ add a check for end-of-string in cvtchar to handle a malformed
|
||||
string in infotocap (report/testcase by "puppet-meteor").
|
||||
|
||||
20200523
|
||||
+ update version-check for gnat to allow for gnat 10.x to 99.x
|
||||
+ fix an uninitialized variable in lib_mouse.c changes (cf: 20200502)
|
||||
+ add a check in EmitRange to guard against repeat_char emitting digits
|
||||
which could be interpreted as BSD-style padding when --enable-bsdpad
|
||||
is configured (report/patch by Hiltjo Posthuma).
|
||||
+ add --disable-pkg-ldflags to suppress EXTRA_LDFLAGS from the
|
||||
generated pkg-config and ncurses*-config files, to simplify
|
||||
configuring in the case where rpath is used but the packager wants
|
||||
to hide the feature (report by Michael Stapelberg).
|
||||
> fixes for building with Visual Studio C++ and msys2 (patches by
|
||||
"Maarten Anonymous"):
|
||||
+ modify CF_SHARED_OPTS to generate a script which translates linker
|
||||
options into Visual Studio's dialect.
|
||||
+ omit parentheses around function-names in generated lib_gen.c to
|
||||
work around a Visual Studio C++ limitation.
|
||||
|
||||
20200516
|
||||
+ add notes on termcap.h header in curs_termcap.3x
|
||||
+ update notes on vscode / xterm.js -TD
|
||||
|
||||
20200509
|
||||
+ add "-r" option to the dots test-programs, to help with scripting
|
||||
a performance comparison.
|
||||
+ build-fix test/move_field.c for NetBSD curses, whose form headers
|
||||
use different names than SVr4 or ncurses.
|
||||
|
||||
20200502
|
||||
+ add details on the change to Linux SGR 21 in 2018 -TD
|
||||
+ add xterm-direct16 and xterm-direct256 -TD
|
||||
+ modify lib_mouse.c to check for out-of-range button numbers, convert
|
||||
those to position reports.
|
||||
|
||||
20200425
|
||||
+ use vt100+fnkeys in putty -TD
|
||||
+ fix a typo in tput.1; "columns" should be "cols".
|
||||
|
||||
20200418
|
||||
+ improve tracemunch logic for "RUN" compaction.
|
||||
+ fix a special case in wresize() where copying the old text did not
|
||||
check if the last cell on a row was the beginning of a fullwidth
|
||||
character (adapted from patch by Benno Schulenberg).
|
||||
+ use vt52+keypad in xterm-vt52, from xterm #354 -TD
|
||||
+ improve see-also section of user_caps.5
|
||||
|
||||
20200411
|
||||
+ fix find_pair(), overlooked when refactoring for _nc_reserve_pairs()
|
||||
(report/testcase by Brad Town, cf: 20170812).
|
||||
+ add a trailing null for magic-string in putwin, flagged by gcc 10
|
||||
+ update check for gcc version versus gnat to work with gcc 10.x
|
||||
|
||||
20200404
|
||||
+ modify -fvisibility check to work with g++
|
||||
> fixes for building with Visual Studio C++ and msys2 (patches by
|
||||
"Maarten Anonymous"):
|
||||
+ add configure option and check for gcc -fvisibility=hidden feature
|
||||
+ define NCURSES_NOMACROS in lib_gen.c to work around Visual Studio
|
||||
C++ preprocessor limitations.
|
||||
+ modify some of the configure-macros, as well as mk-1st.awk to work
|
||||
with Visual Studio C++ default filenaming.
|
||||
|
||||
20200328
|
||||
+ correct length of buffer copied in dup_field().
|
||||
+ remove "$(srcdir)/" from path of library.gpr, needed for out-of-tree
|
||||
builds of Ada95 (patch by Adam Van Ymeren).
|
||||
|
||||
20200321
|
||||
+ improve configure-checks to reduce warnings about unused variables.
|
||||
+ improve description of error-returns in waddch and waddnstr manual
|
||||
pages (prompted by patch by Benno Schulenberg).
|
||||
+ add test/move_field.c to demonstrate move_field(), and a stub for
|
||||
a corresponding demo of dup_field().
|
||||
|
||||
20200314
|
||||
+ add history note to curs_scanw.3x for <stdarg.h> and <varargs.h>
|
||||
+ add history note to curs_printw.3x for <stdarg.h> and <varargs.h>
|
||||
+ add portability note to ncurses.3x regarding <stdarg.h>
|
||||
|
||||
20200308
|
||||
+ update copyright notices in test-packages.
|
||||
+ modify tracemunch to guard against errors in its known_p1 table.
|
||||
+ add several --with-xxx-libname options, to help with pkgsrc (prompted
|
||||
by discussion with Thomas Klausner).
|
||||
|
||||
20200301
|
||||
+ modify wbkgd() and wbkgrnd() to avoid storing a null in the
|
||||
background character, because it may be used in cases where the
|
||||
corresponding 0x80 is not treated as a null (report by Marc Rechte,
|
||||
cf: 20181208).
|
||||
|
||||
20200229
|
||||
+ modify CF_NCURSES_CONFIG to work around xcode's c99 "-W" option,
|
||||
which conflicts with conventional use for passing linker options.
|
||||
> fixes for building with Visual Studio C++ and msys2 (patches by
|
||||
"Maarten Anonymous"):
|
||||
+ check for pcre2posix.h instead of pcre2-posix.h
|
||||
+ add case in CF_SHARED_OPTS for msys2 + msvc
|
||||
+ add fallback definition for STDIN_FILENO in progs.priv.h
|
||||
+ modify win_driver.c to use _alloca() rather than gcc's variable
|
||||
length array feature.
|
||||
+ add NCURSES_IMPEXP to ncurses wrapped-variable declarations
|
||||
+ remove NCURSES_IMPEXP from class variables in c++/cursslk.h
|
||||
+ remove fallback prototype for exit() from c++/etip.h.in
|
||||
+ use configured check for <sys/time.h> in a couple of places
|
||||
+ conditionally include winsock.h in ncurses/win32con/gettimeofday.c,
|
||||
because Visual Studio needs this for the timestruct declaration.
|
||||
+ adjust syntax in a couple of files using the NCURSES_API symbol.
|
||||
|
||||
20200222
|
||||
+ expanded note in ncurses.3x regarding automatically-included headers
|
||||
+ improve vt50h and vt52 based on DECScope manual -TD
|
||||
+ add/use vt52+keypad and vt52-basic -TD
|
||||
+ check/workaround for line-too-long in Ada95 generate utility when
|
||||
building out-of-tree.
|
||||
+ improve/update HEADER_DEPS in */Makefile.in
|
||||
+ add "check" rule to include/Makefile, to demonstrate that the headers
|
||||
include all of the required headers for the types used.
|
||||
|
||||
20200215
|
||||
+ improve manual page for panel library, extending the portability
|
||||
section as well as documenting error-returns.
|
||||
@ -220,7 +683,7 @@ it is not possible to add this information.
|
||||
+ build-fixes for Ada95 configure-script and corresponding test package
|
||||
|
||||
20190907
|
||||
+ add --with-ada-libname option and modify Ada95 configuration to
|
||||
+ add --with-ada-libname option and modify Ada95 configuration to
|
||||
allow renaming the "AdaCurses" library (prompted by proposed changes
|
||||
by Pascal Pignard).
|
||||
+ modify configure script to distinguish gcc from icc and clang when
|
||||
|
139
README.MinGW
139
README.MinGW
@ -26,114 +26,123 @@
|
||||
-- sale, use or other dealings in this Software without prior written --
|
||||
-- authorization. --
|
||||
-------------------------------------------------------------------------------
|
||||
-- $Id: README.MinGW,v 1.10 2020/02/02 23:34:34 tom Exp $
|
||||
-- $Id: README.MinGW,v 1.14 2020/09/06 22:22:44 tom Exp $
|
||||
-- Author: Juergen Pfeifer
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
This is work in progress, but it's in an state where one can see it
|
||||
This is work in progress, but it is in an state where one can see it
|
||||
works at least on the Windows Console.
|
||||
|
||||
You should install the MSYS package, so that you've a shell environment that
|
||||
allows you to run the scripts, especially configure etc. You can get that
|
||||
from http://www.mingw.org
|
||||
You should install the MSYS2 package, so that you have a shell environment that
|
||||
allows you to run scripts, especially configure, etc. You can get that
|
||||
from
|
||||
https://www.msys2.org/
|
||||
|
||||
To build ncurses for native Windows, you need the MinGW toolchain. The
|
||||
original MinGW toolchain from the above site is only for 32-Bit Windows. As
|
||||
Windows Server - and also regular workstations - are moving to 64-Bit, it
|
||||
seems to be reasonable to have a toolchain that supports both architectures.
|
||||
I recommend to use the TDM gcc toolchain which you can find at
|
||||
http://tdm-gcc.tdragon.net/download. Go to the download section and select
|
||||
the bundle installer for tdm64 (MinGW-w64). This installs a multilib version
|
||||
of the gcc toolchain that can compile for native 32- and 64-Bit Windows
|
||||
versions. It also comes with a working pthread implementation.
|
||||
or the individual packages from
|
||||
|
||||
The latest config and build scripts we use for MinGW have only been tested
|
||||
for the gcc-4.6.1 compiler toolchain (or better).
|
||||
https://sourceforge.net/projects/msys2/files/
|
||||
|
||||
Using MinGW is a pragmatic decision, it's the easiest way to port this
|
||||
You may also use a hosted MinGW cross-compile toolchain, e.g., on Ubuntu or
|
||||
ArchLinux to build the libraries and tools.
|
||||
|
||||
To build ncurses for native Windows with support for the new Windows 10 Virtual
|
||||
Terminal and PseudoConsole support, you should install at least version 8.0 of
|
||||
the mingw-w64-x86_64-headers package as it appears to have support for the
|
||||
required Windows SDK level. Please note that some of the Linux distributions
|
||||
are a bit behind with respect to the required MinGW header versions and you may
|
||||
not be able to properly build the libraries for current Windows 10 using these
|
||||
toolchains. Although it is a bit slow, MSYS2 on Windows 10 64-Bit is the
|
||||
authoritative build environment for the MinGW version of ncurses.
|
||||
|
||||
Using MinGW is a pragmatic decision, it is the easiest way to port this
|
||||
heavily UNIX based sourcebase to native Windows. The goal is of course
|
||||
to provide the includes, libraries and DLLs to be used with the more
|
||||
common traditional development environments on Windows, mainly with
|
||||
Microsoft Visual Studio.
|
||||
|
||||
The TERM environment variable must be set specially to active the Windows
|
||||
The TERM environment variable must be set especially to activate the Windows
|
||||
console-driver. The driver checks if TERM is set to "#win32con" (explicit
|
||||
use) or if TERM is unset or empty (implicit).
|
||||
|
||||
Please also make sure that MSYS links to the correct directory containing
|
||||
your MinGW toolchain. For TDM this is usually C:\MinGW64. In your Windows
|
||||
CMD.EXE command shell go to the MSYS root directory (most probably
|
||||
C:\MSYS or C:\MSYS\1.0) and verify, that there is a junction point mingw
|
||||
that points to the MinGW toolchain directory. If not, delete the mingw
|
||||
directory and use the mklink command (or the linkd.exe utility on older
|
||||
Windows) to create the junction point.
|
||||
Beginning with build 17763 (Fall 2018 update), Windows 10 supports ANSI escape
|
||||
sequences (Virtual Terminal support). If ncurses detects this or a later
|
||||
Windows 10 version, the interpretation of the implicit TERM setting (which
|
||||
means: TERM is not set or empty) changes. In this case, TERM is to be assumed
|
||||
to be "ms-terminal" and ncurses acts using the regular terminfo based driver,
|
||||
thus acting like a regular Terminal we all know from UNIX like environments.
|
||||
|
||||
This code requires WindowsNT 5.1 or better, which means on the client
|
||||
Windows XP or better, on the server Windows Server 2003 or better.
|
||||
This code requires WindowsNT 6.0 or better, which means on the client
|
||||
Windows Vista or better, on the server Windows Server 2008 or better.
|
||||
|
||||
I recommend using libtool to build ncurses on MinGW, because libtool
|
||||
knows exactly how to build dll's on Windows for use with MinGW.
|
||||
If running on Windows 10 Build 17763 or later is detected, any program
|
||||
spawning a subprocess running a ncurses program should use the new
|
||||
PseudoConsole support, which provides what we know as pty from the UNIX
|
||||
world also for Windows. Using the CreatePseudoConsole API
|
||||
(see https://docs.microsoft.com/en-us/windows/console/createpseudoconsole)
|
||||
in the calling process, it is guaranteed that the called ncurses program has
|
||||
a console that is required by its implementation, even if the calling program
|
||||
is NOT a console program, e.g., MSYS2's own mintty Terminal emulator.
|
||||
|
||||
In the current MSYS2/minGW setup, building MinGW shared libraries with
|
||||
libtool for ncurses seems to be broken, so I recommend NOT to use libtool.
|
||||
|
||||
To build a modern but still small footprint ncurses that provides
|
||||
hooks for interop, I recommend using these options:
|
||||
|
||||
--with-libtool
|
||||
--disable-home-terminfo
|
||||
--enable-database
|
||||
--disable-termcap
|
||||
--enable-sp-funcs
|
||||
--enable-term-driver
|
||||
--enable-interop
|
||||
--without-libtool
|
||||
--disable-home-terminfo
|
||||
--enable-database
|
||||
--disable-termcap
|
||||
--enable-sp-funcs
|
||||
--enable-term-driver
|
||||
--enable-interop
|
||||
|
||||
This is the configuration commandline as I'm using it at the moment (assuming
|
||||
environment variable MINGW_ROOT to hold the root directory name of your MinGW
|
||||
build):
|
||||
This is the configuration command line which I am using at the moment
|
||||
(assuming environment variable MINGW_ROOT holds the root directory name of
|
||||
your MinGW build):
|
||||
|
||||
./configure \
|
||||
--prefix=$MINGW_ROOT \
|
||||
--with-cxx \
|
||||
--prefix=/mingw64 \
|
||||
--without-cxx \
|
||||
--without-ada \
|
||||
--enable-warnings \
|
||||
--enable-assertions \
|
||||
--enable-exp-win32 \
|
||||
--enable-ext-funcs \
|
||||
--disable-home-terminfo \
|
||||
--disable-echo \
|
||||
--disable-getcap \
|
||||
--disable-hard-tabs \
|
||||
--disable-leaks \
|
||||
--disable-macros \
|
||||
--disable-overwrite \
|
||||
--enable-opaque-curses \
|
||||
--enable-opaque-panel \
|
||||
--enable-opaque-menu \
|
||||
--enable-opaque-form \
|
||||
--enable-database \
|
||||
--enable-sp-funcs \
|
||||
--enable-term-driver \
|
||||
--enable-interop \
|
||||
--disable-termcap \
|
||||
--enable-database \
|
||||
--with-progs \
|
||||
--with-libtool \
|
||||
--without-libtool \
|
||||
--enable-pc-files \
|
||||
--mandir=$MINGW_ROOT/share/man
|
||||
--with-shared \
|
||||
--with-normal \
|
||||
--without-debug \
|
||||
--with-fallbacks=ms-terminal \
|
||||
--without-manpages
|
||||
|
||||
Please note that it is also necessary to set this environment variable:
|
||||
|
||||
export PATH_SEPARATOR=";"
|
||||
|
||||
in order to parse the terminfo paths correctly. Terminfo paths should
|
||||
always be separated by a seeeemicolon,even when running under MSYS.
|
||||
|
||||
To support regular expressions properly, ncurses under MinGW should be
|
||||
linked against the gnurx regex library, which must be built separately
|
||||
under MinGW. See
|
||||
|
||||
ftp.gnome.org/pub/GNOME/binaries/win32/dependencies/libgnurx-src-2.5.zip
|
||||
always be separated by a semicolon, even when running under MSYS2.
|
||||
|
||||
All the options above are - like the whole Windows support -
|
||||
experimental.
|
||||
|
||||
A lot is still TODO, e.g.:
|
||||
|
||||
- Wide Character support (display is workable, but input untested)
|
||||
The Win32Con driver should actually only use Unicode in the
|
||||
future.
|
||||
- Thread support (locking). If using TDM toolchain this is done by
|
||||
configuring pthreads.
|
||||
- A GUI console driver
|
||||
- Support for Terminals attached via a serial port (via terminfo)
|
||||
- Support for networked Terminal connections (via terminfo)
|
||||
- Workarounds for MinGW's filesystem access are necessary to make infocmp
|
||||
work (though tic works).
|
||||
|
||||
To support terminfo, we would need to have an ioctl() simulation for the
|
||||
serial and networked terminals.
|
||||
-- vile:txtmode
|
||||
|
1536
aclocal.m4
vendored
1536
aclocal.m4
vendored
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$Id: announce.html.in,v 1.96 2020/02/09 21:50:48 tom Exp $
|
||||
$Id: announce.html.in,v 1.99 2020/10/19 08:18:12 tom Exp $
|
||||
****************************************************************************
|
||||
* Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
* *
|
||||
@ -344,7 +344,7 @@
|
||||
|
||||
<li>
|
||||
<p>marked <a href=
|
||||
"@HOMEPAGE@/man/curs_printw.3x.html#h3-PORTABILITY"><tt>vwprintw</tt></a>
|
||||
"@HOMEPAGE@/man/curs_printw.3x.html#h2-PORTABILITY"><tt>vwprintw</tt></a>
|
||||
and <tt>vwscanw</tt> as deprecated; recommend using <a href=
|
||||
"@HOMEPAGE@/man/curs_printw.3x.html"><tt>vw_printw</tt></a>
|
||||
and <tt>vw_scanw</tt>, respectively.</p>
|
||||
@ -504,7 +504,7 @@
|
||||
<h3><a name="h3-programs" id="h3-programs">Program
|
||||
improvements</a></h3>
|
||||
|
||||
<p>Several improvements were made to the utility programs:</p>
|
||||
<p id="h4-utilities">Several improvements were made to the utility programs:</p>
|
||||
|
||||
<dl>
|
||||
<dt><span class="part-name">clear</span>
|
||||
@ -1051,7 +1051,7 @@
|
||||
for decompiling descriptions. That came later, with SVr3,
|
||||
with a different developer.</li>
|
||||
|
||||
<li><a href="@HOMEPAGE@/man/tabs.1">tabs.1</a> tells more
|
||||
<li><a href="@HOMEPAGE@/man/tabs.1.html">tabs.1</a> tells more
|
||||
than you wanted to know about the tool.</li>
|
||||
|
||||
<li><a href="@HOMEPAGE@/man/tic.1m.html">tic.1</a> explains
|
||||
@ -1092,7 +1092,7 @@
|
||||
characters.</li>
|
||||
|
||||
<li><a href=
|
||||
"@HOMEPAGE@/man/curs_color.3x.html#h3-RETURN-VALUE">curs_color.3x</a>
|
||||
"@HOMEPAGE@/man/curs_color.3x.html#h2-RETURN-VALUE">curs_color.3x</a>
|
||||
improves discussion of error returns and extensions.</li>
|
||||
|
||||
<li><a href=
|
||||
|
@ -1,6 +1,6 @@
|
||||
# $Id: Makefile.in,v 1.119 2020/02/02 23:34:34 tom Exp $
|
||||
# $Id: Makefile.in,v 1.128 2021/01/23 20:42:08 tom Exp $
|
||||
##############################################################################
|
||||
# Copyright 2018,2020 Thomas E. Dickey #
|
||||
# Copyright 2018-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1998-2015,2016 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -89,7 +89,7 @@ CXXFLAGS = @CXXFLAGS@ @EXTRA_CXXFLAGS@
|
||||
CXXLIBS = @CXXLIBS@
|
||||
|
||||
INCDIR = ../include
|
||||
CPPFLAGS = -DHAVE_CONFIG_H -I../c++ @CPPFLAGS@
|
||||
CPPFLAGS = -DHAVE_CONFIG_H -DBUILDING_NCURSES_CXX -I../c++ @CPPFLAGS@
|
||||
|
||||
CTAGS = @CTAGS@
|
||||
ETAGS = @ETAGS@
|
||||
@ -98,9 +98,9 @@ CC = ${CXX}
|
||||
CCFLAGS = $(CPPFLAGS) $(CXXFLAGS)
|
||||
|
||||
CFLAGS_LIBTOOL = $(CCFLAGS)
|
||||
CFLAGS_NORMAL = $(CCFLAGS)
|
||||
CFLAGS_DEBUG = $(CCFLAGS) @CXX_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -pg
|
||||
CFLAGS_NORMAL = $(CCFLAGS) -DNCURSES_STATIC
|
||||
CFLAGS_DEBUG = $(CCFLAGS) -DNCURSES_STATIC @CXX_G_OPT@ -DTRACE
|
||||
CFLAGS_PROFILE = $(CCFLAGS) -DNCURSES_STATIC -pg
|
||||
CFLAGS_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@
|
||||
|
||||
CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
|
||||
@ -114,7 +114,11 @@ LOCAL_LIBDIR = @top_builddir@/lib
|
||||
|
||||
LINK = @LINK_PROGS@ $(LIBTOOL_LINK) @CXXLDFLAGS@
|
||||
SHLIB_DIRS = -L../lib
|
||||
SHLIB_LIST = $(SHLIB_DIRS) -lform@USE_LIB_SUFFIX@ -lmenu@USE_LIB_SUFFIX@ -lpanel@USE_LIB_SUFFIX@ -lncurses@USE_LIB_SUFFIX@ @SHLIB_LIST@
|
||||
SHLIB_LIST = $(SHLIB_DIRS) \
|
||||
-l@FORM_NAME@@USE_LIB_SUFFIX@ \
|
||||
-l@MENU_NAME@@USE_LIB_SUFFIX@ \
|
||||
-l@PANEL_NAME@@USE_LIB_SUFFIX@ \
|
||||
-lncurses@USE_LIB_SUFFIX@ @SHLIB_LIST@
|
||||
|
||||
LIBROOT = ncurses++
|
||||
|
||||
@ -186,29 +190,34 @@ realclean :: distclean
|
||||
|
||||
###############################################################################
|
||||
|
||||
internal_h = $(srcdir)/internal.h \
|
||||
$(INCDIR)/ncurses_cfg.h \
|
||||
$(INCDIR)/nc_mingw.h \
|
||||
$(INCDIR)/nc_string.h
|
||||
|
||||
etip_h = etip.h \
|
||||
$(INCDIR)/ncurses_dll.h
|
||||
HEADER_DEPS = @INTERNALS_HDR@ \
|
||||
etip.h \
|
||||
../include/curses.h \
|
||||
../include/eti.h \
|
||||
../include/form.h \
|
||||
../include/menu.h \
|
||||
../include/ncurses_cfg.h \
|
||||
../include/ncurses_def.h \
|
||||
../include/ncurses_dll.h \
|
||||
../include/panel.h \
|
||||
../include/unctrl.h \
|
||||
$(INCDIR)/nc_string.h \
|
||||
$(srcdir)/cursesp.h \
|
||||
$(srcdir)/cursesw.h \
|
||||
$(srcdir)/cursslk.h \
|
||||
$(srcdir)/internal.h
|
||||
|
||||
cursesw_h = $(srcdir)/cursesw.h \
|
||||
$(etip_h) \
|
||||
$(INCDIR)/curses.h
|
||||
$(HEADER_DEPS)
|
||||
|
||||
cursesp_h = $(srcdir)/cursesp.h \
|
||||
$(cursesw_h) \
|
||||
$(INCDIR)/panel.h
|
||||
$(cursesw_h)
|
||||
|
||||
cursesf_h = $(srcdir)/cursesf.h \
|
||||
$(cursesp_h) \
|
||||
$(INCDIR)/form.h
|
||||
$(cursesp_h)
|
||||
|
||||
cursesm_h = $(srcdir)/cursesm.h \
|
||||
$(cursesp_h) \
|
||||
$(INCDIR)/menu.h
|
||||
$(cursesp_h)
|
||||
|
||||
cursslk_h = $(srcdir)/cursslk.h \
|
||||
$(cursesw_h)
|
||||
@ -217,25 +226,25 @@ cursesapp_h = $(srcdir)/cursesapp.h \
|
||||
$(cursslk_h)
|
||||
|
||||
$(INCDIR)/form.h :
|
||||
cd ../form && $(MAKE) $@
|
||||
( cd ../form && $(MAKE) $@ )
|
||||
|
||||
$(INCDIR)/menu.h :
|
||||
cd ../menu && $(MAKE) $@
|
||||
( cd ../menu && $(MAKE) $@ )
|
||||
|
||||
$(INCDIR)/panel.h :
|
||||
cd ../panel && $(MAKE) $@
|
||||
( cd ../panel && $(MAKE) $@ )
|
||||
|
||||
###############################################################################
|
||||
|
||||
OBJS_DEMO = $(MODEL)/demo$o
|
||||
|
||||
$(MODEL)/demo$o : $(srcdir)/demo.cc \
|
||||
$(internal_h) \
|
||||
$(HEADER_DEPS) \
|
||||
$(cursesf_h) \
|
||||
$(cursesm_h) \
|
||||
$(cursesapp_h)
|
||||
@echo 'compiling demo (obj_s)'
|
||||
@$(LIBTOOL_COMPILE) $(CXX) $(CFLAGS_DEFAULT) -c $(srcdir)/demo.cc -o $@
|
||||
@( cd $(MODEL) && $(LIBTOOL_COMPILE) $(CXX) $(CFLAGS_DEFAULT) -c $(top_srcdir)/c++/demo.cc -o $@ )
|
||||
|
||||
demo$x: $(OBJS_DEMO) \
|
||||
$(LIBRARIES) \
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include "internal.h"
|
||||
#include "cursesapp.h"
|
||||
|
||||
MODULE_ID("$Id: cursesapp.cc,v 1.17 2020/02/02 23:34:34 tom Exp $")
|
||||
MODULE_ID("$Id: cursesapp.cc,v 1.18 2020/07/18 19:57:11 anonymous.maarten Exp $")
|
||||
|
||||
void
|
||||
NCursesApplication::init(bool bColors)
|
||||
@ -69,6 +69,11 @@ NCursesApplication* NCursesApplication::theApp = 0;
|
||||
NCursesWindow* NCursesApplication::titleWindow = 0;
|
||||
NCursesApplication::SLK_Link* NCursesApplication::slk_stack = 0;
|
||||
|
||||
|
||||
NCursesWindow *&NCursesApplication::getTitleWindow() {
|
||||
return titleWindow;
|
||||
}
|
||||
|
||||
NCursesApplication::~NCursesApplication() THROWS(NCursesException)
|
||||
{
|
||||
Soft_Label_Key_Set* S;
|
||||
@ -87,6 +92,10 @@ NCursesApplication::~NCursesApplication() THROWS(NCursesException)
|
||||
::endwin();
|
||||
}
|
||||
|
||||
NCursesApplication* NCursesApplication::getApplication() {
|
||||
return theApp;
|
||||
}
|
||||
|
||||
int NCursesApplication::rinit(NCursesWindow& w)
|
||||
{
|
||||
titleWindow = &w;
|
||||
|
@ -32,14 +32,25 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: cursesapp.h,v 1.14 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursesapp.h,v 1.17 2020/08/29 16:22:03 juergen Exp $
|
||||
|
||||
#ifndef NCURSES_CURSESAPP_H_incl
|
||||
#define NCURSES_CURSESAPP_H_incl
|
||||
|
||||
#include <cursslk.h>
|
||||
|
||||
class NCURSES_IMPEXP NCursesApplication {
|
||||
#if (defined(_WIN32) || defined(_WIN64))
|
||||
# define NCURSES_CXX_MAIN_NAME cursespp_main
|
||||
# define NCURSES_CXX_MAIN \
|
||||
int main(int argc, char *argv[]) { \
|
||||
return NCURSES_CXX_MAIN_NAME(argc, argv); \
|
||||
}
|
||||
#else
|
||||
# define NCURSES_CXX_MAIN_NAME main
|
||||
#endif
|
||||
NCURSES_CXX_IMPEXP int NCURSES_CXX_MAIN_NAME(int argc, char *argv[]);
|
||||
|
||||
class NCURSES_CXX_IMPEXP NCursesApplication {
|
||||
public:
|
||||
typedef struct _slk_link { // This structure is used to maintain
|
||||
struct _slk_link* prev; // a stack of SLKs
|
||||
@ -106,13 +117,13 @@ class NCURSES_IMPEXP NCursesApplication {
|
||||
{
|
||||
}
|
||||
|
||||
static NCursesWindow *&getTitleWindow();
|
||||
|
||||
public:
|
||||
virtual ~NCursesApplication() THROWS(NCursesException);
|
||||
|
||||
// Get a pointer to the current application object
|
||||
static NCursesApplication* getApplication() {
|
||||
return theApp;
|
||||
}
|
||||
static NCursesApplication* getApplication();
|
||||
|
||||
// This method runs the application and returns its exit value
|
||||
int operator()(void);
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include "cursesf.h"
|
||||
#include "cursesapp.h"
|
||||
|
||||
MODULE_ID("$Id: cursesf.cc,v 1.24 2020/02/02 23:34:34 tom Exp $")
|
||||
MODULE_ID("$Id: cursesf.cc,v 1.25 2020/07/18 19:57:11 anonymous.maarten Exp $")
|
||||
|
||||
NCursesFormField::~NCursesFormField () THROWS(NCursesException)
|
||||
{
|
||||
@ -406,10 +406,19 @@ FIELDTYPE* UserDefinedFieldType::generic_fieldtype =
|
||||
::new_fieldtype(_nc_xx_fld_fcheck,
|
||||
_nc_xx_fld_ccheck);
|
||||
|
||||
|
||||
UserDefinedFieldType::UserDefinedFieldType() : NCursesFieldType(generic_fieldtype) {
|
||||
}
|
||||
|
||||
FIELDTYPE* UserDefinedFieldType_With_Choice::generic_fieldtype_with_choice =
|
||||
::new_fieldtype(_nc_xx_fld_fcheck,
|
||||
_nc_xx_fld_ccheck);
|
||||
|
||||
|
||||
UserDefinedFieldType_With_Choice::UserDefinedFieldType_With_Choice() {
|
||||
fieldtype = generic_fieldtype_with_choice;
|
||||
}
|
||||
|
||||
bool _nc_xx_next_choice(FIELD *f, const void *u)
|
||||
{
|
||||
(void) f;
|
||||
@ -461,3 +470,5 @@ public:
|
||||
};
|
||||
|
||||
UDF_Init* UDF_Init::I = new UDF_Init();
|
||||
|
||||
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: cursesf.h,v 1.35 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursesf.h,v 1.37 2020/07/18 19:57:11 anonymous.maarten Exp $
|
||||
|
||||
#ifndef NCURSES_CURSESF_H_incl
|
||||
#define NCURSES_CURSESF_H_incl 1
|
||||
@ -51,11 +51,11 @@ extern "C" {
|
||||
// The abstract base class for builtin and user defined Fieldtypes.
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP NCursesFormField; // forward declaration
|
||||
class NCURSES_CXX_IMPEXP NCursesFormField; // forward declaration
|
||||
|
||||
// Class to represent builtin field types as well as C++ written new
|
||||
// fieldtypes (see classes UserDefineFieldType...
|
||||
class NCURSES_IMPEXP NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP NCursesFieldType
|
||||
{
|
||||
friend class NCursesFormField;
|
||||
|
||||
@ -101,7 +101,7 @@ class NCURSES_IMPEXP NCursesFieldType
|
||||
// The class representing a forms field, wrapping the lowlevel FIELD struct
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP NCursesFormField
|
||||
class NCURSES_CXX_IMPEXP NCursesFormField
|
||||
{
|
||||
friend class NCursesForm;
|
||||
|
||||
@ -338,7 +338,7 @@ extern "C" {
|
||||
// The class representing a form, wrapping the lowlevel FORM struct
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP NCursesForm : public NCursesPanel
|
||||
class NCURSES_CXX_IMPEXP NCursesForm : public NCursesPanel
|
||||
{
|
||||
protected:
|
||||
FORM* form; // the lowlevel structure
|
||||
@ -629,7 +629,7 @@ class NCURSES_IMPEXP NCursesForm : public NCursesPanel
|
||||
// data belongs to some class T. Use T as template argument
|
||||
// to create a UserField.
|
||||
// -------------------------------------------------------------------------
|
||||
template<class T> class NCURSES_IMPEXP NCursesUserField : public NCursesFormField
|
||||
template<class T> class NCURSES_CXX_IMPEXP NCursesUserField : public NCursesFormField
|
||||
{
|
||||
public:
|
||||
NCursesUserField (int rows,
|
||||
@ -662,7 +662,7 @@ template<class T> class NCURSES_IMPEXP NCursesUserField : public NCursesFormFiel
|
||||
// The same mechanism is used to attach user data to a form
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
template<class T> class NCURSES_IMPEXP NCursesUserForm : public NCursesForm
|
||||
template<class T> class NCURSES_CXX_IMPEXP NCursesUserForm : public NCursesForm
|
||||
{
|
||||
protected:
|
||||
// 'Internal' constructor, builds an object without association to a
|
||||
@ -721,7 +721,7 @@ template<class T> class NCURSES_IMPEXP NCursesUserForm : public NCursesForm
|
||||
// Builtin Fieldtypes
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP Alpha_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Alpha_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
int min_field_width;
|
||||
@ -737,7 +737,7 @@ class NCURSES_IMPEXP Alpha_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP Alphanumeric_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Alphanumeric_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
int min_field_width;
|
||||
@ -753,7 +753,7 @@ class NCURSES_IMPEXP Alphanumeric_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP Integer_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Integer_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
int precision;
|
||||
@ -771,7 +771,7 @@ class NCURSES_IMPEXP Integer_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP Numeric_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Numeric_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
int precision;
|
||||
@ -789,7 +789,7 @@ class NCURSES_IMPEXP Numeric_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP Regular_Expression_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Regular_Expression_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
char* regex;
|
||||
@ -834,7 +834,7 @@ class NCURSES_IMPEXP Regular_Expression_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP Enumeration_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP Enumeration_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
const char** list;
|
||||
@ -873,7 +873,7 @@ class NCURSES_IMPEXP Enumeration_Field : public NCursesFieldType
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP IPV4_Address_Field : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP IPV4_Address_Field : public NCursesFieldType
|
||||
{
|
||||
private:
|
||||
void set(NCursesFormField& f) {
|
||||
@ -896,7 +896,7 @@ extern "C" {
|
||||
// Abstract base class for User-Defined Fieldtypes
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP UserDefinedFieldType : public NCursesFieldType
|
||||
class NCURSES_CXX_IMPEXP UserDefinedFieldType : public NCursesFieldType
|
||||
{
|
||||
friend class UDF_Init; // Internal helper to set up statics
|
||||
private:
|
||||
@ -925,8 +925,7 @@ class NCURSES_IMPEXP UserDefinedFieldType : public NCursesFieldType
|
||||
virtual bool char_check (int c) = 0;
|
||||
|
||||
public:
|
||||
UserDefinedFieldType() : NCursesFieldType(generic_fieldtype) {
|
||||
}
|
||||
UserDefinedFieldType();
|
||||
};
|
||||
|
||||
extern "C" {
|
||||
@ -939,7 +938,7 @@ extern "C" {
|
||||
// Abstract base class for User-Defined Fieldtypes with Choice functions
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP UserDefinedFieldType_With_Choice : public UserDefinedFieldType
|
||||
class NCURSES_CXX_IMPEXP UserDefinedFieldType_With_Choice : public UserDefinedFieldType
|
||||
{
|
||||
friend class UDF_Init; // Internal helper to set up statics
|
||||
private:
|
||||
@ -962,9 +961,7 @@ class NCURSES_IMPEXP UserDefinedFieldType_With_Choice : public UserDefinedFieldT
|
||||
virtual bool previous(NCursesFormField& f) = 0;
|
||||
|
||||
public:
|
||||
UserDefinedFieldType_With_Choice() {
|
||||
fieldtype = generic_fieldtype_with_choice;
|
||||
}
|
||||
UserDefinedFieldType_With_Choice();
|
||||
};
|
||||
|
||||
#endif /* NCURSES_CURSESF_H_incl */
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: cursesm.h,v 1.33 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursesm.h,v 1.34 2020/05/24 01:40:20 anonymous.maarten Exp $
|
||||
|
||||
#ifndef NCURSES_CURSESM_H_incl
|
||||
#define NCURSES_CURSESM_H_incl 1
|
||||
@ -47,7 +47,7 @@ extern "C" {
|
||||
// This wraps the ITEM type of <menu.h>
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP NCursesMenuItem
|
||||
class NCURSES_CXX_IMPEXP NCursesMenuItem
|
||||
{
|
||||
friend class NCursesMenu;
|
||||
|
||||
@ -153,7 +153,7 @@ typedef bool ITEMCALLBACK(NCursesMenuItem&);
|
||||
// If you don't like to create a child class for individual items to
|
||||
// overload action(), you may use this class and provide a callback
|
||||
// function pointer for items.
|
||||
class NCURSES_IMPEXP NCursesMenuCallbackItem : public NCursesMenuItem
|
||||
class NCURSES_CXX_IMPEXP NCursesMenuCallbackItem : public NCursesMenuItem
|
||||
{
|
||||
private:
|
||||
ITEMCALLBACK* p_fct;
|
||||
@ -200,7 +200,7 @@ extern "C" {
|
||||
// This wraps the MENU type of <menu.h>
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
class NCURSES_IMPEXP NCursesMenu : public NCursesPanel
|
||||
class NCURSES_CXX_IMPEXP NCursesMenu : public NCursesPanel
|
||||
{
|
||||
protected:
|
||||
MENU *menu;
|
||||
@ -596,7 +596,7 @@ class NCURSES_IMPEXP NCursesMenu : public NCursesPanel
|
||||
// to create a UserItem.
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
template<class T> class NCURSES_IMPEXP NCursesUserItem : public NCursesMenuItem
|
||||
template<class T> class NCURSES_CXX_IMPEXP NCursesUserItem : public NCursesMenuItem
|
||||
{
|
||||
public:
|
||||
NCursesUserItem (const char* p_name,
|
||||
@ -623,7 +623,7 @@ template<class T> class NCURSES_IMPEXP NCursesUserItem : public NCursesMenuItem
|
||||
// The same mechanism is used to attach user data to a menu
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
template<class T> class NCURSES_IMPEXP NCursesUserMenu : public NCursesMenu
|
||||
template<class T> class NCURSES_CXX_IMPEXP NCursesUserMenu : public NCursesMenu
|
||||
{
|
||||
protected:
|
||||
NCursesUserMenu( int nlines,
|
||||
|
@ -44,7 +44,7 @@
|
||||
#define CPP_HAS_TRY_CATCH 0
|
||||
#endif
|
||||
|
||||
MODULE_ID("$Id: cursesmain.cc,v 1.17 2020/02/02 23:34:34 tom Exp $")
|
||||
MODULE_ID("$Id: cursesmain.cc,v 1.20 2020/07/18 19:57:11 anonymous.maarten Exp $")
|
||||
|
||||
#if HAVE_LOCALE_H
|
||||
#include <locale.h>
|
||||
@ -60,7 +60,7 @@ MODULE_ID("$Id: cursesmain.cc,v 1.17 2020/02/02 23:34:34 tom Exp $")
|
||||
* You only have to instantiate a static NCursesApplication object in your
|
||||
* main application source file and link this module with your application.
|
||||
*/
|
||||
int main(int argc, char* argv[])
|
||||
int NCURSES_CXX_MAIN_NAME(int argc, char* argv[])
|
||||
{
|
||||
setlocale(LC_ALL, "");
|
||||
|
||||
|
@ -35,7 +35,7 @@
|
||||
#ifndef NCURSES_CURSESP_H_incl
|
||||
#define NCURSES_CURSESP_H_incl 1
|
||||
|
||||
// $Id: cursesp.h,v 1.33 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursesp.h,v 1.34 2020/05/24 01:40:20 anonymous.maarten Exp $
|
||||
|
||||
#include <cursesw.h>
|
||||
|
||||
@ -43,7 +43,7 @@ extern "C" {
|
||||
# include <panel.h>
|
||||
}
|
||||
|
||||
class NCURSES_IMPEXP NCursesPanel
|
||||
class NCURSES_CXX_IMPEXP NCursesPanel
|
||||
: public NCursesWindow
|
||||
{
|
||||
protected:
|
||||
|
@ -32,12 +32,23 @@
|
||||
#ifndef NCURSES_CURSESW_H_incl
|
||||
#define NCURSES_CURSESW_H_incl 1
|
||||
|
||||
// $Id: cursesw.h,v 1.56 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursesw.h,v 1.57 2020/07/04 20:38:43 tom Exp $
|
||||
|
||||
extern "C" {
|
||||
# include <curses.h>
|
||||
}
|
||||
|
||||
#if defined(BUILDING_NCURSES_CXX)
|
||||
# define NCURSES_CXX_IMPEXP NCURSES_EXPORT_GENERAL_EXPORT
|
||||
#else
|
||||
# define NCURSES_CXX_IMPEXP NCURSES_EXPORT_GENERAL_IMPORT
|
||||
#endif
|
||||
|
||||
#define NCURSES_CXX_WRAPPED_VAR(type,name) extern NCURSES_CXX_IMPEXP type NCURSES_PUBLIC_VAR(name)(void)
|
||||
|
||||
#define NCURSES_CXX_EXPORT(type) NCURSES_CXX_IMPEXP type NCURSES_API
|
||||
#define NCURSES_CXX_EXPORT_VAR(type) NCURSES_CXX_IMPEXP type
|
||||
|
||||
#include <etip.h>
|
||||
|
||||
/* SCO 3.2v4 curses.h includes term.h, which defines lines as a macro.
|
||||
@ -757,7 +768,7 @@ extern "C" int _nc_ripoffline(int, int (*init)(WINDOW*, int));
|
||||
extern "C" int _nc_xx_ripoff_init(WINDOW *, int);
|
||||
extern "C" int _nc_has_mouse(void);
|
||||
|
||||
class NCURSES_IMPEXP NCursesWindow
|
||||
class NCURSES_CXX_IMPEXP NCursesWindow
|
||||
{
|
||||
friend class NCursesMenu;
|
||||
friend class NCursesForm;
|
||||
@ -1371,7 +1382,7 @@ class NCURSES_IMPEXP NCursesWindow
|
||||
// -------------------------------------------------------------------------
|
||||
// We leave this here for compatibility reasons.
|
||||
// -------------------------------------------------------------------------
|
||||
class NCURSES_IMPEXP NCursesColorWindow : public NCursesWindow
|
||||
class NCURSES_CXX_IMPEXP NCursesColorWindow : public NCursesWindow
|
||||
{
|
||||
public:
|
||||
NCursesColorWindow(WINDOW* &window) // useful only for stdscr
|
||||
@ -1417,7 +1428,7 @@ class NCURSES_IMPEXP NCursesColorWindow : public NCursesWindow
|
||||
// Pad Support. We allow an association of a pad with a "real" window
|
||||
// through which the pad may be viewed.
|
||||
// -------------------------------------------------------------------------
|
||||
class NCURSES_IMPEXP NCursesPad : public NCursesWindow
|
||||
class NCURSES_CXX_IMPEXP NCursesPad : public NCursesWindow
|
||||
{
|
||||
private:
|
||||
NCursesWindow* viewWin; // the "viewport" window
|
||||
@ -1533,7 +1544,7 @@ class NCURSES_IMPEXP NCursesPad : public NCursesWindow
|
||||
// A FramedPad is constructed always with a viewport window. This viewport
|
||||
// will be framed (by a box() command) and the interior of the box is the
|
||||
// viewport subwindow. On the frame we display scrollbar sliders.
|
||||
class NCURSES_IMPEXP NCursesFramedPad : public NCursesPad
|
||||
class NCURSES_CXX_IMPEXP NCursesFramedPad : public NCursesPad
|
||||
{
|
||||
protected:
|
||||
virtual void OnOperation(int pad_req);
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include "cursslk.h"
|
||||
#include "cursesapp.h"
|
||||
|
||||
MODULE_ID("$Id: cursslk.cc,v 1.18 2020/02/02 23:34:34 tom Exp $")
|
||||
MODULE_ID("$Id: cursslk.cc,v 1.19 2020/07/18 19:57:11 anonymous.maarten Exp $")
|
||||
|
||||
Soft_Label_Key_Set::Soft_Label_Key&
|
||||
Soft_Label_Key_Set::Soft_Label_Key::operator=(char *text)
|
||||
@ -102,6 +102,10 @@ Soft_Label_Key_Set::Soft_Label_Key& Soft_Label_Key_Set::operator[](int i) {
|
||||
return slk_array[i-1];
|
||||
}
|
||||
|
||||
int Soft_Label_Key_Set::labels() const {
|
||||
return num_labels;
|
||||
}
|
||||
|
||||
void Soft_Label_Key_Set::activate_label(int i, bool bf) {
|
||||
if (!b_attrInit) {
|
||||
NCursesApplication* A = NCursesApplication::getApplication();
|
||||
|
@ -32,17 +32,17 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: cursslk.h,v 1.15 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: cursslk.h,v 1.18 2020/07/18 19:57:11 anonymous.maarten Exp $
|
||||
|
||||
#ifndef NCURSES_CURSSLK_H_incl
|
||||
#define NCURSES_CURSSLK_H_incl
|
||||
|
||||
#include <cursesw.h>
|
||||
|
||||
class NCURSES_IMPEXP Soft_Label_Key_Set {
|
||||
class NCURSES_CXX_IMPEXP Soft_Label_Key_Set {
|
||||
public:
|
||||
// This inner class represents the attributes of a Soft Label Key (SLK)
|
||||
class NCURSES_IMPEXP Soft_Label_Key {
|
||||
class NCURSES_CXX_IMPEXP Soft_Label_Key {
|
||||
friend class Soft_Label_Key_Set;
|
||||
public:
|
||||
typedef enum { Left=0, Center=1, Right=2 } Justification;
|
||||
@ -101,10 +101,10 @@ class NCURSES_IMPEXP Soft_Label_Key_Set {
|
||||
} Label_Layout;
|
||||
|
||||
private:
|
||||
static long NCURSES_IMPEXP count; // Number of Key Sets
|
||||
static Label_Layout NCURSES_IMPEXP format; // Layout of the Key Sets
|
||||
static int NCURSES_IMPEXP num_labels; // Number Of Labels in Key Sets
|
||||
bool NCURSES_IMPEXP b_attrInit; // Are attributes initialized
|
||||
static long count; // Number of Key Sets
|
||||
static Label_Layout format; // Layout of the Key Sets
|
||||
static int num_labels; // Number Of Labels in Key Sets
|
||||
bool b_attrInit; // Are attributes initialized
|
||||
|
||||
Soft_Label_Key *slk_array; // The array of SLK's
|
||||
|
||||
@ -144,7 +144,7 @@ class NCURSES_IMPEXP Soft_Label_Key_Set {
|
||||
|
||||
// This constructor assumes, that you already constructed a Key Set
|
||||
// with a layout by the constructor above. This layout will be reused.
|
||||
NCURSES_IMPEXP Soft_Label_Key_Set();
|
||||
Soft_Label_Key_Set();
|
||||
|
||||
Soft_Label_Key_Set& operator=(const Soft_Label_Key_Set& rhs)
|
||||
{
|
||||
@ -165,10 +165,10 @@ class NCURSES_IMPEXP Soft_Label_Key_Set {
|
||||
virtual ~Soft_Label_Key_Set() THROWS(NCursesException);
|
||||
|
||||
// Get Label# i. Label counting starts with 1!
|
||||
NCURSES_IMPEXP Soft_Label_Key& operator[](int i);
|
||||
Soft_Label_Key& operator[](int i);
|
||||
|
||||
// Retrieve number of Labels
|
||||
inline int labels() const { return num_labels; }
|
||||
int labels() const;
|
||||
|
||||
// Refresh the SLK portion of the screen
|
||||
inline void refresh() {
|
||||
|
22
c++/demo.cc
22
c++/demo.cc
@ -36,7 +36,7 @@
|
||||
* Demo code for NCursesMenu and NCursesForm written by
|
||||
* Juergen Pfeifer
|
||||
*
|
||||
* $Id: demo.cc,v 1.45 2020/02/02 23:34:34 tom Exp $
|
||||
* $Id: demo.cc,v 1.49 2020/09/13 00:47:00 tom Exp $
|
||||
*/
|
||||
|
||||
#include "internal.h"
|
||||
@ -44,11 +44,10 @@
|
||||
#include "cursesm.h"
|
||||
#include "cursesf.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#if (defined(_WIN32) || defined(_WIN64))
|
||||
#undef KEY_EVENT
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#define sleep(n) Sleep(n)
|
||||
#else
|
||||
extern "C" unsigned int sleep(unsigned int);
|
||||
#endif
|
||||
|
||||
@ -187,7 +186,7 @@ public:
|
||||
};
|
||||
|
||||
template class MyAction<UserData>;
|
||||
template class NCURSES_IMPEXP NCursesUserItem<UserData>;
|
||||
template class NCURSES_CXX_IMPEXP NCursesUserItem<UserData>;
|
||||
|
||||
class QuitItem : public NCursesMenuItem
|
||||
{
|
||||
@ -552,9 +551,9 @@ void TestApplication::title()
|
||||
const char * const titleText = "Simple C++ Binding Demo";
|
||||
const int len = ::strlen(titleText);
|
||||
|
||||
titleWindow->bkgd(screen_titles());
|
||||
titleWindow->addstr(0, (titleWindow->cols() - len)/2, titleText);
|
||||
titleWindow->noutrefresh();
|
||||
getTitleWindow()->bkgd(screen_titles());
|
||||
getTitleWindow()->addstr(0, (getTitleWindow()->cols() - len)/2, titleText);
|
||||
getTitleWindow()->noutrefresh();
|
||||
}
|
||||
|
||||
|
||||
@ -569,3 +568,8 @@ int TestApplication::run()
|
||||
// -------------------------------------------------------------------------
|
||||
//
|
||||
static TestApplication *Demo = new TestApplication();
|
||||
|
||||
#if (defined(_WIN32) || defined(_WIN64))
|
||||
// This is actually only needed when ncurses is a dll
|
||||
NCURSES_CXX_MAIN
|
||||
#endif
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: etip.h.in,v 1.43 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: etip.h.in,v 1.45 2020/05/24 01:40:20 anonymous.maarten Exp $
|
||||
|
||||
#ifndef NCURSES_ETIP_H_incl
|
||||
#define NCURSES_ETIP_H_incl 1
|
||||
@ -140,11 +140,11 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
// Forward Declarations
|
||||
class NCURSES_IMPEXP NCursesPanel;
|
||||
class NCURSES_IMPEXP NCursesMenu;
|
||||
class NCURSES_IMPEXP NCursesForm;
|
||||
class NCURSES_CXX_IMPEXP NCursesPanel;
|
||||
class NCURSES_CXX_IMPEXP NCursesMenu;
|
||||
class NCURSES_CXX_IMPEXP NCursesForm;
|
||||
|
||||
class NCURSES_IMPEXP NCursesException
|
||||
class NCURSES_CXX_IMPEXP NCursesException
|
||||
{
|
||||
public:
|
||||
const char *message;
|
||||
@ -178,7 +178,7 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP NCursesPanelException : public NCursesException
|
||||
class NCURSES_CXX_IMPEXP NCursesPanelException : public NCursesException
|
||||
{
|
||||
public:
|
||||
const NCursesPanel* p;
|
||||
@ -229,7 +229,7 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP NCursesMenuException : public NCursesException
|
||||
class NCURSES_CXX_IMPEXP NCursesMenuException : public NCursesException
|
||||
{
|
||||
public:
|
||||
const NCursesMenu* m;
|
||||
@ -280,7 +280,7 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
class NCURSES_IMPEXP NCursesFormException : public NCursesException
|
||||
class NCURSES_CXX_IMPEXP NCursesFormException : public NCursesException
|
||||
{
|
||||
public:
|
||||
const NCursesForm* f;
|
||||
@ -341,7 +341,6 @@ using std::endl;
|
||||
# else
|
||||
# include <iostream.h>
|
||||
# endif
|
||||
extern "C" void exit(int);
|
||||
#endif
|
||||
|
||||
inline void THROW(const NCursesException *e) {
|
||||
|
@ -32,7 +32,7 @@
|
||||
* Author: Juergen Pfeifer, 1997 *
|
||||
****************************************************************************/
|
||||
|
||||
// $Id: internal.h,v 1.20 2020/02/02 23:34:34 tom Exp $
|
||||
// $Id: internal.h,v 1.22 2020/08/29 23:06:41 tom Exp $
|
||||
|
||||
#ifndef NCURSES_CPLUS_INTERNAL_H
|
||||
#define NCURSES_CPLUS_INTERNAL_H 1
|
||||
@ -45,8 +45,12 @@
|
||||
#define MODULE_ID(id) /*nothing */
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#if (defined(_WIN32) || defined(_WIN64))
|
||||
#if defined(EXP_WIN32_DRIVER)
|
||||
#include <nc_win32.h>
|
||||
#else
|
||||
#include <nc_mingw.h>
|
||||
#endif
|
||||
#undef KEY_EVENT
|
||||
#endif
|
||||
|
||||
|
275
configure.in
275
configure.in
@ -1,5 +1,5 @@
|
||||
dnl***************************************************************************
|
||||
dnl Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
dnl Copyright 2018-2020,2021 Thomas E. Dickey *
|
||||
dnl Copyright 1998-2017,2018 Free Software Foundation, Inc. *
|
||||
dnl *
|
||||
dnl Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -29,7 +29,7 @@ dnl***************************************************************************
|
||||
dnl
|
||||
dnl Author: Thomas E. Dickey 1995-on
|
||||
dnl
|
||||
dnl $Id: configure.in,v 1.697 2020/02/08 20:56:13 tom Exp $
|
||||
dnl $Id: configure.in,v 1.729 2021/01/09 11:20:52 tom Exp $
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
dnl
|
||||
dnl For additional information, see
|
||||
@ -37,8 +37,8 @@ dnl https://invisible-island.net/autoconf/
|
||||
dnl https://invisible-island.net/autoconf/my-autoconf.html
|
||||
dnl
|
||||
dnl ---------------------------------------------------------------------------
|
||||
AC_PREREQ(2.52.20200111)
|
||||
AC_REVISION($Revision: 1.697 $)
|
||||
AC_PREREQ(2.52.20210101)
|
||||
AC_REVISION($Revision: 1.729 $)
|
||||
AC_INIT(ncurses/base/lib_initscr.c)
|
||||
AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
|
||||
|
||||
@ -144,10 +144,10 @@ else
|
||||
fi
|
||||
|
||||
CF_GXX_VERSION
|
||||
case $GXX_VERSION in
|
||||
(1*|2.[[0-6]]*)
|
||||
# GXX=""; CXX=""; ac_cv_prog_gxx=no
|
||||
# cf_cxx_library=no
|
||||
case "$GXX_VERSION" in
|
||||
([[1-9]][[0-9]].*)
|
||||
;;
|
||||
(1.*|2.[[0-6]]*)
|
||||
AC_MSG_WARN(templates do not work)
|
||||
;;
|
||||
esac
|
||||
@ -183,7 +183,7 @@ AC_ARG_WITH(progs,
|
||||
[cf_with_progs=yes])
|
||||
AC_MSG_RESULT($cf_with_progs)
|
||||
|
||||
if test -f $srcdir/tack/tack.h; then
|
||||
if test -f "$srcdir/tack/tack.h" ; then
|
||||
if test "x$cross_compiling" = xyes ; then
|
||||
CF_VERBOSE(ignoring tack because we are cross-compiling)
|
||||
cf_with_tack=no
|
||||
@ -221,7 +221,6 @@ modules_to_build="$modules_to_build panel menu form"
|
||||
AC_ARG_PROGRAM
|
||||
|
||||
CF_PROG_AWK
|
||||
CF_PROG_EGREP
|
||||
CF_PROG_INSTALL
|
||||
CF_PROG_LINT
|
||||
CF_PROG_LN_S
|
||||
@ -311,6 +310,14 @@ CF_HELP_MESSAGE(Build-Tools Needed to Compile Temporary Applications for Cross-c
|
||||
# If we're cross-compiling, allow the user to override the tools and their
|
||||
# options. The configure script is oriented toward identifying the host
|
||||
# compiler, etc., but we need a build compiler to generate parts of the source.
|
||||
|
||||
case "$cf_cv_system_name" in
|
||||
(*-msvc*)
|
||||
LDFLAGS="$LDFLAGS user32.lib"
|
||||
export LDFLAGS
|
||||
;;
|
||||
esac
|
||||
|
||||
CF_BUILD_CC
|
||||
|
||||
###############################################################################
|
||||
@ -443,7 +450,7 @@ fi
|
||||
AC_SUBST(CXX_G_OPT)
|
||||
|
||||
AC_MSG_CHECKING(for default loader flags)
|
||||
case $DFT_LWR_MODEL in
|
||||
case "$DFT_LWR_MODEL" in
|
||||
(libtool) LD_MODEL='' ;;
|
||||
(normal) LD_MODEL='' ;;
|
||||
(debug) LD_MODEL=$CC_G_OPT ;;
|
||||
@ -453,7 +460,7 @@ esac
|
||||
AC_SUBST(LD_MODEL)dnl the type of link (e.g., -g or -pg)
|
||||
AC_MSG_RESULT($LD_MODEL)
|
||||
|
||||
case $DFT_LWR_MODEL in
|
||||
case "$DFT_LWR_MODEL" in
|
||||
(shared)
|
||||
CF_ENABLE_RPATH
|
||||
AC_MSG_CHECKING(if shared libraries should be relinked during install)
|
||||
@ -468,8 +475,8 @@ esac
|
||||
# we will build libraries one-level down.
|
||||
rel_builddir=..
|
||||
CF_SHARED_OPTS
|
||||
for model in $cf_list_models; do
|
||||
case $model in
|
||||
for model in $cf_list_models ; do
|
||||
case "$model" in
|
||||
(libtool)
|
||||
CF_WITH_LIBTOOL_OPTS
|
||||
CF_WITH_EXPORT_SYMS
|
||||
@ -482,7 +489,7 @@ for model in $cf_list_models; do
|
||||
AC_MSG_CHECKING(if current CFLAGS link properly)
|
||||
AC_TRY_LINK(
|
||||
[#include <stdio.h>],
|
||||
[printf("Hello work\n");],
|
||||
[printf("Hello work\\n");],
|
||||
[cf_cflags_work=yes],
|
||||
[cf_cflags_work=no])
|
||||
AC_MSG_RESULT($cf_cflags_work)
|
||||
@ -543,6 +550,23 @@ if test "$DFT_LWR_MODEL" = "shared" && test "x$cf_cv_enable_rpath" != xno; then
|
||||
CF_DISABLE_RPATH_HACK
|
||||
fi
|
||||
|
||||
### Depending on the system, someone may use rpath to build ncurses but not
|
||||
# want users of the package to rely upon that feature. Give those people an
|
||||
# option to suppress that detail from EXTRA_LDFLAGS.
|
||||
EXTRA_PKG_LDFLAGS="$EXTRA_LDFLAGS"
|
||||
if test -n "$EXTRA_PKG_LDFLAGS"
|
||||
then
|
||||
AC_MSG_CHECKING(if you want to disable extra LDFLAGS for package-scripts)
|
||||
CF_ARG_DISABLE(pkg-ldflags,
|
||||
[ --disable-pkg-ldflags disable extra LDFLAGS for package-scripts],
|
||||
[disable_pkg_ldflags=yes],
|
||||
[disable_pkg_ldflags=no],
|
||||
no)
|
||||
AC_MSG_RESULT($disable_pkg_ldflags)
|
||||
test "$disable_pkg_ldflags" = yes && EXTRA_PKG_LDFLAGS=
|
||||
fi
|
||||
AC_SUBST(EXTRA_PKG_LDFLAGS)
|
||||
|
||||
###############################################################################
|
||||
CF_HELP_MESSAGE(Fine-Tuning Your Configuration:)
|
||||
|
||||
@ -552,7 +576,7 @@ EXTRA_SUFFIX=
|
||||
AC_ARG_WITH(extra-suffix,
|
||||
[ --with-extra-suffix=X append extra suffix to header/library paths],
|
||||
[case x$withval in
|
||||
(no)
|
||||
(xno)
|
||||
;;
|
||||
(xyes|x)
|
||||
EXTRA_SUFFIX=$cf_cv_abi_version
|
||||
@ -580,7 +604,7 @@ AC_ARG_ENABLE(database,
|
||||
[use_database=yes])
|
||||
AC_MSG_RESULT($use_database)
|
||||
|
||||
case $host_os in
|
||||
case "$host_os" in
|
||||
(os2*)
|
||||
TERMINFO_SRC='${top_srcdir}/misc/emx.src'
|
||||
;;
|
||||
@ -629,33 +653,38 @@ case ".$with_fallback" in
|
||||
;;
|
||||
esac
|
||||
|
||||
USE_FALLBACKS=
|
||||
test -z "$FALLBACK_LIST" && USE_FALLBACKS="#"
|
||||
AC_SUBST(FALLBACK_LIST)
|
||||
AC_SUBST(USE_FALLBACKS)
|
||||
|
||||
# The fallback feature in ncurses relies upon tic/infocmp outside the build
|
||||
# tree for generating the terminal descriptions that will be compiled into the
|
||||
# library. If your toolchain is old, it may not handle current terminal
|
||||
# databases. Use configure-options to point to the tools which will be used,
|
||||
# rather than the first ones found on the $PATH.
|
||||
AC_CHECK_TOOL(TIC, tic)
|
||||
AC_CHECK_TOOL(INFOCMP, infocmp)
|
||||
if test -n "$FALLBACK_LIST"
|
||||
then
|
||||
CF_WITH_PATH_PROG(TIC, tic, [for fallbacks], $PATH:/usr/local/ncurses/bin)
|
||||
CF_WITH_PATH_PROG(INFOCMP, infocmp, [for fallbacks], $PATH:/usr/local/ncurses/bin)
|
||||
else
|
||||
: ${TIC:=tic}
|
||||
: ${INFOCMP:=infocmp}
|
||||
test -z "$TIC" && FALLBACK_LIST=
|
||||
test -z "$INFOCMP" && FALLBACK_LIST=
|
||||
if test -z "$FALLBACK_LIST"
|
||||
then
|
||||
AC_MSG_WARN(ignoring fallback option because tic/infocmp are not available)
|
||||
fi
|
||||
fi
|
||||
AC_SUBST(TIC)
|
||||
AC_SUBST(INFOCMP)
|
||||
|
||||
USE_FALLBACKS=
|
||||
test -z "$FALLBACK_LIST" && USE_FALLBACKS="#"
|
||||
AC_SUBST(FALLBACK_LIST)
|
||||
AC_SUBST(USE_FALLBACKS)
|
||||
|
||||
AC_MSG_CHECKING(if you want modern xterm or antique)
|
||||
AC_ARG_WITH(xterm-new,
|
||||
[ --without-xterm-new specify if xterm terminfo should be old version],
|
||||
[with_xterm_new=$withval],
|
||||
[with_xterm_new=yes])
|
||||
case $with_xterm_new in
|
||||
case "$with_xterm_new" in
|
||||
(no) with_xterm_new=xterm-old;;
|
||||
(*) with_xterm_new=xterm-new;;
|
||||
esac
|
||||
@ -1447,6 +1476,38 @@ AC_ARG_ENABLE(colorfgbg,
|
||||
AC_MSG_RESULT($with_colorfgbg)
|
||||
test "x$with_colorfgbg" = xyes && AC_DEFINE(USE_COLORFGBG,1,[Define to 1 to compile-in experimental $COLORFGBG code])
|
||||
|
||||
### use option --enable-fvisibility to turn on use of gcc-specific feature
|
||||
AC_MSG_CHECKING(if you want to use gcc -fvisibility option)
|
||||
AC_ARG_ENABLE(fvisibility,
|
||||
[ --enable-fvisibility compile with -fvisibility=hidden],
|
||||
[cf_with_fvisibility=$enableval],
|
||||
[cf_with_fvisibility=no])
|
||||
AC_MSG_RESULT($cf_with_fvisibility)
|
||||
|
||||
NCURSES_IMPEXP=
|
||||
NCURSES_CXX_IMPEXP=
|
||||
if test "x$cf_with_fvisibility" = xyes; then
|
||||
CF_CHECK_FVISIBILITY($CC,CFLAGS,cf_cv_fvisibility_hidden)
|
||||
if test "x$cf_cv_fvisibility_hidden" = xyes
|
||||
then
|
||||
CF_ADD_CFLAGS([-fvisibility=hidden])
|
||||
NCURSES_IMPEXP="__attribute__ ((visibility(\"default\")))"
|
||||
fi
|
||||
if test -n "$CXX"
|
||||
then
|
||||
AC_LANG_PUSH(C++)
|
||||
CF_CHECK_FVISIBILITY($CXX,CXXFLAGS,cf_cv_fvisibility_hidden2)
|
||||
if test "x$cf_cv_fvisibility_hidden2" = xyes
|
||||
then
|
||||
CF_ADD_CXXFLAGS([-fvisibility=hidden])
|
||||
NCURSES_CXX_IMPEXP="__attribute__ ((visibility(\"default\")))"
|
||||
fi
|
||||
AC_LANG_POP
|
||||
fi
|
||||
fi
|
||||
AC_SUBST(NCURSES_IMPEXP)
|
||||
AC_SUBST(NCURSES_CXX_IMPEXP)
|
||||
|
||||
### use option --enable-interop to turn on use of bindings used for interop
|
||||
AC_MSG_CHECKING(if you want interop bindings)
|
||||
AC_ARG_ENABLE(interop,
|
||||
@ -1485,7 +1546,39 @@ AC_ARG_ENABLE(wgetch-events,
|
||||
[with_wgetch_events=$enableval],
|
||||
[with_wgetch_events=no])
|
||||
AC_MSG_RESULT($with_wgetch_events)
|
||||
test "x$with_wgetch_events" = xyes && AC_DEFINE(NCURSES_WGETCH_EVENTS,1,[Define to 1 to compile with wgetch-events code])
|
||||
if test "x$with_wgetch_events" = xyes ; then
|
||||
AC_DEFINE(NCURSES_WGETCH_EVENTS,1,[Define to 1 to compile with wgetch-events code])
|
||||
NCURSES_WGETCH_EVENTS=1
|
||||
else
|
||||
NCURSES_WGETCH_EVENTS=0
|
||||
fi
|
||||
AC_SUBST(NCURSES_WGETCH_EVENTS)
|
||||
|
||||
case "$cf_cv_system_name" in
|
||||
(*mingw32*|*mingw64*|*-msvc*)
|
||||
AC_MSG_CHECKING(if you want experimental-Windows driver)
|
||||
AC_ARG_ENABLE(exp-win32,
|
||||
[ --enable-exp-win32 compile with experimental-Windows driver],
|
||||
[with_exp_win32=$enableval],
|
||||
[with_exp_win32=no])
|
||||
AC_MSG_RESULT($with_exp_win32)
|
||||
if test "x$with_exp_win32" = xyes
|
||||
then
|
||||
AC_DEFINE(EXP_WIN32_DRIVER,1,[Define to 1 to compile with experimental win32 driver])
|
||||
EXP_WIN32_DRIVER=1
|
||||
INTERNALS_HDR='[$](INCDIR)/nc_win32.h'
|
||||
else
|
||||
INTERNALS_HDR='[$](INCDIR)/nc_mingw.h'
|
||||
EXP_WIN32_DRIVER=0
|
||||
fi
|
||||
;;
|
||||
(*)
|
||||
EXP_WIN32_DRIVER=0
|
||||
INTERNALS_HDR=
|
||||
;;
|
||||
esac
|
||||
AC_SUBST(EXP_WIN32_DRIVER)
|
||||
AC_SUBST(INTERNALS_HDR)
|
||||
|
||||
###############################################################################
|
||||
CF_HELP_MESSAGE(Testing/development Options:)
|
||||
@ -1520,20 +1613,14 @@ fi
|
||||
AC_SUBST(INSTALL_OPT_P)
|
||||
|
||||
### use option --enable-warnings to turn on all gcc warnings
|
||||
AC_MSG_CHECKING(if you want to see compiler warnings)
|
||||
AC_ARG_ENABLE(warnings,
|
||||
[ --enable-warnings build: turn on GCC compiler warnings],
|
||||
[with_warnings=$enableval])
|
||||
AC_MSG_RESULT($with_warnings)
|
||||
CF_ENABLE_WARNINGS(Wno-unknown-pragmas Wswitch-enum,yes)
|
||||
|
||||
if test "x$with_warnings" = "xyes"; then
|
||||
if test "x$enable_warnings" = "xyes"; then
|
||||
CF_ADD_ADAFLAGS(-gnatg)
|
||||
CF_GCC_WARNINGS(Wno-unknown-pragmas Wswitch-enum)
|
||||
if test "x$cf_with_cxx" = xyes ; then
|
||||
CF_GXX_WARNINGS(Wno-unused)
|
||||
fi
|
||||
fi
|
||||
CF_GCC_ATTRIBUTES
|
||||
CF_ENABLE_STRING_HACKS
|
||||
|
||||
### use option --enable-assertions to turn on generation of assertion code
|
||||
@ -1598,9 +1685,13 @@ AC_SUBST(ADA_TRACE)
|
||||
CF_DISABLE_GNAT_PROJECTS
|
||||
|
||||
### Checks for libraries.
|
||||
case $cf_cv_system_name in
|
||||
case "$cf_cv_system_name" in
|
||||
(*mingw32*|*mingw64*)
|
||||
if test "x$with_exp_win32" = xyes ; then
|
||||
CPPFLAGS="$CPPFLAGS -DWINVER=0x0600 -DWIN32_LEAN_AND_MEAN"
|
||||
else
|
||||
CPPFLAGS="$CPPFLAGS -DWINVER=0x0501 -DWIN32_LEAN_AND_MEAN"
|
||||
fi
|
||||
# Note: WINVER may be a problem with Windows 10
|
||||
;;
|
||||
(*)
|
||||
@ -1630,7 +1721,6 @@ limits.h \
|
||||
locale.h \
|
||||
math.h \
|
||||
poll.h \
|
||||
sys/bsdtypes.h \
|
||||
sys/ioctl.h \
|
||||
sys/param.h \
|
||||
sys/poll.h \
|
||||
@ -1652,13 +1742,6 @@ then
|
||||
AC_MSG_WARN(The NCURSES_TRACE environment variable is not supported with this configuration)
|
||||
fi
|
||||
|
||||
# check for ISC (this may also define _POSIX_SOURCE)
|
||||
# Note: even non-Posix ISC needs <sys/bsdtypes.h> to declare fd_set
|
||||
if test "x$ISC" = xyes ; then
|
||||
AC_CHECK_LIB(cposix,main)
|
||||
AC_CHECK_LIB(inet,bzero,CF_ADD_LIB(inet))dnl also 'select()'
|
||||
fi
|
||||
|
||||
CF_SYS_TIME_SELECT
|
||||
|
||||
### checks for compiler characteristics
|
||||
@ -1667,7 +1750,7 @@ AC_C_CONST
|
||||
CF_C_INLINE(NCURSES_INLINE,1200)
|
||||
CF_SIG_ATOMIC_T
|
||||
|
||||
if test $NCURSES_CHTYPE = auto ; then
|
||||
if test "$NCURSES_CHTYPE" = auto ; then
|
||||
CF_TYPEOF_CHTYPE
|
||||
else
|
||||
cf_cv_typeof_chtype=$NCURSES_CHTYPE
|
||||
@ -1681,7 +1764,7 @@ test ".$cf_cv_unsigned_literals" = .yes && cf_cv_1UL="${cf_cv_1UL}U"
|
||||
test ".$cf_cv_typeof_chtype" = .long && cf_cv_1UL="${cf_cv_1UL}L"
|
||||
AC_SUBST(cf_cv_1UL)
|
||||
|
||||
if test $NCURSES_MMASK_T = auto ; then
|
||||
if test "$NCURSES_MMASK_T" = auto ; then
|
||||
cf_cv_typeof_mmask_t=long
|
||||
else
|
||||
cf_cv_typeof_mmask_t=$NCURSES_MMASK_T
|
||||
@ -1712,6 +1795,7 @@ setenv \
|
||||
setvbuf \
|
||||
sigaction \
|
||||
sigvec \
|
||||
snprintf \
|
||||
strdup \
|
||||
strstr \
|
||||
sysconf \
|
||||
@ -1784,7 +1868,7 @@ if test "$with_hashed_db" != no ; then
|
||||
fi
|
||||
|
||||
dnl We'll do our own -g libraries, unless the user's overridden via $CFLAGS
|
||||
if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
|
||||
if test -z "$cf_user_CFLAGS" && test "$enable_leaks" = yes ; then
|
||||
CF_STRIP_G_OPT(CFLAGS)
|
||||
CF_STRIP_G_OPT(CXXFLAGS)
|
||||
fi
|
||||
@ -1798,8 +1882,8 @@ if test -n "$CXX" ; then
|
||||
CF_STDCPP_LIBRARY
|
||||
CF_PROG_CC_C_O(CXX,[$CXXFLAGS $CPPFLAGS])
|
||||
|
||||
case $GXX_VERSION in
|
||||
(1*|2.[0-6]*)
|
||||
case "$GXX_VERSION" in
|
||||
(1.*|2.[[0-6]]*|[[1-9]][[0-9]].*)
|
||||
cf_cxx_library=yes
|
||||
;;
|
||||
(*-2.7*|2.7*)
|
||||
@ -1855,11 +1939,11 @@ AC_SUBST(CXXLIBS)
|
||||
# specify the type of bool in a configure-script option and postpone
|
||||
# integration with the C++ compiler provided that the types are compatible.
|
||||
USE_CXX_BOOL=1
|
||||
if test $cf_cv_cc_bool_type = 1
|
||||
if test "$cf_cv_cc_bool_type" = 1
|
||||
then
|
||||
# oops: C has a bool. Unlikely, but C++ could differ.
|
||||
USE_CXX_BOOL=0
|
||||
elif test $cf_cv_builtin_bool = 0
|
||||
elif test "$cf_cv_builtin_bool" = 0
|
||||
then
|
||||
# C++ has no bool
|
||||
USE_CXX_BOOL=0
|
||||
@ -1968,15 +2052,27 @@ LIB_SUBSETS="${LIB_SUBSETS}base"
|
||||
# base library (so it resides in base).
|
||||
if test "$with_term_driver" != no ; then
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_drivers"
|
||||
case $cf_cv_system_name in
|
||||
case "$cf_cv_system_name" in
|
||||
(*mingw32*|*mingw64*)
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo+port_win32con"
|
||||
if test "x$with_exp_win32" = xyes ; then
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo+port_win32"
|
||||
else
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo+port_win32con"
|
||||
fi
|
||||
CPPFLAGS="$CPPFLAGS -DUSE_WIN32CON_DRIVER"
|
||||
;;
|
||||
(*)
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo"
|
||||
;;
|
||||
esac
|
||||
elif test "x$with_exp_win32" = xyes ; then
|
||||
case "$cf_cv_system_name" in
|
||||
(*mingw32*|*mingw64*)
|
||||
LIB_SUBSETS="${LIB_SUBSETS}+port_win32"
|
||||
;;
|
||||
(*)
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
test "x$with_widec" = xyes && LIB_SUBSETS="${LIB_SUBSETS}+widechar"
|
||||
@ -2022,8 +2118,8 @@ fi
|
||||
|
||||
# do not want -ldl in build except as needed for -lncurses dependency
|
||||
if test "x$with_dlsym" = xyes ; then
|
||||
if test $DFT_LWR_MODEL = shared || \
|
||||
test $DFT_LWR_MODEL = libtool ; then
|
||||
if test "$DFT_LWR_MODEL" = shared || \
|
||||
test "$DFT_LWR_MODEL" = libtool ; then
|
||||
CF_REMOVE_LIB(LIBS,$LIBS,dl)
|
||||
fi
|
||||
fi
|
||||
@ -2051,9 +2147,9 @@ if test "$with_ticlib" != no ; then
|
||||
|
||||
if test "x$with_ticlib" != xyes ; then
|
||||
TICS_NAME=$with_ticlib
|
||||
TICS_SUFFIX="`echo ${DFT_LIB_SUFFIX}|sed -e "s/^${USE_LIB_SUFFIX}//"`"
|
||||
TICS_ARG_SUFFIX="${with_ticlib}`echo ${USE_ARG_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TICS_DEP_SUFFIX="${with_ticlib}`echo ${DFT_DEP_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TICS_SUFFIX="`echo "${DFT_LIB_SUFFIX}" |sed -e "s/^${USE_LIB_SUFFIX}//"`"
|
||||
TICS_ARG_SUFFIX="${with_ticlib}`echo "${USE_ARG_SUFFIX}" |sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TICS_DEP_SUFFIX="${with_ticlib}`echo "${DFT_DEP_SUFFIX}" |sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TICS_LIB_SUFFIX="${with_ticlib}"
|
||||
else
|
||||
TICS_SUFFIX=${DFT_LIB_SUFFIX}
|
||||
@ -2078,9 +2174,9 @@ if test "$with_termlib" != no ; then
|
||||
|
||||
if test "x$with_termlib" != xyes ; then
|
||||
TINFO_NAME=$with_termlib
|
||||
TINFO_SUFFIX="`echo ${DFT_LIB_SUFFIX}|sed -e "s/^${USE_LIB_SUFFIX}//"`"
|
||||
TINFO_ARG_SUFFIX="${with_termlib}`echo ${USE_ARG_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TINFO_DEP_SUFFIX="${with_termlib}`echo ${DFT_DEP_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TINFO_SUFFIX="`echo "${DFT_LIB_SUFFIX}" |sed -e "s/^${USE_LIB_SUFFIX}//"`"
|
||||
TINFO_ARG_SUFFIX="${with_termlib}`echo "${USE_ARG_SUFFIX}" |sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TINFO_DEP_SUFFIX="${with_termlib}`echo "${DFT_DEP_SUFFIX}" |sed -e "s/^${LIB_SUFFIX}//"`"
|
||||
TINFO_LIB_SUFFIX="${with_termlib}"
|
||||
else
|
||||
TINFO_SUFFIX=${DFT_LIB_SUFFIX}
|
||||
@ -2128,7 +2224,7 @@ else
|
||||
fi
|
||||
|
||||
if test "$DFT_LWR_MODEL" = shared ; then
|
||||
case $cf_cv_system_name in
|
||||
case "$cf_cv_system_name" in
|
||||
(cygwin*|msys*)
|
||||
# "lib" files have ".dll.a" suffix, "cyg"or "msys-" files have ".dll"
|
||||
TINFO_SUFFIX=.dll
|
||||
@ -2154,7 +2250,7 @@ fi
|
||||
TINFO_LDFLAGS2=`echo "$TINFO_LDFLAGS" | sed -e 's,-L\.\./,-L../../,'`
|
||||
AC_SUBST(TINFO_LDFLAGS2)
|
||||
|
||||
case $DFT_LWR_MODEL in
|
||||
case "$DFT_LWR_MODEL" in
|
||||
(normal|debug|profile)
|
||||
CF_LDFLAGS_STATIC
|
||||
;;
|
||||
@ -2164,8 +2260,8 @@ AC_MSG_CHECKING(where we will install curses.h)
|
||||
AC_SUBST(includesubdir)
|
||||
includesubdir=
|
||||
if test "$with_overwrite" = no && \
|
||||
( test "x$includedir" = 'x${prefix}/include' || \
|
||||
test "x$includedir" = "x${prefix}/include" )
|
||||
{ test "x$includedir" = 'x${prefix}/include' || \
|
||||
test "x$includedir" = "x${prefix}/include"; }
|
||||
then
|
||||
includesubdir="/ncurses${USE_LIB_SUFFIX}"
|
||||
fi
|
||||
@ -2181,6 +2277,17 @@ fi
|
||||
fi
|
||||
WITH_OVERWRITE=$with_overwrite
|
||||
|
||||
### At least on MinGW a shared library build without libtool
|
||||
### requires adding the additional libs to the link list.
|
||||
case "$cf_cv_system_name" in
|
||||
(*mingw32*|*mingw64*)
|
||||
if test "$DFT_LWR_MODEL" != "libtool"; then
|
||||
SHLIB_LIST="$SHLIB_LIST ${LIBS}"
|
||||
fi
|
||||
;;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
AC_SUBST(WITH_OVERWRITE)
|
||||
AC_SUBST(TICS_LIST)
|
||||
AC_SUBST(TINFO_LIST)
|
||||
@ -2193,6 +2300,12 @@ AC_SUBST(NCURSES_TREE)
|
||||
### predefined stuff for the test programs
|
||||
AC_DEFINE(HAVE_SLK_COLOR,1,[Define to 1 if we have slk_color for test-programs])
|
||||
|
||||
# pkgsrc uses these
|
||||
CF_WITH_LIB_BASENAME(FORM_NAME,form)
|
||||
CF_WITH_LIB_BASENAME(MENU_NAME,menu)
|
||||
CF_WITH_LIB_BASENAME(PANEL_NAME,panel)
|
||||
CF_WITH_LIB_BASENAME(CXX_NAME,cxx,ncurses++)
|
||||
|
||||
### Construct the list of subdirectories for which we'll customize makefiles
|
||||
### with the appropriate compile-rules.
|
||||
|
||||
@ -2215,9 +2328,6 @@ AC_DEFINE_UNQUOTED(NCURSES_PATHSEP,'$PATH_SEPARATOR',[Define to override ':' as
|
||||
|
||||
AC_DEFINE_UNQUOTED(NCURSES_VERSION_STRING, "${NCURSES_MAJOR}.${NCURSES_MINOR}.${NCURSES_PATCH}",[Define to 1 if machine has ample memory for tic])
|
||||
|
||||
### Now that we're done running tests, add the compiler-warnings, if any
|
||||
CF_ADD_CFLAGS($EXTRA_CFLAGS)
|
||||
|
||||
### Define substitutions for header files to avoid name-pollution
|
||||
CF_SUBST_IF(["x$cf_cv_have_tcgetattr" = xyes], HAVE_TCGETATTR, 1, 0)
|
||||
CF_SUBST_IF(["x$ac_cv_header_stdint_h" = xyes], HAVE_STDINT_H, 1, 0)
|
||||
@ -2246,19 +2356,8 @@ AC_SUBST(MAKE_TESTS)
|
||||
ADAHTML_DIR=../../doc/html/ada
|
||||
AC_SUBST(ADAHTML_DIR)
|
||||
|
||||
# these could be configurable, but are not currently
|
||||
PANEL_NAME=panel
|
||||
MENU_NAME=menu
|
||||
FORM_NAME=form
|
||||
CXX_NAME=ncurses++
|
||||
|
||||
AC_SUBST(PANEL_NAME)
|
||||
AC_SUBST(MENU_NAME)
|
||||
AC_SUBST(FORM_NAME)
|
||||
AC_SUBST(CXX_NAME)
|
||||
|
||||
# workaround for OS/2 (20151017)
|
||||
case $cf_cv_system_name in
|
||||
case "$cf_cv_system_name" in
|
||||
(os2*)
|
||||
LIBTOOL_OPTS_CXX="-os2dllname ncurs++"
|
||||
;;
|
||||
@ -2269,7 +2368,7 @@ esac
|
||||
AC_SUBST(LIBTOOL_OPTS_CXX)
|
||||
|
||||
# workaround for g++ versus Solaris (20131116)
|
||||
case $cf_cv_system_name in
|
||||
case "$cf_cv_system_name" in
|
||||
(solaris2*)
|
||||
case "x$CPPFLAGS" in
|
||||
(*-D_XOPEN_SOURCE_EXTENDED*)
|
||||
@ -2369,7 +2468,7 @@ fi
|
||||
test "x$cf_with_trace" = xyes && NCURSES_INLINE=
|
||||
|
||||
UNALTERED_SYMS=`echo "$RESULTING_SYMS" | sed -e 's/\\$/\\\\$/g'`
|
||||
if test $cf_filter_syms = yes
|
||||
if test "$cf_filter_syms" = yes
|
||||
then
|
||||
RESULTING_SYMS=resulting.map
|
||||
fi
|
||||
@ -2400,25 +2499,27 @@ AC_OUTPUT( \
|
||||
$SUB_MAKEFILES \
|
||||
Makefile,[
|
||||
if test "x$cf_with_tests" != xno ; then
|
||||
CF_PRG_RULES([$srcdir/test/mk-test.awk INSTALL=no ECHO_LINK="$ECHO_LD"], test)
|
||||
CF_PRG_RULES(["$srcdir/test/mk-test.awk" INSTALL=no ECHO_LINK="$ECHO_LD"], test)
|
||||
fi
|
||||
CF_LIB_RULES($SRC_SUBDIRS)
|
||||
|
||||
if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then
|
||||
if test -z "$USE_OLD_MAKERULES" ; then
|
||||
$AWK -f $srcdir/Ada95/mk-1st.awk <$srcdir/Ada95/src/modules >>Ada95/src/Makefile
|
||||
$AWK -f "$srcdir/Ada95/mk-1st.awk" <"$srcdir/Ada95/src/modules" >>Ada95/src/Makefile
|
||||
fi
|
||||
fi
|
||||
],[
|
||||
### Special initialization commands, used to pass information from the
|
||||
### configuration-run into config.status
|
||||
|
||||
AWK="$AWK"
|
||||
ALTERNATE_SYMS="$ALTERNATE_SYMS"
|
||||
AWK="$AWK"
|
||||
CXX_NAME="$CXX_NAME"
|
||||
DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
|
||||
DFT_LWR_MODEL="$DFT_LWR_MODEL"
|
||||
ECHO_LD="$ECHO_LD"
|
||||
EXTRA_SUFFIX="$EXTRA_SUFFIX"
|
||||
FORM_NAME="$FORM_NAME"
|
||||
LDCONFIG="$LDCONFIG"
|
||||
LIBTOOL_VERSION="$LIBTOOL_VERSION"
|
||||
LIB_NAME="$LIB_NAME"
|
||||
@ -2428,10 +2529,12 @@ LIB_SUFFIX="$LIB_SUFFIX"
|
||||
LIB_TRACING="$LIB_TRACING"
|
||||
LN_S="$LN_S"
|
||||
MAKE_TERMINFO="$MAKE_TERMINFO"
|
||||
MENU_NAME="$MENU_NAME"
|
||||
NCURSES_MAJOR="$NCURSES_MAJOR"
|
||||
NCURSES_MINOR="$NCURSES_MINOR"
|
||||
NCURSES_OSPEED="$NCURSES_OSPEED"
|
||||
NCURSES_PATCH="$NCURSES_PATCH"
|
||||
PANEL_NAME="$PANEL_NAME"
|
||||
SRC_SUBDIRS="$SRC_SUBDIRS"
|
||||
TERMINFO="$TERMINFO"
|
||||
TICS_ARG_SUFFIX="$TICS_ARG_SUFFIX"
|
||||
@ -2453,6 +2556,8 @@ WITH_CURSES_H="$with_curses_h"
|
||||
WITH_ECHO="${enable_echo:=yes}"
|
||||
WITH_OVERWRITE="$with_overwrite"
|
||||
cf_LIST_MODELS="$cf_list_models"
|
||||
cf_cv_VERSION_GNATMAKE=$cf_cv_VERSION_GNATMAKE
|
||||
cf_cv_VERSION_GPRBUILD=$cf_cv_VERSION_GPRBUILD
|
||||
cf_cv_abi_version="$cf_cv_abi_version"
|
||||
cf_cv_do_relink="$cf_cv_do_relink"
|
||||
cf_cv_do_reranlib="$cf_cv_do_reranlib"
|
||||
|
@ -1,120 +0,0 @@
|
||||
extproc perl -S -w
|
||||
|
||||
# $Id: convert_configure.pl,v 1.4 2020/02/02 23:34:34 tom Exp $
|
||||
##############################################################################
|
||||
# Copyright 2020 Thomas E. Dickey #
|
||||
# Copyright 1998-2000,2006 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. #
|
||||
##############################################################################
|
||||
|
||||
# The converted script is written to stdout, so run this script as
|
||||
# convert_configure configure > configure.cmd
|
||||
#
|
||||
# When the converted script runs, it expects that /tmp dir is
|
||||
# available (so we create it).
|
||||
#
|
||||
# run the result like this:
|
||||
# .\configure
|
||||
|
||||
# Some frequent manual intervention:
|
||||
# a) Some makefiles hardwire SHELL = /bin/sh ==> change to: sh
|
||||
# b) Some makefiles recognize that exe files terminate on .exe
|
||||
# You need to give this script -no-zexe option...
|
||||
|
||||
shift, $no_zexe = 1 if @ARGV and $ARGV[0] eq '-no-zexe';
|
||||
|
||||
mkdir '/tmp', 0777 unless -d '/tmp';
|
||||
|
||||
print <<EOF;
|
||||
extproc sh
|
||||
|
||||
EOF
|
||||
|
||||
print <<EOF unless $no_zexe;
|
||||
# Make sensible defaults:
|
||||
CC="gcc -Zexe -Zmt"
|
||||
export CC
|
||||
CXX="gcc -Zexe -Zmt"
|
||||
export CXX
|
||||
#GCCOPT="$GCCOPT -Zexe"
|
||||
#export GCCOPT
|
||||
EOF
|
||||
|
||||
print <<EOF;
|
||||
CONFIG_SHELL=sh
|
||||
export CONFIG_SHELL
|
||||
|
||||
# Optimization (GNU make 3.74 cannot be loaded :-():
|
||||
emxload -m 30 sh.exe ls.exe tr.exe id.exe sed.exe # make.exe
|
||||
emxload -m 30 grep.exe egrep.exe fgrep.exe cat.exe rm.exe mv.exe cp.exe
|
||||
emxload -m 30 uniq.exe basename.exe sort.exe awk.exe echo.exe
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
$checking_path = 0;
|
||||
|
||||
while (<>) {
|
||||
if (/for\s+(\w+)\s+in\s*\$(PATH|ac_dummy)\s*;/) {
|
||||
$checking_path = 1;
|
||||
$varname = $1;
|
||||
$subst= <<EOS
|
||||
$varname="`echo -E \\"\$$varname\\" | tr \\\\\\\\\\\\\\\\ / `"
|
||||
EOS
|
||||
}
|
||||
if (/if\s+test\s+-z\s+\"\$INSTALL\"/) {
|
||||
$checking_install = 1;
|
||||
}
|
||||
$checking_install = $checking_path = 0 if /^\s*done\s*$/;
|
||||
# We want to create an extra line like this one:
|
||||
# ac_dir="`echo -E \"$ac_dir\" | tr \\\\\\\\ / `"
|
||||
s{^((\s*)if\s+test)\s*-f\s*(\$$varname/\S+)\s*;}
|
||||
{$2$subst$1 -f $3 -o -f $3.exe ;}
|
||||
if $checking_path; # Checking for executables
|
||||
# change |/usr/sbin/*| to |/usr/sbin/*|?:[\\/]os2[\\/]install[\\/]*|
|
||||
# in the list of things to skip (with both cases)
|
||||
s{\Q|/usr/sbin/*|}
|
||||
{|/usr/sbin/*|?:[\\\\/]os2[\\\\/]install[\\\\/]*|?:[\\\\/]OS2[\\\\/]INSTALL[\\\\/]*|}
|
||||
if $checking_install; # Do not accept d:/os2/install/install.exe
|
||||
s/^(host|build)=NONE$/$1=x86-emx-os2/; # Make default host/build
|
||||
s/"\$\{IFS}:"$/"\${IFS};"/; # Fix IFS line
|
||||
s/\bIFS=\":\"$/IFS=";"/; # Fix another IFS line
|
||||
s/\btest\s+-s\s+conftest\b/test -f conftest/g; # Fix exe test
|
||||
# This one is needed for curses:
|
||||
s/^\s*host=`.*\$ac_config_sub \$host_alias`/$&\nif test -z "\$host"; then host=\$host_alias; fi/;
|
||||
s,/bin/sh(?![/\w]),sh,g;
|
||||
s,^(\s*/usr/sbin/sendmail\s*)\\$,$1 "`whence sendmail | tr '\\\\\\\\' / `" \\,;
|
||||
print;
|
||||
}
|
||||
|
||||
__END__
|
||||
|
||||
Changes: 98/11 : support check for executables in ncurses.
|
||||
99/2 : support INSTALL,
|
||||
new IFS=':' style
|
||||
99/11 : find sendmail
|
||||
00/01 : export CONFIG_SHELL
|
||||
00/10 : new syntax for host=`...` line
|
8
dist.mk
8
dist.mk
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright 2018-2019,2020 Thomas E. Dickey #
|
||||
# Copyright 2018-2020,2021 Thomas E. Dickey #
|
||||
# Copyright 1998-2017,2018 Free Software Foundation, Inc. #
|
||||
# #
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a #
|
||||
@ -26,7 +26,7 @@
|
||||
# use or other dealings in this Software without prior written #
|
||||
# authorization. #
|
||||
##############################################################################
|
||||
# $Id: dist.mk,v 1.1335 2020/02/15 09:30:48 tom Exp $
|
||||
# $Id: dist.mk,v 1.1401 2021/02/20 12:06:34 tom Exp $
|
||||
# Makefile for creating ncurses distributions.
|
||||
#
|
||||
# This only needs to be used directly as a makefile by developers, but
|
||||
@ -38,7 +38,7 @@ SHELL = /bin/sh
|
||||
# These define the major/minor/patch versions of ncurses.
|
||||
NCURSES_MAJOR = 6
|
||||
NCURSES_MINOR = 2
|
||||
NCURSES_PATCH = 20200215
|
||||
NCURSES_PATCH = 20210220
|
||||
|
||||
# We don't append the patch to the version, since this only applies to releases
|
||||
VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
|
||||
@ -97,7 +97,7 @@ doc/hackguide.doc: doc/html/hackguide.html
|
||||
# If that conflicts with the --without-manpage-renames, you can install those
|
||||
# in a different location using the --with-install-prefix option of the
|
||||
# configure script.
|
||||
MANPROG = tbl | nroff -mandoc -rLL=78n -rLT=78n -Tascii
|
||||
MANPROG = tbl | nroff -mandoc -rHY=0 -rLL=78n -rLT=78n -Tascii
|
||||
|
||||
manhtml:
|
||||
@for f in doc/html/man/*.html; do \
|
||||
|
@ -29,7 +29,7 @@
|
||||
<LI><A HREF="../terminal_interface-curses-menus__adb.htm#ref_386_16" TARGET="main">Menu_Win</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_830_16" TARGET="main">Meta</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_109_16" TARGET="main">MMask</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_211_16" TARGET="main">Mouseinterval</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_212_16" TARGET="main">Mouseinterval</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_51_16" TARGET="main">Mouse_Avail</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__ads.htm#ref_154_13" TARGET="main">Mouse_Interval</A>
|
||||
<LI><A HREF="../terminal_interface-curses-forms__ads.htm#ref_614_14" TARGET="main">Move - terminal_interface-curses-forms.ads:614</A>
|
||||
|
@ -12,7 +12,7 @@
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_2037_16" TARGET="main">Unctrl - terminal_interface-curses.adb:2037</A>
|
||||
<LI><A HREF="../terminal_interface-curses__ads.htm#ref_933_14" TARGET="main">Undo_Keystroke</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_540_16" TARGET="main">Ungetch</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_185_16" TARGET="main">Ungetmouse</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_186_16" TARGET="main">Ungetmouse</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__ads.htm#ref_142_14" TARGET="main">Unget_Mouse</A>
|
||||
<LI><A HREF="../terminal_interface-curses__ads.htm#ref_1307_14" TARGET="main">Untouch</A>
|
||||
<LI><A HREF="../terminal_interface-curses__ads.htm#ref_1793_14" TARGET="main">Un_Control - terminal_interface-curses.ads:1793</A>
|
||||
|
@ -26,7 +26,7 @@
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_1576_16" TARGET="main">Wdelch</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_255_16" TARGET="main">Wdelwin</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_209_16" TARGET="main">Wechochar</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_196_16" TARGET="main">Wenclose</A>
|
||||
<LI><A HREF="../terminal_interface-curses-mouse__adb.htm#ref_197_16" TARGET="main">Wenclose</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_1121_16" TARGET="main">Werase</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_1185_16" TARGET="main">Wgetbkgd</A>
|
||||
<LI><A HREF="../terminal_interface-curses__adb.htm#ref_526_16" TARGET="main">Wgetch</A>
|
||||
|
@ -53,8 +53,8 @@
|
||||
<span class="comment"><EM>------------------------------------------------------------------------------</EM></span>
|
||||
<span class="comment"><EM>-- Author: Juergen Pfeifer, 1996</EM></span>
|
||||
<span class="comment"><EM>-- Version Control:</EM></span>
|
||||
<span class="comment"><EM>-- @Revision: 1.27 @</EM></span>
|
||||
<span class="comment"><EM>-- @Date: 2020/02/02 23:34:34 @</EM></span>
|
||||
<span class="comment"><EM>-- @Revision: 1.28 @</EM></span>
|
||||
<span class="comment"><EM>-- @Date: 2020/06/27 18:50:44 @</EM></span>
|
||||
<span class="comment"><EM>-- Binding Version 01.00</EM></span>
|
||||
<span class="comment"><EM>------------------------------------------------------------------------------</EM></span>
|
||||
<b>with</b> <A HREF="terminal_interface__ads.htm#ref_43_9">Terminal_Interface</A>.<A HREF="terminal_interface-curses__ads.htm#ref_48_28">Curses</A>.<A HREF="terminal_interface-curses-aux__ads.htm#ref_46_35">Aux</A>; <b>use</b> <A HREF="terminal_interface__ads.htm#ref_43_9">Terminal_Interface</A>.<A HREF="terminal_interface-curses__ads.htm#ref_48_28">Curses</A>.<A HREF="terminal_interface-curses-aux__ads.htm#ref_46_35">Aux</A>;
|
||||
@ -164,10 +164,11 @@
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_131_30">Button</A> := <A HREF="terminal_interface-curses-mouse__ads.htm#ref_64_26">Button4</A>;
|
||||
<b>end</b> <b>if</b>;
|
||||
<b>if</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_131_30">Button</A> <b>in</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_69_12">Real_Buttons</A> <b>then</b>
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_132_30">State</A> := <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_26">Released</A>; <span class="comment"><EM>-- preset to non real button;</EM></span>
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_137_7">L</A> := 2 ** (6 * <A HREF="terminal_interface-curses-mouse__ads.htm#ref_61_9">Mouse_Button</A>'Pos (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_131_30">Button</A>));
|
||||
<b>for</b> <span class="symbol"><A NAME="ref_151_14">I</A></span> <b>in</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>'<b>Range</b> <b>loop</b>
|
||||
<b>for</b> <span class="symbol"><A NAME="ref_152_14">I</A></span> <b>in</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>'<b>Range</b> <b>loop</b>
|
||||
<b>if</b> (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_130_30">Mask</A> <b>and</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_137_7">L</A>) /= 0 <b>then</b>
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_132_30">State</A> := <A HREF="terminal_interface-curses-mouse__adb.htm#ref_151_14">I</A>;
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_132_30">State</A> := <A HREF="terminal_interface-curses-mouse__adb.htm#ref_152_14">I</A>;
|
||||
<b>exit</b>;
|
||||
<b>end</b> <b>if</b>;
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_137_7">L</A> := 2 * <A HREF="terminal_interface-curses-mouse__adb.htm#ref_137_7">L</A>;
|
||||
@ -184,37 +185,37 @@
|
||||
<b>end</b> <b>if</b>;
|
||||
<b>end</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_130_14">Dispatch_Event</A>;
|
||||
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_170_14" HREF="terminal_interface-curses-mouse__ads.htm#ref_130_14">Get_Event</A></span> (<span class="symbol"><A NAME="ref_170_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>;
|
||||
<span class="symbol"><A NAME="ref_171_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_131_25">Y</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_59_9">Line_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_172_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_132_25">X</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_60_9">Column_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_173_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_133_25">Button</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_61_9">Mouse_Button</A>;
|
||||
<span class="symbol"><A NAME="ref_174_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_134_25">State</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>)
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_171_14" HREF="terminal_interface-curses-mouse__ads.htm#ref_130_14">Get_Event</A></span> (<span class="symbol"><A NAME="ref_171_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>;
|
||||
<span class="symbol"><A NAME="ref_172_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_131_25">Y</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_59_9">Line_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_173_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_132_25">X</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_60_9">Column_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_174_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_133_25">Button</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_61_9">Mouse_Button</A>;
|
||||
<span class="symbol"><A NAME="ref_175_25" HREF="terminal_interface-curses-mouse__ads.htm#ref_134_25">State</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>)
|
||||
<b>is</b>
|
||||
<span class="symbol"><A NAME="ref_176_7">Mask</A></span> : <b>constant</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_57_9">Event_Mask</A> := <A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_170_10">Bstate</A>;
|
||||
<span class="symbol"><A NAME="ref_177_7">Mask</A></span> : <b>constant</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_57_9">Event_Mask</A> := <A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_170_10">Bstate</A>;
|
||||
<b>begin</b>
|
||||
<A HREF="terminal_interface-curses-mouse__ads.htm#ref_132_25">X</A> := <A HREF="terminal_interface-curses__ads.htm#ref_60_9">Column_Position</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_10">X</A>);
|
||||
<A HREF="terminal_interface-curses-mouse__ads.htm#ref_131_25">Y</A> := <A HREF="terminal_interface-curses__ads.htm#ref_59_9">Line_Position</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_25">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_13">Y</A>);
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_130_14">Dispatch_Event</A> (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_176_7">Mask</A>, <A HREF="terminal_interface-curses-mouse__ads.htm#ref_133_25">Button</A>, <A HREF="terminal_interface-curses-mouse__ads.htm#ref_134_25">State</A>);
|
||||
<A HREF="terminal_interface-curses-mouse__adb.htm#ref_130_14">Dispatch_Event</A> (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_177_7">Mask</A>, <A HREF="terminal_interface-curses-mouse__ads.htm#ref_133_25">Button</A>, <A HREF="terminal_interface-curses-mouse__ads.htm#ref_134_25">State</A>);
|
||||
<b>end</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_14">Get_Event</A>;
|
||||
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_183_14" HREF="terminal_interface-curses-mouse__ads.htm#ref_142_14">Unget_Mouse</A></span> (<span class="symbol"><A NAME="ref_183_27" HREF="terminal_interface-curses-mouse__ads.htm#ref_142_27">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>)
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_184_14" HREF="terminal_interface-curses-mouse__ads.htm#ref_142_14">Unget_Mouse</A></span> (<span class="symbol"><A NAME="ref_184_27" HREF="terminal_interface-curses-mouse__ads.htm#ref_142_27">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>)
|
||||
<b>is</b>
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_185_16">Ungetmouse</A></span> (<span class="symbol"><A NAME="ref_185_28" HREF="terminal_interface-curses-mouse__adb.htm#ref_185_16">Ev</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>;
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_186_16">Ungetmouse</A></span> (<span class="symbol"><A NAME="ref_186_28" HREF="terminal_interface-curses-mouse__adb.htm#ref_186_16">Ev</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>;
|
||||
<b>pragma</b> Import (C, Ungetmouse, "ungetmouse");
|
||||
<b>begin</b>
|
||||
<b>if</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_185_16">Ungetmouse</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_142_27">Event</A>) = <A HREF="terminal_interface-curses-aux__ads.htm#ref_64_4">Curses_Err</A> <b>then</b>
|
||||
<b>if</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_186_16">Ungetmouse</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_142_27">Event</A>) = <A HREF="terminal_interface-curses-aux__ads.htm#ref_64_4">Curses_Err</A> <b>then</b>
|
||||
<b>raise</b> <A HREF="terminal_interface-curses__ads.htm#ref_522_4">Curses_Exception</A>;
|
||||
<b>end</b> <b>if</b>;
|
||||
<b>end</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_142_14">Unget_Mouse</A>;
|
||||
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_193_13" HREF="terminal_interface-curses-mouse__ads.htm#ref_147_13">Enclosed_In_Window</A></span> (<span class="symbol"><A NAME="ref_193_33" HREF="terminal_interface-curses-mouse__ads.htm#ref_147_33">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A> := <A HREF="terminal_interface-curses__ads.htm#ref_645_13">Standard_Window</A>;
|
||||
<span class="symbol"><A NAME="ref_194_33" HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> Boolean
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_194_13" HREF="terminal_interface-curses-mouse__ads.htm#ref_147_13">Enclosed_In_Window</A></span> (<span class="symbol"><A NAME="ref_194_33" HREF="terminal_interface-curses-mouse__ads.htm#ref_147_33">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A> := <A HREF="terminal_interface-curses__ads.htm#ref_645_13">Standard_Window</A>;
|
||||
<span class="symbol"><A NAME="ref_195_33" HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> Boolean
|
||||
<b>is</b>
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_196_16">Wenclose</A></span> (<span class="symbol"><A NAME="ref_196_26" HREF="terminal_interface-curses-mouse__adb.htm#ref_196_16">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A>; <span class="symbol"><A NAME="ref_196_40" HREF="terminal_interface-curses-mouse__adb.htm#ref_196_16">Y</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>; <span class="symbol"><A NAME="ref_196_51" HREF="terminal_interface-curses-mouse__adb.htm#ref_196_16">X</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>)
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_197_16">Wenclose</A></span> (<span class="symbol"><A NAME="ref_197_26" HREF="terminal_interface-curses-mouse__adb.htm#ref_197_16">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A>; <span class="symbol"><A NAME="ref_197_40" HREF="terminal_interface-curses-mouse__adb.htm#ref_197_16">Y</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>; <span class="symbol"><A NAME="ref_197_51" HREF="terminal_interface-curses-mouse__adb.htm#ref_197_16">X</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>)
|
||||
<b>return</b> <A HREF="terminal_interface-curses__ads.htm#ref_2099_9">Curses_Bool</A>;
|
||||
<b>pragma</b> Import (C, Wenclose, "wenclose");
|
||||
<b>begin</b>
|
||||
<b>if</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_196_16">Wenclose</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_147_33">Win</A>, <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_13">Y</A>), <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_10">X</A>))
|
||||
<b>if</b> <A HREF="terminal_interface-curses-mouse__adb.htm#ref_197_16">Wenclose</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_147_33">Win</A>, <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_13">Y</A>), <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_148_33">Event</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_168_10">X</A>))
|
||||
= <A HREF="terminal_interface-curses__ads.htm#ref_2101_4">Curses_Bool_False</A>
|
||||
<b>then</b>
|
||||
<b>return</b> False;
|
||||
@ -223,12 +224,12 @@
|
||||
<b>end</b> <b>if</b>;
|
||||
<b>end</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_147_13">Enclosed_In_Window</A>;
|
||||
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_209_13" HREF="terminal_interface-curses-mouse__ads.htm#ref_154_13">Mouse_Interval</A></span> (<span class="symbol"><A NAME="ref_209_29" HREF="terminal_interface-curses-mouse__ads.htm#ref_154_29">Msec</A></span> : Natural := 200) <b>return</b> Natural
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_210_13" HREF="terminal_interface-curses-mouse__ads.htm#ref_154_13">Mouse_Interval</A></span> (<span class="symbol"><A NAME="ref_210_29" HREF="terminal_interface-curses-mouse__ads.htm#ref_154_29">Msec</A></span> : Natural := 200) <b>return</b> Natural
|
||||
<b>is</b>
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_211_16">Mouseinterval</A></span> (<span class="symbol"><A NAME="ref_211_31" HREF="terminal_interface-curses-mouse__adb.htm#ref_211_16">Msec</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>) <b>return</b> <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>;
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_212_16">Mouseinterval</A></span> (<span class="symbol"><A NAME="ref_212_31" HREF="terminal_interface-curses-mouse__adb.htm#ref_212_16">Msec</A></span> : <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>) <b>return</b> <A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A>;
|
||||
<b>pragma</b> Import (C, Mouseinterval, "mouseinterval");
|
||||
<b>begin</b>
|
||||
<b>return</b> Natural (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_211_16">Mouseinterval</A> (<A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_154_29">Msec</A>)));
|
||||
<b>return</b> Natural (<A HREF="terminal_interface-curses-mouse__adb.htm#ref_212_16">Mouseinterval</A> (<A HREF="terminal_interface-curses-aux__ads.htm#ref_49_12">C_Int</A> (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_154_29">Msec</A>)));
|
||||
<b>end</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_154_13">Mouse_Interval</A>;
|
||||
|
||||
<b>end</b> <A HREF="terminal_interface__ads.htm#ref_43_9">Terminal_Interface</A>.<A HREF="terminal_interface-curses__ads.htm#ref_48_28">Curses</A>.<A HREF="terminal_interface-curses-mouse__ads.htm#ref_45_35">Mouse</A>;
|
||||
|
@ -144,11 +144,11 @@
|
||||
<span class="comment"><EM>-- AKA: <A HREF="../man/curs_mouse.3x.html">getmouse()</A></EM></span>
|
||||
<b>pragma</b> Inline (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_126_13">Get_Mouse</A>);
|
||||
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_130_14" HREF="terminal_interface-curses-mouse__adb.htm#ref_170_14">Get_Event</A></span> (<span class="symbol"><A NAME="ref_130_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_170_25">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>;
|
||||
<span class="symbol"><A NAME="ref_131_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_171_25">Y</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_59_9">Line_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_132_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_172_25">X</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_60_9">Column_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_133_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_173_25">Button</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_61_9">Mouse_Button</A>;
|
||||
<span class="symbol"><A NAME="ref_134_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_174_25">State</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>);
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_130_14" HREF="terminal_interface-curses-mouse__adb.htm#ref_171_14">Get_Event</A></span> (<span class="symbol"><A NAME="ref_130_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_171_25">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>;
|
||||
<span class="symbol"><A NAME="ref_131_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_172_25">Y</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_59_9">Line_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_132_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_173_25">X</A></span> : <b>out</b> <A HREF="terminal_interface-curses__ads.htm#ref_60_9">Column_Position</A>;
|
||||
<span class="symbol"><A NAME="ref_133_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_174_25">Button</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_61_9">Mouse_Button</A>;
|
||||
<span class="symbol"><A NAME="ref_134_25" HREF="terminal_interface-curses-mouse__adb.htm#ref_175_25">State</A></span> : <b>out</b> <A HREF="terminal_interface-curses-mouse__ads.htm#ref_72_9">Button_State</A>);
|
||||
<span class="comment"><EM>-- !!! Warning: X and Y are screen coordinates. Due to ripped of lines they</EM></span>
|
||||
<span class="comment"><EM>-- may not be identical to window coordinates.</EM></span>
|
||||
<span class="comment"><EM>-- Not Implemented: Get_Event only reports one event, the C library</EM></span>
|
||||
@ -156,19 +156,19 @@
|
||||
<b>pragma</b> Inline (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_130_14">Get_Event</A>);
|
||||
|
||||
<span class="comment"><EM>-- <A NAME="AFU_3">|</A></EM></span>
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_142_14" HREF="terminal_interface-curses-mouse__adb.htm#ref_183_14">Unget_Mouse</A></span> (<span class="symbol"><A NAME="ref_142_27" HREF="terminal_interface-curses-mouse__adb.htm#ref_183_27">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>);
|
||||
<b>procedure</b> <span class="symbol"><A NAME="ref_142_14" HREF="terminal_interface-curses-mouse__adb.htm#ref_184_14">Unget_Mouse</A></span> (<span class="symbol"><A NAME="ref_142_27" HREF="terminal_interface-curses-mouse__adb.htm#ref_184_27">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>);
|
||||
<span class="comment"><EM>-- AKA: <A HREF="../man/curs_mouse.3x.html">ungetmouse()</A></EM></span>
|
||||
<b>pragma</b> Inline (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_142_14">Unget_Mouse</A>);
|
||||
|
||||
<span class="comment"><EM>-- <A NAME="AFU_4">|</A></EM></span>
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_147_13" HREF="terminal_interface-curses-mouse__adb.htm#ref_193_13">Enclosed_In_Window</A></span> (<span class="symbol"><A NAME="ref_147_33" HREF="terminal_interface-curses-mouse__adb.htm#ref_193_33">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A> := <A HREF="terminal_interface-curses__ads.htm#ref_645_13">Standard_Window</A>;
|
||||
<span class="symbol"><A NAME="ref_148_33" HREF="terminal_interface-curses-mouse__adb.htm#ref_194_33">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> Boolean;
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_147_13" HREF="terminal_interface-curses-mouse__adb.htm#ref_194_13">Enclosed_In_Window</A></span> (<span class="symbol"><A NAME="ref_147_33" HREF="terminal_interface-curses-mouse__adb.htm#ref_194_33">Win</A></span> : <A HREF="terminal_interface-curses__ads.htm#ref_56_9">Window</A> := <A HREF="terminal_interface-curses__ads.htm#ref_645_13">Standard_Window</A>;
|
||||
<span class="symbol"><A NAME="ref_148_33" HREF="terminal_interface-curses-mouse__adb.htm#ref_195_33">Event</A></span> : <A HREF="terminal_interface-curses-mouse__ads.htm#ref_85_9">Mouse_Event</A>) <b>return</b> Boolean;
|
||||
<span class="comment"><EM>-- AKA: <A HREF="../man/curs_mouse.3x.html">wenclose()</A></EM></span>
|
||||
<span class="comment"><EM>-- But : use event instead of screen coordinates.</EM></span>
|
||||
<b>pragma</b> Inline (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_147_13">Enclosed_In_Window</A>);
|
||||
|
||||
<span class="comment"><EM>-- <A NAME="AFU_5">|</A></EM></span>
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_154_13" HREF="terminal_interface-curses-mouse__adb.htm#ref_209_13">Mouse_Interval</A></span> (<span class="symbol"><A NAME="ref_154_29" HREF="terminal_interface-curses-mouse__adb.htm#ref_209_29">Msec</A></span> : Natural := 200) <b>return</b> Natural;
|
||||
<b>function</b> <span class="symbol"><A NAME="ref_154_13" HREF="terminal_interface-curses-mouse__adb.htm#ref_210_13">Mouse_Interval</A></span> (<span class="symbol"><A NAME="ref_154_29" HREF="terminal_interface-curses-mouse__adb.htm#ref_210_29">Msec</A></span> : Natural := 200) <b>return</b> Natural;
|
||||
<span class="comment"><EM>-- AKA: <A HREF="../man/curs_mouse.3x.html">mouseinterval()</A></EM></span>
|
||||
<b>pragma</b> Inline (<A HREF="terminal_interface-curses-mouse__ads.htm#ref_154_13">Mouse_Interval</A>);
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$Id: announce.html,v 1.61 2020/02/09 21:26:51 tom Exp $
|
||||
$Id: announce.html,v 1.64 2020/10/19 08:18:48 tom Exp $
|
||||
****************************************************************************
|
||||
* Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
* *
|
||||
@ -356,7 +356,7 @@
|
||||
|
||||
<li>
|
||||
<p>marked <a href=
|
||||
"https://invisible-island.net/ncurses/man/curs_printw.3x.html#h3-PORTABILITY">
|
||||
"https://invisible-island.net/ncurses/man/curs_printw.3x.html#h2-PORTABILITY">
|
||||
<tt>vwprintw</tt></a> and <tt>vwscanw</tt> as deprecated;
|
||||
recommend using <a href=
|
||||
"https://invisible-island.net/ncurses/man/curs_printw.3x.html">
|
||||
@ -520,7 +520,8 @@
|
||||
<h3><a name="h3-programs" id="h3-programs">Program
|
||||
improvements</a></h3>
|
||||
|
||||
<p>Several improvements were made to the utility programs:</p>
|
||||
<p id="h4-utilities">Several improvements were made to the
|
||||
utility programs:</p>
|
||||
|
||||
<dl>
|
||||
<dt><span class="part-name">clear</span>
|
||||
@ -1073,7 +1074,7 @@
|
||||
with a different developer.</li>
|
||||
|
||||
<li><a href=
|
||||
"https://invisible-island.net/ncurses/man/tabs.1">tabs.1</a>
|
||||
"https://invisible-island.net/ncurses/man/tabs.1.html">tabs.1</a>
|
||||
tells more than you wanted to know about the tool.</li>
|
||||
|
||||
<li><a href=
|
||||
@ -1117,7 +1118,7 @@
|
||||
the line-drawing characters.</li>
|
||||
|
||||
<li><a href=
|
||||
"https://invisible-island.net/ncurses/man/curs_color.3x.html#h3-RETURN-VALUE">
|
||||
"https://invisible-island.net/ncurses/man/curs_color.3x.html#h2-RETURN-VALUE">
|
||||
curs_color.3x</a> improves discussion of error returns and
|
||||
extensions.</li>
|
||||
|
||||
|
@ -126,7 +126,7 @@
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>
|
||||
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20200215).
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20210109).
|
||||
|
||||
|
||||
|
||||
|
@ -57,9 +57,9 @@
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
<STRONG>captoinfo</STRONG> looks in each given text <EM>file</EM> for <STRONG>termcap</STRONG> descriptions. For
|
||||
each one found, an equivalent <STRONG>terminfo</STRONG> description is written to stan-
|
||||
dard output. Termcap <STRONG>tc</STRONG> capabilities are translated directly to ter-
|
||||
minfo <STRONG>use</STRONG> capabilities.
|
||||
each one found, an equivalent <STRONG>terminfo</STRONG> description is written to
|
||||
standard output. Termcap <STRONG>tc</STRONG> capabilities are translated directly to
|
||||
terminfo <STRONG>use</STRONG> capabilities.
|
||||
|
||||
If no <EM>file</EM> is given, then the environment variable <STRONG>TERMCAP</STRONG> is used for
|
||||
the filename or entry. If <STRONG>TERMCAP</STRONG> is a full pathname to a file, only
|
||||
@ -155,9 +155,9 @@
|
||||
Gc intersection
|
||||
GG acs magic cookie count
|
||||
|
||||
If the single-line capabilities occur in an entry, they will automati-
|
||||
cally be composed into an <STRONG>acsc</STRONG> string. The double-line capabilities
|
||||
and <STRONG>GG</STRONG> are discarded with a warning message.
|
||||
If the single-line capabilities occur in an entry, they will
|
||||
automatically be composed into an <STRONG>acsc</STRONG> string. The double-line
|
||||
capabilities and <STRONG>GG</STRONG> are discarded with a warning message.
|
||||
|
||||
IBM's AIX has a terminfo facility descended from SVr1 terminfo but
|
||||
incompatible with the SVr4 format. The following AIX extensions are
|
||||
@ -199,7 +199,7 @@
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="infocmp.1m.html">infocmp(1m)</A></STRONG>, <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>
|
||||
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20200215).
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20210109).
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-AUTHOR">AUTHOR</a></H2><PRE>
|
||||
|
@ -71,10 +71,10 @@
|
||||
|
||||
</PRE><H2><a name="h2-OPTIONS">OPTIONS</a></H2><PRE>
|
||||
<STRONG>-T</STRONG> <EM>type</EM>
|
||||
indicates the <EM>type</EM> of terminal. Normally this option is unneces-
|
||||
sary, because the default is taken from the environment variable
|
||||
<STRONG>TERM</STRONG>. If <STRONG>-T</STRONG> is specified, then the shell variables <STRONG>LINES</STRONG> and <STRONG>COL-</STRONG>
|
||||
<STRONG>UMNS</STRONG> will also be ignored.
|
||||
indicates the <EM>type</EM> of terminal. Normally this option is
|
||||
unnecessary, because the default is taken from the environment
|
||||
variable <STRONG>TERM</STRONG>. If <STRONG>-T</STRONG> is specified, then the shell variables <STRONG>LINES</STRONG>
|
||||
and <STRONG>COLUMNS</STRONG> will also be ignored.
|
||||
|
||||
<STRONG>-V</STRONG> reports the version of ncurses which was used in this program, and
|
||||
exits. The options are as follows:
|
||||
@ -94,20 +94,21 @@
|
||||
/usr/bin/tput ${1:+-T$1} clear 2> /dev/null
|
||||
exit
|
||||
|
||||
In 1989, when Keith Bostic revised the BSD <STRONG>tput</STRONG> command to make it sim-
|
||||
ilar to the AT&T <STRONG>tput</STRONG>, he added a shell script for the <STRONG>clear</STRONG> command:
|
||||
In 1989, when Keith Bostic revised the BSD <STRONG>tput</STRONG> command to make it
|
||||
similar to the AT&T <STRONG>tput</STRONG>, he added a shell script for the <STRONG>clear</STRONG>
|
||||
command:
|
||||
|
||||
exec tput clear
|
||||
|
||||
The remainder of the script in each case is a copyright notice.
|
||||
|
||||
The ncurses <STRONG>clear</STRONG> command began in 1995 by adapting the original BSD
|
||||
The ncurses <STRONG>clear</STRONG> command began in 1995 by adapting the original BSD
|
||||
<STRONG>clear</STRONG> command (with terminfo, of course).
|
||||
|
||||
The <STRONG>E3</STRONG> extension came later:
|
||||
|
||||
<STRONG>o</STRONG> In June 1999, xterm provided an extension to the standard control
|
||||
sequence for clearing the screen. Rather than clearing just the
|
||||
<STRONG>o</STRONG> In June 1999, xterm provided an extension to the standard control
|
||||
sequence for clearing the screen. Rather than clearing just the
|
||||
visible part of the screen using
|
||||
|
||||
printf '\033[2J'
|
||||
@ -116,24 +117,24 @@
|
||||
|
||||
printf '\033[<STRONG>3</STRONG>J'
|
||||
|
||||
This is documented in <EM>XTerm</EM> <EM>Control</EM> <EM>Sequences</EM> as a feature origi-
|
||||
nating with xterm.
|
||||
This is documented in <EM>XTerm</EM> <EM>Control</EM> <EM>Sequences</EM> as a feature
|
||||
originating with xterm.
|
||||
|
||||
<STRONG>o</STRONG> A few other terminal developers adopted the feature, e.g., PuTTY in
|
||||
2006.
|
||||
|
||||
<STRONG>o</STRONG> In April 2011, a Red Hat developer submitted a patch to the Linux
|
||||
kernel, modifying its console driver to do the same thing. The
|
||||
Linux change, part of the 3.0 release, did not mention xterm,
|
||||
<STRONG>o</STRONG> In April 2011, a Red Hat developer submitted a patch to the Linux
|
||||
kernel, modifying its console driver to do the same thing. The
|
||||
Linux change, part of the 3.0 release, did not mention xterm,
|
||||
although it was cited in the Red Hat bug report (#683733) which led
|
||||
to the change.
|
||||
|
||||
<STRONG>o</STRONG> Again, a few other terminal developers adopted the feature. But
|
||||
<STRONG>o</STRONG> Again, a few other terminal developers adopted the feature. But
|
||||
the next relevant step was a change to the <STRONG>clear</STRONG> program in 2013 to
|
||||
incorporate this extension.
|
||||
|
||||
<STRONG>o</STRONG> In 2013, the <STRONG>E3</STRONG> extension was overlooked in <STRONG>tput</STRONG> with the "clear"
|
||||
parameter. That was addressed in 2016 by reorganizing <STRONG>tput</STRONG> to
|
||||
<STRONG>o</STRONG> In 2013, the <STRONG>E3</STRONG> extension was overlooked in <STRONG>tput</STRONG> with the "clear"
|
||||
parameter. That was addressed in 2016 by reorganizing <STRONG>tput</STRONG> to
|
||||
share its logic with <STRONG>clear</STRONG> and <STRONG>tset</STRONG>.
|
||||
|
||||
|
||||
@ -141,15 +142,15 @@
|
||||
Neither IEEE Std 1003.1/The Open Group Base Specifications Issue 7
|
||||
(POSIX.1-2008) nor X/Open Curses Issue 7 documents tset or reset.
|
||||
|
||||
The latter documents <STRONG>tput</STRONG>, which could be used to replace this utility
|
||||
either via a shell script or by an alias (such as a symbolic link) to
|
||||
The latter documents <STRONG>tput</STRONG>, which could be used to replace this utility
|
||||
either via a shell script or by an alias (such as a symbolic link) to
|
||||
run <STRONG>tput</STRONG> as <STRONG>clear</STRONG>.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="tput.1.html">tput(1)</A></STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>
|
||||
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20200215).
|
||||
This describes <STRONG>ncurses</STRONG> version 6.2 (patch 20210109).
|
||||
|
||||
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_add_wch.3x,v 1.26 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_add_wch.3x,v 1.28 2020/10/17 23:10:38 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>wadd_wch(</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvadd_wch(</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwadd_wch(</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>echo_wchar(</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wecho_wchar(</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
|
||||
@ -66,20 +67,20 @@
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
||||
</PRE><H3><a name="h3-add_wch">add_wch</a></H3><PRE>
|
||||
The <STRONG>add_wch</STRONG>, <STRONG>wadd_wch</STRONG>, <STRONG>mvadd_wch</STRONG>, and <STRONG>mvwadd_wch</STRONG> functions put the com-
|
||||
plex character <EM>wch</EM> into the given window at its current position, which
|
||||
is then advanced. These functions perform wrapping and special-charac-
|
||||
ter processing as follows:
|
||||
The <STRONG>add_wch</STRONG>, <STRONG>wadd_wch</STRONG>, <STRONG>mvadd_wch</STRONG>, and <STRONG>mvwadd_wch</STRONG> functions put the
|
||||
complex character <EM>wch</EM> into the given window at its current position,
|
||||
which is then advanced. These functions perform wrapping and special-
|
||||
character processing as follows:
|
||||
|
||||
<STRONG>o</STRONG> If <EM>wch</EM> refers to a spacing character, then any previous character
|
||||
at that location is removed. A new character specified by <EM>wch</EM> is
|
||||
placed at that location with rendition specified by <EM>wch</EM>. The cur-
|
||||
sor then advances to the next spacing character on the screen.
|
||||
placed at that location with rendition specified by <EM>wch</EM>. The
|
||||
cursor then advances to the next spacing character on the screen.
|
||||
|
||||
<STRONG>o</STRONG> If <EM>wch</EM> refers to a non-spacing character, all previous characters
|
||||
at that location are preserved. The non-spacing characters of <EM>wch</EM>
|
||||
are added to the spacing complex character, and the rendition spec-
|
||||
ified by <EM>wch</EM> is ignored.
|
||||
are added to the spacing complex character, and the rendition
|
||||
specified by <EM>wch</EM> is ignored.
|
||||
|
||||
<STRONG>o</STRONG> If the character part of <EM>wch</EM> is a tab, newline, backspace or other
|
||||
control character, the window is updated and the cursor moves as if
|
||||
@ -88,18 +89,18 @@
|
||||
|
||||
</PRE><H3><a name="h3-echo_wchar">echo_wchar</a></H3><PRE>
|
||||
The <STRONG>echo_wchar</STRONG> function is functionally equivalent to a call to <STRONG>add_wch</STRONG>
|
||||
followed by a call to <STRONG><A HREF="curs_refresh.3x.html">refresh(3x)</A></STRONG>. Similarly, the <STRONG>wecho_wchar</STRONG> is func-
|
||||
tionally equivalent to a call to <STRONG>wadd_wch</STRONG> followed by a call to <STRONG>wre-</STRONG>
|
||||
<STRONG>fresh</STRONG>. The knowledge that only a single character is being output is
|
||||
taken into consideration and, for non-control characters, a consider-
|
||||
able performance gain might be seen by using the *<STRONG>echo</STRONG>* functions
|
||||
instead of their equivalents.
|
||||
followed by a call to <STRONG><A HREF="curs_refresh.3x.html">refresh(3x)</A></STRONG>. Similarly, the <STRONG>wecho_wchar</STRONG> is
|
||||
functionally equivalent to a call to <STRONG>wadd_wch</STRONG> followed by a call to
|
||||
<STRONG>wrefresh</STRONG>. The knowledge that only a single character is being output
|
||||
is taken into consideration and, for non-control characters, a
|
||||
considerable performance gain might be seen by using the *<STRONG>echo</STRONG>*
|
||||
functions instead of their equivalents.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Line-Graphics">Line Graphics</a></H3><PRE>
|
||||
Like <STRONG><A HREF="curs_addch.3x.html">addch(3x)</A></STRONG>, <STRONG>addch_wch</STRONG> accepts symbols which make it simple to draw
|
||||
lines and other frequently used special characters. These symbols cor-
|
||||
respond to the same VT100 line-drawing set as <STRONG><A HREF="curs_addch.3x.html">addch(3x)</A></STRONG>.
|
||||
lines and other frequently used special characters. These symbols
|
||||
correspond to the same VT100 line-drawing set as <STRONG><A HREF="curs_addch.3x.html">addch(3x)</A></STRONG>.
|
||||
|
||||
<STRONG>ACS</STRONG> <STRONG>Unicode</STRONG> <STRONG>ASCII</STRONG> <STRONG>acsc</STRONG> <STRONG>Glyph</STRONG>
|
||||
<STRONG>Name</STRONG> <STRONG>Default</STRONG> <STRONG>Default</STRONG> <STRONG>char</STRONG> <STRONG>Name</STRONG>
|
||||
@ -111,8 +112,8 @@
|
||||
WACS_CKBOARD 0x2592 : a checker board (stipple)
|
||||
WACS_DARROW 0x2193 v . arrow pointing down
|
||||
WACS_DEGREE 0x00b0 ' f degree symbol
|
||||
WACS_DIAMOND 0x25c6 + ` diamond
|
||||
|
||||
WACS_DIAMOND 0x25c6 + ` diamond
|
||||
WACS_GEQUAL 0x2265 > > greater-than-or-equal-to
|
||||
WACS_HLINE 0x2500 - q horizontal line
|
||||
WACS_LANTERN 0x2603 # i lantern symbol
|
||||
@ -188,7 +189,24 @@
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG> on success.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
X/Open does not define any error conditions. This implementation
|
||||
returns an error
|
||||
|
||||
<STRONG>o</STRONG> if the window pointer is null or
|
||||
|
||||
<STRONG>o</STRONG> if it is not possible to add a complete character in the window.
|
||||
|
||||
The latter may be due to different causes:
|
||||
|
||||
<STRONG>o</STRONG> If <STRONG>scrollok</STRONG> is not enabled, writing a character at the lower right
|
||||
margin succeeds. However, an error is returned because it is not
|
||||
possible to wrap to a new line
|
||||
|
||||
<STRONG>o</STRONG> If an error is detected when converting a multibyte character to a
|
||||
sequence of bytes, or if it is not possible to add all of the
|
||||
resulting bytes in the window, an error is returned.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
<STRONG>wmove</STRONG>, and return an error if the position is outside the window, or if
|
||||
the window pointer is null.
|
||||
|
||||
@ -198,77 +216,77 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
All of these functions are described in the XSI Curses standard, Issue
|
||||
4. The defaults specified for line-drawing characters apply in the
|
||||
All of these functions are described in the XSI Curses standard, Issue
|
||||
4. The defaults specified for line-drawing characters apply in the
|
||||
POSIX locale.
|
||||
|
||||
X/Open Curses makes it clear that the WACS_ symbols should be defined
|
||||
X/Open Curses makes it clear that the WACS_ symbols should be defined
|
||||
as a pointer to <STRONG>cchar_t</STRONG> data, e.g., in the discussion of <STRONG>border_set</STRONG>. A
|
||||
few implementations are problematic:
|
||||
|
||||
<STRONG>o</STRONG> NetBSD curses defines the symbols as a <STRONG>wchar_t</STRONG> within a <STRONG>cchar_t</STRONG>.
|
||||
|
||||
<STRONG>o</STRONG> HPUX curses equates some of the <EM>ACS</EM><STRONG>_</STRONG> symbols to the analogous <EM>WACS</EM><STRONG>_</STRONG>
|
||||
symbols as if the <EM>ACS</EM><STRONG>_</STRONG> symbols were wide characters. The misde-
|
||||
fined symbols are the arrows and other symbols which are not used
|
||||
for line-drawing.
|
||||
symbols as if the <EM>ACS</EM><STRONG>_</STRONG> symbols were wide characters. The
|
||||
misdefined symbols are the arrows and other symbols which are not
|
||||
used for line-drawing.
|
||||
|
||||
X/Open Curses does not define symbols for thick- or double-lines. SVr4
|
||||
curses implementations defined their line-drawing symbols in terms of
|
||||
intermediate symbols. This implementation extends those symbols, pro-
|
||||
viding new definitions which are not in the SVr4 implementations.
|
||||
curses implementations defined their line-drawing symbols in terms of
|
||||
intermediate symbols. This implementation extends those symbols,
|
||||
providing new definitions which are not in the SVr4 implementations.
|
||||
|
||||
Not all Unicode-capable terminals provide support for VT100-style
|
||||
alternate character sets (i.e., the <STRONG>acsc</STRONG> capability), with their corre-
|
||||
sponding line-drawing characters. X/Open Curses did not address the
|
||||
aspect of integrating Unicode with line-drawing characters. Existing
|
||||
implementations of Unix curses (AIX, HPUX, Solaris) use only the <STRONG>acsc</STRONG>
|
||||
character-mapping to provide this feature. As a result, those imple-
|
||||
mentations can only use single-byte line-drawing characters. Ncurses
|
||||
5.3 (2002) provided a table of Unicode values to solve these problems.
|
||||
NetBSD curses incorporated that table in 2010.
|
||||
Not all Unicode-capable terminals provide support for VT100-style
|
||||
alternate character sets (i.e., the <STRONG>acsc</STRONG> capability), with their
|
||||
corresponding line-drawing characters. X/Open Curses did not address
|
||||
the aspect of integrating Unicode with line-drawing characters.
|
||||
Existing implementations of Unix curses (AIX, HPUX, Solaris) use only
|
||||
the <STRONG>acsc</STRONG> character-mapping to provide this feature. As a result, those
|
||||
implementations can only use single-byte line-drawing characters.
|
||||
Ncurses 5.3 (2002) provided a table of Unicode values to solve these
|
||||
problems. NetBSD curses incorporated that table in 2010.
|
||||
|
||||
In this implementation, the Unicode values are used instead of the ter-
|
||||
minal description's <STRONG>acsc</STRONG> mapping as discussed in <STRONG><A HREF="ncurses.3x.html">ncurses(3x)</A></STRONG> for the
|
||||
environment variable <STRONG>NCURSES_NO_UTF8_ACS</STRONG>. In contrast, for the same
|
||||
In this implementation, the Unicode values are used instead of the
|
||||
terminal description's <STRONG>acsc</STRONG> mapping as discussed in <STRONG><A HREF="ncurses.3x.html">ncurses(3x)</A></STRONG> for the
|
||||
environment variable <STRONG>NCURSES_NO_UTF8_ACS</STRONG>. In contrast, for the same
|
||||
cases, the line-drawing characters described in <STRONG><A HREF="curs_addch.3x.html">curs_addch(3x)</A></STRONG> will use
|
||||
only the ASCII default values.
|
||||
|
||||
Having Unicode available does not solve all of the problems with line-
|
||||
Having Unicode available does not solve all of the problems with line-
|
||||
drawing for curses:
|
||||
|
||||
<STRONG>o</STRONG> The closest Unicode equivalents to the VT100 graphics <EM>S1</EM>, <EM>S3</EM>, <EM>S7</EM>
|
||||
and <EM>S9</EM> frequently are not displayed at the regular intervals which
|
||||
<STRONG>o</STRONG> The closest Unicode equivalents to the VT100 graphics <EM>S1</EM>, <EM>S3</EM>, <EM>S7</EM>
|
||||
and <EM>S9</EM> frequently are not displayed at the regular intervals which
|
||||
the terminal used.
|
||||
|
||||
<STRONG>o</STRONG> The <EM>lantern</EM> is a special case. It originated with the AT&T 4410
|
||||
terminal in the early 1980s. There is no accessible documentation
|
||||
<STRONG>o</STRONG> The <EM>lantern</EM> is a special case. It originated with the AT&T 4410
|
||||
terminal in the early 1980s. There is no accessible documentation
|
||||
depicting the lantern symbol on the AT&T terminal.
|
||||
|
||||
Lacking documentation, most readers assume that a <EM>storm</EM> <EM>lantern</EM> was
|
||||
intended. But there are several possibilities, all with problems.
|
||||
|
||||
Unicode 6.0 (2010) does provide two lantern symbols: U+1F383 and
|
||||
U+1F3EE. Those were not available in 2002, and are irrelevant
|
||||
since they lie outside the BMP and as a result are not generally
|
||||
Unicode 6.0 (2010) does provide two lantern symbols: U+1F383 and
|
||||
U+1F3EE. Those were not available in 2002, and are irrelevant
|
||||
since they lie outside the BMP and as a result are not generally
|
||||
available in terminals. They are not storm lanterns, in any case.
|
||||
|
||||
Most <EM>storm</EM> <EM>lanterns</EM> have a tapering glass chimney (to guard against
|
||||
tipping); some have a wire grid protecting the chimney.
|
||||
|
||||
For the tapering appearance, U+2603 was adequate. In use on a
|
||||
For the tapering appearance, U+2603 was adequate. In use on a
|
||||
terminal, no one can tell what the image represents. Unicode calls
|
||||
it a snowman.
|
||||
|
||||
Others have suggested these alternatives: S U+00A7 (section mark),
|
||||
<STRONG>O</STRONG> U+0398 (theta), <STRONG>O</STRONG> U+03A6 (phi), d U+03B4 (delta), U+2327 (x in a
|
||||
rectangle), U+256C (forms double vertical and horizontal), and
|
||||
U+2612 (ballot box with x).
|
||||
Others have suggested these alternatives: <section> U+00A7 (section
|
||||
mark), <Theta> U+0398 (theta), <Phi> U+03A6 (phi), <delta> U+03B4
|
||||
(delta), U+2327 (x in a rectangle), U+256C (forms double vertical
|
||||
and horizontal), and U+2612 (ballot box with x).
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_addch.3x.html">curs_addch(3x)</A></STRONG>, <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>, <STRONG><A HREF="curs_clear.3x.html">curs_clear(3x)</A></STRONG>, <STRONG>curs_out-</STRONG>
|
||||
<STRONG><A HREF="curs_outopts.3x.html">opts(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG>putwc(3)</STRONG>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_addch.3x.html">curs_addch(3x)</A></STRONG>, <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>, <STRONG><A HREF="curs_clear.3x.html">curs_clear(3x)</A></STRONG>,
|
||||
<STRONG><A HREF="curs_outopts.3x.html">curs_outopts(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG>putwc(3)</STRONG>
|
||||
|
||||
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_add_wchstr.3x,v 1.13 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_add_wchstr.3x,v 1.15 2020/12/19 21:39:06 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>add_wchnstr(const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wadd_wchstr(WINDOW</STRONG> <STRONG>*</STRONG> <EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wadd_wchnstr(WINDOW</STRONG> <STRONG>*</STRONG> <EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvadd_wchstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvadd_wchnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwadd_wchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
@ -112,7 +113,7 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="curs_addwstr.3x.html">curs_addwstr(3x)</A></STRONG>, <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>.
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_addwstr.3x.html">curs_addwstr(3x)</A></STRONG>.
|
||||
|
||||
Comparable functions in the narrow-character (ncurses) library are de-
|
||||
scribed in <STRONG><A HREF="curs_addchstr.3x.html">curs_addchstr(3x)</A></STRONG>.
|
||||
|
@ -28,7 +28,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_addch.3x,v 1.51 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_addch.3x,v 1.55 2020/10/24 09:12:31 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,12 +55,13 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>addch(const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddch(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>echochar(const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wechochar(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>addch(const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>echochar(const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wechochar(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -95,34 +96,35 @@
|
||||
<STRONG>o</STRONG> Tabs are considered to be at every eighth column. The tab interval
|
||||
may be altered by setting the <STRONG>TABSIZE</STRONG> variable.
|
||||
|
||||
If <EM>ch</EM> is any other control character, it is drawn in <STRONG>^</STRONG><EM>X</EM> notation.
|
||||
Calling <STRONG>winch</STRONG> after adding a control character does not return the
|
||||
character itself, but instead returns the ^-representation of the con-
|
||||
trol character.
|
||||
If <EM>ch</EM> is any other nonprintable character, it is drawn in printable
|
||||
form, i.e., the <STRONG>^</STRONG><EM>X</EM> notation used by <STRONG><A HREF="unctrl.3x.html">unctrl(3x)</A></STRONG>. Calling <STRONG>winch</STRONG> after
|
||||
adding a nonprintable character does not return the character itself,
|
||||
but instead returns the printable representation of the character.
|
||||
|
||||
Video attributes can be combined with a character argument passed to
|
||||
<STRONG>addch</STRONG> or related functions by logical-ORing them into the character.
|
||||
(Thus, text, including attributes, can be copied from one place to
|
||||
another using <STRONG><A HREF="curs_inch.3x.html">inch(3x)</A></STRONG> and <STRONG>addch</STRONG>.) See the <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG> page for val-
|
||||
ues of predefined video attribute constants that can be usefully OR'ed
|
||||
into characters.
|
||||
another using <STRONG><A HREF="curs_inch.3x.html">inch(3x)</A></STRONG> and <STRONG>addch</STRONG>.) See the <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG> page for
|
||||
values of predefined video attribute constants that can be usefully
|
||||
OR'ed into characters.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Echoing-characters">Echoing characters</a></H3><PRE>
|
||||
The <STRONG>echochar</STRONG> and <STRONG>wechochar</STRONG> routines are equivalent to a call to <STRONG>addch</STRONG>
|
||||
followed by a call to <STRONG><A HREF="curs_refresh.3x.html">refresh(3x)</A></STRONG>, or a call to <STRONG>waddch</STRONG> followed by a
|
||||
call to <STRONG>wrefresh</STRONG>. The knowledge that only a single character is being
|
||||
output is used and, for non-control characters, a considerable perfor-
|
||||
mance gain may be seen by using these routines instead of their equiva-
|
||||
lents.
|
||||
output is used and, for non-control characters, a considerable
|
||||
performance gain may be seen by using these routines instead of their
|
||||
equivalents.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Line-Graphics">Line Graphics</a></H3><PRE>
|
||||
The following variables may be used to add line drawing characters to
|
||||
the screen with routines of the <STRONG>addch</STRONG> family. The default character
|
||||
listed below is used if the <STRONG>acsc</STRONG> capability does not define a terminal-
|
||||
specific replacement for it, or if the terminal and locale configura-
|
||||
tion requires Unicode but the library is unable to use Unicode.
|
||||
specific replacement for it, or if the terminal and locale
|
||||
configuration requires Unicode but the library is unable to use
|
||||
Unicode.
|
||||
|
||||
The names are taken from VT100 nomenclature.
|
||||
|
||||
@ -165,14 +167,25 @@
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG> on success (the
|
||||
SVr4 manuals specify only "an integer value other than <STRONG>ERR</STRONG>") upon suc-
|
||||
cessful completion, unless otherwise noted in the preceding routine
|
||||
SVr4 manuals specify only "an integer value other than <STRONG>ERR</STRONG>") upon
|
||||
successful completion, unless otherwise noted in the preceding routine
|
||||
descriptions.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
<STRONG>wmove</STRONG>, and return an error if the position is outside the window, or if
|
||||
the window pointer is null.
|
||||
|
||||
If it is not possible to add a complete character, an error is
|
||||
returned:
|
||||
|
||||
<STRONG>o</STRONG> If <STRONG>scrollok</STRONG> is not enabled, writing a character at the lower right
|
||||
margin succeeds. However, an error is returned because it is not
|
||||
possible to wrap to a new line
|
||||
|
||||
<STRONG>o</STRONG> If an error is detected when converting a multibyte character to a
|
||||
sequence of bytes, or if it is not possible to add all of the
|
||||
resulting bytes in the window, an error is returned.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
Note that <STRONG>addch</STRONG>, <STRONG>mvaddch</STRONG>, <STRONG>mvwaddch</STRONG>, and <STRONG>echochar</STRONG> may be macros.
|
||||
@ -186,9 +199,9 @@
|
||||
|
||||
</PRE><H3><a name="h3-ACS-Symbols">ACS Symbols</a></H3><PRE>
|
||||
X/Open Curses states that the <EM>ACS</EM><STRONG>_</STRONG> definitions are <STRONG>char</STRONG> constants. For
|
||||
the wide-character implementation (see <STRONG>curs_add_wch</STRONG>), there are analo-
|
||||
gous <EM>WACS</EM><STRONG>_</STRONG> definitions which are <STRONG>cchar_t</STRONG> constants. Some implementa-
|
||||
tions are problematic:
|
||||
the wide-character implementation (see <STRONG>curs_add_wch</STRONG>), there are
|
||||
analogous <EM>WACS</EM><STRONG>_</STRONG> definitions which are <STRONG>cchar_t</STRONG> constants. Some
|
||||
implementations are problematic:
|
||||
|
||||
<STRONG>o</STRONG> Some implementations define the ACS symbols to a constant (such as
|
||||
Solaris), while others define those to entries in an array.
|
||||
@ -198,20 +211,20 @@
|
||||
for compatibility.
|
||||
|
||||
<STRONG>o</STRONG> HPUX curses equates some of the <EM>ACS</EM><STRONG>_</STRONG> symbols to the analogous <EM>WACS</EM><STRONG>_</STRONG>
|
||||
symbols as if the <EM>ACS</EM><STRONG>_</STRONG> symbols were wide characters. The misde-
|
||||
fined symbols are the arrows and other symbols which are not used
|
||||
for line-drawing.
|
||||
symbols as if the <EM>ACS</EM><STRONG>_</STRONG> symbols were wide characters. The
|
||||
misdefined symbols are the arrows and other symbols which are not
|
||||
used for line-drawing.
|
||||
|
||||
<STRONG>o</STRONG> X/Open Curses (issues 2 through 7) has a typographical error for
|
||||
the ACS_LANTERN symbol, equating its "VT100+ Character" to <STRONG>I</STRONG> (capi-
|
||||
tal I), while the header files for SVr4 curses and the various
|
||||
the ACS_LANTERN symbol, equating its "VT100+ Character" to <STRONG>I</STRONG>
|
||||
(capital I), while the header files for SVr4 curses and the various
|
||||
implementations use <STRONG>i</STRONG> (lowercase).
|
||||
|
||||
None of the terminal descriptions on Unix platforms use uppercase-
|
||||
I, except for Solaris (i.e., <EM>screen</EM>'s terminal description, appar-
|
||||
ently based on the X/Open documentation around 1995). On the other
|
||||
hand, the terminal description <EM>gs6300</EM> (AT&T PC6300 with EMOTS Ter-
|
||||
minal Emulator) uses lowercase-i.
|
||||
I, except for Solaris (i.e., <EM>screen</EM>'s terminal description,
|
||||
apparently based on the X/Open documentation around 1995). On the
|
||||
other hand, the terminal description <EM>gs6300</EM> (AT&T PC6300 with EMOTS
|
||||
Terminal Emulator) uses lowercase-i.
|
||||
|
||||
Some ACS symbols (ACS_S3, ACS_S7, ACS_LEQUAL, ACS_GEQUAL, ACS_PI,
|
||||
ACS_NEQUAL, ACS_STERLING) were not documented in any publicly released
|
||||
@ -228,9 +241,9 @@
|
||||
|
||||
<STRONG>o</STRONG> whether the <EM>locale</EM> uses UTF-8 encoding.
|
||||
|
||||
In certain cases, the terminal is unable to display line-drawing char-
|
||||
acters except by using UTF-8 (see the discussion of <STRONG>NCURSES_NO_UTF8_ACS</STRONG>
|
||||
in <STRONG><A HREF="ncurses.3x.html">ncurses(3x)</A></STRONG>).
|
||||
In certain cases, the terminal is unable to display line-drawing
|
||||
characters except by using UTF-8 (see the discussion of
|
||||
<STRONG>NCURSES_NO_UTF8_ACS</STRONG> in <STRONG><A HREF="ncurses.3x.html">ncurses(3x)</A></STRONG>).
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Character-Set">Character Set</a></H3><PRE>
|
||||
@ -238,9 +251,9 @@
|
||||
single character. As discussed in <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>, 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 <STRONG>chtype</STRONG> to pass to <STRONG>waddch</STRONG>.
|
||||
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 <STRONG>chtype</STRONG> to pass to <STRONG>waddch</STRONG>.
|
||||
|
||||
In this implementation, <STRONG>chtype</STRONG> holds an eight-bit character. But
|
||||
ncurses allows multibyte characters to be passed in a succession of
|
||||
@ -257,8 +270,8 @@
|
||||
multibyte character by moving the current location (e.g., using <STRONG>wmove</STRONG>),
|
||||
ncurses discards the partially built character, starting over again.
|
||||
|
||||
For portability to other implementations, do not rely upon this behav-
|
||||
ior:
|
||||
For portability to other implementations, do not rely upon this
|
||||
behavior:
|
||||
|
||||
<STRONG>o</STRONG> check if a character can be represented as a single byte in the
|
||||
current locale before attempting call <STRONG>waddch</STRONG>, and
|
||||
@ -277,8 +290,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>, <STRONG><A HREF="curs_clear.3x.html">curs_clear(3x)</A></STRONG>, <STRONG><A HREF="curs_inch.3x.html">curs_inch(3x)</A></STRONG>, <STRONG>curs_out-</STRONG>
|
||||
<STRONG><A HREF="curs_outopts.3x.html">opts(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG><A HREF="curs_variables.3x.html">curs_variables(3x)</A></STRONG>, <STRONG>putc(3)</STRONG>.
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>, <STRONG><A HREF="curs_clear.3x.html">curs_clear(3x)</A></STRONG>, <STRONG><A HREF="curs_inch.3x.html">curs_inch(3x)</A></STRONG>,
|
||||
<STRONG><A HREF="curs_outopts.3x.html">curs_outopts(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG><A HREF="curs_variables.3x.html">curs_variables(3x)</A></STRONG>, <STRONG>putc(3)</STRONG>.
|
||||
|
||||
Comparable functions in the wide-character (ncursesw) library are
|
||||
described in <STRONG><A HREF="curs_add_wch.3x.html">curs_add_wch(3x)</A></STRONG>.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_addchstr.3x,v 1.19 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_addchstr.3x,v 1.22 2020/12/19 21:39:20 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,14 +55,15 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>addchstr(const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>addchnstr(const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddchstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddchnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>addchstr(const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>addchnstr(const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddchnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvaddchstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddchnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddchnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -106,7 +107,7 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="curs_addstr.3x.html">curs_addstr(3x)</A></STRONG>, <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>.
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_addstr.3x.html">curs_addstr(3x)</A></STRONG>.
|
||||
|
||||
Comparable functions in the wide-character (ncursesw) library are de-
|
||||
scribed in <STRONG><A HREF="curs_add_wchstr.3x.html">curs_add_wchstr(3x)</A></STRONG>.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_addstr.3x,v 1.20 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_addstr.3x,v 1.23 2020/10/17 23:11:02 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>addnstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvaddstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
@ -67,16 +68,16 @@
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These functions write the (null-terminated) character string <EM>str</EM> on the
|
||||
given window. It is similar to calling <STRONG>waddch</STRONG> once for each character
|
||||
in the string.
|
||||
given window. It is similar to calling <STRONG>waddch</STRONG> once for each byte in
|
||||
the string.
|
||||
|
||||
The <EM>mv</EM> functions perform cursor movement once, before writing any char-
|
||||
acters. Thereafter, the cursor is advanced as a side-effect of writing
|
||||
to the window.
|
||||
|
||||
The four functions with <EM>n</EM> as the last argument write at most <EM>n</EM> charac-
|
||||
ters, or until a terminating null is reached. If <EM>n</EM> is -1, then the en-
|
||||
tire string will be added.
|
||||
The four functions with <EM>n</EM> as the last argument write at most <EM>n</EM> bytes,
|
||||
or until a terminating null is reached. If <EM>n</EM> is -1, then the entire
|
||||
string will be added.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
@ -93,7 +94,15 @@
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
<STRONG>wmove</STRONG>, and return an error if the position is outside the window, or if
|
||||
the window pointer is null.
|
||||
the window pointer is null. If an error is returned by the <STRONG>wmove</STRONG>, no
|
||||
characters are added to the window.
|
||||
|
||||
If an error is returned by <STRONG>waddch</STRONG> (e.g., because the window is not
|
||||
large enough, or an illegal byte sequence was detected) only part of
|
||||
the string may be added. Aside from that, there is a special case in
|
||||
<STRONG>waddch</STRONG> where an error may be returned after successfully writing a
|
||||
character to the lower-right corner of a window when <STRONG>scrollok</STRONG> is dis-
|
||||
abled.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_addwstr.3x,v 1.14 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_addwstr.3x,v 1.15 2020/10/17 23:12:22 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>addnwstr(const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>waddnwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvaddwstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvaddnwstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwaddwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
|
@ -401,8 +401,8 @@
|
||||
have the <STRONG>enter_italics_mode</STRONG> (<STRONG>sitm</STRONG>) and <STRONG>exit_italics_mode</STRONG> (<STRONG>ritm</STRONG>) capa-
|
||||
bilities. Italics are not mentioned in X/Open Curses. Unlike the oth-
|
||||
er video attributes, <STRONG>A_ITALIC</STRONG> is unrelated to the <STRONG>set_attributes</STRONG> capa-
|
||||
bilities. This implementation makes the assumption that <STRONG>exit_at-</STRONG>
|
||||
<STRONG>tribute_mode</STRONG> may also reset italics.
|
||||
bilities. This implementation makes the assumption that <STRONG>exit_attri-</STRONG>
|
||||
<STRONG>bute_mode</STRONG> may also reset italics.
|
||||
|
||||
Each of the functions added by XSI Curses has a parameter <EM>opts</EM>, which
|
||||
X/Open Curses still (after more than twenty years) documents as re-
|
||||
|
@ -59,11 +59,11 @@
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
The <STRONG>beep</STRONG> and <STRONG>flash</STRONG> routines are used to alert the terminal user. The
|
||||
routine <STRONG>beep</STRONG> sounds an audible alarm on the terminal, if possible; oth-
|
||||
erwise it flashes the screen (visible bell). The routine <STRONG>flash</STRONG> flashes
|
||||
the screen, and if that is not possible, sounds the alert. If neither
|
||||
alert is possible, nothing happens. Nearly all terminals have an audi-
|
||||
ble alert (bell or beep), but only some can flash the screen.
|
||||
routine <STRONG>beep</STRONG> sounds an audible alarm on the terminal, if possible;
|
||||
otherwise it flashes the screen (visible bell). The routine <STRONG>flash</STRONG>
|
||||
flashes the screen, and if that is not possible, sounds the alert. If
|
||||
neither alert is possible, nothing happens. Nearly all terminals have
|
||||
an audible alert (bell or beep), but only some can flash the screen.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
@ -72,8 +72,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-EXTENSIONS">EXTENSIONS</a></H2><PRE>
|
||||
SVr4's beep and flash routines always returned <STRONG>OK</STRONG>, so it was not possi-
|
||||
ble to tell when the beep or flash failed.
|
||||
SVr4's beep and flash routines always returned <STRONG>OK</STRONG>, so it was not
|
||||
possible to tell when the beep or flash failed.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_bkgd.3x,v 1.30 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_bkgd.3x,v 1.31 2020/10/17 23:12:52 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -56,8 +56,10 @@
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>bkgdset(chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>wbkgdset(WINDOW</STRONG> <STRONG>*</STRONG><EM>win,</EM> <EM>chtype</EM> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>bkgd(chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wbkgd(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>chtype</STRONG> <STRONG>getbkgd(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
@ -65,8 +67,8 @@
|
||||
|
||||
</PRE><H3><a name="h3-bkgdset">bkgdset</a></H3><PRE>
|
||||
The <STRONG>bkgdset</STRONG> and <STRONG>wbkgdset</STRONG> routines manipulate the background of the
|
||||
named window. The window background is a <STRONG>chtype</STRONG> consisting of any com-
|
||||
bination of attributes (i.e., rendition) and a character. The
|
||||
named window. The window background is a <STRONG>chtype</STRONG> consisting of any
|
||||
combination of attributes (i.e., rendition) and a character. The
|
||||
attribute part of the background is combined (OR'ed) with all non-blank
|
||||
characters that are written into the window with <STRONG>waddch</STRONG>. Both the
|
||||
character and attribute parts of the background are combined with the
|
||||
@ -97,9 +99,9 @@
|
||||
|
||||
This implementation, like SVr4 curses, does not store the background
|
||||
and window attribute contributions to each cell separately. It updates
|
||||
the rendition by comparing the character, non-color attributes and col-
|
||||
ors contained in the background. For each cell in the window, whether
|
||||
or not it is blank:
|
||||
the rendition by comparing the character, non-color attributes and
|
||||
colors contained in the background. For each cell in the window,
|
||||
whether or not it is blank:
|
||||
|
||||
<STRONG>o</STRONG> The library first compares the <EM>character</EM>, and if it matches the
|
||||
current character part of the background, it replaces that with the
|
||||
@ -107,20 +109,20 @@
|
||||
|
||||
<STRONG>o</STRONG> The library then checks if the cell uses color, i.e., its color
|
||||
pair value is nonzero. If not, it simply replaces the attributes
|
||||
and color pair in the cell with those from the new background char-
|
||||
acter.
|
||||
and color pair in the cell with those from the new background
|
||||
character.
|
||||
|
||||
<STRONG>o</STRONG> If the cell uses color, and that matches the color in the current
|
||||
background, the library removes attributes which may have come from
|
||||
the current background and adds attributes from the new background.
|
||||
It finishes by setting the cell to use the color from the new back-
|
||||
ground.
|
||||
It finishes by setting the cell to use the color from the new
|
||||
background.
|
||||
|
||||
<STRONG>o</STRONG> If the cell uses color, and that does not match the color in the
|
||||
current background, the library updates only the non-color
|
||||
attributes, first removing those which may have come from the cur-
|
||||
rent background, and then adding attributes from the new back-
|
||||
ground.
|
||||
attributes, first removing those which may have come from the
|
||||
current background, and then adding attributes from the new
|
||||
background.
|
||||
|
||||
If the background's character value is zero, a space is assumed.
|
||||
|
||||
@ -136,8 +138,8 @@
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
These functions are described in the XSI Curses standard, Issue 4. It
|
||||
specifies that <STRONG>bkgd</STRONG> and <STRONG>wbkgd</STRONG> return <STRONG>ERR</STRONG> on failure, but gives no fail-
|
||||
ure conditions.
|
||||
specifies that <STRONG>bkgd</STRONG> and <STRONG>wbkgd</STRONG> return <STRONG>ERR</STRONG> on failure, but gives no
|
||||
failure conditions.
|
||||
|
||||
The routines <STRONG>bkgd</STRONG> and <STRONG>wbkgd</STRONG> return the integer <STRONG>OK</STRONG>, unless the library
|
||||
has not been initialized.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_bkgrnd.3x,v 1.11 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_bkgrnd.3x,v 1.12 2020/10/17 23:13:15 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -56,8 +56,10 @@
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>bkgrnd(</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wbkgrnd(</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>bkgrndset(const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM> <STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>wbkgrndset(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getbkgrnd(cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetbkgrnd(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
@ -71,8 +73,8 @@
|
||||
The attribute part of the background is combined (OR'ed) with all non-
|
||||
blank characters that are written into the window with <STRONG>waddch</STRONG>. Both
|
||||
the character and attribute parts of the background are combined with
|
||||
the blank characters. The background becomes a property of the charac-
|
||||
ter and moves with the character through any scrolling and
|
||||
the blank characters. The background becomes a property of the
|
||||
character and moves with the character through any scrolling and
|
||||
insert/delete line/character operations.
|
||||
|
||||
To the extent possible on a particular terminal, the attribute part of
|
||||
@ -82,8 +84,8 @@
|
||||
|
||||
</PRE><H3><a name="h3-bkgrnd">bkgrnd</a></H3><PRE>
|
||||
The <STRONG>bkgrnd</STRONG> and <STRONG>wbkgrnd</STRONG> functions set the background property of the
|
||||
current or specified window and then apply this setting to every char-
|
||||
acter position in that window:
|
||||
current or specified window and then apply this setting to every
|
||||
character position in that window:
|
||||
|
||||
<STRONG>o</STRONG> The rendition of every character on the screen is changed to the
|
||||
new background rendition.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_border.3x,v 1.25 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_border.3x,v 1.27 2020/10/18 00:33:06 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,20 +54,24 @@
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>border(chtype</STRONG> <STRONG>ls,</STRONG> <STRONG>chtype</STRONG> <STRONG>rs,</STRONG> <STRONG>chtype</STRONG> <STRONG>ts,</STRONG> <STRONG>chtype</STRONG> <STRONG>bs,</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>tl,</STRONG> <STRONG>chtype</STRONG> <STRONG>tr,</STRONG> <STRONG>chtype</STRONG> <STRONG>bl,</STRONG> <STRONG>chtype</STRONG> <STRONG>br);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wborder(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>ls,</STRONG> <STRONG>chtype</STRONG> <STRONG>rs,</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>ts,</STRONG> <STRONG>chtype</STRONG> <STRONG>bs,</STRONG> <STRONG>chtype</STRONG> <STRONG>tl,</STRONG> <STRONG>chtype</STRONG> <STRONG>tr,</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>bl,</STRONG> <STRONG>chtype</STRONG> <STRONG>br);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>box(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>verch,</STRONG> <STRONG>chtype</STRONG> <STRONG>horch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>hline(chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>whline(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vline(chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wvline(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvhline(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwhline(WINDOW</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvvline(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwvline(WINDOW</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>border(chtype</STRONG> <EM>ls</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>rs</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ts</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>bs</EM><STRONG>,</STRONG>
|
||||
<STRONG>chtype</STRONG> <EM>tl</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>tr</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>bl</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>br</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wborder(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ls</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>rs</EM><STRONG>,</STRONG>
|
||||
<STRONG>chtype</STRONG> <EM>ts</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>bs</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>tl</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>tr</EM><STRONG>,</STRONG>
|
||||
<STRONG>chtype</STRONG> <EM>bl</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>br</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>box(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>verch</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>horch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>hline(chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>whline(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vline(chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wvline(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvhline(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwhline(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvvline(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwvline(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_clear.3x,v 1.17 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_clear.3x,v 1.20 2020/10/24 09:19:37 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -52,16 +52,19 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#</STRONG> <STRONG>include</STRONG> <STRONG><curses.h></STRONG>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>erase(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>werase(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>werase(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>clear(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclear(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclear(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>clrtobot(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclrtobot(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclrtobot(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>clrtoeol(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclrtoeol(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wclrtoeol(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -85,12 +88,14 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines return the integer <STRONG>OK</STRONG> on success and <STRONG>ERR</STRONG> on failure. The
|
||||
SVr4.0 manual says "or a non-negative integer if <STRONG>immedok</STRONG> is set", but
|
||||
this appears to be an error.
|
||||
All routines return the integer <STRONG>OK</STRONG> on success and <STRONG>ERR</STRONG> on failure.
|
||||
|
||||
X/Open defines no error conditions. In this implementation, functions
|
||||
using a window pointer parameter return an error if it is null.
|
||||
X/Open defines no error conditions. In this implementation,
|
||||
|
||||
<STRONG>o</STRONG> functions using a window pointer parameter return an error if it is
|
||||
null
|
||||
|
||||
<STRONG>o</STRONG> <STRONG>wclrtoeol</STRONG> returns an error if the cursor position is about to wrap.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
@ -103,17 +108,22 @@
|
||||
standard specifies that they return <STRONG>ERR</STRONG> on failure, but specifies no
|
||||
error conditions.
|
||||
|
||||
Some historic curses implementations had, as an undocumented feature,
|
||||
the ability to do the equivalent of <STRONG>clearok(...,</STRONG> <STRONG>1)</STRONG> by saying <STRONG>touch-</STRONG>
|
||||
The SVr4.0 manual says that these functions could return "a non-nega-
|
||||
tive integer if <STRONG>immedok</STRONG> is set", referring to the return-value of <STRONG>wre-</STRONG>
|
||||
<STRONG>fresh</STRONG>. In that implementation, <STRONG>wrefresh</STRONG> would return a count of the
|
||||
number of characters written to the terminal.
|
||||
|
||||
Some historic curses implementations had, as an undocumented feature,
|
||||
the ability to do the equivalent of <STRONG>clearok(...,</STRONG> <STRONG>1)</STRONG> by saying <STRONG>touch-</STRONG>
|
||||
<STRONG>win(stdscr)</STRONG> or <STRONG>clear(stdscr)</STRONG>. This will not work under ncurses.
|
||||
|
||||
This implementation, and others such as Solaris, sets the current posi-
|
||||
tion to 0,0 after erasing via <STRONG>werase</STRONG> and <STRONG>wclear</STRONG>. That fact is not doc-
|
||||
umented in other implementations, and may not be true of implementa-
|
||||
umented in other implementations, and may not be true of implementa-
|
||||
tions which were not derived from SVr4 source.
|
||||
|
||||
Not obvious from the description, most implementations clear the screen
|
||||
after <STRONG>wclear</STRONG> even for a subwindow or derived window. If you do not
|
||||
after <STRONG>wclear</STRONG> even for a subwindow or derived window. If you do not
|
||||
want to clear the screen during the next <STRONG>wrefresh</STRONG>, use <STRONG>werase</STRONG> instead.
|
||||
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_color.3x,v 1.62 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_color.3x,v 1.63 2020/10/24 09:35:23 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -61,22 +61,22 @@
|
||||
<STRONG>bool</STRONG> <STRONG>has_colors(void);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>can_change_color(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>init_pair(short</STRONG> <STRONG>pair,</STRONG> <STRONG>short</STRONG> <STRONG>f,</STRONG> <STRONG>short</STRONG> <STRONG>b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_color(short</STRONG> <STRONG>color,</STRONG> <STRONG>short</STRONG> <STRONG>r,</STRONG> <STRONG>short</STRONG> <STRONG>g,</STRONG> <STRONG>short</STRONG> <STRONG>b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_pair(short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>f</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_color(short</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
/* extensions */
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_pair(int</STRONG> <STRONG>pair,</STRONG> <STRONG>int</STRONG> <STRONG>f,</STRONG> <STRONG>int</STRONG> <STRONG>b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_color(int</STRONG> <STRONG>color,</STRONG> <STRONG>int</STRONG> <STRONG>r,</STRONG> <STRONG>int</STRONG> <STRONG>g,</STRONG> <STRONG>int</STRONG> <STRONG>b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_pair(int</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>f</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_color(int</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>color_content(short</STRONG> <STRONG>color,</STRONG> <STRONG>short</STRONG> <STRONG>*r,</STRONG> <STRONG>short</STRONG> <STRONG>*g,</STRONG> <STRONG>short</STRONG> <STRONG>*b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>pair_content(short</STRONG> <STRONG>pair,</STRONG> <STRONG>short</STRONG> <STRONG>*f,</STRONG> <STRONG>short</STRONG> <STRONG>*b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>color_content(short</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <STRONG>*</STRONG><EM>r</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <STRONG>*</STRONG><EM>g</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <STRONG>*</STRONG><EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>pair_content(short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <STRONG>*</STRONG><EM>f</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <STRONG>*</STRONG><EM>b</EM><STRONG>);</STRONG>
|
||||
/* extensions */
|
||||
<STRONG>int</STRONG> <STRONG>extended_color_content(int</STRONG> <STRONG>color,</STRONG> <STRONG>int</STRONG> <STRONG>*r,</STRONG> <STRONG>int</STRONG> <STRONG>*g,</STRONG> <STRONG>int</STRONG> <STRONG>*b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_pair_content(int</STRONG> <STRONG>pair,</STRONG> <STRONG>int</STRONG> <STRONG>*f,</STRONG> <STRONG>int</STRONG> <STRONG>*b);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_color_content(int</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>r</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>g</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_pair_content(int</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>f</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>b</EM><STRONG>);</STRONG>
|
||||
|
||||
/* extensions */
|
||||
<STRONG>void</STRONG> <STRONG>reset_color_pairs(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>COLOR_PAIR(int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>COLOR_PAIR(int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>PAIR_NUMBER(</STRONG><EM>attrs</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
@ -135,8 +135,8 @@
|
||||
|
||||
<STRONG>o</STRONG> If the parameter passed to <STRONG>waddch</STRONG> is <EM>not</EM> <EM>blank</EM>, or it does not use
|
||||
the special color pair 0, <STRONG>curses</STRONG> prefers the color pair from the
|
||||
parameter, if it is nonzero. Otherwise, it tries the window at-
|
||||
tribute next, and finally the background character.
|
||||
parameter, if it is nonzero. Otherwise, it tries the window attri-
|
||||
bute next, and finally the background character.
|
||||
|
||||
Some <STRONG>curses</STRONG> functions such as <STRONG>wprintw</STRONG> call <STRONG>waddch</STRONG>. Those do not com-
|
||||
bine its parameter with a color pair. Consequently those calls use on-
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_delch.3x,v 1.14 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_delch.3x,v 1.15 2020/10/24 09:36:43 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,24 +55,24 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>delch(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wdelch(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvdelch(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwdelch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wdelch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvdelch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwdelch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These routines delete the character under the cursor; all characters to
|
||||
the right of the cursor on the same line are moved to the left one
|
||||
position and the last character on the line is filled with a blank.
|
||||
The cursor position does not change (after moving to <EM>y</EM>, <EM>x</EM>, if speci-
|
||||
fied). (This does not imply use of the hardware delete character fea-
|
||||
ture.)
|
||||
The cursor position does not change (after moving to <EM>y</EM>, <EM>x</EM>, if
|
||||
specified). (This does not imply use of the hardware delete character
|
||||
feature.)
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and an <STRONG>OK</STRONG> (SVr4 speci-
|
||||
fies only "an integer value other than <STRONG>ERR</STRONG>") upon successful comple-
|
||||
tion.
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and an <STRONG>OK</STRONG> (SVr4
|
||||
specifies only "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
<STRONG>wmove</STRONG>, and return an error if the position is outside the window, or if
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_deleteln.3x,v 1.15 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_deleteln.3x,v 1.17 2020/10/18 00:28:51 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,11 +55,13 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>deleteln(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wdeleteln(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insdelln(int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsdelln(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wdeleteln(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>insdelln(int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsdelln(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>insertln(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsertln(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsertln(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -74,14 +76,14 @@
|
||||
the cursor), and move the remaining lines up. The bottom <EM>n</EM> lines are
|
||||
cleared. The current cursor position remains the same.
|
||||
|
||||
The <STRONG>insertln</STRONG> and <STRONG>winsertln</STRONG> routines insert a blank line above the cur-
|
||||
rent line and the bottom line is lost.
|
||||
The <STRONG>insertln</STRONG> and <STRONG>winsertln</STRONG> routines insert a blank line above the
|
||||
current line and the bottom line is lost.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and an <STRONG>OK</STRONG> (SVr4 speci-
|
||||
fies only "an integer value other than <STRONG>ERR</STRONG>") upon successful comple-
|
||||
tion.
|
||||
All routines return the integer <STRONG>ERR</STRONG> upon failure and an <STRONG>OK</STRONG> (SVr4
|
||||
specifies only "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion.
|
||||
|
||||
X/Open defines no error conditions. In this implementation, if the
|
||||
window parameter is null, an error is returned.
|
||||
@ -98,8 +100,8 @@
|
||||
|
||||
These routines do not require a hardware line delete or insert feature
|
||||
in the terminal. In fact, they will not use hardware line
|
||||
delete/insert unless <STRONG>idlok(...,</STRONG> <STRONG>TRUE)</STRONG> has been set on the current win-
|
||||
dow.
|
||||
delete/insert unless <STRONG>idlok(...,</STRONG> <STRONG>TRUE)</STRONG> has been set on the current
|
||||
window.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
|
@ -28,7 +28,7 @@
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* Author: Thomas E. Dickey 1999-on
|
||||
* @Id: curs_extend.3x,v 1.23 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_extend.3x,v 1.24 2020/10/24 09:37:07 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,7 +55,7 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <STRONG>curses_version(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_extended_names(bool</STRONG> <STRONG>enable);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_extended_names(bool</STRONG> <EM>enable</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -69,11 +69,11 @@
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-use_extended_names">use_extended_names</a></H3><PRE>
|
||||
The <STRONG>use_extended_names</STRONG> function controls whether the calling applica-
|
||||
tion is able to use user-defined or nonstandard names which may be com-
|
||||
piled into the terminfo description, i.e., via the terminfo or termcap
|
||||
interfaces. Normally these names are available for use, since the
|
||||
essential decision is made by using the <STRONG>-x</STRONG> option of <STRONG>tic</STRONG> to compile
|
||||
The <STRONG>use_extended_names</STRONG> function controls whether the calling
|
||||
application is able to use user-defined or nonstandard names which may
|
||||
be compiled into the terminfo description, i.e., via the terminfo or
|
||||
termcap interfaces. Normally these names are available for use, since
|
||||
the essential decision is made by using the <STRONG>-x</STRONG> option of <STRONG>tic</STRONG> to compile
|
||||
extended terminal definitions. However you can disable this feature to
|
||||
ensure compatibility with other implementations of curses.
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_get_wch.3x,v 1.13 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_get_wch.3x,v 1.14 2020/10/17 23:17:05 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -58,6 +58,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>wget_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvget_wch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwget_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>unget_wch(const</STRONG> <STRONG>wchar_t</STRONG> <EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_get_wstr.3x,v 1.20 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_get_wstr.3x,v 1.21 2020/10/17 23:17:24 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>getn_wstr(wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wget_wstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetn_wstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvget_wstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvgetn_wstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwget_wstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wint_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
|
@ -73,8 +73,8 @@
|
||||
|
||||
</PRE><H3><a name="h3-getcchar">getcchar</a></H3><PRE>
|
||||
The <STRONG>getcchar</STRONG> function gets a wide-character string and rendition from a
|
||||
<STRONG>cchar_t</STRONG> argument. When <EM>wch</EM> is not a null pointer, the <STRONG>getcchar</STRONG> func-
|
||||
tion does the following:
|
||||
<STRONG>cchar_t</STRONG> argument. When <EM>wch</EM> is not a null pointer, the <STRONG>getcchar</STRONG>
|
||||
function does the following:
|
||||
|
||||
<STRONG>o</STRONG> Extracts information from a <STRONG>cchar_t</STRONG> value <EM>wcval</EM>
|
||||
|
||||
@ -123,8 +123,8 @@
|
||||
|
||||
<STRONG>o</STRONG> For functions which retrieve the color, e.g., <STRONG>getcchar</STRONG>, if <EM>opts</EM> is
|
||||
set it is treated as a pointer to <STRONG>int</STRONG>, and used to retrieve the
|
||||
color pair as an <STRONG>int</STRONG> value, in addition retrieving it via the stan-
|
||||
dard pointer to <STRONG>short</STRONG> parameter.
|
||||
color pair as an <STRONG>int</STRONG> value, in addition retrieving it via the
|
||||
standard pointer to <STRONG>short</STRONG> parameter.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
@ -134,8 +134,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
When <EM>wch</EM> is a null pointer, <STRONG>getcchar</STRONG> returns the number of wide charac-
|
||||
ters referenced by <EM>wcval</EM>, including one for a trailing null.
|
||||
When <EM>wch</EM> is a null pointer, <STRONG>getcchar</STRONG> returns the number of wide
|
||||
characters referenced by <EM>wcval</EM>, including one for a trailing null.
|
||||
|
||||
When <EM>wch</EM> is not a null pointer, <STRONG>getcchar</STRONG> returns <STRONG>OK</STRONG> upon successful
|
||||
completion, and <STRONG>ERR</STRONG> otherwise.
|
||||
@ -180,8 +180,8 @@
|
||||
of spacing and non-spacing characters (<STRONG>CCHARW_MAX</STRONG>). That was probably
|
||||
due to a misreading of the AIX 4 header files, because the X/Open
|
||||
Curses document was not generally available at that time. Later (in
|
||||
2002), this detail was overlooked when beginning to implement the func-
|
||||
tions using the structure.
|
||||
2002), this detail was overlooked when beginning to implement the
|
||||
functions using the structure.
|
||||
|
||||
In practice, even four non-spacing characters may seem enough. X/Open
|
||||
Curses documents possible uses for non-spacing characters, including
|
||||
|
@ -28,7 +28,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_getch.3x,v 1.55 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_getch.3x,v 1.57 2020/12/19 21:38:20 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -57,9 +57,13 @@
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getch(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win);</EM>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvgetch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwgetch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>ungetch(int</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
/* extension */
|
||||
<STRONG>int</STRONG> <STRONG>has_key(int</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
@ -176,11 +180,11 @@
|
||||
KEY_ENTER Enter or send
|
||||
KEY_SRESET Soft (partial) reset
|
||||
KEY_RESET Reset or hard reset
|
||||
|
||||
KEY_PRINT Print or copy
|
||||
KEY_LL Home down or bottom (lower left)
|
||||
KEY_A1 Upper left of keypad
|
||||
KEY_A3 Upper right of keypad
|
||||
|
||||
KEY_B2 Center of keypad
|
||||
KEY_C1 Lower left of keypad
|
||||
KEY_C3 Lower right of keypad
|
||||
@ -371,8 +375,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_inopts.3x.html">curs_inopts(3x)</A></STRONG>, <STRONG><A HREF="curs_outopts.3x.html">curs_outopts(3x)</A></STRONG>, <STRONG><A HREF="curs_mouse.3x.html">curs_mouse(3x)</A></STRONG>,
|
||||
<STRONG><A HREF="curs_move.3x.html">curs_move(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG><A HREF="curs_variables.3x.html">curs_variables(3x)</A></STRONG>, <STRONG><A HREF="resizeterm.3x.html">resizeterm(3x)</A></STRONG>.
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_inopts.3x.html">curs_inopts(3x)</A></STRONG>, <STRONG><A HREF="curs_mouse.3x.html">curs_mouse(3x)</A></STRONG>, <STRONG><A HREF="curs_move.3x.html">curs_move(3x)</A></STRONG>, <STRONG>curs_out-</STRONG>
|
||||
<STRONG><A HREF="curs_outopts.3x.html">opts(3x)</A></STRONG>, <STRONG><A HREF="curs_refresh.3x.html">curs_refresh(3x)</A></STRONG>, <STRONG><A HREF="curs_variables.3x.html">curs_variables(3x)</A></STRONG>, <STRONG><A HREF="resizeterm.3x.html">resizeterm(3x)</A></STRONG>.
|
||||
|
||||
Comparable functions in the wide-character (ncursesw) library are de-
|
||||
scribed in <STRONG><A HREF="curs_get_wch.3x.html">curs_get_wch(3x)</A></STRONG>.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_getstr.3x,v 1.29 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_getstr.3x,v 1.31 2020/10/18 00:27:44 tom Exp @
|
||||
* X/Open says also until EOf
|
||||
* X/Open says then an EOS is added to the result
|
||||
* X/Open doesn't mention n<0
|
||||
@ -57,14 +57,15 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getstr(char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getnstr(char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvgetstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwgetstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvgetnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwgetnstr(WINDOW</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getstr(char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getnstr(char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvgetstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwgetstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvgetnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwgetnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_getyx.3x,v 1.19 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_getyx.3x,v 1.20 2020/10/24 09:38:43 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,22 +54,22 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>getyx(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getparyx(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getbegyx(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getmaxyx(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getyx(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getparyx(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getbegyx(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>getmaxyx(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
The <STRONG>getyx</STRONG> macro places the current cursor position of the given window
|
||||
in the two integer variables <EM>y</EM> and <EM>x</EM>.
|
||||
|
||||
If <EM>win</EM> is a subwindow, the <STRONG>getparyx</STRONG> macro places the beginning coordi-
|
||||
nates of the subwindow relative to the parent window into two integer
|
||||
variables <EM>y</EM> and <EM>x</EM>. Otherwise, <STRONG>-1</STRONG> is placed into <EM>y</EM> and <EM>x</EM>.
|
||||
If <EM>win</EM> is a subwindow, the <STRONG>getparyx</STRONG> macro places the beginning
|
||||
coordinates of the subwindow relative to the parent window into two
|
||||
integer variables <EM>y</EM> and <EM>x</EM>. Otherwise, <STRONG>-1</STRONG> is placed into <EM>y</EM> and <EM>x</EM>.
|
||||
|
||||
Like <STRONG>getyx</STRONG>, the <STRONG>getbegyx</STRONG> and <STRONG>getmaxyx</STRONG> macros store the current begin-
|
||||
ning coordinates and size of the specified window.
|
||||
Like <STRONG>getyx</STRONG>, the <STRONG>getbegyx</STRONG> and <STRONG>getmaxyx</STRONG> macros store the current
|
||||
beginning coordinates and size of the specified window.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
@ -90,17 +90,18 @@
|
||||
<STRONG>getcury</STRONG>, <STRONG>getmaxx</STRONG>, <STRONG>getmaxy</STRONG>, <STRONG>getparx</STRONG> and <STRONG>getpary</STRONG> for compatibility with
|
||||
older versions of curses.
|
||||
|
||||
Although X/Open Curses does not address this, many implementations pro-
|
||||
vide members of the WINDOW structure containing values corresponding to
|
||||
these macros. For best portability, do not rely on using the data in
|
||||
WINDOW, since some implementations make WINDOW opaque (do not allow
|
||||
Although X/Open Curses does not address this, many implementations
|
||||
provide members of the WINDOW structure containing values corresponding
|
||||
to these macros. For best portability, do not rely on using the data
|
||||
in WINDOW, since some implementations make WINDOW opaque (do not allow
|
||||
direct use of its members).
|
||||
|
||||
Besides the problem of opaque structures, the data stored in like-named
|
||||
members may not have like-values in different implementations. For
|
||||
example, the WINDOW._maxx and WINDOW._maxy values in ncurses have (at
|
||||
least since release 1.8.1) differed by one from some other implementa-
|
||||
tions. The difference is hidden by means of the macro <STRONG>getmaxyx</STRONG>.
|
||||
least since release 1.8.1) differed by one from some other
|
||||
implementations. The difference is hidden by means of the macro
|
||||
<STRONG>getmaxyx</STRONG>.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_in_wch.3x,v 1.9 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_in_wch.3x,v 1.10 2020/10/17 23:19:29 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,9 +55,10 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>in_wch(cchar_t</STRONG> <STRONG>*</STRONG><EM>wcval</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>win_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wcval</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvin_wch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wcval</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwin_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wcval</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>win_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wcval</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -68,8 +69,8 @@
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
No errors are defined in the XSI Curses standard. This implementation
|
||||
checks for null pointers, returns <STRONG>ERR</STRONG> in that case. Also, the <EM>mv</EM> rou-
|
||||
tines check for error moving the cursor, returning <STRONG>ERR</STRONG> in that case.
|
||||
checks for null pointers, returns <STRONG>ERR</STRONG> in that case. Also, the <EM>mv</EM>
|
||||
routines check for error moving the cursor, returning <STRONG>ERR</STRONG> in that case.
|
||||
Otherwise they return <STRONG>OK</STRONG>.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_in_wchstr.3x,v 1.13 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_in_wchstr.3x,v 1.14 2020/10/17 23:19:44 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>in_wchnstr(cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>win_wchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>win_wchnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvin_wchstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvin_wchnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwin_wchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wchstr</EM><STRONG>);</STRONG>
|
||||
|
@ -28,7 +28,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_inch.3x,v 1.23 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_inch.3x,v 1.25 2020/10/18 00:25:23 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -56,15 +56,16 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>chtype</STRONG> <STRONG>inch(void);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>winch(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>mvinch(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>mvwinch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>winch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>chtype</STRONG> <STRONG>mvinch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>mvwinch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These routines return the character, of type <STRONG>chtype</STRONG>, at the current
|
||||
position in the named window. If any attributes are set for that posi-
|
||||
tion, their values are OR'ed into the value returned. Constants
|
||||
position in the named window. If any attributes are set for that
|
||||
position, their values are OR'ed into the value returned. Constants
|
||||
defined in <STRONG><curses.h></STRONG> can be used with the <STRONG>&</STRONG> (logical AND) operator to
|
||||
extract the character or attributes alone.
|
||||
|
||||
@ -114,8 +115,8 @@
|
||||
X/Open Curses does not specify the size and layout of attributes, color
|
||||
and character values in <STRONG>chtype</STRONG>; it is implementation-dependent. This
|
||||
implementation uses 8 bits for character values. An application using
|
||||
more bits, e.g., a Unicode value, should use the wide-character equiva-
|
||||
lents to these functions.
|
||||
more bits, e.g., a Unicode value, should use the wide-character
|
||||
equivalents to these functions.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
@ -123,8 +124,8 @@
|
||||
gives an overview of the WINDOW and <STRONG>chtype</STRONG> data types.
|
||||
|
||||
<STRONG><A HREF="curs_attr.3x.html">curs_attr(3x)</A></STRONG>
|
||||
goes into more detail, pointing out portability problems and con-
|
||||
straints on the use of <STRONG>chtype</STRONG> for returning window information.
|
||||
goes into more detail, pointing out portability problems and
|
||||
constraints on the use of <STRONG>chtype</STRONG> for returning window information.
|
||||
|
||||
<STRONG><A HREF="curs_in_wch.3x.html">curs_in_wch(3x)</A></STRONG>
|
||||
describes comparable functions for the wide-character (ncursesw)
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_inchstr.3x,v 1.19 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_inchstr.3x,v 1.21 2020/10/18 00:24:36 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,14 +55,15 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>inchstr(chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>inchnstr(chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinchstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinchnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinchstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinchnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>*chstr,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>inchstr(chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>inchnstr(chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winchnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvinchstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinchnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinchstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinchnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <STRONG>*</STRONG><EM>chstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_initscr.3x,v 1.32 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_initscr.3x,v 1.33 2020/10/17 23:20:48 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -56,7 +56,9 @@
|
||||
|
||||
<STRONG>WINDOW</STRONG> <STRONG>*initscr(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>endwin(void);</STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>isendwin(void);</STRONG>
|
||||
|
||||
<STRONG>SCREEN</STRONG> <STRONG>*newterm(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>type</EM><STRONG>,</STRONG> <STRONG>FILE</STRONG> <STRONG>*</STRONG><EM>outfd</EM><STRONG>,</STRONG> <STRONG>FILE</STRONG> <STRONG>*</STRONG><EM>infd</EM><STRONG>);</STRONG>
|
||||
<STRONG>SCREEN</STRONG> <STRONG>*set_term(SCREEN</STRONG> <STRONG>*</STRONG><EM>new</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>delscreen(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_inopts.3x,v 1.29 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_inopts.3x,v 1.33 2020/12/05 19:38:18 Benno.Schulenberg Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -47,9 +47,9 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NAME">NAME</a></H2><PRE>
|
||||
<STRONG>cbreak</STRONG>, <STRONG>nocbreak</STRONG>, <STRONG>echo</STRONG>, <STRONG>noecho</STRONG>, <STRONG>halfdelay</STRONG>, <STRONG>intrflush</STRONG>, <STRONG>keypad</STRONG>, <STRONG>meta</STRONG>,
|
||||
<STRONG>nodelay</STRONG>, <STRONG>notimeout</STRONG>, <STRONG>raw</STRONG>, <STRONG>noraw</STRONG>, <STRONG>noqiflush</STRONG>, <STRONG>qiflush</STRONG>, <STRONG>timeout</STRONG>, <STRONG>wtimeout</STRONG>,
|
||||
<STRONG>typeahead</STRONG> - <STRONG>curses</STRONG> input options
|
||||
<STRONG>cbreak</STRONG>, <STRONG>nocbreak</STRONG>, <STRONG>echo</STRONG>, <STRONG>noecho</STRONG>, <STRONG>halfdelay</STRONG>, <STRONG>intrflush</STRONG>, <STRONG>keypad</STRONG>, <STRONG>meta</STRONG>, <STRONG>nl</STRONG>,
|
||||
<STRONG>nonl</STRONG>, <STRONG>nodelay</STRONG>, <STRONG>notimeout</STRONG>, <STRONG>raw</STRONG>, <STRONG>noraw</STRONG>, <STRONG>qiflush</STRONG>, <STRONG>noqiflush</STRONG>, <STRONG>timeout</STRONG>,
|
||||
<STRONG>wtimeout</STRONG>, <STRONG>typeahead</STRONG> - <STRONG>curses</STRONG> input options
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
@ -57,21 +57,30 @@
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>cbreak(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nocbreak(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>echo(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noecho(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>halfdelay(int</STRONG> <STRONG>tenths);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>intrflush(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>bool</STRONG> <STRONG>bf);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>keypad(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>bool</STRONG> <STRONG>bf);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>meta(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>bool</STRONG> <STRONG>bf);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nodelay(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>bool</STRONG> <STRONG>bf);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>intrflush(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>keypad(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>meta(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nodelay(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>notimeout(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>nl(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nonl(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>raw(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noraw(void);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>noqiflush(void);</STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>qiflush(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>notimeout(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>bool</STRONG> <STRONG>bf);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>timeout(int</STRONG> <STRONG>delay);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>wtimeout(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>delay);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>typeahead(int</STRONG> <STRONG>fd);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>noqiflush(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>halfdelay(int</STRONG> <EM>tenths</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>timeout(int</STRONG> <EM>delay</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>wtimeout(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>delay</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>typeahead(int</STRONG> <EM>fd</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -83,7 +92,7 @@
|
||||
behavior is needed.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-cbreak">cbreak</a></H3><PRE>
|
||||
</PRE><H3><a name="h3-cbreak_nocbreak">cbreak/nocbreak</a></H3><PRE>
|
||||
Normally, the tty driver buffers typed characters until a newline or
|
||||
carriage return is typed. The <STRONG>cbreak</STRONG> routine disables line buffering
|
||||
and erase/kill character-processing (interrupt and flow control charac-
|
||||
@ -153,73 +162,80 @@
|
||||
<STRONG>FALSE</STRONG>) is called.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-nl_nonl">nl/nonl</a></H3><PRE>
|
||||
The <STRONG>nl</STRONG> and <STRONG>nonl</STRONG> routines control whether the underlying display device
|
||||
translates the return key into newline on input.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-nodelay">nodelay</a></H3><PRE>
|
||||
The <STRONG>nodelay</STRONG> option causes <STRONG>getch</STRONG> to be a non-blocking call. If no input
|
||||
is ready, <STRONG>getch</STRONG> returns <STRONG>ERR</STRONG>. If disabled (<EM>bf</EM> is <STRONG>FALSE</STRONG>), <STRONG>getch</STRONG> waits
|
||||
is ready, <STRONG>getch</STRONG> returns <STRONG>ERR</STRONG>. If disabled (<EM>bf</EM> is <STRONG>FALSE</STRONG>), <STRONG>getch</STRONG> waits
|
||||
until a key is pressed.
|
||||
|
||||
While interpreting an input escape sequence, <STRONG><A HREF="curs_getch.3x.html">wgetch(3x)</A></STRONG> sets a timer
|
||||
while waiting for the next character. If <STRONG>notimeout(</STRONG><EM>win</EM>, <STRONG>TRUE</STRONG>) is
|
||||
called, then <STRONG>wgetch</STRONG> does not set a timer. The purpose of the timeout
|
||||
is to differentiate between sequences received from a function key and
|
||||
those typed by a user.
|
||||
|
||||
</PRE><H3><a name="h3-notimeout">notimeout</a></H3><PRE>
|
||||
When interpreting an escape sequence, <STRONG><A HREF="curs_getch.3x.html">wgetch(3x)</A></STRONG> sets a timer while
|
||||
waiting for the next character. If <STRONG>notimeout(</STRONG><EM>win</EM>, <STRONG>TRUE</STRONG>) is called,
|
||||
then <STRONG>wgetch</STRONG> does not set a timer. The purpose of the timeout is to
|
||||
differentiate between sequences received from a function key and those
|
||||
typed by a user.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-raw_noraw">raw/noraw</a></H3><PRE>
|
||||
The <STRONG>raw</STRONG> and <STRONG>noraw</STRONG> routines place the terminal into or out of raw mode.
|
||||
Raw mode is similar to <STRONG>cbreak</STRONG> mode, in that characters typed are imme-
|
||||
diately passed through to the user program. The differences are that
|
||||
in raw mode, the interrupt, quit, suspend, and flow control characters
|
||||
are all passed through uninterpreted, instead of generating a signal.
|
||||
The behavior of the BREAK key depends on other bits in the tty driver
|
||||
The <STRONG>raw</STRONG> and <STRONG>noraw</STRONG> routines place the terminal into or out of raw mode.
|
||||
Raw mode is similar to <STRONG>cbreak</STRONG> mode, in that characters typed are imme-
|
||||
diately passed through to the user program. The differences are that
|
||||
in raw mode, the interrupt, quit, suspend, and flow control characters
|
||||
are all passed through uninterpreted, instead of generating a signal.
|
||||
The behavior of the BREAK key depends on other bits in the tty driver
|
||||
that are not set by <STRONG>curses</STRONG>.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-noqiflush">noqiflush</a></H3><PRE>
|
||||
When the <STRONG>noqiflush</STRONG> routine is used, normal flush of input and output
|
||||
queues associated with the <STRONG>INTR</STRONG>, <STRONG>QUIT</STRONG> and <STRONG>SUSP</STRONG> characters will not be
|
||||
done [see <STRONG>termios(3)</STRONG>]. When <STRONG>qiflush</STRONG> is called, the queues will be
|
||||
flushed when these control characters are read. You may want to call
|
||||
<STRONG>noqiflush</STRONG> in a signal handler if you want output to continue as though
|
||||
</PRE><H3><a name="h3-qiflush_noqiflush">qiflush/noqiflush</a></H3><PRE>
|
||||
When the <STRONG>noqiflush</STRONG> routine is used, normal flush of input and output
|
||||
queues associated with the <STRONG>INTR</STRONG>, <STRONG>QUIT</STRONG> and <STRONG>SUSP</STRONG> characters will not be
|
||||
done [see <STRONG>termios(3)</STRONG>]. When <STRONG>qiflush</STRONG> is called, the queues will be
|
||||
flushed when these control characters are read. You may want to call
|
||||
<STRONG>noqiflush</STRONG> in a signal handler if you want output to continue as though
|
||||
the interrupt had not occurred, after the handler exits.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-timeout_wtimeout">timeout/wtimeout</a></H3><PRE>
|
||||
The <STRONG>timeout</STRONG> and <STRONG>wtimeout</STRONG> routines set blocking or non-blocking read for
|
||||
a given window. If <EM>delay</EM> is negative, blocking read is used (i.e.,
|
||||
waits indefinitely for input). If <EM>delay</EM> is zero, then non-blocking
|
||||
a given window. If <EM>delay</EM> is negative, blocking read is used (i.e.,
|
||||
waits indefinitely for input). If <EM>delay</EM> is zero, then non-blocking
|
||||
read is used (i.e., read returns <STRONG>ERR</STRONG> if no input is waiting). If <EM>delay</EM>
|
||||
is positive, then read blocks for <EM>delay</EM> milliseconds, and returns <STRONG>ERR</STRONG>
|
||||
if there is still no input. Hence, these routines provide the same
|
||||
functionality as <STRONG>nodelay</STRONG>, plus the additional capability of being able
|
||||
is positive, then read blocks for <EM>delay</EM> milliseconds, and returns <STRONG>ERR</STRONG>
|
||||
if there is still no input. Hence, these routines provide the same
|
||||
functionality as <STRONG>nodelay</STRONG>, plus the additional capability of being able
|
||||
to block for only <EM>delay</EM> milliseconds (where <EM>delay</EM> is positive).
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-typeahead">typeahead</a></H3><PRE>
|
||||
The <STRONG>curses</STRONG> library does "line-breakout optimization" by looking for ty-
|
||||
peahead periodically while updating the screen. If input is found, and
|
||||
it is coming from a tty, the current update is postponed until <STRONG>re-</STRONG>
|
||||
<STRONG><A HREF="refresh.3x.html">fresh(3x)</A></STRONG> or <STRONG>doupdate</STRONG> is called again. This allows faster response to
|
||||
commands typed in advance. Normally, the input FILE pointer passed to
|
||||
it is coming from a tty, the current update is postponed until <STRONG>re-</STRONG>
|
||||
<STRONG><A HREF="refresh.3x.html">fresh(3x)</A></STRONG> or <STRONG>doupdate</STRONG> is called again. This allows faster response to
|
||||
commands typed in advance. Normally, the input FILE pointer passed to
|
||||
<STRONG>newterm</STRONG>, or <STRONG>stdin</STRONG> in the case that <STRONG>initscr</STRONG> was used, will be used to do
|
||||
this typeahead checking. The <STRONG>typeahead</STRONG> routine specifies that the file
|
||||
descriptor <EM>fd</EM> is to be used to check for typeahead instead. If <EM>fd</EM> is
|
||||
descriptor <EM>fd</EM> is to be used to check for typeahead instead. If <EM>fd</EM> is
|
||||
-1, then no typeahead checking is done.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG>
|
||||
All routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG>
|
||||
(SVr4 specifies only "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion, unless otherwise noted in the preceding routine descrip-
|
||||
completion, unless otherwise noted in the preceding routine descrip-
|
||||
tions.
|
||||
|
||||
X/Open does not define any error conditions. In this implementation,
|
||||
functions with a window parameter will return an error if it is null.
|
||||
X/Open does not define any error conditions. In this implementation,
|
||||
functions with a window parameter will return an error if it is null.
|
||||
Any function will also return an error if the terminal was not initial-
|
||||
ized. Also,
|
||||
|
||||
<STRONG>halfdelay</STRONG>
|
||||
returns an error if its parameter is outside the range
|
||||
returns an error if its parameter is outside the range
|
||||
1..255.
|
||||
|
||||
|
||||
@ -227,13 +243,20 @@
|
||||
These functions are described in the XSI Curses standard, Issue 4.
|
||||
|
||||
The ncurses library obeys the XPG4 standard and the historical practice
|
||||
of the AT&T curses implementations, in that the echo bit is cleared
|
||||
when curses initializes the terminal state. BSD curses differed from
|
||||
this slightly; it left the echo bit on at initialization, but the BSD
|
||||
<STRONG>raw</STRONG> call turned it off as a side-effect. For best portability, set
|
||||
echo or noecho explicitly just after initialization, even if your pro-
|
||||
of the AT&T curses implementations, in that the echo bit is cleared
|
||||
when curses initializes the terminal state. BSD curses differed from
|
||||
this slightly; it left the echo bit on at initialization, but the BSD
|
||||
<STRONG>raw</STRONG> call turned it off as a side-effect. For best portability, set
|
||||
<STRONG>echo</STRONG> or <STRONG>noecho</STRONG> explicitly just after initialization, even if your pro-
|
||||
gram remains in cooked mode.
|
||||
|
||||
The XSI Curses standard is ambiguous on the question of whether <STRONG>raw</STRONG>
|
||||
should disable the CRLF translations controlled by <STRONG>nl</STRONG> and <STRONG>nonl</STRONG>. BSD
|
||||
curses did turn off these translations; AT&T curses (at least as late
|
||||
as SVr1) did not. We chose to do so, on the theory that a programmer
|
||||
requesting raw input wants a clean (ideally 8-bit clean) connection
|
||||
that the operating system will not alter.
|
||||
|
||||
When <STRONG>keypad</STRONG> is first enabled, ncurses loads the key-definitions for the
|
||||
current terminal description. If the terminal description includes ex-
|
||||
tended string capabilities, e.g., from using the <STRONG>-x</STRONG> option of <STRONG>tic</STRONG>, then
|
||||
@ -263,8 +286,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
Note that <STRONG>echo</STRONG>, <STRONG>noecho</STRONG>, <STRONG>halfdelay</STRONG>, <STRONG>intrflush</STRONG>, <STRONG>meta</STRONG>, <STRONG>nodelay</STRONG>, <STRONG>notimeout</STRONG>,
|
||||
<STRONG>noqiflush</STRONG>, <STRONG>qiflush</STRONG>, <STRONG>timeout</STRONG>, and <STRONG>wtimeout</STRONG> may be macros.
|
||||
Note that <STRONG>echo</STRONG>, <STRONG>noecho</STRONG>, <STRONG>halfdelay</STRONG>, <STRONG>intrflush</STRONG>, <STRONG>meta</STRONG>, <STRONG>nl</STRONG>, <STRONG>nonl</STRONG>, <STRONG>nodelay</STRONG>,
|
||||
<STRONG>notimeout</STRONG>, <STRONG>noqiflush</STRONG>, <STRONG>qiflush</STRONG>, <STRONG>timeout</STRONG>, and <STRONG>wtimeout</STRONG> may be macros.
|
||||
|
||||
The <STRONG>noraw</STRONG> and <STRONG>nocbreak</STRONG> calls follow historical practice in that they
|
||||
attempt to restore to normal ("cooked") mode from raw and cbreak modes
|
||||
@ -287,15 +310,17 @@
|
||||
<li><a href="#h2-SYNOPSIS">SYNOPSIS</a></li>
|
||||
<li><a href="#h2-DESCRIPTION">DESCRIPTION</a>
|
||||
<ul>
|
||||
<li><a href="#h3-cbreak">cbreak</a></li>
|
||||
<li><a href="#h3-cbreak_nocbreak">cbreak/nocbreak</a></li>
|
||||
<li><a href="#h3-echo_noecho">echo/noecho</a></li>
|
||||
<li><a href="#h3-halfdelay">halfdelay</a></li>
|
||||
<li><a href="#h3-intrflush">intrflush</a></li>
|
||||
<li><a href="#h3-keypad">keypad</a></li>
|
||||
<li><a href="#h3-meta">meta</a></li>
|
||||
<li><a href="#h3-nl_nonl">nl/nonl</a></li>
|
||||
<li><a href="#h3-nodelay">nodelay</a></li>
|
||||
<li><a href="#h3-notimeout">notimeout</a></li>
|
||||
<li><a href="#h3-raw_noraw">raw/noraw</a></li>
|
||||
<li><a href="#h3-noqiflush">noqiflush</a></li>
|
||||
<li><a href="#h3-qiflush_noqiflush">qiflush/noqiflush</a></li>
|
||||
<li><a href="#h3-timeout_wtimeout">timeout/wtimeout</a></li>
|
||||
<li><a href="#h3-typeahead">typeahead</a></li>
|
||||
</ul>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_ins_wch.3x,v 1.8 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_ins_wch.3x,v 1.10 2020/10/18 00:22:21 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,9 +55,10 @@
|
||||
#include <curses.h>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>ins_wch(const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wins_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win,</EM> <EM>const</EM> <EM>cchar</EM><STRONG>_</STRONG><EM>t</EM> <EM>*wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvins_wch(int</STRONG> <EM>y,</EM> <EM>int</EM> <EM>x,</EM> <EM>const</EM> <EM>cchar</EM><STRONG>_</STRONG><EM>t</EM> <EM>*wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwins_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win,</EM> <EM>int</EM> <EM>y,</EM> <EM>int</EM> <EM>x,</EM> <EM>const</EM> <EM>cchar</EM><STRONG>_</STRONG><EM>t</EM> <EM>*wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wins_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvins_wch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwins_wch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>wch</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_ins_wstr.3x,v 1.10 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_ins_wstr.3x,v 1.11 2020/10/17 23:21:25 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>ins_nwstr(const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wins_wstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wins_nwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvins_wstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvins_nwstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwins_wstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_insch.3x,v 1.17 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_insch.3x,v 1.19 2020/10/18 00:21:39 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,10 +54,11 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>insch(chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinsch(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsch(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>chtype</STRONG> <STRONG>ch);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insch(chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvinsch(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsch(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -71,8 +72,8 @@
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG>
|
||||
(SVr4 specifies only "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion, unless otherwise noted in the preceding routine descrip-
|
||||
tions.
|
||||
completion, unless otherwise noted in the preceding routine
|
||||
descriptions.
|
||||
|
||||
Functions with a "mv" prefix first perform a cursor movement using
|
||||
<STRONG>wmove</STRONG>, and return an error if the position is outside the window, or if
|
||||
@ -80,8 +81,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
These routines do not necessarily imply use of a hardware insert char-
|
||||
acter feature.
|
||||
These routines do not necessarily imply use of a hardware insert
|
||||
character feature.
|
||||
|
||||
Note that <STRONG>insch</STRONG>, <STRONG>mvinsch</STRONG>, and <STRONG>mvwinsch</STRONG> may be macros.
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_insstr.3x,v 1.24 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_insstr.3x,v 1.26 2020/10/18 00:20:36 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -53,14 +53,15 @@
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insnstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinsstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinsnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>insnstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winsnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvinsstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinsnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinsnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -78,8 +79,8 @@
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG>
|
||||
(SVr4 specifies only "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion, unless otherwise noted in the preceding routine descrip-
|
||||
tions.
|
||||
completion, unless otherwise noted in the preceding routine
|
||||
descriptions.
|
||||
|
||||
X/Open defines no error conditions. In this implementation, if the
|
||||
window parameter is null or the str parameter is null, an error is
|
||||
@ -98,10 +99,10 @@
|
||||
These functions are described in the XSI Curses standard, Issue 4,
|
||||
which adds const qualifiers to the arguments.
|
||||
|
||||
The Single Unix Specification, Version 2 states that <STRONG>insnstr</STRONG> and <STRONG>win-</STRONG>
|
||||
<STRONG>snstr</STRONG> perform wrapping. This is probably an error, since it makes this
|
||||
group of functions inconsistent. Also, no implementation of curses
|
||||
documents this inconsistency.
|
||||
The Single Unix Specification, Version 2 states that <STRONG>insnstr</STRONG> and
|
||||
<STRONG>winsnstr</STRONG> perform wrapping. This is probably an error, since it makes
|
||||
this group of functions inconsistent. Also, no implementation of
|
||||
curses documents this inconsistency.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_instr.3x,v 1.20 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_instr.3x,v 1.22 2020/10/18 00:18:27 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,27 +54,28 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>instr(char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>innstr(char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinnstr(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinnstr(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>instr(char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>innstr(char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvinstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinnstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinnstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These routines return a string of characters in <EM>str</EM>, extracted starting
|
||||
at the current cursor position in the named window. Attributes are
|
||||
stripped from the characters. The four functions with <EM>n</EM> as the last
|
||||
argument return a leading substring at most <EM>n</EM> characters long (exclu-
|
||||
sive of the trailing NUL).
|
||||
argument return a leading substring at most <EM>n</EM> characters long
|
||||
(exclusive of the trailing NUL).
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
All of the functions return <STRONG>ERR</STRONG> upon failure, or the number of charac-
|
||||
ters actually read into the string.
|
||||
All of the functions return <STRONG>ERR</STRONG> upon failure, or the number of
|
||||
characters actually read into the string.
|
||||
|
||||
X/Open Curses defines no error conditions. In this implementation:
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_inwstr.3x,v 1.13 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_inwstr.3x,v 1.14 2020/10/17 23:22:11 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -58,6 +58,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>innwstr(wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>winnwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mvinwstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvinnwstr(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwinwstr(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>wstr</EM><STRONG>);</STRONG>
|
||||
@ -68,22 +69,22 @@
|
||||
These routines return a string of <STRONG>wchar_t</STRONG> wide characters in <EM>wstr</EM>,
|
||||
extracted starting at the current cursor position in the named window.
|
||||
|
||||
The four functions with <EM>n</EM> as the last argument return a leading sub-
|
||||
string at most <EM>n</EM> characters long (exclusive of the trailing NUL).
|
||||
The four functions with <EM>n</EM> as the last argument return a leading
|
||||
substring at most <EM>n</EM> characters long (exclusive of the trailing NUL).
|
||||
Transfer stops at the end of the current line, or when <EM>n</EM> characters
|
||||
have been stored at the location referenced by <EM>wstr</EM>.
|
||||
|
||||
If the size <EM>n</EM> is not large enough to store a complete complex charac-
|
||||
ter, an error is generated.
|
||||
If the size <EM>n</EM> is not large enough to store a complete complex
|
||||
character, an error is generated.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
All routines except <STRONG>winnwstr</STRONG> may be macros.
|
||||
|
||||
Each cell in the window holds a complex character (i.e., base- and com-
|
||||
bining-characters) together with attributes and color. These functions
|
||||
store only the wide characters, ignoring attributes and color. Use
|
||||
<STRONG>in_wchstr</STRONG> to return the complex characters from a window.
|
||||
Each cell in the window holds a complex character (i.e., base- and
|
||||
combining-characters) together with attributes and color. These
|
||||
functions store only the wide characters, ignoring attributes and
|
||||
color. Use <STRONG>in_wchstr</STRONG> to return the complex characters from a window.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_kernel.3x,v 1.28 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_kernel.3x,v 1.29 2020/10/17 23:22:35 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -57,12 +57,16 @@
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>def_prog_mode(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>def_shell_mode(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>reset_prog_mode(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>reset_shell_mode(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>resetty(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>savetty(void);</STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>getsyx(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>setsyx(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>ripoffline(int</STRONG> <EM>line</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>(*</STRONG><EM>init</EM><STRONG>)(WINDOW</STRONG> <STRONG>*,</STRONG> <STRONG>int));</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>curs_set(int</STRONG> <EM>visibility</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>napms(int</STRONG> <EM>ms</EM><STRONG>);</STRONG>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_legacy.3x,v 1.10 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_legacy.3x,v 1.12 2020/10/18 00:16:04 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -53,20 +53,24 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getattrs(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getbegx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getbegy(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getcurx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getcury(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getmaxx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getmaxy(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getparx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getpary(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getattrs(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getbegx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getbegy(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getcurx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getcury(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getmaxx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getmaxy(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getparx(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getpary(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These legacy functions are simpler to use than the X/Open Curses func-
|
||||
tions:
|
||||
These legacy functions are simpler to use than the X/Open Curses
|
||||
functions:
|
||||
|
||||
<STRONG>o</STRONG> The <STRONG>getattrs</STRONG> function returns the same attribute data as <STRONG>wattr_get</STRONG>.
|
||||
|
||||
@ -91,8 +95,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
Except as noted, these functions return an integer, or <STRONG>ERR</STRONG> if the win-
|
||||
dow parameter is null.
|
||||
Except as noted, these functions return an integer, or <STRONG>ERR</STRONG> if the
|
||||
window parameter is null.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
@ -105,12 +109,13 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
These functions were supported on Version 7, BSD or System V implemen-
|
||||
tations. None of those implementations checked the window parameter.
|
||||
These functions were supported on Version 7, BSD or System V
|
||||
implementations. None of those implementations checked the window
|
||||
parameter.
|
||||
|
||||
The <STRONG>getattrs</STRONG> 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.
|
||||
The <STRONG>getattrs</STRONG> function and macro are defined to return a (signed)
|
||||
integer for compatibility with those implementations although an
|
||||
unsigned type would have been more appropriate.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<!--
|
||||
****************************************************************************
|
||||
* Copyright 2019,2020 Thomas E. Dickey *
|
||||
* Copyright 2019-2020,2021 Thomas E. Dickey *
|
||||
* Copyright 2008-2010,2017 Free Software Foundation, Inc. *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_memleaks.3x,v 1.8 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_memleaks.3x,v 1.11 2021/01/02 23:47:51 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -47,36 +47,36 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NAME">NAME</a></H2><PRE>
|
||||
<STRONG>_nc_freeall</STRONG>, <STRONG>_nc_free_and_exit</STRONG>, <STRONG>_nc_free_tinfo</STRONG> - <STRONG>curses</STRONG> memory-leak
|
||||
checking
|
||||
<STRONG>exit_curses</STRONG>, <STRONG>exit_terminfo</STRONG> - <STRONG>curses</STRONG> memory-leak checking
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>exit_curses(int</STRONG> <EM>code</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>exit_curses(int);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>exit_terminfo(int);</STRONG>
|
||||
<STRONG>#include</STRONG> <STRONG><term.h></STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>exit_terminfo(int</STRONG> <EM>code</EM><STRONG>);</STRONG>
|
||||
|
||||
/* deprecated */
|
||||
/* deprecated (intentionally not declared in curses.h or term.h) */
|
||||
<STRONG>void</STRONG> <STRONG>_nc_freeall(void);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>_nc_free_and_exit(int);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>_nc_free_tinfo(int);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>_nc_free_and_exit(int</STRONG> <EM>code</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>_nc_free_tinfo(int</STRONG> <EM>code</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These functions are used to simplify analysis of memory leaks in the
|
||||
These functions are used to simplify analysis of memory leaks in the
|
||||
ncurses library.
|
||||
|
||||
Any implementation of curses must not free the memory associated with a
|
||||
screen, since (even after calling <STRONG>endwin</STRONG>), it must be available for use
|
||||
in the next call to <STRONG><A HREF="curs_refresh.3x.html">refresh(3x)</A></STRONG>. There are also chunks of memory held
|
||||
for performance reasons. That makes it hard to analyze curses applica-
|
||||
tions for memory leaks. When using the specially configured debugging
|
||||
version of the ncurses library, applications can call functions which
|
||||
free those chunks of memory, simplifying the process of memory-leak
|
||||
checking.
|
||||
screen, since (even after calling <STRONG><A HREF="curs_initscr.3x.html">endwin(3x)</A></STRONG>), it must be available for
|
||||
use in the next call to <STRONG><A HREF="curs_refresh.3x.html">refresh(3x)</A></STRONG>. There are also chunks of memory
|
||||
held for performance reasons. That makes it hard to analyze curses ap-
|
||||
plications for memory leaks. When using the specially configured de-
|
||||
bugging version of the ncurses library, applications can call functions
|
||||
which free those chunks of memory, simplifying the process of memory-
|
||||
leak checking.
|
||||
|
||||
Some of the functions are named with a "_nc_" prefix because they are
|
||||
Some of the functions are named with a "_nc_" prefix because they are
|
||||
not intended for use in the non-debugging library:
|
||||
|
||||
<STRONG>_nc_freeall</STRONG>
|
||||
@ -89,18 +89,18 @@
|
||||
ply exiting (with the given exit-code) is safer.
|
||||
|
||||
<STRONG>_nc_free_tinfo</STRONG>
|
||||
Use this function if only the low-level terminfo functions (and
|
||||
Use this function if only the low-level terminfo functions (and
|
||||
corresponding library) are used. Like <STRONG>_nc_free_and_exit</STRONG>, it exits
|
||||
the program after freeing memory.
|
||||
|
||||
The functions prefixed "_nc" are normally not available; they must be
|
||||
The functions prefixed "_nc" are normally not available; they must be
|
||||
configured into the library at build time using the <STRONG>--disable-leaks</STRONG> op-
|
||||
tion. That compiles-in code that frees memory that normally would not
|
||||
tion. That compiles-in code that frees memory that normally would not
|
||||
be freed.
|
||||
|
||||
The <STRONG>exit_curses</STRONG> and <STRONG>exit_terminfo</STRONG> functions call <STRONG>_nc_free_and_exit</STRONG> and
|
||||
<STRONG>_nc_free_tinfo</STRONG> if the library is configured to support memory-leak
|
||||
checking. If the library is not configured to support memory-leak
|
||||
The <STRONG>exit_curses</STRONG> and <STRONG>exit_terminfo</STRONG> functions call <STRONG>_nc_free_and_exit</STRONG> and
|
||||
<STRONG>_nc_free_tinfo</STRONG> if the library is configured to support memory-leak
|
||||
checking. If the library is not configured to support memory-leak
|
||||
checking, they simply call <STRONG>exit</STRONG>.
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_mouse.3x,v 1.52 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_mouse.3x,v 1.53 2020/10/17 23:25:08 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -64,13 +64,18 @@
|
||||
<STRONG>}</STRONG> <STRONG>MEVENT;</STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>has_mouse(void);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>getmouse(MEVENT</STRONG> <STRONG>*</STRONG><EM>event</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ungetmouse(MEVENT</STRONG> <STRONG>*</STRONG><EM>event</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>mmask_t</STRONG> <STRONG>mousemask(mmask_t</STRONG> <EM>newmask</EM><STRONG>,</STRONG> <STRONG>mmask_t</STRONG> <STRONG>*</STRONG><EM>oldmask</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>wenclose(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>mouse_trafo(int*</STRONG> <EM>pY</EM><STRONG>,</STRONG> <STRONG>int*</STRONG> <EM>pX</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>to</EM><STRONG>_</STRONG><EM>screen</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>wmouse_trafo(const</STRONG> <STRONG>WINDOW*</STRONG> <EM>win</EM><STRONG>,</STRONG> <STRONG>int*</STRONG> <EM>pY</EM><STRONG>,</STRONG> <STRONG>int*</STRONG> <EM>pX</EM><STRONG>,</STRONG>
|
||||
<STRONG>bool</STRONG> <EM>to</EM><STRONG>_</STRONG><EM>screen</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>wmouse_trafo(const</STRONG> <STRONG>WINDOW*</STRONG> <EM>win</EM><STRONG>,</STRONG>
|
||||
<STRONG>int*</STRONG> <EM>pY</EM><STRONG>,</STRONG> <STRONG>int*</STRONG> <EM>pX</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>to</EM><STRONG>_</STRONG><EM>screen</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mouseinterval(int</STRONG> <EM>erval</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
@ -107,12 +112,12 @@
|
||||
BUTTON2_PRESSED mouse button 2 down
|
||||
BUTTON2_RELEASED mouse button 2 up
|
||||
BUTTON2_CLICKED mouse button 2 clicked
|
||||
|
||||
BUTTON2_DOUBLE_CLICKED mouse button 2 double clicked
|
||||
BUTTON2_TRIPLE_CLICKED mouse button 2 triple clicked
|
||||
---------------------------------------------------------------------
|
||||
BUTTON3_PRESSED mouse button 3 down
|
||||
BUTTON3_RELEASED mouse button 3 up
|
||||
|
||||
BUTTON3_CLICKED mouse button 3 clicked
|
||||
BUTTON3_DOUBLE_CLICKED mouse button 3 double clicked
|
||||
BUTTON3_TRIPLE_CLICKED mouse button 3 triple clicked
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_move.3x,v 1.18 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_move.3x,v 1.19 2020/10/24 09:39:41 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -53,8 +53,8 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>move(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wmove(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>move(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wmove(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_opaque.3x,v 1.14 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_opaque.3x,v 1.15 2020/10/24 09:41:22 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,21 +55,21 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>is_cleared(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_idcok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_idlok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_immedok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_keypad(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_leaveok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_nodelay(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_notimeout(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_pad(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_scrollok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_subwin(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_syncok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>WINDOW</STRONG> <STRONG>*</STRONG> <STRONG>wgetparent(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetdelay(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetscrreg(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>*top,</STRONG> <STRONG>int</STRONG> <STRONG>*bottom);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_cleared(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_idcok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_idlok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_immedok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_keypad(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_leaveok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_nodelay(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_notimeout(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_pad(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_scrollok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_subwin(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_syncok(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>WINDOW</STRONG> <STRONG>*</STRONG> <STRONG>wgetparent(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetdelay(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wgetscrreg(const</STRONG> <STRONG>WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>top</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>bottom</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_outopts.3x,v 1.30 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_outopts.3x,v 1.33 2020/10/03 22:04:09 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -48,7 +48,7 @@
|
||||
|
||||
</PRE><H2><a name="h2-NAME">NAME</a></H2><PRE>
|
||||
<STRONG>clearok</STRONG>, <STRONG>idlok</STRONG>, <STRONG>idcok</STRONG>, <STRONG>immedok</STRONG>, <STRONG>leaveok</STRONG>, <STRONG>setscrreg</STRONG>, <STRONG>wsetscrreg</STRONG>,
|
||||
<STRONG>scrollok</STRONG>, <STRONG>nl</STRONG>, <STRONG>nonl</STRONG> - <STRONG>curses</STRONG> output options
|
||||
<STRONG>scrollok</STRONG> - <STRONG>curses</STRONG> output options
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
@ -59,11 +59,10 @@
|
||||
<STRONG>void</STRONG> <STRONG>idcok(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>immedok(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>leaveok(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scrollok(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>setscrreg(int</STRONG> <EM>top</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bot</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wsetscrreg(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>top</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bot</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scrollok(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nl(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nonl(void);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -118,7 +117,17 @@
|
||||
cursor motions.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-setscrreg">setscrreg</a></H3><PRE>
|
||||
</PRE><H3><a name="h3-scrollok">scrollok</a></H3><PRE>
|
||||
The <STRONG>scrollok</STRONG> option controls what happens when the cursor of a window
|
||||
is moved off the edge of the window or scrolling region, either as a
|
||||
result of a newline action on the bottom line, or typing the last char-
|
||||
acter of the last line. If disabled, (<EM>bf</EM> is <STRONG>FALSE</STRONG>), the cursor is left
|
||||
on the bottom line. If enabled, (<EM>bf</EM> is <STRONG>TRUE</STRONG>), the window is scrolled
|
||||
up one line (Note that to get the physical scrolling effect on the ter-
|
||||
minal, it is also necessary to call <STRONG>idlok</STRONG>).
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-setscrreg_wsetscrreg">setscrreg/wsetscrreg</a></H3><PRE>
|
||||
The <STRONG>setscrreg</STRONG> and <STRONG>wsetscrreg</STRONG> routines allow the application programmer
|
||||
to set a software scrolling region in a window. The <EM>top</EM> and <EM>bot</EM> param-
|
||||
eters are the line numbers of the top and bottom margin of the
|
||||
@ -132,57 +141,37 @@
|
||||
line capability, they will probably be used by the output routines.)
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-scrollok">scrollok</a></H3><PRE>
|
||||
The <STRONG>scrollok</STRONG> option controls what happens when the cursor of a window
|
||||
is moved off the edge of the window or scrolling region, either as a
|
||||
result of a newline action on the bottom line, or typing the last char-
|
||||
acter of the last line. If disabled, (<EM>bf</EM> is <STRONG>FALSE</STRONG>), the cursor is left
|
||||
on the bottom line. If enabled, (<EM>bf</EM> is <STRONG>TRUE</STRONG>), the window is scrolled
|
||||
up one line (Note that to get the physical scrolling effect on the ter-
|
||||
minal, it is also necessary to call <STRONG>idlok</STRONG>).
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-nl_-nonl">nl, nonl</a></H3><PRE>
|
||||
The <STRONG>nl</STRONG> and <STRONG>nonl</STRONG> routines control whether the underlying display device
|
||||
translates the return key into newline on input, and whether it trans-
|
||||
lates newline into return and line-feed on output (in either case, the
|
||||
call <STRONG>addch('\n')</STRONG> does the equivalent of return and line feed on the
|
||||
<EM>virtual</EM> <EM>screen</EM>). Initially, these translations do occur. If you dis-
|
||||
able them using <STRONG>nonl</STRONG>, <STRONG>curses</STRONG> will be able to make better use of the
|
||||
line-feed capability, resulting in faster cursor motion. Also, <STRONG>curses</STRONG>
|
||||
will then be able to detect the return key.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
The functions <STRONG>setscrreg</STRONG> and <STRONG>wsetscrreg</STRONG> return <STRONG>OK</STRONG> upon success and <STRONG>ERR</STRONG>
|
||||
upon failure. All other routines that return an integer always return
|
||||
The functions <STRONG>setscrreg</STRONG> and <STRONG>wsetscrreg</STRONG> return <STRONG>OK</STRONG> upon success and <STRONG>ERR</STRONG>
|
||||
upon failure. All other routines that return an integer always return
|
||||
<STRONG>OK</STRONG>.
|
||||
|
||||
X/Open Curses does not define any error conditions.
|
||||
|
||||
In this implementation, those functions that have a window pointer will
|
||||
return an error if the window pointer is null.
|
||||
In this implementation,
|
||||
|
||||
<STRONG>wclrtoeol</STRONG>
|
||||
returns an error if the cursor position is about to wrap.
|
||||
<STRONG>o</STRONG> those functions that have a window pointer will return an error if
|
||||
the window pointer is null
|
||||
|
||||
<STRONG>wsetscrreg</STRONG>
|
||||
returns an error if the scrolling region limits extend out-
|
||||
side the window.
|
||||
<STRONG>o</STRONG> <STRONG>wsetscrreg</STRONG> returns an error if the scrolling region limits extend
|
||||
outside the window.
|
||||
|
||||
X/Open does not define any error conditions. This implementation re-
|
||||
X/Open does not define any error conditions. This implementation re-
|
||||
turns an error if the window pointer is null.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
These functions are described in the XSI Curses standard, Issue 4.
|
||||
|
||||
The XSI Curses standard is ambiguous on the question of whether <STRONG>raw</STRONG>
|
||||
should disable the CRLF translations controlled by <STRONG>nl</STRONG> and <STRONG>nonl</STRONG>. BSD
|
||||
curses did turn off these translations; AT&T curses (at least as late
|
||||
as SVr1) did not. We choose to do so, on the theory that a programmer
|
||||
requesting raw input wants a clean (ideally 8-bit clean) connection
|
||||
that the operating system will not alter.
|
||||
From the outset, ncurses used <STRONG>nl</STRONG>/<STRONG>nonl</STRONG> to control the conversion of new-
|
||||
lines to carriage return/line-feed on output as well as input. XSI
|
||||
Curses documents only the use of these functions for input. This dif-
|
||||
ference arose from converting the <EM>pcurses</EM> source (which used <STRONG>ioctl</STRONG>
|
||||
calls with the <STRONG>sgttyb</STRONG> structure) to termios (i.e., the POSIX terminal
|
||||
interface). In the former, both input and output were controlled via a
|
||||
single option <STRONG>CRMOD</STRONG>, while the latter separates these features. Be-
|
||||
cause that conversion interferes with output optimization, <STRONG>nl</STRONG>/<STRONG>nonl</STRONG> were
|
||||
amended after ncurses 6.2 to eliminate their effect on output.
|
||||
|
||||
Some historic curses implementations had, as an undocumented feature,
|
||||
the ability to do the equivalent of <STRONG>clearok(...,</STRONG> <STRONG>1)</STRONG> by saying <STRONG>touch-</STRONG>
|
||||
@ -201,8 +190,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
Note that <STRONG>clearok</STRONG>, <STRONG>leaveok</STRONG>, <STRONG>scrollok</STRONG>, <STRONG>idcok</STRONG>, <STRONG>nl</STRONG>, <STRONG>nonl</STRONG> and <STRONG>setscrreg</STRONG> may
|
||||
be macros.
|
||||
Note that <STRONG>clearok</STRONG>, <STRONG>leaveok</STRONG>, <STRONG>scrollok</STRONG>, <STRONG>idcok</STRONG>, and <STRONG>setscrreg</STRONG> may be
|
||||
macros.
|
||||
|
||||
The <STRONG>immedok</STRONG> routine is useful for windows that are used as terminal em-
|
||||
ulators.
|
||||
@ -227,9 +216,8 @@
|
||||
<li><a href="#h3-idcok">idcok</a></li>
|
||||
<li><a href="#h3-immedok">immedok</a></li>
|
||||
<li><a href="#h3-leaveok">leaveok</a></li>
|
||||
<li><a href="#h3-setscrreg">setscrreg</a></li>
|
||||
<li><a href="#h3-scrollok">scrollok</a></li>
|
||||
<li><a href="#h3-nl_-nonl">nl, nonl</a></li>
|
||||
<li><a href="#h3-setscrreg_wsetscrreg">setscrreg/wsetscrreg</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a></li>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_print.3x,v 1.14 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_print.3x,v 1.16 2020/10/24 09:25:14 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -53,7 +53,7 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>mcprint(char</STRONG> <STRONG>*data,</STRONG> <STRONG>int</STRONG> <STRONG>len);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mcprint(char</STRONG> <STRONG>*</STRONG><EM>data</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>len</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -64,15 +64,15 @@
|
||||
printer or to know how much buffering it has. Your application is
|
||||
responsible for keeping the rate of writes to the printer below its
|
||||
continuous throughput rate (typically about half of its nominal cps
|
||||
rating). Dot-matrix printers and 6-page-per-minute lasers can typi-
|
||||
cally handle 80cps, so a good conservative rule of thumb is to sleep
|
||||
for a second after shipping each 80-character line.
|
||||
rating). Dot-matrix printers and 6-page-per-minute lasers can
|
||||
typically handle 80cps, so a good conservative rule of thumb is to
|
||||
sleep for a second after shipping each 80-character line.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
The <STRONG>mcprint</STRONG> function returns <STRONG>ERR</STRONG> if the write operation aborted for
|
||||
some reason. In this case, errno will contain either an error associ-
|
||||
ated with <STRONG>write(2)</STRONG> or one of the following:
|
||||
some reason. In this case, <STRONG>errno</STRONG> will contain either an error
|
||||
associated with <STRONG>write(2)</STRONG> or one of the following:
|
||||
|
||||
ENODEV
|
||||
Capabilities for printer redirection do not exist.
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_printw.3x,v 1.25 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_printw.3x,v 1.28 2020/10/24 09:22:45 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,14 +54,14 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>printw(const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wprintw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvprintw(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwprintw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vw_printw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>va_list</STRONG> <STRONG>varglist);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>printw(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wprintw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvprintw(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwprintw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vw_printw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>va_list</STRONG> <EM>varglist</EM><STRONG>);</STRONG>
|
||||
|
||||
/* obsolete */
|
||||
<STRONG>int</STRONG> <STRONG>vwprintw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>va_list</STRONG> <STRONG>varglist);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vwprintw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>va_list</STRONG> <EM>varglist</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -70,7 +70,7 @@
|
||||
<STRONG>printf</STRONG> is output instead as though <STRONG>waddstr</STRONG> were used on the given win-
|
||||
dow.
|
||||
|
||||
The <STRONG>vwprintw</STRONG> and <STRONG>wv_printw</STRONG> routines are analogous to <STRONG>vprintf</STRONG> [see
|
||||
The <STRONG>vwprintw</STRONG> and <STRONG>vw_printw</STRONG> routines are analogous to <STRONG>vprintf</STRONG> [see
|
||||
<STRONG>printf(3)</STRONG>] and perform a <STRONG>wprintw</STRONG> using a variable argument list. The
|
||||
third argument is a <STRONG>va_list</STRONG>, a pointer to a list of arguments, as de-
|
||||
fined in <STRONG><stdarg.h></STRONG>.
|
||||
@ -91,21 +91,48 @@
|
||||
the window pointer is null.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-HISTORY">HISTORY</a></H2><PRE>
|
||||
While <STRONG>printw</STRONG> was implemented in 4BSD, it was unused until 4.2BSD (which
|
||||
used it in games). That early version of curses was before the ANSI C
|
||||
standard. It did not use <varargs.h>, though that was available. In
|
||||
1991 (a couple of years after SVr4 was generally available, and after
|
||||
the C standard was published), other developers updated the library,
|
||||
using <stdarg.h> internally in 4.4BSD curses. Even with this improve-
|
||||
ment, BSD curses did not use function prototypes (or even declare func-
|
||||
tions) in the <curses.h> header until 1992.
|
||||
|
||||
SVr2 documented <STRONG>printw</STRONG>, <STRONG>wprintw</STRONG> tersely as "printf on <EM>stdscr</EM>" and
|
||||
tersely as "printf on <EM>win</EM>", respectively.
|
||||
|
||||
SVr3 added <STRONG>mvprintw</STRONG>, and <STRONG>mvwprintw</STRONG>, with a three-line summary saying
|
||||
that they were analogous to <STRONG>printf(3)</STRONG>, explaining that the string which
|
||||
would be output from <STRONG>printf(3)</STRONG> would instead be output using <STRONG>waddstr</STRONG> on
|
||||
the given window. SVr3 also added <STRONG>vwprintw</STRONG>, saying that the third pa-
|
||||
rameter is a <STRONG>va_list</STRONG>, defined in <varargs.h>, and referring the reader
|
||||
to the manual pages for <EM>varargs</EM> and <EM>vprintf</EM> for detailed descriptions.
|
||||
|
||||
SVr4 added no new variations of <STRONG>printw</STRONG>, but provided for using
|
||||
<varargs.h> or <stdarg.h> to define the <STRONG>va_list</STRONG> type.
|
||||
|
||||
X/Open Curses added <STRONG>vw_printw</STRONG> to replace <STRONG>vwprintw</STRONG>, stating that its
|
||||
<STRONG>va_list</STRONG> definition requires <stdarg.h>.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
In this implementation, <STRONG>vw_printw</STRONG> and <STRONG>vwprintw</STRONG> are equivalent, to sup-
|
||||
In this implementation, <STRONG>vw_printw</STRONG> and <STRONG>vwprintw</STRONG> are equivalent, to sup-
|
||||
port legacy applications. However, the latter (<STRONG>vwprintw</STRONG>) is obsolete:
|
||||
|
||||
<STRONG>o</STRONG> The XSI Curses standard, Issue 4 described these functions. The
|
||||
function <STRONG>vwprintw</STRONG> is marked TO BE WITHDRAWN, and is to be replaced
|
||||
<STRONG>o</STRONG> The XSI Curses standard, Issue 4 described these functions. The
|
||||
function <STRONG>vwprintw</STRONG> is marked TO BE WITHDRAWN, and is to be replaced
|
||||
by a function <STRONG>vw_printw</STRONG> using the <STRONG><stdarg.h></STRONG> interface.
|
||||
|
||||
<STRONG>o</STRONG> The Single Unix Specification, Version 2 states that <STRONG>vw_printw</STRONG> is
|
||||
preferred to <STRONG>vwprintw</STRONG> since the latter requires including
|
||||
<STRONG><varargs.h></STRONG>, which cannot be used in the same file as <STRONG><stdarg.h></STRONG>.
|
||||
This implementation uses <STRONG><stdarg.h></STRONG> for both, because that header
|
||||
<STRONG>o</STRONG> The Single Unix Specification, Version 2 states that <STRONG>vw_printw</STRONG> is
|
||||
preferred to <STRONG>vwprintw</STRONG> since the latter requires including
|
||||
<STRONG><varargs.h></STRONG>, which cannot be used in the same file as <STRONG><stdarg.h></STRONG>.
|
||||
This implementation uses <STRONG><stdarg.h></STRONG> for both, because that header
|
||||
is included in <STRONG><curses.h</STRONG>>.
|
||||
|
||||
<STRONG>o</STRONG> X/Open Curses, Issue 5 (December 2007) marked <STRONG>vwprintw</STRONG> (along with
|
||||
<STRONG>o</STRONG> X/Open Curses, Issue 5 (December 2007) marked <STRONG>vwprintw</STRONG> (along with
|
||||
<STRONG>vwscanw</STRONG> and the termcap interface) as withdrawn.
|
||||
|
||||
|
||||
@ -123,6 +150,7 @@
|
||||
<li><a href="#h2-SYNOPSIS">SYNOPSIS</a></li>
|
||||
<li><a href="#h2-DESCRIPTION">DESCRIPTION</a></li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a></li>
|
||||
<li><a href="#h2-HISTORY">HISTORY</a></li>
|
||||
<li><a href="#h2-PORTABILITY">PORTABILITY</a></li>
|
||||
<li><a href="#h2-SEE-ALSO">SEE ALSO</a></li>
|
||||
</ul>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_refresh.3x,v 1.21 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_refresh.3x,v 1.22 2020/10/24 09:43:49 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -55,11 +55,12 @@
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>refresh(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wrefresh(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wnoutrefresh(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wrefresh(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wnoutrefresh(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>doupdate(void);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>redrawwin(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wredrawln(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>beg_line,</STRONG> <STRONG>int</STRONG> <STRONG>num_lines);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>redrawwin(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wredrawln(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>beg</EM><STRONG>_</STRONG><EM>line</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>num</EM><STRONG>_</STRONG><EM>lines</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_scanw.3x,v 1.26 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_scanw.3x,v 1.28 2020/10/24 09:29:26 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,14 +54,15 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>scanw(const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wscanw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvscanw(int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwscanw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>y,</STRONG> <STRONG>int</STRONG> <STRONG>x,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vw_scanw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>va_list</STRONG> <STRONG>varglist);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scanw(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wscanw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvscanw(int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvwscanw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>x</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>vw_scanw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>va_list</STRONG> <EM>varglist</EM><STRONG>);</STRONG>
|
||||
|
||||
/* obsolete */
|
||||
<STRONG>int</STRONG> <STRONG>vwscanw(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*fmt,</STRONG> <STRONG>va_list</STRONG> <STRONG>varglist);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vwscanw(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>fmt</EM><STRONG>,</STRONG> <STRONG>va_list</STRONG> <EM>varglist</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
@ -89,41 +90,70 @@
|
||||
the window pointer is null.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-HISTORY">HISTORY</a></H2><PRE>
|
||||
While <STRONG>scanw</STRONG> was implemented in 4BSD, none of the BSD releases used it
|
||||
until 4.4BSD (in a game). That early version of curses was before the
|
||||
ANSI C standard. It did not use <varargs.h>, though that was
|
||||
available. In 1991 (a couple of years after SVr4 was generally
|
||||
available, and after the C standard was published), other developers
|
||||
updated the library, using <stdarg.h> internally in 4.4BSD curses.
|
||||
Even with this improvement, BSD curses did not use function prototypes
|
||||
(or even declare functions) in the <curses.h> header until 1992.
|
||||
|
||||
SVr2 documented <STRONG>scanw</STRONG>, <STRONG>wscanw</STRONG> tersely as "scanf through <EM>stdscr</EM>" and
|
||||
tersely as "scanf through <EM>win</EM>", respectively.
|
||||
|
||||
SVr3 added <STRONG>mvscanw</STRONG>, and <STRONG>mvwscanw</STRONG>, with a three-line summary saying that
|
||||
they were analogous to <STRONG>scanf(3)</STRONG>, explaining that the string which would
|
||||
be output from <STRONG>scanf(3)</STRONG> would instead be output using <STRONG>waddstr</STRONG> on the
|
||||
given window. SVr3 also added <STRONG>vwscanw</STRONG>, saying that the third parameter
|
||||
is a <STRONG>va_list</STRONG>, defined in <varargs.h>, and referring the reader to the
|
||||
manual pages for <EM>varargs</EM> and <EM>vprintf</EM> for detailed descriptions.
|
||||
(Because the SVr3 documentation does not mention <EM>vscanf</EM>, that reference
|
||||
to <EM>vprintf</EM> may not be an error).
|
||||
|
||||
SVr4 added no new variations of <STRONG>scanw</STRONG>, but provided for using
|
||||
<varargs.h> or <stdarg.h> to define the <STRONG>va_list</STRONG> type.
|
||||
|
||||
X/Open Curses added <STRONG>vw_scanw</STRONG> to replace <STRONG>vwscanw</STRONG>, stating that its
|
||||
<STRONG>va_list</STRONG> definition requires <stdarg.h>.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
In this implementation, <STRONG>vw_scanw</STRONG> and <STRONG>vwscanw</STRONG> are equivalent, to support
|
||||
legacy applications. However, the latter (<STRONG>vwscanw</STRONG>) is obsolete:
|
||||
|
||||
<STRONG>o</STRONG> The XSI Curses standard, Issue 4 described these functions, noting
|
||||
that the function <STRONG>vwscanw</STRONG> is marked TO BE WITHDRAWN, and is to be
|
||||
<STRONG>o</STRONG> The XSI Curses standard, Issue 4 described these functions, noting
|
||||
that the function <STRONG>vwscanw</STRONG> is marked TO BE WITHDRAWN, and is to be
|
||||
replaced by a function <STRONG>vw_scanw</STRONG> using the <STRONG><stdarg.h></STRONG> interface.
|
||||
|
||||
<STRONG>o</STRONG> The Single Unix Specification, Version 2 states that <STRONG>vw_scanw</STRONG> is
|
||||
preferred to <STRONG>vwscanw</STRONG> since the latter requires including
|
||||
<STRONG><varargs.h></STRONG>, which cannot be used in the same file as <STRONG><stdarg.h></STRONG>.
|
||||
This implementation uses <STRONG><stdarg.h></STRONG> for both, because that header
|
||||
<STRONG>o</STRONG> The Single Unix Specification, Version 2 states that <STRONG>vw_scanw</STRONG> is
|
||||
preferred to <STRONG>vwscanw</STRONG> since the latter requires including
|
||||
<STRONG><varargs.h></STRONG>, which cannot be used in the same file as <STRONG><stdarg.h></STRONG>.
|
||||
This implementation uses <STRONG><stdarg.h></STRONG> for both, because that header
|
||||
is included in <STRONG><curses.h</STRONG>>.
|
||||
|
||||
<STRONG>o</STRONG> X/Open Curses, Issue 5 (December 2007) marked <STRONG>vwscanw</STRONG> (along with
|
||||
<STRONG>o</STRONG> X/Open Curses, Issue 5 (December 2007) marked <STRONG>vwscanw</STRONG> (along with
|
||||
<STRONG>vwprintw</STRONG> and the termcap interface) as withdrawn.
|
||||
|
||||
Both XSI and The Single Unix Specification, Version 2 state that these
|
||||
Both XSI and The Single Unix Specification, Version 2 state that these
|
||||
functions return <STRONG>ERR</STRONG> or <STRONG>OK</STRONG>.
|
||||
|
||||
<STRONG>o</STRONG> Since the underlying <STRONG>scanf(3)</STRONG> can return the number of items
|
||||
<STRONG>o</STRONG> Since the underlying <STRONG>scanf(3)</STRONG> can return the number of items
|
||||
scanned, and the SVr4 code was documented to use this feature, this
|
||||
is probably an editing error which was introduced in XSI, rather
|
||||
is probably an editing error which was introduced in XSI, rather
|
||||
than being done intentionally.
|
||||
|
||||
<STRONG>o</STRONG> This implementation returns the number of items scanned, for com-
|
||||
patibility with SVr4 curses. As of 2018, NetBSD curses also
|
||||
returns the number of items scanned. Both ncurses and NetBSD
|
||||
<STRONG>o</STRONG> This implementation returns the number of items scanned, for
|
||||
compatibility with SVr4 curses. As of 2018, NetBSD curses also
|
||||
returns the number of items scanned. Both ncurses and NetBSD
|
||||
curses call <STRONG>vsscanf</STRONG> to scan the string, which returns <STRONG>EOF</STRONG> on error.
|
||||
|
||||
<STRONG>o</STRONG> Portable applications should only test if the return value is <STRONG>ERR</STRONG>,
|
||||
<STRONG>o</STRONG> Portable applications should only test if the return value is <STRONG>ERR</STRONG>,
|
||||
since the <STRONG>OK</STRONG> value (zero) is likely to be misleading.
|
||||
|
||||
One possible way to get useful results would be to use a "%n" con-
|
||||
version at the end of the format string to ensure that something
|
||||
One possible way to get useful results would be to use a "%n"
|
||||
conversion at the end of the format string to ensure that something
|
||||
was processed.
|
||||
|
||||
|
||||
@ -141,6 +171,7 @@
|
||||
<li><a href="#h2-SYNOPSIS">SYNOPSIS</a></li>
|
||||
<li><a href="#h2-DESCRIPTION">DESCRIPTION</a></li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a></li>
|
||||
<li><a href="#h2-HISTORY">HISTORY</a></li>
|
||||
<li><a href="#h2-PORTABILITY">PORTABILITY</a></li>
|
||||
<li><a href="#h2-SEE-ALSO">SEE ALSO</a></li>
|
||||
</ul>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_scr_dump.3x,v 1.15 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_scr_dump.3x,v 1.16 2020/10/24 09:44:43 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -54,10 +54,10 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>scr_dump(const</STRONG> <STRONG>char</STRONG> <STRONG>*filename);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_restore(const</STRONG> <STRONG>char</STRONG> <STRONG>*filename);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_init(const</STRONG> <STRONG>char</STRONG> <STRONG>*filename);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_set(const</STRONG> <STRONG>char</STRONG> <STRONG>*filename);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_dump(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_restore(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_init(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_set(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_scroll.3x,v 1.18 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_scroll.3x,v 1.19 2020/10/24 09:45:48 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -53,9 +53,10 @@
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>scroll(WINDOW</STRONG> <STRONG>*win);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scrl(int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wscrl(WINDOW</STRONG> <STRONG>*win,</STRONG> <STRONG>int</STRONG> <STRONG>n);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scroll(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>scrl(int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>wscrl(WINDOW</STRONG> <STRONG>*</STRONG><EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>n</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_slk.3x,v 1.36 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_slk.3x,v 1.37 2020/12/30 18:37:43 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -59,6 +59,7 @@
|
||||
<STRONG>int</STRONG> <STRONG>slk_init(int</STRONG> <EM>fmt</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>slk_set(int</STRONG> <EM>labnum</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>label</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fmt</EM><STRONG>);</STRONG>
|
||||
/* extension */
|
||||
<STRONG>int</STRONG> <STRONG>slk_wset(int</STRONG> <EM>labnum</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <STRONG>*</STRONG><EM>label</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fmt</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>char</STRONG> <STRONG>*slk_label(int</STRONG> <EM>labnum</EM><STRONG>);</STRONG>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<!--
|
||||
****************************************************************************
|
||||
* Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
* Copyright 2018-2020,2021 Thomas E. Dickey *
|
||||
* Copyright 2010-2015,2017 Free Software Foundation, Inc. *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_sp_funcs.3x,v 1.18 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_sp_funcs.3x,v 1.24 2021/01/02 23:53:22 tom Exp @
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
@ -54,146 +54,163 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG> <STRONG>#include</STRONG> <STRONG><term.h></STRONG>
|
||||
<STRONG>#include</STRONG> <STRONG><curses.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>alloc_pair_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>assume_default_colors_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>baudrate_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>beep_sp(SCREEN*);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>can_change_color_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>cbreak_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>color_content_sp(SCREEN*,</STRONG> <STRONG>short,</STRONG> <STRONG>short*,</STRONG> <STRONG>short*,</STRONG> <STRONG>short*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>curs_set_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>define_key_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>def_prog_mode_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>def_shell_mode_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>delay_output_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>doupdate_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>echo_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>endwin_sp(SCREEN*);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>erasechar_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_color_content_sp(SCREEN</STRONG> <STRONG>*,</STRONG> <STRONG>int,</STRONG> <STRONG>int</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_pair_content_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int</STRONG> <STRONG>*,</STRONG> <STRONG>int</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_slk_color_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>filter_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>find_pair_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>free_pair_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>flash_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>flushinp_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>get_escdelay_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getmouse_sp(SCREEN*,</STRONG> <STRONG>MEVENT*);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>getwin_sp(SCREEN*,</STRONG> <STRONG>FILE*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>halfdelay_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_colors_sp(SCREEN*);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_ic_sp(SCREEN*);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_il_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>has_key_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_mouse_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_color_sp(SCREEN*,</STRONG> <STRONG>short,</STRONG> <STRONG>short,</STRONG> <STRONG>short,</STRONG> <STRONG>short);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_color_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_pair_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_pair_sp(SCREEN*,</STRONG> <STRONG>short,</STRONG> <STRONG>short,</STRONG> <STRONG>short);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>intrflush_sp(SCREEN*,</STRONG> <STRONG>WINDOW*,</STRONG> <STRONG>bool);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>isendwin_sp(SCREEN*);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_term_resized_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>keybound_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>key_defined_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>NCURSES_CONST</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <STRONG>keyname_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>keyok_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>bool);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>killchar_sp(SCREEN*);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>longname_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mcprint_sp(SCREEN*,</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mouseinterval_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>mmask_t</STRONG> <STRONG>mousemask_sp(SCREEN*,</STRONG> <STRONG>mmask_t,</STRONG> <STRONG>mmask_t</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvcur_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>napms_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>newpad_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>alloc_pair_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>assume_default_colors_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>baudrate_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>beep_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>can_change_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>cbreak_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>color_content_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>short*</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>short*</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>short*</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>curs_set_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>visibility</EM>);
|
||||
<STRONG>int</STRONG> <STRONG>def_prog_mode_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>def_shell_mode_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>define_key_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <EM>definition</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>keycode</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>delay_output_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ms</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>doupdate_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>echo_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>endwin_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>erasechar_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_color_content_sp(SCREEN</STRONG> <STRONG>*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_pair_content_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>extended_slk_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>pair</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>filter_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>find_pair_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>flash_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>flushinp_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>free_pair_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>pair</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>get_escdelay_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>getmouse_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>MEVENT*</STRONG> <STRONG>event);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>getwin_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>FILE*</STRONG> <EM>filep</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>halfdelay_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>tenths</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_colors_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_ic_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>bool</STRONG> <STRONG>has_il_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>has_key_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>has_mouse_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>color</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>r</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>g</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>b</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_extended_pair_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>init_pair_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>intrflush_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>WINDOW*</STRONG> <EM>win</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>is_term_resized_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>lines</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>columns</EM><STRONG>);</STRONG>
|
||||
<STRONG>bool</STRONG> <STRONG>isendwin_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>key_defined_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>definition</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>keybound_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>keycode</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>count</EM><STRONG>);</STRONG>
|
||||
<STRONG>NCURSES_CONST</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <STRONG>keyname_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>c</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>keyok_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>keycode</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>enable</EM><STRONG>);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>killchar_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>longname_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mcprint_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>data</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>len</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mouseinterval_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>erval</EM><STRONG>);</STRONG>
|
||||
<STRONG>mmask_t</STRONG> <STRONG>mousemask_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>mmask_t</STRONG> <EM>newmask</EM><STRONG>,</STRONG> <STRONG>mmask_t</STRONG> <STRONG>*</STRONG><EM>oldmask</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>mvcur_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>oldrow</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>oldcol</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>newrow</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>newcol</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>napms_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ms</EM><STRONG>);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>newpad_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>nrows</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ncols</EM><STRONG>);</STRONG>
|
||||
<STRONG>SCREEN*</STRONG> <STRONG>new_prescr(void);</STRONG>
|
||||
<STRONG>SCREEN*</STRONG> <STRONG>newterm_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>FILE</STRONG> <STRONG>*,</STRONG> <STRONG>FILE</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>newwin_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nl_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nocbreak_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noecho_sp(SCREEN*);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>nofilter_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nonl_sp(SCREEN*);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>noqiflush_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noraw_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>pair_content_sp(SCREEN*,</STRONG> <STRONG>short,</STRONG> <STRONG>short*,</STRONG> <STRONG>short*);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>qiflush_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>raw_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>reset_prog_mode_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>reset_shell_mode_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>resetty_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>resize_term_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>resizeterm_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>restartterm_sp(SCREEN*,</STRONG> <STRONG>NCURSES_CONST</STRONG> <STRONG>char*,</STRONG> <STRONG>int,</STRONG> <STRONG>int</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ripoffline_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>int</STRONG> <STRONG>(*)(WINDOW*,</STRONG> <STRONG>int));</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>savetty_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_init_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_restore_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_set_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>TERMINAL*</STRONG> <STRONG>set_curterm_sp(SCREEN*,</STRONG> <STRONG>TERMINAL*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>set_escdelay_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>set_tabsize_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attroff_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>chtype);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attron_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>chtype);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attr_set_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>attr_t,</STRONG> <STRONG>short,</STRONG> <STRONG>void*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attrset_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>chtype);</STRONG>
|
||||
<STRONG>attr_t</STRONG> <STRONG>slk_attr_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_clear_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_color_sp(SCREEN*,</STRONG> <STRONG>short);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_init_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>slk_label_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_noutrefresh_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_refresh_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_restore_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_set_sp(SCREEN*,</STRONG> <STRONG>int,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_touch_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>start_color_sp(SCREEN*);</STRONG>
|
||||
<STRONG>attr_t</STRONG> <STRONG>term_attrs_sp(SCREEN*);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>termattrs_sp(SCREEN*);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>termname_sp(SCREEN*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>typeahead_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>NCURSES_CONST</STRONG> <STRONG>char*</STRONG> <STRONG>unctrl_sp(SCREEN*,</STRONG> <STRONG>chtype);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ungetch_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ungetmouse_sp(SCREEN*,MEVENT</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>unget_wch_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_default_colors_sp(SCREEN*);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>use_env_sp(SCREEN*,</STRONG> <STRONG>bool);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>use_tioctl_sp(SCREEN</STRONG> <STRONG>*,</STRONG> <STRONG>bool);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_legacy_coding_sp(SCREEN*,</STRONG> <STRONG>int);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vid_attr_sp(SCREEN*,</STRONG> <STRONG>attr_t,</STRONG> <STRONG>short,</STRONG> <STRONG>void</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vidattr_sp(SCREEN*,</STRONG> <STRONG>chtype);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vid_puts_sp(SCREEN*,</STRONG> <STRONG>attr_t,</STRONG> <STRONG>short,</STRONG> <STRONG>void</STRONG> <STRONG>*,</STRONG> <STRONG>NCURSES_SP_OUTC);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vidputs_sp(SCREEN*,</STRONG> <STRONG>chtype,</STRONG> <STRONG>NCURSES_SP_OUTC);</STRONG>
|
||||
<STRONG>wchar_t*</STRONG> <STRONG>wunctrl_sp(SCREEN*,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>SCREEN*</STRONG> <STRONG>newterm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>type</EM><STRONG>,</STRONG> <STRONG>FILE</STRONG> <STRONG>*</STRONG><EM>outfd</EM><STRONG>,</STRONG> <STRONG>FILE</STRONG> <STRONG>*</STRONG><EM>infd</EM><STRONG>);</STRONG>
|
||||
<STRONG>WINDOW*</STRONG> <STRONG>newwin_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>nlines</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ncols</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>begin</EM><STRONG>_</STRONG><EM>y</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>begin</EM><STRONG>_</STRONG><EM>x</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nl_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nocbreak_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noecho_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>nofilter_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>nonl_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>void</STRONG> <STRONG>noqiflush_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>noraw_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>pair_content_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>short*</STRONG> <EM>fg</EM><STRONG>,</STRONG> <STRONG>short*</STRONG> <EM>bg</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>qiflush_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>raw_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>reset_prog_mode_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>reset_color_pairs_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>reset_shell_mode_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>resetty_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>resize_term_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>lines</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>columns</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>resizeterm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>lines</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>columns</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ripoffline_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>line</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>(*</STRONG><EM>init</EM><STRONG>)(WINDOW*</STRONG> <EM>win</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fmt</EM><STRONG>));</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>savetty_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_init_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_restore_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>scr_set_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>filename</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>set_escdelay_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ms</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>set_tabsize_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>cols</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attr_set_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>attr_t</STRONG> <EM>attrs</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>void*</STRONG><EM>opts</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>slk_attrset_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>a</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attroff_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>a</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_attron_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>chtype</STRONG> <EM>a</EM><STRONG>);</STRONG>
|
||||
<STRONG>attr_t</STRONG> <STRONG>slk_attr_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_clear_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_init_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fmt</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>slk_label_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>labnum</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_noutrefresh_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_refresh_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>slk_restore_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_set_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>labnum</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <EM>label</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fmt</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>slk_touch_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>start_color_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>attr_t</STRONG> <STRONG>term_attrs_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>chtype</STRONG> <STRONG>termattrs_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>termname_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>typeahead_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>fd</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>unget_wch_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>wchar_t</STRONG> <EM>wch</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>ungetch_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>ungetmouse_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,MEVENT</STRONG> <STRONG>*</STRONG> <STRONG>event);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_default_colors_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>use_env_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>use_legacy_coding_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>level</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>use_tioctl_sp(SCREEN</STRONG> <STRONG>*</STRONG><EM>sp</EM><STRONG>,</STRONG> <STRONG>bool</STRONG> <EM>bf</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vid_attr_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>attr_t</STRONG> <EM>attrs</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>void</STRONG> <STRONG>*</STRONG> <EM>opts</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vid_puts_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>attr_t</STRONG> <EM>attrs</EM><STRONG>,</STRONG> <STRONG>short</STRONG> <EM>pair</EM><STRONG>,</STRONG> <STRONG>void</STRONG> <STRONG>*</STRONG> <EM>opts</EM><STRONG>,</STRONG> <STRONG>NCURSES_SP_OUTC</STRONG> <EM>putc</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vidattr_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>attrs</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>vidputs_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>attrs</EM><STRONG>,</STRONG> <STRONG>NCURSES_SP_OUTC</STRONG> <EM>putc</EM><STRONG>);</STRONG>
|
||||
<STRONG>wchar_t*</STRONG> <STRONG>wunctrl_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>cchar_t</STRONG> <STRONG>*</STRONG><EM>ch</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>#include</STRONG> <STRONG><form.h></STRONG>
|
||||
|
||||
<STRONG>FORM*</STRONG> <STRONG>new_form_sp(SCREEN*,</STRONG> <STRONG>FIELD</STRONG> <STRONG>**);</STRONG>
|
||||
<STRONG>FORM*</STRONG> <STRONG>new_form_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>FIELD</STRONG> <STRONG>**</STRONG><EM>fields</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>#include</STRONG> <STRONG><menu.h></STRONG>
|
||||
|
||||
<STRONG>MENU*</STRONG> <STRONG>new_menu_sp(SCREEN*,</STRONG> <STRONG>ITEM</STRONG> <STRONG>**);</STRONG>
|
||||
<STRONG>MENU*</STRONG> <STRONG>new_menu_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>ITEM</STRONG> <STRONG>**</STRONG><EM>items</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>#include</STRONG> <STRONG><panel.h></STRONG>
|
||||
|
||||
<STRONG>PANEL*</STRONG> <STRONG>ceiling_panel(SCREEN*);</STRONG>
|
||||
<STRONG>PANEL*</STRONG> <STRONG>ground_panel(SCREEN*);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>update_panels_sp(SCREEN*);</STRONG>
|
||||
<STRONG>PANEL*</STRONG> <STRONG>ceiling_panel(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>PANEL*</STRONG> <STRONG>ground_panel(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
<STRONG>void</STRONG> <STRONG>update_panels_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>#include</STRONG> <STRONG><term.h></STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>del_curterm_sp(SCREEN*,</STRONG> <STRONG>TERMINAL</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>putp_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetflag_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetent_sp(SCREEN*,</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetnum_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>tgetstr_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>char</STRONG> <STRONG>**);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tigetflag_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tigetnum_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>tigetstr_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tputs_sp(SCREEN*,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*,</STRONG> <STRONG>int,</STRONG> <STRONG>NCURSES_SP_OUTC);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>del_curterm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>TERMINAL</STRONG> <STRONG>*</STRONG><EM>oterm</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>putp_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>restartterm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>NCURSES_CONST</STRONG> <STRONG>char*</STRONG><EM>term</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>filedes</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>errret</EM><STRONG>);</STRONG>
|
||||
<STRONG>TERMINAL*</STRONG> <STRONG>set_curterm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>TERMINAL*</STRONG><EM>nterm</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetent_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>bp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>name</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetflag_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetnum_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>tgetstr_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>**</STRONG><EM>area</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>tgoto_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>col</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>row</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tigetflag_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tigetnum_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>);</STRONG>
|
||||
<STRONG>char*</STRONG> <STRONG>tigetstr_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>capname</EM><STRONG>);</STRONG>
|
||||
/* may instead use 9 long parameters */
|
||||
<STRONG>char*</STRONG> <STRONG>tparm_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>...);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tputs_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>affcnt</EM><STRONG>,</STRONG> <STRONG>NCURSES_SP_OUTC</STRONG> <EM>putc</EM><STRONG>);</STRONG>
|
||||
|
||||
<STRONG>#include</STRONG> <STRONG><unctrl.h></STRONG>
|
||||
|
||||
<STRONG>NCURSES_CONST</STRONG> <STRONG>char*</STRONG> <STRONG>unctrl_sp(SCREEN*</STRONG> <EM>sp</EM><STRONG>,</STRONG> <STRONG>chtype</STRONG> <EM>c</EM><STRONG>);</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
|
@ -79,8 +79,8 @@
|
||||
</PRE><H3><a name="h3-erasechar_-erasewchar">erasechar, erasewchar</a></H3><PRE>
|
||||
The <STRONG>erasechar</STRONG> routine returns the user's current erase character.
|
||||
|
||||
The <STRONG>erasewchar</STRONG> routine stores the current erase character in the loca-
|
||||
tion referenced by <EM>ch</EM>. If no erase character has been defined, the
|
||||
The <STRONG>erasewchar</STRONG> routine stores the current erase character in the
|
||||
location referenced by <EM>ch</EM>. If no erase character has been defined, the
|
||||
routine fails and the location referenced by <EM>ch</EM> is not changed.
|
||||
|
||||
|
||||
@ -113,12 +113,13 @@
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-termattrs_-term_attrs">termattrs, term_attrs</a></H3><PRE>
|
||||
If a given terminal does not support a video attribute that an applica-
|
||||
tion program is trying to use, <STRONG>curses</STRONG> may substitute a different video
|
||||
attribute for it. The <STRONG>termattrs</STRONG> and <STRONG>term_attrs</STRONG> functions return a log-
|
||||
ical <STRONG>OR</STRONG> of all video attributes supported by the terminal using <EM>A</EM><STRONG>_</STRONG> and
|
||||
<EM>WA</EM><STRONG>_</STRONG> constants respectively. This information is useful when a <STRONG>curses</STRONG>
|
||||
program needs complete control over the appearance of the screen.
|
||||
If a given terminal does not support a video attribute that an
|
||||
application program is trying to use, <STRONG>curses</STRONG> may substitute a different
|
||||
video attribute for it. The <STRONG>termattrs</STRONG> and <STRONG>term_attrs</STRONG> functions return
|
||||
a logical <STRONG>OR</STRONG> of all video attributes supported by the terminal using <EM>A</EM><STRONG>_</STRONG>
|
||||
and <EM>WA</EM><STRONG>_</STRONG> constants respectively. This information is useful when a
|
||||
<STRONG>curses</STRONG> program needs complete control over the appearance of the
|
||||
screen.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-termname">termname</a></H3><PRE>
|
||||
@ -128,9 +129,9 @@
|
||||
</PRE><H2><a name="h2-RETURN-VALUE">RETURN VALUE</a></H2><PRE>
|
||||
<STRONG>longname</STRONG> and <STRONG>termname</STRONG> return <STRONG>NULL</STRONG> on error.
|
||||
|
||||
Routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG> (SVr4
|
||||
only specifies "an integer value other than <STRONG>ERR</STRONG>") upon successful com-
|
||||
pletion.
|
||||
Routines that return an integer return <STRONG>ERR</STRONG> upon failure and <STRONG>OK</STRONG> (SVr4
|
||||
only specifies "an integer value other than <STRONG>ERR</STRONG>") upon successful
|
||||
completion.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NOTES">NOTES</a></H2><PRE>
|
||||
@ -139,7 +140,7 @@
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
The XSI Curses standard, Issue 4 describes these functions. It changes
|
||||
the return type of <STRONG>termattrs</STRONG> to the new type <STRONG>attr_t</STRONG>. Most versions of
|
||||
the return type of <STRONG>termattrs</STRONG> to the new type <STRONG>attr_t</STRONG>. Most versions of
|
||||
curses truncate the result returned by <STRONG>termname</STRONG> to 14 characters.
|
||||
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
<!--
|
||||
****************************************************************************
|
||||
* Copyright 2018-2019,2020 Thomas E. Dickey *
|
||||
* Copyright 2018-2020,2021 Thomas E. Dickey *
|
||||
* Copyright 1998-2017,2018 Free Software Foundation, Inc. *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -27,7 +27,7 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_termcap.3x,v 1.43 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_termcap.3x,v 1.48 2021/01/09 11:07:15 tom Exp @
|
||||
-->
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
|
||||
<HTML>
|
||||
@ -48,7 +48,7 @@
|
||||
|
||||
</PRE><H2><a name="h2-NAME">NAME</a></H2><PRE>
|
||||
<STRONG>PC</STRONG>, <STRONG>UP</STRONG>, <STRONG>BC</STRONG>, <STRONG>ospeed</STRONG>, <STRONG>tgetent</STRONG>, <STRONG>tgetflag</STRONG>, <STRONG>tgetnum</STRONG>, <STRONG>tgetstr</STRONG>, <STRONG>tgoto</STRONG>, <STRONG>tputs</STRONG> -
|
||||
direct <STRONG>curses</STRONG> interface to the terminfo capability database
|
||||
<STRONG>curses</STRONG> emulation of termcap
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE>
|
||||
@ -60,17 +60,17 @@
|
||||
<STRONG>extern</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <STRONG>BC;</STRONG>
|
||||
<STRONG>extern</STRONG> <STRONG>short</STRONG> <STRONG>ospeed;</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>tgetent(char</STRONG> <STRONG>*bp,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*name);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetflag(const</STRONG> <STRONG>char</STRONG> <STRONG>*id);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetnum(const</STRONG> <STRONG>char</STRONG> <STRONG>*id);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>*tgetstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*id,</STRONG> <STRONG>char</STRONG> <STRONG>**area);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>*tgoto(const</STRONG> <STRONG>char</STRONG> <STRONG>*cap,</STRONG> <STRONG>int</STRONG> <STRONG>col,</STRONG> <STRONG>int</STRONG> <STRONG>row);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tputs(const</STRONG> <STRONG>char</STRONG> <STRONG>*str,</STRONG> <STRONG>int</STRONG> <STRONG>affcnt,</STRONG> <STRONG>int</STRONG> <STRONG>(*putc)(int));</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetent(char</STRONG> <STRONG>*</STRONG><EM>bp</EM><STRONG>,</STRONG> <STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>name</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetflag(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>id</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tgetnum(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>id</EM><STRONG>);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>*tgetstr(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>id</EM><STRONG>,</STRONG> <STRONG>char</STRONG> <STRONG>**</STRONG><EM>area</EM><STRONG>);</STRONG>
|
||||
<STRONG>char</STRONG> <STRONG>*tgoto(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>cap</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>col</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>row</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>tputs(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>str</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>affcnt</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>(*</STRONG><EM>putc</EM><STRONG>)(int));</STRONG>
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE>
|
||||
These routines are included as a conversion aid for programs that use
|
||||
the <EM>termcap</EM> library. Their parameters are the same and the routines
|
||||
the <EM>termcap</EM> library. Their parameters are the same, but the routines
|
||||
are emulated using the <EM>terminfo</EM> database. Thus, they can only be used
|
||||
to query the capabilities of entries for which a terminfo entry has
|
||||
been compiled.
|
||||
@ -195,6 +195,8 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-PORTABILITY">PORTABILITY</a></H2><PRE>
|
||||
|
||||
</PRE><H3><a name="h3-Standards">Standards</a></H3><PRE>
|
||||
These functions are provided for supporting legacy applications, and
|
||||
should not be used in new programs:
|
||||
|
||||
@ -213,6 +215,8 @@
|
||||
bility with the <EM>termcap</EM> library, that is a defect in XCurses, Issue 4,
|
||||
Version 2 rather than in ncurses.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Compatibility-with-BSD-Termcap">Compatibility with BSD Termcap</a></H3><PRE>
|
||||
External variables are provided for support of certain termcap applica-
|
||||
tions. However, termcap applications' use of those variables is poorly
|
||||
documented, e.g., not distinguishing between input and output. In par-
|
||||
@ -237,9 +241,63 @@
|
||||
against extended capability names which are longer than two charac-
|
||||
ters.
|
||||
|
||||
The BSD termcap function <STRONG>tgetent</STRONG> returns the text of a termcap entry in
|
||||
the buffer passed as an argument. This library (like other terminfo
|
||||
implementations) does not store terminal descriptions as text. It sets
|
||||
the buffer contents to a null-terminated string.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Other-Compatibility">Other Compatibility</a></H3><PRE>
|
||||
This library includes a termcap.h header, for compatibility with other
|
||||
implementations. But the header is rarely used because the other im-
|
||||
plementations are not strictly compatible.
|
||||
|
||||
The original BSD termcap (through 4.3BSD) had no header file which gave
|
||||
function prototypes, because that was a feature of ANSI C. BSD termcap
|
||||
was written several years before C was standardized. However, there
|
||||
were two different termcap.h header files in the BSD sources:
|
||||
|
||||
<STRONG>o</STRONG> One was used internally by the <EM>jove</EM> editor in 2BSD through 4.4BSD.
|
||||
It defined global symbols for the termcap variables which it used.
|
||||
|
||||
<STRONG>o</STRONG> The other appeared in 4.4BSD Lite Release 2 (mid-1993) as part of
|
||||
<EM>libedit</EM> (also known as the <EM>editline</EM> library). The CSRG source his-
|
||||
tory shows that this was added in mid-1992. The <EM>libedit</EM> header
|
||||
file was used internally, as a convenience for compiling the <EM>edit-</EM>
|
||||
<EM>line</EM> library. It declared function prototypes, but no global vari-
|
||||
ables.
|
||||
|
||||
The header file from <EM>libedit</EM> was added to NetBSD's termcap library in
|
||||
mid-1994.
|
||||
|
||||
Meanwhile, GNU termcap was under development, starting in 1990. The
|
||||
first release (termcap 1.0) in 1991 included a termcap.h header. The
|
||||
second release (termcap 1.1) in September 1992 modified the header to
|
||||
use <STRONG>const</STRONG> for the function prototypes in the header where one would ex-
|
||||
pect the parameters to be read-only. This was a difference versus the
|
||||
original BSD termcap. The prototype for <STRONG>tputs</STRONG> also differed, but in
|
||||
that instance, it was <EM>libedit</EM> which differed from BSD termcap.
|
||||
|
||||
A copy of GNU termcap 1.3 was bundled with <EM>bash</EM> in mid-1993, to support
|
||||
the <EM>readline</EM> library.
|
||||
|
||||
A termcap.h file was provided in ncurses 1.8.1 (November 1993). That
|
||||
reflected influence by <EM>emacs</EM> (rather than <EM>jove</EM>) and GNU termcap:
|
||||
|
||||
<STRONG>o</STRONG> it provided declarations for a few global symbols used by <EM>emacs</EM>
|
||||
|
||||
<STRONG>o</STRONG> it provided function prototypes (using <STRONG>const</STRONG>).
|
||||
|
||||
<STRONG>o</STRONG> a prototype for <STRONG>tparam</STRONG> (a GNU termcap feature) was provided.
|
||||
|
||||
Later (in mid-1996) the <STRONG>tparam</STRONG> function was removed from ncurses. As a
|
||||
result, there are differences between any of the four implementations,
|
||||
which must be taken into account by programs which can work with all
|
||||
termcap library interfaces.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>, <STRONG><A HREF="term_variables.3x.html">term_variables(3x)</A></STRONG>, <STRONG>putc(3)</STRONG>.
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG>putc(3)</STRONG>, <STRONG><A HREF="term_variables.3x.html">term_variables(3x)</A></STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>.
|
||||
|
||||
https://invisible-island.net/ncurses/tctest.html
|
||||
|
||||
@ -261,7 +319,13 @@
|
||||
</li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a></li>
|
||||
<li><a href="#h2-BUGS">BUGS</a></li>
|
||||
<li><a href="#h2-PORTABILITY">PORTABILITY</a></li>
|
||||
<li><a href="#h2-PORTABILITY">PORTABILITY</a>
|
||||
<ul>
|
||||
<li><a href="#h3-Standards">Standards</a></li>
|
||||
<li><a href="#h3-Compatibility-with-BSD-Termcap">Compatibility with BSD Termcap</a></li>
|
||||
<li><a href="#h3-Other-Compatibility">Other Compatibility</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h2-SEE-ALSO">SEE ALSO</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<!--
|
||||
****************************************************************************
|
||||
* Copyright 2018,2020 Thomas E. Dickey *
|
||||
* Copyright 2018-2020,2021 Thomas E. Dickey *
|
||||
* Copyright 1998-2016,2017 Free Software Foundation, Inc. *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a *
|
||||
@ -27,7 +27,9 @@
|
||||
* sale, use or other dealings in this Software without prior written *
|
||||
* authorization. *
|
||||
****************************************************************************
|
||||
* @Id: curs_terminfo.3x,v 1.64 2020/02/02 23:34:34 tom Exp @
|
||||
* @Id: curs_terminfo.3x,v 1.72 2021/01/02 23:50:04 tom Exp @
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
* ***************************************************************************
|
||||
@ -52,7 +54,7 @@
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-NAME">NAME</a></H2><PRE>
|
||||
<STRONG>del_curterm</STRONG>, <STRONG>mvcur</STRONG>, <STRONG>putp</STRONG>, <STRONG>restartterm</STRONG>, <STRONG>set_curterm</STRONG>, <STRONG>setterm</STRONG>, <STRONG>setupterm</STRONG>,
|
||||
<STRONG>del_curterm</STRONG>, <STRONG>mvcur</STRONG>, <STRONG>putp</STRONG>, <STRONG>restartterm</STRONG>, <STRONG>set_curterm</STRONG>, <STRONG>setupterm</STRONG>,
|
||||
<STRONG>tigetflag</STRONG>, <STRONG>tigetnum</STRONG>, <STRONG>tigetstr</STRONG>, <STRONG>tiparm</STRONG>, <STRONG>tparm</STRONG>, <STRONG>tputs</STRONG>, <STRONG>vid_attr</STRONG>,
|
||||
<STRONG>vid_puts</STRONG>, <STRONG>vidattr</STRONG>, <STRONG>vidputs</STRONG> - <STRONG>curses</STRONG> interfaces to terminfo database
|
||||
|
||||
@ -74,7 +76,6 @@
|
||||
<STRONG>const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG> <STRONG>const</STRONG> <STRONG>strfnames[];</STRONG>
|
||||
|
||||
<STRONG>int</STRONG> <STRONG>setupterm(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>term</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>filedes</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>errret</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>setterm(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>term</EM><STRONG>);</STRONG>
|
||||
<STRONG>TERMINAL</STRONG> <STRONG>*set_curterm(TERMINAL</STRONG> <STRONG>*</STRONG><EM>nterm</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>del_curterm(TERMINAL</STRONG> <STRONG>*</STRONG><EM>oterm</EM><STRONG>);</STRONG>
|
||||
<STRONG>int</STRONG> <STRONG>restartterm(const</STRONG> <STRONG>char</STRONG> <STRONG>*</STRONG><EM>term</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <EM>filedes</EM><STRONG>,</STRONG> <STRONG>int</STRONG> <STRONG>*</STRONG><EM>errret</EM><STRONG>);</STRONG>
|
||||
@ -103,6 +104,14 @@
|
||||
ities, such as programming function keys. For all other functionality,
|
||||
<STRONG>curses</STRONG> routines are more suitable and their use is recommended.
|
||||
|
||||
None of these functions use (or are aware of) multibyte character
|
||||
strings such as UTF-8:
|
||||
|
||||
<STRONG>o</STRONG> capability names use the POSIX portable character set
|
||||
|
||||
<STRONG>o</STRONG> capability string values have no associated encoding; they are
|
||||
strings of 8-bit characters.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Initialization">Initialization</a></H3><PRE>
|
||||
Initially, <STRONG>setupterm</STRONG> should be called. The high-level curses functions
|
||||
@ -187,14 +196,6 @@
|
||||
|
||||
which uses all the defaults and sends the output to <STRONG>stdout</STRONG>.
|
||||
|
||||
The <STRONG>setterm</STRONG> routine was replaced by <STRONG>setupterm</STRONG>. The call:
|
||||
|
||||
<STRONG>setupterm(</STRONG><EM>term</EM><STRONG>,</STRONG> <STRONG>1,</STRONG> <STRONG>(int</STRONG> <STRONG>*)0)</STRONG>
|
||||
|
||||
provides the same functionality as <STRONG>setterm(</STRONG><EM>term</EM><STRONG>)</STRONG>. The <STRONG>setterm</STRONG> routine
|
||||
is provided for BSD compatibility, and is not recommended for new pro-
|
||||
grams.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-The-Terminal-State">The Terminal State</a></H3><PRE>
|
||||
The <STRONG>setupterm</STRONG> routine stores its information about the terminal in a
|
||||
@ -291,6 +292,10 @@
|
||||
The <STRONG>mvcur</STRONG> routine provides low-level cursor motion. It takes effect
|
||||
immediately (rather than at the next refresh).
|
||||
|
||||
While <STRONG>putp</STRONG> and <STRONG>mvcur</STRONG> are low-level functions which do not use the high-
|
||||
level curses state, they are declared in <STRONG><curses.h></STRONG> because SystemV did
|
||||
this (see <STRONG>HISTORY</STRONG>).
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Terminal-Capability-Functions">Terminal Capability Functions</a></H3><PRE>
|
||||
The <STRONG>tigetflag</STRONG>, <STRONG>tigetnum</STRONG> and <STRONG>tigetstr</STRONG> routines return the value of the
|
||||
@ -325,7 +330,7 @@
|
||||
|
||||
<STRONG>o</STRONG> the short terminfo names ("codes"),
|
||||
|
||||
<STRONG>o</STRONG> the <STRONG>termcap</STRONG> names ("names", and
|
||||
<STRONG>o</STRONG> the <STRONG>termcap</STRONG> names ("names"), and
|
||||
|
||||
<STRONG>o</STRONG> the long terminfo names ("fnames")
|
||||
|
||||
@ -365,16 +370,34 @@
|
||||
value of the output function <EM>putc</EM>.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Compatibility-macros">Compatibility macros</a></H3><PRE>
|
||||
This implementation provides a few macros for compatibility with sys-
|
||||
tems before SVr4 (see <STRONG>HISTORY</STRONG>). Those include <STRONG>crmode</STRONG>, <STRONG>fixterm</STRONG>,
|
||||
<STRONG>gettmode</STRONG>, <STRONG>nocrmode</STRONG>, <STRONG>resetterm</STRONG>, <STRONG>saveterm</STRONG>, and <STRONG>setterm</STRONG>.
|
||||
|
||||
In SVr4, those are found in <STRONG><curses.h></STRONG>, but except for <STRONG>setterm</STRONG>, are
|
||||
likewise macros. The one function, <STRONG>setterm</STRONG>, is mentioned in the manual
|
||||
page. The manual page notes that the <STRONG>setterm</STRONG> routine was replaced by
|
||||
<STRONG>setupterm</STRONG>, stating that the call:
|
||||
|
||||
<STRONG>setupterm(</STRONG><EM>term</EM><STRONG>,</STRONG> <STRONG>1,</STRONG> <STRONG>(int</STRONG> <STRONG>*)0)</STRONG>
|
||||
|
||||
provides the same functionality as <STRONG>setterm(</STRONG><EM>term</EM><STRONG>)</STRONG>, and is not recommend-
|
||||
ed for new programs. This implementation provides each of those sym-
|
||||
bols as macros for BSD compatibility,
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-HISTORY">HISTORY</a></H2><PRE>
|
||||
SVr2 introduced the terminfo feature. Its programming manual mentioned
|
||||
these low-level functions:
|
||||
|
||||
<STRONG>Function</STRONG> <STRONG>Description</STRONG>
|
||||
------------------------------------------------------------
|
||||
|
||||
fixterm restore tty to "in curses" state
|
||||
gettmode establish current tty modes
|
||||
mvcur low level cursor motion
|
||||
putp utility function that uses <STRONG>tputs</STRONG> to send char-
|
||||
putp utility function that uses <STRONG>tputs</STRONG> to send char-
|
||||
acters via <STRONG>putchar</STRONG>.
|
||||
resetterm set tty modes to "out of curses" state
|
||||
resetty reset tty flags to stored value
|
||||
@ -385,10 +408,10 @@
|
||||
tparm instantiate a string expression with parameters
|
||||
tputs apply padding information to a string
|
||||
vidattr like <STRONG>vidputs</STRONG>, but outputs through <STRONG>putchar</STRONG>
|
||||
vidputs output a string to put terminal in a specified
|
||||
vidputs output a string to put terminal in a specified
|
||||
video attribute mode
|
||||
|
||||
The programming manual also mentioned functions provided for termcap
|
||||
The programming manual also mentioned functions provided for termcap
|
||||
compatibility (commenting that they "may go away at a later date"):
|
||||
|
||||
<STRONG>Function</STRONG> <STRONG>Description</STRONG>
|
||||
@ -401,10 +424,10 @@
|
||||
tputs apply padding to capability, calling
|
||||
a function to put characters
|
||||
|
||||
Early terminfo programs obtained capability values from the <STRONG>TERMINAL</STRONG>
|
||||
Early terminfo programs obtained capability values from the <STRONG>TERMINAL</STRONG>
|
||||
structure initialized by <STRONG>setupterm</STRONG>.
|
||||
|
||||
SVr3 extended terminfo by adding functions to retrieve capability val-
|
||||
SVr3 extended terminfo by adding functions to retrieve capability val-
|
||||
ues (like the termcap interface), and reusing tgoto and tputs:
|
||||
|
||||
<STRONG>Function</STRONG> <STRONG>Description</STRONG>
|
||||
@ -413,7 +436,7 @@
|
||||
tigetnum get numeric entry for given <EM>id</EM>
|
||||
tigetstr get string entry for given <EM>id</EM>
|
||||
|
||||
SVr3 also replaced several of the SVr2 terminfo functions which had no
|
||||
SVr3 also replaced several of the SVr2 terminfo functions which had no
|
||||
counterpart in the termcap interface, documenting them as obsolete:
|
||||
|
||||
<STRONG>Function</STRONG> <STRONG>Replaced</STRONG> <STRONG>by</STRONG>
|
||||
@ -426,13 +449,13 @@
|
||||
saveterm def_prog_mode
|
||||
setterm setupterm
|
||||
|
||||
SVr3 kept the <STRONG>mvcur</STRONG>, <STRONG>vidattr</STRONG> and <STRONG>vidputs</STRONG> functions, along with <STRONG>putp</STRONG>,
|
||||
<STRONG>tparm</STRONG> and <STRONG>tputs</STRONG>. The latter were needed to support padding, and han-
|
||||
dling functions such as <STRONG>vidattr</STRONG> (which used more than the two parame-
|
||||
SVr3 kept the <STRONG>mvcur</STRONG>, <STRONG>vidattr</STRONG> and <STRONG>vidputs</STRONG> functions, along with <STRONG>putp</STRONG>,
|
||||
<STRONG>tparm</STRONG> and <STRONG>tputs</STRONG>. The latter were needed to support padding, and han-
|
||||
dling functions such as <STRONG>vidattr</STRONG> (which used more than the two parame-
|
||||
ters supported by <STRONG>tgoto</STRONG>).
|
||||
|
||||
SVr3 introduced the functions for switching between terminal descrip-
|
||||
tions, e.g., <STRONG>set_curterm</STRONG>. The various global variables such as <STRONG>bool-</STRONG>
|
||||
SVr3 introduced the functions for switching between terminal descrip-
|
||||
tions, e.g., <STRONG>set_curterm</STRONG>. The various global variables such as <STRONG>bool-</STRONG>
|
||||
<STRONG>names</STRONG> were mentioned in the programming manual at this point.
|
||||
|
||||
SVr4 added the <STRONG>vid_attr</STRONG> and <STRONG>vid_puts</STRONG> functions.
|
||||
@ -447,15 +470,15 @@
|
||||
</PRE><H3><a name="h3-Legacy-functions">Legacy functions</a></H3><PRE>
|
||||
X/Open notes that <STRONG>vidattr</STRONG> and <STRONG>vidputs</STRONG> may be macros.
|
||||
|
||||
The function <STRONG>setterm</STRONG> is not described by X/Open and must be considered
|
||||
The function <STRONG>setterm</STRONG> is not described by X/Open and must be considered
|
||||
non-portable. All other functions are as described by X/Open.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Legacy-data">Legacy data</a></H3><PRE>
|
||||
<STRONG>setupterm</STRONG> copies the terminal name to the array <STRONG>ttytype</STRONG>. This is not
|
||||
<STRONG>setupterm</STRONG> copies the terminal name to the array <STRONG>ttytype</STRONG>. This is not
|
||||
part of X/Open Curses, but is assumed by some applications.
|
||||
|
||||
Other implementions may not declare the capability name arrays. Some
|
||||
Other implementions may not declare the capability name arrays. Some
|
||||
provide them without declaring them. X/Open does not specify them.
|
||||
|
||||
Extended terminal capability names, e.g., as defined by <STRONG>tic</STRONG> <STRONG>-x</STRONG>, are not
|
||||
@ -463,14 +486,14 @@
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Output-buffering">Output buffering</a></H3><PRE>
|
||||
Older versions of <STRONG>ncurses</STRONG> assumed that the file descriptor passed to
|
||||
Older versions of <STRONG>ncurses</STRONG> assumed that the file descriptor passed to
|
||||
<STRONG>setupterm</STRONG> from <STRONG>initscr</STRONG> or <STRONG>newterm</STRONG> uses buffered I/O, and would write to
|
||||
the corresponding stream. In addition to the limitation that the ter-
|
||||
minal was left in block-buffered mode on exit (like System V curses),
|
||||
it was problematic because <STRONG>ncurses</STRONG> did not allow a reliable way to
|
||||
the corresponding stream. In addition to the limitation that the ter-
|
||||
minal was left in block-buffered mode on exit (like System V curses),
|
||||
it was problematic because <STRONG>ncurses</STRONG> did not allow a reliable way to
|
||||
cleanup on receiving SIGTSTP.
|
||||
|
||||
The current version (ncurses6) uses output buffers managed directly by
|
||||
The current version (ncurses6) uses output buffers managed directly by
|
||||
<STRONG>ncurses</STRONG>. Some of the low-level functions described in this manual page
|
||||
write to the standard output. They are not signal-safe. The high-lev-
|
||||
el functions in <STRONG>ncurses</STRONG> use alternate versions of these functions using
|
||||
@ -479,69 +502,69 @@
|
||||
|
||||
</PRE><H3><a name="h3-Function-prototypes">Function prototypes</a></H3><PRE>
|
||||
The X/Open Curses prototypes are based on the SVr4 curses header decla-
|
||||
rations, which were defined at the same time the C language was first
|
||||
rations, which were defined at the same time the C language was first
|
||||
standardized in the late 1980s.
|
||||
|
||||
<STRONG>o</STRONG> X/Open Curses uses <STRONG>const</STRONG> less effectively than a later design
|
||||
might, in some cases applying it needlessly to values are already
|
||||
constant, and in most cases overlooking parameters which normally
|
||||
would use <STRONG>const</STRONG>. Using constant parameters for functions which do
|
||||
<STRONG>o</STRONG> X/Open Curses uses <STRONG>const</STRONG> less effectively than a later design
|
||||
might, in some cases applying it needlessly to values are already
|
||||
constant, and in most cases overlooking parameters which normally
|
||||
would use <STRONG>const</STRONG>. Using constant parameters for functions which do
|
||||
not use <STRONG>const</STRONG> may prevent the program from compiling. On the other
|
||||
hand, <EM>writable</EM> <EM>strings</EM> are an obsolescent feature.
|
||||
|
||||
As an extension, this implementation can be configured to change
|
||||
the function prototypes to use the <STRONG>const</STRONG> keyword. The ncurses ABI
|
||||
As an extension, this implementation can be configured to change
|
||||
the function prototypes to use the <STRONG>const</STRONG> keyword. The ncurses ABI
|
||||
6 enables this feature by default.
|
||||
|
||||
<STRONG>o</STRONG> X/Open Curses prototypes <STRONG>tparm</STRONG> with a fixed number of parameters,
|
||||
<STRONG>o</STRONG> X/Open Curses prototypes <STRONG>tparm</STRONG> with a fixed number of parameters,
|
||||
rather than a variable argument list.
|
||||
|
||||
This implementation uses a variable argument list, but can be con-
|
||||
figured to use the fixed-parameter list. Portable applications
|
||||
should provide 9 parameters after the format; zeroes are fine for
|
||||
This implementation uses a variable argument list, but can be con-
|
||||
figured to use the fixed-parameter list. Portable applications
|
||||
should provide 9 parameters after the format; zeroes are fine for
|
||||
this purpose.
|
||||
|
||||
In response to review comments by Thomas E. Dickey, X/Open Curses
|
||||
In response to review comments by Thomas E. Dickey, X/Open Curses
|
||||
Issue 7 proposed the <STRONG>tiparm</STRONG> function in mid-2009.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Special-TERM-treatment">Special TERM treatment</a></H3><PRE>
|
||||
If configured to use the terminal-driver, e.g., for the MinGW port,
|
||||
|
||||
<STRONG>o</STRONG> <STRONG>setupterm</STRONG> interprets a missing/empty TERM variable as the special
|
||||
<STRONG>o</STRONG> <STRONG>setupterm</STRONG> interprets a missing/empty TERM variable as the special
|
||||
value "unknown".
|
||||
|
||||
<STRONG>o</STRONG> <STRONG>setupterm</STRONG> allows explicit use of the the windows console driver by
|
||||
checking if $TERM is set to "#win32con" or an abbreviation of that
|
||||
<STRONG>o</STRONG> <STRONG>setupterm</STRONG> allows explicit use of the the windows console driver by
|
||||
checking if $TERM is set to "#win32con" or an abbreviation of that
|
||||
string.
|
||||
|
||||
|
||||
</PRE><H3><a name="h3-Other-portability-issues">Other portability issues</a></H3><PRE>
|
||||
In System V Release 4, <STRONG>set_curterm</STRONG> has an <STRONG>int</STRONG> return type and returns
|
||||
In System V Release 4, <STRONG>set_curterm</STRONG> has an <STRONG>int</STRONG> return type and returns
|
||||
<STRONG>OK</STRONG> or <STRONG>ERR</STRONG>. We have chosen to implement the X/Open Curses semantics.
|
||||
|
||||
In System V Release 4, the third argument of <STRONG>tputs</STRONG> has the type <STRONG>int</STRONG>
|
||||
In System V Release 4, the third argument of <STRONG>tputs</STRONG> has the type <STRONG>int</STRONG>
|
||||
<STRONG>(*putc)(char)</STRONG>.
|
||||
|
||||
At least one implementation of X/Open Curses (Solaris) returns a value
|
||||
other than <STRONG>OK</STRONG>/<STRONG>ERR</STRONG> from <STRONG>tputs</STRONG>. That returns the length of the string,
|
||||
At least one implementation of X/Open Curses (Solaris) returns a value
|
||||
other than <STRONG>OK</STRONG>/<STRONG>ERR</STRONG> from <STRONG>tputs</STRONG>. That returns the length of the string,
|
||||
and does no error-checking.
|
||||
|
||||
X/Open notes that after calling <STRONG>mvcur</STRONG>, the curses state may not match
|
||||
X/Open notes that after calling <STRONG>mvcur</STRONG>, the curses state may not match
|
||||
the actual terminal state, and that an application should touch and re-
|
||||
fresh the window before resuming normal curses calls. Both <STRONG>ncurses</STRONG> and
|
||||
System V Release 4 curses implement <STRONG>mvcur</STRONG> using the SCREEN data allo-
|
||||
cated in either <STRONG>initscr</STRONG> or <STRONG>newterm</STRONG>. So though it is documented as a
|
||||
terminfo function, <STRONG>mvcur</STRONG> is really a curses function which is not well
|
||||
System V Release 4 curses implement <STRONG>mvcur</STRONG> using the SCREEN data allo-
|
||||
cated in either <STRONG>initscr</STRONG> or <STRONG>newterm</STRONG>. So though it is documented as a
|
||||
terminfo function, <STRONG>mvcur</STRONG> is really a curses function which is not well
|
||||
specified.
|
||||
|
||||
X/Open states that the old location must be given for <STRONG>mvcur</STRONG>. This im-
|
||||
plementation allows the caller to use -1's for the old ordinates. In
|
||||
X/Open states that the old location must be given for <STRONG>mvcur</STRONG>. This im-
|
||||
plementation allows the caller to use -1's for the old ordinates. In
|
||||
that case, the old location is unknown.
|
||||
|
||||
|
||||
</PRE><H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE>
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_initscr.3x.html">curs_initscr(3x)</A></STRONG>, <STRONG><A HREF="curs_kernel.3x.html">curs_kernel(3x)</A></STRONG>, <STRONG><A HREF="curs_termcap.3x.html">curs_termcap(3x)</A></STRONG>,
|
||||
<STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="curs_initscr.3x.html">curs_initscr(3x)</A></STRONG>, <STRONG><A HREF="curs_kernel.3x.html">curs_kernel(3x)</A></STRONG>, <STRONG><A HREF="curs_termcap.3x.html">curs_termcap(3x)</A></STRONG>,
|
||||
<STRONG><A HREF="curs_variables.3x.html">curs_variables(3x)</A></STRONG>, <STRONG><A HREF="term_variables.3x.html">term_variables(3x)</A></STRONG>, <STRONG>putc(3)</STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>
|
||||
|
||||
|
||||
@ -562,7 +585,11 @@
|
||||
<li><a href="#h3-Terminal-Capability-Names">Terminal Capability Names</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a></li>
|
||||
<li><a href="#h2-RETURN-VALUE">RETURN VALUE</a>
|
||||
<ul>
|
||||
<li><a href="#h3-Compatibility-macros">Compatibility macros</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h2-HISTORY">HISTORY</a></li>
|
||||
<li><a href="#h2-PORTABILITY">PORTABILITY</a>
|
||||
<ul>
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user