From: Jan Lentfer Date: Thu, 17 Dec 2009 13:10:54 +0000 (+0100) Subject: vendor/NCURSES: Remove version tag. X-Git-Tag: v2.7.1~288^2 X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/fdd4e1e09e069e93fafdd13458a9c511bca7e833 vendor/NCURSES: Remove version tag. --- diff --git a/contrib/ncurses-5.4/Ada95/Makefile.in b/contrib/ncurses-5.4/Ada95/Makefile.in deleted file mode 100644 index b1743cfa6e..0000000000 --- a/contrib/ncurses-5.4/Ada95/Makefile.in +++ /dev/null @@ -1,67 +0,0 @@ -############################################################################## -# Copyright (c) 1998 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Juergen Pfeifer, 1996 -# -# Version Control -# $Revision: 1.15 $ -# -SHELL = /bin/sh -THIS = Makefile - -SUBDIRS = @ADA_SUBDIRS@ - -CF_MFLAGS = @cf_cv_makeflags@ -@SET_MAKE@ - -all \ -libs \ -sources \ -install \ -install.libs \ -uninstall \ -uninstall.libs :: - for d in $(SUBDIRS); do \ - (cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\ - done - -clean \ -mostlyclean :: - for d in $(SUBDIRS); do \ - (cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\ - done - -distclean \ -realclean :: - for d in $(SUBDIRS); do \ - (cd $$d ; $(MAKE) $(CF_MFLAGS) $@) ;\ - done - rm -f Makefile - -install.data : - @ diff --git a/contrib/ncurses-5.4/Ada95/README b/contrib/ncurses-5.4/Ada95/README deleted file mode 100644 index be8425969d..0000000000 --- a/contrib/ncurses-5.4/Ada95/README +++ /dev/null @@ -1,33 +0,0 @@ -------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell copies -- --- of the Software, and to permit persons to whom the Software is furnished -- --- to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -- --- NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -- --- USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- -------------------------------------------------------------------------------- - --- Author: Juergen Pfeifer, 1996 - -The documentation is provided in HTML format in the ./html -subdirectory. The main document is named index.html - diff --git a/contrib/ncurses-5.4/Ada95/TODO b/contrib/ncurses-5.4/Ada95/TODO deleted file mode 100644 index 12fef7b717..0000000000 --- a/contrib/ncurses-5.4/Ada95/TODO +++ /dev/null @@ -1,27 +0,0 @@ --- $Id: TODO,v 1.4 1999/10/20 09:18:58 tom Exp $ - --- Intensive testing - Perhaps the delivery of the Beta will help a bit. - --- Documentation - Like most WEB pages: under continuous construction - --- Style cleanup - --- Alternate functions for procedures with out params - Comfort purpose - --- Sample program - Under continuous construction (and it's not a WEB page!!!) - --- Make the binding objects a shared library - They are rather large, so it would make sense, otherwise Ada95 - would look too large, although the generated code is as compact - as C or C++. I'll wait a bit until the GNAT people provide some - better support to construct shared libraries. - --- Think about more inlining - --- Check for memory leaks. - Oh I would like it so much if the GNAT guys would put an optional - GC into their system. diff --git a/contrib/ncurses-5.4/Ada95/gen/Makefile.in b/contrib/ncurses-5.4/Ada95/gen/Makefile.in deleted file mode 100644 index aea7fdd723..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/Makefile.in +++ /dev/null @@ -1,438 +0,0 @@ -############################################################################## -# Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Juergen Pfeifer, 1996 -# -# Version Control -# $Revision: 1.44 $ -# -.SUFFIXES: - -SHELL = /bin/sh -THIS = Makefile - -x = @PROG_EXT@ - -top_srcdir = @top_srcdir@ -DESTDIR = @DESTDIR@ -srcdir = @srcdir@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ -ADA_INCLUDE = $(DESTDIR)@ADA_INCLUDE@ -ADA_OBJECTS = $(DESTDIR)@ADA_OBJECTS@ - -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ - -AWK = @AWK@ -LN_S = @LN_S@ - -CC = @CC@ -HOST_CC = @BUILD_CC@ -CFLAGS = @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_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@ - -CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@) - -LINK = $(HOST_CC) -LD_FLAGS = @LD_MODEL@ $(LOCAL_LIBS) @LDFLAGS@ @LIBS@ @LOCAL_LDFLAGS2@ $(LDFLAGS) - -RANLIB = @RANLIB@ - -LIB_CURSES = -L../../lib -lncurses@LIB_SUFFIX@ - -M4 = m4 -M4FLAGS = - -GENERATE = ./gen$x '@DFT_ARG_SUFFIX@' -DEL_ADAMODE = sed -e '/^\-\-\ \ \-\*\-\ ada\ \-\*\-.*/d' - -GNATHTML = `type -p gnathtml || type -p gnathtml.pl` -GNATHP = www.gnat.com - -################################################################################ -ALIB = @cf_ada_package@ -ABASE = $(ALIB)-curses - -ADA_SRCDIR = ../src - -GEN_FILES0 = Base_Defs - -GEN_FILES1 = Key_Definitions \ - Old_Keys \ - Character_Attribute_Set_Rep \ - AC_Rep \ - Color_Defs \ - ACS_Map \ - Linker_Options \ - Base_Defs \ - Window_Offsets \ - Version_Info \ - Trace_Defs - -GEN_FILES2 = Menu_Opt_Rep \ - Menu_Base_Defs \ - Menu_Linker_Options \ - Item_Rep - -GEN_FILES3 = Form_Opt_Rep \ - Form_Base_Defs \ - Form_Linker_Options \ - Field_Rep - -GEN_FILES4 = Mouse_Base_Defs \ - Mouse_Event_Rep \ - Mouse_Events \ - Panel_Linker_Options - -GEN_FILES5 = Chtype_Def \ - Eti_Defs - -GEN_TARGETS = $(ADA_SRCDIR)/$(ABASE).ads \ - $(ADA_SRCDIR)/$(ABASE)-aux.ads \ - $(ADA_SRCDIR)/$(ABASE)-trace.ads \ - $(ADA_SRCDIR)/$(ABASE)-menus.ads \ - $(ADA_SRCDIR)/$(ABASE)-forms.ads \ - $(ADA_SRCDIR)/$(ABASE)-mouse.ads \ - $(ADA_SRCDIR)/$(ABASE)-panels.ads \ - $(ADA_SRCDIR)/$(ABASE)-menus-menu_user_data.ads \ - $(ADA_SRCDIR)/$(ABASE)-menus-item_user_data.ads \ - $(ADA_SRCDIR)/$(ABASE)-forms-form_user_data.ads \ - $(ADA_SRCDIR)/$(ABASE)-forms-field_types.ads \ - $(ADA_SRCDIR)/$(ABASE)-forms-field_user_data.ads \ - $(ADA_SRCDIR)/$(ABASE)-panels-user_data.ads - -GEN_SRC = $(srcdir)/$(ABASE).ads.m4 \ - $(srcdir)/$(ABASE)-aux.ads.m4 \ - $(srcdir)/$(ABASE)-trace.ads.m4 \ - $(srcdir)/$(ABASE)-menus.ads.m4 \ - $(srcdir)/$(ABASE)-forms.ads.m4 \ - $(srcdir)/$(ABASE)-mouse.ads.m4 \ - $(srcdir)/$(ABASE)-panels.ads.m4 \ - $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4 \ - $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4 \ - $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4 \ - $(srcdir)/$(ABASE)-forms-field_types.ads.m4 \ - $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4 \ - $(srcdir)/$(ABASE)-panels-user_data.ads.m4 - - -all \ -libs : $(GEN_TARGETS) - @ - -sources: - -$(ADA_INCLUDE) \ -$(ADA_OBJECTS) : - $(top_srcdir)/mkinstalldirs $@ - -install \ -install.libs :: $(ADA_INCLUDE) - @echo installing package $(ALIB) in $(ADA_INCLUDE) - @$(top_srcdir)/tar-copy.sh '$(ALIB)[-.]*.ad?' $(ADA_SRCDIR) $(ADA_INCLUDE) - @test $(srcdir) != ./ && $(top_srcdir)/tar-copy.sh '$(ALIB)[-.]*.ad?' $(srcdir)/../src $(ADA_INCLUDE) - -install \ -install.libs :: $(ADA_OBJECTS) - @echo installing package $(ALIB) in $(ADA_OBJECTS) - @-chmod a-wx $(ADA_SRCDIR)/*.ali - @$(top_srcdir)/tar-copy.sh '$(ALIB)[-.]*.ali' $(ADA_SRCDIR) $(ADA_OBJECTS) - @-chmod u+x $(ADA_SRCDIR)/*.ali - -uninstall \ -uninstall.libs :: - @echo removing package $(ALIB) from $(ADA_INCLUDE) - -@cd $(ADA_INCLUDE) && rm -f $(ALIB)[-.]* - -uninstall \ -uninstall.libs :: - @echo removing package $(ALIB) from $(ADA_OBJECTS) - -@cd $(ADA_OBJECTS) && rm -f $(ALIB)[-.]* - -gen$x: gen.o - @ECHO_LINK@ $(LINK) $(CFLAGS_NORMAL) gen.o $(LD_FLAGS) -o $@ $(LIB_CURSES) - -gen.o: $(srcdir)/gen.c - $(HOST_CC) $(CFLAGS_NORMAL) -c -o $@ $(srcdir)/gen.c - -Character_Attribute_Set_Rep: gen$x - $(GENERATE) B A >$@ - -Base_Defs: gen$x - $(GENERATE) B B >$@ - -Color_Defs: gen$x - $(GENERATE) B C >$@ - -Key_Definitions: gen$x - $(GENERATE) B K >$@ - -Old_Keys: gen$x - $(GENERATE) B O >$@ - -ACS_Map: gen$x - $(GENERATE) B M >$@ - -AC_Rep: gen$x - $(GENERATE) B R >$@ - -Linker_Options: gen$x - $(GENERATE) B L >$@ - -Version_Info: gen$x - $(GENERATE) B V >$@ - -Window_Offsets: gen$x - $(GENERATE) B D >$@ - -Trace_Defs: gen$x - $(GENERATE) B T >$@ - -Menu_Opt_Rep: gen$x - $(GENERATE) M R >$@ - -Menu_Base_Defs: gen$x - $(GENERATE) M B >$@ - -Menu_Linker_Options: gen$x - $(GENERATE) M L >$@ - -Item_Rep: gen$x - $(GENERATE) M I >$@ - -Form_Opt_Rep: gen$x - $(GENERATE) F R >$@ - -Form_Base_Defs: gen$x - $(GENERATE) F B >$@ - -Form_Linker_Options: gen$x - $(GENERATE) F L >$@ - -Field_Rep: gen$x - $(GENERATE) F I >$@ - -Mouse_Base_Defs: gen$x - $(GENERATE) P B >$@ - -Mouse_Event_Rep: gen$x - $(GENERATE) P M >$@ - -Mouse_Events: gen$x - $(GENERATE) B E >$@ - -Panel_Linker_Options: gen$x - $(GENERATE) P L >$@ - -Chtype_Def: gen$x - $(GENERATE) E C >$@ - -Eti_Defs: gen$x - $(GENERATE) E E >$@ - -$(ADA_SRCDIR)/$(ABASE).ads: $(srcdir)/$(ABASE).ads.m4 \ - $(GEN_FILES1) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE).ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-aux.ads: $(srcdir)/$(ABASE)-aux.ads.m4 \ - $(GEN_FILES5) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-aux.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-trace.ads: $(srcdir)/$(ABASE)-trace.ads.m4 \ - $(GEN_FILES5) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-trace.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-menus.ads: $(srcdir)/$(ABASE)-menus.ads.m4 \ - $(GEN_FILES2) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-menus.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-forms.ads: $(srcdir)/$(ABASE)-forms.ads.m4 \ - $(GEN_FILES3) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-forms.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-mouse.ads: $(srcdir)/$(ABASE)-mouse.ads.m4 \ - $(GEN_FILES4) $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-mouse.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-panels.ads: $(srcdir)/$(ABASE)-panels.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-panels.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-menus-menu_user_data.ads: \ - $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-menus-item_user_data.ads: \ - $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-forms-form_user_data.ads: \ - $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-forms-field_types.ads: \ - $(srcdir)/$(ABASE)-forms-field_types.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-forms-field_types.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-forms-field_user_data.ads: \ - $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -$(ADA_SRCDIR)/$(ABASE)-panels-user_data.ads: \ - $(srcdir)/$(ABASE)-panels-user_data.ads.m4 \ - $(srcdir)/normal.m4 - $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \ - $(srcdir)/$(ABASE)-panels-user_data.ads.m4 |\ - $(DEL_ADAMODE) >$@ - -install.progs :: - -tags: - ctags *.[ch] - -TAGS: - etags *.[ch] - -mostlyclean :: - -rm -f a.out core gen$x *.o - -rm -f $(GEN_FILES1) - -rm -f $(GEN_FILES2) - -rm -f $(GEN_FILES3) - -rm -f $(GEN_FILES4) - -rm -f $(GEN_FILES5) - -clean :: mostlyclean - -rm -f $(GEN_TARGETS) instab.tmp *.ad[bs] *.html *.ali *.tmp - -distclean :: clean - rm -f Makefile - -realclean :: distclean - -HTML_DIR = ../../doc/html/ada - -instab.tmp : table.m4 $(GEN_SRC) - @rm -f $@ - @for f in $(GEN_SRC) ; do \ - $(M4) $(M4FLAGS) -DM4MACRO=table.m4 $$f | $(DEL_ADAMODE) >> $@ ;\ - done; - -$(HTML_DIR)/table.html : instab.tmp - @-touch $@ - @-chmod +w $@ - @echo ' $@ - @echo 'PUBLIC "-//IETF//DTD HTML 3.0//EN">' >> $@ - @echo '' >> $@ - @echo '' >> $@ - @echo 'Correspondence between ncurses C and Ada functions' >>$@ - @echo '' >> $@ - @echo '' >> $@ - @echo '

Correspondence between ncurses C and Ada functions

' >>$@ - @echo '

Sorted by C function name

' >>$@ - @echo '' >>$@ - @echo '' >>$@ - @echo '' >>$@ - @sort < instab.tmp >> $@ - @echo '
C nameAda nameman page
' >>$@ - @rm -f instab.tmp - -adahtml: - @rm -rf $(HTML_DIR)/ - @mkdir -p $(HTML_DIR) - cp -p ../src/*.ad[sb] . && chmod +w *.ad[sb] - ln -sf ../src/*.ali . - for f in $(GEN_SRC); do \ - g=`basename $$f .ads.m4` ;\ - $(M4) $(M4FLAGS) -DM4MACRO=html.m4 $$f | $(DEL_ADAMODE) > $$g.ads ;\ - done - @-rm -f $(HTML_DIR)/$(ALIB)*.htm* - $(GNATHTML) -d -f $(ALIB)*.ads - for f in html/$(ALIB)*.htm*; do \ - a=`basename $$f` ; \ - sed -e 's/You may also.*body.*//' <$$f |\ - sed -e 's%GNAT%GNAT%g' |\ - sed -e 's%<A HREF%%g' |\ - sed -e 's/3X/3x/g' |\ - sed -e 's/$$\([ABCDEFGHIJKLMNOPQRSTUVWXZabcdefghijklmnopqrstuvwxz0123456789_]*:.*\)\$$/@\1@/' |\ - sed -e 's%</A>%%g' > $$a.tmp ;\ - mv $$a.tmp $$f ;\ - done - @rm -f *.ad[sb] *.ali *.tmp - @for f in funcs.htm main.htm ; do \ - sed -e "\%\[ \]%d" < html/$$f > $$f ;\ - mv $$f html/$$f ;\ - done - @rm -f "html/funcs/ .htm" - @cp -pdrf html/* $(HTML_DIR)/ - @rm -rf html - -html : adahtml $(HTML_DIR)/table.html - @ - -############################################################################### -# The remainder of this file is automatically generated during configuration -############################################################################### diff --git a/contrib/ncurses-5.4/Ada95/gen/gen.c b/contrib/ncurses-5.4/Ada95/gen/gen.c deleted file mode 100644 index 7a5bbedf63..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/gen.c +++ /dev/null @@ -1,1436 +0,0 @@ -/**************************************************************************** - * Copyright (c) 1998,2000 Free Software Foundation, Inc. * - * * - * Permission is hereby granted, free of charge, to any person obtaining a * - * copy of this software and associated documentation files (the * - * "Software"), to deal in the Software without restriction, including * - * without limitation the rights to use, copy, modify, merge, publish, * - * distribute, distribute with modifications, sublicense, and/or sell * - * copies of the Software, and to permit persons to whom the Software is * - * furnished to do so, subject to the following conditions: * - * * - * The above copyright notice and this permission notice shall be included * - * in all copies or substantial portions of the Software. * - * * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * - * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * - * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * - * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * - * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * - * THE USE OR OTHER DEALINGS IN THE SOFTWARE. * - * * - * Except as contained in this notice, the name(s) of the above copyright * - * holders shall not be used in advertising or otherwise to promote the * - * sale, use or other dealings in this Software without prior written * - * authorization. * - ****************************************************************************/ - -/**************************************************************************** - * Author: Juergen Pfeifer, 1996 * - ****************************************************************************/ - -/* - Version Control - $Revision: 1.36 $ - --------------------------------------------------------------------------*/ -/* - This program generates various record structures and constants from the - ncurses header file for the Ada95 packages. Essentially it produces - Ada95 source on stdout, which is then merged using m4 into a template - to produce the real source. - */ - -#include -#include -#include -#include -#include - -#include -#include - -#define RES_NAME "Reserved" - -static const char *model = ""; -static int little_endian = 0; - -typedef struct { - const char *name; - unsigned long attr; -} name_attribute_pair; - -static int find_pos (char *s, unsigned len, int *low, int *high) -{ - unsigned int i,j; - int l = 0; - - *high = -1; - *low = 8*len; - - for(i=0; i < len; i++,s++) - { - if (*s) - { - for(j=0;j<8*sizeof(char);j++) - { - if ((( little_endian && ((*s)&0x01)) || - (!little_endian && ((*s)&0x80))) ) - { - if (l > *high) - *high = l; - if (l < *low) - *low = l; - } - l++; - if (little_endian) - *s >>= 1; - else - *s <<= 1; - } - } - else - l += 8; - } - return (*high >= 0 && (*low <= *high)) ? *low : -1; -} - -/* - * This helper routine generates a representation clause for a - * record type defined in the binding. - * We are only dealing with record types which are of 32 or 16 - * bit size, i.e. they fit into an (u)int or a (u)short. - */ -static void -gen_reps -(const name_attribute_pair *nap, /* array of name_attribute_pair records */ - const char *name, /* name of the represented record type */ - int len, /* size of the record in bytes */ - int bias) -{ - int i,n,l,cnt = 0,low,high; - int width = strlen(RES_NAME) + 3; - unsigned long a; - unsigned long mask = 0; - - assert (nap!=NULL); - - for (i=0; nap[i].name != (char *)0; i++) - { - cnt++; - l = strlen(nap[i].name); - if (l>width) - width = l; - } - assert (width > 0); - - printf(" type %s is\n",name); - printf(" record\n"); - for (i=0; nap[i].name != (char *)0; i++) - { - printf(" %-*s : Boolean;\n",width,nap[i].name); - } - printf(" end record;\n"); - printf(" pragma Pack (%s);\n",name); - printf(" pragma Convention (C, %s);\n\n",name); - - printf(" for %s use\n",name); - printf(" record\n"); - - for (i=0; nap[i].name != (char *)0; i++) - { - a = nap[i].attr; - mask |= a; - l = find_pos( (char *)&a,sizeof(a),&low,&high ); - if (l>=0) - printf(" %-*s at 0 range %2d .. %2d;\n",width,nap[i].name, - low-bias,high-bias); - } - i = 1; n = cnt; - printf(" end record;\n"); - printf(" for %s'Size use %d;\n", name, 8*len); - printf(" -- Please note: this rep. clause is generated and may be\n"); - printf(" -- different on your system."); -} - - -static void chtype_rep (const char *name, attr_t mask) -{ - attr_t x = -1; - attr_t t = x & mask; - int low, high; - int l = find_pos ((char *)&t, sizeof(t), &low, &high); - if (l>=0) - printf(" %-5s at 0 range %2d .. %2d;\n",name,low,high); -} - -static void gen_chtype_rep(const char *name) -{ - printf(" for %s use\n record\n",name); - chtype_rep("Ch",A_CHARTEXT); - chtype_rep("Color",A_COLOR); - chtype_rep("Attr",(A_ATTRIBUTES&~A_COLOR)); - printf(" end record;\n for %s'Size use %ld;\n", name, (long)(8*sizeof(chtype))); - printf(" -- Please note: this rep. clause is generated and may be\n"); - printf(" -- different on your system.\n"); -} - - -static void mrep_rep (const char *name, void *rec) -{ - int low, high; - int l = find_pos((char *)rec, sizeof(MEVENT), &low, &high); - if (l>=0) - printf(" %-7s at 0 range %3d .. %3d;\n",name,low,high); -} - - -static void gen_mrep_rep(const char *name) -{ - MEVENT x; - - printf(" for %s use\n record\n",name); - - memset(&x,0,sizeof(x)); - x.id = -1; - mrep_rep("Id",&x); - - memset(&x,0,sizeof(x)); - x.x = -1; - mrep_rep("X",&x); - - memset(&x,0,sizeof(x)); - x.y = -1; - mrep_rep("Y",&x); - - memset(&x,0,sizeof(x)); - x.z = -1; - mrep_rep("Z",&x); - - memset(&x,0,sizeof(x)); - x.bstate = -1; - mrep_rep("Bstate",&x); - - printf(" end record;\n"); - printf(" -- Please note: this rep. clause is generated and may be\n"); - printf(" -- different on your system.\n"); -} - -static void gen_attr_set( const char *name ) -{ - /* All of the A_xxx symbols are defined in ncurses, but not all are nonzero - * if "configure --enable-widec" is specified. - */ - static const name_attribute_pair nap[] = { -#if A_STANDOUT - {"Stand_Out", A_STANDOUT}, -#endif -#if A_UNDERLINE - {"Under_Line", A_UNDERLINE}, -#endif -#if A_REVERSE - {"Reverse_Video", A_REVERSE}, -#endif -#if A_BLINK - {"Blink", A_BLINK}, -#endif -#if A_DIM - {"Dim_Character", A_DIM}, -#endif -#if A_BOLD - {"Bold_Character", A_BOLD}, -#endif -#if A_ALTCHARSET - {"Alternate_Character_Set", A_ALTCHARSET}, -#endif -#if A_INVIS - {"Invisible_Character", A_INVIS}, -#endif -#if A_PROTECT - {"Protected_Character", A_PROTECT}, -#endif -#if A_HORIZONTAL - {"Horizontal", A_HORIZONTAL}, -#endif -#if A_LEFT - {"Left", A_LEFT}, -#endif -#if A_LOW - {"Low", A_LOW}, -#endif -#if A_RIGHT - {"Right", A_RIGHT}, -#endif -#if A_TOP - {"Top", A_TOP}, -#endif -#if A_VERTICAL - {"Vertical", A_VERTICAL}, -#endif - {(char *)0, 0} - }; - chtype attr = A_ATTRIBUTES & ~A_COLOR; - int start=-1, len=0, i, set; - for(i=0;i<(int)(8*sizeof(chtype));i++) { - set = attr&1; - if (set) { - if (start<0) - start = i; - if (start>=0) { - len++; - } - } - attr = attr >> 1; - } - gen_reps (nap, name, (len+7)/8, little_endian?start:0); -} - -static void gen_trace(const char *name) -{ - static const name_attribute_pair nap[] = { - {"Times", TRACE_TIMES}, - {"Tputs", TRACE_TPUTS}, - {"Update", TRACE_UPDATE}, - {"Cursor_Move", TRACE_MOVE}, - {"Character_Output", TRACE_CHARPUT}, - {"Calls", TRACE_CALLS}, - {"Virtual_Puts", TRACE_VIRTPUT}, - {"Input_Events", TRACE_IEVENT}, - {"TTY_State", TRACE_BITS}, - {"Internal_Calls", TRACE_ICALLS}, - {"Character_Calls", TRACE_CCALLS}, - {"Termcap_TermInfo", TRACE_DATABASE}, - {(char *)0, 0} - }; - gen_reps(nap,name,sizeof(int),0); -} - -static void gen_menu_opt_rep(const char *name) -{ - static const name_attribute_pair nap[] = { -#ifdef O_ONEVALUE - {"One_Valued", O_ONEVALUE}, -#endif -#ifdef O_SHOWDESC - {"Show_Descriptions", O_SHOWDESC}, -#endif -#ifdef O_ROWMAJOR - {"Row_Major_Order", O_ROWMAJOR}, -#endif -#ifdef O_IGNORECASE - {"Ignore_Case", O_IGNORECASE}, -#endif -#ifdef O_SHOWMATCH - {"Show_Matches", O_SHOWMATCH}, -#endif -#ifdef O_NONCYCLIC - {"Non_Cyclic", O_NONCYCLIC}, -#endif - {(char *)0, 0} - }; - gen_reps (nap, name, sizeof(int),0); -} - -static void gen_item_opt_rep(const char *name) -{ - static const name_attribute_pair nap[] = { -#ifdef O_SELECTABLE - {"Selectable", O_SELECTABLE}, -#endif - {(char *)0 , 0} - }; - gen_reps (nap, name, sizeof(int),0); -} - -static void gen_form_opt_rep(const char *name) -{ - static const name_attribute_pair nap[] = { -#ifdef O_NL_OVERLOAD - {"NL_Overload", O_NL_OVERLOAD}, -#endif -#ifdef O_BS_OVERLOAD - {"BS_Overload", O_BS_OVERLOAD}, -#endif - {(char *)0 , 0} - }; - gen_reps (nap, name, sizeof(int),0); -} - -/* - * Generate the representation clause for the Field_Option_Set record - */ -static void gen_field_opt_rep(const char *name) -{ - static const name_attribute_pair nap[] = { -#ifdef O_VISIBLE - {"Visible",O_VISIBLE}, -#endif -#ifdef O_ACTIVE - {"Active",O_ACTIVE}, -#endif -#ifdef O_PUBLIC - {"Public",O_PUBLIC}, -#endif -#ifdef O_EDIT - {"Edit",O_EDIT}, -#endif -#ifdef O_WRAP - {"Wrap",O_WRAP}, -#endif -#ifdef O_BLANK - {"Blank",O_BLANK}, -#endif -#ifdef O_AUTOSKIP - {"Auto_Skip",O_AUTOSKIP}, -#endif -#ifdef O_NULLOK - {"Null_Ok",O_NULLOK}, -#endif -#ifdef O_PASSOK - {"Pass_Ok",O_PASSOK}, -#endif -#ifdef O_STATIC - {"Static",O_STATIC}, -#endif - {(char *)0, 0} - }; - gen_reps (nap, name, sizeof(int),0); -} - -/* - * Generate a single key code constant definition. - */ -static void keydef(const char *name, const char *old_name, int value, int mode) -{ - if (mode==0) /* Generate the new name */ - printf(" %-30s : constant Special_Key_Code := 8#%3o#;\n",name,value); - else - { /* generate the old name, but only if it doesn't conflict with the old - * name (Ada95 isn't case sensitive!) - */ - const char *s = old_name; const char *t = name; - while ( *s && *t && (toupper(*s++) == toupper(*t++))); - if (*s || *t) - printf(" %-16s : Special_Key_Code renames %s;\n",old_name,name); - } -} - -/* - * Generate constants for the key codes. When called with mode==0, a - * complete list with nice constant names in proper casing style will - * be generated. Otherwise a list of old (i.e. C-style) names will be - * generated, given that the name wasn't already defined in the "nice" - * list. - */ -static void gen_keydefs (int mode) -{ - char buf[16]; - char obuf[16]; - int i; - -#ifdef KEY_CODE_YES - keydef("Key_Code_Yes","KEY_CODE_YES",KEY_CODE_YES,mode); -#endif -#ifdef KEY_MIN - keydef("Key_Min","KEY_MIN",KEY_MIN,mode); -#endif -#ifdef KEY_BREAK - keydef("Key_Break","KEY_BREAK",KEY_BREAK,mode); -#endif -#ifdef KEY_DOWN - keydef("Key_Cursor_Down","KEY_DOWN",KEY_DOWN,mode); -#endif -#ifdef KEY_UP - keydef("Key_Cursor_Up","KEY_UP",KEY_UP,mode); -#endif -#ifdef KEY_LEFT - keydef("Key_Cursor_Left","KEY_LEFT",KEY_LEFT,mode); -#endif -#ifdef KEY_RIGHT - keydef("Key_Cursor_Right","KEY_RIGHT",KEY_RIGHT,mode); -#endif -#ifdef KEY_HOME - keydef("Key_Home","KEY_HOME",KEY_HOME,mode); -#endif -#ifdef KEY_BACKSPACE - keydef("Key_Backspace","KEY_BACKSPACE",KEY_BACKSPACE,mode); -#endif -#ifdef KEY_F0 - keydef("Key_F0","KEY_F0",KEY_F0,mode); -#endif -#ifdef KEY_F - for(i=1;i<=24;i++) - { - sprintf(buf ,"Key_F%d",i); - sprintf(obuf,"KEY_F%d",i); - keydef(buf,obuf,KEY_F(i),mode); - } -#endif -#ifdef KEY_DL - keydef("Key_Delete_Line","KEY_DL",KEY_DL,mode); -#endif -#ifdef KEY_IL - keydef("Key_Insert_Line","KEY_IL",KEY_IL,mode); -#endif -#ifdef KEY_DC - keydef("Key_Delete_Char","KEY_DC",KEY_DC,mode); -#endif -#ifdef KEY_IC - keydef("Key_Insert_Char","KEY_IC",KEY_IC,mode); -#endif -#ifdef KEY_EIC - keydef("Key_Exit_Insert_Mode","KEY_EIC",KEY_EIC,mode); -#endif -#ifdef KEY_CLEAR - keydef("Key_Clear_Screen","KEY_CLEAR",KEY_CLEAR,mode); -#endif -#ifdef KEY_EOS - keydef("Key_Clear_End_Of_Screen","KEY_EOS",KEY_EOS,mode); -#endif -#ifdef KEY_EOL - keydef("Key_Clear_End_Of_Line","KEY_EOL",KEY_EOL,mode); -#endif -#ifdef KEY_SF - keydef("Key_Scroll_1_Forward","KEY_SF",KEY_SF,mode); -#endif -#ifdef KEY_SR - keydef("Key_Scroll_1_Backward","KEY_SR",KEY_SR,mode); -#endif -#ifdef KEY_NPAGE - keydef("Key_Next_Page","KEY_NPAGE",KEY_NPAGE,mode); -#endif -#ifdef KEY_PPAGE - keydef("Key_Previous_Page","KEY_PPAGE",KEY_PPAGE,mode); -#endif -#ifdef KEY_STAB - keydef("Key_Set_Tab","KEY_STAB",KEY_STAB,mode); -#endif -#ifdef KEY_CTAB - keydef("Key_Clear_Tab","KEY_CTAB",KEY_CTAB,mode); -#endif -#ifdef KEY_CATAB - keydef("Key_Clear_All_Tabs","KEY_CATAB",KEY_CATAB,mode); -#endif -#ifdef KEY_ENTER - keydef("Key_Enter_Or_Send","KEY_ENTER",KEY_ENTER,mode); -#endif -#ifdef KEY_SRESET - keydef("Key_Soft_Reset","KEY_SRESET",KEY_SRESET,mode); -#endif -#ifdef KEY_RESET - keydef("Key_Reset","KEY_RESET",KEY_RESET,mode); -#endif -#ifdef KEY_PRINT - keydef("Key_Print","KEY_PRINT",KEY_PRINT,mode); -#endif -#ifdef KEY_LL - keydef("Key_Bottom","KEY_LL",KEY_LL,mode); -#endif -#ifdef KEY_A1 - keydef("Key_Upper_Left_Of_Keypad","KEY_A1",KEY_A1,mode); -#endif -#ifdef KEY_A3 - keydef("Key_Upper_Right_Of_Keypad","KEY_A3",KEY_A3,mode); -#endif -#ifdef KEY_B2 - keydef("Key_Center_Of_Keypad","KEY_B2",KEY_B2,mode); -#endif -#ifdef KEY_C1 - keydef("Key_Lower_Left_Of_Keypad","KEY_C1",KEY_C1,mode); -#endif -#ifdef KEY_C3 - keydef("Key_Lower_Right_Of_Keypad","KEY_C3",KEY_C3,mode); -#endif -#ifdef KEY_BTAB - keydef("Key_Back_Tab","KEY_BTAB",KEY_BTAB,mode); -#endif -#ifdef KEY_BEG - keydef("Key_Beginning","KEY_BEG",KEY_BEG,mode); -#endif -#ifdef KEY_CANCEL - keydef("Key_Cancel","KEY_CANCEL",KEY_CANCEL,mode); -#endif -#ifdef KEY_CLOSE - keydef("Key_Close","KEY_CLOSE",KEY_CLOSE,mode); -#endif -#ifdef KEY_COMMAND - keydef("Key_Command","KEY_COMMAND",KEY_COMMAND,mode); -#endif -#ifdef KEY_COPY - keydef("Key_Copy","KEY_COPY",KEY_COPY,mode); -#endif -#ifdef KEY_CREATE - keydef("Key_Create","KEY_CREATE",KEY_CREATE,mode); -#endif -#ifdef KEY_END - keydef("Key_End","KEY_END",KEY_END,mode); -#endif -#ifdef KEY_EXIT - keydef("Key_Exit","KEY_EXIT",KEY_EXIT,mode); -#endif -#ifdef KEY_FIND - keydef("Key_Find","KEY_FIND",KEY_FIND,mode); -#endif -#ifdef KEY_HELP - keydef("Key_Help","KEY_HELP",KEY_HELP,mode); -#endif -#ifdef KEY_MARK - keydef("Key_Mark","KEY_MARK",KEY_MARK,mode); -#endif -#ifdef KEY_MESSAGE - keydef("Key_Message","KEY_MESSAGE",KEY_MESSAGE,mode); -#endif -#ifdef KEY_MOVE - keydef("Key_Move","KEY_MOVE",KEY_MOVE,mode); -#endif -#ifdef KEY_NEXT - keydef("Key_Next","KEY_NEXT",KEY_NEXT,mode); -#endif -#ifdef KEY_OPEN - keydef("Key_Open","KEY_OPEN",KEY_OPEN,mode); -#endif -#ifdef KEY_OPTIONS - keydef("Key_Options","KEY_OPTIONS",KEY_OPTIONS,mode); -#endif -#ifdef KEY_PREVIOUS - keydef("Key_Previous","KEY_PREVIOUS",KEY_PREVIOUS,mode); -#endif -#ifdef KEY_REDO - keydef("Key_Redo","KEY_REDO",KEY_REDO,mode); -#endif -#ifdef KEY_REFERENCE - keydef("Key_Reference","KEY_REFERENCE",KEY_REFERENCE,mode); -#endif -#ifdef KEY_REFRESH - keydef("Key_Refresh","KEY_REFRESH",KEY_REFRESH,mode); -#endif -#ifdef KEY_REPLACE - keydef("Key_Replace","KEY_REPLACE",KEY_REPLACE,mode); -#endif -#ifdef KEY_RESTART - keydef("Key_Restart","KEY_RESTART",KEY_RESTART,mode); -#endif -#ifdef KEY_RESUME - keydef("Key_Resume","KEY_RESUME",KEY_RESUME,mode); -#endif -#ifdef KEY_SAVE - keydef("Key_Save","KEY_SAVE",KEY_SAVE,mode); -#endif -#ifdef KEY_SBEG - keydef("Key_Shift_Begin","KEY_SBEG",KEY_SBEG,mode); -#endif -#ifdef KEY_SCANCEL - keydef("Key_Shift_Cancel","KEY_SCANCEL",KEY_SCANCEL,mode); -#endif -#ifdef KEY_SCOMMAND - keydef("Key_Shift_Command","KEY_SCOMMAND",KEY_SCOMMAND,mode); -#endif -#ifdef KEY_SCOPY - keydef("Key_Shift_Copy","KEY_SCOPY",KEY_SCOPY,mode); -#endif -#ifdef KEY_SCREATE - keydef("Key_Shift_Create","KEY_SCREATE",KEY_SCREATE,mode); -#endif -#ifdef KEY_SDC - keydef("Key_Shift_Delete_Char","KEY_SDC",KEY_SDC,mode); -#endif -#ifdef KEY_SDL - keydef("Key_Shift_Delete_Line","KEY_SDL",KEY_SDL,mode); -#endif -#ifdef KEY_SELECT - keydef("Key_Select","KEY_SELECT",KEY_SELECT,mode); -#endif -#ifdef KEY_SEND - keydef("Key_Shift_End","KEY_SEND",KEY_SEND,mode); -#endif -#ifdef KEY_SEOL - keydef("Key_Shift_Clear_End_Of_Line","KEY_SEOL",KEY_SEOL,mode); -#endif -#ifdef KEY_SEXIT - keydef("Key_Shift_Exit","KEY_SEXIT",KEY_SEXIT,mode); -#endif -#ifdef KEY_SFIND - keydef("Key_Shift_Find","KEY_SFIND",KEY_SFIND,mode); -#endif -#ifdef KEY_SHELP - keydef("Key_Shift_Help","KEY_SHELP",KEY_SHELP,mode); -#endif -#ifdef KEY_SHOME - keydef("Key_Shift_Home","KEY_SHOME",KEY_SHOME,mode); -#endif -#ifdef KEY_SIC - keydef("Key_Shift_Insert_Char","KEY_SIC",KEY_SIC,mode); -#endif -#ifdef KEY_SLEFT - keydef("Key_Shift_Cursor_Left","KEY_SLEFT",KEY_SLEFT,mode); -#endif -#ifdef KEY_SMESSAGE - keydef("Key_Shift_Message","KEY_SMESSAGE",KEY_SMESSAGE,mode); -#endif -#ifdef KEY_SMOVE - keydef("Key_Shift_Move","KEY_SMOVE",KEY_SMOVE,mode); -#endif -#ifdef KEY_SNEXT - keydef("Key_Shift_Next_Page","KEY_SNEXT",KEY_SNEXT,mode); -#endif -#ifdef KEY_SOPTIONS - keydef("Key_Shift_Options","KEY_SOPTIONS",KEY_SOPTIONS,mode); -#endif -#ifdef KEY_SPREVIOUS - keydef("Key_Shift_Previous_Page","KEY_SPREVIOUS",KEY_SPREVIOUS,mode); -#endif -#ifdef KEY_SPRINT - keydef("Key_Shift_Print","KEY_SPRINT",KEY_SPRINT,mode); -#endif -#ifdef KEY_SREDO - keydef("Key_Shift_Redo","KEY_SREDO",KEY_SREDO,mode); -#endif -#ifdef KEY_SREPLACE - keydef("Key_Shift_Replace","KEY_SREPLACE",KEY_SREPLACE,mode); -#endif -#ifdef KEY_SRIGHT - keydef("Key_Shift_Cursor_Right","KEY_SRIGHT",KEY_SRIGHT,mode); -#endif -#ifdef KEY_SRSUME - keydef("Key_Shift_Resume","KEY_SRSUME",KEY_SRSUME,mode); -#endif -#ifdef KEY_SSAVE - keydef("Key_Shift_Save","KEY_SSAVE",KEY_SSAVE,mode); -#endif -#ifdef KEY_SSUSPEND - keydef("Key_Shift_Suspend","KEY_SSUSPEND",KEY_SSUSPEND,mode); -#endif -#ifdef KEY_SUNDO - keydef("Key_Shift_Undo","KEY_SUNDO",KEY_SUNDO,mode); -#endif -#ifdef KEY_SUSPEND - keydef("Key_Suspend","KEY_SUSPEND",KEY_SUSPEND,mode); -#endif -#ifdef KEY_UNDO - keydef("Key_Undo","KEY_UNDO",KEY_UNDO,mode); -#endif -#ifdef KEY_MOUSE - keydef("Key_Mouse","KEY_MOUSE",KEY_MOUSE,mode); -#endif -#ifdef KEY_RESIZE - keydef("Key_Resize","KEY_RESIZE",KEY_RESIZE,mode); -#endif -} - -/* - * Generate a constant with the given name. The second parameter - * is a reference to the ACS character in the acs_map[] array and - * will be translated into an index. - */ -static void acs_def (const char *name, chtype *a) -{ - int c = a - &acs_map[0]; - printf(" %-24s : constant Character := ",name); - if (isprint(c) && (c!='`')) - printf("'%c';\n",c); - else - printf("Character'Val (%d);\n",c); -} - -/* - * Generate the constants for the ACS characters - */ -static void gen_acs (void) -{ -#ifdef ACS_ULCORNER - acs_def("ACS_Upper_Left_Corner",&ACS_ULCORNER); -#endif -#ifdef ACS_LLCORNER - acs_def("ACS_Lower_Left_Corner",&ACS_LLCORNER); -#endif -#ifdef ACS_URCORNER - acs_def("ACS_Upper_Right_Corner",&ACS_URCORNER); -#endif -#ifdef ACS_LRCORNER - acs_def("ACS_Lower_Right_Corner",&ACS_LRCORNER); -#endif -#ifdef ACS_LTEE - acs_def("ACS_Left_Tee",&ACS_LTEE); -#endif -#ifdef ACS_RTEE - acs_def("ACS_Right_Tee",&ACS_RTEE); -#endif -#ifdef ACS_BTEE - acs_def("ACS_Bottom_Tee",&ACS_BTEE); -#endif -#ifdef ACS_TTEE - acs_def("ACS_Top_Tee",&ACS_TTEE); -#endif -#ifdef ACS_HLINE - acs_def("ACS_Horizontal_Line",&ACS_HLINE); -#endif -#ifdef ACS_VLINE - acs_def("ACS_Vertical_Line",&ACS_VLINE); -#endif -#ifdef ACS_PLUS - acs_def("ACS_Plus_Symbol",&ACS_PLUS); -#endif -#ifdef ACS_S1 - acs_def("ACS_Scan_Line_1",&ACS_S1); -#endif -#ifdef ACS_S9 - acs_def("ACS_Scan_Line_9",&ACS_S9); -#endif -#ifdef ACS_DIAMOND - acs_def("ACS_Diamond",&ACS_DIAMOND); -#endif -#ifdef ACS_CKBOARD - acs_def("ACS_Checker_Board",&ACS_CKBOARD); -#endif -#ifdef ACS_DEGREE - acs_def("ACS_Degree",&ACS_DEGREE); -#endif -#ifdef ACS_PLMINUS - acs_def("ACS_Plus_Minus",&ACS_PLMINUS); -#endif -#ifdef ACS_BULLET - acs_def("ACS_Bullet",&ACS_BULLET); -#endif -#ifdef ACS_LARROW - acs_def("ACS_Left_Arrow",&ACS_LARROW); -#endif -#ifdef ACS_RARROW - acs_def("ACS_Right_Arrow",&ACS_RARROW); -#endif -#ifdef ACS_DARROW - acs_def("ACS_Down_Arrow",&ACS_DARROW); -#endif -#ifdef ACS_UARROW - acs_def("ACS_Up_Arrow",&ACS_UARROW); -#endif -#ifdef ACS_BOARD - acs_def("ACS_Board_Of_Squares",&ACS_BOARD); -#endif -#ifdef ACS_LANTERN - acs_def("ACS_Lantern",&ACS_LANTERN); -#endif -#ifdef ACS_BLOCK - acs_def("ACS_Solid_Block",&ACS_BLOCK); -#endif -#ifdef ACS_S3 - acs_def("ACS_Scan_Line_3",&ACS_S3); -#endif -#ifdef ACS_S7 - acs_def("ACS_Scan_Line_7",&ACS_S7); -#endif -#ifdef ACS_LEQUAL - acs_def("ACS_Less_Or_Equal",&ACS_LEQUAL); -#endif -#ifdef ACS_GEQUAL - acs_def("ACS_Greater_Or_Equal",&ACS_GEQUAL); -#endif -#ifdef ACS_PI - acs_def("ACS_PI",&ACS_PI); -#endif -#ifdef ACS_NEQUAL - acs_def("ACS_Not_Equal",&ACS_NEQUAL); -#endif -#ifdef ACS_STERLING - acs_def("ACS_Sterling",&ACS_STERLING); -#endif -} - - -#define GEN_EVENT(name,value) \ - printf(" %-25s : constant Event_Mask := 8#%011lo#;\n", \ - #name, value) - -#define GEN_MEVENT(name) \ - printf(" %-25s : constant Event_Mask := 8#%011lo#;\n", \ - #name, name) - -static -void gen_mouse_events(void) -{ - mmask_t all1 = 0; - mmask_t all2 = 0; - mmask_t all3 = 0; - mmask_t all4 = 0; - -#ifdef BUTTON1_RELEASED - GEN_MEVENT(BUTTON1_RELEASED); - all1 |= BUTTON1_RELEASED; -#endif -#ifdef BUTTON1_PRESSED - GEN_MEVENT(BUTTON1_PRESSED); - all1 |= BUTTON1_PRESSED; -#endif -#ifdef BUTTON1_CLICKED - GEN_MEVENT(BUTTON1_CLICKED); - all1 |= BUTTON1_CLICKED; -#endif -#ifdef BUTTON1_DOUBLE_CLICKED - GEN_MEVENT(BUTTON1_DOUBLE_CLICKED); - all1 |= BUTTON1_DOUBLE_CLICKED; -#endif -#ifdef BUTTON1_TRIPLE_CLICKED - GEN_MEVENT(BUTTON1_TRIPLE_CLICKED); - all1 |= BUTTON1_TRIPLE_CLICKED; -#endif -#ifdef BUTTON1_RESERVED_EVENT - GEN_MEVENT(BUTTON1_RESERVED_EVENT); - all1 |= BUTTON1_RESERVED_EVENT; -#endif -#ifdef BUTTON2_RELEASED - GEN_MEVENT(BUTTON2_RELEASED); - all2 |= BUTTON2_RELEASED; -#endif -#ifdef BUTTON2_PRESSED - GEN_MEVENT(BUTTON2_PRESSED); - all2 |= BUTTON2_PRESSED; -#endif -#ifdef BUTTON2_CLICKED - GEN_MEVENT(BUTTON2_CLICKED); - all2 |= BUTTON2_CLICKED; -#endif -#ifdef BUTTON2_DOUBLE_CLICKED - GEN_MEVENT(BUTTON2_DOUBLE_CLICKED); - all2 |= BUTTON2_DOUBLE_CLICKED; -#endif -#ifdef BUTTON2_TRIPLE_CLICKED - GEN_MEVENT(BUTTON2_TRIPLE_CLICKED); - all2 |= BUTTON2_TRIPLE_CLICKED; -#endif -#ifdef BUTTON2_RESERVED_EVENT - GEN_MEVENT(BUTTON2_RESERVED_EVENT); - all2 |= BUTTON2_RESERVED_EVENT; -#endif -#ifdef BUTTON3_RELEASED - GEN_MEVENT(BUTTON3_RELEASED); - all3 |= BUTTON3_RELEASED; -#endif -#ifdef BUTTON3_PRESSED - GEN_MEVENT(BUTTON3_PRESSED); - all3 |= BUTTON3_PRESSED; -#endif -#ifdef BUTTON3_CLICKED - GEN_MEVENT(BUTTON3_CLICKED); - all3 |= BUTTON3_CLICKED; -#endif -#ifdef BUTTON3_DOUBLE_CLICKED - GEN_MEVENT(BUTTON3_DOUBLE_CLICKED); - all3 |= BUTTON3_DOUBLE_CLICKED; -#endif -#ifdef BUTTON3_TRIPLE_CLICKED - GEN_MEVENT(BUTTON3_TRIPLE_CLICKED); - all3 |= BUTTON3_TRIPLE_CLICKED; -#endif -#ifdef BUTTON3_RESERVED_EVENT - GEN_MEVENT(BUTTON3_RESERVED_EVENT); - all3 |= BUTTON3_RESERVED_EVENT; -#endif -#ifdef BUTTON4_RELEASED - GEN_MEVENT(BUTTON4_RELEASED); - all4 |= BUTTON4_RELEASED; -#endif -#ifdef BUTTON4_PRESSED - GEN_MEVENT(BUTTON4_PRESSED); - all4 |= BUTTON4_PRESSED; -#endif -#ifdef BUTTON4_CLICKED - GEN_MEVENT(BUTTON4_CLICKED); - all4 |= BUTTON4_CLICKED; -#endif -#ifdef BUTTON4_DOUBLE_CLICKED - GEN_MEVENT(BUTTON4_DOUBLE_CLICKED); - all4 |= BUTTON4_DOUBLE_CLICKED; -#endif -#ifdef BUTTON4_TRIPLE_CLICKED - GEN_MEVENT(BUTTON4_TRIPLE_CLICKED); - all4 |= BUTTON4_TRIPLE_CLICKED; -#endif -#ifdef BUTTON4_RESERVED_EVENT - GEN_MEVENT(BUTTON4_RESERVED_EVENT); - all4 |= BUTTON4_RESERVED_EVENT; -#endif -#ifdef BUTTON_CTRL - GEN_MEVENT(BUTTON_CTRL); -#endif -#ifdef BUTTON_SHIFT - GEN_MEVENT(BUTTON_SHIFT); -#endif -#ifdef BUTTON_ALT - GEN_MEVENT(BUTTON_ALT); -#endif -#ifdef REPORT_MOUSE_POSITION - GEN_MEVENT(REPORT_MOUSE_POSITION); -#endif -#ifdef ALL_MOUSE_EVENTS - GEN_MEVENT(ALL_MOUSE_EVENTS); -#endif - -GEN_EVENT(BUTTON1_EVENTS,all1); -GEN_EVENT(BUTTON2_EVENTS,all2); -GEN_EVENT(BUTTON3_EVENTS,all3); -GEN_EVENT(BUTTON4_EVENTS,all4); -} - -/* - * Output some comment lines indicating that the file is generated. - * The name parameter is the name of the facility to be used in - * the comment. - */ -static void prologue(const char *name) -{ - printf("-- %s binding.\n",name); - printf("-- This module is generated. Please don't change it manually!\n"); - printf("-- Run the generator instead.\n-- |"); - - printf("define(`M4_BIT_ORDER',`%s_Order_First')", - little_endian ? "Low":"High"); -} - -/* - * Write the prologue for the curses facility and make sure that - * KEY_MIN and KEY_MAX are defined for the rest of this source. - */ -static void basedefs (void) -{ - prologue("curses"); -#ifndef KEY_MAX -# define KEY_MAX 0777 -#endif - printf("define(`M4_KEY_MAX',`8#%o#')",KEY_MAX); -#ifndef KEY_MIN -# define KEY_MIN 0401 -#endif - if (KEY_MIN == 256) { - fprintf(stderr,"Unexpected value for KEY_MIN: %d\n",KEY_MIN); - exit(1); - } - printf("define(`M4_SPECIAL_FIRST',`8#%o#')",KEY_MIN - 1); -} - -/* - * Write out the comment lines for the menu facility - */ -static void menu_basedefs (void) -{ - prologue("menu"); -} - -/* - * Write out the comment lines for the form facility - */ -static void form_basedefs (void) -{ - prologue("form"); -} - -/* - * Write out the comment lines for the mouse facility - */ -static void mouse_basedefs(void) -{ - prologue("mouse"); -} - -/* - * Write the definition of a single color - */ -static void color_def (const char *name, int value) -{ - printf(" %-16s : constant Color_Number := %d;\n",name,value); -} - -#define HAVE_USE_DEFAULT_COLORS 1 - -/* - * Generate all color definitions - */ -static void gen_color (void) -{ -#ifdef HAVE_USE_DEFAULT_COLORS - color_def ("Default_Color",-1); -#endif -#ifdef COLOR_BLACK - color_def ("Black",COLOR_BLACK); -#endif -#ifdef COLOR_RED - color_def ("Red",COLOR_RED); -#endif -#ifdef COLOR_GREEN - color_def ("Green",COLOR_GREEN); -#endif -#ifdef COLOR_YELLOW - color_def ("Yellow",COLOR_YELLOW); -#endif -#ifdef COLOR_BLUE - color_def ("Blue",COLOR_BLUE); -#endif -#ifdef COLOR_MAGENTA - color_def ("Magenta",COLOR_MAGENTA); -#endif -#ifdef COLOR_CYAN - color_def ("Cyan",COLOR_CYAN); -#endif -#ifdef COLOR_WHITE - color_def ("White",COLOR_WHITE); -#endif -} - -/* - * Generate the linker options for the base facility - */ -static void gen_linkopts (void) -{ - printf(" pragma Linker_Options (\"-lncurses%s\");\n", model); -} - -/* - * Generate the linker options for the menu facility - */ -static void gen_menu_linkopts (void) -{ - printf(" pragma Linker_Options (\"-lmenu%s\");\n", model); -} - -/* - * Generate the linker options for the form facility - */ -static void gen_form_linkopts (void) -{ - printf(" pragma Linker_Options (\"-lform%s\");\n", model); -} - -/* - * Generate the linker options for the panel facility - */ -static void gen_panel_linkopts (void) -{ - printf(" pragma Linker_Options (\"-lpanel%s\");\n", model); -} - -static void gen_version_info (void) -{ - static const char* v1 = - " NC_Major_Version : constant := %d; -- Major version of the library\n"; - static const char* v2 = - " NC_Minor_Version : constant := %d; -- Minor version of the library\n"; - static const char* v3 = - " NC_Version : constant String := %c%d.%d%c; -- Version of library\n"; - - printf(v1, NCURSES_VERSION_MAJOR); - printf(v2, NCURSES_VERSION_MINOR); - printf(v3, '"',NCURSES_VERSION_MAJOR,NCURSES_VERSION_MINOR,'"'); -} - -static int -eti_gen(char*buf, int code, const char* name, int* etimin, int* etimax) -{ - sprintf(buf," E_%-16s : constant Eti_Error := %d;\n",name,code); - if (code < *etimin) - *etimin = code; - if (code > *etimax) - *etimax = code; - return strlen(buf); -} - -#define GEN_OFFSET(member,itype) \ - if (sizeof(((WINDOW*)0)->member)==sizeof(itype)) { \ - o = offsetof(WINDOW, member); \ - if ((o%sizeof(itype) == 0)) { \ - printf(" Offset%-*s : constant Natural := %2ld; -- %s\n", \ - 12, #member, o/sizeof(itype),#itype); \ - } \ - } - -static void -gen_offsets(void) -{ - long o; - const char* s_bool = ""; - - GEN_OFFSET(_maxy,short); - GEN_OFFSET(_maxx,short); - GEN_OFFSET(_begy,short); - GEN_OFFSET(_begx,short); - GEN_OFFSET(_cury,short); - GEN_OFFSET(_curx,short); - GEN_OFFSET(_yoffset,short); - GEN_OFFSET(_pary,int); - GEN_OFFSET(_parx,int); - if (sizeof(bool) == sizeof(char)) { - GEN_OFFSET(_notimeout,char); - GEN_OFFSET(_clear,char); - GEN_OFFSET(_leaveok,char); - GEN_OFFSET(_scroll,char); - GEN_OFFSET(_idlok,char); - GEN_OFFSET(_idcok,char); - GEN_OFFSET(_immed,char); - GEN_OFFSET(_sync,char); - GEN_OFFSET(_use_keypad,char); - s_bool = "char"; - } else if (sizeof(bool) == sizeof(short)) { - GEN_OFFSET(_notimeout,short); - GEN_OFFSET(_clear,short); - GEN_OFFSET(_leaveok,short); - GEN_OFFSET(_scroll,short); - GEN_OFFSET(_idlok,short); - GEN_OFFSET(_idcok,short); - GEN_OFFSET(_immed,short); - GEN_OFFSET(_sync,short); - GEN_OFFSET(_use_keypad,short); - s_bool = "short"; - } else if (sizeof(bool) == sizeof(int)) { - GEN_OFFSET(_notimeout,int); - GEN_OFFSET(_clear,int); - GEN_OFFSET(_leaveok,int); - GEN_OFFSET(_scroll,int); - GEN_OFFSET(_idlok,int); - GEN_OFFSET(_idcok,int); - GEN_OFFSET(_immed,int); - GEN_OFFSET(_sync,int); - GEN_OFFSET(_use_keypad,int); - s_bool = "int"; - } - printf(" Sizeof%-*s : constant Natural := %2ld; -- %s\n", - 12, "_bool", (long) sizeof(bool),"bool"); - /* In ncurses _maxy and _maxx needs an offset for the "public" - * value - */ - printf(" Offset%-*s : constant Natural := %2d; -- %s\n", - 12, "_XY",1,"int"); - printf("\n"); - printf(" type Curses_Bool is mod 2 ** Interfaces.C.%s'Size;\n",s_bool); -} - -/* - * main() expects two arguments on the commandline, both single characters. - * The first character denotes the facility for which we generate output. - * Possible values are - * B - Base - * M - Menus - * F - Forms - * P - Pointer Device (Mouse) - * E - ETI base definitions - * - * The second character then denotes the specific output that should be - * generated for the selected facility. - */ -int main(int argc, char *argv[]) -{ - int x = 0x12345678; - char *s = (char *)&x; - - if (*s == 0x78) - little_endian = 1; - - if (argc!=4) - exit(1); - model = *++argv; - - switch(argv[1][0]) - { - /* ---------------------------------------------------------------*/ - case 'B': /* The Base facility */ - switch(argv[2][0]) - { - case 'A': /* chtype translation into Ada95 record type */ - gen_attr_set("Character_Attribute_Set"); - break; - case 'K': /* translation of keycodes */ - gen_keydefs(0); - break; - case 'B': /* write some initial comment lines */ - basedefs(); - break; - case 'C': /* generate color constants */ - gen_color(); - break; - case 'D': /* generate displacements of fields in WINDOW struct. */ - gen_offsets(); - break; - case 'E': /* generate Mouse Event codes */ - gen_mouse_events(); - break; - case 'M': /* generate constants for the ACS characters */ - gen_acs(); - break; - case 'L': /* generate the Linker_Options pragma */ - gen_linkopts(); - break; - case 'O': /* generate definitions of the old key code names */ - gen_keydefs(1); - break; - case 'R': /* generate representation clause for Attributed character */ - gen_chtype_rep("Attributed_Character"); - break; - case 'V': /* generate version info */ - gen_version_info(); - break; - case 'T': /* generate the Trace info */ - gen_trace("Trace_Attribute_Set"); - break; - default: - break; - } - break; - /* ---------------------------------------------------------------*/ - case 'M': /* The Menu facility */ - switch(argv[2][0]) - { - case 'R': /* generate representation clause for Menu_Option_Set */ - gen_menu_opt_rep("Menu_Option_Set"); - break; - case 'B': /* write some initial comment lines */ - menu_basedefs(); - break; - case 'L': /* generate the Linker_Options pragma */ - gen_menu_linkopts(); - break; - case 'I': /* generate representation clause for Item_Option_Set */ - gen_item_opt_rep("Item_Option_Set"); - break; - default: - break; - } - break; - /* ---------------------------------------------------------------*/ - case 'F': /* The Form facility */ - switch(argv[2][0]) - { - case 'R': /* generate representation clause for Form_Option_Set */ - gen_form_opt_rep("Form_Option_Set"); - break; - case 'B': /* write some initial comment lines */ - form_basedefs(); - break; - case 'L': /* generate the Linker_Options pragma */ - gen_form_linkopts(); - break; - case 'I': /* generate representation clause for Field_Option_Set */ - gen_field_opt_rep("Field_Option_Set"); - break; - default: - break; - } - break; - /* ---------------------------------------------------------------*/ - case 'P': /* The Pointer(=Mouse) facility */ - switch(argv[2][0]) { - case 'B': /* write some initial comment lines */ - mouse_basedefs(); - break; - case 'M': /* generate representation clause for Mouse_Event */ - gen_mrep_rep("Mouse_Event"); - break; - case 'L': /* generate the Linker_Options pragma */ - gen_panel_linkopts(); - break; - default: - break; - } - break; - /* ---------------------------------------------------------------*/ - case 'E' : /* chtype size detection */ - switch(argv[2][0]) { - case 'C': - { - const char* fmt = " type C_Chtype is new %s;\n"; - const char* afmt = " type C_AttrType is new %s;\n"; - - if (sizeof(chtype)==sizeof(int)) { - if (sizeof(int)==sizeof(long)) - printf(fmt,"C_ULong"); - else - printf(fmt,"C_UInt"); - } - else if (sizeof(chtype)==sizeof(long)) { - printf(fmt,"C_ULong"); - } - else - printf("Error\n"); - - if (sizeof(attr_t)==sizeof(int)) { - if (sizeof(int)==sizeof(long)) - printf(afmt,"C_ULong"); - else - printf(afmt,"C_UInt"); - } - else if (sizeof(attr_t)==sizeof(long)) { - printf(afmt,"C_ULong"); - } - else - printf("Error\n"); - - printf("define(`CF_CURSES_OK',`%d')",OK); - printf("define(`CF_CURSES_ERR',`%d')",ERR); - printf("define(`CF_CURSES_TRUE',`%d')",TRUE); - printf("define(`CF_CURSES_FALSE',`%d')",FALSE); - } - break; - case 'E': - { - char* buf = (char*)malloc(2048); - char* p = buf; - int etimin = E_OK; - int etimax = E_OK; - if (p) { - p += eti_gen(p, E_OK, "Ok", &etimin, &etimax); - p += eti_gen(p, E_SYSTEM_ERROR,"System_Error", &etimin, &etimax); - p += eti_gen(p, E_BAD_ARGUMENT, "Bad_Argument", &etimin, &etimax); - p += eti_gen(p, E_POSTED, "Posted", &etimin, &etimax); - p += eti_gen(p, E_CONNECTED, "Connected", &etimin, &etimax); - p += eti_gen(p, E_BAD_STATE, "Bad_State", &etimin, &etimax); - p += eti_gen(p, E_NO_ROOM, "No_Room", &etimin, &etimax); - p += eti_gen(p, E_NOT_POSTED, "Not_Posted", &etimin, &etimax); - p += eti_gen(p, E_UNKNOWN_COMMAND, - "Unknown_Command", &etimin, &etimax); - p += eti_gen(p, E_NO_MATCH, "No_Match", &etimin, &etimax); - p += eti_gen(p, E_NOT_SELECTABLE, - "Not_Selectable", &etimin, &etimax); - p += eti_gen(p, E_NOT_CONNECTED, - "Not_Connected", &etimin, &etimax); - p += eti_gen(p, E_REQUEST_DENIED, - "Request_Denied", &etimin, &etimax); - p += eti_gen(p, E_INVALID_FIELD, - "Invalid_Field", &etimin, &etimax); - p += eti_gen(p, E_CURRENT, - "Current", &etimin, &etimax); - } - printf(" subtype Eti_Error is C_Int range %d .. %d;\n\n", - etimin,etimax); - printf(buf); - } - break; - default: - break; - } - break; - /* ---------------------------------------------------------------*/ - case 'V' : /* plain version dump */ - { - switch(argv[2][0]) { - case '1': /* major version */ -#ifdef NCURSES_VERSION_MAJOR - printf("%d",NCURSES_VERSION_MAJOR); -#endif - break; - case '2': /* minor version */ -#ifdef NCURSES_VERSION_MINOR - printf("%d",NCURSES_VERSION_MINOR); -#endif - break; - case '3': /* patch level */ -#ifdef NCURSES_VERSION_PATCH - printf("%d",NCURSES_VERSION_PATCH); -#endif - break; - default: - break; - } - } - break; - /* ---------------------------------------------------------------*/ - default: - break; - } - return 0; -} - diff --git a/contrib/ncurses-5.4/Ada95/gen/html.m4 b/contrib/ncurses-5.4/Ada95/gen/html.m4 deleted file mode 100644 index 0b4254d3c0..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/html.m4 +++ /dev/null @@ -1,11 +0,0 @@ -define(`ANCHORIDX',`0')dnl -define(`MANPAGE',`define(`MANPG',$1)dnl -|===================================================================== - -- | Man page MANPG - -- |=====================================================================')dnl -define(`ANCHOR',`define(`ANCHORIDX',incr(ANCHORIDX))dnl -`#'1A NAME="AFU`_'ANCHORIDX"`#'2dnl -define(`CFUNAME',`$1')define(`AFUNAME',`$2')dnl -|') -define(`AKA',``AKA': CFUNAME')dnl -define(`ALIAS',``AKA': $1')dnl diff --git a/contrib/ncurses-5.4/Ada95/gen/normal.m4 b/contrib/ncurses-5.4/Ada95/gen/normal.m4 deleted file mode 100644 index f884c4653e..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/normal.m4 +++ /dev/null @@ -1,8 +0,0 @@ -define(`MANPAGE',`define(`MANPG',$1)dnl -|===================================================================== - -- | Man page MANPG - -- |=====================================================================')dnl -define(`ANCHOR',`define(`CFUNAME',`$1')define(`AFUNAME',`$2')'dnl -|)dnl -define(`AKA',``AKA': CFUNAME')dnl -define(`ALIAS',``AKA': $1')dnl diff --git a/contrib/ncurses-5.4/Ada95/gen/table.m4 b/contrib/ncurses-5.4/Ada95/gen/table.m4 deleted file mode 100644 index 48ed6ce30a..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/table.m4 +++ /dev/null @@ -1,6 +0,0 @@ -define(`ANCHORIDX',`0')dnl -define(`MANPAGE',`define(`MANPG',$1)')dnl -divert(-1)dnl -define(`ANCHOR',`divert(0)define(`ANCHORIDX',incr(ANCHORIDX))dnl -$1$2MANPG -divert(-1)') diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-aux.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-aux.ads.m4 deleted file mode 100644 index 4fc742a235..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-aux.ads.m4 +++ /dev/null @@ -1,104 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-aux__ads.htm')dnl -include(M4MACRO)------------------------------------------------------------------------------ --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Aux -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.15 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -include(`Base_Defs') -with System; -with Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Unchecked_Conversion; - -package Terminal_Interface.Curses.Aux is - pragma Preelaborate (Terminal_Interface.Curses.Aux); - - use type Interfaces.C.int; - - subtype C_Int is Interfaces.C.int; - subtype C_Short is Interfaces.C.short; - subtype C_Long_Int is Interfaces.C.long; - subtype C_Size_T is Interfaces.C.size_t; - subtype C_UInt is Interfaces.C.unsigned; - subtype C_ULong is Interfaces.C.unsigned_long; - subtype C_Char_Ptr is Interfaces.C.Strings.chars_ptr; - type C_Void_Ptr is new System.Address; -include(`Chtype_Def') - -- This is how those constants are defined in ncurses. I see them also - -- exactly like this in all ETI implementations I ever tested. So it - -- could be that this is quite general, but please check with your curses. - -- This is critical, because curses sometime mixes boolean returns with - -- returning an error status. - Curses_Ok : constant C_Int := CF_CURSES_OK; - Curses_Err : constant C_Int := CF_CURSES_ERR; - - Curses_True : constant C_Int := CF_CURSES_TRUE; - Curses_False : constant C_Int := CF_CURSES_FALSE; - - -- Eti_Error: type for error codes returned by the menu and form subsystem -include(`Eti_Defs') - procedure Eti_Exception (Code : Eti_Error); - -- Dispatch the error code and raise the appropriate exception - -- - -- - -- Some helpers - function Chtype_To_AttrChar is new - Unchecked_Conversion (Source => C_Chtype, - Target => Attributed_Character); - function AttrChar_To_Chtype is new - Unchecked_Conversion (Source => Attributed_Character, - Target => C_Chtype); - - function AttrChar_To_AttrType is new - Unchecked_Conversion (Source => Attributed_Character, - Target => C_AttrType); - - function AttrType_To_AttrChar is new - Unchecked_Conversion (Source => C_AttrType, - Target => Attributed_Character); - - procedure Fill_String (Cp : in chars_ptr; - Str : out String); - -- Fill the Str parameter with the string denoted by the chars_ptr - -- C-Style string. - - function Fill_String (Cp : chars_ptr) return String; - -- Same but as function. - -end Terminal_Interface.Curses.Aux; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_types.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_types.ads.m4 deleted file mode 100644 index 8819844a70..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_types.ads.m4 +++ /dev/null @@ -1,238 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-forms-field_user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; - -package Terminal_Interface.Curses.Forms.Field_Types is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types); - use type Interfaces.C.int; - subtype C_Int is Interfaces.C.int; - - -- MANPAGE(`form_fieldtype.3x') - - type Field_Type is abstract tagged null record; - -- Abstract base type for all field types. A concrete field type - -- is an extension that adds some data elements describing formats or - -- boundary values for the type and validation routines. - -- For the builtin low-level fieldtypes, the validation routines are - -- already defined by the low-level C library. - -- The builtin types like Alpha or AlphaNumeric etc. are defined in - -- child packages of this package. You may use one of them as example - -- how to create you own child packages for low-level field types that - -- you may have already written in C. - - type Field_Type_Access is access all Field_Type'Class; - - -- ANCHOR(`set_field_type()',`Set_Type') - procedure Set_Field_Type (Fld : in Field; - Fld_Type : in Field_Type) is abstract; - -- AKA - -- But: we hide the vararg mechanism of the C interface. You always - -- have to pass a single Field_Type parameter. - - -- --------------------------------------------------------------------- - - -- MANPAGE(`form_field_validation.3x') - - -- ANCHOR(`field_type()',`Get_Type') - function Get_Type (Fld : in Field) return Field_Type_Access; - -- AKA - -- ALIAS(`field_arg()') - -- In Ada95 we can combine these. If you try to retrieve the field type - -- that is not defined as extension of the abstract tagged type above, - -- you will raise a Form_Exception. - -- This is not inlined - - -- +---------------------------------------------------------------------- - -- | Private Part. - -- | Most of this is used by the implementations of the child packages. - -- | -private - type Makearg_Function is access - function (Args : System.Address) return System.Address; - pragma Convention (C, Makearg_Function); - - type Copyarg_Function is access - function (Usr : System.Address) return System.Address; - pragma Convention (C, Copyarg_Function); - - type Freearg_Function is access - procedure (Usr : System.Address); - pragma Convention (C, Freearg_Function); - - type Field_Check_Function is access - function (Fld : Field; Usr : System.Address) return C_Int; - pragma Convention (C, Field_Check_Function); - - type Char_Check_Function is access - function (Ch : C_Int; Usr : System.Address) return C_Int; - pragma Convention (C, Char_Check_Function); - - type Choice_Function is access - function (Fld : Field; Usr : System.Address) return C_Int; - pragma Convention (C, Choice_Function); - - -- +---------------------------------------------------------------------- - -- | This must be in sync with the FIELDTYPE structure in form.h - -- | - type Low_Level_Field_Type is - record - Status : Interfaces.C.short; - Ref_Count : Interfaces.C.long; - Left, Right : System.Address; - Makearg : Makearg_Function; - Copyarg : Copyarg_Function; - Freearg : Freearg_Function; - Fcheck : Field_Check_Function; - Ccheck : Char_Check_Function; - Next, Prev : Choice_Function; - end record; - pragma Convention (C, Low_Level_Field_Type); - type C_Field_Type is access all Low_Level_Field_Type; - - Null_Field_Type : constant C_Field_Type := null; - - -- +---------------------------------------------------------------------- - -- | This four low-level fieldtypes are the ones associated with - -- | fieldtypes handled by this binding. Any other low-level fieldtype - -- | will result in a Form_Exception is function Get_Type. - -- | - M_Generic_Type : C_Field_Type := null; - M_Generic_Choice : C_Field_Type := null; - M_Builtin_Router : C_Field_Type := null; - M_Choice_Router : C_Field_Type := null; - - -- Two wrapper functions to access those low-level fieldtypes defined - -- in this package. - function C_Builtin_Router return C_Field_Type; - function C_Choice_Router return C_Field_Type; - - procedure Wrap_Builtin (Fld : Field; - Typ : Field_Type'Class; - Cft : C_Field_Type := C_Builtin_Router); - -- This procedure has to be called by the Set_Field_Type implementation - -- for builtin low-level fieldtypes to replace it by an Ada95 - -- conformant Field_Type object. - -- The parameter Cft must be C_Builtin_Router for regular low-level - -- fieldtypes (like TYP_ALPHA or TYP_ALNUM) and C_Choice_Router for - -- low-level fieldtypes witch choice functions (like TYP_ENUM). - -- Any other value will raise a Form_Exception. - - function Make_Arg (Args : System.Address) return System.Address; - pragma Convention (C, Make_Arg); - -- This is the Makearg_Function for the internal low-level types - -- introduced by this binding. - - function Copy_Arg (Usr : System.Address) return System.Address; - pragma Convention (C, Copy_Arg); - -- This is the Copyarg_Function for the internal low-level types - -- introduced by this binding. - - procedure Free_Arg (Usr : System.Address); - pragma Convention (C, Free_Arg); - -- This is the Freearg_Function for the internal low-level types - -- introduced by this binding. - - function Field_Check_Router (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Field_Check_Router); - -- This is the Field_Check_Function for the internal low-level types - -- introduced to wrap the low-level types by a Field_Type derived - -- type. It routes the call to the corresponding low-level validation - -- function. - - function Char_Check_Router (Ch : C_Int; - Usr : System.Address) return C_Int; - pragma Convention (C, Char_Check_Router); - -- This is the Char_Check_Function for the internal low-level types - -- introduced to wrap the low-level types by a Field_Type derived - -- type. It routes the call to the corresponding low-level validation - -- function. - - function Next_Router (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Next_Router); - -- This is the Choice_Function for the internal low-level types - -- introduced to wrap the low-level types by a Field_Type derived - -- type. It routes the call to the corresponding low-level next_choice - -- function. - - function Prev_Router (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Prev_Router); - -- This is the Choice_Function for the internal low-level types - -- introduced to wrap the low-level types by a Field_Type derived - -- type. It routes the call to the corresponding low-level prev_choice - -- function. - - -- This is the Argument structure maintained by all low-level field types - -- introduced by this binding. - type Argument is record - Typ : Field_Type_Access; -- the Field_Type creating this record - Usr : System.Address; -- original arg for builtin low-level types - Cft : C_Field_Type; -- the original low-level type - end record; - type Argument_Access is access all Argument; - - -- +---------------------------------------------------------------------- - -- | - -- | Some Imports of libform routines to deal with low-level fieldtypes. - -- | - function New_Fieldtype (Fcheck : Field_Check_Function; - Ccheck : Char_Check_Function) - return C_Field_Type; - pragma Import (C, New_Fieldtype, "new_fieldtype"); - - function Set_Fieldtype_Arg (Cft : C_Field_Type; - Mak : Makearg_Function := Make_Arg'Access; - Cop : Copyarg_Function := Copy_Arg'Access; - Fre : Freearg_Function := Free_Arg'Access) - return C_Int; - pragma Import (C, Set_Fieldtype_Arg, "set_fieldtype_arg"); - - function Set_Fieldtype_Choice (Cft : C_Field_Type; - Next, Prev : Choice_Function) - return C_Int; - pragma Import (C, Set_Fieldtype_Choice, "set_fieldtype_choice"); - -end Terminal_Interface.Curses.Forms.Field_Types; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_user_data.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_user_data.ads.m4 deleted file mode 100644 index 41398836e5..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-field_user_data.ads.m4 +++ /dev/null @@ -1,70 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-forms-field_user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_User_Data -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.15 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -generic - type User is limited private; - type User_Access is access User; -package Terminal_Interface.Curses.Forms.Field_User_Data is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_User_Data); - - -- MANPAGE(`form_field_userptr.3x') - - -- ANCHOR(`set_field_userptr',`Set_User_Data') - procedure Set_User_Data (Fld : in Field; - Data : in User_Access); - -- AKA - pragma Inline (Set_User_Data); - - -- ANCHOR(`field_userptr',`Get_User_Data') - procedure Get_User_Data (Fld : in Field; - Data : out User_Access); - -- AKA - - -- ANCHOR(`field_userptr',`Get_User_Data') - function Get_User_Data (Fld : in Field) return User_Access; - -- AKA - -- Sama as function - pragma Inline (Get_User_Data); - -end Terminal_Interface.Curses.Forms.Field_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-form_user_data.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-form_user_data.ads.m4 deleted file mode 100644 index 0c4420d8f9..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms-form_user_data.ads.m4 +++ /dev/null @@ -1,70 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-forms-form_user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Form_User_Data -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -generic - type User is limited private; - type User_Access is access User; -package Terminal_Interface.Curses.Forms.Form_User_Data is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Form_User_Data); - - -- MANPAGE(`form_userptr.3x') - - -- ANCHOR(`set_form_userptr',`Set_User_Data') - procedure Set_User_Data (Frm : in Form; - Data : in User_Access); - -- AKA - pragma Inline (Set_User_Data); - - -- ANCHOR(`form_userptr',`Get_User_Data') - procedure Get_User_Data (Frm : in Form; - Data : out User_Access); - -- AKA - - -- ANCHOR(`form_userptr',`Get_User_Data') - function Get_User_Data (Frm : in Form) return User_Access; - -- AKA - -- Same as function - pragma Inline (Get_User_Data); - -end Terminal_Interface.Curses.Forms.Form_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms.ads.m4 deleted file mode 100644 index e6570c28bd..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-forms.ads.m4 +++ /dev/null @@ -1,699 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-forms__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Form -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.27 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -include(`Form_Base_Defs') -with System; -with Ada.Characters.Latin_1; - -package Terminal_Interface.Curses.Forms is - pragma Preelaborate (Terminal_Interface.Curses.Forms); -include(`Form_Linker_Options')dnl -include(`Linker_Options') - Space : Character renames Ada.Characters.Latin_1.Space; - - type Field is private; - type Form is private; - - Null_Field : constant Field; - Null_Form : constant Form; - - type Field_Justification is (None, - Left, - Center, - Right); - - pragma Warnings (Off); -include(`Field_Rep')Dnl - - pragma Warnings (On); - - function Default_Field_Options return Field_Option_Set; - -- The initial defaults for the field options. - pragma Inline (Default_Field_Options); - - pragma Warnings (Off); -include(`Form_Opt_Rep')Dnl - - pragma Warnings (On); - - function Default_Form_Options return Form_Option_Set; - -- The initial defaults for the form options. - pragma Inline (Default_Form_Options); - - type Buffer_Number is new Natural; - - type Field_Array is array (Positive range <>) of aliased Field; - pragma Convention (C, Field_Array); - - type Field_Array_Access is access Field_Array; - - procedure Free (FA : in out Field_Array_Access; - Free_Fields : in Boolean := False); - -- Release the memory for an allocated field array - -- If Free_Fields is True, call Delete() for all the fields in - -- the array. - - subtype Form_Request_Code is Key_Code range (Key_Max + 1) .. (Key_Max + 57); - - -- The prefix F_ stands for "Form Request" - F_Next_Page : constant Form_Request_Code := Key_Max + 1; - F_Previous_Page : constant Form_Request_Code := Key_Max + 2; - F_First_Page : constant Form_Request_Code := Key_Max + 3; - F_Last_Page : constant Form_Request_Code := Key_Max + 4; - - F_Next_Field : constant Form_Request_Code := Key_Max + 5; - F_Previous_Field : constant Form_Request_Code := Key_Max + 6; - F_First_Field : constant Form_Request_Code := Key_Max + 7; - F_Last_Field : constant Form_Request_Code := Key_Max + 8; - F_Sorted_Next_Field : constant Form_Request_Code := Key_Max + 9; - F_Sorted_Previous_Field : constant Form_Request_Code := Key_Max + 10; - F_Sorted_First_Field : constant Form_Request_Code := Key_Max + 11; - F_Sorted_Last_Field : constant Form_Request_Code := Key_Max + 12; - F_Left_Field : constant Form_Request_Code := Key_Max + 13; - F_Right_Field : constant Form_Request_Code := Key_Max + 14; - F_Up_Field : constant Form_Request_Code := Key_Max + 15; - F_Down_Field : constant Form_Request_Code := Key_Max + 16; - - F_Next_Char : constant Form_Request_Code := Key_Max + 17; - F_Previous_Char : constant Form_Request_Code := Key_Max + 18; - F_Next_Line : constant Form_Request_Code := Key_Max + 19; - F_Previous_Line : constant Form_Request_Code := Key_Max + 20; - F_Next_Word : constant Form_Request_Code := Key_Max + 21; - F_Previous_Word : constant Form_Request_Code := Key_Max + 22; - F_Begin_Field : constant Form_Request_Code := Key_Max + 23; - F_End_Field : constant Form_Request_Code := Key_Max + 24; - F_Begin_Line : constant Form_Request_Code := Key_Max + 25; - F_End_Line : constant Form_Request_Code := Key_Max + 26; - F_Left_Char : constant Form_Request_Code := Key_Max + 27; - F_Right_Char : constant Form_Request_Code := Key_Max + 28; - F_Up_Char : constant Form_Request_Code := Key_Max + 29; - F_Down_Char : constant Form_Request_Code := Key_Max + 30; - - F_New_Line : constant Form_Request_Code := Key_Max + 31; - F_Insert_Char : constant Form_Request_Code := Key_Max + 32; - F_Insert_Line : constant Form_Request_Code := Key_Max + 33; - F_Delete_Char : constant Form_Request_Code := Key_Max + 34; - F_Delete_Previous : constant Form_Request_Code := Key_Max + 35; - F_Delete_Line : constant Form_Request_Code := Key_Max + 36; - F_Delete_Word : constant Form_Request_Code := Key_Max + 37; - F_Clear_EOL : constant Form_Request_Code := Key_Max + 38; - F_Clear_EOF : constant Form_Request_Code := Key_Max + 39; - F_Clear_Field : constant Form_Request_Code := Key_Max + 40; - F_Overlay_Mode : constant Form_Request_Code := Key_Max + 41; - F_Insert_Mode : constant Form_Request_Code := Key_Max + 42; - - -- Vertical Scrolling - F_ScrollForward_Line : constant Form_Request_Code := Key_Max + 43; - F_ScrollBackward_Line : constant Form_Request_Code := Key_Max + 44; - F_ScrollForward_Page : constant Form_Request_Code := Key_Max + 45; - F_ScrollBackward_Page : constant Form_Request_Code := Key_Max + 46; - F_ScrollForward_HalfPage : constant Form_Request_Code := Key_Max + 47; - F_ScrollBackward_HalfPage : constant Form_Request_Code := Key_Max + 48; - - -- Horizontal Scrolling - F_HScrollForward_Char : constant Form_Request_Code := Key_Max + 49; - F_HScrollBackward_Char : constant Form_Request_Code := Key_Max + 50; - F_HScrollForward_Line : constant Form_Request_Code := Key_Max + 51; - F_HScrollBackward_Line : constant Form_Request_Code := Key_Max + 52; - F_HScrollForward_HalfLine : constant Form_Request_Code := Key_Max + 53; - F_HScrollBackward_HalfLine : constant Form_Request_Code := Key_Max + 54; - - F_Validate_Field : constant Form_Request_Code := Key_Max + 55; - F_Next_Choice : constant Form_Request_Code := Key_Max + 56; - F_Previous_Choice : constant Form_Request_Code := Key_Max + 57; - - -- For those who like the old 'C' style request names - REQ_NEXT_PAGE : Form_Request_Code renames F_Next_Page; - REQ_PREV_PAGE : Form_Request_Code renames F_Previous_Page; - REQ_FIRST_PAGE : Form_Request_Code renames F_First_Page; - REQ_LAST_PAGE : Form_Request_Code renames F_Last_Page; - - REQ_NEXT_FIELD : Form_Request_Code renames F_Next_Field; - REQ_PREV_FIELD : Form_Request_Code renames F_Previous_Field; - REQ_FIRST_FIELD : Form_Request_Code renames F_First_Field; - REQ_LAST_FIELD : Form_Request_Code renames F_Last_Field; - REQ_SNEXT_FIELD : Form_Request_Code renames F_Sorted_Next_Field; - REQ_SPREV_FIELD : Form_Request_Code renames F_Sorted_Previous_Field; - REQ_SFIRST_FIELD : Form_Request_Code renames F_Sorted_First_Field; - REQ_SLAST_FIELD : Form_Request_Code renames F_Sorted_Last_Field; - REQ_LEFT_FIELD : Form_Request_Code renames F_Left_Field; - REQ_RIGHT_FIELD : Form_Request_Code renames F_Right_Field; - REQ_UP_FIELD : Form_Request_Code renames F_Up_Field; - REQ_DOWN_FIELD : Form_Request_Code renames F_Down_Field; - - REQ_NEXT_CHAR : Form_Request_Code renames F_Next_Char; - REQ_PREV_CHAR : Form_Request_Code renames F_Previous_Char; - REQ_NEXT_LINE : Form_Request_Code renames F_Next_Line; - REQ_PREV_LINE : Form_Request_Code renames F_Previous_Line; - REQ_NEXT_WORD : Form_Request_Code renames F_Next_Word; - REQ_PREV_WORD : Form_Request_Code renames F_Previous_Word; - REQ_BEG_FIELD : Form_Request_Code renames F_Begin_Field; - REQ_END_FIELD : Form_Request_Code renames F_End_Field; - REQ_BEG_LINE : Form_Request_Code renames F_Begin_Line; - REQ_END_LINE : Form_Request_Code renames F_End_Line; - REQ_LEFT_CHAR : Form_Request_Code renames F_Left_Char; - REQ_RIGHT_CHAR : Form_Request_Code renames F_Right_Char; - REQ_UP_CHAR : Form_Request_Code renames F_Up_Char; - REQ_DOWN_CHAR : Form_Request_Code renames F_Down_Char; - - REQ_NEW_LINE : Form_Request_Code renames F_New_Line; - REQ_INS_CHAR : Form_Request_Code renames F_Insert_Char; - REQ_INS_LINE : Form_Request_Code renames F_Insert_Line; - REQ_DEL_CHAR : Form_Request_Code renames F_Delete_Char; - REQ_DEL_PREV : Form_Request_Code renames F_Delete_Previous; - REQ_DEL_LINE : Form_Request_Code renames F_Delete_Line; - REQ_DEL_WORD : Form_Request_Code renames F_Delete_Word; - REQ_CLR_EOL : Form_Request_Code renames F_Clear_EOL; - REQ_CLR_EOF : Form_Request_Code renames F_Clear_EOF; - REQ_CLR_FIELD : Form_Request_Code renames F_Clear_Field; - REQ_OVL_MODE : Form_Request_Code renames F_Overlay_Mode; - REQ_INS_MODE : Form_Request_Code renames F_Insert_Mode; - - REQ_SCR_FLINE : Form_Request_Code renames F_ScrollForward_Line; - REQ_SCR_BLINE : Form_Request_Code renames F_ScrollBackward_Line; - REQ_SCR_FPAGE : Form_Request_Code renames F_ScrollForward_Page; - REQ_SCR_BPAGE : Form_Request_Code renames F_ScrollBackward_Page; - REQ_SCR_FHPAGE : Form_Request_Code renames F_ScrollForward_HalfPage; - REQ_SCR_BHPAGE : Form_Request_Code renames F_ScrollBackward_HalfPage; - - REQ_SCR_FCHAR : Form_Request_Code renames F_HScrollForward_Char; - REQ_SCR_BCHAR : Form_Request_Code renames F_HScrollBackward_Char; - REQ_SCR_HFLINE : Form_Request_Code renames F_HScrollForward_Line; - REQ_SCR_HBLINE : Form_Request_Code renames F_HScrollBackward_Line; - REQ_SCR_HFHALF : Form_Request_Code renames F_HScrollForward_HalfLine; - REQ_SCR_HBHALF : Form_Request_Code renames F_HScrollBackward_HalfLine; - - REQ_VALIDATION : Form_Request_Code renames F_Validate_Field; - REQ_NEXT_CHOICE : Form_Request_Code renames F_Next_Choice; - REQ_PREV_CHOICE : Form_Request_Code renames F_Previous_Choice; - - - procedure Request_Name (Key : in Form_Request_Code; - Name : out String); - - function Request_Name (Key : Form_Request_Code) return String; - -- Same as function - pragma Inline (Request_Name); - - ------------------ - -- Exceptions -- - ------------------ - Form_Exception : exception; - - -- MANPAGE(`form_field_new.3x') - - -- ANCHOR(`new_field()',`Create') - function Create (Height : Line_Count; - Width : Column_Count; - Top : Line_Position; - Left : Column_Position; - Off_Screen : Natural := 0; - More_Buffers : Buffer_Number := Buffer_Number'First) - return Field; - -- AKA - -- An overloaded Create is defined later. Pragma Inline appears there. - - -- ANCHOR(`new_field()',`New_Field') - function New_Field (Height : Line_Count; - Width : Column_Count; - Top : Line_Position; - Left : Column_Position; - Off_Screen : Natural := 0; - More_Buffers : Buffer_Number := Buffer_Number'First) - return Field renames Create; - -- AKA - pragma Inline (New_Field); - - -- ANCHOR(`free_field()',`Delete') - procedure Delete (Fld : in out Field); - -- AKA - -- Reset Fld to Null_Field - -- An overloaded Delete is defined later. Pragma Inline appears there. - - -- ANCHOR(`dup_field()',`Duplicate') - function Duplicate (Fld : Field; - Top : Line_Position; - Left : Column_Position) return Field; - -- AKA - pragma Inline (Duplicate); - - -- ANCHOR(`link_field()',`Link') - function Link (Fld : Field; - Top : Line_Position; - Left : Column_Position) return Field; - -- AKA - pragma Inline (Link); - - -- MANPAGE(`form_field_just.3x') - - -- ANCHOR(`set_field_just()',`Set_Justification') - procedure Set_Justification (Fld : in Field; - Just : in Field_Justification := None); - -- AKA - pragma Inline (Set_Justification); - - -- ANCHOR(`field_just()',`Get_Justification') - function Get_Justification (Fld : Field) return Field_Justification; - -- AKA - pragma Inline (Get_Justification); - - -- MANPAGE(`form_field_buffer.3x') - - -- ANCHOR(`set_field_buffer()',`Set_Buffer') - procedure Set_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First; - Str : in String); - -- AKA - -- Not inlined - - -- ANCHOR(`field_buffer()',`Get_Buffer') - procedure Get_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First; - Str : out String); - -- AKA - - function Get_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First) return String; - -- AKA - -- Same but as function - pragma Inline (Get_Buffer); - - -- ANCHOR(`set_field_status()',`Set_Status') - procedure Set_Status (Fld : in Field; - Status : in Boolean := True); - -- AKA - pragma Inline (Set_Status); - - -- ANCHOR(`field_status()',`Changed') - function Changed (Fld : Field) return Boolean; - -- AKA - pragma Inline (Changed); - - -- ANCHOR(`set_field_max()',`Set_Maximum_Size') - procedure Set_Maximum_Size (Fld : in Field; - Max : in Natural := 0); - -- AKA - pragma Inline (Set_Maximum_Size); - - -- MANPAGE(`form_field_opts.3x') - - -- ANCHOR(`set_field_opts()',`Set_Options') - procedure Set_Options (Fld : in Field; - Options : in Field_Option_Set); - -- AKA - -- An overloaded version is defined later. Pragma Inline appears there - - -- ANCHOR(`field_opts_on()',`Switch_Options') - procedure Switch_Options (Fld : in Field; - Options : in Field_Option_Set; - On : Boolean := True); - -- AKA - -- ALIAS(`field_opts_off()') - -- An overloaded version is defined later. Pragma Inline appears there - - -- ANCHOR(`field_opts()',`Get_Options') - procedure Get_Options (Fld : in Field; - Options : out Field_Option_Set); - -- AKA - - -- ANCHOR(`field_opts()',`Get_Options') - function Get_Options (Fld : Field := Null_Field) - return Field_Option_Set; - -- AKA - -- An overloaded version is defined later. Pragma Inline appears there - - -- MANPAGE(`form_field_attributes.3x') - - -- ANCHOR(`set_field_fore()',`Set_Foreground') - procedure Set_Foreground - (Fld : in Field; - Fore : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Foreground); - - -- ANCHOR(`field_fore()',`Foreground') - procedure Foreground (Fld : in Field; - Fore : out Character_Attribute_Set); - -- AKA - - -- ANCHOR(`field_fore()',`Foreground') - procedure Foreground (Fld : in Field; - Fore : out Character_Attribute_Set; - Color : out Color_Pair); - -- AKA - pragma Inline (Foreground); - - -- ANCHOR(`set_field_back()',`Set_Background') - procedure Set_Background - (Fld : in Field; - Back : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Background); - - -- ANCHOR(`field_back()',`Background') - procedure Background (Fld : in Field; - Back : out Character_Attribute_Set); - -- AKA - - -- ANCHOR(`field_back()',`Background') - procedure Background (Fld : in Field; - Back : out Character_Attribute_Set; - Color : out Color_Pair); - -- AKA - pragma Inline (Background); - - -- ANCHOR(`set_field_pad()',`Set_Pad_Character') - procedure Set_Pad_Character (Fld : in Field; - Pad : in Character := Space); - -- AKA - pragma Inline (Set_Pad_Character); - - -- ANCHOR(`field_pad()',`Pad_Character') - procedure Pad_Character (Fld : in Field; - Pad : out Character); - -- AKA - pragma Inline (Pad_Character); - - -- MANPAGE(`form_field_info.3x') - - -- ANCHOR(`field_info()',`Info') - procedure Info (Fld : in Field; - Lines : out Line_Count; - Columns : out Column_Count; - First_Row : out Line_Position; - First_Column : out Column_Position; - Off_Screen : out Natural; - Additional_Buffers : out Buffer_Number); - -- AKA - pragma Inline (Info); - - -- ANCHOR(`dynamic_field_info()',`Dynamic_Info') - procedure Dynamic_Info (Fld : in Field; - Lines : out Line_Count; - Columns : out Column_Count; - Max : out Natural); - -- AKA - pragma Inline (Dynamic_Info); - - -- MANPAGE(`form_win.3x') - - -- ANCHOR(`set_form_win()',`Set_Window') - procedure Set_Window (Frm : in Form; - Win : in Window); - -- AKA - pragma Inline (Set_Window); - - -- ANCHOR(`form_win()',`Get_Window') - function Get_Window (Frm : Form) return Window; - -- AKA - pragma Inline (Get_Window); - - -- ANCHOR(`set_form_sub()',`Set_Sub_Window') - procedure Set_Sub_Window (Frm : in Form; - Win : in Window); - -- AKA - pragma Inline (Set_Sub_Window); - - -- ANCHOR(`form_sub()',`Get_Sub_Window') - function Get_Sub_Window (Frm : Form) return Window; - -- AKA - pragma Inline (Get_Sub_Window); - - -- ANCHOR(`scale_form()',`Scale') - procedure Scale (Frm : in Form; - Lines : out Line_Count; - Columns : out Column_Count); - -- AKA - pragma Inline (Scale); - - -- MANPAGE(`form_hook.3x') - - type Form_Hook_Function is access procedure (Frm : in Form); - pragma Convention (C, Form_Hook_Function); - - -- ANCHOR(`set_field_init()',`Set_Field_Init_Hook') - procedure Set_Field_Init_Hook (Frm : in Form; - Proc : in Form_Hook_Function); - -- AKA - pragma Inline (Set_Field_Init_Hook); - - -- ANCHOR(`set_field_term()',`Set_Field_Term_Hook') - procedure Set_Field_Term_Hook (Frm : in Form; - Proc : in Form_Hook_Function); - -- AKA - pragma Inline (Set_Field_Term_Hook); - - -- ANCHOR(`set_form_init()',`Set_Form_Init_Hook') - procedure Set_Form_Init_Hook (Frm : in Form; - Proc : in Form_Hook_Function); - -- AKA - pragma Inline (Set_Form_Init_Hook); - - -- ANCHOR(`set_form_term()',`Set_Form_Term_Hook') - procedure Set_Form_Term_Hook (Frm : in Form; - Proc : in Form_Hook_Function); - -- AKA - pragma Inline (Set_Form_Term_Hook); - - -- ANCHOR(`field_init()',`Get_Field_Init_Hook') - function Get_Field_Init_Hook (Frm : Form) return Form_Hook_Function; - -- AKA - pragma Import (C, Get_Field_Init_Hook, "field_init"); - - -- ANCHOR(`field_term()',`Get_Field_Term_Hook') - function Get_Field_Term_Hook (Frm : Form) return Form_Hook_Function; - -- AKA - pragma Import (C, Get_Field_Term_Hook, "field_term"); - - -- ANCHOR(`form_init()',`Get_Form_Init_Hook') - function Get_Form_Init_Hook (Frm : Form) return Form_Hook_Function; - -- AKA - pragma Import (C, Get_Form_Init_Hook, "form_init"); - - -- ANCHOR(`form_term()',`Get_Form_Term_Hook') - function Get_Form_Term_Hook (Frm : Form) return Form_Hook_Function; - -- AKA - pragma Import (C, Get_Form_Term_Hook, "form_term"); - - -- MANPAGE(`form_field.3x') - - -- ANCHOR(`set_form_fields()',`Redefine') - procedure Redefine (Frm : in Form; - Flds : in Field_Array_Access); - -- AKA - pragma Inline (Redefine); - - -- ANCHOR(`set_form_fields()',`Set_Fields') - procedure Set_Fields (Frm : in Form; - Flds : in Field_Array_Access) renames Redefine; - -- AKA - pragma Inline (Set_Fields); - - -- ANCHOR(`form_fields()',`Fields') - function Fields (Frm : Form; - Index : Positive) return Field; - -- AKA - pragma Inline (Fields); - - -- ANCHOR(`field_count()',`Field_Count') - function Field_Count (Frm : Form) return Natural; - -- AKA - pragma Inline (Field_Count); - - -- ANCHOR(`move_field()',`Move') - procedure Move (Fld : in Field; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - pragma Inline (Move); - - -- MANPAGE(`form_new.3x') - - -- ANCHOR(`new_form()',`Create') - function Create (Fields : Field_Array_Access) return Form; - -- AKA - pragma Inline (Create); - - -- ANCHOR(`new_form()',`New_Form') - function New_Form (Fields : Field_Array_Access) return Form - renames Create; - -- AKA - pragma Inline (New_Form); - - -- ANCHOR(`free_form()',`Delete') - procedure Delete (Frm : in out Form); - -- AKA - -- Reset Frm to Null_Form - pragma Inline (Delete); - - -- MANPAGE(`form_opts.3x') - - -- ANCHOR(`set_form_opts()',`Set_Options') - procedure Set_Options (Frm : in Form; - Options : in Form_Option_Set); - -- AKA - pragma Inline (Set_Options); - - -- ANCHOR(`form_opts_on()',`Switch_Options') - procedure Switch_Options (Frm : in Form; - Options : in Form_Option_Set; - On : Boolean := True); - -- AKA - -- ALIAS(`form_opts_off()') - pragma Inline (Switch_Options); - - -- ANCHOR(`form_opts()',`Get_Options') - procedure Get_Options (Frm : in Form; - Options : out Form_Option_Set); - -- AKA - - -- ANCHOR(`form_opts()',`Get_Options') - function Get_Options (Frm : Form := Null_Form) return Form_Option_Set; - -- AKA - pragma Inline (Get_Options); - - -- MANPAGE(`form_post.3x') - - -- ANCHOR(`post_form()',`Post') - procedure Post (Frm : in Form; - Post : in Boolean := True); - -- AKA - -- ALIAS(`unpost_form()') - pragma Inline (Post); - - -- MANPAGE(`form_cursor.3x') - - -- ANCHOR(`pos_form_cursor()',`Position_Cursor') - procedure Position_Cursor (Frm : Form); - -- AKA - pragma Inline (Position_Cursor); - - -- MANPAGE(`form_data.3x') - - -- ANCHOR(`data_ahead()',`Data_Ahead') - function Data_Ahead (Frm : Form) return Boolean; - -- AKA - pragma Inline (Data_Ahead); - - -- ANCHOR(`data_behind()',`Data_Behind') - function Data_Behind (Frm : Form) return Boolean; - -- AKA - pragma Inline (Data_Behind); - - -- MANPAGE(`form_driver.3x') - - type Driver_Result is (Form_Ok, - Request_Denied, - Unknown_Request, - Invalid_Field); - - -- ANCHOR(`form_driver()',`Driver') - function Driver (Frm : Form; - Key : Key_Code) return Driver_Result; - -- AKA - -- Driver not inlined - - -- MANPAGE(`form_page.3x') - - type Page_Number is new Natural; - - -- ANCHOR(`set_current_field()',`Set_Current') - procedure Set_Current (Frm : in Form; - Fld : in Field); - -- AKA - pragma Inline (Set_Current); - - -- ANCHOR(`current_field()',`Current') - function Current (Frm : in Form) return Field; - -- AKA - pragma Inline (Current); - - -- ANCHOR(`set_form_page()',`Set_Page') - procedure Set_Page (Frm : in Form; - Page : in Page_Number := Page_Number'First); - -- AKA - pragma Inline (Set_Page); - - -- ANCHOR(`form_page()',`Page') - function Page (Frm : Form) return Page_Number; - -- AKA - pragma Inline (Page); - - -- ANCHOR(`field_index()',`Get_Index') - function Get_Index (Fld : Field) return Positive; - -- AKA - -- Please note that in this binding we start the numbering of fields - -- with 1. So this is number is one more than you get from the low - -- level call. - pragma Inline (Get_Index); - - -- MANPAGE(`form_new_page.3x') - - -- ANCHOR(`set_new_page()',`Set_New_Page') - procedure Set_New_Page (Fld : in Field; - New_Page : in Boolean := True); - -- AKA - pragma Inline (Set_New_Page); - - -- ANCHOR(`new_page()',`Is_New_Page') - function Is_New_Page (Fld : Field) return Boolean; - -- AKA - pragma Inline (Is_New_Page); - - -- MANPAGE(`form_requestname.3x') - -- Not Implemented: form_request_name, form_request_by_name - ------------------------------------------------------------------------------- -private - type Field is new System.Storage_Elements.Integer_Address; - type Form is new System.Storage_Elements.Integer_Address; - - Null_Field : constant Field := 0; - Null_Form : constant Form := 0; - -end Terminal_Interface.Curses.Forms; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-item_user_data.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-item_user_data.ads.m4 deleted file mode 100644 index 6a5ab8096b..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-item_user_data.ads.m4 +++ /dev/null @@ -1,75 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-menus-item_user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menus.Item_User_Data -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -generic - type User is limited private; - type User_Access is access User; -package Terminal_Interface.Curses.Menus.Item_User_Data is - pragma Preelaborate (Terminal_Interface.Curses.Menus.Item_User_Data); - - -- The binding uses the same user pointer for menu items - -- as the low level C implementation. So you can safely - -- read or write the user pointer also with the C routines - -- - -- MANPAGE(`mitem_userptr.3x') - - -- ANCHOR(`set_item_userptr',`Set_User_Data') - procedure Set_User_Data (Itm : in Item; - Data : in User_Access); - -- AKA - pragma Inline (Set_User_Data); - - -- ANCHOR(`item_userptr',`Get_User_Data') - procedure Get_User_Data (Itm : in Item; - Data : out User_Access); - -- AKA - - -- ANCHOR(`item_userptr',`Get_User_Data') - function Get_User_Data (Itm : in Item) return User_Access; - -- AKA - -- Same as function - pragma Inline (Get_User_Data); - -end Terminal_Interface.Curses.Menus.Item_User_Data; - diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-menu_user_data.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-menu_user_data.ads.m4 deleted file mode 100644 index 696149b987..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus-menu_user_data.ads.m4 +++ /dev/null @@ -1,70 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-menus-menu_user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menus.Menu_User_Data -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -generic - type User is limited private; - type User_Access is access User; -package Terminal_Interface.Curses.Menus.Menu_User_Data is - pragma Preelaborate (Terminal_Interface.Curses.Menus.Menu_User_Data); - - -- MANPAGE(`menu_userptr.3x') - - -- ANCHOR(`set_menu_userptr',`Set_User_Data') - procedure Set_User_Data (Men : in Menu; - Data : in User_Access); - -- AKA - pragma Inline (Set_User_Data); - - -- ANCHOR(`menu_userptr',`Get_User_Data') - procedure Get_User_Data (Men : in Menu; - Data : out User_Access); - -- AKA - - -- ANCHOR(`menu_userptr',`Get_User_Data') - function Get_User_Data (Men : in Menu) return User_Access; - -- AKA - -- Same as function - pragma Inline (Get_User_Data); - -end Terminal_Interface.Curses.Menus.Menu_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus.ads.m4 deleted file mode 100644 index 6faa0539f9..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-menus.ads.m4 +++ /dev/null @@ -1,603 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-menus__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menu -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.24 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -include(`Menu_Base_Defs') -with System; -with Ada.Characters.Latin_1; - -package Terminal_Interface.Curses.Menus is - pragma Preelaborate (Terminal_Interface.Curses.Menus); -include(`Menu_Linker_Options')dnl -include(`Linker_Options') - Space : Character renames Ada.Characters.Latin_1.Space; - - type Item is private; - type Menu is private; - - --------------------------- - -- Interface constants -- - --------------------------- - Null_Item : constant Item; - Null_Menu : constant Menu; - - subtype Menu_Request_Code is Key_Code - range (Key_Max + 1) .. (Key_Max + 17); - - -- The prefix M_ stands for "Menu Request" - M_Left_Item : constant Menu_Request_Code := Key_Max + 1; - M_Right_Item : constant Menu_Request_Code := Key_Max + 2; - M_Up_Item : constant Menu_Request_Code := Key_Max + 3; - M_Down_Item : constant Menu_Request_Code := Key_Max + 4; - M_ScrollUp_Line : constant Menu_Request_Code := Key_Max + 5; - M_ScrollDown_Line : constant Menu_Request_Code := Key_Max + 6; - M_ScrollDown_Page : constant Menu_Request_Code := Key_Max + 7; - M_ScrollUp_Page : constant Menu_Request_Code := Key_Max + 8; - M_First_Item : constant Menu_Request_Code := Key_Max + 9; - M_Last_Item : constant Menu_Request_Code := Key_Max + 10; - M_Next_Item : constant Menu_Request_Code := Key_Max + 11; - M_Previous_Item : constant Menu_Request_Code := Key_Max + 12; - M_Toggle_Item : constant Menu_Request_Code := Key_Max + 13; - M_Clear_Pattern : constant Menu_Request_Code := Key_Max + 14; - M_Back_Pattern : constant Menu_Request_Code := Key_Max + 15; - M_Next_Match : constant Menu_Request_Code := Key_Max + 16; - M_Previous_Match : constant Menu_Request_Code := Key_Max + 17; - - -- For those who like the old 'C' names for the request codes - REQ_LEFT_ITEM : Menu_Request_Code renames M_Left_Item; - REQ_RIGHT_ITEM : Menu_Request_Code renames M_Right_Item; - REQ_UP_ITEM : Menu_Request_Code renames M_Up_Item; - REQ_DOWN_ITEM : Menu_Request_Code renames M_Down_Item; - REQ_SCR_ULINE : Menu_Request_Code renames M_ScrollUp_Line; - REQ_SCR_DLINE : Menu_Request_Code renames M_ScrollDown_Line; - REQ_SCR_DPAGE : Menu_Request_Code renames M_ScrollDown_Page; - REQ_SCR_UPAGE : Menu_Request_Code renames M_ScrollUp_Page; - REQ_FIRST_ITEM : Menu_Request_Code renames M_First_Item; - REQ_LAST_ITEM : Menu_Request_Code renames M_Last_Item; - REQ_NEXT_ITEM : Menu_Request_Code renames M_Next_Item; - REQ_PREV_ITEM : Menu_Request_Code renames M_Previous_Item; - REQ_TOGGLE_ITEM : Menu_Request_Code renames M_Toggle_Item; - REQ_CLEAR_PATTERN : Menu_Request_Code renames M_Clear_Pattern; - REQ_BACK_PATTERN : Menu_Request_Code renames M_Back_Pattern; - REQ_NEXT_MATCH : Menu_Request_Code renames M_Next_Match; - REQ_PREV_MATCH : Menu_Request_Code renames M_Previous_Match; - - procedure Request_Name (Key : in Menu_Request_Code; - Name : out String); - - function Request_Name (Key : Menu_Request_Code) return String; - -- Same as function - - ------------------ - -- Exceptions -- - ------------------ - - Menu_Exception : exception; - -- - -- Menu options - -- - pragma Warnings (Off); -include(`Menu_Opt_Rep')dnl - - pragma Warnings (On); - - function Default_Menu_Options return Menu_Option_Set; - -- Initial default options for a menu. - pragma Inline (Default_Menu_Options); - -- - -- Item options - -- - pragma Warnings (Off); -include(`Item_Rep')dnl - - pragma Warnings (On); - - function Default_Item_Options return Item_Option_Set; - -- Initial default options for an item. - pragma Inline (Default_Item_Options); - - -- - -- Item Array - -- - type Item_Array is array (Positive range <>) of aliased Item; - pragma Convention (C, Item_Array); - - type Item_Array_Access is access Item_Array; - - procedure Free (IA : in out Item_Array_Access; - Free_Items : Boolean := False); - -- Release the memory for an allocated item array - -- If Free_Items is True, call Delete() for all the items in - -- the array. - - -- MANPAGE(`mitem_new.3x') - - -- ANCHOR(`new_item()',`Create') - function Create (Name : String; - Description : String := "") return Item; - -- AKA - -- Not inlined. - - -- ANCHOR(`new_item()',`New_Item') - function New_Item (Name : String; - Description : String := "") return Item - renames Create; - -- AKA - - -- ANCHOR(`free_item()',`Delete') - procedure Delete (Itm : in out Item); - -- AKA - -- Resets Itm to Null_Item - - -- MANPAGE(`mitem_value.3x') - - -- ANCHOR(`set_item_value()',`Set_Value') - procedure Set_Value (Itm : in Item; - Value : in Boolean := True); - -- AKA - pragma Inline (Set_Value); - - -- ANCHOR(`item_value()',`Value') - function Value (Itm : Item) return Boolean; - -- AKA - pragma Inline (Value); - - -- MANPAGE(`mitem_visible.3x') - - -- ANCHOR(`item_visible()',`Visible') - function Visible (Itm : Item) return Boolean; - -- AKA - pragma Inline (Visible); - - -- MANPAGE(`mitem_opts.3x') - - -- ANCHOR(`set_item_opts()',`Set_Options') - procedure Set_Options (Itm : in Item; - Options : in Item_Option_Set); - -- AKA - -- An overloaded Set_Options is defined later. Pragma Inline appears there - - -- ANCHOR(`item_opts_on()',`Switch_Options') - procedure Switch_Options (Itm : in Item; - Options : in Item_Option_Set; - On : Boolean := True); - -- AKA - -- ALIAS(`item_opts_off()') - -- An overloaded Switch_Options is defined later. - -- Pragma Inline appears there - - -- ANCHOR(`item_opts()',`Get_Options') - procedure Get_Options (Itm : in Item; - Options : out Item_Option_Set); - -- AKA - - -- ANCHOR(`item_opts()',`Get_Options') - function Get_Options (Itm : Item := Null_Item) return Item_Option_Set; - -- AKA - -- An overloaded Get_Options is defined later. Pragma Inline appears there - - -- MANPAGE(`mitem_name.3x') - - -- ANCHOR(`item_name()',`Name') - procedure Name (Itm : in Item; - Name : out String); - -- AKA - function Name (Itm : Item) return String; - -- AKA - -- Implemented as function - pragma Inline (Name); - - -- ANCHOR(`item_description();',`Description') - procedure Description (Itm : in Item; - Description : out String); - -- AKA - - function Description (Itm : Item) return String; - -- AKA - -- Implemented as function - pragma Inline (Description); - - -- MANPAGE(`mitem_current.3x') - - -- ANCHOR(`set_current_item()',`Set_Current') - procedure Set_Current (Men : in Menu; - Itm : in Item); - -- AKA - pragma Inline (Set_Current); - - -- ANCHOR(`current_item()',`Current') - function Current (Men : Menu) return Item; - -- AKA - pragma Inline (Current); - - -- ANCHOR(`set_top_row()',`Set_Top_Row') - procedure Set_Top_Row (Men : in Menu; - Line : in Line_Position); - -- AKA - pragma Inline (Set_Top_Row); - - -- ANCHOR(`top_row()',`Top_Row') - function Top_Row (Men : Menu) return Line_Position; - -- AKA - pragma Inline (Top_Row); - - -- ANCHOR(`item_index()',`Get_Index') - function Get_Index (Itm : Item) return Positive; - -- AKA - -- Please note that in this binding we start the numbering of items - -- with 1. So this is number is one more than you get from the low - -- level call. - pragma Inline (Get_Index); - - -- MANPAGE(`menu_post.3x') - - -- ANCHOR(`post_menu()',`Post') - procedure Post (Men : in Menu; - Post : in Boolean := True); - -- AKA - -- ALIAS(`unpost_menu()') - pragma Inline (Post); - - -- MANPAGE(`menu_opts.3x') - - -- ANCHOR(`set_menu_opts()',`Set_Options') - procedure Set_Options (Men : in Menu; - Options : in Menu_Option_Set); - -- AKA - pragma Inline (Set_Options); - - -- ANCHOR(`menu_opts_on()',`Switch_Options') - procedure Switch_Options (Men : in Menu; - Options : in Menu_Option_Set; - On : Boolean := True); - -- AKA - -- ALIAS(`menu_opts_off()') - pragma Inline (Switch_Options); - - -- ANCHOR(`menu_opts()',`Get_Options') - procedure Get_Options (Men : in Menu; - Options : out Menu_Option_Set); - -- AKA - - -- ANCHOR(`menu_opts()',`Get_Options') - function Get_Options (Men : Menu := Null_Menu) return Menu_Option_Set; - -- AKA - pragma Inline (Get_Options); - - -- MANPAGE(`menu_win.3x') - - -- ANCHOR(`set_menu_win()',`Set_Window') - procedure Set_Window (Men : in Menu; - Win : in Window); - -- AKA - pragma Inline (Set_Window); - - -- ANCHOR(`menu_win()',`Get_Window') - function Get_Window (Men : Menu) return Window; - -- AKA - pragma Inline (Get_Window); - - -- ANCHOR(`set_menu_sub()',`Set_Sub_Window') - procedure Set_Sub_Window (Men : in Menu; - Win : in Window); - -- AKA - pragma Inline (Set_Sub_Window); - - -- ANCHOR(`menu_sub()',`Get_Sub_Window') - function Get_Sub_Window (Men : Menu) return Window; - -- AKA - pragma Inline (Get_Sub_Window); - - -- ANCHOR(`scale_menu()',`Scale') - procedure Scale (Men : in Menu; - Lines : out Line_Count; - Columns : out Column_Count); - -- AKA - pragma Inline (Scale); - - -- MANPAGE(`menu_cursor.3x') - - -- ANCHOR(`pos_menu_cursor()',`Position_Cursor') - procedure Position_Cursor (Men : Menu); - -- AKA - pragma Inline (Position_Cursor); - - -- MANPAGE(`menu_mark.3x') - - -- ANCHOR(`set_menu_mark()',`Set_Mark') - procedure Set_Mark (Men : in Menu; - Mark : in String); - -- AKA - pragma Inline (Set_Mark); - - -- ANCHOR(`menu_mark()',`Mark') - procedure Mark (Men : in Menu; - Mark : out String); - -- AKA - - function Mark (Men : Menu) return String; - -- AKA - -- Implemented as function - pragma Inline (Mark); - - -- MANPAGE(`menu_attribs.3x') - - -- ANCHOR(`set_menu_fore()',`Set_Foreground') - procedure Set_Foreground - (Men : in Menu; - Fore : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Foreground); - - -- ANCHOR(`menu_fore()',`Foreground') - procedure Foreground (Men : in Menu; - Fore : out Character_Attribute_Set); - -- AKA - - -- ANCHOR(`menu_fore()',`Foreground') - procedure Foreground (Men : in Menu; - Fore : out Character_Attribute_Set; - Color : out Color_Pair); - -- AKA - pragma Inline (Foreground); - - -- ANCHOR(`set_menu_back()',`Set_Background') - procedure Set_Background - (Men : in Menu; - Back : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Background); - - -- ANCHOR(`menu_back()',`Background') - procedure Background (Men : in Menu; - Back : out Character_Attribute_Set); - -- AKA - -- ANCHOR(`menu_back()',`Background') - - procedure Background (Men : in Menu; - Back : out Character_Attribute_Set; - Color : out Color_Pair); - -- AKA - pragma Inline (Background); - - -- ANCHOR(`set_menu_grey()',`Set_Grey') - procedure Set_Grey - (Men : in Menu; - Grey : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Grey); - - -- ANCHOR(`menu_grey()',`Grey') - procedure Grey (Men : in Menu; - Grey : out Character_Attribute_Set); - -- AKA - - -- ANCHOR(`menu_grey()',`Grey') - procedure Grey - (Men : in Menu; - Grey : out Character_Attribute_Set; - Color : out Color_Pair); - -- AKA - pragma Inline (Grey); - - -- ANCHOR(`set_menu_pad()',`Set_Pad_Character') - procedure Set_Pad_Character (Men : in Menu; - Pad : in Character := Space); - -- AKA - pragma Inline (Set_Pad_Character); - - -- ANCHOR(`menu_pad()',`Pad_Character') - procedure Pad_Character (Men : in Menu; - Pad : out Character); - -- AKA - pragma Inline (Pad_Character); - - -- MANPAGE(`menu_spacing.3x') - - -- ANCHOR(`set_menu_spacing()',`Set_Spacing') - procedure Set_Spacing (Men : in Menu; - Descr : in Column_Position := 0; - Row : in Line_Position := 0; - Col : in Column_Position := 0); - -- AKA - pragma Inline (Set_Spacing); - - -- ANCHOR(`menu_spacing()',`Spacing') - procedure Spacing (Men : in Menu; - Descr : out Column_Position; - Row : out Line_Position; - Col : out Column_Position); - -- AKA - pragma Inline (Spacing); - - -- MANPAGE(`menu_pattern.3x') - - -- ANCHOR(`set_menu_pattern()',`Set_Pattern') - function Set_Pattern (Men : Menu; - Text : String) return Boolean; - -- AKA - -- Return TRUE if the pattern matches, FALSE otherwise - pragma Inline (Set_Pattern); - - -- ANCHOR(`menu_pattern()',`Pattern') - procedure Pattern (Men : in Menu; - Text : out String); - -- AKA - pragma Inline (Pattern); - - -- MANPAGE(`menu_format.3x') - - -- ANCHOR(`set_menu_format()',`Set_Format') - procedure Set_Format (Men : in Menu; - Lines : in Line_Count; - Columns : in Column_Count); - -- Not implemented: 0 argument for Lines or Columns; - -- instead use Format to get the current sizes - -- The default format is 16 rows, 1 column. Calling - -- set_menu_format with a null menu pointer will change this - -- default. A zero row or column argument to set_menu_format - -- is interpreted as a request not to change the current - -- value. - -- AKA - pragma Inline (Set_Format); - - -- ANCHOR(`menu_format()',`Format') - procedure Format (Men : in Menu; - Lines : out Line_Count; - Columns : out Column_Count); - -- AKA - pragma Inline (Format); - - -- MANPAGE(`menu_hook.3x') - - type Menu_Hook_Function is access procedure (Men : in Menu); - pragma Convention (C, Menu_Hook_Function); - - -- ANCHOR(`set_item_init()',`Set_Item_Init_Hook') - procedure Set_Item_Init_Hook (Men : in Menu; - Proc : in Menu_Hook_Function); - -- AKA - pragma Inline (Set_Item_Init_Hook); - - -- ANCHOR(`set_item_term()',`Set_Item_Term_Hook') - procedure Set_Item_Term_Hook (Men : in Menu; - Proc : in Menu_Hook_Function); - -- AKA - pragma Inline (Set_Item_Term_Hook); - - -- ANCHOR(`set_menu_init()',`Set_Menu_Init_Hook') - procedure Set_Menu_Init_Hook (Men : in Menu; - Proc : in Menu_Hook_Function); - -- AKA - pragma Inline (Set_Menu_Init_Hook); - - -- ANCHOR(`set_menu_term()',`Set_Menu_Term_Hook') - procedure Set_Menu_Term_Hook (Men : in Menu; - Proc : in Menu_Hook_Function); - -- AKA - pragma Inline (Set_Menu_Term_Hook); - - -- ANCHOR(`item_init()',`Get_Item_Init_Hook') - function Get_Item_Init_Hook (Men : Menu) return Menu_Hook_Function; - -- AKA - pragma Inline (Get_Item_Init_Hook); - - -- ANCHOR(`item_term()',`Get_Item_Term_Hook') - function Get_Item_Term_Hook (Men : Menu) return Menu_Hook_Function; - -- AKA - pragma Inline (Get_Item_Term_Hook); - - -- ANCHOR(`menu_init()',`Get_Menu_Init_Hook') - function Get_Menu_Init_Hook (Men : Menu) return Menu_Hook_Function; - -- AKA - pragma Inline (Get_Menu_Init_Hook); - - -- ANCHOR(`menu_term()',`Get_Menu_Term_Hook') - function Get_Menu_Term_Hook (Men : Menu) return Menu_Hook_Function; - -- AKA - pragma Inline (Get_Menu_Term_Hook); - - -- MANPAGE(`menu_items.3x') - - -- ANCHOR(`set_menu_items()',`Redefine') - procedure Redefine (Men : in Menu; - Items : in Item_Array_Access); - -- AKA - pragma Inline (Redefine); - - procedure Set_Items (Men : in Menu; - Items : in Item_Array_Access) renames Redefine; - pragma Inline (Set_Items); - - -- ANCHOR(`menu_items()',`Items') - function Items (Men : Menu; - Index : Positive) return Item; - -- AKA - pragma Inline (Items); - - -- ANCHOR(`item_count()',`Item_Count') - function Item_Count (Men : Menu) return Natural; - -- AKA - pragma Inline (Item_Count); - - -- MANPAGE(`menu_new.3x') - - -- ANCHOR(`new_menu()',`Create') - function Create (Items : Item_Array_Access) return Menu; - -- AKA - -- Not inlined - - function New_Menu (Items : Item_Array_Access) return Menu renames Create; - - -- ANCHOR(`free_menu()',`Delete') - procedure Delete (Men : in out Menu); - -- AKA - -- Reset Men to Null_Menu - -- Not inlined - - -- MANPAGE(`menu_driver.3x') - - type Driver_Result is (Menu_Ok, - Request_Denied, - Unknown_Request, - No_Match); - - -- ANCHOR(`menu_driver()',`Driver') - function Driver (Men : Menu; - Key : Key_Code) return Driver_Result; - -- AKA - -- Driver is not inlined - - -- ANCHOR(`menu_requestname.3x') - -- Not Implemented: menu_request_name, menu_request_by_name -------------------------------------------------------------------------------- -private - type Item is new System.Storage_Elements.Integer_Address; - type Menu is new System.Storage_Elements.Integer_Address; - - Null_Item : constant Item := 0; - Null_Menu : constant Menu := 0; - -end Terminal_Interface.Curses.Menus; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-mouse.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-mouse.ads.m4 deleted file mode 100644 index bb9516f708..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-mouse.ads.m4 +++ /dev/null @@ -1,183 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-mouse__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Mouse -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.22 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -include(`Mouse_Base_Defs') -with System; - -package Terminal_Interface.Curses.Mouse is - pragma Preelaborate (Terminal_Interface.Curses.Mouse); - - -- MANPAGE(`curs_mouse.3x') - -- Please note, that in ncurses-1.9.9e documentation mouse support - -- is still marked as experimental. So also this binding will change - -- if the ncurses methods change. - -- - -- mouse_trafo, wmouse_trafo are implemented as Transform_Coordinates - -- in the parent package. - -- - -- Not implemented: - -- REPORT_MOUSE_POSITION (i.e. as a parameter to Register_Reportable_Event - -- or Start_Mouse) - type Event_Mask is private; - No_Events : constant Event_Mask; - All_Events : constant Event_Mask; - - type Mouse_Button is (Left, -- aka: Button 1 - Middle, -- aka: Button 2 - Right, -- aka: Button 3 - Button4, -- aka: Button 4 - Control, -- Control Key - Shift, -- Shift Key - Alt); -- ALT Key - - subtype Real_Buttons is Mouse_Button range Left .. Button4; - subtype Modifier_Keys is Mouse_Button range Control .. Alt; - - type Button_State is (Released, - Pressed, - Clicked, - Double_Clicked, - Triple_Clicked); - - type Button_States is array (Button_State) of Boolean; - pragma Pack (Button_States); - - All_Clicks : constant Button_States := (Clicked .. Triple_Clicked => True, - others => False); - All_States : constant Button_States := (others => True); - - type Mouse_Event is private; - - -- MANPAGE(`curs_mouse.3x') - - function Has_Mouse return Boolean; - -- Return true if a mouse device is supported, false otherwise. - - procedure Register_Reportable_Event - (Button : in Mouse_Button; - State : in Button_State; - Mask : in out Event_Mask); - -- Stores the event described by the button and the state in the mask. - -- Before you call this the first time, you should init the mask - -- with the Empty_Mask constant - pragma Inline (Register_Reportable_Event); - - procedure Register_Reportable_Events - (Button : in Mouse_Button; - State : in Button_States; - Mask : in out Event_Mask); - -- Register all events described by the Button and the State bitmap. - -- Before you call this the first time, you should init the mask - -- with the Empty_Mask constant - - -- ANCHOR(`mousemask()',`Start_Mouse') - -- There is one difference to mousmask(): we return the value of the - -- old mask, that means the event mask value before this call. - -- Not Implemented: The library version - -- returns a Mouse_Mask that tells which events are reported. - function Start_Mouse (Mask : Event_Mask := All_Events) - return Event_Mask; - -- AKA - pragma Inline (Start_Mouse); - - procedure End_Mouse (Mask : in Event_Mask := No_Events); - -- Terminates the mouse, restores the specified event mask - pragma Inline (End_Mouse); - - -- ANCHOR(`getmouse()',`Get_Mouse') - function Get_Mouse return Mouse_Event; - -- AKA - pragma Inline (Get_Mouse); - - procedure Get_Event (Event : in Mouse_Event; - Y : out Line_Position; - X : out Column_Position; - Button : out Mouse_Button; - State : out Button_State); - -- !!! Warning: X and Y are screen coordinates. Due to ripped of lines they - -- may not be identical to window coordinates. - -- Not Implemented: Get_Event only reports one event, the C library - -- version supports multiple events, e.g. {click-1, click-3} - pragma Inline (Get_Event); - - -- ANCHOR(`ungetmouse()',`Unget_Mouse') - procedure Unget_Mouse (Event : in Mouse_Event); - -- AKA - pragma Inline (Unget_Mouse); - - -- ANCHOR(`wenclose()',`Enclosed_In_Window') - function Enclosed_In_Window (Win : Window := Standard_Window; - Event : Mouse_Event) return Boolean; - -- AKA - -- But : use event instead of screen coordinates. - pragma Inline (Enclosed_In_Window); - - -- ANCHOR(`mouseinterval()',`Mouse_Interval') - function Mouse_Interval (Msec : Natural := 200) return Natural; - -- AKA - pragma Inline (Mouse_Interval); - -private - type Event_Mask is new Interfaces.C.unsigned_long; - - type Mouse_Event is - record - Id : Integer range Integer (Interfaces.C.short'First) .. - Integer (Interfaces.C.short'Last); - X, Y, Z : Integer range Integer (Interfaces.C.int'First) .. - Integer (Interfaces.C.int'Last); - Bstate : Event_Mask; - end record; - pragma Convention (C, Mouse_Event); - pragma Pack (Mouse_Event); - -include(`Mouse_Event_Rep') - Generation_Bit_Order : constant System.Bit_Order := System.M4_BIT_ORDER; - -- This constant may be different on your system. - -include(`Mouse_Events') - - No_Events : constant Event_Mask := 0; - All_Events : constant Event_Mask := ALL_MOUSE_EVENTS; - -end Terminal_Interface.Curses.Mouse; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels-user_data.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels-user_data.ads.m4 deleted file mode 100644 index e6def9b03b..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels-user_data.ads.m4 +++ /dev/null @@ -1,70 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-panels-user_data__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Panels.User_Data -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -generic - type User is limited private; - type User_Access is access all User; -package Terminal_Interface.Curses.Panels.User_Data is - pragma Preelaborate (Terminal_Interface.Curses.Panels.User_Data); - - -- MANPAGE(`panel.3x') - - -- ANCHOR(`set_panel_userptr',`Set_User_Data') - procedure Set_User_Data (Pan : in Panel; - Data : in User_Access); - -- AKA - pragma Inline (Set_User_Data); - - -- ANCHOR(`panel_userptr',`Get_User_Data') - procedure Get_User_Data (Pan : in Panel; - Data : out User_Access); - -- AKA - - -- ANCHOR(`panel_userptr',`Get_User_Data') - function Get_User_Data (Pan : in Panel) return User_Access; - -- AKA - -- Same as function - pragma Inline (Get_User_Data); - -end Terminal_Interface.Curses.Panels.User_Data; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels.ads.m4 deleted file mode 100644 index 71252180f4..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-panels.ads.m4 +++ /dev/null @@ -1,146 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-panels__ads.htm')dnl -include(M4MACRO)dnl ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Panels -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.17 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with System; - -package Terminal_Interface.Curses.Panels is - pragma Preelaborate (Terminal_Interface.Curses.Panels); -include(`Panel_Linker_Options')dnl -include(`Linker_Options') - type Panel is private; - - --------------------------- - -- Interface constants -- - --------------------------- - Null_Panel : constant Panel; - - ------------------- - -- Exceptions -- - ------------------- - - Panel_Exception : exception; - - -- MANPAGE(`panel.3x') - - -- ANCHOR(`new_panel()',`Create') - function Create (Win : Window) return Panel; - -- AKA - pragma Inline (Create); - - -- ANCHOR(`new_panel()',`New_Panel') - function New_Panel (Win : Window) return Panel renames Create; - -- AKA - pragma Inline (New_Panel); - - -- ANCHOR(`bottom_panel()',`Bottom') - procedure Bottom (Pan : in Panel); - -- AKA - pragma Inline (Bottom); - - -- ANCHOR(`top_panel()',`Top') - procedure Top (Pan : in Panel); - -- AKA - pragma Inline (Top); - - -- ANCHOR(`show_panel()',`Show') - procedure Show (Pan : in Panel); - -- AKA - pragma Inline (Show); - - -- ANCHOR(`update_panels()',`Update_Panels') - procedure Update_Panels; - -- AKA - pragma Import (C, Update_Panels, "update_panels"); - - -- ANCHOR(`hide_panel()',`Hide') - procedure Hide (Pan : in Panel); - -- AKA - pragma Inline (Hide); - - -- ANCHOR(`panel_window()',`Get_Window') - function Get_Window (Pan : Panel) return Window; - -- AKA - pragma Inline (Get_Window); - - -- ANCHOR(`panel_window()',`Panel_Window') - function Panel_Window (Pan : Panel) return Window renames Get_Window; - pragma Inline (Panel_Window); - - -- ANCHOR(`replace_panel()',`Replace') - procedure Replace (Pan : in Panel; - Win : in Window); - -- AKA - pragma Inline (Replace); - - -- ANCHOR(`move_panel()',`Move') - procedure Move (Pan : in Panel; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - pragma Inline (Move); - - -- ANCHOR(`panel_hidden()',`Is_Hidden') - function Is_Hidden (Pan : Panel) return Boolean; - -- AKA - pragma Inline (Is_Hidden); - - -- ANCHOR(`panel_above()',`Above') - function Above (Pan : Panel) return Panel; - -- AKA - pragma Import (C, Above, "panel_above"); - - -- ANCHOR(`panel_below()',`Below') - function Below (Pan : Panel) return Panel; - -- AKA - pragma Import (C, Below, "panel_below"); - - -- ANCHOR(`del_panel()',`Delete') - procedure Delete (Pan : in out Panel); - -- AKA - pragma Inline (Delete); - -private - type Panel is new System.Storage_Elements.Integer_Address; - Null_Panel : constant Panel := 0; - -end Terminal_Interface.Curses.Panels; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-trace.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-trace.ads.m4 deleted file mode 100644 index 546004fd49..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses-trace.ads.m4 +++ /dev/null @@ -1,78 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses-trace__ads.htm')dnl -include(M4MACRO)------------------------------------------------------------------------------ --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Trace -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control: --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -package Terminal_Interface.Curses.Trace is - pragma Preelaborate (Terminal_Interface.Curses.Trace); - - pragma Warnings (Off); -include(`Trace_Defs') - - pragma Warnings (On); - - Trace_Disable : constant Trace_Attribute_Set := (others => False); - - Trace_Ordinary : constant Trace_Attribute_Set := - (Times => True, - Tputs => True, - Update => True, - Cursor_Move => True, - Character_Output => True, - others => False); - Trace_Maximum : constant Trace_Attribute_Set := (others => True); - ------------------------------------------------------------------------------- - - -- MANPAGE(`curs_trace.3x') - - -- ANCHOR(`trace()',`Trace_on') - procedure Trace_On (x : Trace_Attribute_Set); - -- The debugging library has trace. - - -- ANCHOR(`_tracef()',`Trace_Put') - procedure Trace_Put (str : String); - -- AKA - - Current_Trace_Setting : Trace_Attribute_Set; - pragma Import (C, Current_Trace_Setting, "_nc_tracing"); - -end Terminal_Interface.Curses.Trace; diff --git a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses.ads.m4 b/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses.ads.m4 deleted file mode 100644 index a8e9795b20..0000000000 --- a/contrib/ncurses-5.4/Ada95/gen/terminal_interface-curses.ads.m4 +++ /dev/null @@ -1,1556 +0,0 @@ --- -*- ada -*- -define(`HTMLNAME',`terminal_interface-curses__ads.htm')dnl -include(M4MACRO)------------------------------------------------------------------------------ --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.31 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -include(`Base_Defs') -with System.Storage_Elements; -with Interfaces.C; -- We need this for some assertions. - -package Terminal_Interface.Curses is - pragma Preelaborate (Terminal_Interface.Curses); -include(`Linker_Options') -include(`Version_Info') - type Window is private; - Null_Window : constant Window; - - type Line_Position is new Natural; -- line coordinate - type Column_Position is new Natural; -- column coordinate - - subtype Line_Count is Line_Position range 1 .. Line_Position'Last; - -- Type to count lines. We do not allow null windows, so must be positive - subtype Column_Count is Column_Position range 1 .. Column_Position'Last; - -- Type to count columns. We do not allow null windows, so must be positive - - type Key_Code is new Natural; - -- That is anything including real characters, special keys and logical - -- request codes. - - subtype Real_Key_Code is Key_Code range 0 .. M4_KEY_MAX; - -- This are the codes that potentially represent a real keystroke. - -- Not all codes may be possible on a specific terminal. To check the - -- availability of a special key, the Has_Key function is provided. - - subtype Special_Key_Code is Real_Key_Code - range M4_SPECIAL_FIRST .. Real_Key_Code'Last; - -- Type for a function- or special key number - - subtype Normal_Key_Code is Real_Key_Code range - Character'Pos (Character'First) .. Character'Pos (Character'Last); - -- This are the codes for regular (incl. non-graphical) characters. - - -- Constants for function- and special keys - -- - Key_None : constant Special_Key_Code := M4_SPECIAL_FIRST; -include(`Key_Definitions') - Key_Max : constant Special_Key_Code - := Special_Key_Code'Last; - - subtype User_Key_Code is Key_Code - range (Key_Max + 129) .. Key_Code'Last; - -- This is reserved for user defined key codes. The range between Key_Max - -- and the first user code is reserved for subsystems like menu and forms. - - -- For those who like to use the original key names we produce them were - -- they differ from the original. Please note that they may differ in - -- lower/upper case. -include(`Old_Keys')dnl - ------------------------------------------------------------------------------- - - type Color_Number is range -1 .. Integer (Interfaces.C.short'Last); - for Color_Number'Size use Interfaces.C.short'Size; - -- (n)curses uses a short for the color index - -- The model is, that a Color_Number is an index into an array of - -- (potentially) definable colors. Some of those indices are - -- predefined (see below), although they may not really exist. - -include(`Color_Defs') - type RGB_Value is range 0 .. Integer (Interfaces.C.short'Last); - for RGB_Value'Size use Interfaces.C.short'Size; - -- Some system may allow to redefine a color by setting RGB values. - - type Color_Pair is range 0 .. 255; - for Color_Pair'Size use 8; - subtype Redefinable_Color_Pair is Color_Pair range 1 .. 255; - -- (n)curses reserves 1 Byte for the color-pair number. Color Pair 0 - -- is fixed (Black & White). A color pair is simply a combination of - -- two colors described by Color_Numbers, one for the foreground and - -- the other for the background - -include(`Character_Attribute_Set_Rep') - -- (n)curses uses all but the lowest 16 Bits for Attributes. - - Normal_Video : constant Character_Attribute_Set := (others => False); - - type Attributed_Character is - record - Attr : Character_Attribute_Set; - Color : Color_Pair; - Ch : Character; - end record; - pragma Convention (C, Attributed_Character); - -- This is the counterpart for the chtype in C. - -include(`AC_Rep') - Default_Character : constant Attributed_Character - := (Ch => Character'First, - Color => Color_Pair'First, - Attr => (others => False)); -- preelaboratable Normal_Video - - type Attributed_String is array (Positive range <>) of Attributed_Character; - pragma Pack (Attributed_String); - -- In this binding we allow strings of attributed characters. - - ------------------ - -- Exceptions -- - ------------------ - Curses_Exception : exception; - Wrong_Curses_Version : exception; - - -- Those exceptions are raised by the ETI (Extended Terminal Interface) - -- subpackets for Menu and Forms handling. - -- - Eti_System_Error : exception; - Eti_Bad_Argument : exception; - Eti_Posted : exception; - Eti_Connected : exception; - Eti_Bad_State : exception; - Eti_No_Room : exception; - Eti_Not_Posted : exception; - Eti_Unknown_Command : exception; - Eti_No_Match : exception; - Eti_Not_Selectable : exception; - Eti_Not_Connected : exception; - Eti_Request_Denied : exception; - Eti_Invalid_Field : exception; - Eti_Current : exception; - - -------------------------------------------------------------------------- - -- External C variables - -- Conceptually even in C this are kind of constants, but they are - -- initialized and sometimes changed by the library routines at runtime - -- depending on the type of terminal. I believe the best way to model - -- this is to use functions. - -------------------------------------------------------------------------- - - function Lines return Line_Count; - pragma Inline (Lines); - - function Columns return Column_Count; - pragma Inline (Columns); - - function Tab_Size return Natural; - pragma Inline (Tab_Size); - - function Number_Of_Colors return Natural; - pragma Inline (Number_Of_Colors); - - function Number_Of_Color_Pairs return Natural; - pragma Inline (Number_Of_Color_Pairs); - - ACS_Map : array (Character'Val (0) .. Character'Val (127)) of - Attributed_Character; - pragma Import (C, ACS_Map, "acs_map"); - -- - -- - -- Constants for several characters from the Alternate Character Set - -- You must use this constants as indices into the ACS_Map array - -- to get the corresponding attributed character at runtime. - -- -include(`ACS_Map')dnl - - -- MANPAGE(`curs_initscr.3x') - -- | Not implemented: newterm, set_term, delscreen, curscr - - -- ANCHOR(`stdscr',`Standard_Window') - function Standard_Window return Window; - -- AKA - pragma Inline (Standard_Window); - - -- ANCHOR(`initscr()',`Init_Screen') - procedure Init_Screen; - - -- ANCHOR(`initscr()',`Init_Windows') - procedure Init_Windows renames Init_Screen; - -- AKA - pragma Inline (Init_Screen); - pragma Inline (Init_Windows); - - -- ANCHOR(`endwin()',`End_Windows') - procedure End_Windows; - -- AKA - procedure End_Screen renames End_Windows; - pragma Inline (End_Windows); - pragma Inline (End_Screen); - - -- ANCHOR(`isendwin()',`Is_End_Window') - function Is_End_Window return Boolean; - -- AKA - pragma Inline (Is_End_Window); - - -- MANPAGE(`curs_move.3x') - - -- ANCHOR(`wmove()',`Move_Cursor') - procedure Move_Cursor (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - -- ALIAS(`move()') - pragma Inline (Move_Cursor); - - -- MANPAGE(`curs_addch.3x') - - -- ANCHOR(`waddch()',`Add') - procedure Add (Win : in Window := Standard_Window; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`addch()') - - procedure Add (Win : in Window := Standard_Window; - Ch : in Character); - -- Add a single character at the current logical cursor position to - -- the window. Use the current windows attributes. - - -- ANCHOR(`mvwaddch()',`Add') - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`mvaddch()') - - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Character); - -- Move to the position and add a single character into the window - -- There are more Add routines, so the Inline pragma follows later - - -- ANCHOR(`wechochar()',`Add_With_Immediate_Echo') - procedure Add_With_Immediate_Echo - (Win : in Window := Standard_Window; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`echochar()') - - procedure Add_With_Immediate_Echo - (Win : in Window := Standard_Window; - Ch : in Character); - -- Add a character and do an immediate refresh of the screen. - pragma Inline (Add_With_Immediate_Echo); - - -- MANPAGE(`curs_window.3x') - -- Not Implemented: wcursyncup - - -- ANCHOR(`newwin()',`Create') - function Create - (Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window; - -- Not Implemented: Default Number_Of_Lines, Number_Of_Columns - -- the C version lets them be 0, see the man page. - -- AKA - pragma Inline (Create); - - function New_Window - (Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window - renames Create; - pragma Inline (New_Window); - - -- ANCHOR(`delwin()',`Delete') - procedure Delete (Win : in out Window); - -- AKA - -- Reset Win to Null_Window - pragma Inline (Delete); - - -- ANCHOR(`subwin()',`Sub_Window') - function Sub_Window - (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window; - -- AKA - pragma Inline (Sub_Window); - - -- ANCHOR(`derwin()',`Derived_Window') - function Derived_Window - (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window; - -- AKA - pragma Inline (Derived_Window); - - -- ANCHOR(`dupwin()',`Duplicate') - function Duplicate (Win : Window) return Window; - -- AKA - pragma Inline (Duplicate); - - -- ANCHOR(`mvwin()',`Move_Window') - procedure Move_Window (Win : in Window; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - pragma Inline (Move_Window); - - -- ANCHOR(`mvderwin()',`Move_Derived_Window') - procedure Move_Derived_Window (Win : in Window; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - pragma Inline (Move_Derived_Window); - - -- ANCHOR(`wsyncup()',`Synchronize_Upwards') - procedure Synchronize_Upwards (Win : in Window); - -- AKA - pragma Import (C, Synchronize_Upwards, "wsyncup"); - - -- ANCHOR(`wsyncdown()',`Synchronize_Downwards') - procedure Synchronize_Downwards (Win : in Window); - -- AKA - pragma Import (C, Synchronize_Downwards, "wsyncdown"); - - -- ANCHOR(`syncok()',`Set_Synch_Mode') - procedure Set_Synch_Mode (Win : in Window := Standard_Window; - Mode : in Boolean := False); - -- AKA - pragma Inline (Set_Synch_Mode); - - -- MANPAGE(`curs_addstr.3x') - - -- ANCHOR(`waddnstr()',`Add') - procedure Add (Win : in Window := Standard_Window; - Str : in String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`waddstr()') - -- ALIAS(`addnstr()') - -- ALIAS(`addstr()') - - -- ANCHOR(`mvwaddnstr()',`Add') - procedure Add (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwaddstr()') - -- ALIAS(`mvaddnstr()') - -- ALIAS(`mvaddstr()') - - -- MANPAGE(`curs_addchstr.3x') - - -- ANCHOR(`waddchnstr()',`Add') - procedure Add (Win : in Window := Standard_Window; - Str : in Attributed_String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`waddchstr()') - -- ALIAS(`addchnstr()') - -- ALIAS(`addchstr()') - - -- ANCHOR(`mvwaddchnstr()',`Add') - procedure Add (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in Attributed_String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwaddchstr()') - -- ALIAS(`mvaddchnstr()') - -- ALIAS(`mvaddchstr()') - pragma Inline (Add); - - -- MANPAGE(`curs_border.3x') - -- | Not implemented: mvhline, mvwhline, mvvline, mvwvline - -- | use Move_Cursor then Horizontal_Line or Vertical_Line - - -- ANCHOR(`wborder()',`Border') - procedure Border - (Win : in Window := Standard_Window; - Left_Side_Symbol : in Attributed_Character := Default_Character; - Right_Side_Symbol : in Attributed_Character := Default_Character; - Top_Side_Symbol : in Attributed_Character := Default_Character; - Bottom_Side_Symbol : in Attributed_Character := Default_Character; - Upper_Left_Corner_Symbol : in Attributed_Character := Default_Character; - Upper_Right_Corner_Symbol : in Attributed_Character := Default_Character; - Lower_Left_Corner_Symbol : in Attributed_Character := Default_Character; - Lower_Right_Corner_Symbol : in Attributed_Character := Default_Character - ); - -- AKA - -- ALIAS(`border()') - pragma Inline (Border); - - -- ANCHOR(`box()',`Box') - procedure Box - (Win : in Window := Standard_Window; - Vertical_Symbol : in Attributed_Character := Default_Character; - Horizontal_Symbol : in Attributed_Character := Default_Character); - -- AKA - pragma Inline (Box); - - -- ANCHOR(`whline()',`Horizontal_Line') - procedure Horizontal_Line - (Win : in Window := Standard_Window; - Line_Size : in Natural; - Line_Symbol : in Attributed_Character := Default_Character); - -- AKA - -- ALIAS(`hline()') - pragma Inline (Horizontal_Line); - - -- ANCHOR(`wvline()',`Vertical_Line') - procedure Vertical_Line - (Win : in Window := Standard_Window; - Line_Size : in Natural; - Line_Symbol : in Attributed_Character := Default_Character); - -- AKA - -- ALIAS(`vline()') - pragma Inline (Vertical_Line); - - -- MANPAGE(`curs_getch.3x') - -- Not implemented: mvgetch, mvwgetch - - -- ANCHOR(`wgetch()',`Get_Keystroke') - function Get_Keystroke (Win : Window := Standard_Window) - return Real_Key_Code; - -- AKA - -- ALIAS(`getch()') - -- Get a character from the keyboard and echo it - if enabled - to the - -- window. - -- If for any reason (i.e. a timeout) we couldn't get a character the - -- returned keycode is Key_None. - pragma Inline (Get_Keystroke); - - -- ANCHOR(`ungetch()',`Undo_Keystroke') - procedure Undo_Keystroke (Key : in Real_Key_Code); - -- AKA - pragma Inline (Undo_Keystroke); - - -- ANCHOR(`has_key()',`Has_Key') - function Has_Key (Key : Special_Key_Code) return Boolean; - -- AKA - pragma Inline (Has_Key); - - -- | - -- | Some helper functions - -- | - function Is_Function_Key (Key : Special_Key_Code) return Boolean; - -- Return True if the Key is a function key (i.e. one of F0 .. F63) - pragma Inline (Is_Function_Key); - - subtype Function_Key_Number is Integer range 0 .. 63; - -- (n)curses allows for 64 function keys. - - function Function_Key (Key : Real_Key_Code) return Function_Key_Number; - -- Return the number of the function key. If the code is not a - -- function key, a CONSTRAINT_ERROR will be raised. - pragma Inline (Function_Key); - - function Function_Key_Code (Key : Function_Key_Number) return Real_Key_Code; - -- Return the key code for a given function-key number. - pragma Inline (Function_Key_Code); - - -- MANPAGE(`curs_attr.3x') - -- | Not implemented attr_off, wattr_off, - -- | attr_on, wattr_on, attr_set, wattr_set - - -- PAIR_NUMBER - -- PAIR_NUMBER(c) is the same as c.Color - - -- ANCHOR(`standout()',`Standout') - procedure Standout (Win : Window := Standard_Window; - On : Boolean := True); - -- ALIAS(`wstandout()') - -- ALIAS(`wstandend()') - - -- ANCHOR(`wattron()',`Switch_Character_Attribute') - procedure Switch_Character_Attribute - (Win : in Window := Standard_Window; - Attr : in Character_Attribute_Set := Normal_Video; - On : in Boolean := True); -- if False we switch Off. - -- Switches those Attributes set to true in the list. - -- AKA - -- ALIAS(`wattroff()') - -- ALIAS(`attron()') - -- ALIAS(`attroff()') - - -- ANCHOR(`wattrset()',`Set_Character_Attributes') - procedure Set_Character_Attributes - (Win : in Window := Standard_Window; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - -- ALIAS(`attrset()') - pragma Inline (Set_Character_Attributes); - - -- ANCHOR(`wattr_get()',`Get_Character_Attributes') - function Get_Character_Attribute - (Win : in Window := Standard_Window) return Character_Attribute_Set; - -- AKA - -- ALIAS(`attr_get()') - - -- ANCHOR(`wattr_get()',`Get_Character_Attribute') - function Get_Character_Attribute - (Win : in Window := Standard_Window) return Color_Pair; - -- AKA - pragma Inline (Get_Character_Attribute); - - -- ANCHOR(`wcolor_set()',`Set_Color') - procedure Set_Color (Win : in Window := Standard_Window; - Pair : in Color_Pair); - -- AKA - -- ALIAS(`color_set()') - pragma Inline (Set_Color); - - -- ANCHOR(`wchgat()',`Change_Attributes') - procedure Change_Attributes - (Win : in Window := Standard_Window; - Count : in Integer := -1; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - -- ALIAS(`chgat()') - - -- ANCHOR(`mvwchgat()',`Change_Attributes') - procedure Change_Attributes - (Win : in Window := Standard_Window; - Line : in Line_Position := Line_Position'First; - Column : in Column_Position := Column_Position'First; - Count : in Integer := -1; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - -- ALIAS(`mvchgat()') - pragma Inline (Change_Attributes); - - -- MANPAGE(`curs_beep.3x') - - -- ANCHOR(`beep()',`Beep') - procedure Beep; - -- AKA - pragma Inline (Beep); - - -- ANCHOR(`flash()',`Flash_Screen') - procedure Flash_Screen; - -- AKA - pragma Inline (Flash_Screen); - - -- MANPAGE(`curs_inopts.3x') - - -- | Not implemented : typeahead - -- - -- ANCHOR(`cbreak()',`Set_Cbreak_Mode') - procedure Set_Cbreak_Mode (SwitchOn : in Boolean := True); - -- AKA - -- ALIAS(`nocbreak()') - pragma Inline (Set_Cbreak_Mode); - - -- ANCHOR(`raw()',`Set_Raw_Mode') - procedure Set_Raw_Mode (SwitchOn : in Boolean := True); - -- AKA - -- ALIAS(`noraw()') - pragma Inline (Set_Raw_Mode); - - -- ANCHOR(`echo()',`Set_Echo_Mode') - procedure Set_Echo_Mode (SwitchOn : in Boolean := True); - -- AKA - -- ALIAS(`noecho()') - pragma Inline (Set_Echo_Mode); - - -- ANCHOR(`meta()',`Set_Meta_Mode') - procedure Set_Meta_Mode (Win : in Window := Standard_Window; - SwitchOn : in Boolean := True); - -- AKA - pragma Inline (Set_Meta_Mode); - - -- ANCHOR(`keypad()',`Set_KeyPad_Mode') - procedure Set_KeyPad_Mode (Win : in Window := Standard_Window; - SwitchOn : in Boolean := True); - -- AKA - pragma Inline (Set_KeyPad_Mode); - - function Get_KeyPad_Mode (Win : in Window := Standard_Window) - return Boolean; - -- This has no pendant in C. There you've to look into the WINDOWS - -- structure to get the value. Bad practice, not repeated in Ada. - - type Half_Delay_Amount is range 1 .. 255; - - -- ANCHOR(`halfdelay()',`Half_Delay') - procedure Half_Delay (Amount : in Half_Delay_Amount); - -- AKA - pragma Inline (Half_Delay); - - -- ANCHOR(`intrflush()',`Set_Flush_On_Interrupt_Mode') - procedure Set_Flush_On_Interrupt_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := True); - -- AKA - pragma Inline (Set_Flush_On_Interrupt_Mode); - - -- ANCHOR(`qiflush()',`Set_Queue_Interrupt_Mode') - procedure Set_Queue_Interrupt_Mode - (Win : in Window := Standard_Window; - Flush : in Boolean := True); - -- AKA - -- ALIAS(`noqiflush()') - pragma Inline (Set_Queue_Interrupt_Mode); - - -- ANCHOR(`nodelay()',`Set_NoDelay_Mode') - procedure Set_NoDelay_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := False); - -- AKA - pragma Inline (Set_NoDelay_Mode); - - type Timeout_Mode is (Blocking, Non_Blocking, Delayed); - - -- ANCHOR(`wtimeout()',`Set_Timeout_Mode') - procedure Set_Timeout_Mode (Win : in Window := Standard_Window; - Mode : in Timeout_Mode; - Amount : in Natural); -- in Milliseconds - -- AKA - -- ALIAS(`timeout()') - -- Instead of overloading the semantic of the sign of amount, we - -- introduce the Timeout_Mode parameter. This should improve - -- readability. For Blocking and Non_Blocking, the Amount is not - -- evaluated. - -- We don't inline this procedure. - - -- ANCHOR(`notimeout()',`Set_Escape_Time_Mode') - procedure Set_Escape_Timer_Mode - (Win : in Window := Standard_Window; - Timer_Off : in Boolean := False); - -- AKA - pragma Inline (Set_Escape_Timer_Mode); - - -- MANPAGE(`curs_outopts.3x') - - -- ANCHOR(`nl()',`Set_NL_Mode') - procedure Set_NL_Mode (SwitchOn : in Boolean := True); - -- AKA - -- ALIAS(`nonl()') - pragma Inline (Set_NL_Mode); - - -- ANCHOR(`clearok()',`Clear_On_Next_Update') - procedure Clear_On_Next_Update - (Win : in Window := Standard_Window; - Do_Clear : in Boolean := True); - -- AKA - pragma Inline (Clear_On_Next_Update); - - -- ANCHOR(`idlok()',`Use_Insert_Delete_Line') - procedure Use_Insert_Delete_Line - (Win : in Window := Standard_Window; - Do_Idl : in Boolean := True); - -- AKA - pragma Inline (Use_Insert_Delete_Line); - - -- ANCHOR(`idcok()',`Use_Insert_Delete_Character') - procedure Use_Insert_Delete_Character - (Win : in Window := Standard_Window; - Do_Idc : in Boolean := True); - -- AKA - pragma Inline (Use_Insert_Delete_Character); - - -- ANCHOR(`leaveok()',`Leave_Cursor_After_Update') - procedure Leave_Cursor_After_Update - (Win : in Window := Standard_Window; - Do_Leave : in Boolean := True); - -- AKA - pragma Inline (Leave_Cursor_After_Update); - - -- ANCHOR(`immedok()',`Immediate_Update_Mode') - procedure Immediate_Update_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := False); - -- AKA - pragma Inline (Immediate_Update_Mode); - - -- ANCHOR(`scrollok()',`Allow_Scrolling') - procedure Allow_Scrolling - (Win : in Window := Standard_Window; - Mode : in Boolean := False); - -- AKA - pragma Inline (Allow_Scrolling); - - function Scrolling_Allowed (Win : Window := Standard_Window) return Boolean; - -- There is no such function in the C interface. - pragma Inline (Scrolling_Allowed); - - -- ANCHOR(`wsetscrreg()',`Set_Scroll_Region') - procedure Set_Scroll_Region - (Win : in Window := Standard_Window; - Top_Line : in Line_Position; - Bottom_Line : in Line_Position); - -- AKA - -- ALIAS(`setscrreg()') - pragma Inline (Set_Scroll_Region); - - -- MANPAGE(`curs_refresh.3x') - - -- ANCHOR(`doupdate()',`Update_Screen') - procedure Update_Screen; - -- AKA - pragma Inline (Update_Screen); - - -- ANCHOR(`wrefresh()',`Refresh') - procedure Refresh (Win : in Window := Standard_Window); - -- AKA - -- There is an overloaded Refresh for Pads. - -- The Inline pragma appears there - -- ALIAS(`refresh()') - - -- ANCHOR(`wnoutrefresh()',`Refresh_Without_Update') - procedure Refresh_Without_Update - (Win : in Window := Standard_Window); - -- AKA - -- There is an overloaded Refresh_Without_Update for Pads. - -- The Inline pragma appears there - - -- ANCHOR(`redrawwin()',`Redraw') - procedure Redraw (Win : in Window := Standard_Window); - -- AKA - - -- ANCHOR(`wredrawln()',`Redraw') - procedure Redraw (Win : in Window := Standard_Window; - Begin_Line : in Line_Position; - Line_Count : in Positive); - -- AKA - pragma Inline (Redraw); - - -- MANPAGE(`curs_clear.3x') - - -- ANCHOR(`werase()',`Erase') - procedure Erase (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`erase()') - pragma Inline (Erase); - - -- ANCHOR(`wclear()',`Clear') - procedure Clear - (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`clear()') - pragma Inline (Clear); - - -- ANCHOR(`wclrtobot()',`Clear_To_End_Of_Screen') - procedure Clear_To_End_Of_Screen - (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`clrtobot()') - pragma Inline (Clear_To_End_Of_Screen); - - -- ANCHOR(`wclrtoeol()',`Clear_To_End_Of_Line') - procedure Clear_To_End_Of_Line - (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`clrtoeol()') - pragma Inline (Clear_To_End_Of_Line); - - -- MANPAGE(`curs_bkgd.3x') - - -- ANCHOR(`wbkgdset()',`Set_Background') - -- TODO: we could have Set_Background(Window; Character_Attribute_Set) - -- because in C it is common to see bkgdset(A_BOLD) or - -- bkgdset(COLOR_PAIR(n)) - procedure Set_Background - (Win : in Window := Standard_Window; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`bkgdset()') - pragma Inline (Set_Background); - - -- ANCHOR(`wbkgd()',`Change_Background') - procedure Change_Background - (Win : in Window := Standard_Window; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`bkgd()') - pragma Inline (Change_Background); - - -- ANCHOR(`wbkgdget()',`Get_Background') - -- ? wbkgdget is not listed in curs_bkgd, getbkgd is thpough. - function Get_Background (Win : Window := Standard_Window) - return Attributed_Character; - -- AKA - -- ALIAS(`bkgdget()') - pragma Inline (Get_Background); - - -- MANPAGE(`curs_touch.3x') - - -- ANCHOR(`untouchwin()',`Untouch') - procedure Untouch (Win : in Window := Standard_Window); - -- AKA - pragma Inline (Untouch); - - -- ANCHOR(`touchwin()',`Touch') - procedure Touch (Win : in Window := Standard_Window); - -- AKA - - -- ANCHOR(`touchline()',`Touch') - procedure Touch (Win : in Window := Standard_Window; - Start : in Line_Position; - Count : in Positive); - -- AKA - pragma Inline (Touch); - - -- ANCHOR(`wtouchln()',`Change_Line_Status') - procedure Change_Lines_Status (Win : in Window := Standard_Window; - Start : in Line_Position; - Count : in Positive; - State : in Boolean); - -- AKA - pragma Inline (Change_Lines_Status); - - -- ANCHOR(`is_linetouched()',`Is_Touched') - function Is_Touched (Win : Window := Standard_Window; - Line : Line_Position) return Boolean; - -- AKA - - -- ANCHOR(`is_wintouched()',`Is_Touched') - function Is_Touched (Win : Window := Standard_Window) return Boolean; - -- AKA - pragma Inline (Is_Touched); - - -- MANPAGE(`curs_overlay.3x') - - -- ANCHOR(`copywin()',`Copy') - procedure Copy - (Source_Window : in Window; - Destination_Window : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position; - Non_Destructive_Mode : in Boolean := True); - -- AKA - pragma Inline (Copy); - - -- ANCHOR(`overwrite()',`Overwrite') - procedure Overwrite (Source_Window : in Window; - Destination_Window : in Window); - -- AKA - pragma Inline (Overwrite); - - -- ANCHOR(`overlay()',`Overlay') - procedure Overlay (Source_Window : in Window; - Destination_Window : in Window); - -- AKA - pragma Inline (Overlay); - - -- MANPAGE(`curs_deleteln.3x') - - -- ANCHOR(`winsdelln()',`Insert_Delete_Lines') - procedure Insert_Delete_Lines - (Win : in Window := Standard_Window; - Lines : in Integer := 1); -- default is to insert one line above - -- AKA - -- ALIAS(`insdelln()') - pragma Inline (Insert_Delete_Lines); - - -- ANCHOR(`wdeleteln()',`Delete_Line') - procedure Delete_Line (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`deleteln()') - pragma Inline (Delete_Line); - - -- ANCHOR(`winsertln()',`Insert_Line') - procedure Insert_Line (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`insertln()') - pragma Inline (Insert_Line); - - -- MANPAGE(`curs_getyx.3x') - - -- ANCHOR(`getmaxyx()',`Get_Size') - procedure Get_Size - (Win : in Window := Standard_Window; - Number_Of_Lines : out Line_Count; - Number_Of_Columns : out Column_Count); - -- AKA - pragma Inline (Get_Size); - - -- ANCHOR(`getbegyx()',`Get_Window_Position') - procedure Get_Window_Position - (Win : in Window := Standard_Window; - Top_Left_Line : out Line_Position; - Top_Left_Column : out Column_Position); - -- AKA - pragma Inline (Get_Window_Position); - - -- ANCHOR(`getyx()',`Get_Cursor_Position') - procedure Get_Cursor_Position - (Win : in Window := Standard_Window; - Line : out Line_Position; - Column : out Column_Position); - -- AKA - pragma Inline (Get_Cursor_Position); - - -- ANCHOR(`getparyx()',`Get_Origin_Relative_To_Parent') - procedure Get_Origin_Relative_To_Parent - (Win : in Window; - Top_Left_Line : out Line_Position; - Top_Left_Column : out Column_Position; - Is_Not_A_Subwindow : out Boolean); - -- AKA - -- Instead of placing -1 in the coordinates as return, we use a boolean - -- to return the info that the window has no parent. - pragma Inline (Get_Origin_Relative_To_Parent); - - -- MANPAGE(`curs_pad.3x') - - -- ANCHOR(`newpad()',`New_Pad') - function New_Pad (Lines : Line_Count; - Columns : Column_Count) return Window; - -- AKA - pragma Inline (New_Pad); - - -- ANCHOR(`subpad()',`Sub_Pad') - function Sub_Pad - (Pad : Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window; - -- AKA - pragma Inline (Sub_Pad); - - -- ANCHOR(`prefresh()',`Refresh') - procedure Refresh - (Pad : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position); - -- AKA - pragma Inline (Refresh); - - -- ANCHOR(`pnoutrefresh()',`Refresh_Without_Update') - procedure Refresh_Without_Update - (Pad : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position); - -- AKA - pragma Inline (Refresh_Without_Update); - - -- ANCHOR(`pechochar()',`Add_Character_To_Pad_And_Echo_It') - procedure Add_Character_To_Pad_And_Echo_It - (Pad : in Window; - Ch : in Attributed_Character); - -- AKA - - procedure Add_Character_To_Pad_And_Echo_It - (Pad : in Window; - Ch : in Character); - pragma Inline (Add_Character_To_Pad_And_Echo_It); - - -- MANPAGE(`curs_scroll.3x') - - -- ANCHOR(`wscrl()',`Scroll') - procedure Scroll (Win : in Window := Standard_Window; - Amount : in Integer := 1); - -- AKA - -- ALIAS(`scroll()') - -- ALIAS(`scrl()') - pragma Inline (Scroll); - - -- MANPAGE(`curs_delch.3x') - - -- ANCHOR(`wdelch()',`Delete_Character') - procedure Delete_Character (Win : in Window := Standard_Window); - -- AKA - -- ALIAS(`delch()') - - -- ANCHOR(`mvwdelch()',`Delete_Character') - procedure Delete_Character - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position); - -- AKA - -- ALIAS(`mvdelch()') - pragma Inline (Delete_Character); - - -- MANPAGE(`curs_inch.3x') - - -- ANCHOR(`winch()',`Peek') - function Peek (Win : Window := Standard_Window) - return Attributed_Character; - -- ALIAS(`inch()') - -- AKA - - -- ANCHOR(`mvwinch()',`Peek') - function Peek - (Win : Window := Standard_Window; - Line : Line_Position; - Column : Column_Position) return Attributed_Character; - -- AKA - -- ALIAS(`mvinch()') - -- More Peek's follow, pragma Inline appears later. - - -- MANPAGE(`curs_insch.3x') - - -- ANCHOR(`winsch()',`Insert') - procedure Insert (Win : in Window := Standard_Window; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`insch()') - - -- ANCHOR(`mvwinsch()',`Insert') - procedure Insert (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Attributed_Character); - -- AKA - -- ALIAS(`mvinsch()') - - -- MANPAGE(`curs_insstr.3x') - - -- ANCHOR(`winsnstr()',`Insert') - procedure Insert (Win : in Window := Standard_Window; - Str : in String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`winsstr()') - -- ALIAS(`insnstr()') - -- ALIAS(`insstr()') - - -- ANCHOR(`mvwinsnstr()',`Insert') - procedure Insert (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwinsstr()') - -- ALIAS(`mvinsnstr()') - -- ALIAS(`mvinsstr()') - pragma Inline (Insert); - - -- MANPAGE(`curs_instr.3x') - - -- ANCHOR(`winnstr()',`Peek') - procedure Peek (Win : in Window := Standard_Window; - Str : out String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`winstr()') - -- ALIAS(`innstr()') - -- ALIAS(`instr()') - - -- ANCHOR(`mvwinnstr()',`Peek') - procedure Peek (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwinstr()') - -- ALIAS(`mvinnstr()') - -- ALIAS(`mvinstr()') - - -- MANPAGE(`curs_inchstr.3x') - - -- ANCHOR(`winchnstr()',`Peek') - procedure Peek (Win : in Window := Standard_Window; - Str : out Attributed_String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`winchstr()') - -- ALIAS(`inchnstr()') - -- ALIAS(`inchstr()') - - -- ANCHOR(`mvwinchnstr()',`Peek') - procedure Peek (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out Attributed_String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwinchstr()') - -- ALIAS(`mvinchnstr()') - -- ALIAS(`mvinchstr()') - -- We don't inline the Peek procedures - - -- MANPAGE(`curs_getstr.3x') - - -- ANCHOR(`wgetnstr()',`Get') - procedure Get (Win : in Window := Standard_Window; - Str : out String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`wgetstr()') - -- ALIAS(`getnstr()') - -- ALIAS(`getstr()') - -- actually getstr is not supported because that results in buffer - -- overflows. - - -- ANCHOR(`mvwgetnstr()',`Get') - procedure Get (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out String; - Len : in Integer := -1); - -- AKA - -- ALIAS(`mvwgetstr()') - -- ALIAS(`mvgetnstr()') - -- ALIAS(`mvgetstr()') - -- Get is not inlined - - -- MANPAGE(`curs_slk.3x') - - -- Not Implemented: slk_attr_on, slk_attr_off, slk_attr_set - - type Soft_Label_Key_Format is (Three_Two_Three, - Four_Four, - PC_Style, -- ncurses specific - PC_Style_With_Index); -- " - type Label_Number is new Positive range 1 .. 12; - type Label_Justification is (Left, Centered, Right); - - -- ANCHOR(`slk_init()',`Init_Soft_Label_Keys') - procedure Init_Soft_Label_Keys - (Format : in Soft_Label_Key_Format := Three_Two_Three); - -- AKA - pragma Inline (Init_Soft_Label_Keys); - - -- ANCHOR(`slk_set()',`Set_Soft_Label_Key') - procedure Set_Soft_Label_Key (Label : in Label_Number; - Text : in String; - Fmt : in Label_Justification := Left); - -- AKA - -- We don't inline this procedure - - -- ANCHOR(`slk_refresh()',`Refresh_Soft_Label_Key') - procedure Refresh_Soft_Label_Keys; - -- AKA - pragma Inline (Refresh_Soft_Label_Keys); - - -- ANCHOR(`slk_noutrefresh()',`Refresh_Soft_Label_Keys_Without_Update') - procedure Refresh_Soft_Label_Keys_Without_Update; - -- AKA - pragma Inline (Refresh_Soft_Label_Keys_Without_Update); - - -- ANCHOR(`slk_label()',`Get_Soft_Label_Key') - procedure Get_Soft_Label_Key (Label : in Label_Number; - Text : out String); - -- AKA - - -- ANCHOR(`slk_label()',`Get_Soft_Label_Key') - function Get_Soft_Label_Key (Label : in Label_Number) return String; - -- AKA - -- Same as function - pragma Inline (Get_Soft_Label_Key); - - -- ANCHOR(`slk_clear()',`Clear_Soft_Label_Keys') - procedure Clear_Soft_Label_Keys; - -- AKA - pragma Inline (Clear_Soft_Label_Keys); - - -- ANCHOR(`slk_restore()',`Restore_Soft_Label_Keys') - procedure Restore_Soft_Label_Keys; - -- AKA - pragma Inline (Restore_Soft_Label_Keys); - - -- ANCHOR(`slk_touch()',`Touch_Soft_Label_Keys') - procedure Touch_Soft_Label_Keys; - -- AKA - pragma Inline (Touch_Soft_Label_Keys); - - -- ANCHOR(`slk_attron()',`Switch_Soft_Label_Key_Attributes') - procedure Switch_Soft_Label_Key_Attributes - (Attr : in Character_Attribute_Set; - On : in Boolean := True); - -- AKA - -- ALIAS(`slk_attroff()') - pragma Inline (Switch_Soft_Label_Key_Attributes); - - -- ANCHOR(`slk_attrset()',`Set_Soft_Label_Key_Attributes') - procedure Set_Soft_Label_Key_Attributes - (Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First); - -- AKA - pragma Inline (Set_Soft_Label_Key_Attributes); - - -- ANCHOR(`slk_attr()',`Get_Soft_Label_Key_Attributes') - function Get_Soft_Label_Key_Attributes return Character_Attribute_Set; - -- AKA - - -- ANCHOR(`slk_attr()',`Get_Soft_Label_Key_Attributes') - function Get_Soft_Label_Key_Attributes return Color_Pair; - -- AKA - pragma Inline (Get_Soft_Label_Key_Attributes); - - -- ANCHOR(`slk_color()',`Set_Soft_Label_Key_Color') - procedure Set_Soft_Label_Key_Color (Pair : in Color_Pair); - -- AKA - pragma Inline (Set_Soft_Label_Key_Color); - - -- MANPAGE(`keybound.3x') - -- Not Implemented: keybound - - -- MANPAGE(`keyok.3x') - - -- ANCHOR(`keyok()',`Enable_Key') - procedure Enable_Key (Key : in Special_Key_Code; - Enable : in Boolean := True); - -- AKA - pragma Inline (Enable_Key); - - -- MANPAGE(`define_key.3x') - - -- ANCHOR(`define_key()',`Define_Key') - procedure Define_Key (Definition : in String; - Key : in Special_Key_Code); - -- AKA - pragma Inline (Define_Key); - - -- MANPAGE(`curs_util.3x') - - -- | Not implemented : filter, use_env - -- | putwin, getwin are in the child package PutWin - -- - - -- ANCHOR(`keyname()',`Key_Name') - procedure Key_Name (Key : in Real_Key_Code; - Name : out String); - -- AKA - -- The external name for a real keystroke. - - -- ANCHOR(`keyname()',`Key_Name') - function Key_Name (Key : in Real_Key_Code) return String; - -- AKA - -- Same as function - -- We don't inline this routine - - -- ANCHOR(`unctrl()',`Un_Control') - procedure Un_Control (Ch : in Attributed_Character; - Str : out String); - -- AKA - - -- ANCHOR(`unctrl()',`Un_Control') - function Un_Control (Ch : in Attributed_Character) return String; - -- AKA - -- Same as function - pragma Inline (Un_Control); - - -- ANCHOR(`delay_output()',`Delay_Output') - procedure Delay_Output (Msecs : in Natural); - -- AKA - pragma Inline (Delay_Output); - - -- ANCHOR(`flushinp()',`Flush_Input') - procedure Flush_Input; - -- AKA - pragma Inline (Flush_Input); - - -- MANPAGE(`curs_termattrs.3x') - - -- ANCHOR(`baudrate()',`Baudrate') - function Baudrate return Natural; - -- AKA - pragma Inline (Baudrate); - - -- ANCHOR(`erasechar()',`Erase_Character') - function Erase_Character return Character; - -- AKA - pragma Inline (Erase_Character); - - -- ANCHOR(`killchar()',`Kill_Character') - function Kill_Character return Character; - -- AKA - pragma Inline (Kill_Character); - - -- ANCHOR(`has_ic()',`Has_Insert_Character') - function Has_Insert_Character return Boolean; - -- AKA - pragma Inline (Has_Insert_Character); - - -- ANCHOR(`has_il()',`Has_Insert_Line') - function Has_Insert_Line return Boolean; - -- AKA - pragma Inline (Has_Insert_Line); - - -- ANCHOR(`termattrs()',`Supported_Attributes') - function Supported_Attributes return Character_Attribute_Set; - -- AKA - pragma Inline (Supported_Attributes); - - -- ANCHOR(`longname()',`Long_Name') - procedure Long_Name (Name : out String); - -- AKA - - -- ANCHOR(`longname()',`Long_Name') - function Long_Name return String; - -- AKA - -- Same as function - pragma Inline (Long_Name); - - -- ANCHOR(`termname()',`Terminal_Name') - procedure Terminal_Name (Name : out String); - -- AKA - - -- ANCHOR(`termname()',`Terminal_Name') - function Terminal_Name return String; - -- AKA - -- Same as function - pragma Inline (Terminal_Name); - - -- MANPAGE(`curs_color.3x') - - -- COLOR_PAIR - -- COLOR_PAIR(n) in C is the same as - -- Attributed_Character(Ch => Nul, Color => n, Attr => Normal_Video) - -- In C you often see something like c = c | COLOR_PAIR(n); - -- This is equivalent to c.Color := n; - - -- ANCHOR(`start_color()',`Start_Color') - procedure Start_Color; - -- AKA - pragma Import (C, Start_Color, "start_color"); - - -- ANCHOR(`init_pair()',`Init_Pair') - procedure Init_Pair (Pair : in Redefinable_Color_Pair; - Fore : in Color_Number; - Back : in Color_Number); - -- AKA - pragma Inline (Init_Pair); - - -- ANCHOR(`pair_content()',`Pair_Content') - procedure Pair_Content (Pair : in Color_Pair; - Fore : out Color_Number; - Back : out Color_Number); - -- AKA - pragma Inline (Pair_Content); - - -- ANCHOR(`has_colors()',`Has_Colors') - function Has_Colors return Boolean; - -- AKA - pragma Inline (Has_Colors); - - -- ANCHOR(`init_color()',`Init_Color') - procedure Init_Color (Color : in Color_Number; - Red : in RGB_Value; - Green : in RGB_Value; - Blue : in RGB_Value); - -- AKA - pragma Inline (Init_Color); - - -- ANCHOR(`can_change_color()',`Can_Change_Color') - function Can_Change_Color return Boolean; - -- AKA - pragma Inline (Can_Change_Color); - - -- ANCHOR(`color_content()',`Color_Content') - procedure Color_Content (Color : in Color_Number; - Red : out RGB_Value; - Green : out RGB_Value; - Blue : out RGB_Value); - -- AKA - pragma Inline (Color_Content); - - -- MANPAGE(`curs_kernel.3x') - -- | Not implemented: getsyx, setsyx - -- - type Curses_Mode is (Curses, Shell); - - -- ANCHOR(`def_prog_mode()',`Save_Curses_Mode') - procedure Save_Curses_Mode (Mode : in Curses_Mode); - -- AKA - -- ALIAS(`def_shell_mode()') - pragma Inline (Save_Curses_Mode); - - -- ANCHOR(`reset_prog_mode()',`Reset_Curses_Mode') - procedure Reset_Curses_Mode (Mode : in Curses_Mode); - -- AKA - -- ALIAS(`reset_shell_mode()') - pragma Inline (Reset_Curses_Mode); - - -- ANCHOR(`savetty()',`Save_Terminal_State') - procedure Save_Terminal_State; - -- AKA - pragma Inline (Save_Terminal_State); - - -- ANCHOR(`resetty();',`Reset_Terminal_State') - procedure Reset_Terminal_State; - -- AKA - pragma Inline (Reset_Terminal_State); - - type Stdscr_Init_Proc is access - function (Win : Window; - Columns : Column_Count) return Integer; - pragma Convention (C, Stdscr_Init_Proc); - -- N.B.: the return value is actually ignored, but it seems to be - -- a good practice to return 0 if you think all went fine - -- and -1 otherwise. - - -- ANCHOR(`ripoffline()',`Rip_Off_Lines') - procedure Rip_Off_Lines (Lines : in Integer; - Proc : in Stdscr_Init_Proc); - -- AKA - -- N.B.: to be more precise, this uses a ncurses specific enhancement of - -- ripoffline(), in which the Lines argument absolute value is the - -- number of lines to be ripped of. The official ripoffline() only - -- uses the sign of Lines to rip of a single line from bottom or top. - pragma Inline (Rip_Off_Lines); - - type Cursor_Visibility is (Invisible, Normal, Very_Visible); - - -- ANCHOR(`curs_set()',`Set_Cursor_Visibility') - procedure Set_Cursor_Visibility (Visibility : in out Cursor_Visibility); - -- AKA - pragma Inline (Set_Cursor_Visibility); - - -- ANCHOR(`napms()',`Nap_Milli_Seconds') - procedure Nap_Milli_Seconds (Ms : in Natural); - -- AKA - pragma Inline (Nap_Milli_Seconds); - - -- |===================================================================== - -- | Some useful helpers. - -- |===================================================================== - type Transform_Direction is (From_Screen, To_Screen); - procedure Transform_Coordinates - (W : in Window := Standard_Window; - Line : in out Line_Position; - Column : in out Column_Position; - Dir : in Transform_Direction := From_Screen); - -- This procedure transforms screen coordinates into coordinates relative - -- to the window and vice versa, depending on the Dir parameter. - -- Screen coordinates are the position informations on the physical device. - -- An Curses_Exception will be raised if Line and Column are not in the - -- Window or if you pass the Null_Window as argument. - -- We don't inline this procedure - - -- MANPAGE(`dft_fgbg.3x') - - -- ANCHOR(`use_default_colors()',`Use_Default_Colors') - procedure Use_Default_Colors; - -- AKA - pragma Inline (Use_Default_Colors); - - -- ANCHOR(`assume_default_colors()',`Assume_Default_Colors') - procedure Assume_Default_Colors (Fore : Color_Number := Default_Color; - Back : Color_Number := Default_Color); - -- AKA - pragma Inline (Assume_Default_Colors); - - -- MANPAGE(`curs_extend.3x') - - -- ANCHOR(`curses_version()',`Curses_Version') - function Curses_Version return String; - -- AKA - - -- ANCHOR(`use_extended_names()',`Use_Extended_Names') - -- The returnvalue is the previous setting of the flag - function Use_Extended_Names (Enable : Boolean) return Boolean; - -- AKA - - -- MANPAGE(`curs_scr_dump.3x') - - -- ANCHOR(`scr_dump()',`Screen_Dump_To_File') - procedure Screen_Dump_To_File (Filename : in String); - -- AKA - - -- ANCHOR(`scr_restore()',`Screen_Restore_From_File') - procedure Screen_Restore_From_File (Filename : in String); - -- AKA - - -- ANCHOR(`scr_init()',`Screen_Init_From_File') - procedure Screen_Init_From_File (Filename : in String); - -- AKA - - -- ANCHOR(`scr_set()',`Screen_Set_File') - procedure Screen_Set_File (Filename : in String); - -- AKA - - -- MANPAGE(`curs_print.3x') - -- Not implemented: mcprint - - -- MANPAGE(`curs_printw.3x') - -- Not implemented: printw, wprintw, mvprintw, mvwprintw, vwprintw, - -- vw_printw - -- Please use the Ada style Text_IO child packages for formatted - -- printing. It doesn't make a lot of sense to map the printf style - -- C functions to Ada. - - -- MANPAGE(`curs_scanw.3x') - -- Not implemented: scanw, wscanw, mvscanw, mvwscanw, vwscanw, vw_scanw - - - -- MANPAGE(`resizeterm.3x') - -- Not Implemented: resizeterm - - -- MANPAGE(`wresize.3x') - - -- ANCHOR(`wresize()',`Resize') - procedure Resize (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count); - -- AKA - -private - type Window is new System.Storage_Elements.Integer_Address; - Null_Window : constant Window := 0; - - -- The next constants are generated and may be different on your - -- architecture. - -- -include(`Window_Offsets')dnl - Curses_Bool_False : constant Curses_Bool := 0; - -end Terminal_Interface.Curses; diff --git a/contrib/ncurses-5.4/Ada95/samples/Makefile.in b/contrib/ncurses-5.4/Ada95/samples/Makefile.in deleted file mode 100644 index 8c8dd72f09..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/Makefile.in +++ /dev/null @@ -1,153 +0,0 @@ -############################################################################## -# Copyright (c) 1998 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Juergen Pfeifer, 1996 -# -# Version Control -# $Revision: 1.30 $ -# -.SUFFIXES: - -SHELL = /bin/sh -THIS = Makefile - -x = @PROG_EXT@ - -srcdir = @srcdir@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ -libdir = @libdir@ -includedir = @includedir@ - -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ - -AWK = @AWK@ -LN_S = @LN_S@ - -CC = @CC@ -CFLAGS = @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_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@ - -CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@) - -LINK = $(CC) -LDFLAGS = @LDFLAGS@ @LD_MODEL@ @LIBS@ - -RANLIB = @RANLIB@ -################################################################################ -ada_srcdir=../src - -LD_FLAGS = @LD_MODEL@ $(LOCAL_LIBS) @LDFLAGS@ @LIBS@ @LOCAL_LDFLAGS2@ $(LDFLAGS) - -ADA = @cf_ada_compiler@ -ADAFLAGS = @ADAFLAGS@ -I$(srcdir) - -ADAMAKE = @cf_ada_make@ -ADAMAKEFLAGS = -a -A$(srcdir) -A$(ada_srcdir) -A$(srcdir)/$(ada_srcdir) - -ALIB = @cf_ada_package@ -ABASE = $(ALIB)-curses - -CARGS =-cargs $(ADAFLAGS) -LARGS =-largs -L../../lib @TEST_ARGS@ $(LD_FLAGS) -lAdaCurses @EXTRA_LIBS@ - -PROGS = tour rain ncurses - -TOUR_OBJS = tour.o sample.o sample-curses_demo.o sample-explanation.o \ - sample-form_demo.o sample-function_key_setting.o \ - sample-header_handler.o sample-helpers.o \ - sample-keyboard_handler.o sample-manifest.o sample-menu_demo.o \ - sample-menu_demo-aux.o sample-text_io_demo.o \ - sample-curses_demo-attributes.o sample-curses_demo-mouse.o \ - sample-form_demo-aux.o sample-my_field_type.o - -RAIN_OBJS = rain.o status.o - -NCURSES_OBJS = ncurses.o ncurses2-getch_test.o \ - ncurses2-acs_and_scroll.o ncurses2-m.o \ - ncurses2-acs_display.o ncurses2-menu_test.o \ - ncurses2-attr_test.o ncurses2-overlap_test.o \ - ncurses2-color_edit.o ncurses2-slk_test.o \ - ncurses2-color_test.o ncurses2-test_sgr_attributes.o \ - ncurses2-demo_forms.o ncurses2-trace_set.o \ - ncurses2-demo_pad.o ncurses2-util.o \ - ncurses2-demo_panels.o ncurses2.o \ - ncurses2-flushinp_test.o - - -all :: tour$x rain$x ncurses$x - @ - -sources : - @ - -libs \ -install \ -install.libs :: - @ - -uninstall \ -uninstall.libs :: - @ - -ncurses$x : - $(ADAMAKE) $(ADAMAKEFLAGS) ncurses $(CARGS) $(LARGS) - -tour$x : explain.msg - $(ADAMAKE) $(ADAMAKEFLAGS) tour $(CARGS) $(LARGS) - -explain.msg: $(srcdir)/explain.txt - cp $(srcdir)/explain.txt $@ - -rain$x : - $(ADAMAKE) $(ADAMAKEFLAGS) rain $(CARGS) $(LARGS) - -mostlyclean: - @ - -clean :: mostlyclean - rm -f *.o *.ali b_t*.* *.s $(PROGS) a.out core b_*_test.c *.xr[bs] \ - explain.msg trace screendump - -distclean :: clean - rm -f Makefile - -realclean :: distclean - @ - - diff --git a/contrib/ncurses-5.4/Ada95/samples/README b/contrib/ncurses-5.4/Ada95/samples/README deleted file mode 100644 index 6ea8a18ec6..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/README +++ /dev/null @@ -1,6 +0,0 @@ -The intention of the demo at this point in time is not to demonstrate all -the features of (n)curses and it's subsystems, but to give some sample -sources how to use the binding at all. - -Ideally in the future we can combine both goals. - diff --git a/contrib/ncurses-5.4/Ada95/samples/explain.txt b/contrib/ncurses-5.4/Ada95/samples/explain.txt deleted file mode 100644 index 570f617bf9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/explain.txt +++ /dev/null @@ -1,186 +0,0 @@ -#VERSION -This is Version 00.90.00 of the demo package. -#MENUKEYS -In a menu you can use the following Keys in the whole application: - - - CTRL-X eXit the menu - - CTRL-N Go to next item - - CTRL-P Go to previous item - - CTRL-U Scroll up one line - - CTRL-D Scroll down one line - - CTRL-F Scroll down one page - - PAGE DOWN Scroll down one page - - PAGE UP Scroll back one page - - CTRL-B Scroll back one page - - CTRL-Y Clear pattern - - CTRL-H Delete last character from pattern - - Backspace Delete last character from pattern - - CTRL-A Next pattern match - - CTRL-E Previous pattern match - - CTRL-T Toggle item in a multi-selection menu - - CR or LF Select an item - - HOME Key Go to the first item - - F3 Quit the menu - - Cursor Down Down one item - - Cursor Up Up one item - - Cursor Left Left one item - - Cursor Right Right one item - - END Key Go to last item -#FORMKEYS - - CTRL-X eXit the form - - CTRL-F Go forward to the next field - - CTRL-B Go backward to the previous field - - CTRL-L Go to the field left of the current one - - CTRL-R Go to the field right of the current one - - CTRL-U Go to the field above the current one - - CTRL-D Go to the field below the current one - - - CTRL-W Go to the next word in the field - - CTRL-T Go to the previous word in the field - - - CTRL-A Go to the beginning of the field - - CTRL-E Go to the end of the field - - - CTRL-I Insert a blank character at the current position - - CTRL-O Insert a line - - CTRL-V Delete a character - - CTRL-H Delete previous character - - CTRL-Y Delete a line - - CTRL-G Delete a word - - CTRL-K Clear to end of field - - - CTRL-N Next choice in a choice field (Enumerations etc.) - - CTRL-P Previous choice in a choice field. -#HELP -#HELPKEYS -You may scroll with the Cursor Up/Down Keys. -You may leave the help with the Function Key labelled 'Quit'. -#INHELP -You are already in the help system. -You may leave the help with the Function Key labelled 'Quit'. -#MAIN -This is the main menu of the sample program for the ncurses Ada95 -binding. The main intention of the demo is not to demonstate or -test all the features of ncurses and it's subsystems, but to provide -to you some sample code how to use the binding with Ada95. - -You may select this options: - - * Look at some ncurses core functions - * Look at some features of the menu subsystem - * Look at some features of the form subsystem - * Look at the output of the Ada.Text_IO like functions - for ncurses. - -#MAINPAD -You may press at any place in this demo CTRL-C. This will give you a command -window. You can just type in the Label-String of a function key, then this -key will be simulated. This should help you to run the application even if -you run it on a terminal with no or only a few function keys. With CTRL-N -and CTRL-P you may browse through the possible values in the command window. -#MENU00 -Here we give you a selection of various menu demonstrations. -#MENU-PAD00 -This menu itself is a demo for a single valued, 1-column menu with -descriptions for the items, a marker and a padding character between -the item name and the description. -#MENU01 -This is a demo of the some of the menu layout options. One of them -is the spacing functionality. Just press the Key labelled "Flip" to -flip between the non-spaced and a spaced version of the menu. Please -note that this functionality is unique for ncurses and is not found -in the SVr4 menu implementation. - -This is a menu that sometimes doesn't fit into it's window and -therefore it becomes a scroll menu. - -You can also see here very nicely the pattern matching functionality -of menus. Type for example a 'J' and you will be positioned to the -next item after the current starting with a 'J'. Any more characters -you type in make the pattern more specific. With CTRL-A and CTRL-Z -(for more details press the Key labelled "Keys") you can browse -through all the items matching the pattern. - -You may change the format of the menu. Just press one of the keys -labelled "4x1", "4x2" or "4x3" to get a menu with that many rows -and columns. - -With the Keys "O-Row" or "O-Col" (they occupy the same label and -switch on selection) you can change the major order scheme for -the menu. If "O-Col" is visible, the menu is currently major -ordered by rows, you can switch to major column order by pressing -the key. If "O-Row" is visible, it's just the reverse situation. -This Key is not visible in "4x1" layout mode, because in this case -the functionality makes no sense. - -With the Keys "Multi" or "Singl" (they occupy the same label and -switch on selection) you can change whether or not the menu allows -multiple or only single selection. - -With the Keys "+Desc" or "-Desc" (they occupy the same label and -switch on selection) you can change whether or not the descriptions -for each item should be displayed. Please not that this key is -not visible in the "4x3" layout mode, because in this case the -menu wouldn't fit on a typicall 80x24 screen. - -With the Keys "Disab" or "Enab" (they occupy the same label and -switch on selection) you can dis- or enable the selectability of -the month with 31 days. -#MENU-PAD01 -You may press "Flip" to see the effect of ncurses unique menu-spacing. -The Keys "4x1", "4x2" and "4x3" will change the format of the menu. -Please note that this is a scrolling menu. You may also play with the -pattern matching functionality or try to change the format of the menu. -For more details press the Key labelled "Help". -#FORM00 -This is a demo of the forms package. -#FORM-PAD00 -Please note that this demo is far from being complete. It really shows -only a small part of the functionality of the forms package. Let's hope -the next version will have a richer demo (You wan't to contribute ?). -#NOTIMPL -Sorry this functionality of the demo is not implemented at the moment. -Remember this is a freeware project, so I can use only my very rare -free time to continue coding. If you would like to contribute, you -are very welcome ! -#CURSES00 -This is a menu where you can select some different demos of the ncurses -functionality. -#CURSES-PAD00 -Please note that this demo is far from being complete. It really shows -only a small part of the functionality of the curses package. Let's hope -the next version will have a richer demo (You wan't to contribute ?). -#MOUSEKEYS -In this demo you may use this keys: - - - Key labelled "Help" to get a help - - Key labelled "Keys" is what you are reading now - - Key labelled "Quit" to leave the demo - -You may click the mouse buttons at any location at the screen and look -at the protocol window ! -#MOUSE00 -A rather simple use of a mouse as demo. It's there just to test the -code and to provide the sample source. - -It might be of interest, that the output into the protocol window is -done by the (n)curses Text_IO subpackages. Especially the output of -the button and state names is done by Ads's enumeration IO, which -allows you to print the names of enumeration literals. That's really -nice. -#MOUSE-PAD00 -This is a very simple demo of the mouse features of ncurses. It's there -just to test whether or not the generated code for the binding really -works on the different architectures (seems so). -#ATTRIBDEMO -Again this is a more than simple demo and just here to give you the -sourcecode. -#ATTRIBKEYS -You may press one of the three well known standard keys of this demo. -#ATTRIB-PAD00 -Again this is a more than simple demo and just here to give you the -sourcecode. Feel free to contribute more. -#TEXTIO -#TEXTIOKEYS -#TEXTIO-PAD00 -#END diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses.adb deleted file mode 100644 index 19f658d563..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses.adb +++ /dev/null @@ -1,47 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.m; use ncurses2.m; -with GNAT.OS_Lib; use GNAT.OS_Lib; - -procedure ncurses is -begin - OS_Exit (main); -end ncurses; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.adb deleted file mode 100644 index 65c2939a85..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.adb +++ /dev/null @@ -1,722 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- Windows and scrolling tester. --- Demonstrate windows - -with Ada.Strings.Fixed; -with Ada.Strings; - -with ncurses2.util; use ncurses2.util; -with ncurses2.genericPuts; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; -with Terminal_Interface.Curses.PutWin; use Terminal_Interface.Curses.PutWin; - -with Ada.Streams.Stream_IO; use Ada.Streams.Stream_IO; -with Ada.Streams; use Ada.Streams; - -procedure ncurses2.acs_and_scroll is - - - Macro_Quit : constant Key_Code := Character'Pos ('Q') mod 16#20#; - Macro_Escape : constant Key_Code := Character'Pos ('[') mod 16#20#; - - Quit : constant Key_Code := CTRL ('Q'); - Escape : constant Key_Code := CTRL ('['); - - - Botlines : constant Line_Position := 4; - - type pair is record - y : Line_Position; - x : Column_Position; - end record; - - type Frame; - type FrameA is access Frame; - - f : File_Type; - dumpfile : constant String := "screendump"; - - procedure Outerbox (ul, lr : pair; onoff : Boolean); - function HaveKeyPad (w : Window) return Boolean; - function HaveScroll (w : Window) return Boolean; - procedure newwin_legend (curpw : Window); - procedure transient (curpw : Window; msg : String); - procedure newwin_report (win : Window := Standard_Window); - procedure selectcell (uli : Line_Position; - ulj : Column_Position; - lri : Line_Position; - lrj : Column_Position; - p : out pair; - b : out Boolean); - function getwindow return Window; - procedure newwin_move (win : Window; - dy : Line_Position; - dx : Column_Position); - function delete_framed (fp : FrameA; showit : Boolean) return FrameA; - - use Ada.Streams.Stream_IO; - - - -- A linked list - -- I wish there was a standard library linked list. Oh well. - type Frame is record - next, last : FrameA; - do_scroll : Boolean; - do_keypad : Boolean; - wind : Window; - end record; - - current : FrameA; - - c : Key_Code; - - procedure Outerbox (ul, lr : pair; onoff : Boolean) is - begin - if onoff then - -- Note the fix of an obscure bug - -- try making a 1x1 box then enlarging it, the is a blank - -- upper left corner! - Add (Line => ul.y - 1, Column => ul.x - 1, - Ch => ACS_Map (ACS_Upper_Left_Corner)); - Add (Line => ul.y - 1, Column => lr.x + 1, - Ch => ACS_Map (ACS_Upper_Right_Corner)); - Add (Line => lr.y + 1, Column => lr.x + 1, - Ch => ACS_Map (ACS_Lower_Right_Corner)); - Add (Line => lr.y + 1, Column => ul.x - 1, - Ch => ACS_Map (ACS_Lower_Left_Corner)); - - Move_Cursor (Line => ul.y - 1, Column => ul.x); - Horizontal_Line (Line_Symbol => ACS_Map (ACS_Horizontal_Line), - Line_Size => Integer (lr.x - ul.x) + 1); - Move_Cursor (Line => ul.y, Column => ul.x - 1); - Vertical_Line (Line_Symbol => ACS_Map (ACS_Vertical_Line), - Line_Size => Integer (lr.y - ul.y) + 1); - Move_Cursor (Line => lr.y + 1, Column => ul.x); - Horizontal_Line (Line_Symbol => ACS_Map (ACS_Horizontal_Line), - Line_Size => Integer (lr.x - ul.x) + 1); - Move_Cursor (Line => ul.y, Column => lr.x + 1); - Vertical_Line (Line_Symbol => ACS_Map (ACS_Vertical_Line), - Line_Size => Integer (lr.y - ul.y) + 1); - else - Add (Line => ul.y - 1, Column => ul.x - 1, Ch => ' '); - Add (Line => ul.y - 1, Column => lr.x + 1, Ch => ' '); - Add (Line => lr.y + 1, Column => lr.x + 1, Ch => ' '); - Add (Line => lr.y + 1, Column => ul.x - 1, Ch => ' '); - - Move_Cursor (Line => ul.y - 1, Column => ul.x); - Horizontal_Line (Line_Symbol => Blank2, - Line_Size => Integer (lr.x - ul.x) + 1); - Move_Cursor (Line => ul.y, Column => ul.x - 1); - Vertical_Line (Line_Symbol => Blank2, - Line_Size => Integer (lr.y - ul.y) + 1); - Move_Cursor (Line => lr.y + 1, Column => ul.x); - Horizontal_Line (Line_Symbol => Blank2, - Line_Size => Integer (lr.x - ul.x) + 1); - Move_Cursor (Line => ul.y, Column => lr.x + 1); - Vertical_Line (Line_Symbol => Blank2, - Line_Size => Integer (lr.y - ul.y) + 1); - end if; - end Outerbox; - - function HaveKeyPad (w : Window) return Boolean is - begin - return Get_KeyPad_Mode (w); - exception - when Curses_Exception => return False; - end HaveKeyPad; - - function HaveScroll (w : Window) return Boolean is - begin - return Scrolling_Allowed (w); - exception - when Curses_Exception => return False; - end HaveScroll; - - - procedure newwin_legend (curpw : Window) is - - package p is new genericPuts (200); - use p; - use p.BS; - - type string_a is access String; - - type rrr is record - msg : string_a; - code : Integer range 0 .. 3; - end record; - - legend : constant array (Positive range <>) of rrr := - ( - ( - new String'("^C = create window"), 0 - ), - ( - new String'("^N = next window"), 0 - ), - ( - new String'("^P = previous window"), 0 - ), - ( - new String'("^F = scroll forward"), 0 - ), - ( - new String'("^B = scroll backward"), 0 - ), - ( - new String'("^K = keypad(%s)"), 1 - ), - ( - new String'("^S = scrollok(%s)"), 2 - ), - ( - new String'("^W = save window to file"), 0 - ), - ( - new String'("^R = restore window"), 0 - ), - ( - new String'("^X = resize"), 0 - ), - ( - new String'("^Q%s = exit"), 3 - ) - ); - - buf : Bounded_String; - do_keypad : Boolean := HaveKeyPad (curpw); - do_scroll : Boolean := HaveScroll (curpw); - - pos : Natural; - - mypair : pair; - - use Ada.Strings.Fixed; - - begin - Move_Cursor (Line => Lines - 4, Column => 0); - for n in legend'Range loop - pos := Ada.Strings.Fixed.Index (Source => legend (n).msg.all, - Pattern => "%s"); - -- buf := (others => ' '); - buf := To_Bounded_String (legend (n).msg.all); - case legend (n).code is - when 0 => null; - when 1 => - if do_keypad then - Replace_Slice (buf, pos, pos + 1, "yes"); - else - Replace_Slice (buf, pos, pos + 1, "no"); - end if; - when 2 => - if do_scroll then - Replace_Slice (buf, pos, pos + 1, "yes"); - else - Replace_Slice (buf, pos, pos + 1, "no"); - end if; - when 3 => - if do_keypad then - Replace_Slice (buf, pos, pos + 1, "/ESC"); - else - Replace_Slice (buf, pos, pos + 1, ""); - end if; - end case; - Get_Cursor_Position (Line => mypair.y, Column => mypair.x); - if Columns < mypair.x + 3 + Column_Position (Length (buf)) then - Add (Ch => newl); - elsif n /= 1 then -- n /= legen'First - Add (Str => ", "); - end if; - myAdd (Str => buf); - end loop; - Clear_To_End_Of_Line; - end newwin_legend; - - - procedure transient (curpw : Window; msg : String) is - begin - newwin_legend (curpw); - if msg /= "" then - Add (Line => Lines - 1, Column => 0, Str => msg); - Refresh; - Nap_Milli_Seconds (1000); - end if; - - Move_Cursor (Line => Lines - 1, Column => 0); - - if HaveKeyPad (curpw) then - Add (Str => "Non-arrow"); - else - Add (Str => "All other"); - end if; - Add (str => " characters are echoed, window should "); - if not HaveScroll (curpw) then - Add (Str => "not "); - end if; - Add (str => "scroll"); - - Clear_To_End_Of_Line; - end transient; - - - procedure newwin_report (win : Window := Standard_Window) is - y : Line_Position; - x : Column_Position; - use Int_IO; - tmp2a : String (1 .. 2); - tmp2b : String (1 .. 2); - begin - if win /= Standard_Window then - transient (win, ""); - end if; - Get_Cursor_Position (win, y, x); - Move_Cursor (Line => Lines - 1, Column => Columns - 17); - Put (tmp2a, Integer (y)); - Put (tmp2b, Integer (x)); - Add (Str => "Y = " & tmp2a & " X = " & tmp2b); - if win /= Standard_Window then - Refresh; - else - Move_Cursor (win, y, x); - end if; - end newwin_report; - - procedure selectcell (uli : Line_Position; - ulj : Column_Position; - lri : Line_Position; - lrj : Column_Position; - p : out pair; - b : out Boolean) is - c : Key_Code; - res : pair; - i : Line_Position := 0; - j : Column_Position := 0; - si : Line_Position := lri - uli + 1; - sj : Column_Position := lrj - ulj + 1; - begin - res.y := uli; - res.x := ulj; - loop - Move_Cursor (Line => uli + i, Column => ulj + j); - newwin_report; - - c := Getchar; - case c is - when - Macro_Quit | - Macro_Escape => - -- on the same line macro calls interfere due to the # comment - -- this is needed because keypad off affects all windows. - -- try removing the ESCAPE and see what happens. - b := False; - return; - when KEY_UP => - i := i + si - 1; - -- same as i := i - 1 because of Modulus arithetic, - -- on Line_Position, which is a Natural - -- the C version uses this form too, interestingly. - when KEY_DOWN => - i := i + 1; - when KEY_LEFT => - j := j + sj - 1; - when KEY_RIGHT => - j := j + 1; - when Key_Mouse => - declare - event : Mouse_Event; - y : Line_Position; - x : Column_Position; - Button : Mouse_Button; - State : Button_State; - - begin - event := Get_Mouse; - Get_Event (Event => event, - Y => y, - X => x, - Button => Button, - State => State); - if y > uli and x > ulj then - i := y - uli; - j := x - ulj; - -- same as when others => - res.y := uli + i; - res.x := ulj + j; - p := res; - b := True; - return; - else - Beep; - end if; - end; - when others => - res.y := uli + i; - res.x := ulj + j; - p := res; - b := True; - return; - end case; - i := i mod si; - j := j mod sj; - end loop; - end selectcell; - - - function getwindow return Window is - rwindow : Window; - ul, lr : pair; - result : Boolean; - begin - Move_Cursor (Line => 0, Column => 0); - Clear_To_End_Of_Line; - Add (Str => "Use arrows to move cursor, anything else to mark corner 1"); - Refresh; - selectcell (2, 1, Lines - Botlines - 2, Columns - 2, ul, result); - if not result then - return Null_Window; - end if; - Add (Line => ul.y - 1, Column => ul.x - 1, - Ch => ACS_Map (ACS_Upper_Left_Corner)); - Move_Cursor (Line => 0, Column => 0); - Clear_To_End_Of_Line; - Add (Str => "Use arrows to move cursor, anything else to mark corner 2"); - Refresh; - selectcell (ul.y, ul.x, Lines - Botlines - 2, Columns - 2, lr, result); - if not result then - return Null_Window; - end if; - - rwindow := Sub_Window (Number_Of_Lines => lr.y - ul.y + 1, - Number_Of_Columns => lr.x - ul.x + 1, - First_Line_Position => ul.y, - First_Column_Position => ul.x); - - Outerbox (ul, lr, True); - Refresh; - - Refresh (rwindow); - - Move_Cursor (Line => 0, Column => 0); - Clear_To_End_Of_Line; - return rwindow; - end getwindow; - - - procedure newwin_move (win : Window; - dy : Line_Position; - dx : Column_Position) is - cur_y, max_y : Line_Position; - cur_x, max_x : Column_Position; - begin - Get_Cursor_Position (win, cur_y, cur_x); - Get_Size (win, max_y, max_x); - cur_x := Column_Position'Min (Column_Position'Max (cur_x + dx, 0), - max_x - 1); - cur_y := Line_Position'Min (Line_Position'Max (cur_y + dy, 0), - max_y - 1); - - Move_Cursor (win, Line => cur_y, Column => cur_x); - end newwin_move; - - function delete_framed (fp : FrameA; showit : Boolean) return FrameA is - np : FrameA; - begin - fp.last.next := fp.next; - fp.next.last := fp.last; - - if showit then - Erase (fp.wind); - Refresh (fp.wind); - end if; - Delete (fp.wind); - - if fp = fp.next then - np := null; - else - np := fp.next; - end if; - -- TODO free(fp); - return np; - end delete_framed; - - Mask : Event_Mask := No_Events; - Mask2 : Event_Mask; - - usescr : Window; - -begin - if Has_Mouse then - Register_Reportable_Event ( - Button => Left, - State => Clicked, - Mask => Mask); - Mask2 := Start_Mouse (Mask); - end if; - c := CTRL ('C'); - Set_Raw_Mode (SwitchOn => True); - loop - transient (Standard_Window, ""); - case c is - when Character'Pos ('c') mod 16#20# => -- Ctrl('c') - declare - neww : FrameA := new Frame'(null, null, False, False, - Null_Window); - begin - neww.wind := getwindow; - if neww.wind = Null_Window then - exit; - -- was goto breakout; ha ha ha - else - - if current = null then - neww.next := neww; - neww.last := neww; - else - neww.next := current.next; - neww.last := current; - neww.last.next := neww; - neww.next.last := neww; - end if; - current := neww; - - Set_KeyPad_Mode (current.wind, True); - current.do_keypad := HaveKeyPad (current.wind); - current.do_scroll := HaveScroll (current.wind); - end if; - end; - when Character'Pos ('N') mod 16#20# => -- Ctrl('N') - if current /= null then - current := current.next; - end if; - when Character'Pos ('P') mod 16#20# => -- Ctrl('P') - if current /= null then - current := current.last; - end if; - when Character'Pos ('F') mod 16#20# => -- Ctrl('F') - if current /= null and HaveScroll (current.wind) then - Scroll (current.wind, 1); - end if; - when Character'Pos ('B') mod 16#20# => -- Ctrl('B') - if current /= null and HaveScroll (current.wind) then - -- The C version of Scroll may return ERR which is ignored - -- we need to avoid the exception - -- with the 'and HaveScroll(current.wind)' - Scroll (current.wind, -1); - end if; - when Character'Pos ('K') mod 16#20# => -- Ctrl('K') - if current /= null then - current.do_keypad := not current.do_keypad; - Set_KeyPad_Mode (current.wind, current.do_keypad); - end if; - when Character'Pos ('S') mod 16#20# => -- Ctrl('S') - if current /= null then - current.do_scroll := not current.do_scroll; - Allow_Scrolling (current.wind, current.do_scroll); - end if; - when Character'Pos ('W') mod 16#20# => -- Ctrl('W') - if current /= current.next then - Create (f, Name => dumpfile); -- TODO error checking - if not Is_Open (f) then - raise Curses_Exception; - end if; - Put_Window (current.wind, f); - Close (f); - current := delete_framed (current, True); - end if; - when Character'Pos ('R') mod 16#20# => -- Ctrl('R') - declare - neww : FrameA := new Frame'(null, null, False, False, - Null_Window); - begin - Open (f, Mode => In_File, Name => dumpfile); - neww := new Frame'(null, null, False, False, Null_Window); - - neww.next := current.next; - neww.last := current; - neww.last.next := neww; - neww.next.last := neww; - - neww.wind := Get_Window (f); - Close (f); - - Refresh (neww.wind); - end; - when Character'Pos ('X') mod 16#20# => -- Ctrl('X') - if current /= null then - declare - tmp, ul, lr : pair; - mx : Column_Position; - my : Line_Position; - tmpbool : Boolean; - begin - Move_Cursor (Line => 0, Column => 0); - Clear_To_End_Of_Line; - Add (Str => "Use arrows to move cursor, anything else " & - "to mark new corner"); - Refresh; - - Get_Window_Position (current.wind, ul.y, ul.x); - - selectcell (ul.y, ul.x, Lines - Botlines - 2, Columns - 2, - tmp, tmpbool); - if not tmpbool then - -- the C version had a goto. I refuse gotos. - Beep; - else - Get_Size (current.wind, lr.y, lr.x); - lr.y := lr.y + ul.y - 1; - lr.x := lr.x + ul.x - 1; - Outerbox (ul, lr, False); - Refresh_Without_Update; - - Get_Size (current.wind, my, mx); - if my > tmp.y - ul.y then - Get_Cursor_Position (current.wind, lr.y, lr.x); - Move_Cursor (current.wind, tmp.y - ul.y + 1, 0); - Clear_To_End_Of_Screen (current.wind); - Move_Cursor (current.wind, lr.y, lr.x); - end if; - if mx > tmp.x - ul.x then - for i in 0 .. my - 1 loop - Move_Cursor (current.wind, i, tmp.x - ul.x + 1); - Clear_To_End_Of_Line (current.wind); - end loop; - end if; - Refresh_Without_Update (current.wind); - - lr := tmp; - -- The C version passes invalid args to resize - -- which returns an ERR. For Ada we avoid the exception. - if lr.y /= ul.y and lr.x /= ul.x then - Resize (current.wind, lr.y - ul.y + 0, - lr.x - ul.x + 0); - end if; - - Get_Window_Position (current.wind, ul.y, ul.x); - Get_Size (current.wind, lr.y, lr.x); - lr.y := lr.y + ul.y - 1; - lr.x := lr.x + ul.x - 1; - Outerbox (ul, lr, True); - Refresh_Without_Update; - - Refresh_Without_Update (current.wind); - Move_Cursor (Line => 0, Column => 0); - Clear_To_End_Of_Line; - Update_Screen; - end if; - end; - end if; - when Key_F10 => - declare tmp : pair; tmpbool : Boolean; - begin - -- undocumented --- use this to test area clears - selectcell (0, 0, Lines - 1, Columns - 1, tmp, tmpbool); - Clear_To_End_Of_Screen; - Refresh; - end; - when Key_Cursor_Up => - newwin_move (current.wind, -1, 0); - when Key_Cursor_Down => - newwin_move (current.wind, 1, 0); - when Key_Cursor_Left => - newwin_move (current.wind, 0, -1); - when Key_Cursor_Right => - newwin_move (current.wind, 0, 1); - when Key_Backspace | Key_Delete_Char => - declare - y : Line_Position; - x : Column_Position; - tmp : Line_Position; - begin - Get_Cursor_Position (current.wind, y, x); - -- x := x - 1; - -- I got tricked by the -1 = Max_Natural - 1 result - -- y := y - 1; - if not (x = 0 and y = 0) then - if x = 0 then - y := y - 1; - Get_Size (current.wind, tmp, x); - end if; - x := x - 1; - Delete_Character (current.wind, y, x); - end if; - end; - when others => - -- TODO c = '\r' ? - if current /= null then - declare - begin - Add (current.wind, Ch => Code_To_Char (c)); - exception - when Curses_Exception => null; - -- this happens if we are at the - -- lower right of a window and add a character. - end; - else - Beep; - end if; - end case; - newwin_report (current.wind); - if current /= null then - usescr := current.wind; - else - usescr := Standard_Window; - end if; - Refresh (usescr); - c := Getchar (usescr); - exit when c = Quit or (c = Escape and HaveKeyPad (usescr)); - -- TODO when does c = ERR happen? - end loop; - - -- TODO while current /= null loop - -- current := delete_framed(current, False); - -- end loop; - - Allow_Scrolling (Mode => True); - - End_Mouse; - Set_Raw_Mode (SwitchOn => True); - Erase; - End_Windows; - -end ncurses2.acs_and_scroll; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.ads deleted file mode 100644 index 79e4862af0..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_and_scroll.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.acs_and_scroll; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.adb deleted file mode 100644 index ab07213249..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.adb +++ /dev/null @@ -1,231 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with ncurses2.genericPuts; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Ada.Strings.Unbounded; -with Ada.Strings.Fixed; - -procedure ncurses2.acs_display is - use Int_IO; - - procedure show_upper_chars (first : Integer); - function show_1_acs (N : Integer; - name : String; - code : Attributed_Character) - return Integer; - procedure show_acs_chars; - - - procedure show_upper_chars (first : Integer) is - C1 : Boolean := (first = 128); - last : Integer := first + 31; - package p is new ncurses2.genericPuts (200); - use p; - use p.BS; - use Ada.Strings.Unbounded; - - tmpa : Unbounded_String; - tmpb : BS.Bounded_String; - begin - Erase; - Switch_Character_Attribute - (Attr => (Bold_Character => True, others => False)); - Move_Cursor (Line => 0, Column => 20); - tmpa := To_Unbounded_String ("Display of "); - if C1 then - tmpa := tmpa & "C1"; - else - tmpa := tmpa & "GR"; - end if; - tmpa := tmpa & " Character Codes "; - myPut (tmpb, first); - Append (tmpa, To_String (tmpb)); - Append (tmpa, " to "); - myPut (tmpb, last); - Append (tmpa, To_String (tmpb)); - Add (Str => To_String (tmpa)); - Switch_Character_Attribute - (On => False, - Attr => (Bold_Character => True, others => False)); - Refresh; - - for code in first .. last loop - declare - row : Line_Position := Line_Position (4 + ((code - first) mod 16)); - col : Column_Position := Column_Position (((code - first) / 16) * - Integer (Columns) / 2); - tmp3 : String (1 .. 3); - tmpx : String (1 .. Integer (Columns / 4)); - reply : Key_Code; - begin - Put (tmp3, code); - myPut (tmpb, code, 16); - tmpa := To_Unbounded_String (tmp3 & " (" & To_String (tmpb) & ')'); - - Ada.Strings.Fixed.Move (To_String (tmpa), tmpx, - Justify => Ada.Strings.Right); - Add (Line => row, Column => col, - Str => tmpx & ' ' & ':' & ' '); - if C1 then - Set_NoDelay_Mode (Mode => True); - end if; - Add_With_Immediate_Echo (Ch => Code_To_Char (Key_Code (code))); - -- TODO check this - if C1 then - reply := Getchar; - while reply /= Key_None loop - Add (Ch => Code_To_Char (reply)); - Nap_Milli_Seconds (10); - reply := Getchar; - end loop; - Set_NoDelay_Mode (Mode => False); - end if; - end; - end loop; - end show_upper_chars; - - function show_1_acs (N : Integer; - name : String; - code : Attributed_Character) - return Integer is - height : constant Integer := 16; - row : Line_Position := Line_Position (4 + (N mod height)); - col : Column_Position := Column_Position ((N / height) * - Integer (Columns) / 2); - tmpx : String (1 .. Integer (Columns) / 3); - begin - Ada.Strings.Fixed.Move (name, tmpx, - Justify => Ada.Strings.Right, - Drop => Ada.Strings.Left); - Add (Line => row, Column => col, Str => tmpx & ' ' & ':' & ' '); - -- we need more room than C because our identifiers are longer - -- 22 chars actually - Add (Ch => code); - return N + 1; - end show_1_acs; - - procedure show_acs_chars is - n : Integer; - begin - Erase; - Switch_Character_Attribute - (Attr => (Bold_Character => True, others => False)); - Add (Line => 0, Column => 20, - Str => "Display of the ACS Character Set"); - Switch_Character_Attribute (On => False, - Attr => (Bold_Character => True, - others => False)); - Refresh; - - -- the following is useful to generate the below - -- grep '^[ ]*ACS_' ../src/terminal_interface-curses.ads | - -- awk '{print "n := show_1_acs(n, \""$1"\", ACS_Map("$1"));"}' - - n := show_1_acs (0, "ACS_Upper_Left_Corner", - ACS_Map (ACS_Upper_Left_Corner)); - n := show_1_acs (n, "ACS_Lower_Left_Corner", - ACS_Map (ACS_Lower_Left_Corner)); - n := show_1_acs (n, "ACS_Upper_Right_Corner", - ACS_Map (ACS_Upper_Right_Corner)); - n := show_1_acs (n, "ACS_Lower_Right_Corner", - ACS_Map (ACS_Lower_Right_Corner)); - n := show_1_acs (n, "ACS_Left_Tee", ACS_Map (ACS_Left_Tee)); - n := show_1_acs (n, "ACS_Right_Tee", ACS_Map (ACS_Right_Tee)); - n := show_1_acs (n, "ACS_Bottom_Tee", ACS_Map (ACS_Bottom_Tee)); - n := show_1_acs (n, "ACS_Top_Tee", ACS_Map (ACS_Top_Tee)); - n := show_1_acs (n, "ACS_Horizontal_Line", - ACS_Map (ACS_Horizontal_Line)); - n := show_1_acs (n, "ACS_Vertical_Line", ACS_Map (ACS_Vertical_Line)); - n := show_1_acs (n, "ACS_Plus_Symbol", ACS_Map (ACS_Plus_Symbol)); - n := show_1_acs (n, "ACS_Scan_Line_1", ACS_Map (ACS_Scan_Line_1)); - n := show_1_acs (n, "ACS_Scan_Line_9", ACS_Map (ACS_Scan_Line_9)); - n := show_1_acs (n, "ACS_Diamond", ACS_Map (ACS_Diamond)); - n := show_1_acs (n, "ACS_Checker_Board", ACS_Map (ACS_Checker_Board)); - n := show_1_acs (n, "ACS_Degree", ACS_Map (ACS_Degree)); - n := show_1_acs (n, "ACS_Plus_Minus", ACS_Map (ACS_Plus_Minus)); - n := show_1_acs (n, "ACS_Bullet", ACS_Map (ACS_Bullet)); - n := show_1_acs (n, "ACS_Left_Arrow", ACS_Map (ACS_Left_Arrow)); - n := show_1_acs (n, "ACS_Right_Arrow", ACS_Map (ACS_Right_Arrow)); - n := show_1_acs (n, "ACS_Down_Arrow", ACS_Map (ACS_Down_Arrow)); - n := show_1_acs (n, "ACS_Up_Arrow", ACS_Map (ACS_Up_Arrow)); - n := show_1_acs (n, "ACS_Board_Of_Squares", - ACS_Map (ACS_Board_Of_Squares)); - n := show_1_acs (n, "ACS_Lantern", ACS_Map (ACS_Lantern)); - n := show_1_acs (n, "ACS_Solid_Block", ACS_Map (ACS_Solid_Block)); - n := show_1_acs (n, "ACS_Scan_Line_3", ACS_Map (ACS_Scan_Line_3)); - n := show_1_acs (n, "ACS_Scan_Line_7", ACS_Map (ACS_Scan_Line_7)); - n := show_1_acs (n, "ACS_Less_Or_Equal", ACS_Map (ACS_Less_Or_Equal)); - n := show_1_acs (n, "ACS_Greater_Or_Equal", - ACS_Map (ACS_Greater_Or_Equal)); - n := show_1_acs (n, "ACS_PI", ACS_Map (ACS_PI)); - n := show_1_acs (n, "ACS_Not_Equal", ACS_Map (ACS_Not_Equal)); - n := show_1_acs (n, "ACS_Sterling", ACS_Map (ACS_Sterling)); - - end show_acs_chars; - - c1 : Key_Code; - c : Character := 'a'; -begin - loop - case c is - when 'a' => - show_acs_chars; - when '0' | '1' | '2' | '3' => - show_upper_chars (ctoi (c) * 32 + 128); - when others => - null; - end case; - Add (Line => Lines - 3, Column => 0, - Str => "Note: ANSI terminals may not display C1 characters."); - Add (Line => Lines - 2, Column => 0, - Str => "Select: a=ACS, 0=C1, 1,2,3=GR characters, q=quit"); - Refresh; - c1 := Getchar; - c := Code_To_Char (c1); - exit when c = 'q' or c = 'x'; - end loop; - Pause; - Erase; - End_Windows; -end ncurses2.acs_display; - diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.ads deleted file mode 100644 index 4e616c5e14..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-acs_display.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.acs_display; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.adb deleted file mode 100644 index d852bb7f27..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.adb +++ /dev/null @@ -1,367 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.2 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Terminfo; -use Terminal_Interface.Curses.Terminfo; -with Ada.Characters.Handling; -with Ada.Strings.Fixed; - -procedure ncurses2.attr_test is - - function subset (super, sub : Character_Attribute_Set) return Boolean; - function intersect (b, a : Character_Attribute_Set) return Boolean; - function has_A_COLOR (attr : Attributed_Character) return Boolean; - function show_attr (row : Line_Position; - skip : Natural; - attr : Character_Attribute_Set; - name : String; - once : Boolean) return Line_Position; - procedure attr_getc (skip : out Integer; - fg, bg : in out Color_Number; - result : out Boolean); - - - function subset (super, sub : Character_Attribute_Set) return Boolean is - begin - if - (super.Stand_Out or not sub.Stand_Out) and - (super.Under_Line or not sub.Under_Line) and - (super.Reverse_Video or not sub.Reverse_Video) and - (super.Blink or not sub.Blink) and - (super.Dim_Character or not sub.Dim_Character) and - (super.Bold_Character or not sub.Bold_Character) and - (super.Alternate_Character_Set or not sub.Alternate_Character_Set) and - (super.Invisible_Character or not sub.Invisible_Character) -- and --- (super.Protected_Character or not sub.Protected_Character) and --- (super.Horizontal or not sub.Horizontal) and --- (super.Left or not sub.Left) and --- (super.Low or not sub.Low) and --- (super.Right or not sub.Right) and --- (super.Top or not sub.Top) and --- (super.Vertical or not sub.Vertical) - then - return True; - else - return False; - end if; - end subset; - - - function intersect (b, a : Character_Attribute_Set) return Boolean is - begin - if - (a.Stand_Out and b.Stand_Out) or - (a.Under_Line and b.Under_Line) or - (a.Reverse_Video and b.Reverse_Video) or - (a.Blink and b.Blink) or - (a.Dim_Character and b.Dim_Character) or - (a.Bold_Character and b.Bold_Character) or - (a.Alternate_Character_Set and b.Alternate_Character_Set) or - (a.Invisible_Character and b.Invisible_Character) -- or --- (a.Protected_Character and b.Protected_Character) or --- (a.Horizontal and b.Horizontal) or --- (a.Left and b.Left) or --- (a.Low and b.Low) or --- (a.Right and b.Right) or --- (a.Top and b.Top) or --- (a.Vertical and b.Vertical) - then - return True; - else - return False; - end if; - end intersect; - - function has_A_COLOR (attr : Attributed_Character) return Boolean is - begin - if attr.Color /= Color_Pair (0) then - return True; - else - return False; - end if; - end has_A_COLOR; - - -- Print some text with attributes. - function show_attr (row : Line_Position; - skip : Natural; - attr : Character_Attribute_Set; - name : String; - once : Boolean) return Line_Position is - - function make_record (n : Integer) return Character_Attribute_Set; - function make_record (n : Integer) return Character_Attribute_Set is - -- unsupported means true - a : Character_Attribute_Set := (others => False); - m : Integer; - rest : Integer; - begin - -- ncv is a bitmap with these fields - -- A_STANDOUT, - -- A_UNDERLINE, - -- A_REVERSE, - -- A_BLINK, - -- A_DIM, - -- A_BOLD, - -- A_INVIS, - -- A_PROTECT, - -- A_ALTCHARSET - -- It means no_color_video, - -- video attributes that can't be used with colors - -- see man terminfo.5 - m := n mod 2; - rest := n / 2; - if 1 = m then - a.Stand_Out := True; - end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Under_Line := True; - end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Reverse_Video := True; - end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Blink := True; - end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Bold_Character := True; - end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Invisible_Character := True; - end if; - m := rest mod 2; - rest := rest / 2; --- if 1 = m then --- a.Protected_Character := True; --- end if; - m := rest mod 2; - rest := rest / 2; - if 1 = m then - a.Alternate_Character_Set := True; - end if; - - return a; - end make_record; - - ncv : constant Integer := Get_Number ("ncv"); - - begin - Move_Cursor (Line => row, Column => 8); - Add (Str => name & " mode:"); - Move_Cursor (Line => row, Column => 24); - Add (Ch => '|'); - if skip /= 0 then - -- printw("%*s", skip, " ") - Add (Str => Ada.Strings.Fixed."*" (skip, ' ')); - end if; - if once then - Switch_Character_Attribute (Attr => attr); - else - Set_Character_Attributes (Attr => attr); - end if; - Add (Str => "abcde fghij klmno pqrst uvwxy z"); - if once then - Switch_Character_Attribute (Attr => attr, On => False); - end if; - if skip /= 0 then - Add (Str => Ada.Strings.Fixed."*" (skip, ' ')); - end if; - Add (Ch => '|'); - if attr /= Normal_Video then - declare begin - if not subset (super => Supported_Attributes, sub => attr) then - Add (Str => " (N/A)"); - elsif ncv > 0 and has_A_COLOR (Get_Background) then - declare - Color_Supported_Attributes : - Character_Attribute_Set := make_record (ncv); - begin - if intersect (Color_Supported_Attributes, attr) then - Add (Str => " (NCV) "); - end if; - end; - end if; - end; - end if; - return row + 2; - end show_attr; - - procedure attr_getc (skip : out Integer; fg, bg : in out Color_Number; - result : out Boolean) is - ch : Key_Code := Getchar; - nc : constant Color_Number := Color_Number (Number_Of_Colors); - curscr : Window; - pragma Import (C, curscr, "curscr"); - -- curscr is not implemented in the Ada binding - begin - result := True; - if Ada.Characters.Handling.Is_Digit (Character'Val (ch)) then - skip := ctoi (Code_To_Char (ch)); - elsif ch = CTRL ('L') then - Touch; - Touch (curscr); - Refresh; - elsif Has_Colors then - case ch is - -- Note the mathematical elegance compared to the C version. - when Character'Pos ('f') => fg := (fg + 1) mod nc; - when Character'Pos ('F') => fg := (fg - 1) mod nc; - when Character'Pos ('b') => bg := (bg + 1) mod nc; - when Character'Pos ('B') => bg := (bg - 1) mod nc; - when others => - result := False; - end case; - else - result := False; - end if; - end attr_getc; - - - - -- pairs could be defined as array ( Color_Number(0) .. colors - 1) of - -- array (Color_Number(0).. colors - 1) of Boolean; - pairs : array (Color_Pair'Range) of Boolean := (others => False); - fg, bg : Color_Number := Black; -- = 0; - xmc : constant Integer := Get_Number ("xmc"); - skip : Integer := xmc; - n : Integer; - - use Int_IO; - -begin - pairs (0) := True; - - if skip < 0 then - skip := 0; - end if; - n := skip; - - loop - declare - row : Line_Position := 2; - normal : Attributed_Character := Blank2; - -- ??? - begin - -- row := 2; -- weird, row is set to 0 without this. - -- TODO delete the above line, it was a gdb quirk that confused me - if Has_Colors then declare - pair : Color_Pair := - Color_Pair (fg * Color_Number (Number_Of_Colors) + bg); - begin - -- Go though each color pair. Assume that the number of - -- Redefinable_Color_Pairs is 8*8 with predefined Colors 0..7 - if not pairs (pair) then - Init_Pair (pair, fg, bg); - pairs (pair) := True; - end if; - normal.Color := pair; - end; - end if; - Set_Background (Ch => normal); - Erase; - - Add (Line => 0, Column => 20, - Str => "Character attribute test display"); - - row := show_attr (row, n, (Stand_Out => True, others => False), - "STANDOUT", True); - row := show_attr (row, n, (Reverse_Video => True, others => False), - "REVERSE", True); - row := show_attr (row, n, (Bold_Character => True, others => False), - "BOLD", True); - row := show_attr (row, n, (Under_Line => True, others => False), - "UNDERLINE", True); - row := show_attr (row, n, (Dim_Character => True, others => False), - "DIM", True); - row := show_attr (row, n, (Blink => True, others => False), - "BLINK", True); --- row := show_attr (row, n, (Protected_Character => True, --- others => False), "PROTECT", True); - row := show_attr (row, n, (Invisible_Character => True, - others => False), "INVISIBLE", True); - row := show_attr (row, n, Normal_Video, "NORMAL", False); - - Move_Cursor (Line => row, Column => 8); - if xmc > -1 then - Add (Str => "This terminal does have the magic-cookie glitch"); - else - Add (Str => "This terminal does not have the magic-cookie glitch"); - end if; - Move_Cursor (Line => row + 1, Column => 8); - Add (Str => "Enter a digit to set gaps on each side of " & - "displayed attributes"); - Move_Cursor (Line => row + 2, Column => 8); - Add (Str => "^L = repaint"); - if Has_Colors then - declare tmp1 : String (1 .. 1); - begin - Add (Str => ". f/F/b/F toggle colors ("); - Put (tmp1, Integer (fg)); - Add (Str => tmp1); - Add (Ch => '/'); - Put (tmp1, Integer (bg)); - Add (Str => tmp1); - Add (Ch => ')'); - end; - end if; - Refresh; - end; - - declare result : Boolean; begin - attr_getc (n, fg, bg, result); - exit when not result; - end; - end loop; - - Set_Background (Ch => Blank2); - Erase; - End_Windows; -end ncurses2.attr_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.ads deleted file mode 100644 index fb1ed185b4..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-attr_test.ads +++ /dev/null @@ -1,42 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.attr_test; - diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.adb deleted file mode 100644 index ac14628fd9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.adb +++ /dev/null @@ -1,264 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with ncurses2.genericPuts; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - - -procedure ncurses2.color_edit is - use Int_IO; - - type RGB_Enum is (Redx, Greenx, Bluex); - - procedure change_color (current : Color_Number; - field : RGB_Enum; - value : RGB_Value; - usebase : Boolean); - - - - procedure change_color (current : Color_Number; - field : RGB_Enum; - value : RGB_Value; - usebase : Boolean) is - red, green, blue : RGB_Value; - begin - if usebase then - Color_Content (current, red, green, blue); - else - red := 0; - green := 0; - blue := 0; - end if; - - case field is - when Redx => red := red + value; - when Greenx => green := green + value; - when Bluex => blue := blue + value; - end case; - - declare - begin - Init_Color (current, red, green, blue); - exception - when Curses_Exception => Beep; - end; - - end change_color; - - - package x is new ncurses2.genericPuts (100); use x; - - tmpb : x.BS.Bounded_String; - - tmp4 : String (1 .. 4); - tmp6 : String (1 .. 6); - tmp8 : String (1 .. 8); - -- This would be easier if Ada had a Bounded_String - -- defined as a class instead of the inferior generic package, - -- then I could define Put, Add, and Get for them. Blech. - value : RGB_Value := 0; - red, green, blue : RGB_Value; - max_colors : constant Natural := Number_Of_Colors; - current : Color_Number := 0; - field : RGB_Enum := Redx; - this_c : Key_Code := 0; - last_c : Key_Code; -begin - Refresh; - - for i in Color_Number'(0) .. Color_Number (Number_Of_Colors) loop - Init_Pair (Color_Pair (i), White, i); - end loop; - - Move_Cursor (Line => Lines - 2, Column => 0); - Add (Str => "Number: "); - myPut (tmpb, Integer (value)); - myAdd (Str => tmpb); - - loop - - Switch_Character_Attribute (On => False, - Attr => (Bold_Character => True, - others => False)); - Add (Line => 0, Column => 20, Str => "Color RGB Value Editing"); - - Switch_Character_Attribute (On => False, - Attr => (Bold_Character => True, - others => False)); - - for i in Color_Number'(0) .. Color_Number (Number_Of_Colors) loop - Move_Cursor (Line => 2 + Line_Position (i), Column => 0); - if current = i then - Add (Ch => '>'); - else - Add (Ch => ' '); - end if; - -- TODO if i <= color_names'Max then - Put (tmp8, Integer (i)); - Set_Character_Attributes (Color => Color_Pair (i)); - Add (Str => " "); - Set_Character_Attributes; - - Refresh; - - Color_Content (i, red, green, blue); - Add (Str => " R = "); - if current = i and field = Redx then - Switch_Character_Attribute (On => True, - Attr => (Stand_Out => True, - others => False)); - end if; - Put (tmp4, Integer (red)); - Add (Str => tmp4); - if current = i and field = Redx then - Set_Character_Attributes; - end if; - Add (Str => " G = "); - if current = i and field = Greenx then - Switch_Character_Attribute (On => True, - Attr => (Stand_Out => True, - others => False)); - end if; - Put (tmp4, Integer (green)); - Add (Str => tmp4); - if current = i and field = Greenx then - Set_Character_Attributes; - end if; - Add (Str => " B = "); - if current = i and field = Bluex then - Switch_Character_Attribute (On => True, - Attr => (Stand_Out => True, - others => False)); - end if; - Put (tmp4, Integer (blue)); - Add (Str => tmp4); - if current = i and field = Bluex then - Set_Character_Attributes; - end if; - Set_Character_Attributes; - Add (ch => ')'); - end loop; - Add (Line => Line_Position (Number_Of_Colors + 3), Column => 0, - Str => "Use up/down to select a color, left/right to change " & - "fields."); - Add (Line => Line_Position (Number_Of_Colors + 4), Column => 0, - Str => "Modify field by typing nnn=, nnn-, or nnn+. ? for help."); - - Move_Cursor (Line => 2 + Line_Position (current), Column => 0); - - last_c := this_c; - this_c := Getchar; - if Is_Digit (this_c) then - value := 0; - end if; - - case this_c is - when KEY_UP => - current := (current - 1) mod Color_Number (max_colors); - when KEY_DOWN => - current := (current + 1) mod Color_Number (max_colors); - when KEY_RIGHT => - field := RGB_Enum'Val ((RGB_Enum'Pos (field) + 1) mod 3); - when KEY_LEFT => - field := RGB_Enum'Val ((RGB_Enum'Pos (field) - 1) mod 3); - when - Character'Pos ('0') | - Character'Pos ('1') | - Character'Pos ('2') | - Character'Pos ('3') | - Character'Pos ('4') | - Character'Pos ('5') | - Character'Pos ('6') | - Character'Pos ('7') | - Character'Pos ('8') | - Character'Pos ('9') => - value := value * 10 + RGB_Value (ctoi (Code_To_Char (this_c))); - - when Character'Pos ('+') => - change_color (current, field, value, True); - - when Character'Pos ('-') => - change_color (current, field, -value, True); - - when Character'Pos ('=') => - change_color (current, field, value, False); - - when Character'Pos ('?') => - Erase; - P (" RGB Value Editing Help"); - P (""); - P ("You are in the RGB value editor. Use the arrow keys to " & - "select one of"); - P ("the fields in one of the RGB triples of the current colors;" & - " the one"); - P ("currently selected will be reverse-video highlighted."); - P (""); - P ("To change a field, enter the digits of the new value; they" & - " are echoed"); - P ("as entered. Finish by typing `='. The change will take" & - " effect instantly."); - P ("To increment or decrement a value, use the same procedure," & - " but finish"); - P ("with a `+' or `-'."); - P (""); - P ("To quit, do `x' or 'q'"); - - Pause; - Erase; - when Character'Pos ('q') | - Character'Pos ('x') => - null; - when others => - Beep; - end case; - Move_Cursor (Line => Lines - 2, Column => 0); - Put (tmp6, Integer (value)); - Add (Str => "Number: " & tmp6); - - Clear_To_End_Of_Line; - exit when this_c = Character'Pos ('x') or - this_c = Character'Pos ('q'); - end loop; - - Erase; - End_Windows; -end ncurses2.color_edit; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.ads deleted file mode 100644 index 3e8e392dfe..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_edit.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.color_edit; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.adb deleted file mode 100644 index ecbf2903b5..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.adb +++ /dev/null @@ -1,164 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Ada.Strings.Fixed; - -procedure ncurses2.color_test is - use Int_IO; - - procedure show_color_name (y, x : Integer; color : Integer); - - color_names : constant array (0 .. 15) of String (1 .. 7) := - ( - "black", - "red", - "green", - "yellow", - "blue", - "magenta", - "cyan", - "white", - "BLACK", - "RED", - "GREEN", - "YELLOW", - "BLUE", - "MAGENTA", - "CYAN", - "WHITE" - ); - - - procedure show_color_name (y, x : Integer; color : Integer) is - tmp5 : String (1 .. 5); - begin - if Number_Of_Colors > 8 then - - Put (tmp5, color); - Add (Line => Line_Position (y), Column => Column_Position (x), - Str => tmp5); - else - Add (Line => Line_Position (y), Column => Column_Position (x), - Str => color_names (color)); - end if; - end show_color_name; - - - top, width : Integer; - hello : String (1 .. 5); - -- tmp3 : String (1 .. 3); - -- tmp2 : String (1 .. 2); - -begin - Refresh; - Add (Str => "There are "); - -- Put(tmp3, Number_Of_Colors*Number_Of_Colors); - Add (Str => Ada.Strings.Fixed.Trim (Integer'Image (Number_Of_Colors * - Number_Of_Colors), - Ada.Strings.Left)); - Add (Str => " color pairs"); - Add (Ch => newl); - - if Number_Of_Colors > 8 then - width := 4; - else - width := 8; - end if; - - if Number_Of_Colors > 8 then - hello := "Test"; - else - hello := "Hello"; - end if; - - for Bright in Boolean loop - if Number_Of_Colors > 8 then - top := 0; - else - top := Boolean'Pos (Bright) * (Number_Of_Colors + 3); - end if; - Clear_To_End_Of_Screen; - Move_Cursor (Line => Line_Position (top) + 1, Column => 0); - -- Put(tmp2, Number_Of_Colors); - Add (Str => Ada.Strings.Fixed.Trim (Integer'Image (Number_Of_Colors), - Ada.Strings.Left)); - Add (Ch => 'x'); - Add (Str => Ada.Strings.Fixed.Trim (Integer'Image (Number_Of_Colors), - Ada.Strings.Left)); - Add (Str => " matrix of foreground/background colors, bright *"); - if Bright then - Add (Str => "on"); - else - Add (Str => "off"); - end if; - Add (Ch => '*'); - - for i in 0 .. Number_Of_Colors - 1 loop - show_color_name (top + 2, (i + 1) * width, i); - end loop; - for i in 0 .. Number_Of_Colors - 1 loop - show_color_name (top + 3 + i, 0, i); - end loop; - for i in 1 .. Number_Of_Color_Pairs - 1 loop - Init_Pair (Color_Pair (i), Color_Number (i mod Number_Of_Colors), - Color_Number (i / Number_Of_Colors)); - -- attron((attr_t) COLOR_PAIR(i)) -- Huh? - Set_Color (Pair => Color_Pair (i)); - if Bright then - Switch_Character_Attribute (Attr => (Bold_Character => True, - others => False)); - end if; - Add (Line => Line_Position (top + 3 + (i / Number_Of_Colors)), - Column => Column_Position ((i mod Number_Of_Colors + 1) * - width), - Str => hello); - Set_Character_Attributes; - end loop; - if Number_Of_Colors > 8 or Bright then - Pause; - end if; - end loop; - - Erase; - End_Windows; -end ncurses2.color_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.ads deleted file mode 100644 index 6e663181a9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-color_test.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.color_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.adb deleted file mode 100644 index 7f4cefc960..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.adb +++ /dev/null @@ -1,496 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; -with Terminal_Interface.Curses.Forms.Field_User_Data; -with Ada.Characters.Handling; -with Ada.Strings; -with Ada.Strings.Bounded; - -procedure ncurses2.demo_forms is - package BS is new Ada.Strings.Bounded.Generic_Bounded_Length (80); - - type myptr is access Integer; - - -- The C version stores a pointer in the userptr and - -- converts it into a long integer. - -- The correct, but inconvenient way to do it is to use a - -- pointer to long and keep the pointer constant. - -- It just adds one memory piece to allocate and deallocate (not done here) - - package StringData is new - Terminal_Interface.Curses.Forms.Field_User_Data (Integer, myptr); - - function edit_secure (me : Field; c_in : Key_Code) return Key_Code; - function form_virtualize (f : Form; w : Window) return Key_Code; - function my_form_driver (f : Form; c : Key_Code) return Boolean; - function make_label (frow : Line_Position; - fcol : Column_Position; - label : String) return Field; - function make_field (frow : Line_Position; - fcol : Column_Position; - rows : Line_Count; - cols : Column_Count; - secure : Boolean) return Field; - procedure display_form (f : Form); - procedure erase_form (f : Form); - - -- prints '*' instead of characters. - -- Not that this keeps a bug from the C version: - -- type in the psasword field then move off and back. - -- the cursor is at position one, but - -- this assumes it as at the end so text gets appended instead - -- of overwtitting. - function edit_secure (me : Field; c_in : Key_Code) return Key_Code is - rows, frow : Line_Position; - nrow : Natural; - cols, fcol : Column_Position; - nbuf : Buffer_Number; - c : Key_Code := c_in; - c2 : Character; - - use StringData; - begin - Info (me, rows, cols, frow, fcol, nrow, nbuf); - -- TODO if result = Form_Ok and nbuf > 0 then - -- C version checked the return value - -- of Info, the Ada binding throws an exception I think. - if nbuf > 0 then - declare - temp : BS.Bounded_String; - temps : String (1 .. 10); - -- TODO Get_Buffer povides no information on the field length? - len : myptr; - begin - Get_Buffer (me, 1, Str => temps); - -- strcpy(temp, field_buffer(me, 1)); - Get_User_Data (me, len); - temp := BS.To_Bounded_String (temps (1 .. len.all)); - if c <= Key_Max then - c2 := Code_To_Char (c); - if Ada.Characters.Handling.Is_Graphic (c2) then - BS.Append (temp, c2); - len.all := len.all + 1; - Set_Buffer (me, 1, BS.To_String (temp)); - c := Character'Pos ('*'); - else - c := 0; - end if; - else - case c is - when REQ_BEG_FIELD | - REQ_CLR_EOF | - REQ_CLR_EOL | - REQ_DEL_LINE | - REQ_DEL_WORD | - REQ_DOWN_CHAR | - REQ_END_FIELD | - REQ_INS_CHAR | - REQ_INS_LINE | - REQ_LEFT_CHAR | - REQ_NEW_LINE | - REQ_NEXT_WORD | - REQ_PREV_WORD | - REQ_RIGHT_CHAR | - REQ_UP_CHAR => - c := 0; -- we don't want to do inline editing - when REQ_CLR_FIELD => - if len.all /= 0 then - temp := BS.To_Bounded_String (""); - Set_Buffer (me, 1, BS.To_String (temp)); - len.all := 0; - end if; - - when REQ_DEL_CHAR | - REQ_DEL_PREV => - if len.all /= 0 then - BS.Delete (temp, BS.Length (temp), BS.Length (temp)); - Set_Buffer (me, 1, BS.To_String (temp)); - len.all := len.all - 1; - end if; - when others => null; - end case; - end if; - end; - end if; - return c; - end edit_secure; - - mode : Key_Code := REQ_INS_MODE; - - function form_virtualize (f : Form; w : Window) return Key_Code is - type lookup_t is record - code : Key_Code; - result : Key_Code; - -- should be Form_Request_Code, but we need MAX_COMMAND + 1 - end record; - - lookup : constant array (Positive range <>) of lookup_t := - ( - ( - Character'Pos ('A') mod 16#20#, REQ_NEXT_CHOICE - ), - ( - Character'Pos ('B') mod 16#20#, REQ_PREV_WORD - ), - ( - Character'Pos ('C') mod 16#20#, REQ_CLR_EOL - ), - ( - Character'Pos ('D') mod 16#20#, REQ_DOWN_FIELD - ), - ( - Character'Pos ('E') mod 16#20#, REQ_END_FIELD - ), - ( - Character'Pos ('F') mod 16#20#, REQ_NEXT_PAGE - ), - ( - Character'Pos ('G') mod 16#20#, REQ_DEL_WORD - ), - ( - Character'Pos ('H') mod 16#20#, REQ_DEL_PREV - ), - ( - Character'Pos ('I') mod 16#20#, REQ_INS_CHAR - ), - ( - Character'Pos ('K') mod 16#20#, REQ_CLR_EOF - ), - ( - Character'Pos ('L') mod 16#20#, REQ_LEFT_FIELD - ), - ( - Character'Pos ('M') mod 16#20#, REQ_NEW_LINE - ), - ( - Character'Pos ('N') mod 16#20#, REQ_NEXT_FIELD - ), - ( - Character'Pos ('O') mod 16#20#, REQ_INS_LINE - ), - ( - Character'Pos ('P') mod 16#20#, REQ_PREV_FIELD - ), - ( - Character'Pos ('R') mod 16#20#, REQ_RIGHT_FIELD - ), - ( - Character'Pos ('S') mod 16#20#, REQ_BEG_FIELD - ), - ( - Character'Pos ('U') mod 16#20#, REQ_UP_FIELD - ), - ( - Character'Pos ('V') mod 16#20#, REQ_DEL_CHAR - ), - ( - Character'Pos ('W') mod 16#20#, REQ_NEXT_WORD - ), - ( - Character'Pos ('X') mod 16#20#, REQ_CLR_FIELD - ), - ( - Character'Pos ('Y') mod 16#20#, REQ_DEL_LINE - ), - ( - Character'Pos ('Z') mod 16#20#, REQ_PREV_CHOICE - ), - ( - Character'Pos ('[') mod 16#20#, -- ESCAPE - Form_Request_Code'Last + 1 - ), - ( - Key_Backspace, REQ_DEL_PREV - ), - ( - KEY_DOWN, REQ_DOWN_CHAR - ), - ( - Key_End, REQ_LAST_FIELD - ), - ( - Key_Home, REQ_FIRST_FIELD - ), - ( - KEY_LEFT, REQ_LEFT_CHAR - ), - ( - KEY_LL, REQ_LAST_FIELD - ), - ( - Key_Next, REQ_NEXT_FIELD - ), - ( - KEY_NPAGE, REQ_NEXT_PAGE - ), - ( - KEY_PPAGE, REQ_PREV_PAGE - ), - ( - Key_Previous, REQ_PREV_FIELD - ), - ( - KEY_RIGHT, REQ_RIGHT_CHAR - ), - ( - KEY_UP, REQ_UP_CHAR - ), - ( - Character'Pos ('Q') mod 16#20#, -- QUIT - Form_Request_Code'Last + 1 -- TODO MAX_FORM_COMMAND + 1 - ) - ); - - c : Key_Code := Getchar (w); - me : Field := Current (f); - - begin - if c = Character'Pos (']') mod 16#20# then - if mode = REQ_INS_MODE then - mode := REQ_OVL_MODE; - else - mode := REQ_INS_MODE; - end if; - c := mode; - else - for n in lookup'Range loop - if lookup (n).code = c then - c := lookup (n).result; - exit; - end if; - end loop; - end if; - - -- Force the field that the user is typing into to be in reverse video, - -- while the other fields are shown underlined. - if c <= Key_Max then - c := edit_secure (me, c); - Set_Background (me, (Reverse_Video => True, others => False)); - elsif c <= Form_Request_Code'Last then - c := edit_secure (me, c); - Set_Background (me, (Under_Line => True, others => False)); - end if; - return c; - end form_virtualize; - - function my_form_driver (f : Form; c : Key_Code) return Boolean is - flag : Driver_Result := Driver (f, F_Validate_Field); - begin - if c = Form_Request_Code'Last + 1 - and flag = Form_Ok then - return True; - else - Beep; - return False; - end if; - end my_form_driver; - - function make_label (frow : Line_Position; - fcol : Column_Position; - label : String) return Field is - f : Field := Create (1, label'Length, frow, fcol, 0, 0); - o : Field_Option_Set := Get_Options (f); - begin - if f /= Null_Field then - Set_Buffer (f, 0, label); - o.Active := False; - Set_Options (f, o); - end if; - return f; - end make_label; - - function make_field (frow : Line_Position; - fcol : Column_Position; - rows : Line_Count; - cols : Column_Count; - secure : Boolean) return Field is - f : Field; - use StringData; - len : myptr; - begin - if secure then - f := Create (rows, cols, frow, fcol, 0, 1); - else - f := Create (rows, cols, frow, fcol, 0, 0); - end if; - - if f /= Null_Field then - Set_Background (f, (Under_Line => True, others => False)); - len := new Integer; - len.all := 0; - Set_User_Data (f, len); - end if; - return f; - end make_field; - - procedure display_form (f : Form) is - w : Window; - rows : Line_Count; - cols : Column_Count; - begin - Scale (f, rows, cols); - - w := New_Window (rows + 2, cols + 4, 0, 0); - if w /= Null_Window then - Set_Window (f, w); - Set_Sub_Window (f, Derived_Window (w, rows, cols, 1, 2)); - Box (w); -- 0,0 - Set_KeyPad_Mode (w, True); - end if; - - -- TODO if Post(f) /= Form_Ok then it's a procedure - declare - begin - Post (f); - exception - when - Eti_System_Error | - Eti_Bad_Argument | - Eti_Posted | - Eti_Connected | - Eti_Bad_State | - Eti_No_Room | - Eti_Not_Posted | - Eti_Unknown_Command | - Eti_No_Match | - Eti_Not_Selectable | - Eti_Not_Connected | - Eti_Request_Denied | - Eti_Invalid_Field | - Eti_Current => - Refresh (w); - end; - -- end if; - end display_form; - - procedure erase_form (f : Form) is - w : Window := Get_Window (f); - s : Window := Get_Sub_Window (f); - begin - Post (f, False); - Erase (w); - Refresh (w); - Delete (s); - Delete (w); - end erase_form; - - finished : Boolean := False; - f : Field_Array_Access := new Field_Array (1 .. 12); - secure : Field; - myform : Form; - w : Window; - c : Key_Code; - result : Driver_Result; -begin - Move_Cursor (Line => 18, Column => 0); - Add (Str => "Defined form-traversal keys: ^Q/ESC- exit form"); - Add (Ch => newl); - Add (Str => "^N -- go to next field ^P -- go to previous field"); - Add (Ch => newl); - Add (Str => "Home -- go to first field End -- go to last field"); - Add (Ch => newl); - Add (Str => "^L -- go to field to left ^R -- go to field to right"); - Add (Ch => newl); - Add (Str => "^U -- move upward to field ^D -- move downward to field"); - Add (Ch => newl); - Add (Str => "^W -- go to next word ^B -- go to previous word"); - Add (Ch => newl); - Add (Str => "^S -- go to start of field ^E -- go to end of field"); - Add (Ch => newl); - Add (Str => "^H -- delete previous char ^Y -- delete line"); - Add (Ch => newl); - Add (Str => "^G -- delete current word ^C -- clear to end of line"); - Add (Ch => newl); - Add (Str => "^K -- clear to end of field ^X -- clear field"); - Add (Ch => newl); - Add (Str => "Arrow keys move within a field as you would expect."); - - Add (Line => 4, Column => 57, Str => "Forms Entry Test"); - - Refresh; - - -- describe the form - f (1) := make_label (0, 15, "Sample Form"); - f (2) := make_label (2, 0, "Last Name"); - f (3) := make_field (3, 0, 1, 18, False); - f (4) := make_label (2, 20, "First Name"); - f (5) := make_field (3, 20, 1, 12, False); - f (6) := make_label (2, 34, "Middle Name"); - f (7) := make_field (3, 34, 1, 12, False); - f (8) := make_label (5, 0, "Comments"); - f (9) := make_field (6, 0, 4, 46, False); - f (10) := make_label (5, 20, "Password:"); - f (11) := make_field (5, 30, 1, 9, True); - secure := f (11); - f (12) := Null_Field; - - myform := New_Form (f); - - display_form (myform); - - w := Get_Window (myform); - Set_Raw_Mode (SwitchOn => True); - Set_NL_Mode (SwitchOn => True); -- lets us read ^M's - while not finished loop - c := form_virtualize (myform, w); - result := Driver (myform, c); - case result is - when Form_Ok => - Add (Line => 5, Column => 57, Str => Get_Buffer (secure, 1)); - Clear_To_End_Of_Line; - Refresh; - when Unknown_Request => - finished := my_form_driver (myform, c); - when others => - Beep; - end case; - end loop; - - erase_form (myform); - - -- TODO Free_Form(myform); - -- for (c = 0; f[c] != 0; c++) free_field(f[c]); - Set_Raw_Mode (SwitchOn => False); - Set_NL_Mode (SwitchOn => True); - -end ncurses2.demo_forms; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.ads deleted file mode 100644 index eabaa01b9e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_forms.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.demo_forms; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.adb deleted file mode 100644 index 1b17cbd54c..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.adb +++ /dev/null @@ -1,671 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Interfaces.C; -with System.Storage_Elements; -with System.Address_To_Access_Conversions; - -with Ada.Text_IO; --- with Ada.Real_Time; use Ada.Real_Time; --- TODO is there a way to use Real_Time or Ada.Calendar in place of --- gettimeofday? - --- Demonstrate pads. -procedure ncurses2.demo_pad is - - type timestruct is record - seconds : Integer; - microseconds : Integer; - end record; - - type myfunc is access function (w : Window) return Key_Code; - - function gettime return timestruct; - procedure do_h_line (y : Line_Position; - x : Column_Position; - c : Attributed_Character; - to : Column_Position); - procedure do_v_line (y : Line_Position; - x : Column_Position; - c : Attributed_Character; - to : Line_Position); - function padgetch (win : Window) return Key_Code; - function panner_legend (line : Line_Position) return Boolean; - procedure panner_legend (line : Line_Position); - procedure panner_h_cleanup (from_y : Line_Position; - from_x : Column_Position; - to_x : Column_Position); - procedure panner_v_cleanup (from_y : Line_Position; - from_x : Column_Position; - to_y : Line_Position); - procedure panner (pad : Window; - top_xp : Column_Position; - top_yp : Line_Position; - portyp : Line_Position; - portxp : Column_Position; - pgetc : myfunc); - - function gettime return timestruct is - - retval : timestruct; - - use Interfaces.C; - type timeval is record - tv_sec : long; - tv_usec : long; - end record; - pragma Convention (C, timeval); - - -- TODO function from_timeval is new Ada.Unchecked_Conversion( - -- timeval_a, System.Storage_Elements.Integer_Address); - -- should Interfaces.C.Pointers be used here? - - package myP is new System.Address_To_Access_Conversions (timeval); - use myP; - - t : Object_Pointer := new timeval; - - function gettimeofday - (TP : System.Storage_Elements.Integer_Address; - TZP : System.Storage_Elements.Integer_Address) return int; - pragma Import (C, gettimeofday, "gettimeofday"); - tmp : int; - begin - tmp := gettimeofday (System.Storage_Elements.To_Integer - (myP.To_Address (t)), - System.Storage_Elements.To_Integer - (myP.To_Address (null))); - retval.seconds := Integer (t.tv_sec); - retval.microseconds := Integer (t.tv_usec); - return retval; - end gettime; - - - -- in C, The behavior of mvhline, mvvline for negative/zero length is - -- unspecified, though we can rely on negative x/y values to stop the - -- macro. Except Ada makes Line_Position(-1) = Natural - 1 so forget it. - procedure do_h_line (y : Line_Position; - x : Column_Position; - c : Attributed_Character; - to : Column_Position) is - begin - if to > x then - Move_Cursor (Line => y, Column => x); - Horizontal_Line (Line_Size => Natural (to - x), Line_Symbol => c); - end if; - end do_h_line; - - procedure do_v_line (y : Line_Position; - x : Column_Position; - c : Attributed_Character; - to : Line_Position) is - begin - if to > y then - Move_Cursor (Line => y, Column => x); - Vertical_Line (Line_Size => Natural (to - y), Line_Symbol => c); - end if; - end do_v_line; - - - - - function padgetch (win : Window) return Key_Code is - c : Key_Code; - c2 : Character; - begin - c := Getchar (win); - c2 := Code_To_Char (c); - - case c2 is - when '!' => - ShellOut (False); - return Key_Refresh; - when Character'Val (Character'Pos ('r') mod 16#20#) => -- CTRL('r') - End_Windows; - Refresh; - return Key_Refresh; - when Character'Val (Character'Pos ('l') mod 16#20#) => -- CTRL('l') - return Key_Refresh; - when 'U' => - return Key_Cursor_Up; - when 'D' => - return Key_Cursor_Down; - when 'R' => - return Key_Cursor_Right; - when 'L' => - return Key_Cursor_Left; - when '+' => - return Key_Insert_Line; - when '-' => - return Key_Delete_Line; - when '>' => - return Key_Insert_Char; - when '<' => - return Key_Delete_Char; - -- when ERR=> /* FALLTHRU */ - when 'q' => - return (Key_Exit); - when others => - return (c); - end case; - end padgetch; - - show_panner_legend : Boolean := True; - - function panner_legend (line : Line_Position) return Boolean is - legend : constant array (0 .. 3) of String (1 .. 61) := - ( - "Use arrow keys (or U,D,L,R) to pan, q to quit (?,t,s flags) ", - "Use ! to shell-out. Toggle legend:?, timer:t, scroll mark:s.", - "Use +,- (or j,k) to grow/shrink the panner vertically. ", - "Use <,> (or h,l) to grow/shrink the panner horizontally. "); - legendsize : constant := 4; - - n : Integer := legendsize - Integer (Lines - line); - begin - if line < Lines and n >= 0 then - Move_Cursor (Line => line, Column => 0); - if show_panner_legend then - Add (Str => legend (n)); - end if; - Clear_To_End_Of_Line; - return show_panner_legend; - end if; - return False; - end panner_legend; - - procedure panner_legend (line : Line_Position) is - tmp : Boolean; - begin - tmp := panner_legend (line); - end panner_legend; - - procedure panner_h_cleanup (from_y : Line_Position; - from_x : Column_Position; - to_x : Column_Position) is - begin - if not panner_legend (from_y) then - do_h_line (from_y, from_x, Blank2, to_x); - end if; - end panner_h_cleanup; - - procedure panner_v_cleanup (from_y : Line_Position; - from_x : Column_Position; - to_y : Line_Position) is - begin - if not panner_legend (from_y) then - do_v_line (from_y, from_x, Blank2, to_y); - end if; - end panner_v_cleanup; - - - procedure panner (pad : Window; - top_xp : Column_Position; - top_yp : Line_Position; - portyp : Line_Position; - portxp : Column_Position; - pgetc : myfunc) is - - function f (y : Line_Position) return Line_Position; - function f (x : Column_Position) return Column_Position; - function greater (y1, y2 : Line_Position) return Integer; - function greater (x1, x2 : Column_Position) return Integer; - - top_x : Column_Position := top_xp; - top_y : Line_Position := top_yp; - porty : Line_Position := portyp; - portx : Column_Position := portxp; - - -- f[x] returns max[x - 1, 0] - function f (y : Line_Position) return Line_Position is - begin - if y > 0 then - return y - 1; - else - return y; -- 0 - end if; - end f; - - function f (x : Column_Position) return Column_Position is - begin - if x > 0 then - return x - 1; - else - return x; -- 0 - end if; - end f; - - function greater (y1, y2 : Line_Position) return Integer is - begin - if y1 > y2 then - return 1; - else - return 0; - end if; - end greater; - - function greater (x1, x2 : Column_Position) return Integer is - begin - if x1 > x2 then - return 1; - else - return 0; - end if; - end greater; - - - pymax : Line_Position; - basey : Line_Position := 0; - pxmax : Column_Position; - basex : Column_Position := 0; - c : Key_Code; - scrollers : Boolean := True; - before, after : timestruct; - timing : Boolean := True; - - package floatio is new Ada.Text_IO.Float_IO (Long_Float); - begin - Get_Size (pad, pymax, pxmax); - Allow_Scrolling (Mode => False); -- we don't want stdscr to scroll! - - c := Key_Refresh; - loop - -- During shell-out, the user may have resized the window. Adjust - -- the port size of the pad to accommodate this. Ncurses - -- automatically resizes all of the normal windows to fit on the - -- new screen. - if top_x > Columns then - top_x := Columns; - end if; - if portx > Columns then - portx := Columns; - end if; - if top_y > Lines then - top_y := Lines; - end if; - if porty > Lines then - porty := Lines; - end if; - - case c is - when Key_Refresh | Character'Pos ('?') => - if c = Key_Refresh then - Erase; - else -- '?' - show_panner_legend := not show_panner_legend; - end if; - panner_legend (Lines - 4); - panner_legend (Lines - 3); - panner_legend (Lines - 2); - panner_legend (Lines - 1); - when Character'Pos ('t') => - timing := not timing; - if not timing then - panner_legend (Lines - 1); - end if; - when Character'Pos ('s') => - scrollers := not scrollers; - - -- Move the top-left corner of the pad, keeping the - -- bottom-right corner fixed. - when Character'Pos ('h') => - -- increase-columns: move left edge to left - if top_x <= 0 then - Beep; - else - panner_v_cleanup (top_y, top_x, porty); - top_x := top_x - 1; - end if; - - when Character'Pos ('j') => - -- decrease-lines: move top-edge down - if top_y >= porty then - Beep; - else - if top_y /= 0 then - panner_h_cleanup (top_y - 1, f (top_x), portx); - end if; - top_y := top_y + 1; - end if; - when Character'Pos ('k') => - -- increase-lines: move top-edge up - if top_y <= 0 then - Beep; - else - top_y := top_y - 1; - panner_h_cleanup (top_y, top_x, portx); - end if; - - when Character'Pos ('l') => - -- decrease-columns: move left-edge to right - if top_x >= portx then - Beep; - else - if top_x /= 0 then - panner_v_cleanup (f (top_y), top_x - 1, porty); - end if; - top_x := top_x + 1; - end if; - - -- Move the bottom-right corner of the pad, keeping the - -- top-left corner fixed. - when Key_Insert_Char => - -- increase-columns: move right-edge to right - if portx >= pxmax or portx >= Columns then - Beep; - else - panner_v_cleanup (f (top_y), portx - 1, porty); - portx := portx + 1; - -- C had ++portx instead of portx++, weird. - end if; - when Key_Insert_Line => - -- increase-lines: move bottom-edge down - if porty >= pymax or porty >= Lines then - Beep; - else - panner_h_cleanup (porty - 1, f (top_x), portx); - porty := porty + 1; - end if; - - when Key_Delete_Char => - -- decrease-columns: move bottom edge up - if portx <= top_x then - Beep; - else - portx := portx - 1; - panner_v_cleanup (f (top_y), portx, porty); - end if; - - when Key_Delete_Line => - -- decrease-lines - if porty <= top_y then - Beep; - else - porty := porty - 1; - panner_h_cleanup (porty, f (top_x), portx); - end if; - when Key_Cursor_Left => - -- pan leftwards - if basex > 0 then - basex := basex - 1; - else - Beep; - end if; - when Key_Cursor_Right => - -- pan rightwards - -- if (basex + portx - (pymax > porty) < pxmax) - if (basex + portx - - Column_Position (greater (pymax, porty)) < pxmax) then - -- if basex + portx < pxmax or - -- (pymax > porty and basex + portx - 1 < pxmax) then - basex := basex + 1; - else - Beep; - end if; - - when Key_Cursor_Up => - -- pan upwards - if basey > 0 then - basey := basey - 1; - else - Beep; - end if; - - when Key_Cursor_Down => - -- pan downwards - -- same as if (basey + porty - (pxmax > portx) < pymax) - if (basey + porty - - Line_Position (greater (pxmax, portx)) < pymax) then - -- if (basey + porty < pymax) or - -- (pxmax > portx and basey + porty - 1 < pymax) then - basey := basey + 1; - else - Beep; - end if; - - when Character'Pos ('H') | - Key_Home | - Key_Find => - basey := 0; - - when Character'Pos ('E') | - Key_End | - Key_Select => - basey := pymax - porty; - if basey < 0 then -- basey := max(basey, 0); - basey := 0; - end if; - - when others => - Beep; - end case; - - -- more writing off the screen. - -- Interestingly, the exception is not handled if - -- we put a block around this. - -- delcare --begin - if top_y /= 0 and top_x /= 0 then - Add (Line => top_y - 1, Column => top_x - 1, - Ch => ACS_Map (ACS_Upper_Left_Corner)); - end if; - if top_x /= 0 then - do_v_line (top_y, top_x - 1, ACS_Map (ACS_Vertical_Line), porty); - end if; - if top_y /= 0 then - do_h_line (top_y - 1, top_x, ACS_Map (ACS_Horizontal_Line), portx); - end if; - -- exception when Curses_Exception => null; end; - - -- in C was ... pxmax > portx - 1 - if scrollers and pxmax >= portx then - declare - length : Column_Position := portx - top_x - 1; - lowend, highend : Column_Position; - begin - -- Instead of using floats, I'll use integers only. - lowend := top_x + (basex * length) / pxmax; - highend := top_x + ((basex + length) * length) / pxmax; - - do_h_line (porty - 1, top_x, ACS_Map (ACS_Horizontal_Line), - lowend); - if highend < portx then - Switch_Character_Attribute - (Attr => (Reverse_Video => True, others => False), - On => True); - do_h_line (porty - 1, lowend, Blank2, highend + 1); - Switch_Character_Attribute - (Attr => (Reverse_Video => True, others => False), - On => False); - do_h_line (porty - 1, highend + 1, - ACS_Map (ACS_Horizontal_Line), portx); - end if; - end; - else - do_h_line (porty - 1, top_x, ACS_Map (ACS_Horizontal_Line), portx); - end if; - - if scrollers and pymax >= porty then - declare - length : Line_Position := porty - top_y - 1; - lowend, highend : Line_Position; - begin - lowend := top_y + (basey * length) / pymax; - highend := top_y + ((basey + length) * length) / pymax; - - do_v_line (top_y, portx - 1, ACS_Map (ACS_Vertical_Line), - lowend); - if highend < porty then - Switch_Character_Attribute - (Attr => (Reverse_Video => True, others => False), - On => True); - do_v_line (lowend, portx - 1, Blank2, highend + 1); - Switch_Character_Attribute - (Attr => (Reverse_Video => True, others => False), - On => False); - do_v_line (highend + 1, portx - 1, - ACS_Map (ACS_Vertical_Line), porty); - end if; - end; - else - do_v_line (top_y, portx - 1, ACS_Map (ACS_Vertical_Line), porty); - end if; - - if top_y /= 0 then - Add (Line => top_y - 1, Column => portx - 1, - Ch => ACS_Map (ACS_Upper_Right_Corner)); - end if; - if top_x /= 0 then - Add (Line => porty - 1, Column => top_x - 1, - Ch => ACS_Map (ACS_Lower_Left_Corner)); - end if; - declare - begin - -- Here is another place where it is possible - -- to write to the corner of the screen. - Add (Line => porty - 1, Column => portx - 1, - Ch => ACS_Map (ACS_Lower_Right_Corner)); - exception - when Curses_Exception => null; - end; - - before := gettime; - - Refresh_Without_Update; - - declare - -- the C version allows the panel to have a zero height - -- wich raise the exception - begin - Refresh_Without_Update - ( - pad, - basey, basex, - top_y, top_x, - porty - Line_Position (greater (pxmax, portx)) - 1, - portx - Column_Position (greater (pymax, porty)) - 1); - exception - when Curses_Exception => null; - end; - - Update_Screen; - - if timing then declare - s : String (1 .. 7); - elapsed : Long_Float; - begin - after := gettime; - elapsed := (Long_Float (after.seconds - before.seconds) + - Long_Float (after.microseconds - before.microseconds) - / 1.0e6); - Move_Cursor (Line => Lines - 1, Column => Columns - 20); - floatio.Put (s, elapsed, Aft => 3, Exp => 0); - Add (Str => s); - Refresh; - end; - end if; - - c := pgetc (pad); - exit when c = Key_Exit; - - end loop; - - Allow_Scrolling (Mode => True); - - end panner; - - Gridsize : constant := 3; - Gridcount : Integer := 0; - - Pad_High : constant Line_Count := 200; - Pad_Wide : constant Column_Count := 200; - panpad : Window := New_Pad (Pad_High, Pad_Wide); -begin - if panpad = Null_Window then - Cannot ("cannot create requested pad"); - return; - end if; - - for i in 0 .. Pad_High - 1 loop - for j in 0 .. Pad_Wide - 1 loop - if i mod Gridsize = 0 and j mod Gridsize = 0 then - if i = 0 or j = 0 then - Add (panpad, '+'); - else - -- depends on ASCII? - Add (panpad, - Ch => Character'Val (Character'Pos ('A') + - Gridcount mod 26)); - Gridcount := Gridcount + 1; - end if; - elsif i mod Gridsize = 0 then - Add (panpad, '-'); - elsif j mod Gridsize = 0 then - Add (panpad, '|'); - else - declare - -- handle the write to the lower right corner error - begin - Add (panpad, ' '); - exception - when Curses_Exception => null; - end; - end if; - end loop; - end loop; - panner_legend (Lines - 4); - panner_legend (Lines - 3); - panner_legend (Lines - 2); - panner_legend (Lines - 1); - - Set_KeyPad_Mode (panpad, True); - -- Make the pad (initially) narrow enough that a trace file won't wrap. - -- We'll still be able to widen it during a test, since that's required - -- for testing boundaries. - - panner (panpad, 2, 2, Lines - 5, Columns - 15, padgetch'Access); - - Delete (panpad); - End_Windows; -- Hmm, Erase after End_Windows - Erase; -end ncurses2.demo_pad; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.ads deleted file mode 100644 index b996263c1c..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_pad.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.demo_pad; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.adb deleted file mode 100644 index 9988a9f135..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.adb +++ /dev/null @@ -1,379 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Panels.User_Data; - -with ncurses2.genericPuts; - -procedure ncurses2.demo_panels (nap_mseci : Integer) is - use Int_IO; - - function mkpanel (color : Color_Number; - rows : Line_Count; - cols : Column_Count; - tly : Line_Position; - tlx : Column_Position) return Panel; - procedure rmpanel (pan : in out Panel); - procedure pflush; - procedure wait_a_while (msec : Integer); - procedure saywhat (text : String); - procedure fill_panel (pan : Panel); - - nap_msec : Integer := nap_mseci; - - function mkpanel (color : Color_Number; - rows : Line_Count; - cols : Column_Count; - tly : Line_Position; - tlx : Column_Position) return Panel is - win : Window; - pan : Panel := Null_Panel; - begin - win := New_Window (rows, cols, tly, tlx); - if Null_Window /= win then - pan := New_Panel (win); - if pan = Null_Panel then - Delete (win); - elsif Has_Colors then - declare - fg, bg : Color_Number; - begin - if color = Blue then - fg := White; - else - fg := Black; - end if; - bg := color; - Init_Pair (Color_Pair (color), fg, bg); - Set_Background (win, (Ch => ' ', - Attr => Normal_Video, - Color => Color_Pair (color))); - end; - else - Set_Background (win, (Ch => ' ', - Attr => (Bold_Character => True, - others => False), - Color => Color_Pair (color))); - end if; - end if; - return pan; - end mkpanel; - - procedure rmpanel (pan : in out Panel) is - win : Window := Panel_Window (pan); - begin - Delete (pan); - Delete (win); - end rmpanel; - - procedure pflush is - begin - Update_Panels; - Update_Screen; - end pflush; - - procedure wait_a_while (msec : Integer) is - begin - -- The C version had some #ifdef blocks here - if nap_msec = 1 then - Getchar; - else - Nap_Milli_Seconds (nap_msec); - end if; - end wait_a_while; - - procedure saywhat (text : String) is - begin - Move_Cursor (Line => Lines - 1, Column => 0); - Clear_To_End_Of_Line; - Add (Str => text); - end saywhat; - - -- from sample-curses_demo.adb - type User_Data is new String (1 .. 2); - type User_Data_Access is access all User_Data; - package PUD is new Panels.User_Data (User_Data, User_Data_Access); - - use PUD; - - procedure fill_panel (pan : Panel) is - win : Window := Panel_Window (pan); - num : Character := Get_User_Data (pan) (2); - tmp6 : String (1 .. 6) := "-panx-"; - maxy : Line_Count; - maxx : Column_Count; - - begin - Move_Cursor (win, 1, 1); - tmp6 (5) := num; - Add (win, Str => tmp6); - Clear_To_End_Of_Line (win); - Box (win); - Get_Size (win, maxy, maxx); - for y in 2 .. maxy - 2 loop - for x in 1 .. maxx - 2 loop - Move_Cursor (win, y, x); - Add (win, num); - end loop; - end loop; - end fill_panel; - - modstr : array (0 .. 5) of String (1 .. 5) := - ("test ", - "TEST ", - "(**) ", - "*()* ", - "<--> ", - "LAST " - ); - - package p is new ncurses2.genericPuts (1024); - use p; - use p.BS; - -- the C version said register int y, x; - tmpb : BS.Bounded_String; - -begin - Refresh; - - for y in 0 .. Integer (Lines - 2) loop - for x in 0 .. Integer (Columns - 1) loop - myPut (tmpb, (y + x) mod 10); - myAdd (Str => tmpb); - end loop; - end loop; - for y in 0 .. 4 loop - declare - p1, p2, p3, p4, p5 : Panel; - U1 : User_Data_Access := new User_Data'("p1"); - U2 : User_Data_Access := new User_Data'("p2"); - U3 : User_Data_Access := new User_Data'("p3"); - U4 : User_Data_Access := new User_Data'("p4"); - U5 : User_Data_Access := new User_Data'("p5"); - - begin - p1 := mkpanel (Red, Lines / 2 - 2, Columns / 8 + 1, 0, 0); - Set_User_Data (p1, U1); - p2 := mkpanel (Green, Lines / 2 + 1, Columns / 7, Lines / 4, - Columns / 10); - Set_User_Data (p2, U2); - p3 := mkpanel (Yellow, Lines / 4, Columns / 10, Lines / 2, - Columns / 9); - Set_User_Data (p3, U3); - p4 := mkpanel (Blue, Lines / 2 - 2, Columns / 8, Lines / 2 - 2, - Columns / 3); - Set_User_Data (p4, U4); - p5 := mkpanel (Magenta, Lines / 2 - 2, Columns / 8, Lines / 2, - Columns / 2 - 2); - Set_User_Data (p5, U5); - - fill_panel (p1); - fill_panel (p2); - fill_panel (p3); - fill_panel (p4); - fill_panel (p5); - Hide (p4); - Hide (p5); - pflush; - saywhat ("press any key to continue"); - wait_a_while (nap_msec); - - saywhat ("h3 s1 s2 s4 s5; press any key to continue"); - Move (p1, 0, 0); - Hide (p3); - Show (p1); - Show (p2); - Show (p4); - Show (p5); - pflush; - wait_a_while (nap_msec); - - saywhat ("s1; press any key to continue"); - Show (p1); - pflush; - wait_a_while (nap_msec); - - saywhat ("s2; press any key to continue"); - Show (p2); - pflush; - wait_a_while (nap_msec); - - saywhat ("m2; press any key to continue"); - Move (p2, Lines / 3 + 1, Columns / 8); - pflush; - wait_a_while (nap_msec); - - saywhat ("s3;"); - Show (p3); - pflush; - wait_a_while (nap_msec); - - saywhat ("m3; press any key to continue"); - Move (p3, Lines / 4 + 1, Columns / 15); - pflush; - wait_a_while (nap_msec); - - saywhat ("b3; press any key to continue"); - Bottom (p3); - pflush; - wait_a_while (nap_msec); - - saywhat ("s4; press any key to continue"); - Show (p4); - pflush; - wait_a_while (nap_msec); - - saywhat ("s5; press any key to continue"); - Show (p5); - pflush; - wait_a_while (nap_msec); - - saywhat ("t3; press any key to continue"); - Top (p3); - pflush; - wait_a_while (nap_msec); - - saywhat ("t1; press any key to continue"); - Top (p1); - pflush; - wait_a_while (nap_msec); - - saywhat ("t2; press any key to continue"); - Top (p2); - pflush; - wait_a_while (nap_msec); - - saywhat ("t3; press any key to continue"); - Top (p3); - pflush; - wait_a_while (nap_msec); - - saywhat ("t4; press any key to continue"); - Top (p4); - pflush; - wait_a_while (nap_msec); - - for itmp in 0 .. 5 loop - declare - w4 : Window := Panel_Window (p4); - w5 : Window := Panel_Window (p5); - begin - - saywhat ("m4; press any key to continue"); - Move_Cursor (w4, Lines / 8, 1); - Add (w4, modstr (itmp)); - Move (p4, Lines / 6, Column_Position (itmp) * (Columns / 8)); - Move_Cursor (w5, Lines / 6, 1); - Add (w5, modstr (itmp)); - pflush; - wait_a_while (nap_msec); - - saywhat ("m5; press any key to continue"); - Move_Cursor (w4, Lines / 6, 1); - Add (w4, modstr (itmp)); - Move (p5, Lines / 3 - 1, (Column_Position (itmp) * 10) + 6); - Move_Cursor (w5, Lines / 8, 1); - Add (w5, modstr (itmp)); - pflush; - wait_a_while (nap_msec); - end; - end loop; - - saywhat ("m4; press any key to continue"); - Move (p4, Lines / 6, 6 * (Columns / 8)); - -- Move(p4, Lines / 6, itmp * (Columns / 8)); - pflush; - wait_a_while (nap_msec); - - saywhat ("t5; press any key to continue"); - Top (p5); - pflush; - wait_a_while (nap_msec); - - saywhat ("t2; press any key to continue"); - Top (p2); - pflush; - wait_a_while (nap_msec); - - saywhat ("t1; press any key to continue"); - Top (p1); - pflush; - wait_a_while (nap_msec); - - saywhat ("d2; press any key to continue"); - rmpanel (p2); - pflush; - wait_a_while (nap_msec); - - saywhat ("h3; press any key to continue"); - Hide (p3); - pflush; - wait_a_while (nap_msec); - - saywhat ("d1; press any key to continue"); - rmpanel (p1); - pflush; - wait_a_while (nap_msec); - - saywhat ("d4; press any key to continue"); - rmpanel (p4); - pflush; - wait_a_while (nap_msec); - - saywhat ("d5; press any key to continue"); - rmpanel (p5); - pflush; - wait_a_while (nap_msec); - if (nap_msec = 1) then - exit; - else - nap_msec := 100; - end if; - - end; - end loop; - - Erase; - End_Windows; - -end ncurses2.demo_panels; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.ads deleted file mode 100644 index eb2878c850..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-demo_panels.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.demo_panels (nap_mseci : Integer); diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.adb deleted file mode 100644 index 9ea98e158c..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.adb +++ /dev/null @@ -1,135 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with ncurses2.util; use ncurses2.util; - -procedure ncurses2.flushinp_test (win : Window) is - - procedure Continue (win : Window); - - procedure Continue (win : Window) is - begin - Set_Echo_Mode (False); - Move_Cursor (win, 10, 1); - Add (win, 10, 1, " Press any key to continue"); - Refresh (win); - Getchar (win); - end Continue; - - h, by, sh : Line_Position; - w, bx, sw : Column_Position; - - subWin : Window; - -begin - Clear (win); - Get_Size (win, h, w); - Get_Window_Position (win, by, bx); - sw := w / 3; - sh := h / 3; - subWin := Sub_Window (win, sh, sw, by + h - sh - 2, bx + w - sw - 2); - - if Has_Colors then - Init_Pair (2, Cyan, Blue); - Change_Background (subWin, - Attributed_Character'(Ch => ' ', Color => 2, - Attr => Normal_Video)); - end if; - - Set_Character_Attributes (subWin, - (Bold_Character => True, others => False)); - Box (subWin); - Add (subWin, 2, 1, "This is a subwindow"); - Refresh (win); - - Set_Cbreak_Mode (True); - Add (win, 0, 1, "This is a test of the flushinp() call."); - - Add (win, 2, 1, "Type random keys for 5 seconds."); - Add (win, 3, 1, - "These should be discarded (not echoed) after the subwindow " & - "goes away."); - Refresh (win); - - for i in 0 .. 4 loop - Move_Cursor (subWin, 1, 1); - Add (subWin, Str => "Time = "); - Add (subWin, Str => Integer'Image (i)); - Refresh (subWin); - Nap_Milli_Seconds (1000); - Flush_Input; - end loop; - - Delete (subWin); - Erase (win); - Flash_Screen; - Refresh (win); - Nap_Milli_Seconds (1000); - - Add (win, 2, 1, - Str => "If you were still typing when the window timer expired,"); - Add (win, 3, 1, - "or else you typed nothing at all while it was running,"); - Add (win, 4, 1, - "test was invalid. You'll see garbage or nothing at all. "); - Add (win, 6, 1, "Press a key"); - Move_Cursor (win, 9, 10); - Refresh (win); - Set_Echo_Mode (True); - Getchar (win); - Flush_Input; - Add (win, 12, 0, - "If you see any key other than what you typed, flushinp() is broken."); - Continue (win); - - Move_Cursor (win, 9, 10); - Delete_Character (win); - Refresh (win); - Move_Cursor (win, 12, 0); - Clear_To_End_Of_Line; - Add (win, - "What you typed should now have been deleted; if not, wdelch() " & - "failed."); - Continue (win); - - Set_Cbreak_Mode (True); - -end ncurses2.flushinp_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.ads deleted file mode 100644 index 5376c94a54..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-flushinp_test.ads +++ /dev/null @@ -1,43 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; - -procedure ncurses2.flushinp_test (win : Terminal_Interface.Curses.Window); diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.adb deleted file mode 100644 index f17b209878..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.adb +++ /dev/null @@ -1,126 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; use Ada.Text_IO; -with Ada.Strings.Bounded; use Ada.Strings.Bounded; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; - - -package body ncurses2.genericPuts is - - procedure myGet (Win : in Window := Standard_Window; - Str : out BS.Bounded_String; - Len : in Integer := -1) - is - use BS; - function Wgetnstr (Win : Window; - Str : char_array; - Len : int) return int; - pragma Import (C, Wgetnstr, "wgetnstr"); - - N : Integer := Len; - Txt : char_array (0 .. size_t (Max_Length)); - xStr : String (1 .. Max_Length); - Cnt : Natural; - begin - if N < 0 then - N := Max_Length; - end if; - if N > Max_Length then - raise Constraint_Error; - end if; - Txt (0) := Interfaces.C.char'First; - if Wgetnstr (Win, Txt, C_Int (N)) = Curses_Err then - raise Curses_Exception; - end if; - To_Ada (Txt, xStr, Cnt, True); - Str := To_Bounded_String (xStr (1 .. Cnt)); - end myGet; - - - - procedure myPut (Str : out BS.Bounded_String; - i : Integer; - Base : in Number_Base := 10) is - package Int_IO is new Integer_IO (Integer); use Int_IO; - tmp : String (1 .. BS.Max_Length); - begin - Put (tmp, i, Base); - Str := To_Bounded_String (tmp); - Trim (Str, Ada.Strings.Trim_End'(Ada.Strings.Left)); - end myPut; - - procedure myAdd (Str : BS.Bounded_String) is - begin - Add (Str => To_String (Str)); - end myAdd; - - -- from ncurses-aux - procedure Fill_String (Cp : in chars_ptr; - Str : out BS.Bounded_String) - is - -- Fill the string with the characters referenced by the - -- chars_ptr. - -- - Len : Natural; - begin - if Cp /= Null_Ptr then - Len := Natural (Strlen (Cp)); - if Max_Length < Len then - raise Constraint_Error; - end if; - declare - S : String (1 .. Len); - begin - S := Value (Cp); - Str := To_Bounded_String (S); - end; - else - Str := Null_Bounded_String; - end if; - - end Fill_String; - -end ncurses2.genericPuts; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.ads deleted file mode 100644 index eec7eba683..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-genericputs.ads +++ /dev/null @@ -1,73 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -with Ada.Text_IO; use Ada.Text_IO; -with Ada.Strings.Bounded; -use Ada.Strings.Bounded; -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Terminal_Interface.Curses; - - -generic - Max : Natural; - -- type mystring is private; - -- type myint is -package ncurses2.genericPuts is - package BS is new - Ada.Strings.Bounded.Generic_Bounded_Length (Max); - use BS; - - - procedure myGet (Win : in Terminal_Interface.Curses.Window - := Terminal_Interface.Curses.Standard_Window; - Str : out BS.Bounded_String; - Len : in Integer := -1); - - procedure myPut (Str : out BS.Bounded_String; - i : Integer; - Base : in Number_Base := 10); - -- the default should be Ada.Text_IO.Integer_IO.Default_Base - -- but Default_Base is hidden in the generic so doesn't exist! - procedure myAdd (Str : BS.Bounded_String); - - procedure Fill_String (Cp : in chars_ptr; Str : out BS.Bounded_String); -end ncurses2.genericPuts; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch.ads deleted file mode 100644 index 21a09f3160..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure getch_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.adb deleted file mode 100644 index d786d49644..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.adb +++ /dev/null @@ -1,251 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- Character input test --- test the keypad feature - -with ncurses2.util; use ncurses2.util; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; -with Ada.Characters.Handling; -with Ada.Strings.Bounded; - -with ncurses2.genericPuts; - -procedure ncurses2.getch_test is - use Int_IO; - - function mouse_decode (ep : Mouse_Event) return String; - - function mouse_decode (ep : Mouse_Event) return String is - Y : Line_Position; - X : Column_Position; - Button : Mouse_Button; - State : Button_State; - package BS is new Ada.Strings.Bounded.Generic_Bounded_Length (200); - use BS; - buf : Bounded_String := To_Bounded_String (""); - begin - -- Note that these bindings do not allow - -- two button states, - -- The C version can print {click-1, click-3} for example. - -- They also don't have the 'id' or z coordinate. - Get_Event (ep, Y, X, Button, State); - - -- TODO Append (buf, "id "); from C version - Append (buf, "at ("); - Append (buf, Column_Position'Image (X)); - Append (buf, ", "); - Append (buf, Line_Position'Image (Y)); - Append (buf, ") state"); - Append (buf, Mouse_Button'Image (Button)); - - Append (buf, " = "); - Append (buf, Button_State'Image (State)); - return To_String (buf); - end mouse_decode; - - - buf : String (1 .. 1024); -- TODO was BUFSIZE - n : Integer; - c : Key_Code; - blockflag : Timeout_Mode := Blocking; - firsttime : Boolean := True; - tmp2 : Event_Mask; - tmp6 : String (1 .. 6); - tmp20 : String (1 .. 20); - x : Column_Position; - y : Line_Position; - tmpx : Integer; - incount : Integer := 0; -begin - Refresh; - tmp2 := Start_Mouse (All_Events); - Add (Str => "Delay in 10ths of a second ( for blocking input)? "); - Set_Echo_Mode (SwitchOn => True); - Get (Str => buf); - - Set_Echo_Mode (SwitchOn => False); - Set_NL_Mode (SwitchOn => False); - - if Ada.Characters.Handling.Is_Digit (buf (1)) then - Get (Item => n, From => buf, Last => tmpx); - Set_Timeout_Mode (Mode => Delayed, Amount => n * 100); - blockflag := Delayed; - end if; - - c := Character'Pos ('?'); - Set_Raw_Mode (SwitchOn => True); - loop - if not firsttime then - Add (Str => "Key pressed: "); - Put (tmp6, Integer (c), 8); - Add (Str => tmp6); - Add (Ch => ' '); - if c = Key_Mouse then declare - event : Mouse_Event; - begin - event := Get_Mouse; - Add (Str => "KEY_MOUSE, "); - Add (Str => mouse_decode (event)); - Add (Ch => newl); - end; - elsif c >= Key_Min then - Key_Name (c, tmp20); - Add (Str => tmp20); - -- I used tmp and got bitten by the length problem:-> - Add (Ch => newl); - elsif c > 16#80# then -- TODO fix, use constant if possible - declare - c2 : Character := Character'Val (c mod 16#80#); - begin - if Ada.Characters.Handling.Is_Graphic (c2) then - Add (Str => "M-"); - Add (Ch => c2); - else - Add (Str => "M-"); - Add (Str => Un_Control ((Ch => c2, - Color => Color_Pair'First, - Attr => Normal_Video))); - end if; - Add (Str => " (high-half character)"); - Add (Ch => newl); - end; - else declare - c2 : Character := Character'Val (c mod 16#80#); - begin - if Ada.Characters.Handling.Is_Graphic (c2) then - Add (Ch => c2); - Add (Str => " (ASCII printable character)"); - Add (Ch => newl); - else - Add (Str => Un_Control ((Ch => c2, - Color => Color_Pair'First, - Attr => Normal_Video))); - Add (Str => " (ASCII control character)"); - Add (Ch => newl); - end if; - end; - end if; - -- TODO I am not sure why this was in the C version - -- the delay statement scroll anyway. - Get_Cursor_Position (Line => y, Column => x); - if y >= Lines - 1 then - Move_Cursor (Line => 0, Column => 0); - end if; - Clear_To_End_Of_Line; - end if; - - firsttime := False; - if c = Character'Pos ('g') then - declare - package p is new ncurses2.genericPuts (1024); - use p; - use p.BS; - timedout : Boolean := False; - boundedbuf : Bounded_String; - begin - Add (Str => "getstr test: "); - Set_Echo_Mode (SwitchOn => True); - -- Note that if delay mode is set - -- Get can raise an exception. - -- The C version would print the string it had so far - -- also TODO get longer length string, like the C version - declare begin - myGet (Str => boundedbuf); - exception when Curses_Exception => - Add (Str => "Timed out."); - Add (Ch => newl); - timedout := True; - end; - -- note that the Ada Get will stop reading at 1024. - if not timedout then - Set_Echo_Mode (SwitchOn => False); - Add (Str => " I saw '"); - myAdd (Str => boundedbuf); - Add (Str => "'."); - Add (ch => newl); - end if; - end; - elsif c = Character'Pos ('s') then - ShellOut (True); - elsif c = Character'Pos ('x') or c = Character'Pos ('q') or - (c = Key_None and blockflag = Blocking) then - exit; - elsif c = Character'Pos ('?') then - Add (Str => "Type any key to see its keypad value. Also:"); - Add (Ch => newl); - Add (Str => "g -- triggers a getstr test"); - Add (Ch => newl); - Add (Str => "s -- shell out"); - Add (Ch => newl); - Add (Str => "q -- quit"); - Add (Ch => newl); - Add (Str => "? -- repeats this help message"); - Add (Ch => newl); - end if; - - loop - c := Getchar; - exit when c /= Key_None; - if blockflag /= Blocking then - Put (tmp6, incount); -- argh string length! - Add (Str => tmp6); - Add (Str => ": input timed out"); - Add (Ch => newl); - else - Put (tmp6, incount); - Add (Str => tmp6); - Add (Str => ": input error"); - Add (Ch => newl); - exit; - end if; - incount := incount + 1; - end loop; - end loop; - - tmp2 := Start_Mouse (No_Events); - Set_Timeout_Mode (Mode => Blocking, Amount => 0); -- amount is ignored - Set_Raw_Mode (SwitchOn => False); - Set_NL_Mode (SwitchOn => True); - Erase; - End_Windows; -end ncurses2.getch_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.ads deleted file mode 100644 index 78a0a48c17..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getch_test.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.getch_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.adb deleted file mode 100644 index 176073b0bb..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.adb +++ /dev/null @@ -1,166 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000,2004 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.3 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- A simplified version of the GNU getopt function --- copyright Free Software Foundtion - -with Ada.Strings.Fixed; -with Ada.Strings.Bounded; -with Ada.Text_IO; use Ada.Text_IO; - -package body ncurses2.getopt is - - optopt : Character := '?'; - - nextchar : Natural := 0; - - -- Ncurses doesn't use the non option elements so we are spared - -- the job of computing those. - - -- also the user is not allowed to modify argv or argc - -- Doing so is Erroneous execution. - - -- longoptions are not handled. - - procedure Qgetopt (retval : out Integer; - argc : Integer; - argv : stringfunc; - -- argv will be the Argument function. - optstring : String; - optind : in out Integer; - -- ignored for ncurses, must be initialized to 1 by - -- the caller - Optarg : out stringa - -- a garbage colector would be useful here. - ) is - - package BS is new Ada.Strings.Bounded.Generic_Bounded_Length (200); - use BS; - optargx : Bounded_String; - begin - - if argc < optind then - retval := -1; - return; - end if; - - optargx := To_Bounded_String (""); - - if nextchar = 0 then - - if argv (optind) = "--" then - -- the rest are non-options, we ignore them - retval := -1; - return; - end if; - - if argv (optind)(1) /= '-' or argv (optind)'Length = 1 then - optind := optind + 1; - Optarg := new String'(argv (optind)); - retval := 1; - return; - end if; - - nextchar := 2; -- skip the one hyphen. - end if; - - -- Look at and handle the next short option-character. - declare - c : Character := argv (optind) (nextchar); - temp : Natural := - Ada.Strings.Fixed.Index (optstring, String'(1 => c)); - begin - if temp = 0 or c = ':' then - Put_Line (Standard_Error, - argv (optind) & ": invalid option -- " & c); - optopt := c; - c := '?'; - return; - end if; - - if optstring (temp + 1) = ':' then - if optstring (temp + 2) = ':' then - -- This is an option that accepts an argument optionally. - if nextchar /= argv (optind)'Length then - optargx := To_Bounded_String - (argv (optind) (nextchar .. argv (optind)'Length)); - else - Optarg := null; - end if; - else - -- This is an option that requires an argument. - if nextchar /= argv (optind)'Length then - optargx := To_Bounded_String - (argv (optind) (nextchar .. argv (optind)'Length)); - optind := optind + 1; - elsif optind = argc then - Put_Line (Standard_Error, - argv (optind) & - ": option requires an argument -- " & c); - optopt := c; - if optstring (1) = ':' then - c := ':'; - else - c := '?'; - end if; - else - -- increment it again when taking next ARGV-elt as argument. - optind := optind + 1; - optargx := To_Bounded_String (argv (optind)); - optind := optind + 1; - end if; - end if; - nextchar := 0; - else -- no argument for the option - if nextchar = argv (optind)'Length then - optind := optind + 1; - nextchar := 0; - else - nextchar := nextchar + 1; - end if; - end if; - - retval := Character'Pos (c); - Optarg := new String'(To_String (optargx)); - return; - end; - end Qgetopt; - -end ncurses2.getopt; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.ads deleted file mode 100644 index 0bd6952a7b..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-getopt.ads +++ /dev/null @@ -1,59 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package ncurses2.getopt is - - type stringa is access String; - - type stringfunc is access - function (n : Positive) return String; - - - procedure Qgetopt (retval : out Integer; - argc : Integer; - argv : stringfunc; - optstring : String; - optind : in out Integer; - -- ignored for ncurses, must be initialized to 0 - -- by the caller - Optarg : out stringa - -- a garbage collector would be useful here. - ); -end ncurses2.getopt; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.adb deleted file mode 100644 index 214c735bf9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.adb +++ /dev/null @@ -1,459 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000,2004 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.2 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- TODO use Default_Character where appropriate - --- This is an Ada version of ncurses --- I translated this because it tests the most features. - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Trace; use Terminal_Interface.Curses.Trace; - -with Ada.Text_IO; use Ada.Text_IO; - -with Ada.Characters.Latin_1; --- with Ada.Characters.Handling; - -with Ada.Command_Line; use Ada.Command_Line; - -with Ada.Strings.Unbounded; - - -with ncurses2.util; use ncurses2.util; -with ncurses2.getch_test; -with ncurses2.attr_test; -with ncurses2.color_test; -with ncurses2.demo_panels; -with ncurses2.color_edit; -with ncurses2.slk_test; -with ncurses2.acs_display; -with ncurses2.color_edit; -with ncurses2.acs_and_scroll; -with ncurses2.flushinp_test; -with ncurses2.test_sgr_attributes; -with ncurses2.menu_test; -with ncurses2.demo_pad; -with ncurses2.demo_forms; -with ncurses2.overlap_test; -with ncurses2.trace_set; - -with ncurses2.getopt; use ncurses2.getopt; - -package body ncurses2.m is - use Int_IO; - - function To_trace (n : Integer) return Trace_Attribute_Set; - procedure usage; - procedure Set_Terminal_Modes; - function Do_Single_Test (c : Character) return Boolean; - - function To_trace (n : Integer) return Trace_Attribute_Set is - a : Trace_Attribute_Set := (others => False); - m : Integer; - rest : Integer; - begin - m := n mod 2; - if 1 = m then - a.Times := True; - end if; - rest := n / 2; - - m := rest mod 2; - if 1 = m then - a.Tputs := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Update := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Cursor_Move := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Character_Output := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Calls := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Virtual_Puts := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Input_Events := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.TTY_State := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Internal_Calls := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Character_Calls := True; - end if; - rest := rest / 2; - m := rest mod 2; - if 1 = m then - a.Termcap_TermInfo := True; - end if; - - return a; - end To_trace; - - -- these are type Stdscr_Init_Proc; - - function rip_footer ( - Win : Window; - Columns : Column_Count) return Integer; - pragma Convention (C, rip_footer); - - function rip_footer ( - Win : Window; - Columns : Column_Count) return Integer is - begin - Set_Background (Win, (Ch => ' ', - Attr => (Reverse_Video => True, others => False), - Color => 0)); - Erase (Win); - Move_Cursor (Win, 0, 0); - Add (Win, "footer:" & Columns'Img & " columns"); - Refresh_Without_Update (Win); - return 0; -- Curses_OK; - end rip_footer; - - - function rip_header ( - Win : Window; - Columns : Column_Count) return Integer; - pragma Convention (C, rip_header); - - function rip_header ( - Win : Window; - Columns : Column_Count) return Integer is - begin - Set_Background (Win, (Ch => ' ', - Attr => (Reverse_Video => True, others => False), - Color => 0)); - Erase (Win); - Move_Cursor (Win, 0, 0); - Add (Win, "header:" & Columns'Img & " columns"); - -- 'Img is a GNAT extention - Refresh_Without_Update (Win); - return 0; -- Curses_OK; - end rip_header; - - procedure usage is - -- type Stringa is access String; - use Ada.Strings.Unbounded; - -- tbl : constant array (Positive range <>) of Stringa := ( - tbl : constant array (Positive range <>) of Unbounded_String - := ( - To_Unbounded_String ("Usage: ncurses [options]"), - To_Unbounded_String (""), - To_Unbounded_String ("Options:"), - To_Unbounded_String (" -a f,b set default-colors " & - "(assumed white-on-black)"), - To_Unbounded_String (" -d use default-colors if terminal " & - "supports them"), - To_Unbounded_String (" -e fmt specify format for soft-keys " & - "test (e)"), - To_Unbounded_String (" -f rip-off footer line " & - "(can repeat)"), - To_Unbounded_String (" -h rip-off header line " & - "(can repeat)"), - To_Unbounded_String (" -s msec specify nominal time for " & - "panel-demo (default: 1, to hold)"), - To_Unbounded_String (" -t mask specify default trace-level " & - "(may toggle with ^T)") - ); - begin - for n in tbl'Range loop - Put_Line (Standard_Error, To_String (tbl (n))); - end loop; - -- exit(EXIT_FAILURE); - -- TODO should we use Set_Exit_Status and throw and exception? - end usage; - - procedure Set_Terminal_Modes is begin - Set_Raw_Mode (SwitchOn => False); - Set_Cbreak_Mode (SwitchOn => True); - Set_Echo_Mode (SwitchOn => False); - Allow_Scrolling (Mode => True); - Use_Insert_Delete_Line (Do_Idl => True); - Set_KeyPad_Mode (SwitchOn => True); - end Set_Terminal_Modes; - - - nap_msec : Integer := 1; - - function Do_Single_Test (c : Character) return Boolean is - begin - case c is - when 'a' => - getch_test; - when 'b' => - attr_test; - when 'c' => - if not Has_Colors then - Cannot ("does not support color."); - else - color_test; - end if; - when 'd' => - if not Has_Colors then - Cannot ("does not support color."); - elsif not Can_Change_Color then - Cannot ("has hardwired color values."); - else - color_edit; - end if; - when 'e' => - slk_test; - when 'f' => - acs_display; - when 'o' => - demo_panels (nap_msec); - when 'g' => - acs_and_scroll; - when 'i' => - flushinp_test (Standard_Window); - when 'k' => - test_sgr_attributes; - when 'm' => - menu_test; - when 'p' => - demo_pad; - when 'r' => - demo_forms; - when 's' => - overlap_test; - when 't' => - trace_set; - when '?' => - null; - when others => return False; - end case; - return True; - end Do_Single_Test; - - - command : Character; - my_e_param : Soft_Label_Key_Format := Four_Four; - assumed_colors : Boolean := False; - default_colors : Boolean := False; - default_fg : Color_Number := White; - default_bg : Color_Number := Black; - -- nap_msec was an unsigned long integer in the C version, - -- yet napms only takes an int! - - c : Integer; - c2 : Character; - optind : Integer := 1; -- must be initialized to one. - optarg : getopt.stringa; - - length : Integer; - tmpi : Integer; - - package myio is new Ada.Text_IO.Integer_IO (Integer); - use myio; - - save_trace : Integer := 0; - save_trace_set : Trace_Attribute_Set; - - function main return Integer is - begin - loop - Qgetopt (c, Argument_Count, Argument'Access, - "a:de:fhs:t:", optind, optarg); - exit when c = -1; - c2 := Character'Val (c); - case c2 is - when 'a' => - -- Ada doesn't have scanf, it doesn't even have a - -- regular expression library. - assumed_colors := True; - myio.Get (optarg.all, Integer (default_fg), length); - myio.Get (optarg.all (length + 2 .. optarg.all'Length), - Integer (default_bg), length); - when 'd' => - default_colors := True; - when 'e' => - myio.Get (optarg.all, tmpi, length); - if Integer (tmpi) > 3 then - usage; - return 1; - end if; - my_e_param := Soft_Label_Key_Format'Val (tmpi); - when 'f' => - Rip_Off_Lines (-1, rip_footer'Access); - when 'h' => - Rip_Off_Lines (1, rip_header'Access); - when 's' => - myio.Get (optarg.all, nap_msec, length); - when 't' => - myio.Get (optarg.all, save_trace, length); - when others => - usage; - return 1; - end case; - end loop; - - -- the C version had a bunch of macros here. - - -- if (!isatty(fileno(stdin))) - -- isatty is not available in the standard Ada so skip it. - save_trace_set := To_trace (save_trace); - Trace_On (save_trace_set); - - - Init_Soft_Label_Keys (my_e_param); - - Init_Screen; - Set_Background (Ch => (Ch => Blank, - Attr => Normal_Video, - Color => Color_Pair'First)); - - if Has_Colors then - Start_Color; - if default_colors then - Use_Default_Colors; - elsif assumed_colors then - Assume_Default_Colors (default_fg, default_bg); - end if; - end if; - - Set_Terminal_Modes; - Save_Curses_Mode (Curses); - - End_Windows; - - -- TODO add macro #if blocks. - Put_Line ("Welcome to " & Curses_Version & ". Press ? for help."); - - loop - Put_Line ("This is the ncurses main menu"); - Put_Line ("a = keyboard and mouse input test"); - Put_Line ("b = character attribute test"); - Put_Line ("c = color test pattern"); - Put_Line ("d = edit RGB color values"); - Put_Line ("e = exercise soft keys"); - Put_Line ("f = display ACS characters"); - Put_Line ("g = display windows and scrolling"); - Put_Line ("i = test of flushinp()"); - Put_Line ("k = display character attributes"); - Put_Line ("m = menu code test"); - Put_Line ("o = exercise panels library"); - Put_Line ("p = exercise pad features"); - Put_Line ("q = quit"); - Put_Line ("r = exercise forms code"); - Put_Line ("s = overlapping-refresh test"); - Put_Line ("t = set trace level"); - Put_Line ("? = repeat this command summary"); - - Put ("> "); - Flush; - - command := Ada.Characters.Latin_1.NUL; - -- get_input: - -- loop - declare - Ch : Character; - begin - Get (Ch); - -- TODO if read(ch) <= 0 - -- TODO ada doesn't have an Is_Space function - command := Ch; - -- TODO if ch = '\n' or '\r' are these in Ada? - end; - -- end loop get_input; - - declare - begin - if Do_Single_Test (command) then - Flush_Input; - Set_Terminal_Modes; - Reset_Curses_Mode (Curses); - Clear; - Refresh; - End_Windows; - if command = '?' then - Put_Line ("This is the ncurses capability tester."); - Put_Line ("You may select a test from the main menu by " & - "typing the"); - Put_Line ("key letter of the choice (the letter to left " & - "of the =)"); - Put_Line ("at the > prompt. The commands `x' or `q' will " & - "exit."); - end if; - -- continue; --why continue in the C version? - end if; - exception - when Curses_Exception => End_Windows; - end; - - exit when command = 'q'; - end loop; - return 0; -- TODO ExitProgram(EXIT_SUCCESS); - end main; - -end ncurses2.m; - - - - - - - diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.ads deleted file mode 100644 index c32d895dc1..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-m.ads +++ /dev/null @@ -1,43 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package ncurses2.m is - function main return Integer; -end ncurses2.m; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.adb deleted file mode 100644 index 0b96315e1c..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.adb +++ /dev/null @@ -1,165 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; - -procedure ncurses2.menu_test is - function menu_virtualize (c : Key_Code) return Menu_Request_Code; - procedure xAdd (l : Line_Position; c : Column_Position; s : String); - - function menu_virtualize (c : Key_Code) return Menu_Request_Code is - begin - case c is - when Character'Pos (newl) | Key_Exit => - return Menu_Request_Code'Last + 1; -- MAX_COMMAND? TODO - when Character'Pos ('u') => - return M_ScrollUp_Line; - when Character'Pos ('d') => - return M_ScrollDown_Line; - when Character'Pos ('b') | Key_Next_Page => - return M_ScrollUp_Page; - when Character'Pos ('f') | Key_Previous_Page => - return M_ScrollDown_Page; - when Character'Pos ('n') | Key_Cursor_Down => - return M_Next_Item; - when Character'Pos ('p') | Key_Cursor_Up => - return M_Previous_Item; - when Character'Pos (' ') => - return M_Toggle_Item; - when Key_Mouse => - return c; - when others => - Beep; - return c; - end case; - end menu_virtualize; - - MENU_Y : constant Line_Count := 8; - MENU_X : constant Column_Count := 8; - - type String_Access is access String; - - animals : constant array (Positive range <>) of String_Access := - (new String'("Lions"), - new String'("Tigers"), - new String'("Bears"), - new String'("(Oh my!)"), - new String'("Newts"), - new String'("Platypi"), - new String'("Lemurs")); - - items_a : Item_Array_Access := new Item_Array (1 .. animals'Last + 1); - - tmp : Event_Mask; - procedure xAdd (l : Line_Position; c : Column_Position; s : String) is - begin - Add (Line => l, Column => c, Str => s); - end xAdd; - - mrows : Line_Count; - mcols : Column_Count; - - menuwin : Window; - - m : Menu; - - c1 : Key_Code; - - c : Driver_Result; - r : Menu_Request_Code; -begin - tmp := Start_Mouse; - xAdd (0, 0, "This is the menu test:"); - xAdd (2, 0, " Use up and down arrow to move the select bar."); - xAdd (3, 0, " 'n' and 'p' act like arrows."); - xAdd (4, 0, " 'b' and 'f' scroll up/down (page), 'u' and 'd' (line)."); - xAdd (5, 0, " Press return to exit."); - Refresh; - - for i in animals'Range loop - items_a (i) := New_Item (animals (i).all); - end loop; - items_a (animals'Last + 1) := Null_Item; - - m := New_Menu (items_a); - - Set_Format (m, Line_Position (animals'Last + 1) / 2, 1); - Scale (m, mrows, mcols); - - menuwin := Create (mrows + 2, mcols + 2, MENU_Y, MENU_X); - Set_Window (m, menuwin); - Set_KeyPad_Mode (menuwin, True); - Box (menuwin); -- 0,0? - - Set_Sub_Window (m, Derived_Window (menuwin, mrows, mcols, 1, 1)); - - Post (m); - - loop - c1 := Getchar (menuwin); - r := menu_virtualize (c1); - c := Driver (m, r); - exit when c = Unknown_Request; -- E_UNKNOWN_COMMAND? - if c = Request_Denied then - Beep; - end if; - -- continue ? - end loop; - - Move_Cursor (Line => Lines - 2, Column => 0); - Add (Str => "You chose: "); - Add (Str => Name (Current (m))); - Add (Ch => newl); - Pause; -- the C version didn't use Pause, it spelled it out - - Post (m, False); -- unpost, not clear :-( - declare begin - Delete (menuwin); - exception when Curses_Exception => null; end; - -- menuwin has children so will raise the exception. - - Delete (m); - - tmp := Start_Mouse (No_Events); -end ncurses2.menu_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.ads deleted file mode 100644 index 17e5b16b3e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-menu_test.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.menu_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.adb deleted file mode 100644 index 5d3fc6d5e4..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.adb +++ /dev/null @@ -1,156 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - --- test effects of overlapping windows - -procedure ncurses2.overlap_test is - - procedure fillwin (win : Window; ch : Character); - procedure crosswin (win : Window; ch : Character); - - procedure fillwin (win : Window; ch : Character) is - y1 : Line_Position; - x1 : Column_Position; - begin - Get_Size (win, y1, x1); - for y in 0 .. y1 - 1 loop - Move_Cursor (win, y, 0); - for x in 0 .. x1 - 1 loop - Add (win, Ch => ch); - end loop; - end loop; - exception - when Curses_Exception => null; - -- write to lower right corner - end fillwin; - - procedure crosswin (win : Window; ch : Character) is - y1 : Line_Position; - x1 : Column_Position; - begin - Get_Size (win, y1, x1); - for y in 0 .. y1 - 1 loop - for x in 0 .. x1 - 1 loop - if (((x > (x1 - 1) / 3) and (x <= (2 * (x1 - 1)) / 3)) - or (((y > (y1 - 1) / 3) and (y <= (2 * (y1 - 1)) / 3)))) then - Move_Cursor (win, y, x); - Add (win, Ch => ch); - end if; - end loop; - end loop; - end crosswin; - - -- In a 24x80 screen like some xterms are, the instructions will - -- be overwritten. - ch : Character; - win1 : Window := New_Window (9, 20, 3, 3); - win2 : Window := New_Window (9, 20, 9, 16); -begin - Set_Raw_Mode (SwitchOn => True); - Refresh; - Move_Cursor (Line => 0, Column => 0); - Add (Str => "This test shows the behavior of wnoutrefresh() with " & - "respect to"); - Add (Ch => newl); - Add (Str => "the shared region of two overlapping windows A and B. "& - "The cross"); - Add (Ch => newl); - Add (Str => "pattern in each window does not overlap the other."); - Add (Ch => newl); - - Move_Cursor (Line => 18, Column => 0); - Add (Str => "a = refresh A, then B, then doupdate. b = refresh B, " & - "then A, then doupdaute"); - Add (Ch => newl); - Add (Str => "c = fill window A with letter A. d = fill window B " & - "with letter B."); - Add (Ch => newl); - Add (Str => "e = cross pattern in window A. f = cross pattern " & - "in window B."); - Add (Ch => newl); - Add (Str => "g = clear window A. h = clear window B."); - Add (Ch => newl); - Add (Str => "i = overwrite A onto B. j = overwrite " & - "B onto A."); - Add (Ch => newl); - Add (Str => "^Q/ESC = terminate test."); - - loop - ch := Code_To_Char (Getchar); - exit when ch = CTRL ('Q') or ch = CTRL ('['); -- QUIT or ESCAPE - case ch is - when 'a' => -- refresh window A first, then B - Refresh_Without_Update (win1); - Refresh_Without_Update (win2); - Update_Screen; - when 'b' => -- refresh window B first, then A - Refresh_Without_Update (win2); - Refresh_Without_Update (win1); - Update_Screen; - when 'c' => -- fill window A so it's visible - fillwin (win1, 'A'); - when 'd' => -- fill window B so it's visible - fillwin (win2, 'B'); - when 'e' => -- cross test pattern in window A - crosswin (win1, 'A'); - when 'f' => -- cross test pattern in window B - crosswin (win2, 'B'); - when 'g' => -- clear window A - Clear (win1); - Move_Cursor (win1, 0, 0); - when 'h' => -- clear window B - Clear (win2); - Move_Cursor (win2, 0, 0); - when 'i' => -- overwrite A onto B - Overwrite (win1, win2); - when 'j' => -- overwrite B onto A - Overwrite (win2, win1); - when others => null; - end case; - end loop; - - Delete (win2); - Delete (win1); - Erase; - End_Windows; -end ncurses2.overlap_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.ads deleted file mode 100644 index ce6e3e6961..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-overlap_test.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.overlap_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.adb deleted file mode 100644 index 77ca2843fa..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.adb +++ /dev/null @@ -1,171 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Ada.Strings.Unbounded; -with Interfaces.C; -with Terminal_Interface.Curses.Aux; - -procedure ncurses2.slk_test is - procedure myGet (Win : in Window := Standard_Window; - Str : out Ada.Strings.Unbounded.Unbounded_String; - Len : in Integer := -1); - - procedure myGet (Win : in Window := Standard_Window; - Str : out Ada.Strings.Unbounded.Unbounded_String; - Len : in Integer := -1) - is - use Ada.Strings.Unbounded; - use Interfaces.C; - use Terminal_Interface.Curses.Aux; - - function Wgetnstr (Win : Window; - Str : char_array; - Len : int) return int; - pragma Import (C, Wgetnstr, "wgetnstr"); - - Txt : char_array (0 .. 10); - begin - Txt (0) := Interfaces.C.char'First; - if Wgetnstr (Win, Txt, 8) = Curses_Err then - raise Curses_Exception; - end if; - Str := To_Unbounded_String (To_Ada (Txt, True)); - end myGet; - - - use Int_IO; - - use Ada.Strings.Unbounded; - - c : Key_Code; - buf : Unbounded_String; - c2 : Character; - fmt : Label_Justification := Centered; - tmp : Integer; - -begin - c := CTRL ('l'); - loop - Move_Cursor (Line => 0, Column => 0); - c2 := Code_To_Char (c); - case c2 is - when Character'Val (Character'Pos ('l') mod 16#20#) => -- CTRL('l') - Erase; - Switch_Character_Attribute (Attr => (Bold_Character => True, - others => False)); - Add (Line => 0, Column => 20, - Str => "Soft Key Exerciser"); - Switch_Character_Attribute (On => False, - Attr => (Bold_Character => True, - others => False)); - - Move_Cursor (Line => 2, Column => 0); - P ("Available commands are:"); - P (""); - P ("^L -- refresh screen"); - P ("a -- activate or restore soft keys"); - P ("d -- disable soft keys"); - P ("c -- set centered format for labels"); - P ("l -- set left-justified format for labels"); - P ("r -- set right-justified format for labels"); - P ("[12345678] -- set label; labels are numbered 1 through 8"); - P ("e -- erase stdscr (should not erase labels)"); - P ("s -- test scrolling of shortened screen"); - P ("x, q -- return to main menu"); - P (""); - P ("Note: if activating the soft keys causes your terminal to"); - P ("scroll up one line, your terminal auto-scrolls when anything"); - P ("is written to the last screen position. The ncurses code"); - P ("does not yet handle this gracefully."); - Refresh; - Restore_Soft_Label_Keys; - - when 'a' => - Restore_Soft_Label_Keys; - when 'e' => - Clear; - when 's' => - Add (Line => 20, Column => 0, - Str => "Press Q to stop the scrolling-test: "); - loop - c := Getchar; - c2 := Code_To_Char (c); - exit when c2 = 'Q'; - -- c = ERR? - -- TODO when c is not a character (arrow key) - -- the behavior is different from the C version. - Add (Ch => c2); - end loop; - when 'd' => - Clear_Soft_Label_Keys; - when 'l' => - fmt := Left; - when 'c' => - fmt := Centered; - when 'r' => - fmt := Right; - when '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' => - Add (Line => 20, Column => 0, - Str => "Please enter the label value: "); - Set_Echo_Mode (SwitchOn => True); - myGet (Str => buf); - Set_Echo_Mode (SwitchOn => False); - tmp := ctoi (c2); - Set_Soft_Label_Key (Label_Number (tmp), To_String (buf), fmt); - Refresh_Soft_Label_Keys; - Move_Cursor (Line => 20, Column => 0); - Clear_To_End_Of_Line; - when 'x' | 'q' => - exit; - -- the C version needed a goto, ha ha - -- breaks exit the case not the loop because fall-throuh - -- happens in C! - when others => - Beep; - end case; - c := Getchar; - -- TODO exit when c = EOF - end loop; - Erase; - End_Windows; -end ncurses2.slk_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.ads deleted file mode 100644 index 51e95871a9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-slk_test.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.slk_test; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.adb deleted file mode 100644 index 9948dc59c3..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.adb +++ /dev/null @@ -1,186 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with ncurses2.util; use ncurses2.util; - - --- Graphic-rendition test (adapted from vttest) - -procedure ncurses2.test_sgr_attributes is - - procedure xAdd (l : Line_Position; c : Column_Position; s : String); - - procedure xAdd (l : Line_Position; c : Column_Position; s : String) is - begin - Add (Line => l, Column => c, Str => s); - end xAdd; - - normal, current : Attributed_Character; -begin - for pass in reverse Boolean loop - if pass then - normal := (Ch => ' ', Attr => Normal_Video, Color => 0); - else - normal := (Ch => ' ', Attr => - (Reverse_Video => True, others => False), Color => 0); - end if; - - -- Use non-default colors if possible to exercise bce a little - if Has_Colors then - Init_Pair (1, White, Blue); - normal.Color := 1; - end if; - Set_Background (Ch => normal); - Erase; - xAdd (1, 20, "Graphic rendition test pattern:"); - - xAdd (4, 1, "vanilla"); - - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - Set_Background (Ch => current); - xAdd (4, 40, "bold"); - - current := normal; - current.Attr.Under_Line := not current.Attr.Under_Line; - Set_Background (Ch => current); - xAdd (6, 6, "underline"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Under_Line := not current.Attr.Under_Line; - Set_Background (Ch => current); - xAdd (6, 45, "bold underline"); - - current := normal; - current.Attr.Blink := not current.Attr.Blink; - Set_Background (Ch => current); - xAdd (8, 1, "blink"); - - current := normal; - current.Attr.Blink := not current.Attr.Blink; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - Set_Background (Ch => current); - xAdd (8, 40, "bold blink"); - - current := normal; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Blink := not current.Attr.Blink; - Set_Background (Ch => current); - xAdd (10, 6, "underline blink"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Blink := not current.Attr.Blink; - Set_Background (Ch => current); - xAdd (10, 45, "bold underline blink"); - - current := normal; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (12, 1, "negative"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (12, 40, "bold negative"); - - current := normal; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (14, 6, "underline negative"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (14, 45, "bold underline negative"); - - current := normal; - current.Attr.Blink := not current.Attr.Blink; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (16, 1, "blink negative"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Blink := not current.Attr.Blink; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (16, 40, "bold blink negative"); - - current := normal; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Blink := not current.Attr.Blink; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (18, 6, "underline blink negative"); - - current := normal; - current.Attr.Bold_Character := not current.Attr.Bold_Character; - current.Attr.Under_Line := not current.Attr.Under_Line; - current.Attr.Blink := not current.Attr.Blink; - current.Attr.Reverse_Video := not current.Attr.Reverse_Video; - Set_Background (Ch => current); - xAdd (18, 45, "bold underline blink negative"); - - Set_Background (Ch => normal); - Move_Cursor (Line => Lines - 2, Column => 1); - if pass then - Add (Str => "Dark"); - else - Add (Str => "Light"); - end if; - Add (Str => " background. "); - Clear_To_End_Of_Line; - Pause; - end loop; - - Set_Background (Ch => Blank2); - Erase; - End_Windows; - -end ncurses2.test_sgr_attributes; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.ads deleted file mode 100644 index 241118094e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-test_sgr_attributes.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.test_sgr_attributes; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.adb deleted file mode 100644 index 10b605a7b2..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.adb +++ /dev/null @@ -1,481 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses2.trace_set -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with ncurses2.util; use ncurses2.util; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Trace; use Terminal_Interface.Curses.Trace; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; - -with Ada.Strings.Bounded; - --- interactively set the trace level - -procedure ncurses2.trace_set is - - function menu_virtualize (c : Key_Code) return Menu_Request_Code; - function subset (super, sub : Trace_Attribute_Set) return Boolean; - function trace_or (a, b : Trace_Attribute_Set) return Trace_Attribute_Set; - function trace_num (tlevel : Trace_Attribute_Set) return String; - function tracetrace (tlevel : Trace_Attribute_Set) return String; - function run_trace_menu (m : Menu) return Boolean; - - function menu_virtualize (c : Key_Code) return Menu_Request_Code is - begin - case c is - when Character'Pos (newl) | Key_Exit => - return Menu_Request_Code'Last + 1; -- MAX_COMMAND? TODO - when Character'Pos ('u') => - return M_ScrollUp_Line; - when Character'Pos ('d') => - return M_ScrollDown_Line; - when Character'Pos ('b') | Key_Next_Page => - return M_ScrollUp_Page; - when Character'Pos ('f') | Key_Previous_Page => - return M_ScrollDown_Page; - when Character'Pos ('n') | Key_Cursor_Down => - return M_Next_Item; - when Character'Pos ('p') | Key_Cursor_Up => - return M_Previous_Item; - when Character'Pos (' ') => - return M_Toggle_Item; - when Key_Mouse => - return c; - when others => - Beep; - return c; - end case; - end menu_virtualize; - - - type string_a is access String; - type tbl_entry is record - name : string_a; - mask : Trace_Attribute_Set; - end record; - - t_tbl : constant array (Positive range <>) of tbl_entry := - ( - (new String'("Disable"), - Trace_Disable), - (new String'("Times"), - Trace_Attribute_Set'(Times => True, others => False)), - (new String'("Tputs"), - Trace_Attribute_Set'(Tputs => True, others => False)), - (new String'("Update"), - Trace_Attribute_Set'(Update => True, others => False)), - (new String'("Cursor_Move"), - Trace_Attribute_Set'(Cursor_Move => True, others => False)), - (new String'("Character_Output"), - Trace_Attribute_Set'(Character_Output => True, others => False)), - (new String'("Ordinary"), - Trace_Ordinary), - (new String'("Calls"), - Trace_Attribute_Set'(Calls => True, others => False)), - (new String'("Virtual_Puts"), - Trace_Attribute_Set'(Virtual_Puts => True, others => False)), - (new String'("Input_Events"), - Trace_Attribute_Set'(Input_Events => True, others => False)), - (new String'("TTY_State"), - Trace_Attribute_Set'(TTY_State => True, others => False)), - (new String'("Internal_Calls"), - Trace_Attribute_Set'(Internal_Calls => True, others => False)), - (new String'("Character_Calls"), - Trace_Attribute_Set'(Character_Calls => True, others => False)), - (new String'("Termcap_TermInfo"), - Trace_Attribute_Set'(Termcap_TermInfo => True, others => False)), - (new String'("Maximium"), - Trace_Maximum) - ); - - package BS is new Ada.Strings.Bounded.Generic_Bounded_Length (300); - - - function subset (super, sub : Trace_Attribute_Set) return Boolean is - begin - if - (super.Times or not sub.Times) and - (super.Tputs or not sub.Tputs) and - (super.Update or not sub.Update) and - (super.Cursor_Move or not sub.Cursor_Move) and - (super.Character_Output or not sub.Character_Output) and - (super.Calls or not sub.Calls) and - (super.Virtual_Puts or not sub.Virtual_Puts) and - (super.Input_Events or not sub.Input_Events) and - (super.TTY_State or not sub.TTY_State) and - (super.Internal_Calls or not sub.Internal_Calls) and - (super.Character_Calls or not sub.Character_Calls) and - (super.Termcap_TermInfo or not sub.Termcap_TermInfo) and - True then - return True; - else - return False; - end if; - end subset; - - function trace_or (a, b : Trace_Attribute_Set) return Trace_Attribute_Set is - retval : Trace_Attribute_Set := Trace_Disable; - begin - retval.Times := (a.Times or b.Times); - retval.Tputs := (a.Tputs or b.Tputs); - retval.Update := (a.Update or b.Update); - retval.Cursor_Move := (a.Cursor_Move or b.Cursor_Move); - retval.Character_Output := (a.Character_Output or b.Character_Output); - retval.Calls := (a.Calls or b.Calls); - retval.Virtual_Puts := (a.Virtual_Puts or b.Virtual_Puts); - retval.Input_Events := (a.Input_Events or b.Input_Events); - retval.TTY_State := (a.TTY_State or b.TTY_State); - retval.Internal_Calls := (a.Internal_Calls or b.Internal_Calls); - retval.Character_Calls := (a.Character_Calls or b.Character_Calls); - retval.Termcap_TermInfo := (a.Termcap_TermInfo or b.Termcap_TermInfo); - - return retval; - end trace_or; - - -- Print the hexadecimal value of the mask so - -- users can set it from the command line. - - function trace_num (tlevel : Trace_Attribute_Set) return String is - result : Integer := 0; - m : Integer := 1; - begin - - if tlevel.Times then - result := result + m; - end if; - m := m * 2; - - if tlevel.Tputs then - result := result + m; - end if; - m := m * 2; - - if tlevel.Update then - result := result + m; - end if; - m := m * 2; - - if tlevel.Cursor_Move then - result := result + m; - end if; - m := m * 2; - - if tlevel.Character_Output then - result := result + m; - end if; - m := m * 2; - - if tlevel.Calls then - result := result + m; - end if; - m := m * 2; - - if tlevel.Virtual_Puts then - result := result + m; - end if; - m := m * 2; - - if tlevel.Input_Events then - result := result + m; - end if; - m := m * 2; - - if tlevel.TTY_State then - result := result + m; - end if; - m := m * 2; - - if tlevel.Internal_Calls then - result := result + m; - end if; - m := m * 2; - - if tlevel.Character_Calls then - result := result + m; - end if; - m := m * 2; - - if tlevel.Termcap_TermInfo then - result := result + m; - end if; - m := m * 2; - return result'Img; - end trace_num; - - - function tracetrace (tlevel : Trace_Attribute_Set) return String is - - use BS; - buf : Bounded_String := To_Bounded_String (""); - begin - -- The C version prints the hexadecimal value of the mask, we - -- won't do that here because this is Ada. - - if tlevel = Trace_Disable then - Append (buf, "Trace_Disable"); - else - - - if subset (tlevel, - Trace_Attribute_Set'(Times => True, others => False)) then - Append (buf, "Times"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Tputs => True, others => False)) then - Append (buf, "Tputs"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Update => True, others => False)) then - Append (buf, "Update"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Cursor_Move => True, - others => False)) then - Append (buf, "Cursor_Move"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Character_Output => True, - others => False)) then - Append (buf, "Character_Output"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Ordinary) then - Append (buf, "Ordinary"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Calls => True, others => False)) then - Append (buf, "Calls"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Virtual_Puts => True, - others => False)) then - Append (buf, "Virtual_Puts"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Input_Events => True, - others => False)) then - Append (buf, "Input_Events"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(TTY_State => True, - others => False)) then - Append (buf, "TTY_State"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Internal_Calls => True, - others => False)) then - Append (buf, "Internal_Calls"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Character_Calls => True, - others => False)) then - Append (buf, "Character_Calls"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Attribute_Set'(Termcap_TermInfo => True, - others => False)) then - Append (buf, "Termcap_TermInfo"); - Append (buf, ", "); - end if; - - if subset (tlevel, - Trace_Maximum) then - Append (buf, "Maximium"); - Append (buf, ", "); - end if; - end if; - - if To_String (buf) (Length (buf) - 1) = ',' then - Delete (buf, Length (buf) - 1, Length (buf)); - end if; - - return To_String (buf); - end tracetrace; - - function run_trace_menu (m : Menu) return Boolean is - i, p : Item; - changed : Boolean; - c, v : Key_Code; - begin - loop - changed := False; - c := Getchar (Get_Window (m)); - v := menu_virtualize (c); - case Driver (m, v) is - when Unknown_Request => - return False; - when others => - i := Current (m); - if i = Menus.Items (m, 1) then -- the first item - for n in t_tbl'First + 1 .. t_tbl'Last loop - if Value (i) then - Set_Value (i, False); - changed := True; - end if; - end loop; - else - for n in t_tbl'First + 1 .. t_tbl'Last loop - p := Menus.Items (m, n); - if Value (p) then - Set_Value (Menus.Items (m, 1), False); - changed := True; - exit; - end if; - end loop; - end if; - if not changed then - return True; - end if; - end case; - end loop; - end run_trace_menu; - - nc_tracing, mask : Trace_Attribute_Set; - pragma Import (C, nc_tracing, "_nc_tracing"); - items_a : Item_Array_Access := - new Item_Array (t_tbl'First .. t_tbl'Last + 1); - mrows : Line_Count; - mcols : Column_Count; - menuwin : Window; - menu_y : constant Line_Position := 8; - menu_x : constant Column_Position := 8; - ip : Item; - m : Menu; - newtrace : Trace_Attribute_Set; -begin - Add (Line => 0, Column => 0, Str => "Interactively set trace level:"); - Add (Line => 2, Column => 0, - Str => " Press space bar to toggle a selection."); - Add (Line => 3, Column => 0, - Str => " Use up and down arrow to move the select bar."); - Add (Line => 4, Column => 0, - Str => " Press return to set the trace level."); - Add (Line => 6, Column => 0, Str => "(Current trace level is "); - Add (Str => tracetrace (nc_tracing) & " numerically: " & - trace_num (nc_tracing)); - Add (Ch => ')'); - - Refresh; - - for n in t_tbl'Range loop - items_a (n) := New_Item (t_tbl (n).name.all); - end loop; - items_a (t_tbl'Last + 1) := Null_Item; - - m := New_Menu (items_a); - - Set_Format (m, 16, 2); - Scale (m, mrows, mcols); - - Switch_Options (m, (One_Valued => True, others => False), On => False); - menuwin := New_Window (mrows + 2, mcols + 2, menu_y, menu_x); - Set_Window (m, menuwin); - Set_KeyPad_Mode (menuwin, SwitchOn => True); - Box (menuwin); - - Set_Sub_Window (m, Derived_Window (menuwin, mrows, mcols, 1, 1)); - - Post (m); - - for n in t_tbl'Range loop - ip := Items (m, n); - mask := t_tbl (n).mask; - if mask = Trace_Disable then - Set_Value (ip, nc_tracing = Trace_Disable); - elsif subset (sub => mask, super => nc_tracing) then - Set_Value (ip, True); - end if; - end loop; - - while run_trace_menu (m) loop - null; - end loop; - - newtrace := Trace_Disable; - for n in t_tbl'Range loop - ip := Items (m, n); - if Value (ip) then - mask := t_tbl (n).mask; - newtrace := trace_or (newtrace, mask); - end if; - end loop; - - Trace_On (newtrace); - Trace_Put ("trace level interactively set to " & - tracetrace (nc_tracing)); - - Move_Cursor (Line => Lines - 4, Column => 0); - Add (Str => "Trace level is "); - Add (Str => tracetrace (nc_tracing)); - Add (Ch => newl); - Pause; -- was just Add(); Getchar - - Post (m, False); - -- menuwin has subwindows I think, which makes an error. - declare begin - Delete (menuwin); - exception when Curses_Exception => null; end; - - -- free_menu(m); - -- free_item() -end ncurses2.trace_set; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.ads deleted file mode 100644 index 7bbf8ca545..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-trace_set.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses2.trace_set -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure ncurses2.trace_set; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.adb b/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.adb deleted file mode 100644 index 907dcef9c7..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.adb +++ /dev/null @@ -1,199 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses2.util -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Ada.Text_IO; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -pragma Warnings (Off); -with Terminal_Interface.Curses.Aux; -pragma Warnings (On); - -with Terminal_Interface.Curses.Trace; use Terminal_Interface.Curses.Trace; - -with Ada.Text_IO; use Ada.Text_IO; - -with Interfaces.C; -with Interfaces.C.Strings; - -with Ada.Characters.Handling; - -with ncurses2.genericPuts; - - -package body ncurses2.util is - - -- #defines from C - -- #define CTRL(x) ((x) & 0x1f) - function CTRL (c : Character) return Key_Code is - begin - return Character'Pos (c) mod 16#20#; - -- uses a property of ASCII - -- A = 16#41#; a = 16#61#; ^A = 1 or 16#1# - end CTRL; - - function CTRL (c : Character) return Character is - begin - return Character'Val (Character'Pos (c) mod 16#20#); - -- uses a property of ASCII - -- A = 16#41#; a = 16#61#; ^A = 1 or 16#1# - end CTRL; - - save_trace : Trace_Attribute_Set; - -- Common function to allow ^T to toggle trace-mode in the middle of a test - -- so that trace-files can be made smaller. - function Getchar (win : Window := Standard_Window) return Key_Code is - c : Key_Code; - begin - -- #ifdef TRACE - c := Get_Keystroke (win); - while c = CTRL ('T') loop - -- if _nc_tracing in C - if Current_Trace_Setting /= Trace_Disable then - save_trace := Current_Trace_Setting; - Trace_Put ("TOGGLE-TRACING OFF"); - Current_Trace_Setting := Trace_Disable; - else - Current_Trace_Setting := save_trace; - end if; - Trace_On (Current_Trace_Setting); - if Current_Trace_Setting /= Trace_Disable then - Trace_Put ("TOGGLE-TRACING ON"); - end if; - end loop; - -- #else c := Get_Keystroke; - return c; - end Getchar; - - procedure Getchar (win : Window := Standard_Window) is - x : Key_Code; - begin - x := Getchar (win); - end Getchar; - - - procedure Pause is - begin - Move_Cursor (Line => Lines - 1, Column => 0); - Add (Str => "Press any key to continue... "); - Getchar; - end Pause; - - - procedure Cannot (s : String) is - use Interfaces.C; - use Interfaces.C.Strings; - use Terminal_Interface.Curses.Aux; - function getenv (x : char_array) return chars_ptr; - pragma Import (C, getenv, "getenv"); - tmp1 : char_array (0 .. 10); - package p is new ncurses2.genericPuts (1024); - use p; - use p.BS; - - tmpb : BS.Bounded_String; - - Length : size_t; - begin - To_C ("TERM", tmp1, Length); - Fill_String (getenv (tmp1), tmpb); - Add (Ch => newl); - myAdd (Str => "This " & tmpb & " terminal " & s); - Pause; - end Cannot; - - procedure ShellOut (message : Boolean) is - use Interfaces.C; - Txt : char_array (0 .. 10); - Length : size_t; - procedure system (x : char_array); - pragma Import (C, system, "system"); - begin - To_C ("sh", Txt, Length); - if message then - Add (Str => "Shelling out..."); - end if; - Save_Curses_Mode (Mode => Curses); - End_Windows; - system (Txt); - if message then - Add (Str => "returned from shellout."); - Add (Ch => newl); - end if; - Refresh; - end ShellOut; - - - - function Is_Digit (c : Key_Code) return Boolean is - begin - if c >= 16#100# then - return False; - else - return Ada.Characters.Handling.Is_Digit (Character'Val (c)); - end if; - end Is_Digit; - - procedure P (s : String) is - begin - Add (Str => s); - Add (Ch => newl); - end P; - - - function Code_To_Char (c : Key_Code) return Character is - begin - if c > Character'Pos (Character'Last) then - return Character'Val (0); - -- maybe raise exception? - else - return Character'Val (c); - end if; - end Code_To_Char; - - -- This was untestable due to a bug in GNAT (3.12p) - -- Hmm, what bug? I don't remember. - function ctoi (c : Character) return Integer is - begin - return Character'Pos (c) - Character'Pos ('0'); - end ctoi; - -end ncurses2.util; diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.ads deleted file mode 100644 index 6c81e83e76..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2-util.ads +++ /dev/null @@ -1,79 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses2.util -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Ada.Text_IO; -package ncurses2.util is - - Blank : constant Character := ' '; - Blank2 : constant Attributed_Character := - (Ch => Blank, Attr => Normal_Video, Color => Color_Pair'First); - - - newl : constant Character := Character'Val (10); - - function CTRL (c : Character) return Key_Code; - - function CTRL (c : Character) return Character; - - function Getchar (win : Window := Standard_Window) return Key_Code; - - procedure Getchar (win : Window := Standard_Window); - - procedure Pause; - - - procedure Cannot (s : String); - - procedure ShellOut (message : Boolean); - - - package Int_IO is new Ada.Text_IO.Integer_IO (Integer); - - - function Is_Digit (c : Key_Code) return Boolean; - - procedure P (s : String); - - function Code_To_Char (c : Key_Code) return Character; - function ctoi (c : Character) return Integer; -end ncurses2.util; - diff --git a/contrib/ncurses-5.4/Ada95/samples/ncurses2.ads b/contrib/ncurses-5.4/Ada95/samples/ncurses2.ads deleted file mode 100644 index 2fe0197089..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/ncurses2.ads +++ /dev/null @@ -1,44 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- ncurses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Eugene V. Melaragno 2000 --- Version Control --- $Revision: 1.1 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -package ncurses2 is - pragma Pure (ncurses2); -end ncurses2; diff --git a/contrib/ncurses-5.4/Ada95/samples/rain.adb b/contrib/ncurses-5.4/Ada95/samples/rain.adb deleted file mode 100644 index c576f3f38c..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/rain.adb +++ /dev/null @@ -1,162 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Rain -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Laurent Pautet --- Modified by: Juergen Pfeifer, 1997 --- Version Control --- $Revision: 1.6 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- -- -with Ada.Numerics.Float_Random; use Ada.Numerics.Float_Random; -with Status; use Status; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -procedure Rain is - - Visibility : Cursor_Visibility; - - subtype X_Position is Line_Position; - subtype Y_Position is Column_Position; - - Xpos : array (1 .. 5) of X_Position; - Ypos : array (1 .. 5) of Y_Position; - - N : Integer; - - G : Generator; - - Max_X, X : X_Position; - Max_Y, Y : Y_Position; - - procedure Next (J : in out Integer); - procedure Cursor (X : X_Position; Y : Y_Position); - - procedure Next (J : in out Integer) is - begin - if J = 5 then - J := 1; - else - J := J + 1; - end if; - end Next; - - procedure Cursor (X : X_Position; Y : Y_Position) is - begin - Move_Cursor (Line => X, Column => Y); - end Cursor; - pragma Inline (Cursor); - -begin - - Init_Screen; - Set_NL_Mode; - Set_Echo_Mode (False); - - Visibility := Invisible; - Set_Cursor_Visibility (Visibility); - - Max_X := Lines - 5; - Max_Y := Columns - 5; - - for I in Xpos'Range loop - Xpos (I) := X_Position (Float (Max_X) * Random (G)) + 2; - Ypos (I) := Y_Position (Float (Max_Y) * Random (G)) + 2; - end loop; - - N := 1; - while Process.Continue loop - - X := X_Position (Float (Max_X) * Random (G)) + 2; - Y := Y_Position (Float (Max_Y) * Random (G)) + 2; - - Cursor (X, Y); - Add (Ch => '.'); - - Cursor (Xpos (N), Ypos (N)); - Add (Ch => 'o'); - - -- - Next (N); - Cursor (Xpos (N), Ypos (N)); - Add (Ch => 'O'); - - -- - Next (N); - Cursor (Xpos (N) - 1, Ypos (N)); - Add (Ch => '-'); - Cursor (Xpos (N), Ypos (N) - 1); - Add (Str => "|.|"); - Cursor (Xpos (N) + 1, Ypos (N)); - Add (Ch => '-'); - - -- - Next (N); - Cursor (Xpos (N) - 2, Ypos (N)); - Add (Ch => '-'); - Cursor (Xpos (N) - 1, Ypos (N) - 1); - Add (Str => "/\\"); - Cursor (Xpos (N), Ypos (N) - 2); - Add (Str => "| O |"); - Cursor (Xpos (N) + 1, Ypos (N) - 1); - Add (Str => "\\/"); - Cursor (Xpos (N) + 2, Ypos (N)); - Add (Ch => '-'); - - -- - Next (N); - Cursor (Xpos (N) - 2, Ypos (N)); - Add (Ch => ' '); - Cursor (Xpos (N) - 1, Ypos (N) - 1); - Add (Str => " "); - Cursor (Xpos (N), Ypos (N) - 2); - Add (Str => " "); - Cursor (Xpos (N) + 1, Ypos (N) - 1); - Add (Str => " "); - Cursor (Xpos (N) + 2, Ypos (N)); - Add (Ch => ' '); - - Xpos (N) := X; - Ypos (N) := Y; - - Refresh; - Nap_Milli_Seconds (50); - end loop; - - Visibility := Normal; - Set_Cursor_Visibility (Visibility); - End_Windows; - -end Rain; diff --git a/contrib/ncurses-5.4/Ada95/samples/rain.ads b/contrib/ncurses-5.4/Ada95/samples/rain.ads deleted file mode 100644 index 3ad1912c5e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/rain.ads +++ /dev/null @@ -1,43 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Rain -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Laurent Pautet --- Modified by: Juergen Pfeifer, 1997 --- Version Control --- $Revision: 1.6 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- -- -procedure Rain; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.adb b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.adb deleted file mode 100644 index c49f37d602..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.adb +++ /dev/null @@ -1,122 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo.Attributes -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Curses_Demo.Attributes is - - procedure Demo - is - P : Panel := Create (Standard_Window); - K : Real_Key_Code; - begin - Set_Meta_Mode; - Set_KeyPad_Mode; - - Top (P); - - Push_Environment ("ATTRIBDEMO"); - Default_Labels; - Notepad ("ATTRIB-PAD00"); - - Set_Character_Attributes (Attr => (others => False)); - Add (Line => 1, Column => Columns / 2 - 10, - Str => "This is NORMAL"); - - Set_Character_Attributes (Attr => (Stand_Out => True, - others => False)); - Add (Line => 2, Column => Columns / 2 - 10, - Str => "This is Stand_Out"); - - Set_Character_Attributes (Attr => (Under_Line => True, - others => False)); - Add (Line => 3, Column => Columns / 2 - 10, - Str => "This is Under_Line"); - - Set_Character_Attributes (Attr => (Reverse_Video => True, - others => False)); - Add (Line => 4, Column => Columns / 2 - 10, - Str => "This is Reverse_Video"); - - Set_Character_Attributes (Attr => (Blink => True, - others => False)); - Add (Line => 5, Column => Columns / 2 - 10, - Str => "This is Blink"); - - Set_Character_Attributes (Attr => (Dim_Character => True, - others => False)); - Add (Line => 6, Column => Columns / 2 - 10, - Str => "This is Dim_Character"); - - Set_Character_Attributes (Attr => (Bold_Character => True, - others => False)); - Add (Line => 7, Column => Columns / 2 - 10, - Str => "This is Bold_Character"); - - Refresh_Without_Update; - Update_Panels; Update_Screen; - - loop - K := Get_Key; - if K in Special_Key_Code'Range then - case K is - when QUIT_CODE => exit; - when HELP_CODE => Explain_Context; - when EXPLAIN_CODE => Explain ("ATTRIBKEYS"); - when others => null; - end case; - end if; - end loop; - - Pop_Environment; - Clear; - Refresh_Without_Update; - Delete (P); - Update_Panels; Update_Screen; - - end Demo; - -end Sample.Curses_Demo.Attributes; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.ads b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.ads deleted file mode 100644 index 6d9b4e8df8..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-attributes.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo.Attributes -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Curses_Demo.Attributes is - - procedure Demo; - -end Sample.Curses_Demo.Attributes; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.adb b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.adb deleted file mode 100644 index 34a0ab1156..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.adb +++ /dev/null @@ -1,220 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo.Mouse -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.13 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; -with Terminal_Interface.Curses.Text_IO; use Terminal_Interface.Curses.Text_IO; -with Terminal_Interface.Curses.Text_IO.Integer_IO; -with Terminal_Interface.Curses.Text_IO.Enumeration_IO; - -with Sample.Helpers; use Sample.Helpers; -with Sample.Manifest; use Sample.Manifest; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Curses_Demo.Mouse is - - package Int_IO is new - Terminal_Interface.Curses.Text_IO.Integer_IO (Integer); - use Int_IO; - - package Button_IO is new - Terminal_Interface.Curses.Text_IO.Enumeration_IO (Mouse_Button); - use Button_IO; - - package State_IO is new - Terminal_Interface.Curses.Text_IO.Enumeration_IO (Button_State); - use State_IO; - - procedure Demo is - - type Controls is array (1 .. 3) of Panel; - - Frame : Window; - Msg : Window; - Ctl : Controls; - Pan : Panel; - K : Real_Key_Code; - V : Cursor_Visibility := Invisible; - W : Window; - Note : Window; - Msg_L : constant Line_Count := 8; - Lins : Line_Position := Lines; - Cols : Column_Position; - Mask : Event_Mask; - procedure Show_Mouse_Event; - - procedure Show_Mouse_Event - is - Evt : constant Mouse_Event := Get_Mouse; - Y : Line_Position; - X : Column_Position; - Button : Mouse_Button; - State : Button_State; - W : Window; - begin - Get_Event (Evt, Y, X, Button, State); - Put (Msg, "Event at"); - Put (Msg, " X="); Put (Msg, Integer (X), 3); - Put (Msg, ", Y="); Put (Msg, Integer (Y), 3); - Put (Msg, ", Btn="); Put (Msg, Button, 10); - Put (Msg, ", Stat="); Put (Msg, State, 15); - for I in Ctl'Range loop - W := Get_Window (Ctl (I)); - if Enclosed_In_Window (W, Evt) then - Transform_Coordinates (W, Y, X, From_Screen); - Put (Msg, ",Box("); - Put (Msg, Integer (I), 1); Put (Msg, ","); - Put (Msg, Integer (Y), 1); Put (Msg, ","); - Put (Msg, Integer (X), 1); Put (Msg, ")"); - end if; - end loop; - New_Line (Msg); - Flush (Msg); - Update_Panels; Update_Screen; - end Show_Mouse_Event; - - begin - Push_Environment ("MOUSE00"); - Notepad ("MOUSE-PAD00"); - Default_Labels; - Set_Cursor_Visibility (V); - - Note := Notepad_Window; - if Note /= Null_Window then - Get_Window_Position (Note, Lins, Cols); - end if; - Frame := Create (Msg_L, Columns, Lins - Msg_L, 0); - if Has_Colors then - Set_Background (Win => Frame, - Ch => (Color => Default_Colors, - Attr => Normal_Video, - Ch => ' ')); - Set_Character_Attributes (Win => Frame, - Attr => Normal_Video, - Color => Default_Colors); - Erase (Frame); - end if; - Msg := Derived_Window (Frame, Msg_L - 2, Columns - 2, 1, 1); - Pan := Create (Frame); - - Set_Meta_Mode; - Set_KeyPad_Mode; - Mask := Start_Mouse; - - Box (Frame); - Window_Title (Frame, "Mouse Protocol"); - Refresh_Without_Update (Frame); - Allow_Scrolling (Msg, True); - - declare - Middle_Column : constant Integer := Integer (Columns) / 2; - Middle_Index : constant Natural := Ctl'First + (Ctl'Length / 2); - Width : constant Column_Count := 5; - Height : constant Line_Count := 3; - Half : constant Column_Count := Width / 2; - Space : constant Column_Count := 3; - Position : Integer; - W : Window; - begin - for I in Ctl'Range loop - Position := (Integer (I) - Integer (Middle_Index)) * - Integer (Half + Space + Width) + Middle_Column; - W := Create (Height, - Width, - 1, - Column_Position (Position)); - if Has_Colors then - Set_Background (Win => W, - Ch => (Color => Menu_Back_Color, - Attr => Normal_Video, - Ch => ' ')); - Set_Character_Attributes (Win => W, - Attr => Normal_Video, - Color => Menu_Fore_Color); - Erase (W); - end if; - Ctl (I) := Create (W); - Box (W); - Move_Cursor (W, 1, Half); - Put (W, Integer (I), 1); - Refresh_Without_Update (W); - end loop; - end; - - Update_Panels; Update_Screen; - - loop - K := Get_Key; - if K in Special_Key_Code'Range then - case K is - when QUIT_CODE => exit; - when HELP_CODE => Explain_Context; - when EXPLAIN_CODE => Explain ("MOUSEKEYS"); - when Key_Mouse => Show_Mouse_Event; - when others => null; - end case; - end if; - end loop; - - for I in Ctl'Range loop - W := Get_Window (Ctl (I)); - Clear (W); - Delete (Ctl (I)); - Delete (W); - end loop; - - Clear (Frame); - Delete (Pan); - Delete (Msg); - Delete (Frame); - - Set_Cursor_Visibility (V); - End_Mouse (Mask); - - Pop_Environment; - Update_Panels; Update_Screen; - - end Demo; - -end Sample.Curses_Demo.Mouse; - diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.ads b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.ads deleted file mode 100644 index ad78d0d0a7..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo-mouse.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo.Mouse -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Curses_Demo.Mouse is - - procedure Demo; - -end Sample.Curses_Demo.Mouse; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.adb b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.adb deleted file mode 100644 index aab45c2989..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.adb +++ /dev/null @@ -1,142 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Panels.User_Data; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Helpers; use Sample.Helpers; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; - -with Sample.Explanation; use Sample.Explanation; - -with Sample.Menu_Demo.Handler; -with Sample.Curses_Demo.Mouse; -with Sample.Curses_Demo.Attributes; - -package body Sample.Curses_Demo is - - type User_Data is new Integer; - type User_Data_Access is access all User_Data; - package PUD is new Panels.User_Data (User_Data, User_Data_Access); - -- We use above instantiation of the generic User_Data package to - -- demonstrate and test the use of the user data maechanism. - - procedure Demo - is - function My_Driver (M : Menu; - K : Key_Code; - Pan : Panel) return Boolean; - package Mh is new Sample.Menu_Demo.Handler (My_Driver); - - Itm : Item_Array_Access := new Item_Array' - (New_Item ("Attributes Demo"), - New_Item ("Mouse Demo"), - Null_Item); - M : Menu := New_Menu (Itm); - U1 : User_Data_Access := new User_Data'(4711); - U2 : User_Data_Access; - - function My_Driver (M : Menu; - K : Key_Code; - Pan : Panel) return Boolean - is - Idx : constant Positive := Get_Index (Current (M)); - Result : Boolean := False; - begin - PUD.Set_User_Data (Pan, U1); -- set some user data, just for fun - if K in User_Key_Code'Range then - if K = QUIT then - Result := True; - elsif K = SELECT_ITEM then - if Idx in Itm'Range then - Hide (Pan); - Update_Panels; - end if; - case Idx is - when 1 => Sample.Curses_Demo.Attributes.Demo; - when 2 => Sample.Curses_Demo.Mouse.Demo; - when others => Not_Implemented; - end case; - if Idx in Itm'Range then - Top (Pan); - Show (Pan); - Update_Panels; - Update_Screen; - end if; - end if; - end if; - PUD.Get_User_Data (Pan, U2); -- get the user data - pragma Assert (U1.all = U2.all and then U1 = U2); - return Result; - end My_Driver; - - begin - - if (1 + Item_Count (M)) /= Itm'Length then - raise Constraint_Error; - end if; - - if not Has_Mouse then - declare - O : Item_Option_Set; - begin - Get_Options (Itm (2), O); - O.Selectable := False; - Set_Options (Itm (2), O); - end; - end if; - - Push_Environment ("CURSES00"); - Notepad ("CURSES-PAD00"); - Default_Labels; - Refresh_Soft_Label_Keys_Without_Update; - - Mh.Drive_Me (M, " Demo "); - Pop_Environment; - - Delete (M); - Free (Itm, True); - end Demo; - -end Sample.Curses_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.ads b/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.ads deleted file mode 100644 index ed4ad0f019..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-curses_demo.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Curses_Demo -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Curses_Demo is - - procedure Demo; - -end Sample.Curses_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-explanation.adb b/contrib/ncurses-5.4/Ada95/samples/sample-explanation.adb deleted file mode 100644 index 705e02da5e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-explanation.adb +++ /dev/null @@ -1,408 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Explanation -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.15 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- Poor mans help system. This scans a sequential file for key lines and --- then reads the lines up to the next key. Those lines are presented in --- a window as help or explanation. --- -with Ada.Text_IO; use Ada.Text_IO; -with Ada.Unchecked_Deallocation; -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; - -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Manifest; use Sample.Manifest; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Helpers; use Sample.Helpers; - -package body Sample.Explanation is - - Help_Keys : constant String := "HELPKEYS"; - In_Help : constant String := "INHELP"; - - File_Name : String := "explain.msg"; - F : File_Type; - - type Help_Line; - type Help_Line_Access is access Help_Line; - pragma Controlled (Help_Line_Access); - type String_Access is access String; - pragma Controlled (String_Access); - - type Help_Line is - record - Prev, Next : Help_Line_Access; - Line : String_Access; - end record; - - procedure Explain (Key : in String; - Win : in Window); - - procedure Release_String is - new Ada.Unchecked_Deallocation (String, - String_Access); - procedure Release_Help_Line is - new Ada.Unchecked_Deallocation (Help_Line, - Help_Line_Access); - - function Search (Key : String) return Help_Line_Access; - procedure Release_Help (Root : in out Help_Line_Access); - - procedure Explain (Key : in String) - is - begin - Explain (Key, Null_Window); - end Explain; - - procedure Explain (Key : in String; - Win : in Window) - is - -- Retrieve the text associated with this key and display it in this - -- window. If no window argument is passed, the routine will create - -- a temporary window and use it. - - function Filter_Key return Real_Key_Code; - procedure Unknown_Key; - procedure Redo; - procedure To_Window (C : in out Help_Line_Access; - More : in out Boolean); - - Frame : Window := Null_Window; - - W : Window := Win; - K : Real_Key_Code; - P : Panel; - - Height : Line_Count; - Width : Column_Count; - Help : Help_Line_Access := Search (Key); - Current : Help_Line_Access; - Top_Line : Help_Line_Access; - - Has_More : Boolean; - - procedure Unknown_Key - is - begin - Add (W, "Help message with ID "); - Add (W, Key); - Add (W, " not found."); - Add (W, Character'Val (10)); - Add (W, "Press the Function key labelled 'Quit' key to continue."); - end Unknown_Key; - - procedure Redo - is - H : Help_Line_Access := Top_Line; - begin - if Top_Line /= null then - for L in 0 .. (Height - 1) loop - Add (W, L, 0, H.Line.all); - exit when H.Next = null; - H := H.Next; - end loop; - else - Unknown_Key; - end if; - end Redo; - - function Filter_Key return Real_Key_Code - is - K : Real_Key_Code; - begin - loop - K := Get_Key (W); - if K in Special_Key_Code'Range then - case K is - when HELP_CODE => - if not Find_Context (In_Help) then - Push_Environment (In_Help, False); - Explain (In_Help, W); - Pop_Environment; - Redo; - end if; - when EXPLAIN_CODE => - if not Find_Context (Help_Keys) then - Push_Environment (Help_Keys, False); - Explain (Help_Keys, W); - Pop_Environment; - Redo; - end if; - when others => exit; - end case; - else - exit; - end if; - end loop; - return K; - end Filter_Key; - - procedure To_Window (C : in out Help_Line_Access; - More : in out Boolean) - is - L : Line_Position := 0; - begin - loop - Add (W, L, 0, C.Line.all); - L := L + 1; - exit when C.Next = null or else L = Height; - C := C.Next; - end loop; - if C.Next /= null then - pragma Assert (L = Height); - More := True; - else - More := False; - end if; - end To_Window; - - begin - if W = Null_Window then - Push_Environment ("HELP"); - Default_Labels; - Frame := New_Window (Lines - 2, Columns, 0, 0); - if Has_Colors then - Set_Background (Win => Frame, - Ch => (Ch => ' ', - Color => Help_Color, - Attr => Normal_Video)); - Set_Character_Attributes (Win => Frame, - Attr => Normal_Video, - Color => Help_Color); - Erase (Frame); - end if; - Box (Frame); - Set_Character_Attributes (Frame, (Reverse_Video => True, - others => False)); - Add (Frame, Lines - 3, 2, "Cursor Up/Down scrolls"); - Set_Character_Attributes (Frame); -- Back to default. - Window_Title (Frame, "Explanation"); - W := Derived_Window (Frame, Lines - 4, Columns - 2, 1, 1); - Refresh_Without_Update (Frame); - Get_Size (W, Height, Width); - Set_Meta_Mode (W); - Set_KeyPad_Mode (W); - Allow_Scrolling (W, True); - Set_Echo_Mode (False); - P := Create (Frame); - Top (P); - Update_Panels; - else - Clear (W); - Refresh_Without_Update (W); - end if; - - Current := Help; Top_Line := Help; - - if null = Help then - Unknown_Key; - loop - K := Filter_Key; - exit when K = QUIT_CODE; - end loop; - else - To_Window (Current, Has_More); - if Has_More then - -- This means there are more lines available, so we have to go - -- into a scroll manager. - loop - K := Filter_Key; - if K in Special_Key_Code'Range then - case K is - when Key_Cursor_Down => - if Current.Next /= null then - Move_Cursor (W, Height - 1, 0); - Scroll (W, 1); - Current := Current.Next; - Top_Line := Top_Line.Next; - Add (W, Current.Line.all); - end if; - when Key_Cursor_Up => - if Top_Line.Prev /= null then - Move_Cursor (W, 0, 0); - Scroll (W, -1); - Top_Line := Top_Line.Prev; - Current := Current.Prev; - Add (W, Top_Line.Line.all); - end if; - when QUIT_CODE => exit; - when others => null; - end case; - end if; - end loop; - else - loop - K := Filter_Key; - exit when K = QUIT_CODE; - end loop; - end if; - end if; - - Clear (W); - - if Frame /= Null_Window then - Clear (Frame); - Delete (P); - Delete (W); - Delete (Frame); - Pop_Environment; - end if; - - Update_Panels; - Update_Screen; - - Release_Help (Help); - - end Explain; - - function Search (Key : String) return Help_Line_Access - is - Last : Natural; - Buffer : String (1 .. 256); - Root : Help_Line_Access := null; - Current : Help_Line_Access; - Tail : Help_Line_Access := null; - - function Next_Line return Boolean; - - function Next_Line return Boolean - is - H_End : constant String := "#END"; - begin - Get_Line (F, Buffer, Last); - if Last = H_End'Length and then H_End = Buffer (1 .. Last) then - return False; - else - return True; - end if; - end Next_Line; - begin - Reset (F); - Outer : - loop - exit Outer when not Next_Line; - if Last = (1 + Key'Length) and then Key = Buffer (2 .. Last) - and then Buffer (1) = '#' then - loop - exit when not Next_Line; - exit when Buffer (1) = '#'; - Current := new Help_Line'(null, null, - new String'(Buffer (1 .. Last))); - if Tail = null then - Release_Help (Root); - Root := Current; - else - Tail.Next := Current; - Current.Prev := Tail; - end if; - Tail := Current; - end loop; - exit Outer; - end if; - end loop Outer; - return Root; - end Search; - - procedure Release_Help (Root : in out Help_Line_Access) - is - Next : Help_Line_Access; - begin - loop - exit when Root = null; - Next := Root.Next; - Release_String (Root.Line); - Release_Help_Line (Root); - Root := Next; - end loop; - end Release_Help; - - procedure Explain_Context - is - begin - Explain (Context); - end Explain_Context; - - procedure Notepad (Key : in String) - is - H : constant Help_Line_Access := Search (Key); - T : Help_Line_Access := H; - N : Line_Count := 1; - L : Line_Position := 0; - W : Window; - P : Panel; - begin - if H /= null then - loop - T := T.Next; - exit when T = null; - N := N + 1; - end loop; - W := New_Window (N + 2, Columns, Lines - N - 2, 0); - if Has_Colors then - Set_Background (Win => W, - Ch => (Ch => ' ', - Color => Notepad_Color, - Attr => Normal_Video)); - Set_Character_Attributes (Win => W, - Attr => Normal_Video, - Color => Notepad_Color); - Erase (W); - end if; - Box (W); - Window_Title (W, "Notepad"); - P := New_Panel (W); - T := H; - loop - Add (W, L + 1, 1, T.Line.all, Integer (Columns - 2)); - L := L + 1; - T := T.Next; - exit when T = null; - end loop; - T := H; - Release_Help (T); - Refresh_Without_Update (W); - Notepad_To_Context (P); - end if; - end Notepad; - -begin - Open (F, In_File, File_Name); -end Sample.Explanation; - diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-explanation.ads b/contrib/ncurses-5.4/Ada95/samples/sample-explanation.ads deleted file mode 100644 index 18617ac46a..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-explanation.ads +++ /dev/null @@ -1,59 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Explanation -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- Poor mans help system. This scans a sequential file for key lines and --- then reads the lines up to the next key. Those lines are presented in --- a window as help or explanation. --- -package Sample.Explanation is - - procedure Explain (Key : in String); - -- Retrieve the text associated with this key and display it. - - procedure Explain_Context; - -- Explain the current context. - - procedure Notepad (Key : in String); - -- Put a note on the screen and maintain it with the context - - Explanation_Not_Found : exception; - Explanation_Error : exception; - -end Sample.Explanation; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.adb b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.adb deleted file mode 100644 index 712fb5d122..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.adb +++ /dev/null @@ -1,259 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo.Aux -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.13 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Characters.Latin_1; use Ada.Characters.Latin_1; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Helpers; use Sample.Helpers; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Form_Demo.Aux is - - procedure Geometry (F : in Form; - L : out Line_Count; -- Lines used for menu - C : out Column_Count; -- Columns used for menu - Y : out Line_Position; -- Proposed Line for menu - X : out Column_Position) -- Proposed Column for menu - is - begin - Scale (F, L, C); - - L := L + 2; -- count for frame at top and bottom - C := C + 2; -- " - - -- Calculate horizontal coordinate at the screen center - X := (Columns - C) / 2; - Y := 1; -- start always in line 1 - end Geometry; - - function Create (F : Form; - Title : String; - Lin : Line_Position; - Col : Column_Position) return Panel - is - W, S : Window; - L : Line_Count; - C : Column_Count; - Y : Line_Position; - X : Column_Position; - Pan : Panel; - begin - Geometry (F, L, C, Y, X); - W := New_Window (L, C, Lin, Col); - Set_Meta_Mode (W); - Set_KeyPad_Mode (W); - if Has_Colors then - Set_Background (Win => W, - Ch => (Ch => ' ', - Color => Default_Colors, - Attr => Normal_Video)); - Set_Character_Attributes (Win => W, - Color => Default_Colors, - Attr => Normal_Video); - Erase (W); - end if; - S := Derived_Window (W, L - 2, C - 2, 1, 1); - Set_Meta_Mode (S); - Set_KeyPad_Mode (S); - Box (W); - Set_Window (F, W); - Set_Sub_Window (F, S); - if Title'Length > 0 then - Window_Title (W, Title); - end if; - Pan := New_Panel (W); - Post (F); - return Pan; - end Create; - - procedure Destroy (F : in Form; - P : in out Panel) - is - W, S : Window; - begin - W := Get_Window (F); - S := Get_Sub_Window (F); - Post (F, False); - Erase (W); - Delete (P); - Set_Window (F, Null_Window); - Set_Sub_Window (F, Null_Window); - Delete (S); - Delete (W); - Update_Panels; - end Destroy; - - function Get_Request (F : Form; - P : Panel; - Handle_CRLF : Boolean := True) return Key_Code - is - W : constant Window := Get_Window (F); - K : Real_Key_Code; - Ch : Character; - begin - Top (P); - loop - K := Get_Key (W); - if K in Special_Key_Code'Range then - case K is - when HELP_CODE => Explain_Context; - when EXPLAIN_CODE => Explain ("FORMKEYS"); - when Key_Home => return F_First_Field; - when Key_End => return F_Last_Field; - when QUIT_CODE => return QUIT; - when Key_Cursor_Down => return F_Down_Char; - when Key_Cursor_Up => return F_Up_Char; - when Key_Cursor_Left => return F_Previous_Char; - when Key_Cursor_Right => return F_Next_Char; - when Key_Next_Page => return F_Next_Page; - when Key_Previous_Page => return F_Previous_Page; - when Key_Backspace => return F_Delete_Previous; - when Key_Clear_Screen => return F_Clear_Field; - when Key_Clear_End_Of_Line => return F_Clear_EOF; - when others => return K; - end case; - elsif K in Normal_Key_Code'Range then - Ch := Character'Val (K); - case Ch is - when CAN => return QUIT; -- CTRL-X - - when ACK => return F_Next_Field; -- CTRL-F - when STX => return F_Previous_Field; -- CTRL-B - when FF => return F_Left_Field; -- CTRL-L - when DC2 => return F_Right_Field; -- CTRL-R - when NAK => return F_Up_Field; -- CTRL-U - when EOT => return F_Down_Field; -- CTRL-D - - when ETB => return F_Next_Word; -- CTRL-W - when DC4 => return F_Previous_Word; -- CTRL-T - - when SOH => return F_Begin_Field; -- CTRL-A - when ENQ => return F_End_Field; -- CTRL-E - - when HT => return F_Insert_Char; -- CTRL-I - when SI => return F_Insert_Line; -- CTRL-O - when SYN => return F_Delete_Char; -- CTRL-V - when BS => return F_Delete_Previous; -- CTRL-H - when EM => return F_Delete_Line; -- CTRL-Y - when BEL => return F_Delete_Word; -- CTRL-G - when VT => return F_Clear_EOF; -- CTRL-K - - when SO => return F_Next_Choice; -- CTRL-N - when DLE => return F_Previous_Choice; -- CTRL-P - - when CR | LF => - if Handle_CRLF then - return F_New_Line; - else - return K; - end if; - when others => return K; - end case; - else - return K; - end if; - end loop; - end Get_Request; - - function Make (Top : Line_Position; - Left : Column_Position; - Text : String) return Field - is - Fld : Field; - C : Column_Count := Column_Count (Text'Length); - begin - Fld := New_Field (1, C, Top, Left); - Set_Buffer (Fld, 0, Text); - Switch_Options (Fld, (Active => True, others => False), False); - if Has_Colors then - Set_Background (Fld => Fld, Color => Default_Colors); - end if; - return Fld; - end Make; - - function Make (Height : Line_Count := 1; - Width : Column_Count; - Top : Line_Position; - Left : Column_Position; - Off_Screen : Natural := 0) return Field - is - Fld : Field := New_Field (Height, Width, Top, Left, Off_Screen); - begin - if Has_Colors then - Set_Foreground (Fld => Fld, Color => Form_Fore_Color); - Set_Background (Fld => Fld, Color => Form_Back_Color); - else - Set_Background (Fld, (Reverse_Video => True, others => False)); - end if; - return Fld; - end Make; - - function Default_Driver (F : Form; - K : Key_Code; - P : Panel) return Boolean - is - begin - if K in User_Key_Code'Range and then K = QUIT then - if Driver (F, F_Validate_Field) = Form_Ok then - return True; - end if; - end if; - return False; - end Default_Driver; - - function Count_Active (F : Form) return Natural - is - N : Natural := 0; - O : Field_Option_Set; - H : constant Natural := Field_Count (F); - begin - if H > 0 then - for I in 1 .. H loop - Get_Options (Fields (F, I), O); - if O.Active then - N := N + 1; - end if; - end loop; - end if; - return N; - end Count_Active; - -end Sample.Form_Demo.Aux; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.ads b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.ads deleted file mode 100644 index 2317e14504..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-aux.ads +++ /dev/null @@ -1,92 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo.Aux -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; - -package Sample.Form_Demo.Aux is - - procedure Geometry (F : in Form; - L : out Line_Count; - C : out Column_Count; - Y : out Line_Position; - X : out Column_Position); - -- Calculate the geometry for a panel beeing able to be used to display - -- the menu. - - function Create (F : Form; - Title : String; - Lin : Line_Position; - Col : Column_Position) return Panel; - -- Create a panel decorated with a frame and the title at the specified - -- position. The dimension of the panel is derived from the menus layout. - - procedure Destroy (F : in Form; - P : in out Panel); - -- Destroy all the windowing structures associated with this menu and - -- panel. - - function Get_Request (F : Form; - P : Panel; - Handle_CRLF : Boolean := True) return Key_Code; - -- Centralized request driver for all menus in this sample. This - -- gives us a common key binding for all menus. - - function Make (Top : Line_Position; - Left : Column_Position; - Text : String) return Field; - -- create a label - - function Make (Height : Line_Count := 1; - Width : Column_Count; - Top : Line_Position; - Left : Column_Position; - Off_Screen : Natural := 0) return Field; - -- create a editable field - - function Default_Driver (F : Form; - K : Key_Code; - P : Panel) return Boolean; - - function Count_Active (F : Form) return Natural; - -- Count the number of active fields in the form - -end Sample.Form_Demo.Aux; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.adb b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.adb deleted file mode 100644 index 667df4ddec..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.adb +++ /dev/null @@ -1,97 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo.Handler -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Sample.Form_Demo.Aux; - -package body Sample.Form_Demo.Handler is - - package Aux renames Sample.Form_Demo.Aux; - - procedure Drive_Me (F : in Form; - Title : in String := "") - is - L : Line_Count; - C : Column_Count; - Y : Line_Position; - X : Column_Position; - begin - Aux.Geometry (F, L, C, Y, X); - Drive_Me (F, Y, X, Title); - end Drive_Me; - - procedure Drive_Me (F : in Form; - Lin : in Line_Position; - Col : in Column_Position; - Title : in String := "") - is - Pan : Panel := Aux.Create (F, Title, Lin, Col); - V : Cursor_Visibility := Normal; - Handle_CRLF : Boolean := True; - - begin - Set_Cursor_Visibility (V); - if Aux.Count_Active (F) = 1 then - Handle_CRLF := False; - end if; - loop - declare - K : Key_Code := Aux.Get_Request (F, Pan, Handle_CRLF); - R : Driver_Result; - begin - if (K = 13 or else K = 10) and then not Handle_CRLF then - R := Unknown_Request; - else - R := Driver (F, K); - end if; - case R is - when Form_Ok => null; - when Unknown_Request => - if My_Driver (F, K, Pan) then - exit; - end if; - when others => Beep; - end case; - end; - end loop; - Set_Cursor_Visibility (V); - Aux.Destroy (F, Pan); - end Drive_Me; - -end Sample.Form_Demo.Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.ads b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.ads deleted file mode 100644 index 4a5641213e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo-handler.ads +++ /dev/null @@ -1,64 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo.Handler -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; -use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; -use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Forms; -use Terminal_Interface.Curses.Forms; - -generic - with function My_Driver (Frm : Form; - K : Key_Code; - Pan : Panel) return Boolean; -package Sample.Form_Demo.Handler is - - procedure Drive_Me (F : in Form; - Lin : in Line_Position; - Col : in Column_Position; - Title : in String := ""); - -- Position the menu at the given point and drive it. - - procedure Drive_Me (F : in Form; - Title : in String := ""); - -- Center menu and drive it. - -end Sample.Form_Demo.Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.adb b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.adb deleted file mode 100644 index c5df36f7c0..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.adb +++ /dev/null @@ -1,134 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; -with Terminal_Interface.Curses.Forms.Field_User_Data; -with Terminal_Interface.Curses.Forms.Form_User_Data; -with Sample.My_Field_Type; use Sample.My_Field_Type; -with Sample.Explanation; use Sample.Explanation; -with Sample.Form_Demo.Aux; use Sample.Form_Demo.Aux; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Form_Demo.Handler; - -with Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada; -with Terminal_Interface.Curses.Forms.Field_Types.Enumeration; -use Terminal_Interface.Curses.Forms.Field_Types.Enumeration; -with Terminal_Interface.Curses.Forms.Field_Types.IntField; -use Terminal_Interface.Curses.Forms.Field_Types.IntField; - -package body Sample.Form_Demo is - - type User_Data is - record - Data : Integer; - end record; - type User_Access is access User_Data; - - package Fld_U is new - Terminal_Interface.Curses.Forms.Field_User_Data (User_Data, - User_Access); - - package Frm_U is new - Terminal_Interface.Curses.Forms.Form_User_Data (User_Data, - User_Access); - - type Weekday is (Sunday, Monday, Tuesday, Wednesday, Thursday, - Friday, Saturday); - - package Weekday_Enum is new - Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada (Weekday); - - Enum_Field : constant Enumeration_Field := - Weekday_Enum.Create; - - procedure Demo - is - - Mft : My_Data := (Ch => 'X'); - - FA : Field_Array_Access := new Field_Array' - (Make (0, 14, "Sample Entry Form"), - Make (2, 0, "WeekdayEnumeration"), - Make (2, 20, "Numeric 1-10"), - Make (2, 34, "Only 'X'"), - Make (5, 0, "Multiple Lines offscreen(Scroll)"), - Make (Width => 18, Top => 3, Left => 0), - Make (Width => 12, Top => 3, Left => 20), - Make (Width => 12, Top => 3, Left => 34), - Make (Width => 46, Top => 6, Left => 0, Height => 4, Off_Screen => 2), - Null_Field - ); - - Frm : Terminal_Interface.Curses.Forms.Form := Create (FA); - - I_F : constant Integer_Field := (Precision => 0, - Lower_Limit => 1, - Upper_Limit => 10); - - F1, F2 : User_Access; - - package Fh is new Sample.Form_Demo.Handler (Default_Driver); - - begin - Push_Environment ("FORM00"); - Notepad ("FORM-PAD00"); - Default_Labels; - - Set_Field_Type (FA (6), Enum_Field); - Set_Field_Type (FA (7), I_F); - Set_Field_Type (FA (8), Mft); - - F1 := new User_Data'(Data => 4711); - Fld_U.Set_User_Data (FA (1), F1); - - Fh.Drive_Me (Frm); - - Fld_U.Get_User_Data (FA (1), F2); - pragma Assert (F1 = F2); - pragma Assert (F1.Data = F2.Data); - - Pop_Environment; - Delete (Frm); - - Free (FA, True); - end Demo; - -end Sample.Form_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.ads b/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.ads deleted file mode 100644 index bd33f57875..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-form_demo.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Form_Demo -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Form_Demo is - - procedure Demo; - -end Sample.Form_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.adb b/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.adb deleted file mode 100644 index 9c7a31e8e3..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.adb +++ /dev/null @@ -1,213 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Function_Key_Setting -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Deallocation; -with Sample.Manifest; use Sample.Manifest; - --- This package implements a simple stack of function key label environments. --- -package body Sample.Function_Key_Setting is - - Max_Label_Length : constant Positive := 8; - Number_Of_Keys : Label_Number := Label_Number'Last; - Justification : Label_Justification := Left; - - subtype Label is String (1 .. Max_Label_Length); - type Label_Array is array (Label_Number range <>) of Label; - - type Key_Environment (N : Label_Number := Label_Number'Last); - type Env_Ptr is access Key_Environment; - pragma Controlled (Env_Ptr); - - type String_Access is access String; - pragma Controlled (String_Access); - - Active_Context : String_Access := new String'("MAIN"); - Active_Notepad : Panel := Null_Panel; - - type Key_Environment (N : Label_Number := Label_Number'Last) is - record - Prev : Env_Ptr; - Help : String_Access; - Notepad : Panel; - Labels : Label_Array (1 .. N); - end record; - - procedure Release_String is - new Ada.Unchecked_Deallocation (String, - String_Access); - - procedure Release_Environment is - new Ada.Unchecked_Deallocation (Key_Environment, - Env_Ptr); - - Top_Of_Stack : Env_Ptr := null; - - procedure Push_Environment (Key : in String; - Reset : in Boolean := True) - is - P : constant Env_Ptr := new Key_Environment (Number_Of_Keys); - begin - -- Store the current labels in the environment - for I in 1 .. Number_Of_Keys loop - Get_Soft_Label_Key (I, P.Labels (I)); - if Reset then - Set_Soft_Label_Key (I, " "); - end if; - end loop; - P.Prev := Top_Of_Stack; - -- now store active help context and notepad - P.Help := Active_Context; - P.Notepad := Active_Notepad; - -- The notepad must now vanish and the new notepad is empty. - if (P.Notepad /= Null_Panel) then - Hide (P.Notepad); - Update_Panels; - end if; - Active_Notepad := Null_Panel; - Active_Context := new String'(Key); - - Top_Of_Stack := P; - if Reset then - Refresh_Soft_Label_Keys_Without_Update; - end if; - end Push_Environment; - - procedure Pop_Environment - is - P : Env_Ptr := Top_Of_Stack; - begin - if Top_Of_Stack = null then - raise Function_Key_Stack_Error; - else - for I in 1 .. Number_Of_Keys loop - Set_Soft_Label_Key (I, P.Labels (I), Justification); - end loop; - pragma Assert (Active_Context /= null); - Release_String (Active_Context); - Active_Context := P.Help; - Refresh_Soft_Label_Keys_Without_Update; - Notepad_To_Context (P.Notepad); - Top_Of_Stack := P.Prev; - Release_Environment (P); - end if; - end Pop_Environment; - - function Context return String - is - begin - if Active_Context /= null then - return Active_Context.all; - else - return ""; - end if; - end Context; - - function Find_Context (Key : String) return Boolean - is - P : Env_Ptr := Top_Of_Stack; - begin - if Active_Context.all = Key then - return True; - else - loop - exit when P = null; - if P.Help.all = Key then - return True; - else - P := P.Prev; - end if; - end loop; - return False; - end if; - end Find_Context; - - procedure Notepad_To_Context (Pan : in Panel) - is - W : Window; - begin - if Active_Notepad /= Null_Panel then - W := Get_Window (Active_Notepad); - Clear (W); - Delete (Active_Notepad); - Delete (W); - end if; - Active_Notepad := Pan; - if Pan /= Null_Panel then - Top (Pan); - end if; - Update_Panels; - Update_Screen; - end Notepad_To_Context; - - procedure Initialize (Mode : Soft_Label_Key_Format := PC_Style; - Just : Label_Justification := Left) - is - begin - case Mode is - when PC_Style .. PC_Style_With_Index - => Number_Of_Keys := 12; - when others - => Number_Of_Keys := 8; - end case; - Init_Soft_Label_Keys (Mode); - Justification := Just; - end Initialize; - - procedure Default_Labels - is - begin - Set_Soft_Label_Key (FKEY_QUIT, "Quit"); - Set_Soft_Label_Key (FKEY_HELP, "Help"); - Set_Soft_Label_Key (FKEY_EXPLAIN, "Keys"); - Refresh_Soft_Label_Keys_Without_Update; - end Default_Labels; - - function Notepad_Window return Window - is - begin - if Active_Notepad /= Null_Panel then - return Get_Window (Active_Notepad); - else - return Null_Window; - end if; - end Notepad_Window; - -end Sample.Function_Key_Setting; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.ads b/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.ads deleted file mode 100644 index e20f619acd..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-function_key_setting.ads +++ /dev/null @@ -1,82 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Function_Key_Setting -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; - --- This package implements a simple stack of function key label environments. --- -package Sample.Function_Key_Setting is - - procedure Push_Environment (Key : in String; - Reset : in Boolean := True); - -- Push the definition of the current function keys on an internal - -- stack. If the reset flag is true, all labels are reset while - -- pushed, so the new environment can assume a tabula rasa. - -- The Key defines the new Help Context associated with the new - -- Environment. This saves also the currently active Notepad. - - procedure Pop_Environment; - -- Pop the Definitions from the stack and make them the current ones. - -- This also restores the Help context and the previous Notepad. - - procedure Initialize (Mode : Soft_Label_Key_Format := PC_Style; - Just : Label_Justification := Left); - -- Initialize the environment - - function Context return String; - -- Return the current context identitfier - - function Find_Context (Key : String) return Boolean; - -- Look for a context, return true if it is in the stack, - -- false otherwise. - - procedure Notepad_To_Context (Pan : in Panel); - -- Add a panel representing a notepad to the current context. - - Function_Key_Stack_Error : exception; - - procedure Default_Labels; - -- Set the default labels used in all environments - - function Notepad_Window return Window; - -- Return the current notepad window or Null_Window if there is none. - -end Sample.Function_Key_Setting; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.adb b/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.adb deleted file mode 100644 index 2c51e94193..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.adb +++ /dev/null @@ -1,180 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Header_Handler -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Calendar; use Ada.Calendar; -with Terminal_Interface.Curses.Text_IO.Integer_IO; -with Sample.Manifest; use Sample.Manifest; - --- This package handles the painting of the header line of the screen. --- -package body Sample.Header_Handler is - - package Int_IO is new - Terminal_Interface.Curses.Text_IO.Integer_IO (Integer); - use Int_IO; - - Header_Window : Window := Null_Window; - - Display_Hour : Integer := -1; -- hour last displayed - Display_Min : Integer := -1; -- minute last displayed - Display_Day : Integer := -1; -- day last displayed - Display_Month : Integer := -1; -- month last displayed - - -- This is the routine handed over to the curses library to be called - -- as initialization routine when ripping of the header lines from - -- the screen. This routine must follow C conventions. - function Init_Header_Window (Win : Window; - Columns : Column_Count) return Integer; - pragma Convention (C, Init_Header_Window); - - procedure Internal_Update_Header_Window (Do_Update : in Boolean); - - - -- The initialization must be called before Init_Screen. It steals two - -- lines from the top of the screen. - procedure Init_Header_Handler - is - begin - Rip_Off_Lines (2, Init_Header_Window'Access); - end Init_Header_Handler; - - procedure N_Out (N : in Integer); - - -- Emit a two digit number and ensure that a leading zero is generated if - -- necessary. - procedure N_Out (N : in Integer) - is - begin - if N < 10 then - Add (Header_Window, '0'); - Put (Header_Window, N, 1); - else - Put (Header_Window, N, 2); - end if; - end N_Out; - - -- Paint the header window. The input parameter is a flag indicating - -- whether or not the screen should be updated physically after painting. - procedure Internal_Update_Header_Window (Do_Update : in Boolean) - is - type Month_Name_Array is - array (Month_Number'First .. Month_Number'Last) of String (1 .. 9); - - Month_Names : constant Month_Name_Array := - ("January ", - "February ", - "March ", - "April ", - "May ", - "June ", - "July ", - "August ", - "September", - "October ", - "November ", - "December "); - - Now : Time := Clock; - Sec : Integer := Integer (Seconds (Now)); - Hour : Integer := Sec / 3600; - Minute : Integer := (Sec - Hour * 3600) / 60; - Mon : Month_Number := Month (Now); - D : Day_Number := Day (Now); - begin - if Header_Window /= Null_Window then - if Minute /= Display_Min or else Hour /= Display_Hour - or else Display_Day /= D or else Display_Month /= Mon then - Move_Cursor (Header_Window, 0, 0); - N_Out (D); Add (Header_Window, '.'); - Add (Header_Window, Month_Names (Mon)); - Move_Cursor (Header_Window, 1, 0); - N_Out (Hour); Add (Header_Window, ':'); - N_Out (Minute); - Display_Min := Minute; - Display_Hour := Hour; - Display_Month := Mon; - Display_Day := D; - Refresh_Without_Update (Header_Window); - if Do_Update then - Update_Screen; - end if; - end if; - end if; - end Internal_Update_Header_Window; - - -- This routine is called in the keyboard input timeout handler. So it will - -- periodically update the header line of the screen. - procedure Update_Header_Window - is - begin - Internal_Update_Header_Window (True); - end Update_Header_Window; - - function Init_Header_Window (Win : Window; - Columns : Column_Count) return Integer - is - Title : constant String := "Ada 95 ncurses Binding Sample"; - Pos : Column_Position; - begin - Header_Window := Win; - if Win /= Null_Window then - if Has_Colors then - Set_Background (Win => Win, - Ch => (Ch => ' ', - Color => Header_Color, - Attr => Normal_Video)); - Set_Character_Attributes (Win => Win, - Attr => Normal_Video, - Color => Header_Color); - Erase (Win); - end if; - Leave_Cursor_After_Update (Win, True); - Pos := Columns - Column_Position (Title'Length); - Add (Win, 0, Pos / 2, Title); - -- In this phase we must not allow a physical update, because - -- ncurses isn´t properly initialized at this point. - Internal_Update_Header_Window (False); - return 0; - else - return -1; - end if; - end Init_Header_Window; - -end Sample.Header_Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.ads b/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.ads deleted file mode 100644 index aa0a0c29e9..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-header_handler.ads +++ /dev/null @@ -1,53 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Header_Handler -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - --- This package handles the painting of the header line of the screen. --- -package Sample.Header_Handler is - - procedure Init_Header_Handler; - -- Initialize the handler for the headerlines. - - procedure Update_Header_Window; - -- Update the information in the header window - -end Sample.Header_Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-helpers.adb b/contrib/ncurses-5.4/Ada95/samples/sample-helpers.adb deleted file mode 100644 index aed5a37405..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-helpers.adb +++ /dev/null @@ -1,69 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Helpers -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -with Sample.Explanation; use Sample.Explanation; - --- This package contains some conveniant helper routines used throughout --- this example. --- -package body Sample.Helpers is - - procedure Window_Title (Win : in Window; - Title : in String) - is - Height : Line_Count; - Width : Column_Count; - Pos : Column_Position := 0; - begin - Get_Size (Win, Height, Width); - if Title'Length < Width then - Pos := (Width - Title'Length) / 2; - end if; - Add (Win, 0, Pos, Title); - end Window_Title; - - procedure Not_Implemented is - begin - Explain ("NOTIMPL"); - end Not_Implemented; - -end Sample.Helpers; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-helpers.ads b/contrib/ncurses-5.4/Ada95/samples/sample-helpers.ads deleted file mode 100644 index c1c8e7996e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-helpers.ads +++ /dev/null @@ -1,54 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Helpers -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - --- This package contains some conveniant helper routines used throughout --- this example. --- -package Sample.Helpers is - - procedure Window_Title (Win : in Window; - Title : in String); - -- Put a title string into the first line of the window - - procedure Not_Implemented; - -end Sample.Helpers; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.adb b/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.adb deleted file mode 100644 index 60043581c0..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.adb +++ /dev/null @@ -1,191 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Keyboard_Handler -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Strings; use Ada.Strings; -with Ada.Strings.Fixed; use Ada.Strings.Fixed; -with Ada.Strings.Maps.Constants; use Ada.Strings.Maps.Constants; -with Ada.Characters.Latin_1; use Ada.Characters.Latin_1; -with Ada.Characters.Handling; use Ada.Characters.Handling; - -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; -with Terminal_Interface.Curses.Forms.Field_Types.Enumeration; -use Terminal_Interface.Curses.Forms.Field_Types.Enumeration; - -with Sample.Header_Handler; use Sample.Header_Handler; -with Sample.Form_Demo.Aux; use Sample.Form_Demo.Aux; -with Sample.Manifest; use Sample.Manifest; -with Sample.Form_Demo.Handler; - --- This package contains a centralized keyboard handler used throughout --- this example. The handler establishes a timeout mechanism that provides --- periodical updates of the common header lines used in this example. --- - -package body Sample.Keyboard_Handler is - - In_Command : Boolean := False; - - function Get_Key (Win : Window := Standard_Window) return Real_Key_Code - is - K : Real_Key_Code; - - function Command return Real_Key_Code; - - - function Command return Real_Key_Code - is - function My_Driver (F : Form; - C : Key_Code; - P : Panel) return Boolean; - package Fh is new Sample.Form_Demo.Handler (My_Driver); - - type Label_Array is array (Label_Number) of String (1 .. 8); - - Labels : Label_Array; - - FA : Field_Array_Access := new Field_Array' - (Make (0, 0, "Command:"), - Make (Top => 0, Left => 9, Width => Columns - 11), - Null_Field); - - K : Real_Key_Code := Key_None; - N : Natural := 0; - - function My_Driver (F : Form; - C : Key_Code; - P : Panel) return Boolean - is - Ch : Character; - begin - if C in User_Key_Code'Range and then C = QUIT then - if Driver (F, F_Validate_Field) = Form_Ok then - K := Key_None; - return True; - end if; - elsif C in Normal_Key_Code'Range then - Ch := Character'Val (C); - if (Ch = LF or else Ch = CR) then - if Driver (F, F_Validate_Field) = Form_Ok then - declare - Buffer : String (1 .. Positive (Columns - 11)); - Cmdc : String (1 .. 8); - begin - Get_Buffer (Fld => FA (2), Str => Buffer); - Trim (Buffer, Left); - if Buffer (1) /= ' ' then - Cmdc := To_Upper (Buffer (Cmdc'Range)); - for I in Labels'Range loop - if Cmdc = Labels (I) then - K := Function_Key_Code - (Function_Key_Number (I)); - exit; - end if; - end loop; - end if; - return True; - end; - end if; - end if; - end if; - return False; - end My_Driver; - - begin - In_Command := True; - for I in Label_Number'Range loop - Get_Soft_Label_Key (I, Labels (I)); - Trim (Labels (I), Left); - Translate (Labels (I), Upper_Case_Map); - if Labels (I) (1) /= ' ' then - N := N + 1; - end if; - end loop; - if N > 0 then -- some labels were really set - declare - Enum_Info : Enumeration_Info (N); - Enum_Field : Enumeration_Field; - J : Positive := Enum_Info.Names'First; - - Frm : Form := Create (FA); - - begin - for I in Label_Number'Range loop - if Labels (I) (1) /= ' ' then - Enum_Info.Names (J) := new String'(Labels (I)); - J := J + 1; - end if; - end loop; - Enum_Field := Create (Enum_Info, True); - Set_Field_Type (FA (2), Enum_Field); - Set_Background (FA (2), Normal_Video); - - Fh.Drive_Me (Frm, Lines - 3, 0); - Delete (Frm); - Update_Panels; Update_Screen; - end; - end if; - Free (FA, True); - In_Command := False; - return K; - end Command; - - begin - Set_Timeout_Mode (Win, Delayed, 30000); - loop - K := Get_Keystroke (Win); - if K = Key_None then -- a timeout occured - Update_Header_Window; - elsif K = 3 and then not In_Command then -- CTRL-C - K := Command; - exit when K /= Key_None; - else - exit; - end if; - end loop; - return K; - end Get_Key; - - procedure Init_Keyboard_Handler is - begin - null; - end Init_Keyboard_Handler; - -end Sample.Keyboard_Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.ads b/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.ads deleted file mode 100644 index ac5b1399db..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-keyboard_handler.ads +++ /dev/null @@ -1,55 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Keyboard_Handler -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - --- This package contains a centralized keyboard handler used throughout --- this example. The handler establishes a timeout mechanism that provides --- periodical updates of the common header lines used in this example. --- -package Sample.Keyboard_Handler is - - function Get_Key (Win : Window := Standard_Window) return Real_Key_Code; - -- The central routine for handling keystrokes. - - procedure Init_Keyboard_Handler; - -- Initialize the keyboard - -end Sample.Keyboard_Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-manifest.ads b/contrib/ncurses-5.4/Ada95/samples/sample-manifest.ads deleted file mode 100644 index bb76c4cba7..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-manifest.ads +++ /dev/null @@ -1,67 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Manifest -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; - -package Sample.Manifest is - - QUIT : constant User_Key_Code := User_Key_Code'First; - SELECT_ITEM : constant User_Key_Code := QUIT + 1; - - FKEY_HELP : constant Label_Number := 1; - HELP_CODE : constant Special_Key_Code := Key_F1; - FKEY_EXPLAIN : constant Label_Number := 2; - EXPLAIN_CODE : constant Special_Key_Code := Key_F2; - FKEY_QUIT : constant Label_Number := 3; - QUIT_CODE : constant Special_Key_Code := Key_F3; - - Menu_Marker : constant String := "=> "; - - Default_Colors : constant Redefinable_Color_Pair := 1; - Menu_Fore_Color : constant Redefinable_Color_Pair := 2; - Menu_Back_Color : constant Redefinable_Color_Pair := 3; - Menu_Grey_Color : constant Redefinable_Color_Pair := 4; - Form_Fore_Color : constant Redefinable_Color_Pair := 5; - Form_Back_Color : constant Redefinable_Color_Pair := 6; - Notepad_Color : constant Redefinable_Color_Pair := 7; - Help_Color : constant Redefinable_Color_Pair := 8; - Header_Color : constant Redefinable_Color_Pair := 9; - -end Sample.Manifest; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.adb b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.adb deleted file mode 100644 index 2d2e06acce..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.adb +++ /dev/null @@ -1,204 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo.Aux -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Characters.Latin_1; use Ada.Characters.Latin_1; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Helpers; use Sample.Helpers; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Menu_Demo.Aux is - - procedure Geometry (M : in Menu; - L : out Line_Count; - C : out Column_Count; - Y : out Line_Position; - X : out Column_Position; - Fy : out Line_Position; - Fx : out Column_Position); - - procedure Geometry (M : in Menu; - L : out Line_Count; -- Lines used for menu - C : out Column_Count; -- Columns used for menu - Y : out Line_Position; -- Proposed Line for menu - X : out Column_Position; -- Proposed Column for menu - Fy : out Line_Position; -- Vertical inner frame - Fx : out Column_Position) -- Horiz. inner frame - is - Spc_Desc : Column_Position; -- spaces between description and item - begin - Set_Mark (M, Menu_Marker); - - Spacing (M, Spc_Desc, Fy, Fx); - Scale (M, L, C); - - Fx := Fx + Column_Position (Fy - 1); -- looks a bit nicer - - L := L + 2 * Fy; -- count for frame at top and bottom - C := C + 2 * Fx; -- " - - -- Calculate horizontal coordinate at the screen center - X := (Columns - C) / 2; - Y := 1; -- always startin line 1 - - end Geometry; - - procedure Geometry (M : in Menu; - L : out Line_Count; -- Lines used for menu - C : out Column_Count; -- Columns used for menu - Y : out Line_Position; -- Proposed Line for menu - X : out Column_Position) -- Proposed Column for menu - is - Fy : Line_Position; - Fx : Column_Position; - begin - Geometry (M, L, C, Y, X, Fy, Fx); - end Geometry; - - function Create (M : Menu; - Title : String; - Lin : Line_Position; - Col : Column_Position) return Panel - is - W, S : Window; - L : Line_Count; - C : Column_Count; - Y, Fy : Line_Position; - X, Fx : Column_Position; - Pan : Panel; - begin - Geometry (M, L, C, Y, X, Fy, Fx); - W := New_Window (L, C, Lin, Col); - Set_Meta_Mode (W); - Set_KeyPad_Mode (W); - if Has_Colors then - Set_Background (Win => W, - Ch => (Ch => ' ', - Color => Menu_Back_Color, - Attr => Normal_Video)); - Set_Foreground (Men => M, Color => Menu_Fore_Color); - Set_Background (Men => M, Color => Menu_Back_Color); - Set_Grey (Men => M, Color => Menu_Grey_Color); - Erase (W); - end if; - S := Derived_Window (W, L - Fy, C - Fx, Fy, Fx); - Set_Meta_Mode (S); - Set_KeyPad_Mode (S); - Box (W); - Set_Window (M, W); - Set_Sub_Window (M, S); - if Title'Length > 0 then - Window_Title (W, Title); - end if; - Pan := New_Panel (W); - Post (M); - return Pan; - end Create; - - procedure Destroy (M : in Menu; - P : in out Panel) - is - W, S : Window; - begin - W := Get_Window (M); - S := Get_Sub_Window (M); - Post (M, False); - Erase (W); - Delete (P); - Set_Window (M, Null_Window); - Set_Sub_Window (M, Null_Window); - Delete (S); - Delete (W); - Update_Panels; - end Destroy; - - function Get_Request (M : Menu; P : Panel) return Key_Code - is - W : constant Window := Get_Window (M); - K : Real_Key_Code; - Ch : Character; - begin - Top (P); - loop - K := Get_Key (W); - if K in Special_Key_Code'Range then - case K is - when HELP_CODE => Explain_Context; - when EXPLAIN_CODE => Explain ("MENUKEYS"); - when Key_Home => return REQ_FIRST_ITEM; - when QUIT_CODE => return QUIT; - when Key_Cursor_Down => return REQ_DOWN_ITEM; - when Key_Cursor_Up => return REQ_UP_ITEM; - when Key_Cursor_Left => return REQ_LEFT_ITEM; - when Key_Cursor_Right => return REQ_RIGHT_ITEM; - when Key_End => return REQ_LAST_ITEM; - when Key_Backspace => return REQ_BACK_PATTERN; - when Key_Next_Page => return REQ_SCR_DPAGE; - when Key_Previous_Page => return REQ_SCR_UPAGE; - when others => return K; - end case; - elsif K in Normal_Key_Code'Range then - Ch := Character'Val (K); - case Ch is - when CAN => return QUIT; -- CTRL-X - when SO => return REQ_NEXT_ITEM; -- CTRL-N - when DLE => return REQ_PREV_ITEM; -- CTRL-P - when NAK => return REQ_SCR_ULINE; -- CTRL-U - when EOT => return REQ_SCR_DLINE; -- CTRL-D - when ACK => return REQ_SCR_DPAGE; -- CTRL-F - when STX => return REQ_SCR_UPAGE; -- CTRL-B - when EM => return REQ_CLEAR_PATTERN; -- CTRL-Y - when BS => return REQ_BACK_PATTERN; -- CTRL-H - when SOH => return REQ_NEXT_MATCH; -- CTRL-A - when ENQ => return REQ_PREV_MATCH; -- CTRL-E - when DC4 => return REQ_TOGGLE_ITEM; -- CTRL-T - - when CR | LF => return SELECT_ITEM; - when others => return K; - end case; - else - return K; - end if; - end loop; - end Get_Request; - -end Sample.Menu_Demo.Aux; - diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.ads b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.ads deleted file mode 100644 index 964e38e6e0..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-aux.ads +++ /dev/null @@ -1,71 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo.Aux -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; - -package Sample.Menu_Demo.Aux is - - procedure Geometry (M : in Menu; - L : out Line_Count; - C : out Column_Count; - Y : out Line_Position; - X : out Column_Position); - -- Calculate the geometry for a panel beeing able to be used to display - -- the menu. - - function Create (M : Menu; - Title : String; - Lin : Line_Position; - Col : Column_Position) return Panel; - -- Create a panel decorated with a frame and the title at the specified - -- position. The dimension of the panel is derived from the menus layout. - - procedure Destroy (M : in Menu; - P : in out Panel); - -- Destroy all the windowing structures associated with this menu and - -- panel. - - function Get_Request (M : Menu; P : Panel) return Key_Code; - -- Centralized request driver for all menus in this sample. This - -- gives us a common key binding for all menus. - -end Sample.Menu_Demo.Aux; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.adb b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.adb deleted file mode 100644 index 6098a2504a..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.adb +++ /dev/null @@ -1,107 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo.Handler -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Sample.Menu_Demo.Aux; -with Sample.Manifest; use Sample.Manifest; -with Terminal_Interface.Curses.Mouse; use Terminal_Interface.Curses.Mouse; - -package body Sample.Menu_Demo.Handler is - - package Aux renames Sample.Menu_Demo.Aux; - - procedure Drive_Me (M : in Menu; - Title : in String := "") - is - L : Line_Count; - C : Column_Count; - Y : Line_Position; - X : Column_Position; - begin - Aux.Geometry (M, L, C, Y, X); - Drive_Me (M, Y, X, Title); - end Drive_Me; - - procedure Drive_Me (M : in Menu; - Lin : in Line_Position; - Col : in Column_Position; - Title : in String := "") - is - Mask : Event_Mask := No_Events; - Old : Event_Mask; - Pan : Panel := Aux.Create (M, Title, Lin, Col); - V : Cursor_Visibility := Invisible; - begin - -- We are only interested in Clicks with the left button - Register_Reportable_Events (Left, All_Clicks, Mask); - Old := Start_Mouse (Mask); - Set_Cursor_Visibility (V); - loop - declare - K : Key_Code := Aux.Get_Request (M, Pan); - R : Driver_Result := Driver (M, K); - begin - case R is - when Menu_Ok => null; - when Unknown_Request => - declare - I : constant Item := Current (M); - O : Item_Option_Set; - begin - if K = Key_Mouse then - K := SELECT_ITEM; - end if; - Get_Options (I, O); - if K = SELECT_ITEM and then not O.Selectable then - Beep; - else - if My_Driver (M, K, Pan) then - exit; - end if; - end if; - end; - when others => Beep; - end case; - end; - end loop; - End_Mouse (Old); - Aux.Destroy (M, Pan); - end Drive_Me; - -end Sample.Menu_Demo.Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.ads b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.ads deleted file mode 100644 index 1a82f9fdb1..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo-handler.ads +++ /dev/null @@ -1,64 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo.Handler -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; -use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; -use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Menus; -use Terminal_Interface.Curses.Menus; - -generic - with function My_Driver (Men : Menu; - K : Key_Code; - Pan : Panel) return Boolean; -package Sample.Menu_Demo.Handler is - - procedure Drive_Me (M : in Menu; - Lin : in Line_Position; - Col : in Column_Position; - Title : in String := ""); - -- Position the menu at the given point and drive it. - - procedure Drive_Me (M : in Menu; - Title : in String := ""); - -- Center menu and drive it. - -end Sample.Menu_Demo.Handler; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.adb b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.adb deleted file mode 100644 index a0ebf6952e..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.adb +++ /dev/null @@ -1,390 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.13 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; -with Terminal_Interface.Curses.Menus.Menu_User_Data; -with Terminal_Interface.Curses.Menus.Item_User_Data; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Menu_Demo.Handler; -with Sample.Helpers; use Sample.Helpers; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Menu_Demo is - - package Spacing_Demo is - procedure Spacing_Test; - end Spacing_Demo; - - package body Spacing_Demo is - - procedure Spacing_Test - is - function My_Driver (M : Menu; - K : Key_Code; - P : Panel) return Boolean; - - procedure Set_Option_Key; - procedure Set_Select_Key; - procedure Set_Description_Key; - procedure Set_Hide_Key; - - package Mh is new Sample.Menu_Demo.Handler (My_Driver); - - I : Item_Array_Access := new Item_Array' - (New_Item ("January", "31 Days"), - New_Item ("February", "28/29 Days"), - New_Item ("March", "31 Days"), - New_Item ("April", "30 Days"), - New_Item ("May", "31 Days"), - New_Item ("June", "30 Days"), - New_Item ("July", "31 Days"), - New_Item ("August", "31 Days"), - New_Item ("September", "30 Days"), - New_Item ("October", "31 Days"), - New_Item ("November", "30 Days"), - New_Item ("December", "31 Days"), - Null_Item); - - M : Menu := New_Menu (I); - Flip_State : Boolean := True; - Hide_Long : Boolean := False; - - type Format_Code is (Four_By_1, Four_By_2, Four_By_3); - type Operations is (Flip, Reorder, Reformat, Reselect, Describe); - - type Change is array (Operations) of Boolean; - pragma Pack (Change); - No_Change : constant Change := Change'(others => False); - - Current_Format : Format_Code := Four_By_1; - To_Change : Change := No_Change; - - function My_Driver (M : Menu; - K : Key_Code; - P : Panel) return Boolean - is - begin - To_Change := No_Change; - if K in User_Key_Code'Range then - if K = QUIT then - return True; - end if; - end if; - if K in Special_Key_Code'Range then - case K is - when Key_F4 => - To_Change (Flip) := True; - return True; - when Key_F5 => - To_Change (Reformat) := True; - Current_Format := Four_By_1; - return True; - when Key_F6 => - To_Change (Reformat) := True; - Current_Format := Four_By_2; - return True; - when Key_F7 => - To_Change (Reformat) := True; - Current_Format := Four_By_3; - return True; - when Key_F8 => - To_Change (Reorder) := True; - return True; - when Key_F9 => - To_Change (Reselect) := True; - return True; - when Key_F10 => - if Current_Format /= Four_By_3 then - To_Change (Describe) := True; - return True; - else - return False; - end if; - when Key_F11 => - Hide_Long := not Hide_Long; - declare - O : Item_Option_Set; - begin - for J in I'Range loop - Get_Options (I (J), O); - O.Selectable := True; - if Hide_Long then - case J is - when 1 | 3 | 5 | 7 | 8 | 10 | 12 => - O.Selectable := False; - when others => null; - end case; - end if; - Set_Options (I (J), O); - end loop; - end; - return False; - when others => null; - end case; - end if; - return False; - end My_Driver; - - procedure Set_Option_Key - is - O : Menu_Option_Set; - begin - if Current_Format = Four_By_1 then - Set_Soft_Label_Key (8, ""); - else - Get_Options (M, O); - if O.Row_Major_Order then - Set_Soft_Label_Key (8, "O-Col"); - else - Set_Soft_Label_Key (8, "O-Row"); - end if; - end if; - Refresh_Soft_Label_Keys_Without_Update; - end Set_Option_Key; - - procedure Set_Select_Key - is - O : Menu_Option_Set; - begin - Get_Options (M, O); - if O.One_Valued then - Set_Soft_Label_Key (9, "Multi"); - else - Set_Soft_Label_Key (9, "Singl"); - end if; - Refresh_Soft_Label_Keys_Without_Update; - end Set_Select_Key; - - procedure Set_Description_Key - is - O : Menu_Option_Set; - begin - if Current_Format = Four_By_3 then - Set_Soft_Label_Key (10, ""); - else - Get_Options (M, O); - if O.Show_Descriptions then - Set_Soft_Label_Key (10, "-Desc"); - else - Set_Soft_Label_Key (10, "+Desc"); - end if; - end if; - Refresh_Soft_Label_Keys_Without_Update; - end Set_Description_Key; - - procedure Set_Hide_Key - is - begin - if Hide_Long then - Set_Soft_Label_Key (11, "Enab"); - else - Set_Soft_Label_Key (11, "Disab"); - end if; - Refresh_Soft_Label_Keys_Without_Update; - end Set_Hide_Key; - - begin - Push_Environment ("MENU01"); - Notepad ("MENU-PAD01"); - Default_Labels; - Set_Soft_Label_Key (4, "Flip"); - Set_Soft_Label_Key (5, "4x1"); - Set_Soft_Label_Key (6, "4x2"); - Set_Soft_Label_Key (7, "4x3"); - Set_Option_Key; - Set_Select_Key; - Set_Description_Key; - Set_Hide_Key; - - Set_Format (M, 4, 1); - loop - Mh.Drive_Me (M); - exit when To_Change = No_Change; - if To_Change (Flip) then - if Flip_State then - Flip_State := False; - Set_Spacing (M, 3, 2, 0); - else - Flip_State := True; - Set_Spacing (M); - end if; - elsif To_Change (Reformat) then - case Current_Format is - when Four_By_1 => Set_Format (M, 4, 1); - when Four_By_2 => Set_Format (M, 4, 2); - when Four_By_3 => - declare - O : Menu_Option_Set; - begin - Get_Options (M, O); - O.Show_Descriptions := False; - Set_Options (M, O); - Set_Format (M, 4, 3); - end; - end case; - Set_Option_Key; - Set_Description_Key; - elsif To_Change (Reorder) then - declare - O : Menu_Option_Set; - begin - Get_Options (M, O); - O.Row_Major_Order := not O.Row_Major_Order; - Set_Options (M, O); - Set_Option_Key; - end; - elsif To_Change (Reselect) then - declare - O : Menu_Option_Set; - begin - Get_Options (M, O); - O.One_Valued := not O.One_Valued; - Set_Options (M, O); - Set_Select_Key; - end; - elsif To_Change (Describe) then - declare - O : Menu_Option_Set; - begin - Get_Options (M, O); - O.Show_Descriptions := not O.Show_Descriptions; - Set_Options (M, O); - Set_Description_Key; - end; - else - null; - end if; - end loop; - Set_Spacing (M); - Flip_State := True; - - Pop_Environment; - pragma Assert (Get_Index (Items (M, 1)) = Get_Index (I (1))); - Delete (M); - Free (I, True); - end Spacing_Test; - end Spacing_Demo; - - procedure Demo - is - -- We use this datatype only to test the instantiation of - -- the Menu_User_Data generic package. No functionality - -- behind it. - type User_Data is new Integer; - type User_Data_Access is access User_Data; - - -- Those packages are only instantiated to test the usability. - -- No real functionality is shown in the demo. - package MUD is new Menu_User_Data (User_Data, User_Data_Access); - package IUD is new Item_User_Data (User_Data, User_Data_Access); - - function My_Driver (M : Menu; - K : Key_Code; - P : Panel) return Boolean; - - package Mh is new Sample.Menu_Demo.Handler (My_Driver); - - Itm : Item_Array_Access := new Item_Array' - (New_Item ("Menu Layout Options"), - New_Item ("Demo of Hook functions"), - Null_Item); - M : Menu := New_Menu (Itm); - - U1 : User_Data_Access := new User_Data'(4711); - U2 : User_Data_Access; - U3 : User_Data_Access := new User_Data'(4712); - U4 : User_Data_Access; - - function My_Driver (M : Menu; - K : Key_Code; - P : Panel) return Boolean - is - Idx : constant Positive := Get_Index (Current (M)); - begin - if K in User_Key_Code'Range then - if K = QUIT then - return True; - elsif K = SELECT_ITEM then - if Idx in Itm'Range then - Hide (P); - Update_Panels; - end if; - case Idx is - when 1 => Spacing_Demo.Spacing_Test; - when others => Not_Implemented; - end case; - if Idx in Itm'Range then - Top (P); - Show (P); - Update_Panels; - Update_Screen; - end if; - end if; - end if; - return False; - end My_Driver; - begin - Push_Environment ("MENU00"); - Notepad ("MENU-PAD00"); - Default_Labels; - Refresh_Soft_Label_Keys_Without_Update; - Set_Pad_Character (M, '|'); - - MUD.Set_User_Data (M, U1); - IUD.Set_User_Data (Itm (1), U3); - - Mh.Drive_Me (M); - - MUD.Get_User_Data (M, U2); - pragma Assert (U1 = U2 and U1.all = 4711); - - IUD.Get_User_Data (Itm (1), U4); - pragma Assert (U3 = U4 and U3.all = 4712); - - Pop_Environment; - Delete (M); - Free (Itm, True); - end Demo; - -end Sample.Menu_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.ads b/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.ads deleted file mode 100644 index b071afc827..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-menu_demo.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Menu_Demo -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Menu_Demo is - - procedure Demo; - -end Sample.Menu_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.adb b/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.adb deleted file mode 100644 index cd289b91cb..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.adb +++ /dev/null @@ -1,65 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.My_Field_Type -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; - --- This is a very simple user defined field type. It accepts only a --- defined character as input into the field. --- -package body Sample.My_Field_Type is - - -- That's simple. There are no field validity checks. - function Field_Check (Fld : Field; - Typ : My_Data) return Boolean - is - begin - return True; - end Field_Check; - - -- Check exactly against the specified character. - function Character_Check (Ch : Character; - Typ : My_Data) return Boolean - is - C : constant Character := Typ.Ch; - begin - return Ch = C; - end Character_Check; - -end Sample.My_Field_Type; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.ads b/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.ads deleted file mode 100644 index 7e74c33d13..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-my_field_type.ads +++ /dev/null @@ -1,62 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.My_Field_Type -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; -with Terminal_Interface.Curses.Forms.Field_Types.User; -use Terminal_Interface.Curses.Forms.Field_Types.User; - --- This is a very simple user defined field type. It accepts only a --- defined character as input into the field. --- -package Sample.My_Field_Type is - - type My_Data is new User_Defined_Field_Type with - record - Ch : Character; - end record; - - function Field_Check (Fld : Field; - Typ : My_Data) return Boolean; - - function Character_Check (Ch : Character; - Typ : My_Data) return Boolean; - -end Sample.My_Field_Type; - diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.adb b/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.adb deleted file mode 100644 index 43b24232be..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.adb +++ /dev/null @@ -1,180 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Text_IO_Demo -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Numerics.Generic_Elementary_Functions; -with Ada.Numerics.Complex_Types; -use Ada.Numerics.Complex_Types; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Text_IO; -use Terminal_Interface.Curses.Text_IO; -with Terminal_Interface.Curses.Text_IO.Integer_IO; -with Terminal_Interface.Curses.Text_IO.Float_IO; -with Terminal_Interface.Curses.Text_IO.Enumeration_IO; -with Terminal_Interface.Curses.Text_IO.Complex_IO; -with Terminal_Interface.Curses.Text_IO.Fixed_IO; -with Terminal_Interface.Curses.Text_IO.Decimal_IO; -with Terminal_Interface.Curses.Text_IO.Modular_IO; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Explanation; use Sample.Explanation; - -package body Sample.Text_IO_Demo is - - type Weekday is (Sunday, - Monday, - Tuesday, - Wednesday, - Thursday, - Friday, - Saturday); - - type Fix is delta 0.1 range 0.0 .. 4.0; - type Dec is delta 0.01 digits 5 range 0.0 .. 4.0; - type Md is mod 5; - - package Math is new - Ada.Numerics.Generic_Elementary_Functions (Float); - - package Int_IO is new - Terminal_Interface.Curses.Text_IO.Integer_IO (Integer); - use Int_IO; - - package Real_IO is new - Terminal_Interface.Curses.Text_IO.Float_IO (Float); - use Real_IO; - - package Enum_IO is new - Terminal_Interface.Curses.Text_IO.Enumeration_IO (Weekday); - use Enum_IO; - - package C_IO is new - Terminal_Interface.Curses.Text_IO.Complex_IO (Ada.Numerics.Complex_Types); - use C_IO; - - package F_IO is new - Terminal_Interface.Curses.Text_IO.Fixed_IO (Fix); - use F_IO; - - package D_IO is new - Terminal_Interface.Curses.Text_IO.Decimal_IO (Dec); - use D_IO; - - package M_IO is new - Terminal_Interface.Curses.Text_IO.Modular_IO (Md); - use M_IO; - - procedure Demo - is - W : Window; - P : Panel := Create (Standard_Window); - K : Real_Key_Code; - Im : Complex := (0.0, 1.0); - Fx : Fix := 3.14; - Dc : Dec := 2.72; - L : Md; - - begin - Push_Environment ("TEXTIO"); - Default_Labels; - Notepad ("TEXTIO-PAD00"); - - Set_Echo_Mode (False); - Set_Meta_Mode; - Set_KeyPad_Mode; - W := Sub_Window (Standard_Window, Lines - 2, Columns - 2, 1, 1); - Box; - Refresh_Without_Update; - Set_Meta_Mode (W); - Set_KeyPad_Mode (W); - Immediate_Update_Mode (W, True); - - Set_Window (W); - - for I in 1 .. 10 loop - Put ("Square root of "); - Put (Item => I, Width => 5); - Put (" is "); - Put (Item => Math.Sqrt (Float (I)), Exp => 0, Aft => 7); - New_Line; - end loop; - - for W in Weekday loop - Put (Item => W); Put (' '); - end loop; - New_Line; - - L := Md'First; - for I in 1 .. 2 loop - for J in Md'Range loop - Put (L); Put (' '); - L := L + 1; - end loop; - end loop; - New_Line; - - Put (Im); New_Line; - Put (Fx); New_Line; - Put (Dc); New_Line; - - loop - K := Get_Key; - if K in Special_Key_Code'Range then - case K is - when QUIT_CODE => exit; - when HELP_CODE => Explain_Context; - when EXPLAIN_CODE => Explain ("TEXTIOKEYS"); - when others => null; - end case; - end if; - end loop; - - Set_Window (Null_Window); - Erase; Refresh_Without_Update; - Delete (P); - Delete (W); - - Pop_Environment; - end Demo; - -end Sample.Text_IO_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.ads b/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.ads deleted file mode 100644 index d3f5a188ba..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample-text_io_demo.ads +++ /dev/null @@ -1,45 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample.Text_IO_Demo -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample.Text_IO_Demo is - - procedure Demo; - -end Sample.Text_IO_Demo; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample.adb b/contrib/ncurses-5.4/Ada95/samples/sample.adb deleted file mode 100644 index 962963ed1b..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample.adb +++ /dev/null @@ -1,218 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Text_IO; - -with Ada.Exceptions; use Ada.Exceptions; - -with Terminal_Interface.Curses; use Terminal_Interface.Curses; -with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels; -with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; -with Terminal_Interface.Curses.Menus.Menu_User_Data; -with Terminal_Interface.Curses.Menus.Item_User_Data; - -with Sample.Manifest; use Sample.Manifest; -with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Header_Handler; use Sample.Header_Handler; -with Sample.Explanation; use Sample.Explanation; - -with Sample.Menu_Demo.Handler; -with Sample.Curses_Demo; -with Sample.Form_Demo; -with Sample.Menu_Demo; -with Sample.Text_IO_Demo; - -with GNAT.OS_Lib; - -package body Sample is - - type User_Data is - record - Data : Integer; - end record; - type User_Access is access User_Data; - - package Ud is new - Terminal_Interface.Curses.Menus.Menu_User_Data - (User_Data, User_Access); - - package Id is new - Terminal_Interface.Curses.Menus.Item_User_Data - (User_Data, User_Access); - - procedure Whow is - procedure Main_Menu; - procedure Main_Menu - is - function My_Driver (M : Menu; - K : Key_Code; - Pan : Panel) return Boolean; - - package Mh is new Sample.Menu_Demo.Handler (My_Driver); - - I : Item_Array_Access := new Item_Array' - (New_Item ("Curses Core Demo"), - New_Item ("Menu Demo"), - New_Item ("Form Demo"), - New_Item ("Text IO Demo"), - Null_Item); - - M : Menu := New_Menu (I); - - D1, D2 : User_Access; - I1, I2 : User_Access; - - function My_Driver (M : Menu; - K : Key_Code; - Pan : Panel) return Boolean - is - Idx : constant Positive := Get_Index (Current (M)); - begin - if K in User_Key_Code'Range then - if K = QUIT then - return True; - elsif K = SELECT_ITEM then - if Idx in 1 .. 4 then - Hide (Pan); - Update_Panels; - end if; - case Idx is - when 1 => Sample.Curses_Demo.Demo; - when 2 => Sample.Menu_Demo.Demo; - when 3 => Sample.Form_Demo.Demo; - when 4 => Sample.Text_IO_Demo.Demo; - when others => null; - end case; - if Idx in 1 .. 4 then - Top (Pan); - Show (Pan); - Update_Panels; - Update_Screen; - end if; - end if; - end if; - return False; - end My_Driver; - - begin - - if (1 + Item_Count (M)) /= I'Length then - raise Constraint_Error; - end if; - - D1 := new User_Data'(Data => 4711); - Ud.Set_User_Data (M, D1); - - I1 := new User_Data'(Data => 1174); - Id.Set_User_Data (I (1), I1); - - Set_Spacing (Men => M, Row => 2); - - Default_Labels; - Notepad ("MAINPAD"); - - Mh.Drive_Me (M, " Demo "); - - Ud.Get_User_Data (M, D2); - pragma Assert (D1 = D2); - pragma Assert (D1.Data = D2.Data); - - Id.Get_User_Data (I (1), I2); - pragma Assert (I1 = I2); - pragma Assert (I1.Data = I2.Data); - - Delete (M); - Free (I, True); - end Main_Menu; - - begin - Initialize (PC_Style_With_Index); - Init_Header_Handler; - Init_Screen; - - if Has_Colors then - Start_Color; - - Init_Pair (Pair => Default_Colors, Fore => Black, Back => White); - Init_Pair (Pair => Menu_Back_Color, Fore => Black, Back => Cyan); - Init_Pair (Pair => Menu_Fore_Color, Fore => Red, Back => Cyan); - Init_Pair (Pair => Menu_Grey_Color, Fore => White, Back => Cyan); - Init_Pair (Pair => Notepad_Color, Fore => Black, Back => Yellow); - Init_Pair (Pair => Help_Color, Fore => Blue, Back => Cyan); - Init_Pair (Pair => Form_Back_Color, Fore => Black, Back => Cyan); - Init_Pair (Pair => Form_Fore_Color, Fore => Red, Back => Cyan); - Init_Pair (Pair => Header_Color, Fore => Black, Back => Green); - - Set_Background (Ch => (Color => Default_Colors, - Attr => Normal_Video, - Ch => ' ')); - Set_Character_Attributes (Attr => Normal_Video, - Color => Default_Colors); - Erase; - - Set_Soft_Label_Key_Attributes (Color => Header_Color); - -- This propagates the attributes to the label window - Clear_Soft_Label_Keys; Restore_Soft_Label_Keys; - end if; - - Init_Keyboard_Handler; - - Set_Echo_Mode (False); - Set_Raw_Mode; - Set_Meta_Mode; - Set_KeyPad_Mode; - - -- Initialize the Function Key Environment - -- We have some fixed key throughout this sample - Main_Menu; - End_Windows; - - exception - when Event : others => - Terminal_Interface.Curses.End_Windows; - Text_IO.Put ("Exception: "); - Text_IO.Put (Exception_Name (Event)); - Text_IO.New_Line; - GNAT.OS_Lib.OS_Exit (1); - - end Whow; - -end Sample; diff --git a/contrib/ncurses-5.4/Ada95/samples/sample.ads b/contrib/ncurses-5.4/Ada95/samples/sample.ads deleted file mode 100644 index 9d0647dad7..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/sample.ads +++ /dev/null @@ -1,43 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Sample -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Sample is - procedure Whow; -end Sample; diff --git a/contrib/ncurses-5.4/Ada95/samples/status.adb b/contrib/ncurses-5.4/Ada95/samples/status.adb deleted file mode 100644 index e6581317f4..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/status.adb +++ /dev/null @@ -1,57 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Status -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Laurent Pautet --- Modified by: Juergen Pfeifer, 1997 --- Version Control --- $Revision: 1.7 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- This package has been contributed by Laurent Pautet -- --- -- -package body Status is - - protected body Process is - procedure Stop is - begin - Done := True; - end Stop; - function Continue return Boolean is - begin - return not Done; - end Continue; - end Process; - -end Status; diff --git a/contrib/ncurses-5.4/Ada95/samples/status.ads b/contrib/ncurses-5.4/Ada95/samples/status.ads deleted file mode 100644 index e9e3ee8b35..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/status.ads +++ /dev/null @@ -1,60 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Status -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Laurent Pautet --- Modified by: Juergen Pfeifer, 1997 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- This package has been contributed by Laurent Pautet -- --- -- -with Ada.Interrupts.Names; - -package Status is - - pragma Warnings (Off); -- the next pragma exists since 3.11p - pragma Unreserve_All_Interrupts; - pragma Warnings (On); - - protected Process is - procedure Stop; - function Continue return Boolean; - pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT); - private - Done : Boolean := False; - end Process; - -end Status; diff --git a/contrib/ncurses-5.4/Ada95/samples/tour.adb b/contrib/ncurses-5.4/Ada95/samples/tour.adb deleted file mode 100644 index 1cc91c15d7..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/tour.adb +++ /dev/null @@ -1,46 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- tour -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Sample; use Sample; - -procedure Tour is -begin - Whow; -end Tour; diff --git a/contrib/ncurses-5.4/Ada95/samples/tour.ads b/contrib/ncurses-5.4/Ada95/samples/tour.ads deleted file mode 100644 index 8888169160..0000000000 --- a/contrib/ncurses-5.4/Ada95/samples/tour.ads +++ /dev/null @@ -1,41 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding Samples -- --- -- --- Tour -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -procedure Tour; diff --git a/contrib/ncurses-5.4/Ada95/src/Makefile.in b/contrib/ncurses-5.4/Ada95/src/Makefile.in deleted file mode 100644 index 01823144f9..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/Makefile.in +++ /dev/null @@ -1,389 +0,0 @@ -############################################################################## -# Copyright (c) 1998 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Juergen Pfeifer, 1996 -# -# Version Control -# $Revision: 1.28 $ -# -.SUFFIXES: - -SHELL = /bin/sh -THIS = Makefile - -MODEL = ../../@DFT_OBJ_SUBDIR@ -DESTDIR = @DESTDIR@ -srcdir = @srcdir@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ -ADA_INCLUDE = @ADA_INCLUDE@ - -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ - -AR = @AR@ -AR_OPTS = @AR_OPTS@ -AWK = @AWK@ -LN_S = @LN_S@ - -CC = @CC@ -CFLAGS = @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_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@ - -CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@) - -LINK = $(CC) -LDFLAGS = @LDFLAGS@ @LD_MODEL@ @LIBS@ - -RANLIB = @RANLIB@ -################################################################################ -ADA = @cf_ada_compiler@ -ADAPREP = gnatprep -ADAFLAGS = @ADAFLAGS@ -I. -I$(srcdir) - -ADAMAKE = @cf_ada_make@ -ADAMAKEFLAGS = - -CARGS = -cargs $(ADAFLAGS) -LARGS = - -ALIB = @cf_ada_package@ -ABASE = $(ALIB)-curses - -LIBALIS=$(ALIB).ali \ - $(ABASE)-aux.ali \ - $(ABASE).ali \ - $(ABASE)-terminfo.ali \ - $(ABASE)-termcap.ali \ - $(ABASE)-putwin.ali \ - $(ABASE)-trace.ali \ - $(ABASE)-mouse.ali \ - $(ABASE)-panels.ali \ - $(ABASE)-menus.ali \ - $(ABASE)-forms.ali \ - $(ABASE)-forms-field_types.ali \ - $(ABASE)-forms-field_types-alpha.ali \ - $(ABASE)-forms-field_types-alphanumeric.ali \ - $(ABASE)-forms-field_types-intfield.ali \ - $(ABASE)-forms-field_types-numeric.ali \ - $(ABASE)-forms-field_types-regexp.ali \ - $(ABASE)-forms-field_types-enumeration.ali \ - $(ABASE)-forms-field_types-ipv4_address.ali \ - $(ABASE)-forms-field_types-user.ali \ - $(ABASE)-forms-field_types-user-choice.ali \ - $(ABASE)-text_io.ali \ - $(ABASE)-text_io-aux.ali - -# Ada Library files for generic packages. Since gnat 3.10 they are -# also compiled -GENALIS=$(ABASE)-menus-menu_user_data.ali \ - $(ABASE)-menus-item_user_data.ali \ - $(ABASE)-forms-form_user_data.ali \ - $(ABASE)-forms-field_user_data.ali \ - $(ABASE)-forms-field_types-enumeration-ada.ali \ - $(ABASE)-panels-user_data.ali \ - $(ABASE)-text_io-integer_io.ali \ - $(ABASE)-text_io-float_io.ali \ - $(ABASE)-text_io-fixed_io.ali \ - $(ABASE)-text_io-decimal_io.ali \ - $(ABASE)-text_io-enumeration_io.ali \ - $(ABASE)-text_io-modular_io.ali \ - $(ABASE)-text_io-complex_io.ali - -LIBOBJS=$(ALIB).o \ - $(ABASE)-aux.o \ - $(ABASE).o \ - $(ABASE)-terminfo.o \ - $(ABASE)-termcap.o \ - $(ABASE)-putwin.o \ - $(ABASE)-trace.o \ - $(ABASE)-mouse.o \ - $(ABASE)-panels.o \ - $(ABASE)-menus.o \ - $(ABASE)-forms.o \ - $(ABASE)-forms-field_types.o \ - $(ABASE)-forms-field_types-alpha.o \ - $(ABASE)-forms-field_types-alphanumeric.o \ - $(ABASE)-forms-field_types-intfield.o \ - $(ABASE)-forms-field_types-numeric.o \ - $(ABASE)-forms-field_types-regexp.o \ - $(ABASE)-forms-field_types-enumeration.o \ - $(ABASE)-forms-field_types-ipv4_address.o \ - $(ABASE)-forms-field_types-user.o \ - $(ABASE)-forms-field_types-user-choice.o \ - $(ABASE)-text_io.o \ - $(ABASE)-text_io-aux.o - -# Ada object files for generic packages. Since gnat 3.10 they are -# also compiled -GENOBJS=$(ABASE)-menus-menu_user_data.o \ - $(ABASE)-menus-item_user_data.o \ - $(ABASE)-forms-form_user_data.o \ - $(ABASE)-forms-field_user_data.o \ - $(ABASE)-forms-field_types-enumeration-ada.o \ - $(ABASE)-panels-user_data.o \ - $(ABASE)-text_io-integer_io.o \ - $(ABASE)-text_io-float_io.o \ - $(ABASE)-text_io-fixed_io.o \ - $(ABASE)-text_io-decimal_io.o \ - $(ABASE)-text_io-enumeration_io.o \ - $(ABASE)-text_io-modular_io.o \ - $(ABASE)-text_io-complex_io.o - - -all :: libAdaCurses.a - @echo done - -libAdaCurses.a :: dotouch $(LIBOBJS) @cf_generic_objects@ - $(AR) $(AR_OPTS) $@ $(LIBOBJS) @cf_generic_objects@ - -dotouch : - @sh -c 'for f in $(LIBALIS) $(GENALIS); do test -f $$f || touch $$f; done' - -sources : - @ - -libs \ -install \ -install.libs \ -uninstall \ -uninstall.libs :: - @ - -generics: $(GENALIS) - @ - -mostlyclean :: - rm -f *.o *.ali b_t*.* *.s $(PROGS) a.out core b_*_test.c *.xr[bs] *.a - -clean :: mostlyclean - rm -f $(LIBALIS) $(GENALIS) $(LIBOBJS) $(GENOBJS) $(ABASE)-trace.adb - -distclean :: clean - rm -f Makefile - -realclean :: distclean - -BASEDEPS=$(ABASE).ads $(ABASE)-aux.ads $(srcdir)/$(ABASE).adb - -$(ALIB).o: $(srcdir)/$(ALIB).ads - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ALIB).ads - - -$(ABASE)-aux.o: $(srcdir)/$(ABASE)-aux.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-aux.adb - - -$(ABASE).o: $(srcdir)/$(ABASE).adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE).adb - - -$(ABASE)-terminfo.o: \ - $(srcdir)/$(ABASE)-terminfo.ads \ - $(srcdir)/$(ABASE)-terminfo.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-terminfo.adb - - -$(ABASE)-termcap.o: \ - $(srcdir)/$(ABASE)-termcap.ads \ - $(srcdir)/$(ABASE)-termcap.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-termcap.adb - - -$(ABASE)-putwin.o: \ - $(srcdir)/$(ABASE)-putwin.ads \ - $(srcdir)/$(ABASE)-putwin.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-putwin.adb - - -$(ABASE)-trace.adb : $(srcdir)/$(ABASE)-trace.adb_p - rm -f $@ - $(ADAPREP) -DADA_TRACE=@ADA_TRACE@ $(srcdir)/$(ABASE)-trace.adb_p $@ - -$(ABASE)-trace.o: \ - $(ABASE)-trace.ads \ - $(ABASE)-trace.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(ABASE)-trace.adb - - -$(ABASE)-mouse.o: \ - $(ABASE)-mouse.ads \ - $(srcdir)/$(ABASE)-mouse.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-mouse.adb - - -$(ABASE)-panels.o: \ - $(ABASE)-panels.ads \ - $(srcdir)/$(ABASE)-panels.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-panels.adb - - -$(ABASE)-menus.o: \ - $(ABASE)-menus.ads \ - $(srcdir)/$(ABASE)-menus.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-menus.adb - - -$(ABASE)-forms.o: \ - $(ABASE)-forms.ads \ - $(srcdir)/$(ABASE)-forms.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms.adb - -$(ABASE)-forms-field_types.o: \ - $(ABASE)-forms-field_types.ads \ - $(srcdir)/$(ABASE)-forms-field_types.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types.adb - -$(ABASE)-forms-field_types-alpha.o: \ - $(srcdir)/$(ABASE)-forms-field_types-alpha.ads \ - $(srcdir)/$(ABASE)-forms-field_types-alpha.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-alpha.adb - -$(ABASE)-forms-field_types-alphanumeric.o: \ - $(srcdir)/$(ABASE)-forms-field_types-alphanumeric.ads \ - $(srcdir)/$(ABASE)-forms-field_types-alphanumeric.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-alphanumeric.adb - -$(ABASE)-forms-field_types-intfield.o: \ - $(srcdir)/$(ABASE)-forms-field_types-intfield.ads \ - $(srcdir)/$(ABASE)-forms-field_types-intfield.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-intfield.adb - -$(ABASE)-forms-field_types-numeric.o: \ - $(srcdir)/$(ABASE)-forms-field_types-numeric.ads \ - $(srcdir)/$(ABASE)-forms-field_types-numeric.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-numeric.adb - -$(ABASE)-forms-field_types-regexp.o: \ - $(srcdir)/$(ABASE)-forms-field_types-regexp.ads \ - $(srcdir)/$(ABASE)-forms-field_types-regexp.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-regexp.adb - -$(ABASE)-forms-field_types-enumeration.o: \ - $(srcdir)/$(ABASE)-forms-field_types-enumeration.ads \ - $(srcdir)/$(ABASE)-forms-field_types-enumeration.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-enumeration.adb - -$(ABASE)-forms-field_types-ipv4_address.o: \ - $(srcdir)/$(ABASE)-forms-field_types-ipv4_address.ads \ - $(srcdir)/$(ABASE)-forms-field_types-ipv4_address.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-ipv4_address.adb - -$(ABASE)-forms-field_types-user.o: \ - $(srcdir)/$(ABASE)-forms-field_types-user.ads \ - $(srcdir)/$(ABASE)-forms-field_types-user.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-user.adb - -$(ABASE)-forms-field_types-user-choice.o: \ - $(srcdir)/$(ABASE)-forms-field_types-user-choice.ads \ - $(srcdir)/$(ABASE)-forms-field_types-user-choice.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-user-choice.adb - -$(ABASE)-text_io.o: \ - $(srcdir)/$(ABASE)-text_io.ads \ - $(srcdir)/$(ABASE)-text_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io.adb - -$(ABASE)-text_io-aux.o: \ - $(srcdir)/$(ABASE)-text_io-aux.ads \ - $(srcdir)/$(ABASE)-text_io-aux.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-aux.adb - -$(ABASE)-menus-menu_user_data.o: \ - $(ABASE)-menus-menu_user_data.ads \ - $(srcdir)/$(ABASE)-menus-menu_user_data.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-menus-menu_user_data.adb - -$(ABASE)-menus-item_user_data.o: \ - $(ABASE)-menus-item_user_data.ads \ - $(srcdir)/$(ABASE)-menus-item_user_data.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-menus-item_user_data.adb - -$(ABASE)-forms-form_user_data.o: \ - $(ABASE)-forms-form_user_data.ads \ - $(srcdir)/$(ABASE)-forms-form_user_data.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-form_user_data.adb - -$(ABASE)-forms-field_user_data.o: \ - $(ABASE)-forms-field_user_data.ads \ - $(srcdir)/$(ABASE)-forms-field_user_data.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_user_data.adb - -$(ABASE)-forms-field_types-enumeration-ada.o: \ - $(srcdir)/$(ABASE)-forms-field_types-enumeration-ada.ads \ - $(srcdir)/$(ABASE)-forms-field_types-enumeration-ada.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-forms-field_types-enumeration-ada.adb - -$(ABASE)-panels-user_data.o: \ - $(ABASE)-panels-user_data.ads \ - $(srcdir)/$(ABASE)-panels-user_data.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-panels-user_data.adb - -$(ABASE)-text_io-integer_io.o: \ - $(srcdir)/$(ABASE)-text_io-integer_io.ads \ - $(srcdir)/$(ABASE)-text_io-integer_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-integer_io.adb - -$(ABASE)-text_io-float_io.o: \ - $(srcdir)/$(ABASE)-text_io-float_io.ads \ - $(srcdir)/$(ABASE)-text_io-float_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-float_io.adb - -$(ABASE)-text_io-fixed_io.o: \ - $(srcdir)/$(ABASE)-text_io-fixed_io.ads \ - $(srcdir)/$(ABASE)-text_io-fixed_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-fixed_io.adb - -$(ABASE)-text_io-decimal_io.o: \ - $(srcdir)/$(ABASE)-text_io-decimal_io.ads \ - $(srcdir)/$(ABASE)-text_io-decimal_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-decimal_io.adb - -$(ABASE)-text_io-enumeration_io.o: \ - $(srcdir)/$(ABASE)-text_io-enumeration_io.ads \ - $(srcdir)/$(ABASE)-text_io-enumeration_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-enumeration_io.adb - -$(ABASE)-text_io-modular_io.o: \ - $(srcdir)/$(ABASE)-text_io-modular_io.ads \ - $(srcdir)/$(ABASE)-text_io-modular_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-modular_io.adb - -$(ABASE)-text_io-complex_io.o: \ - $(srcdir)/$(ABASE)-text_io-complex_io.ads \ - $(srcdir)/$(ABASE)-text_io-complex_io.adb $(BASEDEPS) - $(ADA) $(ADAFLAGS) -c -o $@ $(srcdir)/$(ABASE)-text_io-complex_io.adb diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-aux.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-aux.adb deleted file mode 100644 index 812e8cc143..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-aux.adb +++ /dev/null @@ -1,116 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Aux -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package body Terminal_Interface.Curses.Aux is - -- - -- Some helpers - procedure Fill_String (Cp : in chars_ptr; - Str : out String) - is - -- Fill the string with the characters referenced by the - -- chars_ptr. - -- - Len : Natural; - begin - if Cp /= Null_Ptr then - Len := Natural (Strlen (Cp)); - if Str'Length < Len then - raise Constraint_Error; - end if; - declare - S : String (1 .. Len); - begin - S := Value (Cp); - Str (Str'First .. (Str'First + Len - 1)) := S (S'Range); - end; - else - Len := 0; - end if; - - if Len < Str'Length then - Str ((Str'First + Len) .. Str'Last) := (others => ' '); - end if; - - end Fill_String; - - function Fill_String (Cp : chars_ptr) return String - is - Len : Natural; - begin - if Cp /= Null_Ptr then - Len := Natural (Strlen (Cp)); - if Len = 0 then - return ""; - else - declare - S : String (1 .. Len); - begin - Fill_String (Cp, S); - return S; - end; - end if; - else - return ""; - end if; - end Fill_String; - - procedure Eti_Exception (Code : Eti_Error) - is - begin - case Code is - when E_Ok => null; - when E_System_Error => raise Eti_System_Error; - when E_Bad_Argument => raise Eti_Bad_Argument; - when E_Posted => raise Eti_Posted; - when E_Connected => raise Eti_Connected; - when E_Bad_State => raise Eti_Bad_State; - when E_No_Room => raise Eti_No_Room; - when E_Not_Posted => raise Eti_Not_Posted; - when E_Unknown_Command => raise Eti_Unknown_Command; - when E_No_Match => raise Eti_No_Match; - when E_Not_Selectable => raise Eti_Not_Selectable; - when E_Not_Connected => raise Eti_Not_Connected; - when E_Request_Denied => raise Eti_Request_Denied; - when E_Invalid_Field => raise Eti_Invalid_Field; - when E_Current => raise Eti_Current; - end case; - end Eti_Exception; - -end Terminal_Interface.Curses.Aux; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.adb deleted file mode 100644 index 5d1ef200e7..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.adb +++ /dev/null @@ -1,68 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Alpha -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.8 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.Alpha is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Alpha_Field) - is - C_Alpha_Field_Type : C_Field_Type; - pragma Import (C, C_Alpha_Field_Type, "TYPE_ALPHA"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_Alpha_Field_Type; - Arg1 : C_Int) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - Res := Set_Fld_Type (Arg1 => C_Int (Typ.Minimum_Field_Width)); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.Alpha; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.ads deleted file mode 100644 index 6f0b79d76e..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alpha.ads +++ /dev/null @@ -1,53 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Alpha -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.Alpha is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types.Alpha); - - type Alpha_Field is new Field_Type - with record - Minimum_Field_Width : Natural := 0; - end record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Alpha_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.Alpha; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.adb deleted file mode 100644 index f10321b4a7..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.adb +++ /dev/null @@ -1,68 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.8 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in AlphaNumeric_Field) - is - C_AlphaNumeric_Field_Type : C_Field_Type; - pragma Import (C, C_AlphaNumeric_Field_Type, "TYPE_ALNUM"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_AlphaNumeric_Field_Type; - Arg1 : C_Int) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - Res := Set_Fld_Type (Arg1 => C_Int (Typ.Minimum_Field_Width)); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.ads deleted file mode 100644 index 1f21950802..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-alphanumeric.ads +++ /dev/null @@ -1,54 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric is - pragma Preelaborate - (Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric); - - type AlphaNumeric_Field is new Field_Type - with record - Minimum_Field_Width : Natural := 0; - end record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in AlphaNumeric_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.AlphaNumeric; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.adb deleted file mode 100644 index 84f276af83..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.adb +++ /dev/null @@ -1,80 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.7 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Characters.Handling; use Ada.Characters.Handling; - -package body Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada is - - function Create (Set : Type_Set := Mixed_Case; - Case_Sensitive : Boolean := False; - Must_Be_Unique : Boolean := False) - return Enumeration_Field - is - I : Enumeration_Info (T'Pos (T'Last) - T'Pos (T'First) + 1); - J : Positive := 1; - begin - I.Case_Sensitive := Case_Sensitive; - I.Match_Must_Be_Unique := Must_Be_Unique; - - for E in T'Range loop - I.Names (J) := new String'(T'Image (T (E))); - -- The Image attribute defaults to upper case, so we have to handle - -- only the other ones... - if Set /= Upper_Case then - I.Names (J).all := To_Lower (I.Names (J).all); - if Set = Mixed_Case then - I.Names (J)(I.Names (J).all'First) := - To_Upper (I.Names (J)(I.Names (J).all'First)); - end if; - end if; - J := J + 1; - end loop; - - return Create (I, True); - end Create; - - function Value (Fld : Field; - Buf : Buffer_Number := Buffer_Number'First) return T - is - begin - return T'Value (Get_Buffer (Fld, Buf)); - end Value; - -end Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.ads deleted file mode 100644 index 48fad09c2f..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration-ada.ads +++ /dev/null @@ -1,59 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type T is (<>); - -package Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada is - pragma Preelaborate - (Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada); - - function Create (Set : Type_Set := Mixed_Case; - Case_Sensitive : Boolean := False; - Must_Be_Unique : Boolean := False) - return Enumeration_Field; - - function Value (Fld : Field; - Buf : Buffer_Number := Buffer_Number'First) return T; - -- Translate the content of the fields buffer - indicated by the - -- buffer number - into an enumeration value. If the buffer is empty - -- or the content is invalid, a Constraint_Error is raises. - -end Terminal_Interface.Curses.Forms.Field_Types.Enumeration.Ada; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.adb deleted file mode 100644 index 8be20f23e8..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.adb +++ /dev/null @@ -1,119 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Enumeration -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.7 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Deallocation; -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.Enumeration is - - function Create (Info : Enumeration_Info; - Auto_Release_Names : Boolean := False) - return Enumeration_Field - is - procedure Release_String is - new Ada.Unchecked_Deallocation (String, - String_Access); - E : Enumeration_Field; - L : constant size_t := 1 + size_t (Info.C); - S : String_Access; - begin - E.Case_Sensitive := Info.Case_Sensitive; - E.Match_Must_Be_Unique := Info.Match_Must_Be_Unique; - E.Arr := new chars_ptr_array (size_t (1) .. L); - for I in 1 .. Positive (L - 1) loop - if Info.Names (I) = null then - raise Form_Exception; - end if; - E.Arr (size_t (I)) := New_String (Info.Names (I).all); - if Auto_Release_Names then - S := Info.Names (I); - Release_String (S); - end if; - end loop; - E.Arr (L) := Null_Ptr; - return E; - end Create; - - procedure Release (Enum : in out Enumeration_Field) - is - I : size_t := 0; - P : chars_ptr; - begin - loop - P := Enum.Arr (I); - exit when P = Null_Ptr; - Free (P); - Enum.Arr (I) := Null_Ptr; - I := I + 1; - end loop; - Enum.Arr := null; - end Release; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Enumeration_Field) - is - C_Enum_Type : C_Field_Type; - pragma Import (C, C_Enum_Type, "TYPE_ENUM"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_Enum_Type; - Arg1 : chars_ptr_array; - Arg2 : C_Int; - Arg3 : C_Int) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - if Typ.Arr = null then - raise Form_Exception; - end if; - Res := Set_Fld_Type (Arg1 => Typ.Arr.all, - Arg2 => C_Int (Boolean'Pos (Typ.Case_Sensitive)), - Arg3 => C_Int (Boolean'Pos - (Typ.Match_Must_Be_Unique))); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ, C_Choice_Router); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.Enumeration; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.ads deleted file mode 100644 index 5a7e411ff9..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-enumeration.ads +++ /dev/null @@ -1,98 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Enumeration -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C.Strings; - -package Terminal_Interface.Curses.Forms.Field_Types.Enumeration is - pragma Preelaborate - (Terminal_Interface.Curses.Forms.Field_Types.Enumeration); - - type String_Access is access String; - - -- Type_Set is used by the child package Ada - type Type_Set is (Lower_Case, Upper_Case, Mixed_Case); - - type Enum_Array is array (Positive range <>) - of String_Access; - - type Enumeration_Info (C : Positive) is - record - Names : Enum_Array (1 .. C); - Case_Sensitive : Boolean := False; - Match_Must_Be_Unique : Boolean := False; - end record; - - type Enumeration_Field is new Field_Type with private; - - function Create (Info : Enumeration_Info; - Auto_Release_Names : Boolean := False) - return Enumeration_Field; - -- Make an fieldtype from the info. Enumerations are special, because - -- they normally don't copy the enum values into a private store, so - -- we have to care for the lifetime of the info we provide. - -- The Auto_Release_Names flag may be used to automatically releases - -- the strings in the Names array of the Enumeration_Info. - - function Make_Enumeration_Type (Info : Enumeration_Info; - Auto_Release_Names : Boolean := False) - return Enumeration_Field renames Create; - - procedure Release (Enum : in out Enumeration_Field); - -- But we may want to release the field to release the memory allocated - -- by it internally. After that the Enumeration field is no longer usable. - - -- The next type defintions are all ncurses extensions. They are typically - -- not available in other curses implementations. - - procedure Set_Field_Type (Fld : in Field; - Typ : in Enumeration_Field); - pragma Inline (Set_Field_Type); - -private - type CPA_Access is access Interfaces.C.Strings.chars_ptr_array; - - type Enumeration_Field is new Field_Type with - record - Case_Sensitive : Boolean := False; - Match_Must_Be_Unique : Boolean := False; - Arr : CPA_Access := null; - end record; - -end Terminal_Interface.Curses.Forms.Field_Types.Enumeration; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.adb deleted file mode 100644 index 1e279b4c24..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.adb +++ /dev/null @@ -1,72 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.IntField -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.8 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.IntField is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Integer_Field) - is - C_Integer_Field_Type : C_Field_Type; - pragma Import (C, C_Integer_Field_Type, "TYPE_INTEGER"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_Integer_Field_Type; - Arg1 : C_Int; - Arg2 : C_Long_Int; - Arg3 : C_Long_Int) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - Res := Set_Fld_Type (Arg1 => C_Int (Typ.Precision), - Arg2 => C_Long_Int (Typ.Lower_Limit), - Arg3 => C_Long_Int (Typ.Upper_Limit)); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.IntField; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.ads deleted file mode 100644 index b285ca2556..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-intfield.ads +++ /dev/null @@ -1,55 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.IntField -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.IntField is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types.IntField); - - type Integer_Field is new Field_Type with - record - Precision : Natural; - Lower_Limit : Integer; - Upper_Limit : Integer; - end record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Integer_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.IntField; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.adb deleted file mode 100644 index a86b5fe12c..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.adb +++ /dev/null @@ -1,68 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.8 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Internet_V4_Address_Field) - is - C_IPV4_Field_Type : C_Field_Type; - pragma Import (C, C_IPV4_Field_Type, "TYPE_IPV4"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_IPV4_Field_Type) - return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - Res := Set_Fld_Type; - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.ads deleted file mode 100644 index 6d0aef0610..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-ipv4_address.ads +++ /dev/null @@ -1,51 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address is - pragma Preelaborate - (Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address); - - type Internet_V4_Address_Field is new Field_Type with null record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Internet_V4_Address_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.IPV4_Address; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.adb deleted file mode 100644 index e580df3503..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.adb +++ /dev/null @@ -1,74 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Numeric -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.9 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.Numeric is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Numeric_Field) - is - type Double is new Interfaces.C.double; - - C_Numeric_Field_Type : C_Field_Type; - pragma Import (C, C_Numeric_Field_Type, "TYPE_NUMERIC"); - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_Numeric_Field_Type; - Arg1 : C_Int; - Arg2 : Double; - Arg3 : Double) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - begin - Res := Set_Fld_Type (Arg1 => C_Int (Typ.Precision), - Arg2 => Double (Typ.Lower_Limit), - Arg3 => Double (Typ.Upper_Limit)); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.Numeric; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.ads deleted file mode 100644 index f211bc87bc..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-numeric.ads +++ /dev/null @@ -1,55 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.Numeric -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.Numeric is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types.Numeric); - - type Numeric_Field is new Field_Type with - record - Precision : Natural; - Lower_Limit : Float; - Upper_Limit : Float; - end record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Numeric_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.Numeric; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.adb deleted file mode 100644 index cbd9e2f368..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.adb +++ /dev/null @@ -1,71 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.RegExp -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.8 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; use Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.RegExp is - - procedure Set_Field_Type (Fld : in Field; - Typ : in Regular_Expression_Field) - is - type Char_Ptr is access all Interfaces.C.char; - - C_Regexp_Field_Type : C_Field_Type; - pragma Import (C, C_Regexp_Field_Type, "TYPE_REGEXP"); - - function Set_Ftyp (F : Field := Fld; - Cft : C_Field_Type := C_Regexp_Field_Type; - Arg1 : Char_Ptr) return C_Int; - pragma Import (C, Set_Ftyp, "set_field_type"); - - Txt : char_array (0 .. Typ.Regular_Expression.all'Length); - Len : size_t; - Res : Eti_Error; - begin - To_C (Typ.Regular_Expression.all, Txt, Len); - Res := Set_Ftyp (Arg1 => Txt (Txt'First)'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Wrap_Builtin (Fld, Typ); - end Set_Field_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.RegExp; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.ads deleted file mode 100644 index 1e451ab85c..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-regexp.ads +++ /dev/null @@ -1,55 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.RegExp -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface.Curses.Forms.Field_Types.RegExp is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types.RegExp); - - type String_Access is access String; - - type Regular_Expression_Field is new Field_Type with - record - Regular_Expression : String_Access; - end record; - - procedure Set_Field_Type (Fld : in Field; - Typ : in Regular_Expression_Field); - pragma Inline (Set_Field_Type); - -end Terminal_Interface.Curses.Forms.Field_Types.RegExp; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.adb deleted file mode 100644 index d9ed454b0a..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.adb +++ /dev/null @@ -1,110 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.User.Choice -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Conversion; -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.User.Choice is - - use type Interfaces.C.int; - - function To_Argument_Access is new Ada.Unchecked_Conversion - (System.Address, Argument_Access); - - function Generic_Next (Fld : Field; - Usr : System.Address) return C_Int - is - Result : Boolean; - Udf : User_Defined_Field_Type_With_Choice_Access := - User_Defined_Field_Type_With_Choice_Access - (To_Argument_Access (Usr).Typ); - begin - Result := Next (Fld, Udf.all); - return C_Int (Boolean'Pos (Result)); - end Generic_Next; - - function Generic_Prev (Fld : Field; - Usr : System.Address) return C_Int - is - Result : Boolean; - Udf : User_Defined_Field_Type_With_Choice_Access := - User_Defined_Field_Type_With_Choice_Access - (To_Argument_Access (Usr).Typ); - begin - Result := Previous (Fld, Udf.all); - return C_Int (Boolean'Pos (Result)); - end Generic_Prev; - - -- ----------------------------------------------------------------------- - -- - function C_Generic_Choice return C_Field_Type - is - Res : Eti_Error; - T : C_Field_Type; - begin - if M_Generic_Choice = Null_Field_Type then - T := New_Fieldtype (Generic_Field_Check'Access, - Generic_Char_Check'Access); - if T = Null_Field_Type then - raise Form_Exception; - else - Res := Set_Fieldtype_Arg (T, - Make_Arg'Access, - Copy_Arg'Access, - Free_Arg'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - - Res := Set_Fieldtype_Choice (T, - Generic_Next'Access, - Generic_Prev'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - M_Generic_Choice := T; - end if; - pragma Assert (M_Generic_Choice /= Null_Field_Type); - return M_Generic_Choice; - end C_Generic_Choice; - -end Terminal_Interface.Curses.Forms.Field_Types.User.Choice; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.ads deleted file mode 100644 index d970c3a76f..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user-choice.ads +++ /dev/null @@ -1,96 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.User.Choice -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; - -package Terminal_Interface.Curses.Forms.Field_Types.User.Choice is - pragma Preelaborate - (Terminal_Interface.Curses.Forms.Field_Types.User.Choice); - - use type Interfaces.C.int; - subtype C_Int is Interfaces.C.int; - - type User_Defined_Field_Type_With_Choice is abstract new - User_Defined_Field_Type with null record; - -- This is the root of the mechanism we use to create field types in - -- Ada95 that allow the prev/next mechanism. You should your own type - -- derive from this one and implement the Field_Check, Character_Check - -- Next and Previous functions for your own type. - - type User_Defined_Field_Type_With_Choice_Access is access all - User_Defined_Field_Type_With_Choice'Class; - - function Next - (Fld : Field; - Typ : User_Defined_Field_Type_With_Choice) return Boolean - is abstract; - -- If True is returned, the function successfully generated a next - -- value into the fields buffer. - - function Previous - (Fld : Field; - Typ : User_Defined_Field_Type_With_Choice) return Boolean - is abstract; - -- If True is returned, the function successfully generated a previous - -- value into the fields buffer. - - -- +---------------------------------------------------------------------- - -- | Private Part. - -- | -private - use type Interfaces.C.int; - - function C_Generic_Choice return C_Field_Type; - - function Generic_Next (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Generic_Next); - -- This is the generic next Choice_Function for the low-level fieldtype - -- representing all the User_Defined_Field_Type derivates. It routes - -- the call to the Next implementation for the type. - - function Generic_Prev (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Generic_Prev); - -- This is the generic prev Choice_Function for the low-level fieldtype - -- representing all the User_Defined_Field_Type derivates. It routes - -- the call to the Previous implementation for the type. - -end Terminal_Interface.Curses.Forms.Field_Types.User.Choice; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.adb deleted file mode 100644 index 6e348b93dd..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.adb +++ /dev/null @@ -1,132 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.User -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Conversion; -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Field_Types.User is - - use type Interfaces.C.int; - - procedure Set_Field_Type (Fld : in Field; - Typ : in User_Defined_Field_Type) - is - function Allocate_Arg (T : User_Defined_Field_Type'Class) - return Argument_Access; - - function Set_Fld_Type (F : Field := Fld; - Cft : C_Field_Type := C_Generic_Type; - Arg1 : Argument_Access) - return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - Res : Eti_Error; - - function Allocate_Arg (T : User_Defined_Field_Type'Class) - return Argument_Access - is - Ptr : Field_Type_Access := new User_Defined_Field_Type'Class'(T); - begin - return new Argument'(Usr => System.Null_Address, - Typ => Ptr, - Cft => Null_Field_Type); - end Allocate_Arg; - - begin - Res := Set_Fld_Type (Arg1 => Allocate_Arg (Typ)); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Field_Type; - - function To_Argument_Access is new Ada.Unchecked_Conversion - (System.Address, Argument_Access); - - function Generic_Field_Check (Fld : Field; - Usr : System.Address) return C_Int - is - Result : Boolean; - Udf : User_Defined_Field_Type_Access := - User_Defined_Field_Type_Access (To_Argument_Access (Usr).Typ); - begin - Result := Field_Check (Fld, Udf.all); - return C_Int (Boolean'Pos (Result)); - end Generic_Field_Check; - - function Generic_Char_Check (Ch : C_Int; - Usr : System.Address) return C_Int - is - Result : Boolean; - Udf : User_Defined_Field_Type_Access := - User_Defined_Field_Type_Access (To_Argument_Access (Usr).Typ); - begin - Result := Character_Check (Character'Val (Ch), Udf.all); - return C_Int (Boolean'Pos (Result)); - end Generic_Char_Check; - - -- ----------------------------------------------------------------------- - -- - function C_Generic_Type return C_Field_Type - is - Res : Eti_Error; - T : C_Field_Type; - begin - if M_Generic_Type = Null_Field_Type then - T := New_Fieldtype (Generic_Field_Check'Access, - Generic_Char_Check'Access); - if T = Null_Field_Type then - raise Form_Exception; - else - Res := Set_Fieldtype_Arg (T, - Make_Arg'Access, - Copy_Arg'Access, - Free_Arg'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - M_Generic_Type := T; - end if; - pragma Assert (M_Generic_Type /= Null_Field_Type); - return M_Generic_Type; - end C_Generic_Type; - -end Terminal_Interface.Curses.Forms.Field_Types.User; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.ads deleted file mode 100644 index 0d09fcf2a1..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types-user.ads +++ /dev/null @@ -1,97 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types.User -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; - -package Terminal_Interface.Curses.Forms.Field_Types.User is - pragma Preelaborate (Terminal_Interface.Curses.Forms.Field_Types.User); - use type Interfaces.C.int; - subtype C_Int is Interfaces.C.int; - - type User_Defined_Field_Type is abstract new Field_Type with null record; - -- This is the root of the mechanism we use to create field types in - -- Ada95. You should your own type derive from this one and implement - -- the Field_Check and Character_Check functions for your own type. - - type User_Defined_Field_Type_Access is access all - User_Defined_Field_Type'Class; - - function Field_Check - (Fld : Field; - Typ : User_Defined_Field_Type) return Boolean - is abstract; - -- If True is returned, the field is considered valid, otherwise it is - -- invalid. - - function Character_Check - (Ch : Character; - Typ : User_Defined_Field_Type) return Boolean - is abstract; - -- If True is returned, the character is considered as valid for the - -- field, otherwise as invalid. - - procedure Set_Field_Type (Fld : in Field; - Typ : in User_Defined_Field_Type); - -- This should work for all types derived from User_Defined_Field_Type. - -- No need to reimplement it for your derived type. - - -- +---------------------------------------------------------------------- - -- | Private Part. - -- | Used by the Choice child package. -private - use type Interfaces.C.int; - - function C_Generic_Type return C_Field_Type; - - function Generic_Field_Check (Fld : Field; - Usr : System.Address) return C_Int; - pragma Convention (C, Generic_Field_Check); - -- This is the generic Field_Check_Function for the low-level fieldtype - -- representing all the User_Defined_Field_Type derivates. It routes - -- the call to the Field_Check implementation for the type. - - function Generic_Char_Check (Ch : C_Int; - Usr : System.Address) return C_Int; - pragma Convention (C, Generic_Char_Check); - -- This is the generic Char_Check_Function for the low-level fieldtype - -- representing all the User_Defined_Field_Type derivates. It routes - -- the call to the Character_Check implementation for the type. - -end Terminal_Interface.Curses.Forms.Field_Types.User; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types.adb deleted file mode 100644 index e003058b0e..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_types.adb +++ /dev/null @@ -1,296 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_Types -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Ada.Unchecked_Deallocation; -with Ada.Unchecked_Conversion; --- | --- |===================================================================== --- | man page form_fieldtype.3x --- |===================================================================== --- | -package body Terminal_Interface.Curses.Forms.Field_Types is - - use type Interfaces.C.int; - use type System.Address; - - function To_Argument_Access is new Ada.Unchecked_Conversion - (System.Address, Argument_Access); - - function Get_Fieldtype (F : Field) return C_Field_Type; - pragma Import (C, Get_Fieldtype, "field_type"); - - function Get_Arg (F : Field) return System.Address; - pragma Import (C, Get_Arg, "field_arg"); - -- | - -- |===================================================================== - -- | man page form_field_validation.3x - -- |===================================================================== - -- | - -- | - -- | - function Get_Type (Fld : in Field) return Field_Type_Access - is - Low_Level : constant C_Field_Type := Get_Fieldtype (Fld); - Arg : Argument_Access; - begin - if Low_Level = Null_Field_Type then - return null; - else - if Low_Level = M_Builtin_Router or else - Low_Level = M_Generic_Type or else - Low_Level = M_Choice_Router or else - Low_Level = M_Generic_Choice then - Arg := To_Argument_Access (Get_Arg (Fld)); - if Arg = null then - raise Form_Exception; - else - return Arg.Typ; - end if; - else - raise Form_Exception; - end if; - end if; - end Get_Type; - - function Make_Arg (Args : System.Address) return System.Address - is - -- Actually args is a double indirected pointer to the arguments - -- of a C variable argument list. In theory it is now quite - -- complicated to write portable routine that reads the arguments, - -- because one has to know the growth direction of the stack and - -- the sizes of the individual arguments. - -- Fortunately we are only interested in the first argument (#0), - -- we know its size and for the first arg we don't care about - -- into which stack direction we have to proceed. We simply - -- resolve the double indirection and thats it. - type V is access all System.Address; - function To_Access is new Ada.Unchecked_Conversion (System.Address, - V); - begin - return To_Access (To_Access (Args).all).all; - end Make_Arg; - - function Copy_Arg (Usr : System.Address) return System.Address - is - begin - return Usr; - end Copy_Arg; - - procedure Free_Arg (Usr : in System.Address) - is - procedure Free_Type is new Ada.Unchecked_Deallocation - (Field_Type'Class, Field_Type_Access); - procedure Freeargs is new Ada.Unchecked_Deallocation - (Argument, Argument_Access); - - To_Be_Free : Argument_Access := To_Argument_Access (Usr); - Low_Level : C_Field_Type; - begin - if To_Be_Free /= null then - if To_Be_Free.Usr /= System.Null_Address then - Low_Level := To_Be_Free.Cft; - if Low_Level.Freearg /= null then - Low_Level.Freearg (To_Be_Free.Usr); - end if; - end if; - if To_Be_Free.Typ /= null then - Free_Type (To_Be_Free.Typ); - end if; - Freeargs (To_Be_Free); - end if; - end Free_Arg; - - - procedure Wrap_Builtin (Fld : Field; - Typ : Field_Type'Class; - Cft : C_Field_Type := C_Builtin_Router) - is - Usr_Arg : System.Address := Get_Arg (Fld); - Low_Level : constant C_Field_Type := Get_Fieldtype (Fld); - Arg : Argument_Access; - Res : Eti_Error; - function Set_Fld_Type (F : Field := Fld; - Cf : C_Field_Type := Cft; - Arg1 : Argument_Access) return C_Int; - pragma Import (C, Set_Fld_Type, "set_field_type"); - - begin - pragma Assert (Low_Level /= Null_Field_Type); - if Cft /= C_Builtin_Router and then Cft /= C_Choice_Router then - raise Form_Exception; - else - Arg := new Argument'(Usr => System.Null_Address, - Typ => new Field_Type'Class'(Typ), - Cft => Get_Fieldtype (Fld)); - if Usr_Arg /= System.Null_Address then - if Low_Level.Copyarg /= null then - Arg.Usr := Low_Level.Copyarg (Usr_Arg); - else - Arg.Usr := Usr_Arg; - end if; - end if; - - Res := Set_Fld_Type (Arg1 => Arg); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - end Wrap_Builtin; - - function Field_Check_Router (Fld : Field; - Usr : System.Address) return C_Int - is - Arg : constant Argument_Access := To_Argument_Access (Usr); - begin - pragma Assert (Arg /= null and then Arg.Cft /= Null_Field_Type - and then Arg.Typ /= null); - if Arg.Cft.Fcheck /= null then - return Arg.Cft.Fcheck (Fld, Arg.Usr); - else - return 1; - end if; - end Field_Check_Router; - - function Char_Check_Router (Ch : C_Int; - Usr : System.Address) return C_Int - is - Arg : constant Argument_Access := To_Argument_Access (Usr); - begin - pragma Assert (Arg /= null and then Arg.Cft /= Null_Field_Type - and then Arg.Typ /= null); - if Arg.Cft.Ccheck /= null then - return Arg.Cft.Ccheck (Ch, Arg.Usr); - else - return 1; - end if; - end Char_Check_Router; - - function Next_Router (Fld : Field; - Usr : System.Address) return C_Int - is - Arg : constant Argument_Access := To_Argument_Access (Usr); - begin - pragma Assert (Arg /= null and then Arg.Cft /= Null_Field_Type - and then Arg.Typ /= null); - if Arg.Cft.Next /= null then - return Arg.Cft.Next (Fld, Arg.Usr); - else - return 1; - end if; - end Next_Router; - - function Prev_Router (Fld : Field; - Usr : System.Address) return C_Int - is - Arg : constant Argument_Access := To_Argument_Access (Usr); - begin - pragma Assert (Arg /= null and then Arg.Cft /= Null_Field_Type - and then Arg.Typ /= null); - if Arg.Cft.Prev /= null then - return Arg.Cft.Prev (Fld, Arg.Usr); - else - return 1; - end if; - end Prev_Router; - - -- ----------------------------------------------------------------------- - -- - function C_Builtin_Router return C_Field_Type - is - Res : Eti_Error; - T : C_Field_Type; - begin - if M_Builtin_Router = Null_Field_Type then - T := New_Fieldtype (Field_Check_Router'Access, - Char_Check_Router'Access); - if T = Null_Field_Type then - raise Form_Exception; - else - Res := Set_Fieldtype_Arg (T, - Make_Arg'Access, - Copy_Arg'Access, - Free_Arg'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - M_Builtin_Router := T; - end if; - pragma Assert (M_Builtin_Router /= Null_Field_Type); - return M_Builtin_Router; - end C_Builtin_Router; - - -- ----------------------------------------------------------------------- - -- - function C_Choice_Router return C_Field_Type - is - Res : Eti_Error; - T : C_Field_Type; - begin - if M_Choice_Router = Null_Field_Type then - T := New_Fieldtype (Field_Check_Router'Access, - Char_Check_Router'Access); - if T = Null_Field_Type then - raise Form_Exception; - else - Res := Set_Fieldtype_Arg (T, - Make_Arg'Access, - Copy_Arg'Access, - Free_Arg'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - - Res := Set_Fieldtype_Choice (T, - Next_Router'Access, - Prev_Router'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - M_Choice_Router := T; - end if; - pragma Assert (M_Choice_Router /= Null_Field_Type); - return M_Choice_Router; - end C_Choice_Router; - -end Terminal_Interface.Curses.Forms.Field_Types; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_user_data.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_user_data.adb deleted file mode 100644 index 817ebe5927..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-field_user_data.adb +++ /dev/null @@ -1,85 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Field_User_Data -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - --- | --- |===================================================================== --- | man page form_field_userptr.3x --- |===================================================================== --- | -package body Terminal_Interface.Curses.Forms.Field_User_Data is - -- | - -- | - -- | - use type Interfaces.C.int; - - procedure Set_User_Data (Fld : in Field; - Data : in User_Access) - is - function Set_Field_Userptr (Fld : Field; - Usr : User_Access) return C_Int; - pragma Import (C, Set_Field_Userptr, "set_field_userptr"); - - Res : constant Eti_Error := Set_Field_Userptr (Fld, Data); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_User_Data; - -- | - -- | - -- | - function Get_User_Data (Fld : in Field) return User_Access - is - function Field_Userptr (Fld : Field) return User_Access; - pragma Import (C, Field_Userptr, "field_userptr"); - begin - return Field_Userptr (Fld); - end Get_User_Data; - - procedure Get_User_Data (Fld : in Field; - Data : out User_Access) - is - begin - Data := Get_User_Data (Fld); - end Get_User_Data; - -end Terminal_Interface.Curses.Forms.Field_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-form_user_data.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-form_user_data.adb deleted file mode 100644 index 50c6708fcf..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms-form_user_data.adb +++ /dev/null @@ -1,86 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms.Form_User_Data -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- --- | --- |===================================================================== --- | man page form__userptr.3x --- |===================================================================== --- | -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms.Form_User_Data is - - use type Interfaces.C.int; - - -- | - -- | - -- | - procedure Set_User_Data (Frm : in Form; - Data : in User_Access) - is - function Set_Form_Userptr (Frm : Form; - Data : User_Access) return C_Int; - pragma Import (C, Set_Form_Userptr, "set_form_userptr"); - - Res : constant Eti_Error := Set_Form_Userptr (Frm, Data); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_User_Data; - -- | - -- | - -- | - function Get_User_Data (Frm : in Form) return User_Access - is - function Form_Userptr (Frm : Form) return User_Access; - pragma Import (C, Form_Userptr, "form_userptr"); - begin - return Form_Userptr (Frm); - end Get_User_Data; - - procedure Get_User_Data (Frm : in Form; - Data : out User_Access) - is - begin - Data := Get_User_Data (Frm); - end Get_User_Data; - -end Terminal_Interface.Curses.Forms.Form_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms.adb deleted file mode 100644 index b50b031ba5..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-forms.adb +++ /dev/null @@ -1,1160 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Forms -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.22 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Deallocation; -with Ada.Unchecked_Conversion; - -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Interfaces.C.Pointers; - -with Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Forms is - - use Terminal_Interface.Curses.Aux; - - type C_Field_Array is array (Natural range <>) of aliased Field; - package F_Array is new - Interfaces.C.Pointers (Natural, Field, C_Field_Array, Null_Field); - ------------------------------------------------------------------------------- - -- | - -- | - -- | - -- subtype chars_ptr is Interfaces.C.Strings.chars_ptr; - - function FOS_2_CInt is new - Ada.Unchecked_Conversion (Field_Option_Set, - C_Int); - - function CInt_2_FOS is new - Ada.Unchecked_Conversion (C_Int, - Field_Option_Set); - - function FrmOS_2_CInt is new - Ada.Unchecked_Conversion (Form_Option_Set, - C_Int); - - function CInt_2_FrmOS is new - Ada.Unchecked_Conversion (C_Int, - Form_Option_Set); - - procedure Request_Name (Key : in Form_Request_Code; - Name : out String) - is - function Form_Request_Name (Key : C_Int) return chars_ptr; - pragma Import (C, Form_Request_Name, "form_request_name"); - begin - Fill_String (Form_Request_Name (C_Int (Key)), Name); - end Request_Name; - - function Request_Name (Key : Form_Request_Code) return String - is - function Form_Request_Name (Key : C_Int) return chars_ptr; - pragma Import (C, Form_Request_Name, "form_request_name"); - begin - return Fill_String (Form_Request_Name (C_Int (Key))); - end Request_Name; ------------------------------------------------------------------------------- - -- | - -- | - -- | - -- | - -- |===================================================================== - -- | man page form_field_new.3x - -- |===================================================================== - -- | - -- | - -- | - function Create (Height : Line_Count; - Width : Column_Count; - Top : Line_Position; - Left : Column_Position; - Off_Screen : Natural := 0; - More_Buffers : Buffer_Number := Buffer_Number'First) - return Field - is - function Newfield (H, W, T, L, O, M : C_Int) return Field; - pragma Import (C, Newfield, "new_field"); - Fld : constant Field := Newfield (C_Int (Height), C_Int (Width), - C_Int (Top), C_Int (Left), - C_Int (Off_Screen), - C_Int (More_Buffers)); - begin - if Fld = Null_Field then - raise Form_Exception; - end if; - return Fld; - end Create; --- | --- | --- | - procedure Delete (Fld : in out Field) - is - function Free_Field (Fld : Field) return C_Int; - pragma Import (C, Free_Field, "free_field"); - - Res : Eti_Error; - begin - Res := Free_Field (Fld); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Fld := Null_Field; - end Delete; - -- | - -- | - -- | - function Duplicate (Fld : Field; - Top : Line_Position; - Left : Column_Position) return Field - is - function Dup_Field (Fld : Field; - Top : C_Int; - Left : C_Int) return Field; - pragma Import (C, Dup_Field, "dup_field"); - - F : constant Field := Dup_Field (Fld, - C_Int (Top), - C_Int (Left)); - begin - if F = Null_Field then - raise Form_Exception; - end if; - return F; - end Duplicate; - -- | - -- | - -- | - function Link (Fld : Field; - Top : Line_Position; - Left : Column_Position) return Field - is - function Lnk_Field (Fld : Field; - Top : C_Int; - Left : C_Int) return Field; - pragma Import (C, Lnk_Field, "link_field"); - - F : constant Field := Lnk_Field (Fld, - C_Int (Top), - C_Int (Left)); - begin - if F = Null_Field then - raise Form_Exception; - end if; - return F; - end Link; - -- | - -- |===================================================================== - -- | man page form_field_just.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Justification (Fld : in Field; - Just : in Field_Justification := None) - is - function Set_Field_Just (Fld : Field; - Just : C_Int) return C_Int; - pragma Import (C, Set_Field_Just, "set_field_just"); - - Res : constant Eti_Error := - Set_Field_Just (Fld, - C_Int (Field_Justification'Pos (Just))); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Justification; - -- | - -- | - -- | - function Get_Justification (Fld : Field) return Field_Justification - is - function Field_Just (Fld : Field) return C_Int; - pragma Import (C, Field_Just, "field_just"); - begin - return Field_Justification'Val (Field_Just (Fld)); - end Get_Justification; - -- | - -- |===================================================================== - -- | man page form_field_buffer.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First; - Str : in String) - is - type Char_Ptr is access all Interfaces.C.char; - function Set_Fld_Buffer (Fld : Field; - Bufnum : C_Int; - S : Char_Ptr) - return C_Int; - pragma Import (C, Set_Fld_Buffer, "set_field_buffer"); - - Txt : char_array (0 .. Str'Length); - Len : size_t; - Res : Eti_Error; - begin - To_C (Str, Txt, Len); - Res := Set_Fld_Buffer (Fld, C_Int (Buffer), Txt (Txt'First)'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Buffer; - -- | - -- | - -- | - procedure Get_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First; - Str : out String) - is - function Field_Buffer (Fld : Field; - B : C_Int) return chars_ptr; - pragma Import (C, Field_Buffer, "field_buffer"); - begin - Fill_String (Field_Buffer (Fld, C_Int (Buffer)), Str); - end Get_Buffer; - - function Get_Buffer - (Fld : in Field; - Buffer : in Buffer_Number := Buffer_Number'First) return String - is - function Field_Buffer (Fld : Field; - B : C_Int) return chars_ptr; - pragma Import (C, Field_Buffer, "field_buffer"); - begin - return Fill_String (Field_Buffer (Fld, C_Int (Buffer))); - end Get_Buffer; - -- | - -- | - -- | - procedure Set_Status (Fld : in Field; - Status : in Boolean := True) - is - function Set_Fld_Status (Fld : Field; - St : C_Int) return C_Int; - pragma Import (C, Set_Fld_Status, "set_field_status"); - - Res : constant Eti_Error := Set_Fld_Status (Fld, Boolean'Pos (Status)); - begin - if Res /= E_Ok then - raise Form_Exception; - end if; - end Set_Status; - -- | - -- | - -- | - function Changed (Fld : Field) return Boolean - is - function Field_Status (Fld : Field) return C_Int; - pragma Import (C, Field_Status, "field_status"); - - Res : constant C_Int := Field_Status (Fld); - begin - if Res = Curses_False then - return False; - else - return True; - end if; - end Changed; - -- | - -- | - -- | - procedure Set_Maximum_Size (Fld : in Field; - Max : in Natural := 0) - is - function Set_Field_Max (Fld : Field; - M : C_Int) return C_Int; - pragma Import (C, Set_Field_Max, "set_max_field"); - - Res : constant Eti_Error := Set_Field_Max (Fld, C_Int (Max)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Maximum_Size; - -- | - -- |===================================================================== - -- | man page form_field_opts.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Options (Fld : in Field; - Options : in Field_Option_Set) - is - function Set_Field_Opts (Fld : Field; - Opt : C_Int) return C_Int; - pragma Import (C, Set_Field_Opts, "set_field_opts"); - - Opt : C_Int := FOS_2_CInt (Options); - Res : Eti_Error; - begin - Res := Set_Field_Opts (Fld, Opt); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Options; - -- | - -- | - -- | - procedure Switch_Options (Fld : in Field; - Options : in Field_Option_Set; - On : Boolean := True) - is - function Field_Opts_On (Fld : Field; - Opt : C_Int) return C_Int; - pragma Import (C, Field_Opts_On, "field_opts_on"); - function Field_Opts_Off (Fld : Field; - Opt : C_Int) return C_Int; - pragma Import (C, Field_Opts_Off, "field_opts_off"); - - Err : Eti_Error; - Opt : C_Int := FOS_2_CInt (Options); - begin - if On then - Err := Field_Opts_On (Fld, Opt); - else - Err := Field_Opts_Off (Fld, Opt); - end if; - if Err /= E_Ok then - Eti_Exception (Err); - end if; - end Switch_Options; - -- | - -- | - -- | - procedure Get_Options (Fld : in Field; - Options : out Field_Option_Set) - is - function Field_Opts (Fld : Field) return C_Int; - pragma Import (C, Field_Opts, "field_opts"); - - Res : C_Int := Field_Opts (Fld); - begin - Options := CInt_2_FOS (Res); - end Get_Options; - -- | - -- | - -- | - function Get_Options (Fld : Field := Null_Field) - return Field_Option_Set - is - Fos : Field_Option_Set; - begin - Get_Options (Fld, Fos); - return Fos; - end Get_Options; - -- | - -- |===================================================================== - -- | man page form_field_attributes.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Foreground - (Fld : in Field; - Fore : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Set_Field_Fore (Fld : Field; - Attr : C_Chtype) return C_Int; - pragma Import (C, Set_Field_Fore, "set_field_fore"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Color => Color, - Attr => Fore); - Res : constant Eti_Error := - Set_Field_Fore (Fld, AttrChar_To_Chtype (Ch)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Foreground; - -- | - -- | - -- | - procedure Foreground (Fld : in Field; - Fore : out Character_Attribute_Set) - is - function Field_Fore (Fld : Field) return C_Chtype; - pragma Import (C, Field_Fore, "field_fore"); - begin - Fore := Chtype_To_AttrChar (Field_Fore (Fld)).Attr; - end Foreground; - - procedure Foreground (Fld : in Field; - Fore : out Character_Attribute_Set; - Color : out Color_Pair) - is - function Field_Fore (Fld : Field) return C_Chtype; - pragma Import (C, Field_Fore, "field_fore"); - begin - Fore := Chtype_To_AttrChar (Field_Fore (Fld)).Attr; - Color := Chtype_To_AttrChar (Field_Fore (Fld)).Color; - end Foreground; - -- | - -- | - -- | - procedure Set_Background - (Fld : in Field; - Back : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Set_Field_Back (Fld : Field; - Attr : C_Chtype) return C_Int; - pragma Import (C, Set_Field_Back, "set_field_back"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Color => Color, - Attr => Back); - Res : constant Eti_Error := - Set_Field_Back (Fld, AttrChar_To_Chtype (Ch)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Background; - -- | - -- | - -- | - procedure Background (Fld : in Field; - Back : out Character_Attribute_Set) - is - function Field_Back (Fld : Field) return C_Chtype; - pragma Import (C, Field_Back, "field_back"); - begin - Back := Chtype_To_AttrChar (Field_Back (Fld)).Attr; - end Background; - - procedure Background (Fld : in Field; - Back : out Character_Attribute_Set; - Color : out Color_Pair) - is - function Field_Back (Fld : Field) return C_Chtype; - pragma Import (C, Field_Back, "field_back"); - begin - Back := Chtype_To_AttrChar (Field_Back (Fld)).Attr; - Color := Chtype_To_AttrChar (Field_Back (Fld)).Color; - end Background; - -- | - -- | - -- | - procedure Set_Pad_Character (Fld : in Field; - Pad : in Character := Space) - is - function Set_Field_Pad (Fld : Field; - Ch : C_Int) return C_Int; - pragma Import (C, Set_Field_Pad, "set_field_pad"); - - Res : constant Eti_Error := Set_Field_Pad (Fld, - C_Int (Character'Pos (Pad))); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Pad_Character; - -- | - -- | - -- | - procedure Pad_Character (Fld : in Field; - Pad : out Character) - is - function Field_Pad (Fld : Field) return C_Int; - pragma Import (C, Field_Pad, "field_pad"); - begin - Pad := Character'Val (Field_Pad (Fld)); - end Pad_Character; - -- | - -- |===================================================================== - -- | man page form_field_info.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Info (Fld : in Field; - Lines : out Line_Count; - Columns : out Column_Count; - First_Row : out Line_Position; - First_Column : out Column_Position; - Off_Screen : out Natural; - Additional_Buffers : out Buffer_Number) - is - type C_Int_Access is access all C_Int; - function Fld_Info (Fld : Field; - L, C, Fr, Fc, Os, Ab : C_Int_Access) - return C_Int; - pragma Import (C, Fld_Info, "field_info"); - - L, C, Fr, Fc, Os, Ab : aliased C_Int; - Res : constant Eti_Error := Fld_Info (Fld, - L'Access, C'Access, - Fr'Access, Fc'Access, - Os'Access, Ab'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - else - Lines := Line_Count (L); - Columns := Column_Count (C); - First_Row := Line_Position (Fr); - First_Column := Column_Position (Fc); - Off_Screen := Natural (Os); - Additional_Buffers := Buffer_Number (Ab); - end if; - end Info; --- | --- | --- | - procedure Dynamic_Info (Fld : in Field; - Lines : out Line_Count; - Columns : out Column_Count; - Max : out Natural) - is - type C_Int_Access is access all C_Int; - function Dyn_Info (Fld : Field; L, C, M : C_Int_Access) return C_Int; - pragma Import (C, Dyn_Info, "dynamic_field_info"); - - L, C, M : aliased C_Int; - Res : constant Eti_Error := Dyn_Info (Fld, - L'Access, C'Access, - M'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - else - Lines := Line_Count (L); - Columns := Column_Count (C); - Max := Natural (M); - end if; - end Dynamic_Info; - -- | - -- |===================================================================== - -- | man page form_win.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Window (Frm : in Form; - Win : in Window) - is - function Set_Form_Win (Frm : Form; - Win : Window) return C_Int; - pragma Import (C, Set_Form_Win, "set_form_win"); - - Res : constant Eti_Error := Set_Form_Win (Frm, Win); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Window; - -- | - -- | - -- | - function Get_Window (Frm : Form) return Window - is - function Form_Win (Frm : Form) return Window; - pragma Import (C, Form_Win, "form_win"); - - W : constant Window := Form_Win (Frm); - begin - return W; - end Get_Window; - -- | - -- | - -- | - procedure Set_Sub_Window (Frm : in Form; - Win : in Window) - is - function Set_Form_Sub (Frm : Form; - Win : Window) return C_Int; - pragma Import (C, Set_Form_Sub, "set_form_sub"); - - Res : constant Eti_Error := Set_Form_Sub (Frm, Win); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Sub_Window; - -- | - -- | - -- | - function Get_Sub_Window (Frm : Form) return Window - is - function Form_Sub (Frm : Form) return Window; - pragma Import (C, Form_Sub, "form_sub"); - - W : constant Window := Form_Sub (Frm); - begin - return W; - end Get_Sub_Window; - -- | - -- | - -- | - procedure Scale (Frm : in Form; - Lines : out Line_Count; - Columns : out Column_Count) - is - type C_Int_Access is access all C_Int; - function M_Scale (Frm : Form; Yp, Xp : C_Int_Access) return C_Int; - pragma Import (C, M_Scale, "scale_form"); - - X, Y : aliased C_Int; - Res : constant Eti_Error := M_Scale (Frm, Y'Access, X'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Lines := Line_Count (Y); - Columns := Column_Count (X); - end Scale; - -- | - -- |===================================================================== - -- | man page menu_hook.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Field_Init_Hook (Frm : in Form; - Proc : in Form_Hook_Function) - is - function Set_Field_Init (Frm : Form; - Proc : Form_Hook_Function) return C_Int; - pragma Import (C, Set_Field_Init, "set_field_init"); - - Res : constant Eti_Error := Set_Field_Init (Frm, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Field_Init_Hook; - -- | - -- | - -- | - procedure Set_Field_Term_Hook (Frm : in Form; - Proc : in Form_Hook_Function) - is - function Set_Field_Term (Frm : Form; - Proc : Form_Hook_Function) return C_Int; - pragma Import (C, Set_Field_Term, "set_field_term"); - - Res : constant Eti_Error := Set_Field_Term (Frm, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Field_Term_Hook; - -- | - -- | - -- | - procedure Set_Form_Init_Hook (Frm : in Form; - Proc : in Form_Hook_Function) - is - function Set_Form_Init (Frm : Form; - Proc : Form_Hook_Function) return C_Int; - pragma Import (C, Set_Form_Init, "set_form_init"); - - Res : constant Eti_Error := Set_Form_Init (Frm, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Form_Init_Hook; - -- | - -- | - -- | - procedure Set_Form_Term_Hook (Frm : in Form; - Proc : in Form_Hook_Function) - is - function Set_Form_Term (Frm : Form; - Proc : Form_Hook_Function) return C_Int; - pragma Import (C, Set_Form_Term, "set_form_term"); - - Res : constant Eti_Error := Set_Form_Term (Frm, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Form_Term_Hook; - -- | - -- |===================================================================== - -- | man page form_fields.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Redefine (Frm : in Form; - Flds : in Field_Array_Access) - is - function Set_Frm_Fields (Frm : Form; - Items : System.Address) return C_Int; - pragma Import (C, Set_Frm_Fields, "set_form_fields"); - - Res : Eti_Error; - begin - pragma Assert (Flds (Flds'Last) = Null_Field); - if Flds (Flds'Last) /= Null_Field then - raise Form_Exception; - else - Res := Set_Frm_Fields (Frm, Flds (Flds'First)'Address); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - end Redefine; - -- | - -- | - -- | - function Fields (Frm : Form; - Index : Positive) return Field - is - use F_Array; - - function C_Fields (Frm : Form) return Pointer; - pragma Import (C, C_Fields, "form_fields"); - - P : Pointer := C_Fields (Frm); - begin - if P = null or else Index not in 1 .. Field_Count (Frm) then - raise Form_Exception; - else - P := P + ptrdiff_t (C_Int (Index) - 1); - return P.all; - end if; - end Fields; - -- | - -- | - -- | - function Field_Count (Frm : Form) return Natural - is - function Count (Frm : Form) return C_Int; - pragma Import (C, Count, "field_count"); - begin - return Natural (Count (Frm)); - end Field_Count; - -- | - -- | - -- | - procedure Move (Fld : in Field; - Line : in Line_Position; - Column : in Column_Position) - is - function Move (Fld : Field; L, C : C_Int) return C_Int; - pragma Import (C, Move, "move_field"); - - Res : constant Eti_Error := Move (Fld, C_Int (Line), C_Int (Column)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Move; - -- | - -- |===================================================================== - -- | man page form_new.3x - -- |===================================================================== - -- | - -- | - -- | - function Create (Fields : Field_Array_Access) return Form - is - function NewForm (Fields : System.Address) return Form; - pragma Import (C, NewForm, "new_form"); - - M : Form; - begin - pragma Assert (Fields (Fields'Last) = Null_Field); - if Fields (Fields'Last) /= Null_Field then - raise Form_Exception; - else - M := NewForm (Fields (Fields'First)'Address); - if M = Null_Form then - raise Form_Exception; - end if; - return M; - end if; - end Create; - -- | - -- | - -- | - procedure Delete (Frm : in out Form) - is - function Free (Frm : Form) return C_Int; - pragma Import (C, Free, "free_form"); - - Res : constant Eti_Error := Free (Frm); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Frm := Null_Form; - end Delete; - -- | - -- |===================================================================== - -- | man page form_opts.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Options (Frm : in Form; - Options : in Form_Option_Set) - is - function Set_Form_Opts (Frm : Form; - Opt : C_Int) return C_Int; - pragma Import (C, Set_Form_Opts, "set_form_opts"); - - Opt : C_Int := FrmOS_2_CInt (Options); - Res : Eti_Error; - begin - Res := Set_Form_Opts (Frm, Opt); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Options; - -- | - -- | - -- | - procedure Switch_Options (Frm : in Form; - Options : in Form_Option_Set; - On : Boolean := True) - is - function Form_Opts_On (Frm : Form; - Opt : C_Int) return C_Int; - pragma Import (C, Form_Opts_On, "form_opts_on"); - function Form_Opts_Off (Frm : Form; - Opt : C_Int) return C_Int; - pragma Import (C, Form_Opts_Off, "form_opts_off"); - - Err : Eti_Error; - Opt : C_Int := FrmOS_2_CInt (Options); - begin - if On then - Err := Form_Opts_On (Frm, Opt); - else - Err := Form_Opts_Off (Frm, Opt); - end if; - if Err /= E_Ok then - Eti_Exception (Err); - end if; - end Switch_Options; - -- | - -- | - -- | - procedure Get_Options (Frm : in Form; - Options : out Form_Option_Set) - is - function Form_Opts (Frm : Form) return C_Int; - pragma Import (C, Form_Opts, "form_opts"); - - Res : C_Int := Form_Opts (Frm); - begin - Options := CInt_2_FrmOS (Res); - end Get_Options; - -- | - -- | - -- | - function Get_Options (Frm : Form := Null_Form) return Form_Option_Set - is - Fos : Form_Option_Set; - begin - Get_Options (Frm, Fos); - return Fos; - end Get_Options; - -- | - -- |===================================================================== - -- | man page form_post.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Post (Frm : in Form; - Post : in Boolean := True) - is - function M_Post (Frm : Form) return C_Int; - pragma Import (C, M_Post, "post_form"); - function M_Unpost (Frm : Form) return C_Int; - pragma Import (C, M_Unpost, "unpost_form"); - - Res : Eti_Error; - begin - if Post then - Res := M_Post (Frm); - else - Res := M_Unpost (Frm); - end if; - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Post; - -- | - -- |===================================================================== - -- | man page form_cursor.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Position_Cursor (Frm : Form) - is - function Pos_Form_Cursor (Frm : Form) return C_Int; - pragma Import (C, Pos_Form_Cursor, "pos_form_cursor"); - - Res : constant Eti_Error := Pos_Form_Cursor (Frm); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Position_Cursor; - -- | - -- |===================================================================== - -- | man page form_data.3x - -- |===================================================================== - -- | - -- | - -- | - function Data_Ahead (Frm : Form) return Boolean - is - function Ahead (Frm : Form) return C_Int; - pragma Import (C, Ahead, "data_ahead"); - - Res : constant C_Int := Ahead (Frm); - begin - if Res = Curses_False then - return False; - else - return True; - end if; - end Data_Ahead; - -- | - -- | - -- | - function Data_Behind (Frm : Form) return Boolean - is - function Behind (Frm : Form) return C_Int; - pragma Import (C, Behind, "data_behind"); - - Res : constant C_Int := Behind (Frm); - begin - if Res = Curses_False then - return False; - else - return True; - end if; - end Data_Behind; - -- | - -- |===================================================================== - -- | man page form_driver.3x - -- |===================================================================== - -- | - -- | - -- | - function Driver (Frm : Form; - Key : Key_Code) return Driver_Result - is - function Frm_Driver (Frm : Form; Key : C_Int) return C_Int; - pragma Import (C, Frm_Driver, "form_driver"); - - R : Eti_Error := Frm_Driver (Frm, C_Int (Key)); - begin - if R /= E_Ok then - if R = E_Unknown_Command then - return Unknown_Request; - elsif R = E_Invalid_Field then - return Invalid_Field; - elsif R = E_Request_Denied then - return Request_Denied; - else - Eti_Exception (R); - return Form_Ok; - end if; - else - return Form_Ok; - end if; - end Driver; - -- | - -- |===================================================================== - -- | man page form_page.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_Current (Frm : in Form; - Fld : in Field) - is - function Set_Current_Fld (Frm : Form; Fld : Field) return C_Int; - pragma Import (C, Set_Current_Fld, "set_current_field"); - - Res : constant Eti_Error := Set_Current_Fld (Frm, Fld); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Current; - -- | - -- | - -- | - function Current (Frm : in Form) return Field - is - function Current_Fld (Frm : Form) return Field; - pragma Import (C, Current_Fld, "current_field"); - - Fld : constant Field := Current_Fld (Frm); - begin - if Fld = Null_Field then - raise Form_Exception; - end if; - return Fld; - end Current; - -- | - -- | - -- | - procedure Set_Page (Frm : in Form; - Page : in Page_Number := Page_Number'First) - is - function Set_Frm_Page (Frm : Form; Pg : C_Int) return C_Int; - pragma Import (C, Set_Frm_Page, "set_form_page"); - - Res : constant Eti_Error := Set_Frm_Page (Frm, C_Int (Page)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Page; - -- | - -- | - -- | - function Page (Frm : Form) return Page_Number - is - function Get_Page (Frm : Form) return C_Int; - pragma Import (C, Get_Page, "form_page"); - - P : constant C_Int := Get_Page (Frm); - begin - if P < 0 then - raise Form_Exception; - else - return Page_Number (P); - end if; - end Page; - - function Get_Index (Fld : Field) return Positive - is - function Get_Fieldindex (Fld : Field) return C_Int; - pragma Import (C, Get_Fieldindex, "field_index"); - - Res : constant C_Int := Get_Fieldindex (Fld); - begin - if Res = Curses_Err then - raise Form_Exception; - end if; - return Positive (Natural (Res) + Positive'First); - end Get_Index; - - -- | - -- |===================================================================== - -- | man page form_new_page.3x - -- |===================================================================== - -- | - -- | - -- | - procedure Set_New_Page (Fld : in Field; - New_Page : in Boolean := True) - is - function Set_Page (Fld : Field; Flg : C_Int) return C_Int; - pragma Import (C, Set_Page, "set_new_page"); - - Res : constant Eti_Error := Set_Page (Fld, Boolean'Pos (New_Page)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_New_Page; - -- | - -- | - -- | - function Is_New_Page (Fld : Field) return Boolean - is - function Is_New (Fld : Field) return C_Int; - pragma Import (C, Is_New, "new_page"); - - Res : constant C_Int := Is_New (Fld); - begin - if Res = Curses_False then - return False; - else - return True; - end if; - end Is_New_Page; - - procedure Free (FA : in out Field_Array_Access; - Free_Fields : in Boolean := False) - is - procedure Release is new Ada.Unchecked_Deallocation - (Field_Array, Field_Array_Access); - begin - if FA /= null and then Free_Fields then - for I in FA'First .. (FA'Last - 1) loop - if (FA (I) /= Null_Field) then - Delete (FA (I)); - end if; - end loop; - end if; - Release (FA); - end Free; - - -- |===================================================================== - - function Default_Field_Options return Field_Option_Set - is - begin - return Get_Options (Null_Field); - end Default_Field_Options; - - function Default_Form_Options return Form_Option_Set - is - begin - return Get_Options (Null_Form); - end Default_Form_Options; - -end Terminal_Interface.Curses.Forms; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-item_user_data.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-item_user_data.adb deleted file mode 100644 index 6c35d338fd..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-item_user_data.adb +++ /dev/null @@ -1,77 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menus.Item_User_Data -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Menus.Item_User_Data is - - use type Interfaces.C.int; - - procedure Set_User_Data (Itm : in Item; - Data : in User_Access) - is - function Set_Item_Userptr (Itm : Item; - Addr : User_Access) return C_Int; - pragma Import (C, Set_Item_Userptr, "set_item_userptr"); - - Res : constant Eti_Error := Set_Item_Userptr (Itm, Data); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_User_Data; - - function Get_User_Data (Itm : in Item) return User_Access - is - function Item_Userptr (Itm : Item) return User_Access; - pragma Import (C, Item_Userptr, "item_userptr"); - begin - return Item_Userptr (Itm); - end Get_User_Data; - - procedure Get_User_Data (Itm : in Item; - Data : out User_Access) - is - begin - Data := Get_User_Data (Itm); - end Get_User_Data; - -end Terminal_Interface.Curses.Menus.Item_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-menu_user_data.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-menu_user_data.adb deleted file mode 100644 index 20b9e8665a..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus-menu_user_data.adb +++ /dev/null @@ -1,76 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menus.Menu_User_Data -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.Menus.Menu_User_Data is - - use type Interfaces.C.int; - - procedure Set_User_Data (Men : in Menu; - Data : in User_Access) - is - function Set_Menu_Userptr (Men : Menu; - Data : User_Access) return C_Int; - pragma Import (C, Set_Menu_Userptr, "set_menu_userptr"); - - Res : constant Eti_Error := Set_Menu_Userptr (Men, Data); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_User_Data; - - function Get_User_Data (Men : in Menu) return User_Access - is - function Menu_Userptr (Men : Menu) return User_Access; - pragma Import (C, Menu_Userptr, "menu_userptr"); - begin - return Menu_Userptr (Men); - end Get_User_Data; - - procedure Get_User_Data (Men : in Menu; - Data : out User_Access) - is - begin - Data := Get_User_Data (Men); - end Get_User_Data; - -end Terminal_Interface.Curses.Menus.Menu_User_Data; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus.adb deleted file mode 100644 index 3dac213dd8..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-menus.adb +++ /dev/null @@ -1,1021 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Menus -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.22 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Unchecked_Deallocation; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Interfaces.C.Pointers; - -with Ada.Unchecked_Conversion; - -package body Terminal_Interface.Curses.Menus is - - type C_Item_Array is array (Natural range <>) of aliased Item; - package I_Array is new - Interfaces.C.Pointers (Natural, Item, C_Item_Array, Null_Item); - - use type System.Bit_Order; - subtype chars_ptr is Interfaces.C.Strings.chars_ptr; - - function MOS_2_CInt is new - Ada.Unchecked_Conversion (Menu_Option_Set, - C_Int); - - function CInt_2_MOS is new - Ada.Unchecked_Conversion (C_Int, - Menu_Option_Set); - - function IOS_2_CInt is new - Ada.Unchecked_Conversion (Item_Option_Set, - C_Int); - - function CInt_2_IOS is new - Ada.Unchecked_Conversion (C_Int, - Item_Option_Set); - ------------------------------------------------------------------------------- - procedure Request_Name (Key : in Menu_Request_Code; - Name : out String) - is - function Request_Name (Key : C_Int) return chars_ptr; - pragma Import (C, Request_Name, "menu_request_name"); - begin - Fill_String (Request_Name (C_Int (Key)), Name); - end Request_Name; - - function Request_Name (Key : Menu_Request_Code) return String - is - function Request_Name (Key : C_Int) return chars_ptr; - pragma Import (C, Request_Name, "menu_request_name"); - begin - return Fill_String (Request_Name (C_Int (Key))); - end Request_Name; - - function Create (Name : String; - Description : String := "") return Item - is - type Char_Ptr is access all Interfaces.C.char; - function Newitem (Name, Desc : Char_Ptr) return Item; - pragma Import (C, Newitem, "new_item"); - - type Name_String is new char_array (0 .. Name'Length); - type Name_String_Ptr is access Name_String; - pragma Controlled (Name_String_Ptr); - - type Desc_String is new char_array (0 .. Description'Length); - type Desc_String_Ptr is access Desc_String; - pragma Controlled (Desc_String_Ptr); - - Name_Str : Name_String_Ptr := new Name_String; - Desc_Str : Desc_String_Ptr := new Desc_String; - Name_Len, Desc_Len : size_t; - Result : Item; - begin - To_C (Name, Name_Str.all, Name_Len); - To_C (Description, Desc_Str.all, Desc_Len); - Result := Newitem (Name_Str.all (Name_Str.all'First)'Access, - Desc_Str.all (Desc_Str.all'First)'Access); - if Result = Null_Item then - raise Eti_System_Error; - end if; - return Result; - end Create; - - procedure Delete (Itm : in out Item) - is - function Descname (Itm : Item) return chars_ptr; - pragma Import (C, Descname, "item_description"); - function Itemname (Itm : Item) return chars_ptr; - pragma Import (C, Itemname, "item_name"); - - function Freeitem (Itm : Item) return C_Int; - pragma Import (C, Freeitem, "free_item"); - - Res : Eti_Error; - Ptr : chars_ptr; - begin - Ptr := Descname (Itm); - if Ptr /= Null_Ptr then - Interfaces.C.Strings.Free (Ptr); - end if; - Ptr := Itemname (Itm); - if Ptr /= Null_Ptr then - Interfaces.C.Strings.Free (Ptr); - end if; - Res := Freeitem (Itm); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Itm := Null_Item; - end Delete; -------------------------------------------------------------------------------- - procedure Set_Value (Itm : in Item; - Value : in Boolean := True) - is - function Set_Item_Val (Itm : Item; - Val : C_Int) return C_Int; - pragma Import (C, Set_Item_Val, "set_item_value"); - - Res : constant Eti_Error := Set_Item_Val (Itm, Boolean'Pos (Value)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Value; - - function Value (Itm : Item) return Boolean - is - function Item_Val (Itm : Item) return C_Int; - pragma Import (C, Item_Val, "item_value"); - begin - if Item_Val (Itm) = Curses_False then - return False; - else - return True; - end if; - end Value; - -------------------------------------------------------------------------------- - function Visible (Itm : Item) return Boolean - is - function Item_Vis (Itm : Item) return C_Int; - pragma Import (C, Item_Vis, "item_visible"); - begin - if Item_Vis (Itm) = Curses_False then - return False; - else - return True; - end if; - end Visible; -------------------------------------------------------------------------------- - procedure Set_Options (Itm : in Item; - Options : in Item_Option_Set) - is - function Set_Item_Opts (Itm : Item; - Opt : C_Int) return C_Int; - pragma Import (C, Set_Item_Opts, "set_item_opts"); - - Opt : C_Int := IOS_2_CInt (Options); - Res : Eti_Error; - begin - Res := Set_Item_Opts (Itm, Opt); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Options; - - procedure Switch_Options (Itm : in Item; - Options : in Item_Option_Set; - On : Boolean := True) - is - function Item_Opts_On (Itm : Item; - Opt : C_Int) return C_Int; - pragma Import (C, Item_Opts_On, "item_opts_on"); - function Item_Opts_Off (Itm : Item; - Opt : C_Int) return C_Int; - pragma Import (C, Item_Opts_Off, "item_opts_off"); - - Opt : C_Int := IOS_2_CInt (Options); - Err : Eti_Error; - begin - if On then - Err := Item_Opts_On (Itm, Opt); - else - Err := Item_Opts_Off (Itm, Opt); - end if; - if Err /= E_Ok then - Eti_Exception (Err); - end if; - end Switch_Options; - - procedure Get_Options (Itm : in Item; - Options : out Item_Option_Set) - is - function Item_Opts (Itm : Item) return C_Int; - pragma Import (C, Item_Opts, "item_opts"); - - Res : C_Int := Item_Opts (Itm); - begin - Options := CInt_2_IOS (Res); - end Get_Options; - - function Get_Options (Itm : Item := Null_Item) return Item_Option_Set - is - Ios : Item_Option_Set; - begin - Get_Options (Itm, Ios); - return Ios; - end Get_Options; -------------------------------------------------------------------------------- - procedure Name (Itm : in Item; - Name : out String) - is - function Itemname (Itm : Item) return chars_ptr; - pragma Import (C, Itemname, "item_name"); - begin - Fill_String (Itemname (Itm), Name); - end Name; - - function Name (Itm : in Item) return String - is - function Itemname (Itm : Item) return chars_ptr; - pragma Import (C, Itemname, "item_name"); - begin - return Fill_String (Itemname (Itm)); - end Name; - - procedure Description (Itm : in Item; - Description : out String) - is - function Descname (Itm : Item) return chars_ptr; - pragma Import (C, Descname, "item_description"); - begin - Fill_String (Descname (Itm), Description); - end Description; - - function Description (Itm : in Item) return String - is - function Descname (Itm : Item) return chars_ptr; - pragma Import (C, Descname, "item_description"); - begin - return Fill_String (Descname (Itm)); - end Description; -------------------------------------------------------------------------------- - procedure Set_Current (Men : in Menu; - Itm : in Item) - is - function Set_Curr_Item (Men : Menu; - Itm : Item) return C_Int; - pragma Import (C, Set_Curr_Item, "set_current_item"); - - Res : constant Eti_Error := Set_Curr_Item (Men, Itm); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Current; - - function Current (Men : Menu) return Item - is - function Curr_Item (Men : Menu) return Item; - pragma Import (C, Curr_Item, "current_item"); - - Res : constant Item := Curr_Item (Men); - begin - if Res = Null_Item then - raise Menu_Exception; - end if; - return Res; - end Current; - - procedure Set_Top_Row (Men : in Menu; - Line : in Line_Position) - is - function Set_Toprow (Men : Menu; - Line : C_Int) return C_Int; - pragma Import (C, Set_Toprow, "set_top_row"); - - Res : constant Eti_Error := Set_Toprow (Men, C_Int (Line)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Top_Row; - - function Top_Row (Men : Menu) return Line_Position - is - function Toprow (Men : Menu) return C_Int; - pragma Import (C, Toprow, "top_row"); - - Res : constant C_Int := Toprow (Men); - begin - if Res = Curses_Err then - raise Menu_Exception; - end if; - return Line_Position (Res); - end Top_Row; - - function Get_Index (Itm : Item) return Positive - is - function Get_Itemindex (Itm : Item) return C_Int; - pragma Import (C, Get_Itemindex, "item_index"); - - Res : constant C_Int := Get_Itemindex (Itm); - begin - if Res = Curses_Err then - raise Menu_Exception; - end if; - return Positive (Natural (Res) + Positive'First); - end Get_Index; -------------------------------------------------------------------------------- - procedure Post (Men : in Menu; - Post : in Boolean := True) - is - function M_Post (Men : Menu) return C_Int; - pragma Import (C, M_Post, "post_menu"); - function M_Unpost (Men : Menu) return C_Int; - pragma Import (C, M_Unpost, "unpost_menu"); - - Res : Eti_Error; - begin - if Post then - Res := M_Post (Men); - else - Res := M_Unpost (Men); - end if; - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Post; -------------------------------------------------------------------------------- - procedure Set_Options (Men : in Menu; - Options : in Menu_Option_Set) - is - function Set_Menu_Opts (Men : Menu; - Opt : C_Int) return C_Int; - pragma Import (C, Set_Menu_Opts, "set_menu_opts"); - - Opt : C_Int := MOS_2_CInt (Options); - Res : Eti_Error; - begin - Res := Set_Menu_Opts (Men, Opt); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Options; - - procedure Switch_Options (Men : in Menu; - Options : in Menu_Option_Set; - On : in Boolean := True) - is - function Menu_Opts_On (Men : Menu; - Opt : C_Int) return C_Int; - pragma Import (C, Menu_Opts_On, "menu_opts_on"); - function Menu_Opts_Off (Men : Menu; - Opt : C_Int) return C_Int; - pragma Import (C, Menu_Opts_Off, "menu_opts_off"); - - Opt : C_Int := MOS_2_CInt (Options); - Err : Eti_Error; - begin - if On then - Err := Menu_Opts_On (Men, Opt); - else - Err := Menu_Opts_Off (Men, Opt); - end if; - if Err /= E_Ok then - Eti_Exception (Err); - end if; - end Switch_Options; - - procedure Get_Options (Men : in Menu; - Options : out Menu_Option_Set) - is - function Menu_Opts (Men : Menu) return C_Int; - pragma Import (C, Menu_Opts, "menu_opts"); - - Res : C_Int := Menu_Opts (Men); - begin - Options := CInt_2_MOS (Res); - end Get_Options; - - function Get_Options (Men : Menu := Null_Menu) return Menu_Option_Set - is - Mos : Menu_Option_Set; - begin - Get_Options (Men, Mos); - return Mos; - end Get_Options; -------------------------------------------------------------------------------- - procedure Set_Window (Men : in Menu; - Win : in Window) - is - function Set_Menu_Win (Men : Menu; - Win : Window) return C_Int; - pragma Import (C, Set_Menu_Win, "set_menu_win"); - - Res : constant Eti_Error := Set_Menu_Win (Men, Win); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Window; - - function Get_Window (Men : Menu) return Window - is - function Menu_Win (Men : Menu) return Window; - pragma Import (C, Menu_Win, "menu_win"); - - W : constant Window := Menu_Win (Men); - begin - return W; - end Get_Window; - - procedure Set_Sub_Window (Men : in Menu; - Win : in Window) - is - function Set_Menu_Sub (Men : Menu; - Win : Window) return C_Int; - pragma Import (C, Set_Menu_Sub, "set_menu_sub"); - - Res : constant Eti_Error := Set_Menu_Sub (Men, Win); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Sub_Window; - - function Get_Sub_Window (Men : Menu) return Window - is - function Menu_Sub (Men : Menu) return Window; - pragma Import (C, Menu_Sub, "menu_sub"); - - W : constant Window := Menu_Sub (Men); - begin - return W; - end Get_Sub_Window; - - procedure Scale (Men : in Menu; - Lines : out Line_Count; - Columns : out Column_Count) - is - type C_Int_Access is access all C_Int; - function M_Scale (Men : Menu; - Yp, Xp : C_Int_Access) return C_Int; - pragma Import (C, M_Scale, "scale_menu"); - - X, Y : aliased C_Int; - Res : constant Eti_Error := M_Scale (Men, Y'Access, X'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Lines := Line_Count (Y); - Columns := Column_Count (X); - end Scale; -------------------------------------------------------------------------------- - procedure Position_Cursor (Men : Menu) - is - function Pos_Menu_Cursor (Men : Menu) return C_Int; - pragma Import (C, Pos_Menu_Cursor, "pos_menu_cursor"); - - Res : constant Eti_Error := Pos_Menu_Cursor (Men); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Position_Cursor; - -------------------------------------------------------------------------------- - procedure Set_Mark (Men : in Menu; - Mark : in String) - is - type Char_Ptr is access all Interfaces.C.char; - function Set_Mark (Men : Menu; - Mark : Char_Ptr) return C_Int; - pragma Import (C, Set_Mark, "set_menu_mark"); - - Txt : char_array (0 .. Mark'Length); - Len : size_t; - Res : Eti_Error; - begin - To_C (Mark, Txt, Len); - Res := Set_Mark (Men, Txt (Txt'First)'Access); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Mark; - - procedure Mark (Men : in Menu; - Mark : out String) - is - function Get_Menu_Mark (Men : Menu) return chars_ptr; - pragma Import (C, Get_Menu_Mark, "menu_mark"); - begin - Fill_String (Get_Menu_Mark (Men), Mark); - end Mark; - - function Mark (Men : Menu) return String - is - function Get_Menu_Mark (Men : Menu) return chars_ptr; - pragma Import (C, Get_Menu_Mark, "menu_mark"); - begin - return Fill_String (Get_Menu_Mark (Men)); - end Mark; - -------------------------------------------------------------------------------- - procedure Set_Foreground - (Men : in Menu; - Fore : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Set_Menu_Fore (Men : Menu; - Attr : C_Chtype) return C_Int; - pragma Import (C, Set_Menu_Fore, "set_menu_fore"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Color => Color, - Attr => Fore); - Res : constant Eti_Error := Set_Menu_Fore (Men, AttrChar_To_Chtype (Ch)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Foreground; - - procedure Foreground (Men : in Menu; - Fore : out Character_Attribute_Set) - is - function Menu_Fore (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Fore, "menu_fore"); - begin - Fore := Chtype_To_AttrChar (Menu_Fore (Men)).Attr; - end Foreground; - - procedure Foreground (Men : in Menu; - Fore : out Character_Attribute_Set; - Color : out Color_Pair) - is - function Menu_Fore (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Fore, "menu_fore"); - begin - Fore := Chtype_To_AttrChar (Menu_Fore (Men)).Attr; - Color := Chtype_To_AttrChar (Menu_Fore (Men)).Color; - end Foreground; - - procedure Set_Background - (Men : in Menu; - Back : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Set_Menu_Back (Men : Menu; - Attr : C_Chtype) return C_Int; - pragma Import (C, Set_Menu_Back, "set_menu_back"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Color => Color, - Attr => Back); - Res : constant Eti_Error := Set_Menu_Back (Men, AttrChar_To_Chtype (Ch)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Background; - - procedure Background (Men : in Menu; - Back : out Character_Attribute_Set) - is - function Menu_Back (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Back, "menu_back"); - begin - Back := Chtype_To_AttrChar (Menu_Back (Men)).Attr; - end Background; - - procedure Background (Men : in Menu; - Back : out Character_Attribute_Set; - Color : out Color_Pair) - is - function Menu_Back (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Back, "menu_back"); - begin - Back := Chtype_To_AttrChar (Menu_Back (Men)).Attr; - Color := Chtype_To_AttrChar (Menu_Back (Men)).Color; - end Background; - - procedure Set_Grey (Men : in Menu; - Grey : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Set_Menu_Grey (Men : Menu; - Attr : C_Chtype) return C_Int; - pragma Import (C, Set_Menu_Grey, "set_menu_grey"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Color => Color, - Attr => Grey); - - Res : constant Eti_Error := Set_Menu_Grey (Men, AttrChar_To_Chtype (Ch)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Grey; - - procedure Grey (Men : in Menu; - Grey : out Character_Attribute_Set) - is - function Menu_Grey (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Grey, "menu_grey"); - begin - Grey := Chtype_To_AttrChar (Menu_Grey (Men)).Attr; - end Grey; - - procedure Grey (Men : in Menu; - Grey : out Character_Attribute_Set; - Color : out Color_Pair) - is - function Menu_Grey (Men : Menu) return C_Chtype; - pragma Import (C, Menu_Grey, "menu_grey"); - begin - Grey := Chtype_To_AttrChar (Menu_Grey (Men)).Attr; - Color := Chtype_To_AttrChar (Menu_Grey (Men)).Color; - end Grey; - - procedure Set_Pad_Character (Men : in Menu; - Pad : in Character := Space) - is - function Set_Menu_Pad (Men : Menu; - Ch : C_Int) return C_Int; - pragma Import (C, Set_Menu_Pad, "set_menu_pad"); - - Res : constant Eti_Error := Set_Menu_Pad (Men, - C_Int (Character'Pos (Pad))); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Pad_Character; - - procedure Pad_Character (Men : in Menu; - Pad : out Character) - is - function Menu_Pad (Men : Menu) return C_Int; - pragma Import (C, Menu_Pad, "menu_pad"); - begin - Pad := Character'Val (Menu_Pad (Men)); - end Pad_Character; -------------------------------------------------------------------------------- - procedure Set_Spacing (Men : in Menu; - Descr : in Column_Position := 0; - Row : in Line_Position := 0; - Col : in Column_Position := 0) - is - function Set_Spacing (Men : Menu; - D, R, C : C_Int) return C_Int; - pragma Import (C, Set_Spacing, "set_menu_spacing"); - - Res : constant Eti_Error := Set_Spacing (Men, - C_Int (Descr), - C_Int (Row), - C_Int (Col)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Spacing; - - procedure Spacing (Men : in Menu; - Descr : out Column_Position; - Row : out Line_Position; - Col : out Column_Position) - is - type C_Int_Access is access all C_Int; - function Get_Spacing (Men : Menu; - D, R, C : C_Int_Access) return C_Int; - pragma Import (C, Get_Spacing, "menu_spacing"); - - D, R, C : aliased C_Int; - Res : constant Eti_Error := Get_Spacing (Men, - D'Access, - R'Access, - C'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - else - Descr := Column_Position (D); - Row := Line_Position (R); - Col := Column_Position (C); - end if; - end Spacing; -------------------------------------------------------------------------------- - function Set_Pattern (Men : Menu; - Text : String) return Boolean - is - type Char_Ptr is access all Interfaces.C.char; - function Set_Pattern (Men : Menu; - Pattern : Char_Ptr) return C_Int; - pragma Import (C, Set_Pattern, "set_menu_pattern"); - - S : char_array (0 .. Text'Length); - L : size_t; - Res : Eti_Error; - begin - To_C (Text, S, L); - Res := Set_Pattern (Men, S (S'First)'Access); - case Res is - when E_No_Match => return False; - when E_Ok => return True; - when others => - Eti_Exception (Res); - return False; - end case; - end Set_Pattern; - - procedure Pattern (Men : in Menu; - Text : out String) - is - function Get_Pattern (Men : Menu) return chars_ptr; - pragma Import (C, Get_Pattern, "menu_pattern"); - begin - Fill_String (Get_Pattern (Men), Text); - end Pattern; -------------------------------------------------------------------------------- - procedure Set_Format (Men : in Menu; - Lines : in Line_Count; - Columns : in Column_Count) - is - function Set_Menu_Fmt (Men : Menu; - Lin : C_Int; - Col : C_Int) return C_Int; - pragma Import (C, Set_Menu_Fmt, "set_menu_format"); - - Res : constant Eti_Error := Set_Menu_Fmt (Men, - C_Int (Lines), - C_Int (Columns)); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Format; - - procedure Format (Men : in Menu; - Lines : out Line_Count; - Columns : out Column_Count) - is - type C_Int_Access is access all C_Int; - function Menu_Fmt (Men : Menu; - Y, X : C_Int_Access) return C_Int; - pragma Import (C, Menu_Fmt, "menu_format"); - - L, C : aliased C_Int; - Res : constant Eti_Error := Menu_Fmt (Men, L'Access, C'Access); - begin - if Res /= E_Ok then - Eti_Exception (Res); - else - Lines := Line_Count (L); - Columns := Column_Count (C); - end if; - end Format; -------------------------------------------------------------------------------- - procedure Set_Item_Init_Hook (Men : in Menu; - Proc : in Menu_Hook_Function) - is - function Set_Item_Init (Men : Menu; - Proc : Menu_Hook_Function) return C_Int; - pragma Import (C, Set_Item_Init, "set_item_init"); - - Res : constant Eti_Error := Set_Item_Init (Men, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Item_Init_Hook; - - procedure Set_Item_Term_Hook (Men : in Menu; - Proc : in Menu_Hook_Function) - is - function Set_Item_Term (Men : Menu; - Proc : Menu_Hook_Function) return C_Int; - pragma Import (C, Set_Item_Term, "set_item_term"); - - Res : constant Eti_Error := Set_Item_Term (Men, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Item_Term_Hook; - - procedure Set_Menu_Init_Hook (Men : in Menu; - Proc : in Menu_Hook_Function) - is - function Set_Menu_Init (Men : Menu; - Proc : Menu_Hook_Function) return C_Int; - pragma Import (C, Set_Menu_Init, "set_menu_init"); - - Res : constant Eti_Error := Set_Menu_Init (Men, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Menu_Init_Hook; - - procedure Set_Menu_Term_Hook (Men : in Menu; - Proc : in Menu_Hook_Function) - is - function Set_Menu_Term (Men : Menu; - Proc : Menu_Hook_Function) return C_Int; - pragma Import (C, Set_Menu_Term, "set_menu_term"); - - Res : constant Eti_Error := Set_Menu_Term (Men, Proc); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end Set_Menu_Term_Hook; - - function Get_Item_Init_Hook (Men : Menu) return Menu_Hook_Function - is - function Item_Init (Men : Menu) return Menu_Hook_Function; - pragma Import (C, Item_Init, "item_init"); - begin - return Item_Init (Men); - end Get_Item_Init_Hook; - - function Get_Item_Term_Hook (Men : Menu) return Menu_Hook_Function - is - function Item_Term (Men : Menu) return Menu_Hook_Function; - pragma Import (C, Item_Term, "item_term"); - begin - return Item_Term (Men); - end Get_Item_Term_Hook; - - function Get_Menu_Init_Hook (Men : Menu) return Menu_Hook_Function - is - function Menu_Init (Men : Menu) return Menu_Hook_Function; - pragma Import (C, Menu_Init, "menu_init"); - begin - return Menu_Init (Men); - end Get_Menu_Init_Hook; - - function Get_Menu_Term_Hook (Men : Menu) return Menu_Hook_Function - is - function Menu_Term (Men : Menu) return Menu_Hook_Function; - pragma Import (C, Menu_Term, "menu_term"); - begin - return Menu_Term (Men); - end Get_Menu_Term_Hook; -------------------------------------------------------------------------------- - procedure Redefine (Men : in Menu; - Items : in Item_Array_Access) - is - function Set_Items (Men : Menu; - Items : System.Address) return C_Int; - pragma Import (C, Set_Items, "set_menu_items"); - - Res : Eti_Error; - begin - pragma Assert (Items (Items'Last) = Null_Item); - if Items (Items'Last) /= Null_Item then - raise Menu_Exception; - else - Res := Set_Items (Men, Items.all'Address); - if Res /= E_Ok then - Eti_Exception (Res); - end if; - end if; - end Redefine; - - function Item_Count (Men : Menu) return Natural - is - function Count (Men : Menu) return C_Int; - pragma Import (C, Count, "item_count"); - begin - return Natural (Count (Men)); - end Item_Count; - - function Items (Men : Menu; - Index : Positive) return Item - is - use I_Array; - - function C_Mitems (Men : Menu) return Pointer; - pragma Import (C, C_Mitems, "menu_items"); - - P : Pointer := C_Mitems (Men); - begin - if P = null or else Index not in 1 .. Item_Count (Men) then - raise Menu_Exception; - else - P := P + ptrdiff_t (C_Int (Index) - 1); - return P.all; - end if; - end Items; - -------------------------------------------------------------------------------- - function Create (Items : Item_Array_Access) return Menu - is - function Newmenu (Items : System.Address) return Menu; - pragma Import (C, Newmenu, "new_menu"); - - M : Menu; - begin - pragma Assert (Items (Items'Last) = Null_Item); - if Items (Items'Last) /= Null_Item then - raise Menu_Exception; - else - M := Newmenu (Items.all'Address); - if M = Null_Menu then - raise Menu_Exception; - end if; - return M; - end if; - end Create; - - procedure Delete (Men : in out Menu) - is - function Free (Men : Menu) return C_Int; - pragma Import (C, Free, "free_menu"); - - Res : constant Eti_Error := Free (Men); - begin - if Res /= E_Ok then - Eti_Exception (Res); - end if; - Men := Null_Menu; - end Delete; - ------------------------------------------------------------------------------- - function Driver (Men : Menu; - Key : Key_Code) return Driver_Result - is - function Driver (Men : Menu; - Key : C_Int) return C_Int; - pragma Import (C, Driver, "menu_driver"); - - R : Eti_Error := Driver (Men, C_Int (Key)); - begin - if R /= E_Ok then - case R is - when E_Unknown_Command => return Unknown_Request; - when E_No_Match => return No_Match; - when E_Request_Denied | - E_Not_Selectable => return Request_Denied; - when others => - Eti_Exception (R); - end case; - end if; - return Menu_Ok; - end Driver; - - procedure Free (IA : in out Item_Array_Access; - Free_Items : in Boolean := False) - is - procedure Release is new Ada.Unchecked_Deallocation - (Item_Array, Item_Array_Access); - begin - if IA /= null and then Free_Items then - for I in IA'First .. (IA'Last - 1) loop - if (IA (I) /= Null_Item) then - Delete (IA (I)); - end if; - end loop; - end if; - Release (IA); - end Free; - -------------------------------------------------------------------------------- - function Default_Menu_Options return Menu_Option_Set - is - begin - return Get_Options (Null_Menu); - end Default_Menu_Options; - - function Default_Item_Options return Item_Option_Set - is - begin - return Get_Options (Null_Item); - end Default_Item_Options; -------------------------------------------------------------------------------- - -end Terminal_Interface.Curses.Menus; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-mouse.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-mouse.adb deleted file mode 100644 index 52ac522ebf..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-mouse.adb +++ /dev/null @@ -1,214 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Mouse -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.18 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with System; - -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Interfaces.C; use Interfaces.C; -use Interfaces; - -package body Terminal_Interface.Curses.Mouse is - - use type System.Bit_Order; - use type Interfaces.C.int; - - function Has_Mouse return Boolean - is - function Mouse_Avail return C_Int; - pragma Import (C, Mouse_Avail, "_nc_has_mouse"); - begin - if Has_Key (Key_Mouse) or else Mouse_Avail /= 0 then - return True; - else - return False; - end if; - end Has_Mouse; - - function Get_Mouse return Mouse_Event - is - type Event_Access is access all Mouse_Event; - - function Getmouse (Ev : Event_Access) return C_Int; - pragma Import (C, Getmouse, "getmouse"); - - Event : aliased Mouse_Event; - begin - if Getmouse (Event'Access) = Curses_Err then - raise Curses_Exception; - end if; - return Event; - end Get_Mouse; - - procedure Register_Reportable_Event (Button : in Mouse_Button; - State : in Button_State; - Mask : in out Event_Mask) - is - Button_Nr : constant Natural := Mouse_Button'Pos (Button); - State_Nr : constant Natural := Button_State'Pos (State); - begin - if Button in Modifier_Keys and then State /= Pressed then - raise Curses_Exception; - else - if Button in Real_Buttons then - Mask := Mask or ((2 ** (6 * Button_Nr)) ** State_Nr); - else - Mask := Mask or (BUTTON_CTRL ** (Button_Nr - 4)); - end if; - end if; - end Register_Reportable_Event; - - procedure Register_Reportable_Events (Button : in Mouse_Button; - State : in Button_States; - Mask : in out Event_Mask) - is - begin - for S in Button_States'Range loop - if State (S) then - Register_Reportable_Event (Button, S, Mask); - end if; - end loop; - end Register_Reportable_Events; - - function Start_Mouse (Mask : Event_Mask := All_Events) - return Event_Mask - is - function MMask (M : Event_Mask; - O : access Event_Mask) return Event_Mask; - pragma Import (C, MMask, "mousemask"); - R : Event_Mask; - Old : aliased Event_Mask; - begin - R := MMask (Mask, Old'Access); - return Old; - end Start_Mouse; - - procedure End_Mouse (Mask : in Event_Mask := No_Events) - is - begin - null; - end End_Mouse; - - procedure Dispatch_Event (Mask : in Event_Mask; - Button : out Mouse_Button; - State : out Button_State); - - procedure Dispatch_Event (Mask : in Event_Mask; - Button : out Mouse_Button; - State : out Button_State) is - L : Event_Mask; - begin - Button := Alt; -- preset to non real button; - if (Mask and BUTTON1_EVENTS) /= 0 then - Button := Left; - elsif (Mask and BUTTON2_EVENTS) /= 0 then - Button := Middle; - elsif (Mask and BUTTON3_EVENTS) /= 0 then - Button := Right; - elsif (Mask and BUTTON4_EVENTS) /= 0 then - Button := Button4; - end if; - if Button in Real_Buttons then - L := 2 ** (6 * Mouse_Button'Pos (Button)); - for I in Button_State'Range loop - if (Mask and L) /= 0 then - State := I; - exit; - end if; - L := 2 * L; - end loop; - else - State := Pressed; - if (Mask and BUTTON_CTRL) /= 0 then - Button := Control; - elsif (Mask and BUTTON_SHIFT) /= 0 then - Button := Shift; - elsif (Mask and BUTTON_ALT) /= 0 then - Button := Alt; - end if; - end if; - end Dispatch_Event; - - procedure Get_Event (Event : in Mouse_Event; - Y : out Line_Position; - X : out Column_Position; - Button : out Mouse_Button; - State : out Button_State) - is - Mask : constant Event_Mask := Event.Bstate; - begin - X := Column_Position (Event.X); - Y := Line_Position (Event.Y); - Dispatch_Event (Mask, Button, State); - end Get_Event; - - procedure Unget_Mouse (Event : in Mouse_Event) - is - function Ungetmouse (Ev : Mouse_Event) return C_Int; - pragma Import (C, Ungetmouse, "ungetmouse"); - begin - if Ungetmouse (Event) = Curses_Err then - raise Curses_Exception; - end if; - end Unget_Mouse; - - function Enclosed_In_Window (Win : Window := Standard_Window; - Event : Mouse_Event) return Boolean - is - function Wenclose (Win : Window; Y : C_Int; X : C_Int) - return Curses_Bool; - pragma Import (C, Wenclose, "wenclose"); - begin - if Wenclose (Win, C_Int (Event.Y), C_Int (Event.X)) - = Curses_Bool_False then - return False; - else - return True; - end if; - end Enclosed_In_Window; - - function Mouse_Interval (Msec : Natural := 200) return Natural - is - function Mouseinterval (Msec : C_Int) return C_Int; - pragma Import (C, Mouseinterval, "mouseinterval"); - begin - return Natural (Mouseinterval (C_Int (Msec))); - end Mouse_Interval; - -end Terminal_Interface.Curses.Mouse; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels-user_data.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels-user_data.adb deleted file mode 100644 index 231efaefbc..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels-user_data.adb +++ /dev/null @@ -1,78 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Panels.User_Data -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Interfaces.C; -with Terminal_Interface.Curses.Aux; -use Terminal_Interface.Curses.Aux; -with Terminal_Interface.Curses.Panels; -use Terminal_Interface.Curses.Panels; - -package body Terminal_Interface.Curses.Panels.User_Data is - - use type Interfaces.C.int; - - procedure Set_User_Data (Pan : in Panel; - Data : in User_Access) - is - function Set_Panel_Userptr (Pan : Panel; - Addr : User_Access) return C_Int; - pragma Import (C, Set_Panel_Userptr, "set_panel_userptr"); - begin - if Set_Panel_Userptr (Pan, Data) = Curses_Err then - raise Panel_Exception; - end if; - end Set_User_Data; - - function Get_User_Data (Pan : in Panel) return User_Access - is - function Panel_Userptr (Pan : Panel) return User_Access; - pragma Import (C, Panel_Userptr, "panel_userptr"); - begin - return Panel_Userptr (Pan); - end Get_User_Data; - - procedure Get_User_Data (Pan : in Panel; - Data : out User_Access) - is - begin - Data := Get_User_Data (Pan); - end Get_User_Data; - -end Terminal_Interface.Curses.Panels.User_Data; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels.adb deleted file mode 100644 index a5af83a6b5..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-panels.adb +++ /dev/null @@ -1,164 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Panels -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Interfaces.C; - -package body Terminal_Interface.Curses.Panels is - - use type Interfaces.C.int; - - function Create (Win : Window) return Panel - is - function Newpanel (Win : Window) return Panel; - pragma Import (C, Newpanel, "new_panel"); - - Pan : Panel; - begin - Pan := Newpanel (Win); - if Pan = Null_Panel then - raise Panel_Exception; - end if; - return Pan; - end Create; - - procedure Bottom (Pan : in Panel) - is - function Bottompanel (Pan : Panel) return C_Int; - pragma Import (C, Bottompanel, "bottom_panel"); - begin - if Bottompanel (Pan) = Curses_Err then - raise Panel_Exception; - end if; - end Bottom; - - procedure Top (Pan : in Panel) - is - function Toppanel (Pan : Panel) return C_Int; - pragma Import (C, Toppanel, "top_panel"); - begin - if Toppanel (Pan) = Curses_Err then - raise Panel_Exception; - end if; - end Top; - - procedure Show (Pan : in Panel) - is - function Showpanel (Pan : Panel) return C_Int; - pragma Import (C, Showpanel, "show_panel"); - begin - if Showpanel (Pan) = Curses_Err then - raise Panel_Exception; - end if; - end Show; - - procedure Hide (Pan : in Panel) - is - function Hidepanel (Pan : Panel) return C_Int; - pragma Import (C, Hidepanel, "hide_panel"); - begin - if Hidepanel (Pan) = Curses_Err then - raise Panel_Exception; - end if; - end Hide; - - function Get_Window (Pan : Panel) return Window - is - function Panel_Win (Pan : Panel) return Window; - pragma Import (C, Panel_Win, "panel_window"); - - Win : Window := Panel_Win (Pan); - begin - if Win = Null_Window then - raise Panel_Exception; - end if; - return Win; - end Get_Window; - - procedure Replace (Pan : in Panel; - Win : in Window) - is - function Replace_Pan (Pan : Panel; - Win : Window) return C_Int; - pragma Import (C, Replace_Pan, "replace_panel"); - begin - if Replace_Pan (Pan, Win) = Curses_Err then - raise Panel_Exception; - end if; - end Replace; - - procedure Move (Pan : in Panel; - Line : in Line_Position; - Column : in Column_Position) - is - function Move (Pan : Panel; - Line : C_Int; - Column : C_Int) return C_Int; - pragma Import (C, Move, "move_panel"); - begin - if Move (Pan, C_Int (Line), C_Int (Column)) = Curses_Err then - raise Panel_Exception; - end if; - end Move; - - function Is_Hidden (Pan : Panel) return Boolean - is - function Panel_Hidden (Pan : Panel) return C_Int; - pragma Import (C, Panel_Hidden, "panel_hidden"); - begin - if Panel_Hidden (Pan) = Curses_False then - return False; - else - return True; - end if; - end Is_Hidden; - - procedure Delete (Pan : in out Panel) - is - function Del_Panel (Pan : Panel) return C_Int; - pragma Import (C, Del_Panel, "del_panel"); - begin - if Del_Panel (Pan) = Curses_Err then - raise Panel_Exception; - end if; - Pan := Null_Panel; - end Delete; - -end Terminal_Interface.Curses.Panels; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.adb deleted file mode 100644 index 986cd6b9bd..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.adb +++ /dev/null @@ -1,77 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.PutWin -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.3 $ --- Binding Version 01.00 - -with Ada.Streams.Stream_IO.C_Streams; -with Interfaces.C_Streams; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; - -package body Terminal_Interface.Curses.PutWin is - - package ICS renames Interfaces.C_Streams; - package ACS renames Ada.Streams.Stream_IO.C_Streams; - use type C_Int; - - procedure Put_Window (Win : Window; - File : Ada.Streams.Stream_IO.File_Type) is - function putwin (Win : Window; f : ICS.FILEs) return C_Int; - pragma Import (C, putwin, "putwin"); - - R : constant C_Int := putwin (Win, ACS.C_Stream (File)); - begin - if R /= Curses_Ok then - raise Curses_Exception; - end if; - end Put_Window; - - function Get_Window (File : Ada.Streams.Stream_IO.File_Type) - return Window is - function getwin (f : ICS.FILEs) return Window; - pragma Import (C, getwin, "getwin"); - - W : constant Window := getwin (ACS.C_Stream (File)); - begin - if W = Null_Window then - raise Curses_Exception; - else - return W; - end if; - end Get_Window; - -end Terminal_Interface.Curses.PutWin; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.ads deleted file mode 100644 index d302bdcec4..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-putwin.ads +++ /dev/null @@ -1,50 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.PutWin -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.3 $ --- Binding Version 01.00 - -with Ada.Streams.Stream_IO; - -package Terminal_Interface.Curses.PutWin is - - procedure Put_Window (Win : Window; - File : Ada.Streams.Stream_IO.File_Type); - - function Get_Window (File : Ada.Streams.Stream_IO.File_Type) return Window; - -end Terminal_Interface.Curses.PutWin; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.adb deleted file mode 100644 index be1da8297c..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.adb +++ /dev/null @@ -1,163 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Termcap -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000,2004 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.6 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; - -package body Terminal_Interface.Curses.Termcap is - - function Get_Entry (Name : String) return Boolean - is - function tgetent (name : char_array; val : char_array) - return C_Int; - pragma Import (C, tgetent, "tgetent"); - NameTxt : char_array (0 .. Name'Length); - Length : size_t; - ignored : char_array (0 .. 0) := (0 => nul); - result : C_Int; - begin - To_C (Name, NameTxt, Length); - result := tgetent (char_array (ignored), NameTxt); - if result = -1 then - raise Curses_Exception; - else - return Boolean'Val (result); - end if; - end Get_Entry; - ------------------------------------------------------------------------------- - function Get_Flag (Name : String) return Boolean - is - function tgetflag (id : char_array) return C_Int; - pragma Import (C, tgetflag, "tgetflag"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - begin - To_C (Name, Txt, Length); - if tgetflag (Txt) = 0 then - return False; - else - return True; - end if; - end Get_Flag; - ------------------------------------------------------------------------------- - procedure Get_Number (Name : in String; - Value : out Integer; - Result : out Boolean) - is - function tgetnum (id : char_array) return C_Int; - pragma Import (C, tgetnum, "tgetnum"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - begin - To_C (Name, Txt, Length); - Value := Integer (tgetnum (Txt)); - if Value = -1 then - Result := False; - else - Result := True; - end if; - end Get_Number; - ------------------------------------------------------------------------------- - procedure Get_String (Name : String; - Value : out String; - Result : out Boolean) - is - function tgetstr (id : char_array; - buf : char_array) return chars_ptr; - pragma Import (C, tgetstr, "tgetstr"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - Txt2 : chars_ptr; - type t is new char_array (0 .. 1024); -- does it need to be 1024? - Return_Buffer : t := (others => nul); - begin - To_C (Name, Txt, Length); - Txt2 := tgetstr (Txt, char_array (Return_Buffer)); - if Txt2 = Null_Ptr then - Result := False; - else - Value := Fill_String (Txt2); - Result := True; - end if; - end Get_String; - - function Get_String (Name : String) return Boolean - is - function tgetstr (Id : char_array; - buf : char_array) return chars_ptr; - pragma Import (C, tgetstr, "tgetstr"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - Txt2 : chars_ptr; - type t is new char_array (0 .. 1024); -- does it need to be 1024? - Phony_Txt : t := (others => nul); - begin - To_C (Name, Txt, Length); - Txt2 := tgetstr (Txt, char_array (Phony_Txt)); - if Txt2 = Null_Ptr then - return False; - else - return True; - end if; - end Get_String; - ------------------------------------------------------------------------------- - function TGoto (Cap : String; - Col : Column_Position; - Row : Line_Position) return Termcap_String is - function tgoto (cap : char_array; - col : C_Int; - row : C_Int) return chars_ptr; - pragma Import (C, tgoto); - Txt : char_array (0 .. Cap'Length); - Length : size_t; - begin - To_C (Cap, Txt, Length); - return Termcap_String (Fill_String - (tgoto (Txt, C_Int (Col), C_Int (Row)))); - end TGoto; - - -end Terminal_Interface.Curses.Termcap; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.ads deleted file mode 100644 index dd01396e8b..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-termcap.ads +++ /dev/null @@ -1,80 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Termcap -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.3 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -package Terminal_Interface.Curses.Termcap is - pragma Preelaborate (Terminal_Interface.Curses.Termcap); - - -- |===================================================================== - -- | Man page curs_termcap.3x - -- |===================================================================== - -- Not implemented: tputs (see curs_terminfo) - - type Termcap_String is new String; - - -- | - function TGoto (Cap : String; - Col : Column_Position; - Row : Line_Position) return Termcap_String; - -- AKA: tgoto() - - -- | - function Get_Entry (Name : String) return Boolean; - -- AKA: tgetent() - - -- | - function Get_Flag (Name : String) return Boolean; - -- AKA: tgetflag() - - -- | - procedure Get_Number (Name : String; - Value : out Integer; - Result : out Boolean); - -- AKA: tgetnum() - - -- | - procedure Get_String (Name : String; - Value : out String; - Result : out Boolean); - function Get_String (Name : String) return Boolean; - -- Returns True if the string is found. - -- AKA: tgetstr() - -end Terminal_Interface.Curses.Termcap; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.adb deleted file mode 100644 index 657871ce1d..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.adb +++ /dev/null @@ -1,161 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Terminfo -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.3 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Ada.Unchecked_Conversion; - -package body Terminal_Interface.Curses.Terminfo is - - - function Is_MinusOne_Pointer (P : in chars_ptr) return Boolean; - - function Is_MinusOne_Pointer (P : in chars_ptr) return Boolean is - type Weird_Address is new System.Storage_Elements.Integer_Address; - Invalid_Pointer : constant Weird_Address := -1; - function To_Weird is new Ada.Unchecked_Conversion - (Source => chars_ptr, Target => Weird_Address); - begin - if To_Weird (P) = Invalid_Pointer then - return True; - else - return False; - end if; - end Is_MinusOne_Pointer; - pragma Inline (Is_MinusOne_Pointer); - ------------------------------------------------------------------------------- - function Get_Flag (Name : String) return Boolean - is - function tigetflag (id : char_array) return Curses_Bool; - pragma Import (C, tigetflag); - Txt : char_array (0 .. Name'Length); - Length : size_t; - begin - To_C (Name, Txt, Length); - if tigetflag (Txt) = Curses_Bool (Curses_True) then - return True; - else - return False; - end if; - end Get_Flag; - ------------------------------------------------------------------------------- - procedure Get_String (Name : String; - Value : out Terminfo_String; - Result : out Boolean) - is - function tigetstr (id : char_array) return chars_ptr; - pragma Import (C, tigetstr, "tigetstr"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - Txt2 : chars_ptr; - begin - To_C (Name, Txt, Length); - Txt2 := tigetstr (Txt); - if Txt2 = Null_Ptr then - Result := False; - elsif Is_MinusOne_Pointer (Txt2) then - raise Curses_Exception; - else - Value := Terminfo_String (Fill_String (Txt2)); - Result := True; - end if; - end Get_String; - ------------------------------------------------------------------------------- - function Has_String (Name : String) return Boolean - is - function tigetstr (id : char_array) return chars_ptr; - pragma Import (C, tigetstr, "tigetstr"); - Txt : char_array (0 .. Name'Length); - Length : size_t; - Txt2 : chars_ptr; - begin - To_C (Name, Txt, Length); - Txt2 := tigetstr (Txt); - if Txt2 = Null_Ptr then - return False; - elsif Is_MinusOne_Pointer (Txt2) then - raise Curses_Exception; - else - return True; - end if; - end Has_String; - ------------------------------------------------------------------------------- - function Get_Number (Name : String) return Integer is - function tigetstr (s : char_array) return C_Int; - pragma Import (C, tigetstr); - Txt : char_array (0 .. Name'Length); - Length : size_t; - begin - To_C (Name, Txt, Length); - return Integer (tigetstr (Txt)); - end Get_Number; - ------------------------------------------------------------------------------- - procedure Put_String (Str : Terminfo_String; - affcnt : Natural := 1; - putc : putctype := null) is - function tputs (str : char_array; - affcnt : C_Int; - putc : putctype) return C_Int; - function putp (str : char_array) return C_Int; - pragma Import (C, tputs); - pragma Import (C, putp); - Txt : char_array (0 .. Str'Length); - Length : size_t; - Err : C_Int; - begin - To_C (String (Str), Txt, Length); - if putc = null then - Err := putp (Txt); - else - Err := tputs (Txt, C_Int (affcnt), putc); - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Put_String; - -end Terminal_Interface.Curses.Terminfo; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.ads deleted file mode 100644 index fb39bf1ed6..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-terminfo.ads +++ /dev/null @@ -1,81 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Terminfo -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.3 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- - -with Interfaces.C; - -package Terminal_Interface.Curses.Terminfo is - pragma Preelaborate (Terminal_Interface.Curses.Terminfo); - - -- |===================================================================== - -- | Man page curs_terminfo.3x - -- |===================================================================== - -- Not implemented: setupterm, setterm, set_curterm, del_curterm, - -- restartterm, tparm, putp, vidputs, vidattr, - -- mvcur - - type Terminfo_String is new String; - - -- | - procedure Get_String (Name : String; - Value : out Terminfo_String; - Result : out Boolean); - function Has_String (Name : String) return Boolean; - -- AKA: tigetstr() - - -- | - function Get_Flag (Name : String) return Boolean; - -- AKA: tigetflag() - - -- | - function Get_Number (Name : String) return Integer; - -- AKA: tigetnum() - - type putctype is access function (c : Interfaces.C.int) - return Interfaces.C.int; - pragma Convention (C, putctype); - - -- | - procedure Put_String (Str : Terminfo_String; - affcnt : Natural := 1; - putc : putctype := null); - -- AKA: tputs() - -end Terminal_Interface.Curses.Terminfo; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.adb deleted file mode 100644 index ecd58e0e06..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.adb +++ /dev/null @@ -1,128 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Aux -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package body Terminal_Interface.Curses.Text_IO.Aux is - - procedure Put_Buf - (Win : in Window; - Buf : in String; - Width : in Field; - Signal : in Boolean := True; - Ljust : in Boolean := False) - is - L : Field; - Len : Field; - W : Field := Width; - LC : Line_Count; - CC : Column_Count; - Y : Line_Position; - X : Column_Position; - - procedure Output (From, To : Field); - - procedure Output (From, To : Field) - is - begin - if Len > 0 then - if W = 0 then - W := Len; - end if; - if Len > W then - -- LRM A10.6 (7) says this - W := Len; - end if; - - pragma Assert (Len <= W); - Get_Size (Win, LC, CC); - if Column_Count (Len) > CC then - if Signal then - raise Layout_Error; - else - return; - end if; - else - if Len < W and then not Ljust then - declare - Filler : constant String (1 .. (W - Len)) - := (others => ' '); - begin - Put (Win, Filler); - end; - end if; - Get_Cursor_Position (Win, Y, X); - if (X + Column_Position (Len)) > CC then - New_Line (Win); - end if; - Put (Win, Buf (From .. To)); - if Len < W and then Ljust then - declare - Filler : constant String (1 .. (W - Len)) - := (others => ' '); - begin - Put (Win, Filler); - end; - end if; - end if; - end if; - end Output; - - begin - pragma Assert (Win /= Null_Window); - if Ljust then - L := 1; - for I in 1 .. Buf'Length loop - exit when Buf (L) = ' '; - L := L + 1; - end loop; - Len := L - 1; - Output (1, Len); - else -- input buffer is not left justified - L := Buf'Length; - for I in 1 .. Buf'Length loop - exit when Buf (L) = ' '; - L := L - 1; - end loop; - Len := Buf'Length - L; - Output (L + 1, Buf'Length); - end if; - end Put_Buf; - -end Terminal_Interface.Curses.Text_IO.Aux; - diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.ads deleted file mode 100644 index e14c2e50a0..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-aux.ads +++ /dev/null @@ -1,55 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Aux -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -private package Terminal_Interface.Curses.Text_IO.Aux is - -- pragma Preelaborate (Aux); - - -- This routine is called from the Text_IO output routines for numeric - -- and enumeration types. - -- - procedure Put_Buf - (Win : in Window; -- The output window - Buf : in String; -- The buffer containing the text - Width : in Field; -- The width of the output field - Signal : in Boolean := True; -- If true, we raise Layout_Error - Ljust : in Boolean := False); -- The Buf is left justified - -end Terminal_Interface.Curses.Text_IO.Aux; - diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.adb deleted file mode 100644 index 3b5871e286..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.adb +++ /dev/null @@ -1,73 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Complex_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Terminal_Interface.Curses.Text_IO.Float_IO; - -package body Terminal_Interface.Curses.Text_IO.Complex_IO is - - package FIO is new - Terminal_Interface.Curses.Text_IO.Float_IO (Complex_Types.Real'Base); - - procedure Put - (Win : in Window; - Item : in Complex; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - begin - Put (Win, '('); - FIO.Put (Win, Item.Re, Fore, Aft, Exp); - Put (Win, ','); - FIO.Put (Win, Item.Im, Fore, Aft, Exp); - Put (Win, ')'); - end Put; - - procedure Put - (Item : in Complex; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - begin - Put (Get_Window, Item, Fore, Aft, Exp); - end Put; - -end Terminal_Interface.Curses.Text_IO.Complex_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.ads deleted file mode 100644 index 233eb3c03b..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-complex_io.ads +++ /dev/null @@ -1,70 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Complex_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Numerics.Generic_Complex_Types; - -generic - with package Complex_Types is new Ada.Numerics.Generic_Complex_Types (<>); - -package Terminal_Interface.Curses.Text_IO.Complex_IO is - - use Complex_Types; - - Default_Fore : Field := 2; - Default_Aft : Field := Real'Digits - 1; - Default_Exp : Field := 3; - - procedure Put - (Win : in Window; - Item : in Complex; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - - procedure Put - (Item : in Complex; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Complex_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.adb deleted file mode 100644 index 02068a06cb..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.adb +++ /dev/null @@ -1,75 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Decimal_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Decimal_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package DIO is new Ada.Text_IO.Decimal_IO (Num); - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - Buf : String (1 .. Field'Last); - Len : Field := Fore + 1 + Aft; - begin - if Exp > 0 then - Len := Len + 1 + Exp; - end if; - DIO.Put (Buf, Item, Aft, Exp); - Aux.Put_Buf (Win, Buf, Len, False); - end Put; - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) is - begin - Put (Get_Window, Item, Fore, Aft, Exp); - end Put; - -end Terminal_Interface.Curses.Text_IO.Decimal_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.ads deleted file mode 100644 index 6f6fe75b26..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-decimal_io.ads +++ /dev/null @@ -1,66 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Decimal_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Num is delta <> digits <>; - -package Terminal_Interface.Curses.Text_IO.Decimal_IO is - - Default_Fore : Field := Num'Fore; - Default_Aft : Field := Num'Aft; - Default_Exp : Field := 0; - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Decimal_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.adb deleted file mode 100644 index 528873a9e6..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.adb +++ /dev/null @@ -1,80 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Enumeration_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Ada.Characters.Handling; use Ada.Characters.Handling; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Enumeration_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package EIO is new Ada.Text_IO.Enumeration_IO (Enum); - - procedure Put - (Win : in Window; - Item : in Enum; - Width : in Field := Default_Width; - Set : in Type_Set := Default_Setting) - is - Buf : String (1 .. Field'Last); - Tset : Ada.Text_IO.Type_Set; - begin - if Set /= Mixed_Case then - Tset := Ada.Text_IO.Type_Set'Val (Type_Set'Pos (Set)); - else - Tset := Ada.Text_IO.Lower_Case; - end if; - EIO.Put (Buf, Item, Tset); - if Set = Mixed_Case then - Buf (Buf'First) := To_Upper (Buf (Buf'First)); - end if; - Aux.Put_Buf (Win, Buf, Width, True, True); - end Put; - - procedure Put - (Item : in Enum; - Width : in Field := Default_Width; - Set : in Type_Set := Default_Setting) - is - begin - Put (Get_Window, Item, Width, Set); - end Put; - -end Terminal_Interface.Curses.Text_IO.Enumeration_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.ads deleted file mode 100644 index b221d7ff38..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-enumeration_io.ads +++ /dev/null @@ -1,63 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Enumeration_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Enum is (<>); - -package Terminal_Interface.Curses.Text_IO.Enumeration_IO is - - Default_Width : Field := 0; - Default_Setting : Type_Set := Mixed_Case; - - procedure Put - (Win : in Window; - Item : in Enum; - Width : in Field := Default_Width; - Set : in Type_Set := Default_Setting); - - procedure Put - (Item : in Enum; - Width : in Field := Default_Width; - Set : in Type_Set := Default_Setting); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Enumeration_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.adb deleted file mode 100644 index e74f148736..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.adb +++ /dev/null @@ -1,75 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Fixed_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Fixed_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package FIXIO is new Ada.Text_IO.Fixed_IO (Num); - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - Buf : String (1 .. Field'Last); - Len : Field := Fore + 1 + Aft; - begin - if Exp > 0 then - Len := Len + 1 + Exp; - end if; - FIXIO.Put (Buf, Item, Aft, Exp); - Aux.Put_Buf (Win, Buf, Len, False); - end Put; - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) is - begin - Put (Get_Window, Item, Fore, Aft, Exp); - end Put; - -end Terminal_Interface.Curses.Text_IO.Fixed_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.ads deleted file mode 100644 index 4b8b136657..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-fixed_io.ads +++ /dev/null @@ -1,66 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Fixed_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Num is delta <>; - -package Terminal_Interface.Curses.Text_IO.Fixed_IO is - - Default_Fore : Field := Num'Fore; - Default_Aft : Field := Num'Aft; - Default_Exp : Field := 0; - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Fixed_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.adb deleted file mode 100644 index 19d261b7a8..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.adb +++ /dev/null @@ -1,76 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Float_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Float_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package FIO is new Ada.Text_IO.Float_IO (Num); - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - Buf : String (1 .. Field'Last); - Len : Field := Fore + 1 + Aft; - begin - if Exp > 0 then - Len := Len + 1 + Exp; - end if; - FIO.Put (Buf, Item, Aft, Exp); - Aux.Put_Buf (Win, Buf, Len, False); - end Put; - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp) - is - begin - Put (Get_Window, Item, Fore, Aft, Exp); - end Put; - -end Terminal_Interface.Curses.Text_IO.Float_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.ads deleted file mode 100644 index 0856523543..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-float_io.ads +++ /dev/null @@ -1,66 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Float_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Num is digits <>; - -package Terminal_Interface.Curses.Text_IO.Float_IO is - - Default_Fore : Field := 2; - Default_Aft : Field := Num'Digits - 1; - Default_Exp : Field := 3; - - procedure Put - (Win : in Window; - Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - - procedure Put - (Item : in Num; - Fore : in Field := Default_Fore; - Aft : in Field := Default_Aft; - Exp : in Field := Default_Exp); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Float_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.adb deleted file mode 100644 index e694e082ea..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.adb +++ /dev/null @@ -1,70 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Integer_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Integer_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package IIO is new Ada.Text_IO.Integer_IO (Num); - - procedure Put - (Win : in Window; - Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base) - is - Buf : String (1 .. Field'Last); - begin - IIO.Put (Buf, Item, Base); - Aux.Put_Buf (Win, Buf, Width); - end Put; - - procedure Put - (Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base) - is - begin - Put (Get_Window, Item, Width, Base); - end Put; - -end Terminal_Interface.Curses.Text_IO.Integer_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.ads deleted file mode 100644 index d8b169a740..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-integer_io.ads +++ /dev/null @@ -1,63 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Integer_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Num is range <>; - -package Terminal_Interface.Curses.Text_IO.Integer_IO is - - Default_Width : Field := Num'Width; - Default_Base : Number_Base := 10; - - procedure Put - (Win : in Window; - Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base); - - procedure Put - (Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Integer_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.adb deleted file mode 100644 index 8cc1d4a616..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.adb +++ /dev/null @@ -1,70 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Modular_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.10 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Terminal_Interface.Curses.Text_IO.Aux; - -package body Terminal_Interface.Curses.Text_IO.Modular_IO is - - package Aux renames Terminal_Interface.Curses.Text_IO.Aux; - package MIO is new Ada.Text_IO.Modular_IO (Num); - - procedure Put - (Win : in Window; - Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base) - is - Buf : String (1 .. Field'Last); - begin - MIO.Put (Buf, Item, Base); - Aux.Put_Buf (Win, Buf, Width); - end Put; - - procedure Put - (Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base) - is - begin - Put (Get_Window, Item, Width, Base); - end Put; - -end Terminal_Interface.Curses.Text_IO.Modular_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.ads deleted file mode 100644 index 618706fc51..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io-modular_io.ads +++ /dev/null @@ -1,63 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO.Modular_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.11 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -generic - type Num is mod <>; - -package Terminal_Interface.Curses.Text_IO.Modular_IO is - - Default_Width : Field := Num'Width; - Default_Base : Number_Base := 10; - - procedure Put - (Win : in Window; - Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base); - - procedure Put - (Item : in Num; - Width : in Field := Default_Width; - Base : in Number_Base := Default_Base); - -private - pragma Inline (Put); - -end Terminal_Interface.Curses.Text_IO.Modular_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.adb deleted file mode 100644 index cbf1d54098..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.adb +++ /dev/null @@ -1,336 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.14 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package body Terminal_Interface.Curses.Text_IO is - - Default_Window : Window := Null_Window; - - procedure Set_Window (Win : in Window) - is - begin - Default_Window := Win; - end Set_Window; - - function Get_Window return Window - is - begin - if Default_Window = Null_Window then - return Standard_Window; - else - return Default_Window; - end if; - end Get_Window; - pragma Inline (Get_Window); - - procedure Flush (Win : in Window) - is - begin - Refresh (Win); - end Flush; - - procedure Flush - is - begin - Flush (Get_Window); - end Flush; - - -------------------------------------------- - -- Specification of line and page lengths -- - -------------------------------------------- - - -- There are no set routines in this package. I assume, that you allocate - -- the window with an appropriate size. - -- A scroll-window is interpreted as an page with unbounded page length, - -- i.e. it returns the conventional 0 as page length. - - function Line_Length (Win : in Window) return Count - is - N_Lines : Line_Count; - N_Cols : Column_Count; - begin - Get_Size (Win, N_Lines, N_Cols); - if Natural (N_Cols) > Natural (Count'Last) then - raise Layout_Error; - end if; - return Count (N_Cols); - end Line_Length; - - function Line_Length return Count - is - begin - return Line_Length (Get_Window); - end Line_Length; - - function Page_Length (Win : in Window) return Count - is - N_Lines : Line_Count; - N_Cols : Column_Count; - begin - if Scrolling_Allowed (Win) then - return 0; - else - Get_Size (Win, N_Lines, N_Cols); - if Natural (N_Lines) > Natural (Count'Last) then - raise Layout_Error; - end if; - return Count (N_Lines); - end if; - end Page_Length; - - function Page_Length return Count - is - begin - return Page_Length (Get_Window); - end Page_Length; - - ------------------------------------ - -- Column, Line, and Page Control -- - ------------------------------------ - procedure New_Line (Win : in Window; Spacing : in Positive_Count := 1) - is - P_Size : constant Count := Page_Length (Win); - begin - if Spacing not in Positive_Count then - raise Constraint_Error; - end if; - - for I in 1 .. Spacing loop - if P_Size > 0 and then Line (Win) >= P_Size then - New_Page (Win); - else - Add (Win, ASCII.LF); - end if; - end loop; - end New_Line; - - procedure New_Line (Spacing : in Positive_Count := 1) - is - begin - New_Line (Get_Window, Spacing); - end New_Line; - - procedure New_Page (Win : in Window) - is - begin - Clear (Win); - end New_Page; - - procedure New_Page - is - begin - New_Page (Get_Window); - end New_Page; - - procedure Set_Col (Win : in Window; To : in Positive_Count) - is - Y : Line_Position; - X1 : Column_Position; - X2 : Column_Position; - N : Natural; - begin - if To not in Positive_Count then - raise Constraint_Error; - end if; - - Get_Cursor_Position (Win, Y, X1); - N := Natural (To); N := N - 1; - X2 := Column_Position (N); - if X1 > X2 then - New_Line (Win, 1); - X1 := 0; - end if; - if X1 < X2 then - declare - Filler : constant String (Integer (X1) .. (Integer (X2) - 1)) - := (others => ' '); - begin - Put (Win, Filler); - end; - end if; - end Set_Col; - - procedure Set_Col (To : in Positive_Count) - is - begin - Set_Col (Get_Window, To); - end Set_Col; - - procedure Set_Line (Win : in Window; To : in Positive_Count) - is - Y1 : Line_Position; - Y2 : Line_Position; - X : Column_Position; - N : Natural; - begin - if To not in Positive_Count then - raise Constraint_Error; - end if; - - Get_Cursor_Position (Win, Y1, X); - N := Natural (To); N := N - 1; - Y2 := Line_Position (N); - if Y2 < Y1 then - New_Page (Win); - Y1 := 0; - end if; - if Y1 < Y2 then - New_Line (Win, Positive_Count (Y2 - Y1)); - end if; - end Set_Line; - - procedure Set_Line (To : in Positive_Count) - is - begin - Set_Line (Get_Window, To); - end Set_Line; - - function Col (Win : in Window) return Positive_Count - is - Y : Line_Position; - X : Column_Position; - N : Natural; - begin - Get_Cursor_Position (Win, Y, X); - N := Natural (X); N := N + 1; - if N > Natural (Count'Last) then - raise Layout_Error; - end if; - return Positive_Count (N); - end Col; - - function Col return Positive_Count - is - begin - return Col (Get_Window); - end Col; - - function Line (Win : in Window) return Positive_Count - is - Y : Line_Position; - X : Column_Position; - N : Natural; - begin - Get_Cursor_Position (Win, Y, X); - N := Natural (Y); N := N + 1; - if N > Natural (Count'Last) then - raise Layout_Error; - end if; - return Positive_Count (N); - end Line; - - function Line return Positive_Count - is - begin - return Line (Get_Window); - end Line; - - ----------------------- - -- Characters Output -- - ----------------------- - - procedure Put (Win : in Window; Item : in Character) - is - P_Size : constant Count := Page_Length (Win); - Y : Line_Position; - X : Column_Position; - L : Line_Count; - C : Column_Count; - begin - if P_Size > 0 then - Get_Cursor_Position (Win, Y, X); - Get_Size (Win, L, C); - if (Y + 1) = L and then (X + 1) = C then - New_Page (Win); - end if; - end if; - Add (Win, Item); - end Put; - - procedure Put (Item : in Character) - is - begin - Put (Get_Window, Item); - end Put; - - -------------------- - -- Strings-Output -- - -------------------- - - procedure Put (Win : in Window; Item : in String) - is - P_Size : constant Count := Page_Length (Win); - Y : Line_Position; - X : Column_Position; - L : Line_Count; - C : Column_Count; - begin - if P_Size > 0 then - Get_Cursor_Position (Win, Y, X); - Get_Size (Win, L, C); - if (Y + 1) = L and then (X + 1 + Item'Length) >= C then - New_Page (Win); - end if; - end if; - Add (Win, Item); - end Put; - - procedure Put (Item : in String) - is - begin - Put (Get_Window, Item); - end Put; - - procedure Put_Line - (Win : in Window; - Item : in String) - is - begin - Put (Win, Item); - New_Line (Win, 1); - end Put_Line; - - procedure Put_Line - (Item : in String) - is - begin - Put_Line (Get_Window, Item); - end Put_Line; - -end Terminal_Interface.Curses.Text_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.ads deleted file mode 100644 index 2f6c48a1ed..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-text_io.ads +++ /dev/null @@ -1,136 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Text_IO -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.13 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with Ada.Text_IO; -with Ada.IO_Exceptions; - -package Terminal_Interface.Curses.Text_IO is - - use type Ada.Text_IO.Count; - subtype Count is Ada.Text_IO.Count; - subtype Positive_Count is Count range 1 .. Count'Last; - - subtype Field is Ada.Text_IO.Field; - subtype Number_Base is Integer range 2 .. 16; - - type Type_Set is (Lower_Case, Upper_Case, Mixed_Case); - - -- For most of the routines you will see a version without a Window - -- type parameter. They will operate on a default window, which can - -- be set by the user. It is initially equal to Standard_Window. - - procedure Set_Window (Win : in Window); - -- Set Win as the default window - - function Get_Window return Window; - -- Get the current default window - - procedure Flush (Win : in Window); - procedure Flush; - - -------------------------------------------- - -- Specification of line and page lengths -- - -------------------------------------------- - - -- There are no set routines in this package. I assume, that you allocate - -- the window with an appropriate size. - -- A scroll-window is interpreted as an page with unbounded page length, - -- i.e. it returns the conventional 0 as page length. - - function Line_Length (Win : in Window) return Count; - function Line_Length return Count; - - function Page_Length (Win : in Window) return Count; - function Page_Length return Count; - - ------------------------------------ - -- Column, Line, and Page Control -- - ------------------------------------ - procedure New_Line (Win : in Window; Spacing : in Positive_Count := 1); - procedure New_Line (Spacing : in Positive_Count := 1); - - procedure New_Page (Win : in Window); - procedure New_Page; - - procedure Set_Col (Win : in Window; To : in Positive_Count); - procedure Set_Col (To : in Positive_Count); - - procedure Set_Line (Win : in Window; To : in Positive_Count); - procedure Set_Line (To : in Positive_Count); - - function Col (Win : in Window) return Positive_Count; - function Col return Positive_Count; - - function Line (Win : in Window) return Positive_Count; - function Line return Positive_Count; - - ----------------------- - -- Characters-Output -- - ----------------------- - - procedure Put (Win : in Window; Item : in Character); - procedure Put (Item : in Character); - - -------------------- - -- Strings-Output -- - -------------------- - - procedure Put (Win : in Window; Item : in String); - procedure Put (Item : in String); - - procedure Put_Line - (Win : in Window; - Item : in String); - - procedure Put_Line - (Item : in String); - - -- Exceptions - - Status_Error : exception renames Ada.IO_Exceptions.Status_Error; - Mode_Error : exception renames Ada.IO_Exceptions.Mode_Error; - Name_Error : exception renames Ada.IO_Exceptions.Name_Error; - Use_Error : exception renames Ada.IO_Exceptions.Use_Error; - Device_Error : exception renames Ada.IO_Exceptions.Device_Error; - End_Error : exception renames Ada.IO_Exceptions.End_Error; - Data_Error : exception renames Ada.IO_Exceptions.Data_Error; - Layout_Error : exception renames Ada.IO_Exceptions.Layout_Error; - -end Terminal_Interface.Curses.Text_IO; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-trace.adb_p b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-trace.adb_p deleted file mode 100644 index 6b510d91a6..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses-trace.adb_p +++ /dev/null @@ -1,91 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses.Trace -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 2000 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.4 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -#if ADA_TRACE then -with Interfaces.C; use Interfaces.C; -with Terminal_Interface.Curses.Aux; use Terminal_Interface.Curses.Aux; -with Ada.Unchecked_Conversion; -#end if; - -package body Terminal_Interface.Curses.Trace is - -#if ADA_TRACE then - type C_TraceType is new C_UInt; - - function TraceAda_To_TraceC is new - Ada.Unchecked_Conversion (Source => Trace_Attribute_Set, - Target => C_TraceType); - - procedure Trace_On (x : Trace_Attribute_Set) is - procedure traceC (y : C_TraceType); - pragma Import (C, traceC, "trace"); - begin - traceC (TraceAda_To_TraceC (x)); - end Trace_On; - - -- 75. (12) A C function that takes a variable number of arguments can - -- correspond to several Ada subprograms, taking various specific - -- numbers and types of parameters. - - procedure Trace_Put (str : String) is - procedure tracef (format : char_array; s : char_array); - pragma Import (C, tracef, "_tracef"); - Txt : char_array (0 .. str'Length); - Length : size_t; - formatstr : constant String := "%s" & ASCII.Nul; - formattxt : char_array (0 .. formatstr'Length); - begin - To_C (formatstr, formattxt, Length); - To_C (str, Txt, Length); - tracef (formattxt, Txt); - end Trace_Put; -#else - procedure Trace_On (x : Trace_Attribute_Set) is - begin - null; - end Trace_On; - - procedure Trace_Put (str : String) is - begin - null; - end Trace_Put; -#end if; - -end Terminal_Interface.Curses.Trace; diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses.adb b/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses.adb deleted file mode 100644 index 0349c80d82..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface-curses.adb +++ /dev/null @@ -1,2560 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface.Curses -- --- -- --- B O D Y -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.29 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -with System; - -with Terminal_Interface.Curses.Aux; -with Interfaces.C; use Interfaces.C; -with Interfaces.C.Strings; use Interfaces.C.Strings; -with Interfaces.C.Pointers; -with Ada.Characters.Handling; use Ada.Characters.Handling; -with Ada.Strings.Fixed; -with Ada.Unchecked_Conversion; - -package body Terminal_Interface.Curses is - - use Aux; - use type System.Bit_Order; - - package ASF renames Ada.Strings.Fixed; - - type chtype_array is array (size_t range <>) - of aliased Attributed_Character; - pragma Convention (C, chtype_array); - ------------------------------------------------------------------------------- - generic - type Element is (<>); - function W_Get_Element (Win : in Window; - Offset : in Natural) return Element; - - function W_Get_Element (Win : in Window; - Offset : in Natural) return Element is - type E_Array is array (Natural range <>) of aliased Element; - package C_E_Array is new - Interfaces.C.Pointers (Natural, Element, E_Array, Element'Val (0)); - use C_E_Array; - - function To_Pointer is new - Ada.Unchecked_Conversion (Window, Pointer); - - P : Pointer := To_Pointer (Win); - begin - if Win = Null_Window then - raise Curses_Exception; - else - P := P + ptrdiff_t (Offset); - return P.all; - end if; - end W_Get_Element; - - function W_Get_Int is new W_Get_Element (C_Int); - function W_Get_Short is new W_Get_Element (C_Short); - function W_Get_Byte is new W_Get_Element (Interfaces.C.unsigned_char); - - function Get_Flag (Win : Window; - Offset : Natural) return Boolean; - - function Get_Flag (Win : Window; - Offset : Natural) return Boolean - is - Res : C_Int; - begin - case Sizeof_bool is - when 1 => Res := C_Int (W_Get_Byte (Win, Offset)); - when 2 => Res := C_Int (W_Get_Short (Win, Offset)); - when 4 => Res := C_Int (W_Get_Int (Win, Offset)); - when others => raise Curses_Exception; - end case; - - case Res is - when 0 => return False; - when others => return True; - end case; - end Get_Flag; - ------------------------------------------------------------------------------- - function Key_Name (Key : in Real_Key_Code) return String - is - function Keyname (K : C_Int) return chars_ptr; - pragma Import (C, Keyname, "keyname"); - - Ch : Character; - begin - if Key <= Character'Pos (Character'Last) then - Ch := Character'Val (Key); - if Is_Control (Ch) then - return Un_Control (Attributed_Character'(Ch => Ch, - Color => Color_Pair'First, - Attr => Normal_Video)); - elsif Is_Graphic (Ch) then - declare - S : String (1 .. 1); - begin - S (1) := Ch; - return S; - end; - else - return ""; - end if; - else - return Fill_String (Keyname (C_Int (Key))); - end if; - end Key_Name; - - procedure Key_Name (Key : in Real_Key_Code; - Name : out String) - is - begin - ASF.Move (Key_Name (Key), Name); - end Key_Name; - ------------------------------------------------------------------------------- - procedure Init_Screen - is - function Initscr return Window; - pragma Import (C, Initscr, "initscr"); - - W : Window; - begin - W := Initscr; - if W = Null_Window then - raise Curses_Exception; - end if; - end Init_Screen; - - procedure End_Windows - is - function Endwin return C_Int; - pragma Import (C, Endwin, "endwin"); - begin - if Endwin = Curses_Err then - raise Curses_Exception; - end if; - end End_Windows; - - function Is_End_Window return Boolean - is - function Isendwin return Curses_Bool; - pragma Import (C, Isendwin, "isendwin"); - begin - if Isendwin = Curses_Bool_False then - return False; - else - return True; - end if; - end Is_End_Window; ------------------------------------------------------------------------------- - procedure Move_Cursor (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position) - is - function Wmove (Win : Window; - Line : C_Int; - Column : C_Int - ) return C_Int; - pragma Import (C, Wmove, "wmove"); - begin - if Wmove (Win, C_Int (Line), C_Int (Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Move_Cursor; ------------------------------------------------------------------------------- - procedure Add (Win : in Window := Standard_Window; - Ch : in Attributed_Character) - is - function Waddch (W : Window; - Ch : C_Chtype) return C_Int; - pragma Import (C, Waddch, "waddch"); - begin - if Waddch (Win, AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Add; - - procedure Add (Win : in Window := Standard_Window; - Ch : in Character) - is - begin - Add (Win, - Attributed_Character'(Ch => Ch, - Color => Color_Pair'First, - Attr => Normal_Video)); - end Add; - - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Attributed_Character) - is - function mvwaddch (W : Window; - Y : C_Int; - X : C_Int; - Ch : C_Chtype) return C_Int; - pragma Import (C, mvwaddch, "mvwaddch"); - begin - if mvwaddch (Win, C_Int (Line), - C_Int (Column), - AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Add; - - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Character) - is - begin - Add (Win, - Line, - Column, - Attributed_Character'(Ch => Ch, - Color => Color_Pair'First, - Attr => Normal_Video)); - end Add; - - procedure Add_With_Immediate_Echo - (Win : in Window := Standard_Window; - Ch : in Attributed_Character) - is - function Wechochar (W : Window; - Ch : C_Chtype) return C_Int; - pragma Import (C, Wechochar, "wechochar"); - begin - if Wechochar (Win, AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Add_With_Immediate_Echo; - - procedure Add_With_Immediate_Echo - (Win : in Window := Standard_Window; - Ch : in Character) - is - begin - Add_With_Immediate_Echo - (Win, - Attributed_Character'(Ch => Ch, - Color => Color_Pair'First, - Attr => Normal_Video)); - end Add_With_Immediate_Echo; ------------------------------------------------------------------------------- - function Create (Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window - is - function Newwin (Number_Of_Lines : C_Int; - Number_Of_Columns : C_Int; - First_Line_Position : C_Int; - First_Column_Position : C_Int) return Window; - pragma Import (C, Newwin, "newwin"); - - W : Window; - begin - W := Newwin (C_Int (Number_Of_Lines), - C_Int (Number_Of_Columns), - C_Int (First_Line_Position), - C_Int (First_Column_Position)); - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end Create; - - procedure Delete (Win : in out Window) - is - function Wdelwin (W : Window) return C_Int; - pragma Import (C, Wdelwin, "delwin"); - begin - if Wdelwin (Win) = Curses_Err then - raise Curses_Exception; - end if; - Win := Null_Window; - end Delete; - - function Sub_Window - (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window - is - function Subwin - (Win : Window; - Number_Of_Lines : C_Int; - Number_Of_Columns : C_Int; - First_Line_Position : C_Int; - First_Column_Position : C_Int) return Window; - pragma Import (C, Subwin, "subwin"); - - W : Window; - begin - W := Subwin (Win, - C_Int (Number_Of_Lines), - C_Int (Number_Of_Columns), - C_Int (First_Line_Position), - C_Int (First_Column_Position)); - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end Sub_Window; - - function Derived_Window - (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window - is - function Derwin - (Win : Window; - Number_Of_Lines : C_Int; - Number_Of_Columns : C_Int; - First_Line_Position : C_Int; - First_Column_Position : C_Int) return Window; - pragma Import (C, Derwin, "derwin"); - - W : Window; - begin - W := Derwin (Win, - C_Int (Number_Of_Lines), - C_Int (Number_Of_Columns), - C_Int (First_Line_Position), - C_Int (First_Column_Position)); - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end Derived_Window; - - function Duplicate (Win : Window) return Window - is - function Dupwin (Win : Window) return Window; - pragma Import (C, Dupwin, "dupwin"); - - W : Window := Dupwin (Win); - begin - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end Duplicate; - - procedure Move_Window (Win : in Window; - Line : in Line_Position; - Column : in Column_Position) - is - function Mvwin (Win : Window; - Line : C_Int; - Column : C_Int) return C_Int; - pragma Import (C, Mvwin, "mvwin"); - begin - if Mvwin (Win, C_Int (Line), C_Int (Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Move_Window; - - procedure Move_Derived_Window (Win : in Window; - Line : in Line_Position; - Column : in Column_Position) - is - function Mvderwin (Win : Window; - Line : C_Int; - Column : C_Int) return C_Int; - pragma Import (C, Mvderwin, "mvderwin"); - begin - if Mvderwin (Win, C_Int (Line), C_Int (Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Move_Derived_Window; - - procedure Set_Synch_Mode (Win : in Window := Standard_Window; - Mode : in Boolean := False) - is - function Syncok (Win : Window; - Mode : Curses_Bool) return C_Int; - pragma Import (C, Syncok, "syncok"); - begin - if Syncok (Win, Curses_Bool (Boolean'Pos (Mode))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Synch_Mode; ------------------------------------------------------------------------------- - procedure Add (Win : in Window := Standard_Window; - Str : in String; - Len : in Integer := -1) - is - function Waddnstr (Win : Window; - Str : char_array; - Len : C_Int := -1) return C_Int; - pragma Import (C, Waddnstr, "waddnstr"); - - Txt : char_array (0 .. Str'Length); - Length : size_t; - begin - To_C (Str, Txt, Length); - if Waddnstr (Win, Txt, C_Int (Len)) = Curses_Err then - raise Curses_Exception; - end if; - end Add; - - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in String; - Len : in Integer := -1) - is - begin - Move_Cursor (Win, Line, Column); - Add (Win, Str, Len); - end Add; ------------------------------------------------------------------------------- - procedure Add - (Win : in Window := Standard_Window; - Str : in Attributed_String; - Len : in Integer := -1) - is - function Waddchnstr (Win : Window; - Str : chtype_array; - Len : C_Int := -1) return C_Int; - pragma Import (C, Waddchnstr, "waddchnstr"); - - Txt : chtype_array (0 .. Str'Length); - begin - for Length in 1 .. size_t (Str'Length) loop - Txt (Length - 1) := Str (Natural (Length)); - end loop; - Txt (Str'Length) := Default_Character; - if Waddchnstr (Win, - Txt, - C_Int (Len)) = Curses_Err then - raise Curses_Exception; - end if; - end Add; - - procedure Add - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in Attributed_String; - Len : in Integer := -1) - is - begin - Move_Cursor (Win, Line, Column); - Add (Win, Str, Len); - end Add; ------------------------------------------------------------------------------- - procedure Border - (Win : in Window := Standard_Window; - Left_Side_Symbol : in Attributed_Character := Default_Character; - Right_Side_Symbol : in Attributed_Character := Default_Character; - Top_Side_Symbol : in Attributed_Character := Default_Character; - Bottom_Side_Symbol : in Attributed_Character := Default_Character; - Upper_Left_Corner_Symbol : in Attributed_Character := Default_Character; - Upper_Right_Corner_Symbol : in Attributed_Character := Default_Character; - Lower_Left_Corner_Symbol : in Attributed_Character := Default_Character; - Lower_Right_Corner_Symbol : in Attributed_Character := Default_Character) - is - function Wborder (W : Window; - LS : C_Chtype; - RS : C_Chtype; - TS : C_Chtype; - BS : C_Chtype; - ULC : C_Chtype; - URC : C_Chtype; - LLC : C_Chtype; - LRC : C_Chtype) return C_Int; - pragma Import (C, Wborder, "wborder"); - begin - if Wborder (Win, - AttrChar_To_Chtype (Left_Side_Symbol), - AttrChar_To_Chtype (Right_Side_Symbol), - AttrChar_To_Chtype (Top_Side_Symbol), - AttrChar_To_Chtype (Bottom_Side_Symbol), - AttrChar_To_Chtype (Upper_Left_Corner_Symbol), - AttrChar_To_Chtype (Upper_Right_Corner_Symbol), - AttrChar_To_Chtype (Lower_Left_Corner_Symbol), - AttrChar_To_Chtype (Lower_Right_Corner_Symbol) - ) = Curses_Err - then - raise Curses_Exception; - end if; - end Border; - - procedure Box - (Win : in Window := Standard_Window; - Vertical_Symbol : in Attributed_Character := Default_Character; - Horizontal_Symbol : in Attributed_Character := Default_Character) - is - begin - Border (Win, - Vertical_Symbol, Vertical_Symbol, - Horizontal_Symbol, Horizontal_Symbol); - end Box; - - procedure Horizontal_Line - (Win : in Window := Standard_Window; - Line_Size : in Natural; - Line_Symbol : in Attributed_Character := Default_Character) - is - function Whline (W : Window; - Ch : C_Chtype; - Len : C_Int) return C_Int; - pragma Import (C, Whline, "whline"); - begin - if Whline (Win, - AttrChar_To_Chtype (Line_Symbol), - C_Int (Line_Size)) = Curses_Err then - raise Curses_Exception; - end if; - end Horizontal_Line; - - procedure Vertical_Line - (Win : in Window := Standard_Window; - Line_Size : in Natural; - Line_Symbol : in Attributed_Character := Default_Character) - is - function Wvline (W : Window; - Ch : C_Chtype; - Len : C_Int) return C_Int; - pragma Import (C, Wvline, "wvline"); - begin - if Wvline (Win, - AttrChar_To_Chtype (Line_Symbol), - C_Int (Line_Size)) = Curses_Err then - raise Curses_Exception; - end if; - end Vertical_Line; - ------------------------------------------------------------------------------- - function Get_Keystroke (Win : Window := Standard_Window) - return Real_Key_Code - is - function Wgetch (W : Window) return C_Int; - pragma Import (C, Wgetch, "wgetch"); - - C : constant C_Int := Wgetch (Win); - begin - if C = Curses_Err then - return Key_None; - else - return Real_Key_Code (C); - end if; - end Get_Keystroke; - - procedure Undo_Keystroke (Key : in Real_Key_Code) - is - function Ungetch (Ch : C_Int) return C_Int; - pragma Import (C, Ungetch, "ungetch"); - begin - if Ungetch (C_Int (Key)) = Curses_Err then - raise Curses_Exception; - end if; - end Undo_Keystroke; - - function Has_Key (Key : Special_Key_Code) return Boolean - is - function Haskey (Key : C_Int) return C_Int; - pragma Import (C, Haskey, "has_key"); - begin - if Haskey (C_Int (Key)) = Curses_False then - return False; - else - return True; - end if; - end Has_Key; - - function Is_Function_Key (Key : Special_Key_Code) return Boolean - is - L : constant Special_Key_Code := Special_Key_Code (Natural (Key_F0) + - Natural (Function_Key_Number'Last)); - begin - if (Key >= Key_F0) and then (Key <= L) then - return True; - else - return False; - end if; - end Is_Function_Key; - - function Function_Key (Key : Real_Key_Code) - return Function_Key_Number - is - begin - if Is_Function_Key (Key) then - return Function_Key_Number (Key - Key_F0); - else - raise Constraint_Error; - end if; - end Function_Key; - - function Function_Key_Code (Key : Function_Key_Number) return Real_Key_Code - is - begin - return Real_Key_Code (Natural (Key_F0) + Natural (Key)); - end Function_Key_Code; ------------------------------------------------------------------------------- - procedure Standout (Win : Window := Standard_Window; - On : Boolean := True) - is - function wstandout (Win : Window) return C_Int; - pragma Import (C, wstandout, "wstandout"); - function wstandend (Win : Window) return C_Int; - pragma Import (C, wstandend, "wstandend"); - - Err : C_Int; - begin - if On then - Err := wstandout (Win); - else - Err := wstandend (Win); - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Standout; - - procedure Switch_Character_Attribute - (Win : in Window := Standard_Window; - Attr : in Character_Attribute_Set := Normal_Video; - On : in Boolean := True) - is - function Wattron (Win : Window; - C_Attr : C_AttrType) return C_Int; - pragma Import (C, Wattron, "wattr_on"); - function Wattroff (Win : Window; - C_Attr : C_AttrType) return C_Int; - pragma Import (C, Wattroff, "wattr_off"); - -- In Ada we use the On Boolean to control whether or not we want to - -- switch on or off the attributes in the set. - Err : C_Int; - AC : constant Attributed_Character := (Ch => Character'First, - Color => Color_Pair'First, - Attr => Attr); - begin - if On then - Err := Wattron (Win, AttrChar_To_AttrType (AC)); - else - Err := Wattroff (Win, AttrChar_To_AttrType (AC)); - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Switch_Character_Attribute; - - procedure Set_Character_Attributes - (Win : in Window := Standard_Window; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Wattrset (Win : Window; - C_Attr : C_AttrType) return C_Int; - pragma Import (C, Wattrset, "wattrset"); -- ??? wattr_set - begin - if Wattrset (Win, - AttrChar_To_AttrType (Attributed_Character' - (Ch => Character'First, - Color => Color, - Attr => Attr))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Character_Attributes; - - function Get_Character_Attribute (Win : Window := Standard_Window) - return Character_Attribute_Set - is - function Wattrget (Win : Window; - Atr : access C_AttrType; - Col : access C_Short; - Opt : System.Address) return C_Int; - pragma Import (C, Wattrget, "wattr_get"); - - Attr : aliased C_AttrType; - Col : aliased C_Short; - Res : constant C_Int := Wattrget (Win, Attr'Access, Col'Access, - System.Null_Address); - Ch : Attributed_Character; - begin - if Res = Curses_Ok then - Ch := AttrType_To_AttrChar (Attr); - return Ch.Attr; - else - raise Curses_Exception; - end if; - end Get_Character_Attribute; - - function Get_Character_Attribute (Win : Window := Standard_Window) - return Color_Pair - is - function Wattrget (Win : Window; - Atr : access C_AttrType; - Col : access C_Short; - Opt : System.Address) return C_Int; - pragma Import (C, Wattrget, "wattr_get"); - - Attr : aliased C_AttrType; - Col : aliased C_Short; - Res : constant C_Int := Wattrget (Win, Attr'Access, Col'Access, - System.Null_Address); - Ch : Attributed_Character; - begin - if Res = Curses_Ok then - Ch := AttrType_To_AttrChar (Attr); - return Ch.Color; - else - raise Curses_Exception; - end if; - end Get_Character_Attribute; - - procedure Set_Color (Win : in Window := Standard_Window; - Pair : in Color_Pair) - is - function Wset_Color (Win : Window; - Color : C_Short; - Opts : C_Void_Ptr) return C_Int; - pragma Import (C, Wset_Color, "wcolor_set"); - begin - if Wset_Color (Win, - C_Short (Pair), - C_Void_Ptr (System.Null_Address)) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Color; - - procedure Change_Attributes - (Win : in Window := Standard_Window; - Count : in Integer := -1; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Wchgat (Win : Window; - Cnt : C_Int; - Attr : C_AttrType; - Color : C_Short; - Opts : System.Address := System.Null_Address) - return C_Int; - pragma Import (C, Wchgat, "wchgat"); - - Ch : constant Attributed_Character := - (Ch => Character'First, Color => Color_Pair'First, Attr => Attr); - begin - if Wchgat (Win, C_Int (Count), AttrChar_To_AttrType (Ch), - C_Short (Color)) = Curses_Err then - raise Curses_Exception; - end if; - end Change_Attributes; - - procedure Change_Attributes - (Win : in Window := Standard_Window; - Line : in Line_Position := Line_Position'First; - Column : in Column_Position := Column_Position'First; - Count : in Integer := -1; - Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - begin - Move_Cursor (Win, Line, Column); - Change_Attributes (Win, Count, Attr, Color); - end Change_Attributes; ------------------------------------------------------------------------------- - procedure Beep - is - function Beeper return C_Int; - pragma Import (C, Beeper, "beep"); - begin - if Beeper = Curses_Err then - raise Curses_Exception; - end if; - end Beep; - - procedure Flash_Screen - is - function Flash return C_Int; - pragma Import (C, Flash, "flash"); - begin - if Flash = Curses_Err then - raise Curses_Exception; - end if; - end Flash_Screen; ------------------------------------------------------------------------------- - procedure Set_Cbreak_Mode (SwitchOn : in Boolean := True) - is - function Cbreak return C_Int; - pragma Import (C, Cbreak, "cbreak"); - function NoCbreak return C_Int; - pragma Import (C, NoCbreak, "nocbreak"); - - Err : C_Int; - begin - if SwitchOn then - Err := Cbreak; - else - Err := NoCbreak; - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Set_Cbreak_Mode; - - procedure Set_Raw_Mode (SwitchOn : in Boolean := True) - is - function Raw return C_Int; - pragma Import (C, Raw, "raw"); - function NoRaw return C_Int; - pragma Import (C, NoRaw, "noraw"); - - Err : C_Int; - begin - if SwitchOn then - Err := Raw; - else - Err := NoRaw; - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Set_Raw_Mode; - - procedure Set_Echo_Mode (SwitchOn : in Boolean := True) - is - function Echo return C_Int; - pragma Import (C, Echo, "echo"); - function NoEcho return C_Int; - pragma Import (C, NoEcho, "noecho"); - - Err : C_Int; - begin - if SwitchOn then - Err := Echo; - else - Err := NoEcho; - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Set_Echo_Mode; - - procedure Set_Meta_Mode (Win : in Window := Standard_Window; - SwitchOn : in Boolean := True) - is - function Meta (W : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Meta, "meta"); - begin - if Meta (Win, Curses_Bool (Boolean'Pos (SwitchOn))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Meta_Mode; - - procedure Set_KeyPad_Mode (Win : in Window := Standard_Window; - SwitchOn : in Boolean := True) - is - function Keypad (W : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Keypad, "keypad"); - begin - if Keypad (Win, Curses_Bool (Boolean'Pos (SwitchOn))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_KeyPad_Mode; - - function Get_KeyPad_Mode (Win : in Window := Standard_Window) - return Boolean - is - begin - return Get_Flag (Win, Offset_use_keypad); - end Get_KeyPad_Mode; - - procedure Half_Delay (Amount : in Half_Delay_Amount) - is - function Halfdelay (Amount : C_Int) return C_Int; - pragma Import (C, Halfdelay, "halfdelay"); - begin - if Halfdelay (C_Int (Amount)) = Curses_Err then - raise Curses_Exception; - end if; - end Half_Delay; - - procedure Set_Flush_On_Interrupt_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := True) - is - function Intrflush (Win : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Intrflush, "intrflush"); - begin - if Intrflush (Win, Curses_Bool (Boolean'Pos (Mode))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Flush_On_Interrupt_Mode; - - procedure Set_Queue_Interrupt_Mode - (Win : in Window := Standard_Window; - Flush : in Boolean := True) - is - procedure Qiflush; - pragma Import (C, Qiflush, "qiflush"); - procedure No_Qiflush; - pragma Import (C, No_Qiflush, "noqiflush"); - begin - if Flush then - Qiflush; - else - No_Qiflush; - end if; - end Set_Queue_Interrupt_Mode; - - procedure Set_NoDelay_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := False) - is - function Nodelay (Win : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Nodelay, "nodelay"); - begin - if Nodelay (Win, Curses_Bool (Boolean'Pos (Mode))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_NoDelay_Mode; - - procedure Set_Timeout_Mode (Win : in Window := Standard_Window; - Mode : in Timeout_Mode; - Amount : in Natural) - is - function Wtimeout (Win : Window; Amount : C_Int) return C_Int; - pragma Import (C, Wtimeout, "wtimeout"); - - Time : C_Int; - begin - case Mode is - when Blocking => Time := -1; - when Non_Blocking => Time := 0; - when Delayed => - if Amount = 0 then - raise Constraint_Error; - end if; - Time := C_Int (Amount); - end case; - if Wtimeout (Win, Time) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Timeout_Mode; - - procedure Set_Escape_Timer_Mode - (Win : in Window := Standard_Window; - Timer_Off : in Boolean := False) - is - function Notimeout (Win : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Notimeout, "notimeout"); - begin - if Notimeout (Win, Curses_Bool (Boolean'Pos (Timer_Off))) - = Curses_Err then - raise Curses_Exception; - end if; - end Set_Escape_Timer_Mode; - ------------------------------------------------------------------------------- - procedure Set_NL_Mode (SwitchOn : in Boolean := True) - is - function NL return C_Int; - pragma Import (C, NL, "nl"); - function NoNL return C_Int; - pragma Import (C, NoNL, "nonl"); - - Err : C_Int; - begin - if SwitchOn then - Err := NL; - else - Err := NoNL; - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Set_NL_Mode; - - procedure Clear_On_Next_Update - (Win : in Window := Standard_Window; - Do_Clear : in Boolean := True) - is - function Clear_Ok (W : Window; Flag : Curses_Bool) return C_Int; - pragma Import (C, Clear_Ok, "clearok"); - begin - if Clear_Ok (Win, Curses_Bool (Boolean'Pos (Do_Clear))) = Curses_Err then - raise Curses_Exception; - end if; - end Clear_On_Next_Update; - - procedure Use_Insert_Delete_Line - (Win : in Window := Standard_Window; - Do_Idl : in Boolean := True) - is - function IDL_Ok (W : Window; Flag : Curses_Bool) return C_Int; - pragma Import (C, IDL_Ok, "idlok"); - begin - if IDL_Ok (Win, Curses_Bool (Boolean'Pos (Do_Idl))) = Curses_Err then - raise Curses_Exception; - end if; - end Use_Insert_Delete_Line; - - procedure Use_Insert_Delete_Character - (Win : in Window := Standard_Window; - Do_Idc : in Boolean := True) - is - function IDC_Ok (W : Window; Flag : Curses_Bool) return C_Int; - pragma Import (C, IDC_Ok, "idcok"); - begin - if IDC_Ok (Win, Curses_Bool (Boolean'Pos (Do_Idc))) = Curses_Err then - raise Curses_Exception; - end if; - end Use_Insert_Delete_Character; - - procedure Leave_Cursor_After_Update - (Win : in Window := Standard_Window; - Do_Leave : in Boolean := True) - is - function Leave_Ok (W : Window; Flag : Curses_Bool) return C_Int; - pragma Import (C, Leave_Ok, "leaveok"); - begin - if Leave_Ok (Win, Curses_Bool (Boolean'Pos (Do_Leave))) = Curses_Err then - raise Curses_Exception; - end if; - end Leave_Cursor_After_Update; - - procedure Immediate_Update_Mode - (Win : in Window := Standard_Window; - Mode : in Boolean := False) - is - function Immedok (Win : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Immedok, "immedok"); - begin - if Immedok (Win, Curses_Bool (Boolean'Pos (Mode))) = Curses_Err then - raise Curses_Exception; - end if; - end Immediate_Update_Mode; - - procedure Allow_Scrolling - (Win : in Window := Standard_Window; - Mode : in Boolean := False) - is - function Scrollok (Win : Window; Mode : Curses_Bool) return C_Int; - pragma Import (C, Scrollok, "scrollok"); - begin - if Scrollok (Win, Curses_Bool (Boolean'Pos (Mode))) = Curses_Err then - raise Curses_Exception; - end if; - end Allow_Scrolling; - - function Scrolling_Allowed (Win : Window := Standard_Window) - return Boolean - is - begin - return Get_Flag (Win, Offset_scroll); - end Scrolling_Allowed; - - procedure Set_Scroll_Region - (Win : in Window := Standard_Window; - Top_Line : in Line_Position; - Bottom_Line : in Line_Position) - is - function Wsetscrreg (Win : Window; - Lin : C_Int; - Col : C_Int) return C_Int; - pragma Import (C, Wsetscrreg, "wsetscrreg"); - begin - if Wsetscrreg (Win, C_Int (Top_Line), C_Int (Bottom_Line)) - = Curses_Err then - raise Curses_Exception; - end if; - end Set_Scroll_Region; ------------------------------------------------------------------------------- - procedure Update_Screen - is - function Do_Update return C_Int; - pragma Import (C, Do_Update, "doupdate"); - begin - if Do_Update = Curses_Err then - raise Curses_Exception; - end if; - end Update_Screen; - - procedure Refresh (Win : in Window := Standard_Window) - is - function Wrefresh (W : Window) return C_Int; - pragma Import (C, Wrefresh, "wrefresh"); - begin - if Wrefresh (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Refresh; - - procedure Refresh_Without_Update - (Win : in Window := Standard_Window) - is - function Wnoutrefresh (W : Window) return C_Int; - pragma Import (C, Wnoutrefresh, "wnoutrefresh"); - begin - if Wnoutrefresh (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Refresh_Without_Update; - - procedure Redraw (Win : in Window := Standard_Window) - is - function Redrawwin (Win : Window) return C_Int; - pragma Import (C, Redrawwin, "redrawwin"); - begin - if Redrawwin (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Redraw; - - procedure Redraw - (Win : in Window := Standard_Window; - Begin_Line : in Line_Position; - Line_Count : in Positive) - is - function Wredrawln (Win : Window; First : C_Int; Cnt : C_Int) - return C_Int; - pragma Import (C, Wredrawln, "wredrawln"); - begin - if Wredrawln (Win, - C_Int (Begin_Line), - C_Int (Line_Count)) = Curses_Err then - raise Curses_Exception; - end if; - end Redraw; - ------------------------------------------------------------------------------- - procedure Erase (Win : in Window := Standard_Window) - is - function Werase (W : Window) return C_Int; - pragma Import (C, Werase, "werase"); - begin - if Werase (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Erase; - - procedure Clear (Win : in Window := Standard_Window) - is - function Wclear (W : Window) return C_Int; - pragma Import (C, Wclear, "wclear"); - begin - if Wclear (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Clear; - - procedure Clear_To_End_Of_Screen (Win : in Window := Standard_Window) - is - function Wclearbot (W : Window) return C_Int; - pragma Import (C, Wclearbot, "wclrtobot"); - begin - if Wclearbot (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Clear_To_End_Of_Screen; - - procedure Clear_To_End_Of_Line (Win : in Window := Standard_Window) - is - function Wcleareol (W : Window) return C_Int; - pragma Import (C, Wcleareol, "wclrtoeol"); - begin - if Wcleareol (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Clear_To_End_Of_Line; ------------------------------------------------------------------------------- - procedure Set_Background - (Win : in Window := Standard_Window; - Ch : in Attributed_Character) - is - procedure WBackground (W : in Window; Ch : in C_Chtype); - pragma Import (C, WBackground, "wbkgdset"); - begin - WBackground (Win, AttrChar_To_Chtype (Ch)); - end Set_Background; - - procedure Change_Background - (Win : in Window := Standard_Window; - Ch : in Attributed_Character) - is - function WChangeBkgd (W : Window; Ch : C_Chtype) return C_Int; - pragma Import (C, WChangeBkgd, "wbkgd"); - begin - if WChangeBkgd (Win, AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Change_Background; - - function Get_Background (Win : Window := Standard_Window) - return Attributed_Character - is - function Wgetbkgd (Win : Window) return C_Chtype; - pragma Import (C, Wgetbkgd, "getbkgd"); - begin - return Chtype_To_AttrChar (Wgetbkgd (Win)); - end Get_Background; ------------------------------------------------------------------------------- - procedure Change_Lines_Status (Win : in Window := Standard_Window; - Start : in Line_Position; - Count : in Positive; - State : in Boolean) - is - function Wtouchln (Win : Window; - Sta : C_Int; - Cnt : C_Int; - Chg : C_Int) return C_Int; - pragma Import (C, Wtouchln, "wtouchln"); - begin - if Wtouchln (Win, C_Int (Start), C_Int (Count), - C_Int (Boolean'Pos (State))) = Curses_Err then - raise Curses_Exception; - end if; - end Change_Lines_Status; - - procedure Touch (Win : in Window := Standard_Window) - is - Y : Line_Position; - X : Column_Position; - begin - Get_Size (Win, Y, X); - Change_Lines_Status (Win, 0, Positive (Y), True); - end Touch; - - procedure Untouch (Win : in Window := Standard_Window) - is - Y : Line_Position; - X : Column_Position; - begin - Get_Size (Win, Y, X); - Change_Lines_Status (Win, 0, Positive (Y), False); - end Untouch; - - procedure Touch (Win : in Window := Standard_Window; - Start : in Line_Position; - Count : in Positive) - is - begin - Change_Lines_Status (Win, Start, Count, True); - end Touch; - - function Is_Touched - (Win : Window := Standard_Window; - Line : Line_Position) return Boolean - is - function WLineTouched (W : Window; L : C_Int) return Curses_Bool; - pragma Import (C, WLineTouched, "is_linetouched"); - begin - if WLineTouched (Win, C_Int (Line)) = Curses_Bool_False then - return False; - else - return True; - end if; - end Is_Touched; - - function Is_Touched - (Win : Window := Standard_Window) return Boolean - is - function WWinTouched (W : Window) return Curses_Bool; - pragma Import (C, WWinTouched, "is_wintouched"); - begin - if WWinTouched (Win) = Curses_Bool_False then - return False; - else - return True; - end if; - end Is_Touched; ------------------------------------------------------------------------------- - procedure Copy - (Source_Window : in Window; - Destination_Window : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position; - Non_Destructive_Mode : in Boolean := True) - is - function Copywin (Src : Window; - Dst : Window; - Str : C_Int; - Slc : C_Int; - Dtr : C_Int; - Dlc : C_Int; - Dbr : C_Int; - Drc : C_Int; - Ndm : C_Int) return C_Int; - pragma Import (C, Copywin, "copywin"); - begin - if Copywin (Source_Window, - Destination_Window, - C_Int (Source_Top_Row), - C_Int (Source_Left_Column), - C_Int (Destination_Top_Row), - C_Int (Destination_Left_Column), - C_Int (Destination_Bottom_Row), - C_Int (Destination_Right_Column), - Boolean'Pos (Non_Destructive_Mode) - ) = Curses_Err then - raise Curses_Exception; - end if; - end Copy; - - procedure Overwrite - (Source_Window : in Window; - Destination_Window : in Window) - is - function Overwrite (Src : Window; Dst : Window) return C_Int; - pragma Import (C, Overwrite, "overwrite"); - begin - if Overwrite (Source_Window, Destination_Window) = Curses_Err then - raise Curses_Exception; - end if; - end Overwrite; - - procedure Overlay - (Source_Window : in Window; - Destination_Window : in Window) - is - function Overlay (Src : Window; Dst : Window) return C_Int; - pragma Import (C, Overlay, "overlay"); - begin - if Overlay (Source_Window, Destination_Window) = Curses_Err then - raise Curses_Exception; - end if; - end Overlay; - ------------------------------------------------------------------------------- - procedure Insert_Delete_Lines - (Win : in Window := Standard_Window; - Lines : in Integer := 1) -- default is to insert one line above - is - function Winsdelln (W : Window; N : C_Int) return C_Int; - pragma Import (C, Winsdelln, "winsdelln"); - begin - if Winsdelln (Win, C_Int (Lines)) = Curses_Err then - raise Curses_Exception; - end if; - end Insert_Delete_Lines; - - procedure Delete_Line (Win : in Window := Standard_Window) - is - begin - Insert_Delete_Lines (Win, -1); - end Delete_Line; - - procedure Insert_Line (Win : in Window := Standard_Window) - is - begin - Insert_Delete_Lines (Win, 1); - end Insert_Line; ------------------------------------------------------------------------------- - - - procedure Get_Size - (Win : in Window := Standard_Window; - Number_Of_Lines : out Line_Count; - Number_Of_Columns : out Column_Count) - is - -- Please note: in ncurses they are one off. - -- This might be different in other implementations of curses - Y : C_Int := C_Int (W_Get_Short (Win, Offset_maxy)) + C_Int (Offset_XY); - X : C_Int := C_Int (W_Get_Short (Win, Offset_maxx)) + C_Int (Offset_XY); - begin - Number_Of_Lines := Line_Count (Y); - Number_Of_Columns := Column_Count (X); - end Get_Size; - - procedure Get_Window_Position - (Win : in Window := Standard_Window; - Top_Left_Line : out Line_Position; - Top_Left_Column : out Column_Position) - is - Y : C_Short := W_Get_Short (Win, Offset_begy); - X : C_Short := W_Get_Short (Win, Offset_begx); - begin - Top_Left_Line := Line_Position (Y); - Top_Left_Column := Column_Position (X); - end Get_Window_Position; - - procedure Get_Cursor_Position - (Win : in Window := Standard_Window; - Line : out Line_Position; - Column : out Column_Position) - is - Y : C_Short := W_Get_Short (Win, Offset_cury); - X : C_Short := W_Get_Short (Win, Offset_curx); - begin - Line := Line_Position (Y); - Column := Column_Position (X); - end Get_Cursor_Position; - - procedure Get_Origin_Relative_To_Parent - (Win : in Window; - Top_Left_Line : out Line_Position; - Top_Left_Column : out Column_Position; - Is_Not_A_Subwindow : out Boolean) - is - Y : C_Int := W_Get_Int (Win, Offset_pary); - X : C_Int := W_Get_Int (Win, Offset_parx); - begin - if Y = -1 then - Top_Left_Line := Line_Position'Last; - Top_Left_Column := Column_Position'Last; - Is_Not_A_Subwindow := True; - else - Top_Left_Line := Line_Position (Y); - Top_Left_Column := Column_Position (X); - Is_Not_A_Subwindow := False; - end if; - end Get_Origin_Relative_To_Parent; ------------------------------------------------------------------------------- - function New_Pad (Lines : Line_Count; - Columns : Column_Count) return Window - is - function Newpad (Lines : C_Int; Columns : C_Int) return Window; - pragma Import (C, Newpad, "newpad"); - - W : Window; - begin - W := Newpad (C_Int (Lines), C_Int (Columns)); - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end New_Pad; - - function Sub_Pad - (Pad : Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count; - First_Line_Position : Line_Position; - First_Column_Position : Column_Position) return Window - is - function Subpad - (Pad : Window; - Number_Of_Lines : C_Int; - Number_Of_Columns : C_Int; - First_Line_Position : C_Int; - First_Column_Position : C_Int) return Window; - pragma Import (C, Subpad, "subpad"); - - W : Window; - begin - W := Subpad (Pad, - C_Int (Number_Of_Lines), - C_Int (Number_Of_Columns), - C_Int (First_Line_Position), - C_Int (First_Column_Position)); - if W = Null_Window then - raise Curses_Exception; - end if; - return W; - end Sub_Pad; - - procedure Refresh - (Pad : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position) - is - function Prefresh - (Pad : Window; - Source_Top_Row : C_Int; - Source_Left_Column : C_Int; - Destination_Top_Row : C_Int; - Destination_Left_Column : C_Int; - Destination_Bottom_Row : C_Int; - Destination_Right_Column : C_Int) return C_Int; - pragma Import (C, Prefresh, "prefresh"); - begin - if Prefresh (Pad, - C_Int (Source_Top_Row), - C_Int (Source_Left_Column), - C_Int (Destination_Top_Row), - C_Int (Destination_Left_Column), - C_Int (Destination_Bottom_Row), - C_Int (Destination_Right_Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Refresh; - - procedure Refresh_Without_Update - (Pad : in Window; - Source_Top_Row : in Line_Position; - Source_Left_Column : in Column_Position; - Destination_Top_Row : in Line_Position; - Destination_Left_Column : in Column_Position; - Destination_Bottom_Row : in Line_Position; - Destination_Right_Column : in Column_Position) - is - function Pnoutrefresh - (Pad : Window; - Source_Top_Row : C_Int; - Source_Left_Column : C_Int; - Destination_Top_Row : C_Int; - Destination_Left_Column : C_Int; - Destination_Bottom_Row : C_Int; - Destination_Right_Column : C_Int) return C_Int; - pragma Import (C, Pnoutrefresh, "pnoutrefresh"); - begin - if Pnoutrefresh (Pad, - C_Int (Source_Top_Row), - C_Int (Source_Left_Column), - C_Int (Destination_Top_Row), - C_Int (Destination_Left_Column), - C_Int (Destination_Bottom_Row), - C_Int (Destination_Right_Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Refresh_Without_Update; - - procedure Add_Character_To_Pad_And_Echo_It - (Pad : in Window; - Ch : in Attributed_Character) - is - function Pechochar (Pad : Window; Ch : C_Chtype) - return C_Int; - pragma Import (C, Pechochar, "pechochar"); - begin - if Pechochar (Pad, AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Add_Character_To_Pad_And_Echo_It; - - procedure Add_Character_To_Pad_And_Echo_It - (Pad : in Window; - Ch : in Character) - is - begin - Add_Character_To_Pad_And_Echo_It - (Pad, - Attributed_Character'(Ch => Ch, - Color => Color_Pair'First, - Attr => Normal_Video)); - end Add_Character_To_Pad_And_Echo_It; ------------------------------------------------------------------------------- - procedure Scroll (Win : in Window := Standard_Window; - Amount : in Integer := 1) - is - function Wscrl (Win : Window; N : C_Int) return C_Int; - pragma Import (C, Wscrl, "wscrl"); - - begin - if Wscrl (Win, C_Int (Amount)) = Curses_Err then - raise Curses_Exception; - end if; - end Scroll; - ------------------------------------------------------------------------------- - procedure Delete_Character (Win : in Window := Standard_Window) - is - function Wdelch (Win : Window) return C_Int; - pragma Import (C, Wdelch, "wdelch"); - begin - if Wdelch (Win) = Curses_Err then - raise Curses_Exception; - end if; - end Delete_Character; - - procedure Delete_Character - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position) - is - function Mvwdelch (Win : Window; - Lin : C_Int; - Col : C_Int) return C_Int; - pragma Import (C, Mvwdelch, "mvwdelch"); - begin - if Mvwdelch (Win, C_Int (Line), C_Int (Column)) = Curses_Err then - raise Curses_Exception; - end if; - end Delete_Character; ------------------------------------------------------------------------------- - function Peek (Win : Window := Standard_Window) - return Attributed_Character - is - function Winch (Win : Window) return C_Chtype; - pragma Import (C, Winch, "winch"); - begin - return Chtype_To_AttrChar (Winch (Win)); - end Peek; - - function Peek - (Win : Window := Standard_Window; - Line : Line_Position; - Column : Column_Position) return Attributed_Character - is - function Mvwinch (Win : Window; - Lin : C_Int; - Col : C_Int) return C_Chtype; - pragma Import (C, Mvwinch, "mvwinch"); - begin - return Chtype_To_AttrChar (Mvwinch (Win, C_Int (Line), C_Int (Column))); - end Peek; ------------------------------------------------------------------------------- - procedure Insert (Win : in Window := Standard_Window; - Ch : in Attributed_Character) - is - function Winsch (Win : Window; Ch : C_Chtype) return C_Int; - pragma Import (C, Winsch, "winsch"); - begin - if Winsch (Win, AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Insert; - - procedure Insert - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Ch : in Attributed_Character) - is - function Mvwinsch (Win : Window; - Lin : C_Int; - Col : C_Int; - Ch : C_Chtype) return C_Int; - pragma Import (C, Mvwinsch, "mvwinsch"); - begin - if Mvwinsch (Win, - C_Int (Line), - C_Int (Column), - AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Insert; ------------------------------------------------------------------------------- - procedure Insert (Win : in Window := Standard_Window; - Str : in String; - Len : in Integer := -1) - is - function Winsnstr (Win : Window; - Str : char_array; - Len : Integer := -1) return C_Int; - pragma Import (C, Winsnstr, "winsnstr"); - - Txt : char_array (0 .. Str'Length); - Length : size_t; - begin - To_C (Str, Txt, Length); - if Winsnstr (Win, Txt, Len) = Curses_Err then - raise Curses_Exception; - end if; - end Insert; - - procedure Insert - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : in String; - Len : in Integer := -1) - is - function Mvwinsnstr (Win : Window; - Line : C_Int; - Column : C_Int; - Str : char_array; - Len : C_Int) return C_Int; - pragma Import (C, Mvwinsnstr, "mvwinsnstr"); - - Txt : char_array (0 .. Str'Length); - Length : size_t; - begin - To_C (Str, Txt, Length); - if Mvwinsnstr (Win, C_Int (Line), C_Int (Column), Txt, C_Int (Len)) - = Curses_Err then - raise Curses_Exception; - end if; - end Insert; ------------------------------------------------------------------------------- - procedure Peek (Win : in Window := Standard_Window; - Str : out String; - Len : in Integer := -1) - is - function Winnstr (Win : Window; - Str : char_array; - Len : C_Int) return C_Int; - pragma Import (C, Winnstr, "winnstr"); - - N : Integer := Len; - Txt : char_array (0 .. Str'Length); - Cnt : Natural; - begin - if N < 0 then - N := Str'Length; - end if; - if N > Str'Length then - raise Constraint_Error; - end if; - Txt (0) := Interfaces.C.char'First; - if Winnstr (Win, Txt, C_Int (N)) = Curses_Err then - raise Curses_Exception; - end if; - To_Ada (Txt, Str, Cnt, True); - if Cnt < Str'Length then - Str ((Str'First + Cnt) .. Str'Last) := (others => ' '); - end if; - end Peek; - - procedure Peek - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out String; - Len : in Integer := -1) - is - begin - Move_Cursor (Win, Line, Column); - Peek (Win, Str, Len); - end Peek; ------------------------------------------------------------------------------- - procedure Peek - (Win : in Window := Standard_Window; - Str : out Attributed_String; - Len : in Integer := -1) - is - function Winchnstr (Win : Window; - Str : chtype_array; -- out - Len : C_Int) return C_Int; - pragma Import (C, Winchnstr, "winchnstr"); - - N : Integer := Len; - Txt : chtype_array (0 .. Str'Length) := (0 => Default_Character); - Cnt : Natural := 0; - begin - if N < 0 then - N := Str'Length; - end if; - if N > Str'Length then - raise Constraint_Error; - end if; - if Winchnstr (Win, Txt, C_Int (N)) = Curses_Err then - raise Curses_Exception; - end if; - for To in Str'Range loop - exit when Txt (size_t (Cnt)) = Default_Character; - Str (To) := Txt (size_t (Cnt)); - Cnt := Cnt + 1; - end loop; - if Cnt < Str'Length then - Str ((Str'First + Cnt) .. Str'Last) := - (others => (Ch => ' ', - Color => Color_Pair'First, - Attr => Normal_Video)); - end if; - end Peek; - - procedure Peek - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out Attributed_String; - Len : in Integer := -1) - is - begin - Move_Cursor (Win, Line, Column); - Peek (Win, Str, Len); - end Peek; ------------------------------------------------------------------------------- - procedure Get (Win : in Window := Standard_Window; - Str : out String; - Len : in Integer := -1) - is - function Wgetnstr (Win : Window; - Str : char_array; - Len : C_Int) return C_Int; - pragma Import (C, Wgetnstr, "wgetnstr"); - - N : Integer := Len; - Txt : char_array (0 .. Str'Length); - Cnt : Natural; - begin - if N < 0 then - N := Str'Length; - end if; - if N > Str'Length then - raise Constraint_Error; - end if; - Txt (0) := Interfaces.C.char'First; - if Wgetnstr (Win, Txt, C_Int (N)) = Curses_Err then - raise Curses_Exception; - end if; - To_Ada (Txt, Str, Cnt, True); - if Cnt < Str'Length then - Str ((Str'First + Cnt) .. Str'Last) := (others => ' '); - end if; - end Get; - - procedure Get - (Win : in Window := Standard_Window; - Line : in Line_Position; - Column : in Column_Position; - Str : out String; - Len : in Integer := -1) - is - begin - Move_Cursor (Win, Line, Column); - Get (Win, Str, Len); - end Get; ------------------------------------------------------------------------------- - procedure Init_Soft_Label_Keys - (Format : in Soft_Label_Key_Format := Three_Two_Three) - is - function Slk_Init (Fmt : C_Int) return C_Int; - pragma Import (C, Slk_Init, "slk_init"); - begin - if Slk_Init (Soft_Label_Key_Format'Pos (Format)) = Curses_Err then - raise Curses_Exception; - end if; - end Init_Soft_Label_Keys; - - procedure Set_Soft_Label_Key (Label : in Label_Number; - Text : in String; - Fmt : in Label_Justification := Left) - is - function Slk_Set (Label : C_Int; - Txt : char_array; - Fmt : C_Int) return C_Int; - pragma Import (C, Slk_Set, "slk_set"); - - Txt : char_array (0 .. Text'Length); - Len : size_t; - begin - To_C (Text, Txt, Len); - if Slk_Set (C_Int (Label), Txt, - C_Int (Label_Justification'Pos (Fmt))) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Soft_Label_Key; - - procedure Refresh_Soft_Label_Keys - is - function Slk_Refresh return C_Int; - pragma Import (C, Slk_Refresh, "slk_refresh"); - begin - if Slk_Refresh = Curses_Err then - raise Curses_Exception; - end if; - end Refresh_Soft_Label_Keys; - - procedure Refresh_Soft_Label_Keys_Without_Update - is - function Slk_Noutrefresh return C_Int; - pragma Import (C, Slk_Noutrefresh, "slk_noutrefresh"); - begin - if Slk_Noutrefresh = Curses_Err then - raise Curses_Exception; - end if; - end Refresh_Soft_Label_Keys_Without_Update; - - procedure Get_Soft_Label_Key (Label : in Label_Number; - Text : out String) - is - function Slk_Label (Label : C_Int) return chars_ptr; - pragma Import (C, Slk_Label, "slk_label"); - begin - Fill_String (Slk_Label (C_Int (Label)), Text); - end Get_Soft_Label_Key; - - function Get_Soft_Label_Key (Label : in Label_Number) return String - is - function Slk_Label (Label : C_Int) return chars_ptr; - pragma Import (C, Slk_Label, "slk_label"); - begin - return Fill_String (Slk_Label (C_Int (Label))); - end Get_Soft_Label_Key; - - procedure Clear_Soft_Label_Keys - is - function Slk_Clear return C_Int; - pragma Import (C, Slk_Clear, "slk_clear"); - begin - if Slk_Clear = Curses_Err then - raise Curses_Exception; - end if; - end Clear_Soft_Label_Keys; - - procedure Restore_Soft_Label_Keys - is - function Slk_Restore return C_Int; - pragma Import (C, Slk_Restore, "slk_restore"); - begin - if Slk_Restore = Curses_Err then - raise Curses_Exception; - end if; - end Restore_Soft_Label_Keys; - - procedure Touch_Soft_Label_Keys - is - function Slk_Touch return C_Int; - pragma Import (C, Slk_Touch, "slk_touch"); - begin - if Slk_Touch = Curses_Err then - raise Curses_Exception; - end if; - end Touch_Soft_Label_Keys; - - procedure Switch_Soft_Label_Key_Attributes - (Attr : in Character_Attribute_Set; - On : in Boolean := True) - is - function Slk_Attron (Ch : C_Chtype) return C_Int; - pragma Import (C, Slk_Attron, "slk_attron"); - function Slk_Attroff (Ch : C_Chtype) return C_Int; - pragma Import (C, Slk_Attroff, "slk_attroff"); - - Err : C_Int; - Ch : constant Attributed_Character := (Ch => Character'First, - Attr => Attr, - Color => Color_Pair'First); - begin - if On then - Err := Slk_Attron (AttrChar_To_Chtype (Ch)); - else - Err := Slk_Attroff (AttrChar_To_Chtype (Ch)); - end if; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Switch_Soft_Label_Key_Attributes; - - procedure Set_Soft_Label_Key_Attributes - (Attr : in Character_Attribute_Set := Normal_Video; - Color : in Color_Pair := Color_Pair'First) - is - function Slk_Attrset (Ch : C_Chtype) return C_Int; - pragma Import (C, Slk_Attrset, "slk_attrset"); - - Ch : constant Attributed_Character := (Ch => Character'First, - Attr => Attr, - Color => Color); - begin - if Slk_Attrset (AttrChar_To_Chtype (Ch)) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Soft_Label_Key_Attributes; - - function Get_Soft_Label_Key_Attributes return Character_Attribute_Set - is - function Slk_Attr return C_Chtype; - pragma Import (C, Slk_Attr, "slk_attr"); - - Attr : constant C_Chtype := Slk_Attr; - begin - return Chtype_To_AttrChar (Attr).Attr; - end Get_Soft_Label_Key_Attributes; - - function Get_Soft_Label_Key_Attributes return Color_Pair - is - function Slk_Attr return C_Chtype; - pragma Import (C, Slk_Attr, "slk_attr"); - - Attr : constant C_Chtype := Slk_Attr; - begin - return Chtype_To_AttrChar (Attr).Color; - end Get_Soft_Label_Key_Attributes; - - procedure Set_Soft_Label_Key_Color (Pair : in Color_Pair) - is - function Slk_Color (Color : in C_Short) return C_Int; - pragma Import (C, Slk_Color, "slk_color"); - begin - if Slk_Color (C_Short (Pair)) = Curses_Err then - raise Curses_Exception; - end if; - end Set_Soft_Label_Key_Color; - ------------------------------------------------------------------------------- - procedure Enable_Key (Key : in Special_Key_Code; - Enable : in Boolean := True) - is - function Keyok (Keycode : C_Int; - On_Off : Curses_Bool) return C_Int; - pragma Import (C, Keyok, "keyok"); - begin - if Keyok (C_Int (Key), Curses_Bool (Boolean'Pos (Enable))) - = Curses_Err then - raise Curses_Exception; - end if; - end Enable_Key; ------------------------------------------------------------------------------- - procedure Define_Key (Definition : in String; - Key : in Special_Key_Code) - is - function Defkey (Def : char_array; - Key : C_Int) return C_Int; - pragma Import (C, Defkey, "define_key"); - - Txt : char_array (0 .. Definition'Length); - Length : size_t; - begin - To_C (Definition, Txt, Length); - if Defkey (Txt, C_Int (Key)) = Curses_Err then - raise Curses_Exception; - end if; - end Define_Key; ------------------------------------------------------------------------------- - procedure Un_Control (Ch : in Attributed_Character; - Str : out String) - is - function Unctrl (Ch : C_Chtype) return chars_ptr; - pragma Import (C, Unctrl, "unctrl"); - begin - Fill_String (Unctrl (AttrChar_To_Chtype (Ch)), Str); - end Un_Control; - - function Un_Control (Ch : in Attributed_Character) return String - is - function Unctrl (Ch : C_Chtype) return chars_ptr; - pragma Import (C, Unctrl, "unctrl"); - begin - return Fill_String (Unctrl (AttrChar_To_Chtype (Ch))); - end Un_Control; - - procedure Delay_Output (Msecs : in Natural) - is - function Delayoutput (Msecs : C_Int) return C_Int; - pragma Import (C, Delayoutput, "delay_output"); - begin - if Delayoutput (C_Int (Msecs)) = Curses_Err then - raise Curses_Exception; - end if; - end Delay_Output; - - procedure Flush_Input - is - function Flushinp return C_Int; - pragma Import (C, Flushinp, "flushinp"); - begin - if Flushinp = Curses_Err then -- docu says that never happens, but... - raise Curses_Exception; - end if; - end Flush_Input; ------------------------------------------------------------------------------- - function Baudrate return Natural - is - function Baud return C_Int; - pragma Import (C, Baud, "baudrate"); - begin - return Natural (Baud); - end Baudrate; - - function Erase_Character return Character - is - function Erasechar return C_Int; - pragma Import (C, Erasechar, "erasechar"); - begin - return Character'Val (Erasechar); - end Erase_Character; - - function Kill_Character return Character - is - function Killchar return C_Int; - pragma Import (C, Killchar, "killchar"); - begin - return Character'Val (Killchar); - end Kill_Character; - - function Has_Insert_Character return Boolean - is - function Has_Ic return Curses_Bool; - pragma Import (C, Has_Ic, "has_ic"); - begin - if Has_Ic = Curses_Bool_False then - return False; - else - return True; - end if; - end Has_Insert_Character; - - function Has_Insert_Line return Boolean - is - function Has_Il return Curses_Bool; - pragma Import (C, Has_Il, "has_il"); - begin - if Has_Il = Curses_Bool_False then - return False; - else - return True; - end if; - end Has_Insert_Line; - - function Supported_Attributes return Character_Attribute_Set - is - function Termattrs return C_Chtype; - pragma Import (C, Termattrs, "termattrs"); - - Ch : constant Attributed_Character := Chtype_To_AttrChar (Termattrs); - begin - return Ch.Attr; - end Supported_Attributes; - - procedure Long_Name (Name : out String) - is - function Longname return chars_ptr; - pragma Import (C, Longname, "longname"); - begin - Fill_String (Longname, Name); - end Long_Name; - - function Long_Name return String - is - function Longname return chars_ptr; - pragma Import (C, Longname, "longname"); - begin - return Fill_String (Longname); - end Long_Name; - - procedure Terminal_Name (Name : out String) - is - function Termname return chars_ptr; - pragma Import (C, Termname, "termname"); - begin - Fill_String (Termname, Name); - end Terminal_Name; - - function Terminal_Name return String - is - function Termname return chars_ptr; - pragma Import (C, Termname, "termname"); - begin - return Fill_String (Termname); - end Terminal_Name; ------------------------------------------------------------------------------- - procedure Init_Pair (Pair : in Redefinable_Color_Pair; - Fore : in Color_Number; - Back : in Color_Number) - is - function Initpair (Pair : C_Short; - Fore : C_Short; - Back : C_Short) return C_Int; - pragma Import (C, Initpair, "init_pair"); - begin - if Integer (Pair) >= Number_Of_Color_Pairs then - raise Constraint_Error; - end if; - if Integer (Fore) >= Number_Of_Colors or else - Integer (Back) >= Number_Of_Colors then raise Constraint_Error; - end if; - if Initpair (C_Short (Pair), C_Short (Fore), C_Short (Back)) - = Curses_Err then - raise Curses_Exception; - end if; - end Init_Pair; - - procedure Pair_Content (Pair : in Color_Pair; - Fore : out Color_Number; - Back : out Color_Number) - is - type C_Short_Access is access all C_Short; - function Paircontent (Pair : C_Short; - Fp : C_Short_Access; - Bp : C_Short_Access) return C_Int; - pragma Import (C, Paircontent, "pair_content"); - - F, B : aliased C_Short; - begin - if Paircontent (C_Short (Pair), F'Access, B'Access) = Curses_Err then - raise Curses_Exception; - else - Fore := Color_Number (F); - Back := Color_Number (B); - end if; - end Pair_Content; - - function Has_Colors return Boolean - is - function Hascolors return Curses_Bool; - pragma Import (C, Hascolors, "has_colors"); - begin - if Hascolors = Curses_Bool_False then - return False; - else - return True; - end if; - end Has_Colors; - - procedure Init_Color (Color : in Color_Number; - Red : in RGB_Value; - Green : in RGB_Value; - Blue : in RGB_Value) - is - function Initcolor (Col : C_Short; - Red : C_Short; - Green : C_Short; - Blue : C_Short) return C_Int; - pragma Import (C, Initcolor, "init_color"); - begin - if Initcolor (C_Short (Color), C_Short (Red), C_Short (Green), - C_Short (Blue)) = Curses_Err then - raise Curses_Exception; - end if; - end Init_Color; - - function Can_Change_Color return Boolean - is - function Canchangecolor return Curses_Bool; - pragma Import (C, Canchangecolor, "can_change_color"); - begin - if Canchangecolor = Curses_Bool_False then - return False; - else - return True; - end if; - end Can_Change_Color; - - procedure Color_Content (Color : in Color_Number; - Red : out RGB_Value; - Green : out RGB_Value; - Blue : out RGB_Value) - is - type C_Short_Access is access all C_Short; - - function Colorcontent (Color : C_Short; R, G, B : C_Short_Access) - return C_Int; - pragma Import (C, Colorcontent, "color_content"); - - R, G, B : aliased C_Short; - begin - if Colorcontent (C_Short (Color), R'Access, G'Access, B'Access) = - Curses_Err then - raise Curses_Exception; - else - Red := RGB_Value (R); - Green := RGB_Value (G); - Blue := RGB_Value (B); - end if; - end Color_Content; - ------------------------------------------------------------------------------- - procedure Save_Curses_Mode (Mode : in Curses_Mode) - is - function Def_Prog_Mode return C_Int; - pragma Import (C, Def_Prog_Mode, "def_prog_mode"); - function Def_Shell_Mode return C_Int; - pragma Import (C, Def_Shell_Mode, "def_shell_mode"); - - Err : C_Int; - begin - case Mode is - when Curses => Err := Def_Prog_Mode; - when Shell => Err := Def_Shell_Mode; - end case; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Save_Curses_Mode; - - procedure Reset_Curses_Mode (Mode : in Curses_Mode) - is - function Reset_Prog_Mode return C_Int; - pragma Import (C, Reset_Prog_Mode, "reset_prog_mode"); - function Reset_Shell_Mode return C_Int; - pragma Import (C, Reset_Shell_Mode, "reset_shell_mode"); - - Err : C_Int; - begin - case Mode is - when Curses => Err := Reset_Prog_Mode; - when Shell => Err := Reset_Shell_Mode; - end case; - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Reset_Curses_Mode; - - procedure Save_Terminal_State - is - function Savetty return C_Int; - pragma Import (C, Savetty, "savetty"); - begin - if Savetty = Curses_Err then - raise Curses_Exception; - end if; - end Save_Terminal_State; - - procedure Reset_Terminal_State - is - function Resetty return C_Int; - pragma Import (C, Resetty, "resetty"); - begin - if Resetty = Curses_Err then - raise Curses_Exception; - end if; - end Reset_Terminal_State; - - procedure Rip_Off_Lines (Lines : in Integer; - Proc : in Stdscr_Init_Proc) - is - function Ripoffline (Lines : C_Int; - Proc : Stdscr_Init_Proc) return C_Int; - pragma Import (C, Ripoffline, "_nc_ripoffline"); - begin - if Ripoffline (C_Int (Lines), Proc) = Curses_Err then - raise Curses_Exception; - end if; - end Rip_Off_Lines; - - procedure Set_Cursor_Visibility (Visibility : in out Cursor_Visibility) - is - function Curs_Set (Curs : C_Int) return C_Int; - pragma Import (C, Curs_Set, "curs_set"); - - Res : C_Int; - begin - Res := Curs_Set (Cursor_Visibility'Pos (Visibility)); - if Res /= Curses_Err then - Visibility := Cursor_Visibility'Val (Res); - end if; - end Set_Cursor_Visibility; - - procedure Nap_Milli_Seconds (Ms : in Natural) - is - function Napms (Ms : C_Int) return C_Int; - pragma Import (C, Napms, "napms"); - begin - if Napms (C_Int (Ms)) = Curses_Err then - raise Curses_Exception; - end if; - end Nap_Milli_Seconds; ------------------------------------------------------------------------------- - - function Standard_Window return Window - is - Stdscr : Window; - pragma Import (C, Stdscr, "stdscr"); - begin - return Stdscr; - end Standard_Window; - - function Lines return Line_Count - is - C_Lines : C_Int; - pragma Import (C, C_Lines, "LINES"); - begin - return Line_Count (C_Lines); - end Lines; - - function Columns return Column_Count - is - C_Columns : C_Int; - pragma Import (C, C_Columns, "COLS"); - begin - return Column_Count (C_Columns); - end Columns; - - function Tab_Size return Natural - is - C_Tab_Size : C_Int; - pragma Import (C, C_Tab_Size, "TABSIZE"); - begin - return Natural (C_Tab_Size); - end Tab_Size; - - function Number_Of_Colors return Natural - is - C_Number_Of_Colors : C_Int; - pragma Import (C, C_Number_Of_Colors, "COLORS"); - begin - return Natural (C_Number_Of_Colors); - end Number_Of_Colors; - - function Number_Of_Color_Pairs return Natural - is - C_Number_Of_Color_Pairs : C_Int; - pragma Import (C, C_Number_Of_Color_Pairs, "COLOR_PAIRS"); - begin - return Natural (C_Number_Of_Color_Pairs); - end Number_Of_Color_Pairs; ------------------------------------------------------------------------------- - procedure Transform_Coordinates - (W : in Window := Standard_Window; - Line : in out Line_Position; - Column : in out Column_Position; - Dir : in Transform_Direction := From_Screen) - is - type Int_Access is access all C_Int; - function Transform (W : Window; - Y, X : Int_Access; - Dir : Curses_Bool) return C_Int; - pragma Import (C, Transform, "wmouse_trafo"); - - X : aliased C_Int := C_Int (Column); - Y : aliased C_Int := C_Int (Line); - D : Curses_Bool := Curses_Bool_False; - R : C_Int; - begin - if Dir = To_Screen then - D := 1; - end if; - R := Transform (W, Y'Access, X'Access, D); - if R = Curses_False then - raise Curses_Exception; - else - Line := Line_Position (Y); - Column := Column_Position (X); - end if; - end Transform_Coordinates; ------------------------------------------------------------------------------- - procedure Use_Default_Colors is - function C_Use_Default_Colors return C_Int; - pragma Import (C, C_Use_Default_Colors, "use_default_colors"); - Err : constant C_Int := C_Use_Default_Colors; - begin - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Use_Default_Colors; - - procedure Assume_Default_Colors (Fore : Color_Number := Default_Color; - Back : Color_Number := Default_Color) - is - function C_Assume_Default_Colors (Fore : C_Int; - Back : C_Int) return C_Int; - pragma Import (C, C_Assume_Default_Colors, "assume_default_colors"); - - Err : constant C_Int := C_Assume_Default_Colors (C_Int (Fore), - C_Int (Black)); - begin - if Err = Curses_Err then - raise Curses_Exception; - end if; - end Assume_Default_Colors; ------------------------------------------------------------------------------- - function Curses_Version return String - is - function curses_versionC return chars_ptr; - pragma Import (C, curses_versionC, "curses_version"); - Result : constant chars_ptr := curses_versionC; - begin - return Fill_String (Result); - end Curses_Version; ------------------------------------------------------------------------------- - function Use_Extended_Names (Enable : Boolean) return Boolean - is - function use_extended_namesC (e : Curses_Bool) return C_Int; - pragma Import (C, use_extended_namesC, "use_extended_names"); - - Res : constant C_Int := - use_extended_namesC (Curses_Bool (Boolean'Pos (Enable))); - begin - if Res = C_Int (Curses_Bool_False) then - return False; - else - return True; - end if; - end Use_Extended_Names; ------------------------------------------------------------------------------- - procedure Screen_Dump_To_File (Filename : in String) - is - function scr_dump (f : char_array) return C_Int; - pragma Import (C, scr_dump, "scr_dump"); - Txt : char_array (0 .. Filename'Length); - Length : size_t; - begin - To_C (Filename, Txt, Length); - if Curses_Err = scr_dump (Txt) then - raise Curses_Exception; - end if; - end Screen_Dump_To_File; - - procedure Screen_Restore_From_File (Filename : in String) - is - function scr_restore (f : char_array) return C_Int; - pragma Import (C, scr_restore, "scr_restore"); - Txt : char_array (0 .. Filename'Length); - Length : size_t; - begin - To_C (Filename, Txt, Length); - if Curses_Err = scr_restore (Txt) then - raise Curses_Exception; - end if; - end Screen_Restore_From_File; - - procedure Screen_Init_From_File (Filename : in String) - is - function scr_init (f : char_array) return C_Int; - pragma Import (C, scr_init, "scr_init"); - Txt : char_array (0 .. Filename'Length); - Length : size_t; - begin - To_C (Filename, Txt, Length); - if Curses_Err = scr_init (Txt) then - raise Curses_Exception; - end if; - end Screen_Init_From_File; - - procedure Screen_Set_File (Filename : in String) - is - function scr_set (f : char_array) return C_Int; - pragma Import (C, scr_set, "scr_set"); - Txt : char_array (0 .. Filename'Length); - Length : size_t; - begin - To_C (Filename, Txt, Length); - if Curses_Err = scr_set (Txt) then - raise Curses_Exception; - end if; - end Screen_Set_File; ------------------------------------------------------------------------------- - procedure Resize (Win : Window := Standard_Window; - Number_Of_Lines : Line_Count; - Number_Of_Columns : Column_Count) is - function wresize (win : Window; - lines : C_Int; - columns : C_Int) return C_Int; - pragma Import (C, wresize); - begin - if wresize (Win, - C_Int (Number_Of_Lines), - C_Int (Number_Of_Columns)) = Curses_Err then - raise Curses_Exception; - end if; - end Resize; ------------------------------------------------------------------------------- - -end Terminal_Interface.Curses; - diff --git a/contrib/ncurses-5.4/Ada95/src/terminal_interface.ads b/contrib/ncurses-5.4/Ada95/src/terminal_interface.ads deleted file mode 100644 index eaaeea9fc7..0000000000 --- a/contrib/ncurses-5.4/Ada95/src/terminal_interface.ads +++ /dev/null @@ -1,48 +0,0 @@ ------------------------------------------------------------------------------- --- -- --- GNAT ncurses Binding -- --- -- --- Terminal_Interface -- --- -- --- S P E C -- --- -- ------------------------------------------------------------------------------- --- Copyright (c) 1998 Free Software Foundation, Inc. -- --- -- --- Permission is hereby granted, free of charge, to any person obtaining a -- --- copy of this software and associated documentation files (the -- --- "Software"), to deal in the Software without restriction, including -- --- without limitation the rights to use, copy, modify, merge, publish, -- --- distribute, distribute with modifications, sublicense, and/or sell -- --- copies of the Software, and to permit persons to whom the Software is -- --- furnished to do so, subject to the following conditions: -- --- -- --- The above copyright notice and this permission notice shall be included -- --- in all copies or substantial portions of the Software. -- --- -- --- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- --- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- --- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- --- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- --- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- --- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- --- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- --- -- --- Except as contained in this notice, the name(s) of the above copyright -- --- holders shall not be used in advertising or otherwise to promote the -- --- sale, use or other dealings in this Software without prior written -- --- authorization. -- ------------------------------------------------------------------------------- --- Author: Juergen Pfeifer, 1996 --- Version Control: --- $Revision: 1.12 $ --- Binding Version 01.00 ------------------------------------------------------------------------------- -package Terminal_Interface is - pragma Pure (Terminal_Interface); --- --- Everything is in the child units --- -end Terminal_Interface; - - diff --git a/contrib/ncurses-5.4/man/MKterminfo.sh b/contrib/ncurses-5.4/man/MKterminfo.sh deleted file mode 100644 index 3a99609565..0000000000 --- a/contrib/ncurses-5.4/man/MKterminfo.sh +++ /dev/null @@ -1,110 +0,0 @@ -#!/bin/sh -# $Id: MKterminfo.sh,v 1.12 2003/01/11 21:42:12 tom Exp $ -# -# MKterminfo.sh -- generate terminfo.5 from Caps tabular data -# -#*************************************************************************** -# Copyright (c) 1998,2002,2003 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. * -#*************************************************************************** -# -# This script takes terminfo.head and terminfo.tail and splices in between -# them a table derived from the Caps data file. Besides avoiding having -# the docs fall out of sync with the table, this also lets us set up tbl -# commands for better formatting of the table. -# -# NOTE: The s in this script really are control characters. It translates -#  to \n because I couldn't get used to inserting linefeeds directly. There -# had better be no s in the table source text. -# -# keep the order independent of locale: -if test "${LANGUAGE+set}" = set; then LANGUAGE=C; export LANGUAGE; fi -if test "${LANG+set}" = set; then LANG=C; export LANG; fi -if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi -if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi -if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi -if test "${LC_COLLATE+set}" = set; then LC_COLLATE=C; export LC_COLLATE; fi - -# -head=$1 -caps=$2 -tail=$3 -cat <<'EOF' -'\" t -.\" DO NOT EDIT THIS FILE BY HAND! -.\" It is generated from terminfo.head, Caps, and terminfo.tail. -.\" -.\" Note: this must be run through tbl before nroff. -.\" The magic cookie on the first line triggers this under some man programs. -EOF -cat $head - -temp=temp$$ -sorted=sorted$$ -unsorted=unsorted$$ -trap "rm -f $sorted $temp $unsorted; exit 99" 1 2 5 15 - -sed -n <$caps "\ -/%%-STOP-HERE-%%/q -/^#%/s/#%//p -/^#/d -s/[ ][ ]*/ /g -s/$/T}/ -s/ [A-Z0-9_()\-][A-Z0-9_()\-]* [0-9\-][0-9\-]* [Y\-][B\-][C\-][G\-][EK\-]\** / T{/ -s/ bool / /p -s/ num / /p -s/ str / /p -" |sed -e 's/^$/../' | tr "\134" "\006" >$unsorted - -rm -f $sorted -rm -f $temp -saved=no -while true -do - data= - read data - test -z "$data" && break - case "$data" in #(vi - **) #(vi - echo "$data" >>$temp - saved=yes - ;; - *) - if test $saved = yes ; then - saved=no - sort $temp >>$sorted - rm -f $temp - fi - echo "$data" >>$sorted - ;; - esac -done <$unsorted -test $saved = yes && sort $temp >>$sorted - -sed -e 's/^\.\.$//' $sorted | tr "\005\006" "\012\134" -cat $tail - -rm -f $sorted $temp $unsorted diff --git a/contrib/ncurses-5.4/man/Makefile.in b/contrib/ncurses-5.4/man/Makefile.in deleted file mode 100644 index 92fb9d30cd..0000000000 --- a/contrib/ncurses-5.4/man/Makefile.in +++ /dev/null @@ -1,79 +0,0 @@ -# $Id: Makefile.in,v 1.35 2003/12/20 18:41:10 tom Exp $ -############################################################################## -# Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Thomas E. Dickey 1996,1997 -# -# Makefile for ncurses manual pages. -# -# NOTE: When you add or rename a man page, make sure you update both -# the top-level MANIFEST and any man/*.renames files! - -SHELL = /bin/sh - -DESTDIR = @DESTDIR@ -srcdir = @srcdir@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ -datadir = @datadir@ -mandir = @mandir@ - -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ - -all \ -sources : terminfo.5 -depend : - -$(DESTDIR)$(mandir) : - sh $(srcdir)/../mkinstalldirs $@ - -EDITARGS = $(DESTDIR)$(mandir) $(srcdir) terminfo.5 $(srcdir)/*.[0-9]* - -install install.man : terminfo.5 $(DESTDIR)$(mandir) - sh ./edit_man.sh normal installing $(EDITARGS) - -uninstall uninstall.man : - -sh ./edit_man.sh normal removing $(EDITARGS) - -# We compose terminfo.5 from the real sources... -CAPLIST=$(srcdir)/../include/@TERMINFO_CAPS@ -terminfo.5: $(srcdir)/terminfo.head $(CAPLIST) $(srcdir)/terminfo.tail Makefile $(srcdir)/MKterminfo.sh - sh $(srcdir)/MKterminfo.sh $(srcdir)/terminfo.head $(CAPLIST) $(srcdir)/terminfo.tail >terminfo.5 - -mostlyclean : - -rm -f core tags TAGS *~ *.bak *.ln *.atac trace - -clean: mostlyclean - rm -f terminfo.5 - -edit_man.sed : make_sed.sh @MANPAGE_RENAMES@ - sh $srcdir/make_sed.sh @MANPAGE_RENAMES@ >edit_man.sed - -distclean realclean: clean - rm -f Makefile edit_man.* diff --git a/contrib/ncurses-5.4/man/captoinfo.1m b/contrib/ncurses-5.4/man/captoinfo.1m deleted file mode 100644 index 2938ec6c9f..0000000000 --- a/contrib/ncurses-5.4/man/captoinfo.1m +++ /dev/null @@ -1,189 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: captoinfo.1m,v 1.17 2003/05/11 00:32:53 tom Exp $ -.TH captoinfo 1M "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBcaptoinfo\fR - convert a \fItermcap\fR description into a \fIterminfo\fR description -.SH SYNOPSIS -\fBcaptoinfo\fR [\fB\-v\fR\fIn\fR \fIwidth\fR] [\fB\-V\fR] [\fB\-1\fR] [\fB\-w\fR \fIwidth\fR] \fIfile\fR . . . -.SH DESCRIPTION -\fBcaptoinfo\fR looks in \fIfile\fR for \fBtermcap\fR descriptions. For each -one found, an equivalent \fBterminfo\fR description is written to standard -output. Termcap \fBtc\fR capabilities are translated directly to terminfo -\fBuse\fR capabilities. - -If no \fIfile\fR is given, then the environment variable \fBTERMCAP\fR is used -for the filename or entry. If \fBTERMCAP\fR is a full pathname to a file, only -the terminal whose name is specified in the environment variable \fBTERM\fR is -extracted from that file. If the environment variable \fBTERMCAP\fR is not -set, then the file \fB\*d\fR is read. -.TP 5 -\fB\-v\fR -print out tracing information on standard error as the program runs. -.TP 5 -\fB\-V\fR -print out the version of the program in use on standard error and exit. -.TP 5 -\fB\-1\fR -cause the fields to print out one to a line. Otherwise, the fields -will be printed several to a line to a maximum width of 60 -characters. -.TP 5 -\fB\-w\fR -change the output to \fIwidth\fR characters. -.SH FILES -.TP 20 -\*d -Compiled terminal description database. -.SH TRANSLATIONS FROM NONSTANDARD CAPABILITIES -.PP -Some obsolete nonstandard capabilities will automatically be translated -into standard (SVr4/XSI Curses) terminfo capabilities by \fBcaptoinfo\fR. -Whenever one of these automatic translations is done, the program -will issue an notification to stderr, inviting the user to check that -it has not mistakenly translated a completely unknown and random -capability and/or syntax error. -.PP -.TS H -c c c c -c c c c -l l l l. -Nonstd Std From Terminfo -name name capability -_ -BO mr AT&T enter_reverse_mode -CI vi AT&T cursor_invisible -CV ve AT&T cursor_normal -DS mh AT&T enter_dim_mode -EE me AT&T exit_attribute_mode -FE LF AT&T label_on -FL LO AT&T label_off -XS mk AT&T enter_secure_mode -EN @7 XENIX key_end -GE ae XENIX exit_alt_charset_mode -GS as XENIX enter_alt_charset_mode -HM kh XENIX key_home -LD kL XENIX key_dl -PD kN XENIX key_npage -PN po XENIX prtr_off -PS pf XENIX prtr_on -PU kP XENIX key_ppage -RT @8 XENIX kent -UP ku XENIX kcuu1 -KA k; Tek key_f10 -KB F1 Tek key_f11 -KC F2 Tek key_f12 -KD F3 Tek key_f13 -KE F4 Tek key_f14 -KF F5 Tek key_f15 -BC Sb Tek set_background -FC Sf Tek set_foreground -HS mh Iris enter_dim_mode -.TE -.PP -XENIX termcap also used to have a set of extension capabilities -for forms drawing, designed to take advantage of the IBM PC -high-half graphics. They were as follows: -.PP -.TS H -c c -l l. -Cap Graphic -_ -G2 upper left -G3 lower left -G1 upper right -G4 lower right -GR pointing right -GL pointing left -GU pointing up -GD pointing down -GH horizontal line -GV vertical line -GC intersection -G6 upper left -G7 lower left -G5 upper right -G8 lower right -Gr tee pointing right -Gr tee pointing left -Gu tee pointing up -Gd tee pointing down -Gh horizontal line -Gv vertical line -Gc intersection -GG acs magic cookie count -.TE -.PP -If the single-line capabilities occur in an entry, they will automatically -be composed into an \fBacsc\fR string. The double-line capabilities and -\fBGG\fR are discarded with a warning message. -.PP -IBM's AIX has a terminfo facility descended from SVr1 terminfo but incompatible -with the SVr4 format. The following AIX extensions are automatically -translated: -.PP -.TS -c c -l l. -IBM XSI -_ -ksel kslt -kbtab kcbt -font0 s0ds -font1 s1ds -font2 s2ds -font3 s3ds -.TE -.PP -Additionally, the AIX \fBbox1\fR capability will be automatically translated to -an \fBacsc\fR string. -.PP -Hewlett-Packard's terminfo library supports two nonstandard terminfo -capabilities \fBmeml\fR (memory lock) and \fBmemu\fR (memory unlock). -These will be discarded with a warning message. -.SH NOTES -This utility is actually a link to \fItic\fR(1M), running in \fI\-I\fR mode. -You can use other \fItic\fR options such as \fB\-f\fR and \fB\-x\fR. - -The trace option isn't identical to SVr4's. Under SVr4, instead of following -the \fB\-v\fR with a trace level n, you repeat it n times. -.SH SEE ALSO -\fBcurses\fR(3X), \fB@INFOCMP@\fR(1M), \fBterminfo\fR(\*n) -.SH AUTHOR -Eric S. Raymond -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/clear.1 b/contrib/ncurses-5.4/man/clear.1 deleted file mode 100644 index 4c4991f1d1..0000000000 --- a/contrib/ncurses-5.4/man/clear.1 +++ /dev/null @@ -1,48 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: clear.1,v 1.3 2000/07/15 23:59:35 china Exp $ -.TH clear 1 "" -.ds n 5 -.SH NAME -\fBclear\fR - clear the terminal screen -.SH SYNOPSIS -\fBclear\fR -.br -.SH DESCRIPTION -\fBclear\fR clears your screen if this is possible. It looks in the -environment for the terminal type and then in the \fBterminfo\fR database to -figure out how to clear the screen. -.SH SEE ALSO -\fB@TPUT@\fR(1), \fBterminfo\fR(\*n) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_add_wch.3x b/contrib/ncurses-5.4/man/curs_add_wch.3x deleted file mode 100644 index fae59ae0b6..0000000000 --- a/contrib/ncurses-5.4/man/curs_add_wch.3x +++ /dev/null @@ -1,134 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2001,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_add_wch.3x,v 1.4 2002/02/16 22:28:43 tom Exp $ -.TH curs_add_wch 3X "" -.SH NAME -\fBadd_wch\fP, -\fBwadd_wch\fP, -\fBmvadd_wch\fP, -\fBmvwadd_wch\fP, -\fBecho_wchar\fP, -\fBwecho_wchar\fP - add a complex character and rendition to a \fBcurses\fR window, then advance the cursor -.SH SYNOPSIS -.PP -\fB#include \fP -.sp -.B "int add_wch( const cchar_t *\fIwch\fB );" -.br -.B "int wadd_wch( WINDOW *\fIwin\fP, const cchar_t *\fIwch\fB );" -.br -.B "int mvadd_wch( int \fIy\fP, int \fIx\fP, const cchar_t *\fIwch\fB );" -.br -.B "int mvwadd_wch( WINDOW *\fIwin\fP, int \fIy\fP, int \fIx\fP, const cchar_t *\fIwch\fB );" -.br -.B "int echo_wchar( const cchar_t *\fIwch\fB );" -.br -.B "int wecho_wchar( WINDOW *\fIwin\fP, const cchar_t *\fIwch\fB );" -.br -.SH DESCRIPTION -.PP -The -\fBadd_wch\fP, -\fBwadd_wch\fP, -\fBmvadd_wch\fP, and -\fBmvwadd_wch\fP -functions put the complex character \fIwch\fP into the given -window at its current position, -which is then advanced. -These functions perform -wrapping and special-character processing as follows: -.TP 5 -- -If \fIwch\fP refers to a spacing character, -then any previous character at that location is removed. -A new character specified by \fIwch\fP is -placed at that location with rendition specified by \fIwch\fP. -The cursor then advances to -the next spacing character on the screen. -.TP 5 -- -If \fIwch\fP refers to a non-spacing character, -all previous characters at that location are preserved. -The non-spacing characters of \fIwch\fP -are added to the spacing complex character, -and the rendition specified by \fIwch\fP is ignored. -.TP 5 -- -If the character part of \fIwch\fP is -a tab, newline, backspace or other control character, -the window is updated and the cursor moves as if \fBaddch\fR(3X) were called. -.PP -The \fBecho_wchar\fP -function is functionally equivalent to a call to -\fBadd_wch\fP -followed by a call to -\fBrefresh\fP. -Similarly, the -\fBwecho_wchar\fP -is functionally equivalent to a call to -\fBwadd_wch\fP -followed by a call to -\fBwrefresh\fP. -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 *\fBecho\fP* functions instead of their equivalents. -.SH RETURN VALUES -.PP -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success. -.SH NOTES -.PP -Note that -\fBadd_wch\fP, -\fBmvadd_wch\fP, -\fBmvwadd_wch\fP, and -\fBecho_wchar\fP -may be macros. -.SH PORTABILITY -.PP -All these functions are described in the XSI Curses standard, Issue 4. -The defaults specified for forms-drawing characters apply in the POSIX locale. -.PP -XSI documents constants beginning with \fBWACS_\fP which are used for -line-drawing. -Those are not currently implemented in \fBncurses\fP. -.SH SEE ALSO -.PP -\fBcurses\fR(3X), -\fBcurs_attr_get\fR(3X), -\fBcurs_clear\fR(3X), -\fBcurs_outopts\fR(3X), -\fBcurs_refresh\fR(3X), -\fBputwc\fR(3) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_add_wchstr.3x b/contrib/ncurses-5.4/man/curs_add_wchstr.3x deleted file mode 100644 index 7afd498473..0000000000 --- a/contrib/ncurses-5.4/man/curs_add_wchstr.3x +++ /dev/null @@ -1,98 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_add_wchstr.3x,v 1.2 2003/12/27 18:53:41 tom Exp $ -.TH curs_add_wchstr 3X "" -.SH NAME -.PP -\fBadd_wchstr\fR, -\fBadd_wchnstr\fR, -\fBwadd_wchstr\fR, -\fBwadd_wchnstr\fR, -\fBmvadd_wchstr\fR, -\fBmvadd_wchnstr\fR, -\fBmvwadd_wchstr\fR, -\fBmvwadd_wchnstr\fR \- add an array of complex characters (and attributes) to a curses window -.SH SYNOPSIS -.B #include -.PP -.nf -\fBint add_wchstr(const cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint add_wchnstr(const cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint wadd_wchstr(WINDOW *\fR \fIwin\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint wadd_wchnstr(WINDOW *\fR \fIwin\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvadd_wchstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint mvadd_wchnstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwadd_wchstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint mvwadd_wchnstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These routines copy the array of complex characters \fIwchstr\fR -into the window image structure at and after the current cursor position. -The four routines with \fIn\fR as the last -argument copy at most \fIn\fR elements, but no more than will fit on the line. -If \fBn\fR=\fB-1\fR then the whole array is copied, -to the maximum number of characters that will fit on the line. -.PP -The window cursor is \fInot\fR advanced. -These routines work faster than \fBwaddnstr\fR. -On the other hand, they do not perform checking -(such as for the newline, backspace, or carriage return characters), -they do not advance the current cursor position, -they do not expand other control characters to ^-escapes, -and they truncate the string if it crosses the right margin, -rather then wrapping it around to the new line. -.PP -These routines end successfully -on encountering a null \fIcchar_t\fR, or -when they have filled the current line. -If a complex character cannot completely fit at the end of the current line, -the remaining columns are filled with the background character and rendition. -.SH NOTES -All functions except \fBwadd_wchnstr\fR may be macros. -.SH RETURN VALUES -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success. -.SH PORTABILITY -All these entry points are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_addchstr\fR(3X) -\fBcurs_addwstr\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_addch.3x b/contrib/ncurses-5.4/man/curs_addch.3x deleted file mode 100644 index 13053d0053..0000000000 --- a/contrib/ncurses-5.4/man/curs_addch.3x +++ /dev/null @@ -1,173 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2003,2004 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_addch.3x,v 1.23 2004/01/31 13:16:21 tom Exp $ -.TH curs_addch 3X "" -.SH NAME -\fBaddch\fR, \fBwaddch\fR, \fBmvaddch\fR, \fBmvwaddch\fR, -\fBechochar\fR, -\fBwechochar\fR - add a character (with attributes) to a \fBcurses\fR window, then advance the cursor -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint addch(const chtype ch);\fR -.br -\fBint waddch(WINDOW *win, const chtype ch);\fR -.br -\fBint mvaddch(int y, int x, const chtype ch);\fR -.br -\fBint mvwaddch(WINDOW *win, int y, int x, const chtype ch);\fR -.br -\fBint echochar(const chtype ch);\fR -.br -\fBint wechochar(WINDOW *win, const chtype ch);\fR -.br -.SH DESCRIPTION -The \fBaddch\fR, \fBwaddch\fR, \fBmvaddch\fR and \fBmvwaddch\fR routines put -the character \fIch\fR into the given window at its current window position, -which is then advanced. They are analogous to \fBputchar\fR in \fBstdio\fR(3). -If the advance is at the right margin, the cursor automatically wraps to the -beginning of the next line. At the bottom of the current scrolling region, if -\fBscrollok\fR is enabled, the scrolling region is scrolled up one line. -.PP -If \fIch\fR is a tab, newline, or backspace, -the cursor is moved appropriately within the window. -Backspace moves the cursor one character left; at the left -edge of a window it does nothing. -Newline does a \fBclrtoeol\fR, -then moves the cursor to the window left margin on the next line, -scrolling the window if on the last line. -Tabs are considered to be at every eighth column. -The tab interval may be altered by setting the \fBTABSIZE\fR variable. -.PP -If \fIch\fR is any control character other than tab, newline, or backspace, it -is drawn in \fB^\fR\fIX\fR notation. Calling \fBwinch\fR after adding a -control character does not return the character itself, but instead returns -the ^-representation of the control character. -.PP -Video attributes can be combined with a character argument passed to -\fBaddch\fR or related functions by logical-ORing them into the character. -(Thus, text, including attributes, can be copied from one place to another -using \fBinch\fR and \fBaddch\fR.) See the \fBcurs_attr\fR(3X) page for -values of predefined video attribute constants that can be usefully OR'ed -into characters. -.PP -The \fBechochar\fR and \fBwechochar\fR routines are equivalent to a call to -\fBaddch\fR followed by a call to \fBrefresh\fR, or a call to \fBwaddch\fR -followed by a call to \fBwrefresh\fR. The knowledge that only a single -character is being output is used and, for non-control characters, a -considerable performance gain may be seen by using these routines instead of -their equivalents. -.SS Line Graphics -The following variables may be used to add line drawing characters to the -screen with routines of the \fBaddch\fR family. The default character listed -below is used if the \fBacsc\fR capability doesn't define a terminal-specific -replacement for it (but see the EXTENSIONS section below). The names are -taken from VT100 nomenclature. -.PP -.TS -l l l -_ _ _ -l l l. -\fIName\fR \fIDefault\fR \fIDescription\fR -ACS_BLOCK # solid square block -ACS_BOARD # board of squares -ACS_BTEE + bottom tee -ACS_BULLET o bullet -ACS_CKBOARD : checker board (stipple) -ACS_DARROW v arrow pointing down -ACS_DEGREE ' degree symbol -ACS_DIAMOND + diamond -ACS_GEQUAL > greater-than-or-equal-to -ACS_HLINE - horizontal line -ACS_LANTERN # lantern symbol -ACS_LARROW < arrow pointing left -ACS_LEQUAL < less-than-or-equal-to -ACS_LLCORNER + lower left-hand corner -ACS_LRCORNER + lower right-hand corner -ACS_LTEE + left tee -ACS_NEQUAL ! not-equal -ACS_PI * greek pi -ACS_PLMINUS # plus/minus -ACS_PLUS + plus -ACS_RARROW > arrow pointing right -ACS_RTEE + right tee -ACS_S1 - scan line 1 -ACS_S3 - scan line 3 -ACS_S7 - scan line 7 -ACS_S9 \&_ scan line 9 -ACS_STERLING f pound-sterling symbol -ACS_TTEE + top tee -ACS_UARROW ^ arrow pointing up -ACS_ULCORNER + upper left-hand corner -ACS_URCORNER + upper right-hand corner -ACS_VLINE | vertical line -.TE -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success -(the SVr4 manuals specify only "an integer value other than \fBERR\fR") upon -successful completion, unless otherwise noted in the preceding routine -descriptions. -.SH NOTES -Note that \fBaddch\fR, \fBmvaddch\fR, \fBmvwaddch\fR, and -\fBechochar\fR may be macros. -.SH PORTABILITY -All these functions are described in the XSI Curses standard, Issue 4. -The defaults specified for forms-drawing characters apply in the POSIX locale. -.LP -Some ACS symbols -(ACS_S3, -ACS_S7, -ACS_LEQUAL, -ACS_GEQUAL, -ACS_PI, -ACS_NEQUAL, -ACS_STERLING) -were not documented in -any publicly released System V. However, many publicly available terminfos -include \fBacsc\fR strings in which their key characters (pryz{|}) are -embedded, and a second-hand list of their character descriptions has come -to light. The ACS-prefixed names for them were invented for \fBncurses\fR(3X). -.LP -The \fBTABSIZE\fR variable is implemented in some versions of curses, -but is not part of X/Open curses. -.LP -If \fIch\fR is a carriage return, -the cursor is moved to the beginning of the current row of the window. -This is true of other implementations, but is not documented. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_attr\fR(3X), \fBcurs_clear\fR(3X), -\fBcurs_inch\fR(3X), \fBcurs_outopts\fR(3X), \fBcurs_refresh\fR(3X), -\fBputc\fR(3S). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_addchstr.3x b/contrib/ncurses-5.4/man/curs_addchstr.3x deleted file mode 100644 index 9de749fc8f..0000000000 --- a/contrib/ncurses-5.4/man/curs_addchstr.3x +++ /dev/null @@ -1,82 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_addchstr.3x,v 1.8 2003/12/27 18:51:24 tom Exp $ -.TH curs_addchstr 3X "" -.SH NAME -\fBaddchstr\fR, \fBaddchnstr\fR, \fBwaddchstr\fR, -\fBwaddchnstr\fR, \fBmvaddchstr\fR, \fBmvaddchnstr\fR, \fBmvwaddchstr\fR, -\fBmvwaddchnstr\fR - add a string of characters (and attributes) to a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint addchstr(const chtype *chstr);\fR -.br -\fBint addchnstr(const chtype *chstr, int n);\fR -.br -\fBint waddchstr(WINDOW *win, const chtype *chstr);\fR -.br -\fBint waddchnstr(WINDOW *win, const chtype *chstr, int n);\fR -.br -\fBint mvaddchstr(int y, int x, const chtype *chstr);\fR -.br -\fBint mvaddchnstr(int y, int x, const chtype *chstr, int n);\fR -.br -\fBint mvwaddchstr(WINDOW *win, int y, int x, const chtype *chstr);\fR -.br -\fBint mvwaddchnstr(WINDOW *win, int y, int x, const chtype *chstr, int n);\fR -.SH DESCRIPTION -These routines copy \fIchstr\fR into the window image structure at and after -the current cursor position. The four routines with \fIn\fR as the last -argument copy at most \fIn\fR elements, but no more than will fit on the line. -If \fBn\fR=\fB-1\fR then the whole string is copied, to the maximum number of -characters that will fit on the line. -.PP -The window cursor is \fInot\fR advanced, and these routines work faster than -\fBwaddnstr\fR. On the other hand, they don't perform any kind of checking -(such as for the newline, backspace, or carriage return characters), they don't -advance the current cursor position, they don't expand other control characters -to ^-escapes, and they truncate the string if it crosses the right margin, -rather then wrapping it around to the new line. -.SH RETURN VALUES -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success -(the SVr4 manuals specify only "an integer value other than \fBERR\fR") upon -successful completion, unless otherwise noted in the preceding routine -descriptions. -.SH NOTES -Note that all routines except \fBwaddchnstr\fR may be macros. -.SH PORTABILITY -All these entry points are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_addstr.3x b/contrib/ncurses-5.4/man/curs_addstr.3x deleted file mode 100644 index 0ffacc6fa9..0000000000 --- a/contrib/ncurses-5.4/man/curs_addstr.3x +++ /dev/null @@ -1,87 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_addstr.3x,v 1.11 2003/12/27 18:51:15 tom Exp $ -.TH curs_addstr 3X "" -.SH NAME -\fBaddstr\fR, -\fBaddnstr\fR, -\fBwaddstr\fR, -\fBwaddnstr\fR, -\fBmvaddstr\fR, -\fBmvaddnstr\fR, -\fBmvwaddstr\fR, -\fBmvwaddnstr\fR - add a string of characters to a \fBcurses\fR window and advance cursor -.SH SYNOPSIS -.nf -\fB#include \fR -.PP -\fBint addstr(const char *\fR\fIstr\fR\fB);\fR -.br -\fBint addnstr(const char *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint waddstr(WINDOW *\fR\fIwin\fR\fB, const char *\fR\fIstr\fR\fB);\fR -.br -\fBint waddnstr(WINDOW *\fR\fIwin\fR\fB, const char *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvaddstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const char *\fR\fIstr\fR\fB);\fR -.br -\fBint mvaddnstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const char *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwaddstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const char *\fR\fIstr\fR\fB);\fR -.br -\fBint mvwaddnstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const char *\fR\fIstr, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These routines write the characters of the (null-terminated) character string -\fIstr\fR on the given window. -It is similar to calling \fBwaddch\fR once for each character in the string. -The four routines with \fIn\fR as the last argument -write at most \fIn\fR characters. -If \fIn\fR is -1, then the entire string will be added, -up to the maximum number of characters that will fit on the line, -or until a terminating null is reached. -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success -(the SVr4 manuals specify only "an integer value other than \fBERR\fR") upon -successful completion. -.SH NOTES -Note that all of these routines except \fBwaddstr\fR and \fBwaddnstr\fR may be -macros. -.SH PORTABILITY -All these entry points are described in the XSI Curses standard, Issue 4. The -XSI errors EILSEQ and EOVERFLOW, associated with extended-level conformance, -are not yet detected. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_addch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_addwstr.3x b/contrib/ncurses-5.4/man/curs_addwstr.3x deleted file mode 100644 index 4091b36276..0000000000 --- a/contrib/ncurses-5.4/man/curs_addwstr.3x +++ /dev/null @@ -1,91 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_addwstr.3x,v 1.3 2003/12/27 18:51:01 tom Exp $ -.TH curs_addwstr 3X "" -.SH NAME -\fBaddwstr\fR, -\fBaddnwstr\fR, -\fBwaddwstr\fR, -\fBwaddnwstr\fR, -\fBmvaddwstr\fR, -\fBmvaddnwstr\fR, -\fBmvwaddwstr\fR, -\fBmvwaddnwstr\fR \- add a string of wide characters to a \fBcurses\fR window and advance cursor -.SH SYNOPSIS -.nf -\fB#include \fR -.PP -\fBint addwstr(const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint addnwstr(const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint waddwstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint waddnwstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvaddwstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvaddnwstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwaddwstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvwaddnwstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These routines write the characters of the (null-terminated) \fBwchar_t\fRcharacter string -\fIwstr\fR on the given window. -It is similar to constructing a \fBcchar_t\fR for each wchar_t in the string, -then calling \fBwadd_wch\fR for the resulting \fBcchar_t\fR. -.PP -The \fImv\fR routines perform cursor movement once, before writing any -characters. -Thereafter, the cursor is advanced as a side-effect of writing to the window. -.PP -The four routines with \fIn\fR as the last argument -write at most \fIn\fR \fBwchar_t\fR characters. -If \fIn\fR is -1, then the entire string will be added, -up to the maximum number of characters that will fit on the line, -or until a terminating null is reached. -.SH RETURN VALUES -All routines return the integer \fBERR\fR upon failure and \fBOK\fR on success. -.SH NOTES -Note that all of these routines except \fBwaddnwstr\fR may be macros. -.SH PORTABILITY -All these entry points are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -.PP -Functions: -\fBcurses\fR(3X), -\fBcurs_add_wch\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_attr.3x b/contrib/ncurses-5.4/man/curs_attr.3x deleted file mode 100644 index bcbf61c498..0000000000 --- a/contrib/ncurses-5.4/man/curs_attr.3x +++ /dev/null @@ -1,232 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_attr.3x,v 1.27 2003/12/27 18:50:51 tom Exp $ -.TH curs_attr 3X "" -.SH NAME -\fBattroff\fR, \fBwattroff\fR, \fBattron\fR, \fBwattron\fR, -\fBattrset\fR, \fBwattrset\fR, \fBcolor_set\fR, \fBwcolor_set\fR, -\fBstandend\fR, \fBwstandend\fR, \fBstandout\fR, \fBwstandout\fR, -\fBattr_get\fR, \fBwattr_get\fR, -\fBattr_off\fR, \fBwattr_off\fR, -\fBattr_on\fR, \fBwattr_on\fR, -\fBattr_set\fR, \fBwattr_set\fR, -\fBchgat\fR, \fBwchgat\fR, -\fBmvchgat\fR, \fBmvwchgat\fR, -\fBPAIR_NUMBER\fR - \fBcurses\fR character and window attribute control routines -.SH SYNOPSIS -\fB#include \fR -.br -\fBint attroff(int attrs);\fR -.br -\fBint wattroff(WINDOW *win, int attrs);\fR -.br -\fBint attron(int attrs);\fR -.br -\fBint wattron(WINDOW *win, int attrs);\fR -.br -\fBint attrset(int attrs);\fR -.br -\fBint wattrset(WINDOW *win, int attrs);\fR -.br -\fBint color_set(short color_pair_number, void* opts);\fR -.br -\fBint wcolor_set(WINDOW *win, short color_pair_number,\fR - \fBvoid* opts);\fR -.br -\fBint standend(void);\fR -.br -\fBint wstandend(WINDOW *win);\fR -.br -\fBint standout(void);\fR -.br -\fBint wstandout(WINDOW *win);\fR -.br -\fBint attr_get(attr_t *attrs, short *pair, void *opts);\fR -.br -\fBint wattr_get(WINDOW *win, attr_t *attrs, short *pair,\fR - \fBvoid *opts);\fR -.br -\fBint attr_off(attr_t attrs, void *opts);\fR -.br -\fBint wattr_off(WINDOW *win, attr_t attrs, void *opts);\fR -.br -\fBint attr_on(attr_t attrs, void *opts);\fR -.br -\fBint wattr_on(WINDOW *win, attr_t attrs, void *opts);\fR -.br -\fBint attr_set(attr_t attrs, short pair, void *opts);\fR -.br -\fBint wattr_set(WINDOW *win, attr_t attrs, short pair, void *opts);\fR -.br -\fBint chgat(int n, attr_t attr, short color,\fR - \fBconst void *opts)\fR -.br -\fBint wchgat(WINDOW *win, int n, attr_t attr,\fR - \fBshort color, const void *opts)\fR -.br -\fBint mvchgat(int y, int x, int n, attr_t attr,\fR - \fBshort color, const void *opts)\fR -.br -\fBint mvwchgat(WINDOW *win, int y, int x, int n,\fR - \fBattr_t attr, short color, const void *opts)\fR -.br -.SH DESCRIPTION -These routines manipulate the current attributes of the named window. The -current attributes of a window apply to all characters that are written into -the window with \fBwaddch\fR, \fBwaddstr\fR and \fBwprintw\fR. Attributes are -a property of the character, and move with the character through any scrolling -and insert/delete line/character operations. To the extent possible, they are -displayed as appropriate modifications to the graphic rendition of characters -put on the screen. -.PP -The routine \fBattrset\fR sets the current attributes of the given window to -\fIattrs\fR. The routine \fBattroff\fR turns off the named attributes without -turning any other attributes on or off. The routine \fBattron\fR turns on the -named attributes without affecting any others. The routine \fBstandout\fR is -the same as \fBattron(A_STANDOUT)\fR. The routine \fBstandend\fR is the same -as \fBattrset(A_NORMAL)\fR or \fBattrset(0)\fR, that is, it turns off all -attributes. -.PP -The \fBattrset\fR and related routines do not affect the attributes used -when erasing portions of the window. -See \fBcurs_bkgd\fR(3X) for functions which modify the attributes used for -erasing and clearing. -.PP -The routine \fBcolor_set\fR sets the current color of the given window to the -foreground/background combination described by the color_pair_number. The -parameter opts is reserved for future use, applications must supply a null -pointer. -.PP -The routine \fBwattr_get\fR returns the current attribute and color pair for -the given window; \fBattr_get\fR returns the current attribute and color pair -for \fBstdscr\fR. -The remaining \fBattr_\fR* functions operate exactly like the corresponding -\fBattr\fR* functions, except that they take arguments of type \fBattr_t\fR -rather than \fBint\fR. -.PP -The routine \fBchgat\fR changes the attributes of a given number of characters -starting at the current cursor location of \fBstdscr\fR. It does not update -the cursor and does not perform wrapping. A character count of -1 or greater -than the remaining window width means to change attributes all the way to the -end of the current line. The \fBwchgat\fR function generalizes this to any -window; the \fBmvwchgat\fR function does a cursor move before acting. In these -functions, the color argument is a color-pair index (as in the first argument -of \fIinit_pair\fR, see \fBcurs_color\fR(3X)). The \fBopts\fR argument is not -presently used, but is reserved for the future (leave it \fBNULL\fR). -Note that changing the attributes does not imply -that a subsequent \fBrefresh\fR will update the screen to match, -since the character values are not modified. -Use \fBtouchwin\fR to force the screen to match the updated attributes. -.SS Attributes -The following video attributes, defined in \fB\fR, can be passed to -the routines \fBattron\fR, \fBattroff\fR, and \fBattrset\fR, or OR'ed with the -characters passed to \fBaddch\fR. -.PP -.TS -center ; -l l . -\fBA_NORMAL\fR Normal display (no highlight) -\fBA_STANDOUT\fR Best highlighting mode of the terminal. -\fBA_UNDERLINE\fR Underlining -\fBA_REVERSE\fR Reverse video -\fBA_BLINK\fR Blinking -\fBA_DIM\fR Half bright -\fBA_BOLD\fR Extra bright or bold -\fBA_PROTECT\fR Protected mode -\fBA_INVIS\fR Invisible or blank mode -\fBA_ALTCHARSET\fR Alternate character set -\fBA_CHARTEXT\fR Bit-mask to extract a character -\fBCOLOR_PAIR(\fR\fIn\fR\fB)\fR Color-pair number \fIn\fR -.TE -.PP -The following macro is the reverse of \fBCOLOR_PAIR(\fR\fIn\fR\fB)\fR: -.PP -.br -\fBPAIR_NUMBER(\fR\fIattrs\fR) Returns the pair number associated - with the \fBCOLOR_PAIR(\fR\fIn\fR\fB)\fR attribute. -.br -.PP -The return values of many of these routines are not meaningful (they are -implemented as macro-expanded assignments and simply return their argument). -The SVr4 manual page claims (falsely) that these routines always return \fB1\fR. -.SH NOTES -Note that \fBattroff\fR, \fBwattroff\fR, \fBattron\fR, \fBwattron\fR, -\fBattrset\fR, \fBwattrset\fR, \fBstandend\fR and \fBstandout\fR may be macros. -.SH PORTABILITY -All these functions are supported in the XSI Curses standard, Issue 4. The -standard defined the dedicated type for highlights, \fBattr_t\fR, which is not -defined in SVr4 curses. The functions taking \fBattr_t\fR arguments are -not supported under SVr4. -.PP -The XSI Curses standard states that whether the traditional functions -\fBattron\fR/\fBattroff\fR/\fBattrset\fR can manipulate attributes other than -\fBA_BLINK\fR, \fBA_BOLD\fR, \fBA_DIM\fR, \fBA_REVERSE\fR, \fBA_STANDOUT\fR, or -\fBA_UNDERLINE\fR is "unspecified". Under this implementation as well as -SVr4 curses, these functions correctly manipulate all other highlights -(specifically, \fBA_ALTCHARSET\fR, \fBA_PROTECT\fR, and \fBA_INVIS\fR). -.PP -XSI Curses added the new entry points, \fBattr_get\fR, \fBattr_on\fR, -\fBattr_off\fR, \fBattr_set\fR, \fBwattr_on\fR, \fBwattr_off\fR, -\fBwattr_get\fR, \fBwattr_set\fR. These are intended to work with -a new series of highlight macros prefixed with \fBWA_\fR. -.PP -.TS -center ; -l l . -\fBWA_NORMAL\fR Normal display (no highlight) -\fBWA_STANDOUT\fR Best highlighting mode of the terminal. -\fBWA_UNDERLINE\fR Underlining -\fBWA_REVERSE\fR Reverse video -\fBWA_BLINK\fR Blinking -\fBWA_DIM\fR Half bright -\fBWA_BOLD\fR Extra bright or bold -\fBWA_ALTCHARSET\fR Alternate character set -.TE -.PP -The XSI curses standard specifies that each pair of corresponding \fBA_\fR -and \fBWA_\fR-using functions operates on the same current-highlight -information. -.PP -The XSI standard extended conformance level adds new highlights -\fBA_HORIZONTAL\fR, \fBA_LEFT\fR, \fBA_LOW\fR, \fBA_RIGHT\fR, \fBA_TOP\fR, -\fBA_VERTICAL\fR (and corresponding \fBWA_\fR macros for each) which this -curses does not yet support. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_addch\fR(3X), -\fBcurs_addstr\fR(3X), -\fBcurs_bkgd\fR(3X), -\fBcurs_printw\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_beep.3x b/contrib/ncurses-5.4/man/curs_beep.3x deleted file mode 100644 index 579931ccc4..0000000000 --- a/contrib/ncurses-5.4/man/curs_beep.3x +++ /dev/null @@ -1,63 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_beep.3x,v 1.9 2003/12/27 18:44:30 tom Exp $ -.TH curs_beep 3X "" -.SH NAME -\fBbeep\fR, \fBflash\fR - \fBcurses\fR bell and screen flash routines -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint beep(void);\fR -.br -\fBint flash(void);\fR -.br -.SH DESCRIPTION -The \fBbeep\fR and \fBflash\fR routines are used to alert the terminal user. -The routine \fBbeep\fR sounds an audible alarm on the terminal, if possible; -otherwise it flashes the screen (visible bell). The routine \fBflash\fR -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. -.SH RETURN VALUE -These routines return \fBOK\fR if they succeed in beeping or flashing, -\fBERR\fR otherwise. -.SH EXTENSIONS -SVr4's beep and flash routines always returned \fBOK\fR, so it was not -possible to tell when the beep or flash failed. -.SH PORTABILITY -These functions are defined in the XSI Curses standard, Issue 4. Like SVr4, it -specifies that they always return \fBOK\fR. -.SH SEE ALSO -\fBcurses\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_bkgd.3x b/contrib/ncurses-5.4/man/curs_bkgd.3x deleted file mode 100644 index b2d768a441..0000000000 --- a/contrib/ncurses-5.4/man/curs_bkgd.3x +++ /dev/null @@ -1,98 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_bkgd.3x,v 1.19 2003/12/27 18:50:40 tom Exp $ -.TH curs_bkgd 3X "" -.SH NAME -\fBbkgdset\fR, \fBwbkgdset\fR, -\fBbkgd\fR, \fBwbkgd\fR, -\fBgetbkgd\fR - \fBcurses\fR window background manipulation routines -.SH SYNOPSIS -\fB#include \fR -.PP -\fBvoid bkgdset(chtype ch);\fR -.br -\fBvoid wbkgdset(WINDOW *win, chtype ch);\fR -.br -\fBint bkgd(chtype ch);\fR -.br -\fBint wbkgd(WINDOW *win, chtype ch);\fR -.br -\fBchtype getbkgd(WINDOW *win);\fR -.br -.SH DESCRIPTION -The \fBbkgdset\fR and \fBwbkgdset\fR routines manipulate the -background of the named window. -The window background is a \fBchtype\fR 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 \fBwaddch\fR. Both -the character and attribute parts of the background are combined with -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. -.PP -To the extent possible on a particular terminal, -the attribute part of the background is displayed -as the graphic rendition of the character put on the screen. -.PP -The \fBbkgd\fR and \fBwbkgd\fR functions -set the background property of the current or specified window -and then apply this setting to every character position in that window: -.PP -.RS -The rendition of every character on the screen is changed to -the new background rendition. -.PP -Wherever the former background character -appears, it is changed to the new background character. -.RE -.PP -The \fBgetbkgd\fR function returns the given window's current background -character/attribute pair. -.SH RETURN VALUE -The routines \fBbkgd\fR and \fBwbkgd\fR return the integer \fBOK\fR. -The SVr4.0 manual says "or a non-negative integer if \fBimmedok\fR is set", -but this appears to be an error. -.SH NOTES -Note that \fBbkgdset\fR and \fBbkgd\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -It specifies that \fBbkgd\fR and \fBwbkgd\fR return \fBERR\fR on failure. -but gives no failure conditions. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_addch\fR(3X), -\fBcurs_attr\fR(3X), -\fBcurs_outopts\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_bkgrnd.3x b/contrib/ncurses-5.4/man/curs_bkgrnd.3x deleted file mode 100644 index 3be0dced7b..0000000000 --- a/contrib/ncurses-5.4/man/curs_bkgrnd.3x +++ /dev/null @@ -1,107 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_bkgrnd.3x,v 1.1 2002/02/23 23:23:42 tom Exp $ -.TH curs_bkgrnd 3X "" -.SH NAME -.PP -\fBbkgrnd\fR, -\fBwbkgrnd\fR, -\fBbkgrndset\fR, -\fBwbkgrndset\fR, -\fBgetbkgrnd\fR, -\fBwgetbkgrnd\fR \- \fBcurses\fR window complex background manipulation routines -.SH SYNOPSIS -.PP -.B #include - -\fBint bkgrnd(\fR\fB const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint wbkgrnd(\fR\fB WINDOW *\fR\fIwin\fR\fB, const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBvoid bkgrndset(const cchar_t *\fR\fIwch\fR \fB);\fR -.br -\fBvoid wbkgrndset(WINDOW *\fR\fIwin\fR\fB, const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint getbkgrnd(cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint wgetbkgrnd(WINDOW *\fR\fIwin\fR\fB, cchar_t *\fR\fIwch\fR\fB);\fR -.br -.SH DESCRIPTION -The \fBbkgrndset\fR and \fBwbkgrndset\fR routines manipulate the -background of the named window. -The window background is a \fBcchar_t\fR consisting of -any combination of attributes (i.e., rendition) and a complex character. -The attribute part of the background is combined (OR'ed) with all non-blank -characters that are written into the window with \fBwaddch\fR. Both -the character and attribute parts of the background are combined with -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 the background is displayed -as the graphic rendition of the character put on the screen. - -The \fBbkgrnd\fR and \fBwbkgrnd\fR functions -set the background property of the current or specified window -and then apply this setting to every character position in that window: - -.RS -The rendition of every character on the screen is changed to -the new background rendition. - -Wherever the former background character -appears, it is changed to the new background character. -.RE - -The \fBgetbkgrnd\fR function returns the given window's current background -character/attribute pair via the \fBwch\fR pointer. - -.SH NOTES -Note that -\fBbkgrnd\fR, -\fBbkgrndset\fR, and -\fBgetbkgrnd\fR -may be macros. -.SH RETURN VALUES -The \fBbkgrndset\fR and \fBwbkgrndset\fR routines do not return a value. -.PP -Upon successful completion, the other functions return \fBOK\fR. -Otherwise, they return \fBERR\fR. -A null window pointer is treated as an error. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_bkgd\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_border.3x b/contrib/ncurses-5.4/man/curs_border.3x deleted file mode 100644 index c087fad73b..0000000000 --- a/contrib/ncurses-5.4/man/curs_border.3x +++ /dev/null @@ -1,138 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_border.3x,v 1.15 2002/02/16 22:21:47 tom Exp $ -.TH curs_border 3X "" -.SH NAME -\fBborder\fR, \fBwborder\fR, \fBbox\fR, -\fBhline\fR, \fBwhline\fR, -\fBvline\fR, \fBwvline\fR, -\fBmvhline\fR, \fBmvwhline\fR, -\fBmvvline\fR, \fBmvwvline\fR - create \fBcurses\fR borders, horizontal and vertical lines -.SH SYNOPSIS -\fB#include \fR -.br -\fBint border(chtype ls, chtype rs, chtype ts, chtype bs,\fR - \fBchtype tl, chtype tr, chtype bl, chtype br);\fR -.br -\fBint wborder(WINDOW *win, chtype ls, chtype rs,\fR - \fBchtype ts, chtype bs, chtype tl, chtype tr,\fR - \fBchtype bl, chtype br);\fR -.br -\fBint box(WINDOW *win, chtype verch, chtype horch);\fR -.br -\fBint hline(chtype ch, int n);\fR -.br -\fBint whline(WINDOW *win, chtype ch, int n);\fR -.br -\fBint vline(chtype ch, int n);\fR -.br -\fBint wvline(WINDOW *win, chtype ch, int n);\fR -.br -\fBmvhline(int y, int x, chtype ch, int n);\fR -.br -\fBmvwhline(WINDOW *, int y, int x, chtype ch, int n);\fR -.br -\fBint mvvline(int y, int x, chtype ch, int n);\fR -.br -\fBint mvwvline(WINDOW *, int y, int x, chtype ch, int n);\fR -.br -.SH DESCRIPTION -The \fBborder\fR, \fBwborder\fR and \fBbox\fR routines -draw a box around the edges of a window. -Other than the window, each argument is a character with attributes: -.RS -\fIls\fR - left side, -.br -\fIrs\fR - right side, -.br -\fIts\fR - top side, -.br -\fIbs\fR - bottom side, -.br -\fItl\fR - top left-hand corner, -.br -\fItr\fR - top right-hand corner, -.br -\fIbl\fR - bottom left-hand corner, and -.br -\fIbr\fR - bottom right-hand corner. -.RE -If any of these arguments is zero, then the corresponding -default values (defined in \fBcurses.h\fR) are used instead: -.RS -\fBACS_VLINE\fR, -.br -\fBACS_VLINE\fR, -.br -\fBACS_HLINE\fR, -.br -\fBACS_HLINE\fR, -.br -\fBACS_ULCORNER\fR, -.br -\fBACS_URCORNER\fR, -.br -\fBACS_LLCORNER\fR, -.br -\fBACS_LRCORNER\fR. -.RE - -\fBbox(\fR\fIwin\fR\fB, \fR\fIverch\fR\fB, \fR\fIhorch\fR\fB)\fR is a shorthand -for the following call: \fBwborder(\fR\fIwin\fR\fB,\fR \fIverch\fR\fB,\fR -\fIverch\fR\fB,\fR \fIhorch\fR\fB,\fR \fIhorch\fR\fB, 0, 0, 0, 0)\fR. - -The \fBhline\fR and \fBwhline\fR functions draw a horizontal (left to right) -line using \fIch\fR starting at the current cursor position in the window. The -current cursor position is not changed. The line is at most \fIn\fR characters -long, or as many as fit into the window. - -The \fBvline\fR and \fBwvline\fR functions draw a vertical (top to bottom) line -using \fIch\fR starting at the current cursor position in the window. The -current cursor position is not changed. The line is at most \fIn\fR characters -long, or as many as fit into the window. -.SH RETURN VALUE -All routines return the integer \fBOK\fR. The SVr4.0 manual says "or a -non-negative integer if \fBimmedok\fR is set", but this appears to be an error. -.SH NOTES -The borders generated by these functions are \fIinside\fR borders (this -is also true of SVr4 curses, though the fact is not documented). - -Note that \fBborder\fR and \fBbox\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -The standard specifies that they return \fBERR\fR on failure, -but specifies no error conditions. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_outopts\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_border_set.3x b/contrib/ncurses-5.4/man/curs_border_set.3x deleted file mode 100644 index ba7a197bf0..0000000000 --- a/contrib/ncurses-5.4/man/curs_border_set.3x +++ /dev/null @@ -1,202 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_border_set.3x,v 1.3 2002/04/20 16:49:13 tom Exp $ -.TH curs_border_set 3X "" -.SH NAME -.PP -\fBborder_set\fR, -\fBwborder_set\fR, -\fBbox_set\fR, -\fBhline_set\fR, -\fBwhline_set\fR, -\fBmvhline_set\fR, -\fBmvwhline_set\fR, -\fBvline_set\fR, -\fBwvline_set\fR, -\fBmvvline_set\fR, -\fBmvwvline_set\fR \- create \fBcurses\fR borders or lines using complex characters and renditions -.SH SYNOPSIS -.PP -\fB#include \fR -.sp -\fBint border_set(\fR - \fBconst cchar_t *\fR\fIls\fR, \fBconst cchar_t *\fR\fIrs\fR, - \fBconst cchar_t *\fR\fIts\fR, \fBconst cchar_t *\fR\fIbs\fR, - \fBconst cchar_t *\fR\fItl\fR, \fBconst cchar_t *\fR\fItr\fR, - \fBconst cchar_t *\fR\fIbl\fR, \fBconst cchar_t *\fR\fIbr\fR -\fB);\fR -.br -\fBint wborder_set(\fR - \fBWINDOW *win\fR, - \fBconst cchar_t *\fR\fIls\fR, \fBconst cchar_t *\fR\fIrs\fR, - \fBconst cchar_t *\fR\fIts\fR, \fBconst cchar_t *\fR\fIbs\fR, - \fBconst cchar_t *\fR\fItl\fR, \fBconst cchar_t *\fR\fItr\fR, - \fBconst cchar_t *\fR\fIbl\fR, \fBconst cchar_t *\fR\fIbr\fR\fB);\fR -.br -\fBint box_set(\fR - \fBWINDOW *win\fR, - \fBconst cchar_t *\fR\fIverch\fR, - \fBconst cchar_t *\fR\fIhorch\fR\fB);\fR -.br -\fBint hline_set(\fR - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint whline_set(\fR - \fBWINDOW *\fR\fIwin\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint mvhline_set(\fR - \fBint \fR\fIy\fR, \fBint \fR\fIx\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint mvwhline_set(\fR - \fBWINDOW *\fR\fIwin\fR, - \fBint \fR\fIy\fR, \fBint \fR\fIx\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint vline_set(\fR - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint wvline_set(\fR - \fBWINDOW *\fR\fIwin\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint mvvline_set(\fR - \fBint \fR\fIy\fR, \fBint \fR\fIx\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -\fBint mvwvline_set(\fR - \fBWINDOW *\fR\fIwin\fR, - \fBint \fR\fIy\fR, \fBint \fR\fIx\fR, - \fBconst cchar_t *\fR\fIwch\fR, \fBint \fR\fIn\fR\fB);\fR -.br -.SH DESCRIPTION -.PP -The -\fBborder_set\fR -and -\fBwborder_set\fR -functions draw a border around the edges of the current or specified window. -These functions do not change the cursor position, and do not wrap. -.PP -Other than the window, each argument is a complex character with attributes: -.RS -\fIls\fR - left side, -.br -\fIrs\fR - right side, -.br -\fIts\fR - top side, -.br -\fIbs\fR - bottom side, -.br -\fItl\fR - top left-hand corner, -.br -\fItr\fR - top right-hand corner, -.br -\fIbl\fR - bottom left-hand corner, and -.br -\fIbr\fR - bottom right-hand corner. -.RE -.PP -If any of these arguments is zero, then the corresponding -default values (defined in \fBcurses.h\fR) are used instead: -.RS -\fBWACS_VLINE\fR, -.br -\fBWACS_VLINE\fR, -.br -\fBWACS_HLINE\fR, -.br -\fBWACS_HLINE\fR, -.br -\fBWACS_ULCORNER\fR, -.br -\fBWACS_URCORNER\fR, -.br -\fBWACS_LLCORNER\fR, and -.br -\fBWACS_LRCORNER\fR. -.RE -.PP -\fBbox_set(\fR\fIwin\fR, \fIverch\fR\fB, \fR\fIhorch\fR\fB);\fR -is a shorthand for the following call: -.PP -\fBwborder_set(\fR\fIwin\fR\fB, \fR\fIverch\fR\fB, \fR\fIverch\fR\fB,\fR - \fIhorch\fR\fB, \fR\fIhorch\fR\fB, NULL, NULL, NULL, NULL);\fR -.PP -The -\fB*line_set\fR -functions use -\fIwch\fR -to draw a line starting at the current cursor position in the window. -The line is at most \fIn\fR characters long or as many as fit into the window. -The current cursor position is not changed. -.PP -The -\fBhline_set\fR, -\fBmvhline_set\fR, -\fBmvwhline_set\fR, and -\fBwhline_set\fR -functions draw a line proceeding toward the last column of the same line. -.PP -The -\fBvline_set\fR, -\fBmvvline_set\fR, -\fBmvwvline_set\fR, and -\fBwvline_set\fR -functions draw a line proceeding toward the last line of the window. -.br -.SH NOTES -.PP -Note that -\fBborder_set\fR, -\fBhline_set\fR, -\fBmvhline_set\fR, -\fBmvvline_set\fR, -\fBmvwhline_set\fR, -\fBmvwvline_set\fR, and -\fBvline_set\fR -may be macros. -.br -.SH RETURN VALUES -.PP -Upon successful completion, these functions return -\fBOK\fR. -Otherwise, they return -\fBERR\fR. -.SH SEE ALSO -\fBncurses\fR(3X), -\fBcurs_border\fR(3X), -\fBcurs_outopts\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_clear.3x b/contrib/ncurses-5.4/man/curs_clear.3x deleted file mode 100644 index d08e852a27..0000000000 --- a/contrib/ncurses-5.4/man/curs_clear.3x +++ /dev/null @@ -1,94 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_clear.3x,v 1.7 1998/03/11 21:12:53 juergen Exp $ -.TH curs_clear 3X "" -.SH NAME -\fBerase\fR, \fBwerase\fR, \fBclear\fR, -\fBwclear\fR, \fBclrtobot\fR, \fBwclrtobot\fR, \fBclrtoeol\fR, -\fBwclrtoeol\fR - clear all or part of a \fBcurses\fR window -.SH SYNOPSIS -\fB# include \fR - -\fBint erase(void);\fR -.br -\fBint werase(WINDOW *win);\fR -.br -\fBint clear(void);\fR -.br -\fBint wclear(WINDOW *win);\fR -.br -\fBint clrtobot(void);\fR -.br -\fBint wclrtobot(WINDOW *win);\fR -.br -\fBint clrtoeol(void);\fR -.br -\fBint wclrtoeol(WINDOW *win);\fR -.br -.SH DESCRIPTION -The \fBerase\fR and \fBwerase\fR routines copy blanks to every -position in the window, clearing the screen. - -The \fBclear\fR and \fBwclear\fR routines are like \fBerase\fR and -\fBwerase\fR, but they also call \fBclearok\fR, so that the screen is -cleared completely on the next call to \fBwrefresh\fR for that window -and repainted from scratch. - -The \fBclrtobot\fR and \fBwclrtobot\fR routines erase from the cursor to the -end of screen. That is, they erase all lines below the cursor in the window. -Also, the current line to the right of the cursor, inclusive, is erased. - -The \fBclrtoeol\fR and \fBwclrtoeol\fR routines erase the current line -to the right of the cursor, inclusive, to the end of the current line. - -Blanks created by erasure have the current background rendition (as set -by \fBwbkgdset\fR) merged into them. -.SH RETURN VALUE -All routines return the integer \fBOK\fR. The SVr4.0 manual says "or a -non-negative integer if \fBimmedok\fR is set", but this appears to be an error. -.SH NOTES -Note that \fBerase\fR, \fBwerase\fR, \fBclear\fR, \fBwclear\fR, -\fBclrtobot\fR, and \fBclrtoeol\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. The -standard specifies that they return \fBERR\fR on failure, but specifies no -error conditions. - -Some historic curses implementations had, as an undocumented feature, the -ability to do the equivalent of \fBclearok(..., 1)\fR by saying -\fBtouchwin(stdscr)\fR or \fBclear(stdscr)\fR. This will not work under -ncurses. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_outopts\fR(3X), \fBcurs_refresh\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_color.3x b/contrib/ncurses-5.4/man/curs_color.3x deleted file mode 100644 index 18926d92e6..0000000000 --- a/contrib/ncurses-5.4/man/curs_color.3x +++ /dev/null @@ -1,216 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2001,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_color.3x,v 1.19 2002/02/16 22:38:32 tom Exp $ -.TH curs_color 3X "" -.SH NAME -\fBstart_color\fR, -\fBinit_pair\fR, -\fBinit_color\fR, -\fBhas_colors\fR, -\fBcan_change_color\fR, -\fBcolor_content\fR, -\fBpair_content\fR, -\fBCOLOR_PAIR\fR - \fBcurses\fR color manipulation routines -.SH SYNOPSIS -\fB# include \fR -.br -\fBint start_color(void);\fR -.br -\fBint init_pair(short pair, short f, short b);\fR -.br -\fBint init_color(short color, short r, short g, short b);\fR -.br -\fBbool has_colors(void);\fR -.br -\fBbool can_change_color(void);\fR -.br -\fBint color_content(short color, short *r, short *g, short *b);\fR -.br -\fBint pair_content(short pair, short *f, short *b);\fR -.br -.SH DESCRIPTION -.SS Overview -\fBcurses\fR support color attributes on terminals with that capability. To -use these routines \fBstart_color\fR must be called, usually right after -\fBinitscr\fR. Colors are always used in pairs (referred to as color-pairs). -A color-pair consists of a foreground color (for characters) and a background -color (for the blank field on which the characters are displayed). A -programmer initializes a color-pair with the routine \fBinit_pair\fR. After it -has been initialized, \fBCOLOR_PAIR\fR(\fIn\fR), a macro defined in -\fB\fR, can be used as a new video attribute. - -If a terminal is capable of redefining colors, the programmer can use the -routine \fBinit_color\fR to change the definition of a color. The routines -\fBhas_colors\fR and \fBcan_change_color\fR return \fBTRUE\fR or \fBFALSE\fR, -depending on whether the terminal has color capabilities and whether the -programmer can change the colors. The routine \fBcolor_content\fR allows a -programmer to extract the amounts of red, green, and blue components in an -initialized color. The routine \fBpair_content\fR allows a programmer to find -out how a given color-pair is currently defined. -.SS Routine Descriptions -The \fBstart_color\fR routine requires no arguments. It must be -called if the programmer wants to use colors, and before any other -color manipulation routine is called. It is good practice to call -this routine right after \fBinitscr\fR. \fBstart_color\fR initializes -eight basic colors (black, red, green, yellow, blue, magenta, cyan, -and white), and two global variables, \fBCOLORS\fR and -\fBCOLOR_PAIRS\fR (respectively defining the maximum number of colors -and color-pairs the terminal can support). It also restores the -colors on the terminal to the values they had when the terminal was -just turned on. - -The \fBinit_pair\fR routine changes the definition of a color-pair. It takes -three arguments: the number of the color-pair to be changed, the foreground -color number, and the background color number. -For portable applications: -.TP 5 -- -The value of the first argument -must be between \fB1\fR and \fBCOLOR_PAIRS-1\fR. -.TP 5 -- -The value of the second and -third arguments must be between 0 and \fBCOLORS\fR (the 0 color pair is wired -to white on black and cannot be changed). -.PP -If the color-pair was previously -initialized, the screen is refreshed and all occurrences of that color-pair -are changed to the new definition. - -As an extension, ncurses allows you to set color pair 0 via -the \fBassume_default_colors\fR routine, or to specify the use of -default colors (color number \fB-1\fR) if you first invoke the -\fBuse_default_colors\fR routine. - -The \fBinit_color\fR routine changes the definition of a color. It takes four -arguments: the number of the color to be changed followed by three RGB values -(for the amounts of red, green, and blue components). The value of the first -argument must be between \fB0\fR and \fBCOLORS\fR. (See the section -\fBColors\fR for the default color index.) Each of the last three arguments -must be a value between 0 and 1000. When \fBinit_color\fR is used, all -occurrences of that color on the screen immediately change to the new -definition. - -The \fBhas_colors\fR routine requires no arguments. It returns \fBTRUE\fR if -the terminal can manipulate colors; otherwise, it returns \fBFALSE\fR. This -routine facilitates writing terminal-independent programs. For example, a -programmer can use it to decide whether to use color or some other video -attribute. - -The \fBcan_change_color\fR routine requires no arguments. It returns -\fBTRUE\fR if the terminal supports colors and can change their definitions; -other, it returns \fBFALSE\fR. This routine facilitates writing -terminal-independent programs. - -The \fBcolor_content\fR routine gives programmers a way to find the intensity -of the red, green, and blue (RGB) components in a color. It requires four -arguments: the color number, and three addresses of \fBshort\fRs for storing -the information about the amounts of red, green, and blue components in the -given color. The value of the first argument must be between 0 and -\fBCOLORS\fR. The values that are stored at the addresses pointed to by the -last three arguments are between 0 (no component) and 1000 (maximum amount of -component). - -The \fBpair_content\fR routine allows programmers to find out what colors a -given color-pair consists of. It requires three arguments: the color-pair -number, and two addresses of \fBshort\fRs for storing the foreground and the -background color numbers. The value of the first argument must be between 1 -and \fBCOLOR_PAIRS-1\fR. The values that are stored at the addresses pointed -to by the second and third arguments are between 0 and \fBCOLORS\fR. -.SS Colors -In \fB\fR the following macros are defined. These are the default -colors. \fBcurses\fR also assumes that \fBCOLOR_BLACK\fR is the default -background color for all terminals. - -.nf - \fBCOLOR_BLACK\fR - \fBCOLOR_RED\fR - \fBCOLOR_GREEN\fR - \fBCOLOR_YELLOW\fR - \fBCOLOR_BLUE\fR - \fBCOLOR_MAGENTA\fR - \fBCOLOR_CYAN\fR - \fBCOLOR_WHITE\fR -.fi -.SH RETURN VALUE -The routines \fBcan_change_color()\fR and \fBhas_colors()\fR return \fBTRUE\fR -or \fBFALSE\fR. - -All other routines return the integer \fBERR\fR upon failure and an \fBOK\fR -(SVr4 specifies only "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -In the \fIncurses\fR implementation, there is a separate color activation flag, -color palette, color pairs table, and associated COLORS and COLOR_PAIRS counts -for each screen; the \fBstart_color\fR function only affects the current -screen. The SVr4/XSI interface is not really designed with this in mind, and -historical implementations may use a single shared color palette. - -Note that setting an implicit background color via a color pair affects only -character cells that a character write operation explicitly touches. To change -the background color used when parts of a window are blanked by erasing or -scrolling operations, see \fBcurs_bkgd\fR(3X). - -Several caveats apply on 386 and 486 machines with VGA-compatible graphics: -.TP 5 -- -COLOR_YELLOW is actually brown. To get yellow, use COLOR_YELLOW combined with -the \fBA_BOLD\fR attribute. -.TP 5 -- -The A_BLINK attribute should in theory cause the background to go bright. This -often fails to work, and even some cards for which it mostly works (such as the -Paradise and compatibles) do the wrong thing when you try to set a bright -"yellow" background (you get a blinking yellow foreground instead). -.TP 5 -- -Color RGB values are not settable. -.SH PORTABILITY -This implementation satisfies XSI Curses's minimum maximums -for \fBCOLORS\fR and \fBCOLOR_PAIRS\fR. -.PP -The \fBinit_pair\fP routine accepts negative values of foreground -and background color to support the \fBuse_default_colors\fP extension, -but only if that routine has been first invoked. -.PP -The assumption that \fBCOLOR_BLACK\fR is the default -background color for all terminals can be modified using the -\fBassume_default_colors\fP extension, - -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_initscr\fR(3X), -\fBcurs_attr\fR(3X), -\fBdefault_colors\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_delch.3x b/contrib/ncurses-5.4/man/curs_delch.3x deleted file mode 100644 index 34bd9ac3e2..0000000000 --- a/contrib/ncurses-5.4/man/curs_delch.3x +++ /dev/null @@ -1,70 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_delch.3x,v 1.7 2000/07/01 19:55:37 tom Exp $ -.TH curs_delch 3X "" -.SH NAME -\fBdelch\fR, -\fBwdelch\fR, -\fBmvdelch\fR, -\fBmvwdelch\fR - delete character under the cursor in a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint delch(void);\fR -.br -\fBint wdelch(WINDOW *win);\fR -.br -\fBint mvdelch(int y, int x);\fR -.br -\fBint mvwdelch(WINDOW *win, int y, int x);\fR -.br -.SH DESCRIPTION -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 \fIy\fR, \fIx\fR, if specified). (This does not -imply use of the hardware delete character feature.) -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an \fBOK\fR (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBdelch\fR, \fBmvdelch\fR, and \fBmvwdelch\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. The -standard specifies that they return \fBERR\fR on failure, but specifies no -error conditions. -.SH SEE ALSO -\fBcurses\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_deleteln.3x b/contrib/ncurses-5.4/man/curs_deleteln.3x deleted file mode 100644 index 38a5496a9b..0000000000 --- a/contrib/ncurses-5.4/man/curs_deleteln.3x +++ /dev/null @@ -1,87 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_deleteln.3x,v 1.8 2003/05/10 20:33:49 jmc Exp $ -.TH curs_deleteln 3X "" -.SH NAME -\fBdeleteln\fR, -\fBwdeleteln\fR, -\fBinsdelln\fR, -\fBwinsdelln\fR, -\fBinsertln\fR, -\fBwinsertln\fR - delete and insert lines in a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint deleteln(void);\fR -.br -\fBint wdeleteln(WINDOW *win);\fR -.br -\fBint insdelln(int n);\fR -.br -\fBint winsdelln(WINDOW *win, int n);\fR -.br -\fBint insertln(void);\fR -.br -\fBint winsertln(WINDOW *win);\fR -.br -.SH DESCRIPTION -The \fBdeleteln\fR and \fBwdeleteln\fR routines delete the line under the -cursor in the window; all lines below the current line are moved up one line. -The bottom line of the window is cleared. The cursor position does not change. - -The \fBinsdelln\fR and \fBwinsdelln\fR routines, for positive \fIn\fR, insert -\fIn\fR lines into the specified window above the current line. The \fIn\fR -bottom lines are lost. For negative \fIn\fR, delete \fIn\fR lines (starting -with the one under the cursor), and move the remaining lines up. The bottom -\fIn\fR lines are cleared. The current cursor position remains the same. - -The \fBinsertln\fR and \fBwinsertln\fR routines insert a blank line above the -current line and the bottom line is lost. -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an \fBOK\fR (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. The -standard specifies that they return \fBERR\fR on failure, but specifies no -error conditions. -.SH NOTES -Note that all but \fBwinsdelln\fR may be macros. - -These routines do not require a hardware line delete or insert feature in the -terminal. In fact, they won't use hardware line delete/insert unless -\fBidlok(..., TRUE)\fR has been set on the current window. -.SH SEE ALSO -\fBcurses\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_extend.3x b/contrib/ncurses-5.4/man/curs_extend.3x deleted file mode 100644 index 8e992e749d..0000000000 --- a/contrib/ncurses-5.4/man/curs_extend.3x +++ /dev/null @@ -1,84 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1999-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1999 -.\" -.\" $Id: curs_extend.3x,v 1.12 2003/10/25 20:33:16 tom Exp $ -.TH curs_extend 3X "" -.SH NAME -\fBcurses_version\fP, -\fBuse_extended_names\fP \- miscellaneous curses extensions - -.SH SYNOPSIS -\fB#include \fP - -\fBconst char * curses_version(void);\fP -.br -\fBint use_extended_names(bool enable);\fP -.SH DESCRIPTION -These functions are extensions to the curses library -which do not fit easily into other categories. -.PP -Use -.I curses_version() -to get the version number, including patch level of the library, e.g., -.B 5.0.19991023 -.PP -The -.I use_extended_names() -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 \fB\-x\fP option of \fItic\fP to compile -extended terminal definitions. -However you can disable this feature -to ensure compatibility with other implementations of curses. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBcurs_getch\fR(3X), -\fBcurs_mouse\fR(3X), -\fBcurs_print\fR(3X), -\fBdefault_colors\fR(3X), -\fBdefine_key\fR(3X), -\fBkeybound\fR(3X), -\fBkeyok\fR(3X), -\fBresizeterm\fR(3X), -\fBwresize\fR(3X). -.SH AUTHOR -Thomas Dickey. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_get_wch.3x b/contrib/ncurses-5.4/man/curs_get_wch.3x deleted file mode 100644 index ce723a0a65..0000000000 --- a/contrib/ncurses-5.4/man/curs_get_wch.3x +++ /dev/null @@ -1,161 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_get_wch.3x,v 1.5 2003/05/10 20:33:49 jmc Exp $ -.TH curs_get_wch 3X "" -.SH NAME -\fBget_wch\fR, -\fBwget_wch\fR, -\fBmvget_wch\fR, -\fBmvwget_wch\fR, -\fBunget_wch\fR \- get (or push back) a wide character from curses terminal keyboard -.SH SYNOPSIS -\fB#include \fR -.sp -\fBint get_wch(wint_t *\fR\fIwch\fR\fB);\fR -.br -\fBint wget_wch(WINDOW *\fR\fIwin\fR\fB, wint_t *\fR\fIwch\fR\fB);\fR -.br -\fBint mvget_wch(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwch\fR\fB);\fR -.br -\fBint mvwget_wch(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwch\fR\fB);\fR -.br -\fBint unget_wch(const wchar_t \fR\fIwch\fR\fB);\fR -.SH DESCRIPTION -The -\fBget_wch\fR, -\fBwget_wch\fR, -\fBmvget_wch\fR, and -\fBmvwget_wch\fR -functions read a character -from the terminal associated with the current or specified window. -In no-delay mode, -if no input is waiting, the value \fBERR\fR is returned. -In delay mode, -the program waits until the system passes text through to the program. -Depending on the setting of \fBcbreak\fR, -this is after one character (cbreak mode), -or after the first newline (nocbreak mode). -In half-delay mode, -the program waits until the user types a character or the specified -timeout interval has elapsed. - -Unless \fBnoecho\fR has been set, -these routines echo the character into the designated window. - -If the window is not a pad and has been moved or modified since the -last call to \fBwrefresh\fR, -\fBwrefresh\fR will be called before another character is read. - -If \fBkeypad\fR is enabled, -these functions respond to -the pressing of a function key by setting the object pointed to by -\fIwch\fR -to the corresponding -\fBKEY_\fR -value defined -in -\fB\fR -and returning -\fBKEY_CODE_YES\fR. -If a character (such as escape) that could be the -beginning of a function key is received, curses sets a timer. -If the remainder -of the sequence does arrive within the designated time, curses passes through -the character; otherwise, curses returns the function key value. -For this -reason, many terminals experience a delay between the time a user presses -the escape key and the time the escape is returned to the program. -.PP -The -\fBunget_wch\fR -function pushes the wide character -\fIwch\fR -back onto the head of the input queue, so the wide character -is returned by the next call to -\fBget_wch\fR. -The pushback of -one character is guaranteed. -If the program calls -\fBunget_wch\fR -too many times without an intervening call to -\fBget_wch\fR, -the operation may fail. -.SH NOTES -The header file -\fB\fR -automatically -includes the header file -\fB\fR. -.PP -Applications should not define the escape key by itself as a single-character -function. -.PP -When using -\fBget_wch\fR, -\fBwget_wch\fR, -\fBmvget_wch\fR, or -\fBmvwget_wch\fR, applications should -not use -\fBnocbreak\fR -mode and -\fBecho\fR -mode -at the same time. -Depending on the state of the tty driver when each character -is typed, the program may produce undesirable results. -.PP -All functions except \fBwget_wch\fR and \fBunget_wch\fR -may be macros. -.SH RETURN VALUES -When -\fBget_wch\fR, -\fBwget_wch\fR, -\fBmvget_wch\fR, and -\fBmvwget_wch\fR -functions successfully -report the pressing of a function key, they return -\fBKEY_CODE_YES\fR. -When they successfully report a wide character, they return -\fBOK\fR. -Otherwise, they return -\fBERR\fR. -.PP -Upon successful completion, -\fBunget_wch\fR -returns -\fBOK\fR. -Otherwise, the function returns -\fBERR\fR. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_getch\fR(3X), -\fBcurs_ins_wch\fR(3X), -\fBcurs_inopts\fR(3X), -\fBcurs_move\fR(3X), -\fBcurs_refresh\fR(3X) diff --git a/contrib/ncurses-5.4/man/curs_get_wstr.3x b/contrib/ncurses-5.4/man/curs_get_wstr.3x deleted file mode 100644 index 86a5b82a11..0000000000 --- a/contrib/ncurses-5.4/man/curs_get_wstr.3x +++ /dev/null @@ -1,167 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_get_wstr.3x,v 1.3 2003/07/05 11:15:28 tom Exp $ -.TH curs_get_wstr 3X "" -.SH NAME -\fBget_wstr\fR, -\fBgetn_wstr\fR, -\fBwget_wstr\fR, -\fBwgetn_wstr\fR, -\fBmvget_wstr\fR, -\fBmvgetn_wstr\fR, -\fBmvwget_wstr\fR, -\fBmvwgetn_wstr\fR \- get an array of wide characters from a curses terminal keyboard -.SH SYNOPSIS -.nf -\fB#include \fR - -\fBint get_wstr(wint_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint getn_wstr(wint_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint wget_wstr(WINDOW *\fR\fIwin\fR\fB, wint_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint wgetn_wstr(WINDOW *\fR\fIwin\fR\fB, wint_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvget_wstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvgetn_wstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwget_wstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvwgetn_wstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wint_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -The effect of -\fBget_wstr\fR -is as though a series of calls -to -\fBget_wch\fR -were made, until a newline, other end-of-line, or end-of-file condition is processed. -An end-of-file condition is represented by \fBWEOF\fR, as defined in \fB\fR. -The newline and end-of-line conditions are represented by the \fB\\n\fR \fBwchar_t\fR value. -In all instances, the end of the string is terminated by a null \fBwchar_t\fR. -The routine places resulting values in the area pointed to by \fIwstr\fR. - -The user's erase and kill characters are interpreted. If keypad -mode is on for the window, \fBKEY_LEFT\fR and \fBKEY_BACKSPACE\fR -are both considered equivalent to the user's kill character. - -Characters input are echoed only if \fBecho\fR is currently on. In that case, -backspace is echoed as deletion of the previous character (typically a left -motion). - -The effect of -\fBwget_wstr\fR -is as though a series of -calls to -\fBwget_wch\fR -were made. - -The effect of -\fBmvget_wstr\fR -is as though a call to -\fBmove\fR -and then a series of calls to -\fBget_wch\fR -were -made. - -The effect of -\fBmvwget_wstr\fR -is as though a call to -\fBwmove\fR -and then a series of calls to -\fBwget_wch\fR -were made. - -The -\fBgetn_wstr\fR, -\fBmvgetn_wstr\fR, -\fBmvwgetn_wstr\fR, and -\fBwgetn_wstr\fR -functions are identical -to the -\fBget_wstr\fR, -\fBmvget_wstr\fR, -\fBmvwget_wstr\fR, and -\fBwget_wstr\fR -functions, respectively, -except that the -\fB*n_*\fR -versions read at most -\fIn\fR -characters, letting the application prevent overflow of the -input buffer. -.SH NOTES -Using -\fBget_wstr\fR, -\fBmvget_wstr\fR, -\fBmvwget_wstr\fR, or -\fBwget_wstr\fR -to read a line that -overflows the array pointed to by -\fBwstr\fR -causes undefined -results. -The use of -\fBgetn_wstr\fR, -\fBmvgetn_wstr\fR, -\fBmvwgetn_wstr\fR, or -\fBwgetn_wstr\fR, respectively, is recommended. - -These functions cannot return \fBKEY_\fR values because there -is no way to distinguish a \fBKEY_\fR value from a valid \fBwchar_t\fR value. - -All of these routines except \fBwgetn_wstr\fR may be macros. -.SH RETURN VALUES -All of these functions return \fBOK\fR upon successful completion. -Otherwise, they return \fBERR\fR. -.SH PORTABILITY -These functions are described in The Single Unix Specification, Version 2. -No error conditions are defined. -This implementation returns ERR if the window pointer is null, -or if the lower-level \fBwget_wch\fR call returns an ERR. -In the latter case, -an ERR return without other data is treated as an end-of-file condition, -and the returned array contains a \fBWEOF\fR followed by a null \fBwchar_t\fR. -.PP -X/Open curses documents these functions to pass an array of \fBwchar_t\fR, -but all of the vendors implement this using \fBwint_t\fR. -.SH SEE ALSO -Functions: -\fBcurses\fR(3X), -\fBcurs_get_wch\fR(3X), -\fBcurs_getstr\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_getcchar.3x b/contrib/ncurses-5.4/man/curs_getcchar.3x deleted file mode 100644 index 0662317583..0000000000 --- a/contrib/ncurses-5.4/man/curs_getcchar.3x +++ /dev/null @@ -1,144 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2001-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_getcchar.3x,v 1.7 2003/05/10 20:33:49 jmc Exp $ -.TH curs_getcchar 3X "" -.SH NAME -\fBgetcchar\fP, -\fBsetcchar\fP \- Get a wide character string and rendition from a \fBcchar_t\fP or set a \fBcchar_t\fP from a wide-character string -.SH SYNOPSIS -\fB#include \fP -.sp -\fBint getcchar(\fP -.br -.B " const cchar_t *\fIwcval\fP," -.br -.B " wchar_t *\fIwch\fP," -.br -.B " attr_t *\fIattrs\fP," -.br -.B " short *\fIcolor_pair\fP," -.br -.B " void *\fIopts\fP );" -.sp -.B "int setcchar(" -.br -.B " cchar_t *\fIwcval\fP," -.br -.B " const wchar_t *\fIwch\fP," -.br -.B " const attr_t \fIattrs\fP," -.br -.B " short \fIcolor_pair\fP," -.br -.B " void *\fIopts\fP );" -.SH DESCRIPTION -.PP -The \fBgetcchar\fP function gets a wide-character string -and rendition from a \fBcchar_t\fP argument. -When \fIwch\fP is not a null pointer, -the \fBgetcchar\fP function does the following: -.TP 5 -- -Extracts information from a \fBcchar_t\fP value \fIwcval\fP -.TP 5 -- -Stores the character attributes in the location pointed to by \fIattrs\fP -.TP 5 -- -Stores the color-pair in the location pointed to by \fIcolor_pair\fP -.TP 5 -- -Stores the wide-character string, -characters referenced by \fIwcval\fP, into the array pointed to by \fIwch\fP. -.PP -When -\fIwch\fP -is a null pointer, the -\fBgetcchar\fP -function does the following: -.TP 5 -- -Obtains the number of wide characters pointed to by \fIwcval\fP -.TP 5 -- -Does not change the data referenced by -\fIattrs\fP -or -\fIcolor_pair\fP -.PP -The \fBsetcchar\fP function initializes the location pointed to by \fIwcval\fP -by using: -.TP 5 -- -The character attributes in -\fIattrs\fP -.TP 5 -- -The color pair in -\fIcolor_pair\fP -.TP 5 -- -The wide-character string pointed to by \fIwch\fP. -The string must be L'\\0' terminated, -contain at most one character with strictly positive width, -which must be the first, -and contain no characters of negative width. -.SH NOTES -.PP -The \fIopts\fP argument is reserved for future use. -Currently, an application must provide a null pointer as \fIopts\fP. -.PP -The \fIwcval\fP argument may be a value generated by a call to -\fBsetcchar\fP or by a function that has a \fBcchar_t\fP output argument. -If \fIwcval\fP is constructed by any other means, the effect is unspecified. -.SH RETURN VALUES -.PP -When \fIwch\fP is a null pointer, -\fBgetcchar\fP returns the number of wide characters referenced by -\fIwcval\fP, including the null terminator. -.PP -When \fIwch\fP is not a null pointer, -\fBgetcchar\fP returns \fBOK\fP upon successful completion, -and \fBERR\fP otherwise. -.PP -Upon successful completion, \fBsetcchar\fP returns \fBOK\fP. -Otherwise, it returns \fBERR\fP. -.SH SEE ALSO -.PP -Functions: -\fBcurses\fR(3X), -\fBwcwidth\fR(3X), -\fBcurs_attr_get\fR(3X), -\fBcan_change_color\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_getch.3x b/contrib/ncurses-5.4/man/curs_getch.3x deleted file mode 100644 index 88003a5d9d..0000000000 --- a/contrib/ncurses-5.4/man/curs_getch.3x +++ /dev/null @@ -1,307 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_getch.3x,v 1.24 2003/12/27 18:46:06 tom Exp $ -.TH curs_getch 3X "" -.SH NAME -\fBgetch\fR, -\fBwgetch\fR, -\fBmvgetch\fR, -\fBmvwgetch\fR, -\fBungetch\fR, -\fBhas_key\fR \- get (or push back) characters from \fBcurses\fR terminal keyboard -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint getch(void);\fR -.br -\fBint wgetch(WINDOW *win);\fR -.br -\fBint mvgetch(int y, int x);\fR -.br -\fBint mvwgetch(WINDOW *win, int y, int x);\fR -.br -\fBint ungetch(int ch);\fR -.br -\fBint has_key(int ch);\fR -.br -.SH DESCRIPTION -The \fBgetch\fR, \fBwgetch\fR, \fBmvgetch\fR and \fBmvwgetch\fR, routines read -a character from the window. -In no-delay mode, if no input is waiting, the value \fBERR\fR is returned. -In delay mode, the program waits until the system -passes text through to the program. -Depending on the setting of \fBcbreak\fR, -this is after one character (cbreak mode), -or after the first newline (nocbreak mode). -In half-delay mode, -the program waits until a character is typed or the -specified timeout has been reached. -.PP -Unless \fBnoecho\fR has been set, -then the character will also be echoed into the -designated window according to the following rules: -If the character is the current erase character, left arrow, or backspace, -the cursor is moved one space to the left and that screen position is erased -as if \fBdelch\fR had been called. -If the character value is any other \fBKEY_\fR define, the user is alerted -with a \fBbeep\fR call. -Otherwise the character is simply output to the screen. -.PP -If the window is not a pad, and it has been moved or modified since the last -call to \fBwrefresh\fR, \fBwrefresh\fR will be called before another character -is read. -.PP -If \fBkeypad\fR is \fBTRUE\fR, and a function key is pressed, the token for -that function key is returned instead of the raw characters. -Possible function -keys are defined in \fB\fR as macros with values outside the range -of 8-bit characters whose names begin with \fBKEY_\fR. Thus, a variable -intended to hold the return value of a function key must be of short size or -larger. -.PP -When a character that could be the beginning of a function key is received -(which, on modern terminals, means an escape character), -\fBcurses\fR sets a timer. -If the remainder of the sequence does not come in within the designated -time, the character is passed through; -otherwise, the function key value is returned. -For this reason, many terminals experience a delay between the time -a user presses the escape key and the escape is returned to the program. -.PP -The \fBungetch\fR routine places \fIch\fR back onto the input queue to be -returned by the next call to \fBwgetch\fR. -There is just one input queue for all windows. -.PP -.SS Function Keys -The following function keys, defined in \fB\fR, might be returned by -\fBgetch\fR if \fBkeypad\fR has been enabled. -Note that not all of these are -necessarily supported on any particular terminal. -.sp -.TS -center tab(/) ; -l l -l l . -\fIName\fR/\fIKey\fR \fIname\fR -.PP -KEY_BREAK/Break key -KEY_DOWN/The four arrow keys ... -KEY_UP -KEY_LEFT -KEY_RIGHT -KEY_HOME/Home key (upward+left arrow) -KEY_BACKSPACE/Backspace -KEY_F0/T{ -Function keys; space for 64 keys is reserved. -T} -KEY_F(\fIn\fR)/T{ -For 0 \(<= \fIn\fR \(<= 63 -T} -KEY_DL/Delete line -KEY_IL/Insert line -KEY_DC/Delete character -KEY_IC/Insert char or enter insert mode -KEY_EIC/Exit insert char mode -KEY_CLEAR/Clear screen -KEY_EOS/Clear to end of screen -KEY_EOL/Clear to end of line -KEY_SF/Scroll 1 line forward -KEY_SR/Scroll 1 line backward (reverse) -KEY_NPAGE/Next page -KEY_PPAGE/Previous page -KEY_STAB/Set tab -KEY_CTAB/Clear tab -KEY_CATAB/Clear all tabs -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 -KEY_BTAB/Back tab key -KEY_BEG/Beg(inning) key -KEY_CANCEL/Cancel key -KEY_CLOSE/Close key -KEY_COMMAND/Cmd (command) key -KEY_COPY/Copy key -KEY_CREATE/Create key -KEY_END/End key -KEY_EXIT/Exit key -KEY_FIND/Find key -KEY_HELP/Help key -KEY_MARK/Mark key -KEY_MESSAGE/Message key -KEY_MOUSE/Mouse event read -KEY_MOVE/Move key -KEY_NEXT/Next object key -KEY_OPEN/Open key -KEY_OPTIONS/Options key -KEY_PREVIOUS/Previous object key -KEY_REDO/Redo key -KEY_REFERENCE/Ref(erence) key -KEY_REFRESH/Refresh key -KEY_REPLACE/Replace key -KEY_RESIZE/Screen resized -KEY_RESTART/Restart key -KEY_RESUME/Resume key -KEY_SAVE/Save key -KEY_SBEG/Shifted beginning key -KEY_SCANCEL/Shifted cancel key -KEY_SCOMMAND/Shifted command key -KEY_SCOPY/Shifted copy key -KEY_SCREATE/Shifted create key -KEY_SDC/Shifted delete char key -KEY_SDL/Shifted delete line key -KEY_SELECT/Select key -KEY_SEND/Shifted end key -KEY_SEOL/Shifted clear line key -KEY_SEXIT/Shifted exit key -KEY_SFIND/Shifted find key -KEY_SHELP/Shifted help key -KEY_SHOME/Shifted home key -KEY_SIC/Shifted input key -KEY_SLEFT/Shifted left arrow key -KEY_SMESSAGE/Shifted message key -KEY_SMOVE/Shifted move key -KEY_SNEXT/Shifted next key -KEY_SOPTIONS/Shifted options key -KEY_SPREVIOUS/Shifted prev key -KEY_SPRINT/Shifted print key -KEY_SREDO/Shifted redo key -KEY_SREPLACE/Shifted replace key -KEY_SRIGHT/Shifted right arrow -KEY_SRSUME/Shifted resume key -KEY_SSAVE/Shifted save key -KEY_SSUSPEND/Shifted suspend key -KEY_SUNDO/Shifted undo key -KEY_SUSPEND/Suspend key -KEY_UNDO/Undo key -.TE -.PP -Keypad is arranged like this: -.sp -.TS -center allbox tab(/) ; -c c c . -\fBA1\fR/\fBup\fR/\fBA3\fR -\fBleft\fR/\fBB2\fR/\fBright\fR -\fBC1\fR/\fBdown\fR/\fBC3\fR -.TE -.sp -The \fBhas_key\fR routine takes a key value from the above list, and -returns TRUE or FALSE according to whether -the current terminal type recognizes a key with that value. -Note that a few values do not correspond to a real key, -e.g., KEY_RESIZE and KEY_MOUSE. -.PP -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an integer value -other than \fBERR\fR (\fBOK\fR in the case of ungetch()) upon successful -completion. -.SH NOTES -Use of the escape key by a programmer for a single character function is -discouraged, as it will cause a delay of up to one second while the -keypad code looks for a following function-key sequence. -.PP -Note that some keys may be the same as commonly used control -keys, e.g., KEY_ENTER versus control/M, KEY_BACKSPACE versus control/H. -Some curses implementations may differ according to whether they -treat these control keys specially (and ignore the terminfo), or -use the terminfo definitions. -\fBNcurses\fR uses the terminfo definition. -If it says that KEY_ENTER is control/M, \fBgetch\fR will return KEY_ENTER -when you press control/M. -.PP -When using \fBgetch\fR, \fBwgetch\fR, \fBmvgetch\fR, or -\fBmvwgetch\fR, nocbreak mode (\fBnocbreak\fR) and echo mode -(\fBecho\fR) should not be used at the same time. -Depending on the -state of the tty driver when each character is typed, the program may -produce undesirable results. -.PP -Note that \fBgetch\fR, \fBmvgetch\fR, and \fBmvwgetch\fR may be macros. -.PP -Historically, the set of keypad macros was largely defined by the extremely -function-key-rich keyboard of the AT&T 7300, aka 3B1, aka Safari 4. -Modern -personal computers usually have only a small subset of these. -IBM PC-style -consoles typically support little more than \fBKEY_UP\fR, \fBKEY_DOWN\fR, -\fBKEY_LEFT\fR, \fBKEY_RIGHT\fR, \fBKEY_HOME\fR, \fBKEY_END\fR, -\fBKEY_NPAGE\fR, \fBKEY_PPAGE\fR, and function keys 1 through 12. -The Ins key -is usually mapped to \fBKEY_IC\fR. -.SH PORTABILITY -The *get* functions are described in the XSI Curses standard, Issue 4. -They -read single-byte characters only. -The standard specifies that they return -\fBERR\fR on failure, but specifies no error conditions. -.PP -The echo behavior of these functions on input of \fBKEY_\fR or backspace -characters was not specified in the SVr4 documentation. -This description is -adopted from the XSI Curses standard. -.PP -The behavior of \fBgetch\fR and friends in the presence of handled signals is -unspecified in the SVr4 and XSI Curses documentation. -Under historical curses -implementations, it varied depending on whether the operating system's -implementation of handled signal receipt interrupts a \fBread\fR(2) call in -progress or not, and also (in some implementations) depending on whether an -input timeout or non-blocking mode has been set. -.PP -Programmers concerned about portability should be prepared for either of two -cases: (a) signal receipt does not interrupt \fBgetch\fR; (b) signal receipt -interrupts \fBgetch\fR and causes it to return ERR with \fBerrno\fR set to -\fBEINTR\fR. -Under the \fBncurses\fR implementation, handled signals never -interrupt \fBgetch\fR. -.PP -The \fBhas_key\fR function is unique to \fBncurses\fR. -We recommend that -any code using it be conditionalized on the \fBNCURSES_VERSION\fR feature macro. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_inopts\fR(3X), -\fBcurs_mouse\fR(3X), -\fBcurs_move\fR(3X), -\fBcurs_refresh\fR(3X). -\fBresizeterm\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_getstr.3x b/contrib/ncurses-5.4/man/curs_getstr.3x deleted file mode 100644 index ffbd288724..0000000000 --- a/contrib/ncurses-5.4/man/curs_getstr.3x +++ /dev/null @@ -1,107 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_getstr.3x,v 1.12 2003/05/10 20:33:49 jmc Exp $ -.TH curs_getstr 3X "" -.SH NAME -\fBgetstr\fR, -\fBgetnstr\fR, -\fBwgetstr\fR, -\fBwgetnstr\fR, -\fBmvgetstr\fR, -\fBmvgetnstr\fR, -\fBmvwgetstr\fR, -\fBmvwgetnstr\fR - accept character strings from \fBcurses\fR terminal keyboard -.SH SYNOPSIS -\fB#include \fR - -\fBint getstr(char *str);\fR -.br -\fBint getnstr(char *str, int n);\fR -.br -\fBint wgetstr(WINDOW *win, char *str);\fR -.br -\fBint wgetnstr(WINDOW *win, char *str, int n);\fR -.br -\fBint mvgetstr(int y, int x, char *str);\fR -.br -\fBint mvwgetstr(WINDOW *win, int y, int x, char *str);\fR -.br -\fBint mvgetnstr(int y, int x, char *str, int n);\fR -.br -\fBint mvwgetnstr(WINDOW *, int y, int x, char *str, int n);\fR -.br -.SH DESCRIPTION -The function \fBgetstr\fR is equivalent to a series of calls to \fBgetch\fR, -until a newline or carriage return is received (the terminating character is -not included in the returned string). The resulting value is placed in the -area pointed to by the character pointer \fIstr\fR. - -\fBwgetnstr\fR reads at most \fIn\fR characters, thus preventing a possible -overflow of the input buffer. Any attempt to enter more characters (other -than the terminating newline or carriage return) causes a beep. Function -keys also cause a beep and are ignored. The \fBgetnstr\fR function reads -from the \fIstdscr\fR default window. - -The user's erase and kill characters are interpreted. If keypad -mode is on for the window, \fBKEY_LEFT\fR and \fBKEY_BACKSPACE\fR -are both considered equivalent to the user's kill character. - -Characters input are echoed only if \fBecho\fR is currently on. In that case, -backspace is echoed as deletion of the previous character (typically a left -motion). -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an \fBOK\fR (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBgetstr\fR, \fBmvgetstr\fR, and \fBmvwgetstr\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -They read single-byte characters only. -The standard does not define any error conditions. -This implementation returns ERR if the window pointer is null, -or if the lower-level \fBwgetch\fR call returns an ERR. - -SVr3 and early SVr4 curses implementations did not reject function keys; -the SVr4.0 documentation claimed that "special keys" (such as function -keys, "home" key, "clear" key, \fIetc\fR.) are "interpreted", without -giving details. It lied. In fact, the `character' value appended to the -string by those implementations was predictable but not useful -(being, in fact, the low-order eight bits of the key's KEY_ value). - -The functions \fBgetnstr\fR, \fBmvgetnstr\fR, and \fBmvwgetnstr\fR were -present but not documented in SVr4. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_getch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_getyx.3x b/contrib/ncurses-5.4/man/curs_getyx.3x deleted file mode 100644 index 1e1a6eff1f..0000000000 --- a/contrib/ncurses-5.4/man/curs_getyx.3x +++ /dev/null @@ -1,89 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_getyx.3x,v 1.10 2003/05/10 20:33:49 jmc Exp $ -.TH curs_getyx 3X "" -.SH NAME -\fBgetyx\fR, -\fBgetparyx\fR, -\fBgetbegyx\fR, -\fBgetmaxyx\fR - get \fBcurses\fR cursor and window coordinates -.SH SYNOPSIS -\fB#include \fR - -\fBvoid getyx(WINDOW *win, int y, int x);\fR -.br -\fBvoid getparyx(WINDOW *win, int y, int x);\fR -.br -\fBvoid getbegyx(WINDOW *win, int y, int x);\fR -.br -\fBvoid getmaxyx(WINDOW *win, int y, int x);\fR -.br -.SH DESCRIPTION -The \fBgetyx\fR macro places the current cursor position of the given window in -the two integer variables \fIy\fR and \fIx\fR. - -If \fIwin\fR is a subwindow, the \fBgetparyx\fR macro places the beginning -coordinates of the subwindow relative to the parent window into two integer -variables \fIy\fR and \fIx\fR. -Otherwise, \fB-1\fR is placed into \fIy\fR and \fIx\fR. - -Like \fBgetyx\fR, the \fBgetbegyx\fR and \fBgetmaxyx\fR macros store -the current beginning coordinates and size of the specified window. -.SH RETURN VALUE -The return values of these macros are undefined (i.e., -they should not be used as the right-hand side of assignment statements). -.SH NOTES -All of these interfaces are macros. -A "\fB&\fR" is not necessary before the variables \fIy\fR and \fIx\fR. -.SH PORTABILITY -The -\fBgetyx\fR, -\fBgetparyx\fR, -\fBgetbegyx\fR and -\fBgetmaxyx\fR -functions are described in the XSI Curses standard, Issue 4. -.PP -This implementation also provides -\fBgetbegx\fR, -\fBgetbegy\fR, -\fBgetcurx\fR, -\fBgetcury\fR, -\fBgetmaxx\fR, -\fBgetmaxy\fR, -\fBgetparx\fR and -\fBgetpary\fR -for compatibility with older versions of curses. -.SH SEE ALSO -\fBcurses\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_in_wch.3x b/contrib/ncurses-5.4/man/curs_in_wch.3x deleted file mode 100644 index 668595c6f3..0000000000 --- a/contrib/ncurses-5.4/man/curs_in_wch.3x +++ /dev/null @@ -1,68 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_in_wch.3x,v 1.1 2002/03/10 15:08:57 tom Exp $ -.TH curs_in_wch 3X "" -.SH NAME -\fBin_wch\fR, -\fBmvin_wch\fR, -\fBmvwin_wch\fR, -\fBwin_wch\fR - extract a complex character and rendition from a window -.SH SYNOPSIS -\fB#include \fR - -\fBint in_wch(cchar_t *\fR\fIwcval\fR\fB);\fR -.br -\fBint mvin_wch(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwcval\fR\fB);\fR -.br -\fBint mvwin_wch(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwcval\fR\fB);\fR -.br -\fBint win_wch(WINDOW *\fR\fIwin\fR\fB, cchar_t *\fR\fIwcval\fR\fB);\fR -.SH DESCRIPTION -These functions extract the complex character and rendition from -the current position in the named window into the \fBcchar_t\fR object -referenced by wcval. -.SH RETURN VALUE -No errors are defined in the XSI Curses standard. -This implementation checks for null pointers, returns ERR in that case. -Also, the \fImv\fR routines check for error moving the cursor, returning ERR -in that case. -Otherwise they return OK -.SH NOTES -Note that all of these routines may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_inch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_in_wchstr.3x b/contrib/ncurses-5.4/man/curs_in_wchstr.3x deleted file mode 100644 index 0012789f70..0000000000 --- a/contrib/ncurses-5.4/man/curs_in_wchstr.3x +++ /dev/null @@ -1,117 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_in_wchstr.3x,v 1.2 2002/05/18 21:48:30 tom Exp $ -.TH curs_in_wchstr 3X "" -.SH NAME -\fBin_wchstr\fR, -\fBin_wchnstr\fR, -\fBwin_wchstr\fR, -\fBwin_wchnstr\fR, -\fBmvin_wchstr\fR, -\fBmvin_wchnstr\fR, -\fBmvwin_wchstr\fR, -\fBmvwin_wchnstr\fR \- get an array of complex characters and renditions from a curses window -.SH SYNOPSIS -.nf -\fB#include \fR - -\fBint in_wchstr(cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint in_wchnstr(cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint win_wchstr(WINDOW *\fR\fIwin\fR\fB, cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint win_wchnstr(WINDOW *\fR\fIwin\fR\fB, cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvin_wchstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint mvin_wchnstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwchstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwin_wchstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwchstr\fR\fB);\fR -.br -\fBint mvwin_wchnstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, cchar_t *\fR\fIwchstr\fR, int \fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These functions return an array of complex characters in \fIwchstr\fR, -starting at the current cursor position in the named window. -Attributes (rendition) are stored with the characters. -.PP -The -\fBin_wchnstr\fR, -\fBmvin_wchnstr\fR, -\fBmvwin_wchnstr\fR -and -\fBwin_wchnstr\fR -fill the array -with at most -\fIn\fR -\fBcchar_t\fR -elements. -.br -.SH NOTES -Note that all routines except -\fBwin_wchnstr\fR -may be -macros. -.PP -Reading a line that overflows the array pointed to by -\fIwchstr\fR -with -\fBin_wchstr\fR, -\fBmvin_wchstr\fR, -\fBmvwin_wchstr\fR -or -\fBwin_wchstr\fR -causes undefined results. Therefore, the use of -\fBin_wchnstr\fR, -\fBmvin_wchnstr\fR, -\fBmvwin_wchnstr\fR, or -\fBwin_wchnstr\fR -is recommended. -.SH RETURN VALUES -Upon successful completion, these functions return -\fBOK\fR. -Otherwise, they return -\fBERR\fR. -.SH PORTABILITY -The XSI Curses defines no error conditions. -This implementation checks for null pointers, -returning ERR in that case. -.SH SEE ALSO -Functions: -\fBcurses\fR(3X), -\fBcurs_in_wch\fR(3X) -\fBcurs_instr\fR(3X), -\fBcurs_inwstr\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_inch.3x b/contrib/ncurses-5.4/man/curs_inch.3x deleted file mode 100644 index bcc8d6f85c..0000000000 --- a/contrib/ncurses-5.4/man/curs_inch.3x +++ /dev/null @@ -1,73 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_inch.3x,v 1.11 1998/11/29 01:04:34 Rick.Ohnemus Exp $ -.TH curs_inch 3X "" -.SH NAME -\fBinch\fR, \fBwinch\fR, \fBmvinch\fR, \fBmvwinch\fR -- get a character and attributes from a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBchtype inch(void);\fR -.br -\fBchtype winch(WINDOW *win);\fR -.br -\fBchtype mvinch(int y, int x);\fR -.br -\fBchtype mvwinch(WINDOW *win, int y, int x);\fR -.br -.SH DESCRIPTION -These routines return the character, of type \fBchtype\fR, at the current -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 -\fB\fR can be used with the \fB&\fR (logical AND) operator to -extract the character or attributes alone. - -.SS Attributes -The following bit-masks may be AND-ed with characters returned by \fBwinch\fR. - -.TS -l l . -\fBA_CHARTEXT\fR Bit-mask to extract character -\fBA_ATTRIBUTES\fR Bit-mask to extract attributes -\fBA_COLOR\fR Bit-mask to extract color-pair field information -.TE -.SH NOTES -Note that all of these routines may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_inchstr.3x b/contrib/ncurses-5.4/man/curs_inchstr.3x deleted file mode 100644 index 60f9d566e9..0000000000 --- a/contrib/ncurses-5.4/man/curs_inchstr.3x +++ /dev/null @@ -1,88 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_inchstr.3x,v 1.8 2000/07/01 20:16:18 tom Exp $ -.TH curs_inchstr 3X "" -.SH NAME -\fBinchstr\fR, -\fBinchnstr\fR, -\fBwinchstr\fR, -\fBwinchnstr\fR, -\fBmvinchstr\fR, -\fBmvinchnstr\fR, -\fBmvwinchstr\fR, -\fBmvwinchnstr\fR - get a string of characters (and attributes) from a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint inchstr(chtype *chstr);\fR -.br -\fBint inchnstr(chtype *chstr, int n);\fR -.br -\fBint winchstr(WINDOW *win, chtype *chstr);\fR -.br -\fBint winchnstr(WINDOW *win, chtype *chstr, int n);\fR -.br -\fBint mvinchstr(int y, int x, chtype *chstr);\fR -.br -\fBint mvinchnstr(int y, int x, chtype *chstr, int n);\fR -.br -\fBint mvwinchstr(WINDOW *win, int y, int x, chtype *chstr);\fR -.br -\fBint mvwinchnstr(WINDOW *win, int y, int x, chtype *chstr, int n);\fR -.br -.SH DESCRIPTION -These routines return a NULL-terminated array of \fBchtype\fR quantities, -starting at the current cursor position in the named window and ending at the -right margin of the window. The four functions with \fIn\fR as -the last argument, return a leading substring at most \fIn\fR characters long -(exclusive of the trailing (chtype)0). -Constants defined in \fB\fR can be used with the \fB&\fR (logical -AND) operator to extract the character or the attribute alone from any position -in the \fIchstr\fR [see \fBcurs_inch\fR(3X)]. -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an integer value -other than \fBERR\fR upon successful completion (the number of characters -retrieved, exclusive of the trailing 0). -.SH NOTES -Note that all routines except \fBwinchnstr\fR may be macros. SVr4 does not -document whether the result string is 0-terminated; it does not document -whether a length limit argument includes any trailing 0; and it does not -document the meaning of the return value. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. It is no -more specific than the SVr4 documentation on the trailing 0. It does specify -that the successful return of the functions is \fBOK\fR. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_inch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_initscr.3x b/contrib/ncurses-5.4/man/curs_initscr.3x deleted file mode 100644 index 02f149dff7..0000000000 --- a/contrib/ncurses-5.4/man/curs_initscr.3x +++ /dev/null @@ -1,124 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_initscr.3x,v 1.12 2003/05/10 20:33:49 jmc Exp $ -.TH curs_initscr 3X "" -.SH NAME -\fBinitscr\fR, -\fBnewterm\fR, -\fBendwin\fR, -\fBisendwin\fR, -\fBset_term\fR, -\fBdelscreen\fR - \fBcurses\fR screen initialization and manipulation routines -.SH SYNOPSIS -\fB#include \fR - -\fBWINDOW *initscr(void);\fR -.br -\fBint endwin(void);\fR -.br -\fBbool isendwin(void);\fR -.br -\fBSCREEN *newterm(char *type, FILE *outfd, FILE *infd);\fR -.br -\fBSCREEN *set_term(SCREEN *new);\fR -.br -\fBvoid delscreen(SCREEN* sp);\fR -.br -.SH DESCRIPTION -\fBinitscr\fR is normally the first \fBcurses\fR routine to call when -initializing a program. A few special routines sometimes need to be -called before it; these are \fBslk_init\fR, \fBfilter\fR, \fBripoffline\fR, -\fBuse_env\fR. For multiple-terminal applications, \fBnewterm\fR may be -called before \fBinitscr\fR. - -The initscr code determines the terminal type and initializes all \fBcurses\fR -data structures. \fBinitscr\fR also causes the first call to \fBrefresh\fR to -clear the screen. If errors occur, \fBinitscr\fR writes an appropriate error -message to standard error and exits; otherwise, a pointer is returned to -\fBstdscr\fR. - -A program that outputs to more than one terminal should use the \fBnewterm\fR -routine for each terminal instead of \fBinitscr\fR. A program that needs to -inspect capabilities, so it can continue to run in a line-oriented mode if the -terminal cannot support a screen-oriented program, would also use -\fBnewterm\fR. The routine \fBnewterm\fR should be called once for each -terminal. It returns a variable of type \fBSCREEN *\fR which should be saved -as a reference to that terminal. The arguments are the \fItype\fR of the -terminal to be used in place of \fB$TERM\fR, a file pointer for output to the -terminal, and another file pointer for input from the terminal (if \fItype\fR -is \fBNULL\fR, \fB$TERM\fR will be used). The program must also call -\fBendwin\fR for each terminal being used before exiting from \fBcurses\fR. -If \fBnewterm\fR is called more than once for the same terminal, the first -terminal referred to must be the last one for which \fBendwin\fR is called. - -A program should always call \fBendwin\fR before exiting or escaping from -\fBcurses\fR mode temporarily. This routine restores tty modes, moves the -cursor to the lower left-hand corner of the screen and resets the terminal into -the proper non-visual mode. Calling \fBrefresh\fR or \fBdoupdate\fR after a -temporary escape causes the program to resume visual mode. - -The \fBisendwin\fR routine returns \fBTRUE\fR if \fBendwin\fR has been -called without any subsequent calls to \fBwrefresh\fR, and \fBFALSE\fR -otherwise. - -The \fBset_term\fR routine is used to switch between different -terminals. The screen reference \fBnew\fR becomes the new current -terminal. The previous terminal is returned by the routine. This is -the only routine which manipulates \fBSCREEN\fR pointers; all other -routines affect only the current terminal. - -The \fBdelscreen\fR routine frees storage associated with the -\fBSCREEN\fR data structure. The \fBendwin\fR routine does not do -this, so \fBdelscreen\fR should be called after \fBendwin\fR if a -particular \fBSCREEN\fR is no longer needed. -.SH RETURN VALUE -\fBendwin\fR returns the integer \fBERR\fR upon failure and \fBOK\fR -upon successful completion. - -Routines that return pointers always return \fBNULL\fR on error. -.SH NOTES -Note that \fBinitscr\fR and \fBnewterm\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. It -specifies that portable applications must not call \fBinitscr\fR more than -once. - -Old versions of curses, e.g., BSD 4.4, may have returned a null pointer -from \fBinitscr\fR when an error is detected, rather than exiting. -It is safe but redundant to check the return value of \fBinitscr\fR -in XSI Curses. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_kernel\fR(3X), \fBcurs_refresh\fR(3X), -\fBcurs_slk\fR(3X), \fBcurs_util\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_inopts.3x b/contrib/ncurses-5.4/man/curs_inopts.3x deleted file mode 100644 index 24a9bd6145..0000000000 --- a/contrib/ncurses-5.4/man/curs_inopts.3x +++ /dev/null @@ -1,214 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_inopts.3x,v 1.11 2003/12/27 18:45:42 tom Exp $ -.TH curs_inopts 3X "" -.SH NAME -\fBcbreak\fR, \fBnocbreak\fR, \fBecho\fR, -\fBnoecho\fR, \fBhalfdelay\fR, \fBintrflush\fR, \fBkeypad\fR, -\fBmeta\fR, \fBnodelay\fR, \fBnotimeout\fR, \fBraw\fR, \fBnoraw\fR, -\fBnoqiflush\fR, \fBqiflush\fR, \fBtimeout\fR, \fBwtimeout\fR, -\fBtypeahead\fR - \fBcurses\fR input options -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint cbreak(void);\fR -.br -\fBint nocbreak(void);\fR -.br -\fBint echo(void);\fR -.br -\fBint noecho(void);\fR -.br -\fBint halfdelay(int tenths);\fR -.br -\fBint intrflush(WINDOW *win, bool bf);\fR -.br -\fBint keypad(WINDOW *win, bool bf);\fR -.br -\fBint meta(WINDOW *win, bool bf);\fR -.br -\fBint nodelay(WINDOW *win, bool bf);\fR -.br -\fBint raw(void);\fR -.br -\fBint noraw(void);\fR -.br -\fBvoid noqiflush(void);\fR -.br -\fBvoid qiflush(void);\fR -.br -\fBint notimeout(WINDOW *win, bool bf);\fR -.br -\fBvoid timeout(int delay);\fR -.br -\fBvoid wtimeout(WINDOW *win, int delay);\fR -.br -\fBint typeahead(int fd);\fR -.br -.SH DESCRIPTION -Normally, the tty driver buffers typed characters until a newline or carriage -return is typed. The \fBcbreak\fR routine disables line buffering and -erase/kill character-processing (interrupt and flow control characters are -unaffected), making characters typed by the user immediately available to the -program. The \fBnocbreak\fR routine returns the terminal to normal (cooked) -mode. -.PP -Initially the terminal may or may not be in \fBcbreak\fR mode, as the mode is -inherited; therefore, a program should call \fBcbreak\fR or \fBnocbreak\fR -explicitly. Most interactive programs using \fBcurses\fR set the \fBcbreak\fR -mode. Note that \fBcbreak\fR overrides \fBraw\fR. -[See \fBcurs_getch\fR(3X) for a -discussion of how these routines interact with \fBecho\fR and \fBnoecho\fR.] -.PP -The \fBecho\fR and \fBnoecho\fR routines control whether characters typed by -the user are echoed by \fBgetch\fR as they are typed. Echoing by the tty -driver is always disabled, but initially \fBgetch\fR is in echo mode, so -characters typed are echoed. Authors of most interactive programs prefer to do -their own echoing in a controlled area of the screen, or not to echo at all, so -they disable echoing by calling \fBnoecho\fR. -[See \fBcurs_getch\fR(3X) for a -discussion of how these routines interact with \fBcbreak\fR and -\fBnocbreak\fR.] -.PP -The \fBhalfdelay\fR routine is used for half-delay mode, which is similar to -\fBcbreak\fR mode in that characters typed by the user are immediately -available to the program. However, after blocking for \fItenths\fR tenths of -seconds, ERR is returned if nothing has been typed. The value of \fBtenths\fR -must be a number between 1 and 255. Use \fBnocbreak\fR to leave half-delay -mode. -.PP -If the \fBintrflush\fR option is enabled, (\fIbf\fR is \fBTRUE\fR), when an -interrupt key is pressed on the keyboard (interrupt, break, quit) all output in -the tty driver queue will be flushed, giving the effect of faster response to -the interrupt, but causing \fBcurses\fR to have the wrong idea of what is on -the screen. Disabling (\fIbf\fR is \fBFALSE\fR), the option prevents the -flush. The default for the option is inherited from the tty driver settings. -The window argument is ignored. -.PP -The \fBkeypad\fR option enables the keypad of the user's terminal. If -enabled (\fIbf\fR is \fBTRUE\fR), the user can press a function key -(such as an arrow key) and \fBwgetch\fR returns a single value -representing the function key, as in \fBKEY_LEFT\fR. If disabled -(\fIbf\fR is \fBFALSE\fR), \fBcurses\fR does not treat function keys -specially and the program has to interpret the escape sequences -itself. If the keypad in the terminal can be turned on (made to -transmit) and off (made to work locally), turning on this option -causes the terminal keypad to be turned on when \fBwgetch\fR is -called. The default value for keypad is false. -.PP -Initially, whether the terminal returns 7 or 8 significant bits on -input depends on the control mode of the tty driver [see termio(7)]. -To force 8 bits to be returned, invoke \fBmeta\fR(\fIwin\fR, -\fBTRUE\fR); this is equivalent, under POSIX, to setting the CS8 flag -on the terminal. To force 7 bits to be returned, invoke -\fBmeta\fR(\fIwin\fR, \fBFALSE\fR); this is equivalent, under POSIX, -to setting the CS7 flag on the terminal. The window argument, -\fIwin\fR, is always ignored. If the terminfo capabilities \fBsmm\fR -(meta_on) and \fBrmm\fR (meta_off) are defined for the terminal, -\fBsmm\fR is sent to the terminal when \fBmeta\fR(\fIwin\fR, -\fBTRUE\fR) is called and \fBrmm\fR is sent when \fBmeta\fR(\fIwin\fR, -\fBFALSE\fR) is called. -.PP -The \fBnodelay\fR option causes \fBgetch\fR to be a non-blocking call. -If no input is ready, \fBgetch\fR returns \fBERR\fR. If disabled -(\fIbf\fR is \fBFALSE\fR), \fBgetch\fR waits until a key is pressed. -.PP -While interpreting an input escape sequence, \fBwgetch\fR sets a timer -while waiting for the next character. If \fBnotimeout(\fR\fIwin\fR, -\fBTRUE\fR) is called, then \fBwgetch\fR 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. -.PP -The \fBraw\fR and \fBnoraw\fR routines place the terminal into or out of raw -mode. Raw mode is similar to \fBcbreak\fR mode, in that characters typed are -immediately 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 -\fBcurses\fR. -.PP -When the \fBnoqiflush\fR routine is used, normal flush of input and -output queues associated with the \fBINTR\fR, \fBQUIT\fR and -\fBSUSP\fR characters will not be done [see termio(7)]. When -\fBqiflush\fR is called, the queues will be flushed when these control -characters are read. You may want to call \fBnoqiflush()\fR in a signal -handler if you want output to continue as though the interrupt -had not occurred, after the handler exits. -.PP -The \fBtimeout\fR and \fBwtimeout\fR routines set blocking or -non-blocking read for a given window. If \fIdelay\fR is negative, -blocking read is used (i.e., waits indefinitely for -input). If \fIdelay\fR is zero, then non-blocking read is used -(i.e., read returns \fBERR\fR if no input is waiting). If -\fIdelay\fR is positive, then read blocks for \fIdelay\fR -milliseconds, and returns \fBERR\fR if there is still no input. -Hence, these routines provide the same functionality as \fBnodelay\fR, -plus the additional capability of being able to block for only -\fIdelay\fR milliseconds (where \fIdelay\fR is positive). -.PP -The \fBcurses\fR library does ``line-breakout optimization'' by looking for -typeahead periodically while updating the screen. If input is found, -and it is coming from a tty, the current update is postponed until -\fBrefresh\fR or \fBdoupdate\fR is called again. This allows faster -response to commands typed in advance. Normally, the input FILE -pointer passed to \fBnewterm\fR, or \fBstdin\fR in the case that -\fBinitscr\fR was used, will be used to do this typeahead checking. -The \fBtypeahead\fR routine specifies that the file descriptor -\fIfd\fR is to be used to check for typeahead instead. If \fIfd\fR is --1, then no typeahead checking is done. -.SH RETURN VALUE -All routines that return an integer return \fBERR\fR upon failure and OK (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion, unless otherwise noted in the preceding routine descriptions. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -.PP -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 \fBraw\fR call turned it -off as a side-effect. For best portability, set echo or noecho explicitly -just after initialization, even if your program remains in cooked mode. -.SH NOTES -Note that \fBecho\fR, \fBnoecho\fR, \fBhalfdelay\fR, \fBintrflush\fR, -\fBmeta\fR, \fBnodelay\fR, \fBnotimeout\fR, \fBnoqiflush\fR, -\fBqiflush\fR, \fBtimeout\fR, and \fBwtimeout\fR may be macros. -.PP -The \fBnoraw\fR and \fBnocbreak\fR calls follow historical practice in that -they attempt to restore to normal (`cooked') mode from raw and cbreak modes -respectively. Mixing raw/noraw and cbreak/nocbreak calls leads to tty driver -control states that are hard to predict or understand; it is not recommended. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_getch\fR(3X), \fBcurs_initscr\fR(3X), \fBtermio\fR(7) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_ins_wch.3x b/contrib/ncurses-5.4/man/curs_ins_wch.3x deleted file mode 100644 index 23cf099957..0000000000 --- a/contrib/ncurses-5.4/man/curs_ins_wch.3x +++ /dev/null @@ -1,65 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_ins_wch.3x,v 1.2 2002/03/10 23:43:27 tom Exp $ -.TH curs_ins_wch 3X "" -.SH NAME -\fBins_wch\fR, -\fBmvins_wch\fR, -\fBmvwins_wch\fR, -\fBwins_wch\fR \- insert a complex character and rendition into a window -.SH SYNOPSIS -#include - -\fBint ins_wch(const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint wins_wch(WINDOW *\fR\fIwin, const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint mvins_wch(int \fR\fIy, int \fR\fIx, const cchar_t *\fR\fIwch\fR\fB);\fR -.br -\fBint mvwins_wch(WINDOW *\fR\fIwin, int \fR\fIy, int \fR\fIx, const cchar_t *\fR\fIwch\fR\fB);\fR -.SH DESCRIPTION -These routines, insert the complex character \fIwch\fR with rendition -before the character under the cursor. -All characters to the right of the cursor are moved one space to the right, -with the possibility of the rightmost character on the line being lost. -The insertion operation does not change the cursor position. -.SH RETURN VALUE -If successful, these functions return OK. -If not, they return ERR. -.SH ERRORS -No errors are defined. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_insch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_ins_wstr.3x b/contrib/ncurses-5.4/man/curs_ins_wstr.3x deleted file mode 100644 index 197f30f5cd..0000000000 --- a/contrib/ncurses-5.4/man/curs_ins_wstr.3x +++ /dev/null @@ -1,104 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_ins_wstr.3x,v 1.2 2002/03/10 23:43:27 tom Exp $ -.TH curs_ins_wstr 3X "" -.SH NAME -\fBins_wstr\fR, -\fBins_nwstr\fR, -\fBwins_wstr\fR, -\fBwins_nwstr\fR, -\fBmvins_wstr\fR, -\fBmvins_nwstr\fR, -\fBmvwins_wstr\fR, -\fBmvwins_nwstr\fR \- insert a wide-character string into a curses window -.SH SYNOPSIS -.nf -\fB#include \fR - -\fBint ins_wstr(const wchar_t *\fR\fIwstr);\fR -.br -\fBint ins_nwstr(const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint wins_wstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint wins_nwstr(WINDOW *\fR\fIwin\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvins_wstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvins_nwstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwins_wstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB);\fR -.br -\fBint mvwins_nwstr(WINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const wchar_t *\fR\fIwstr\fR\fB, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These routines insert a \fBwchar_t\fR character string -(as many characters as will fit on the line) -before the character under the cursor. -All characters to the right of the cursor are shifted right, -with the possibility of the rightmost characters on the line being lost. -No wrapping is performed. -The cursor position does not change -(after moving to \fIy\fR, \fIx\fR, if specified). -The four routines with \fIn\fR as the last argument -insert a leading substring of at most \fIn\fR \fBwchar_t\fR characters. -If \fIn\fR is less than 1, the entire string is inserted. - -If a character in \fIwstr\fR is a tab, newline, carriage return or -backspace, the cursor is moved appropriately within the window. -A newline also does a \fBclrtoeol\fR before moving. -Tabs are considered to be at every eighth column. -If a character in \fIwstr\fR is another control character, -it is drawn in the \fB^\fR\fIX\fR notation. -Calling \fBwin_wch\fR after adding a control character -(and moving to it, if necessary) -does not return the control character, -but instead returns a character in the ^-representation -of the control character. -.SH NOTES -Note that all but wins_nwstr may be macros. - -If the first character in the string is a nonspacing character, these -functions will fail. -XSI does not define what will happen if a nonspacing character follows -a control character. -.SH RETURN VALUES -Upon successful completion, these functions return OK. -Otherwise, they return ERR. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_insstr\fR(3X), -\fBcurs_in_wch\fR(3X), -\fBcurs_ins_wch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_insch.3x b/contrib/ncurses-5.4/man/curs_insch.3x deleted file mode 100644 index 44eaa1ecaf..0000000000 --- a/contrib/ncurses-5.4/man/curs_insch.3x +++ /dev/null @@ -1,70 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_insch.3x,v 1.8 2003/05/10 20:33:49 jmc Exp $ -.TH curs_insch 3X "" -.SH NAME -\fBinsch\fR, -\fBwinsch\fR, -\fBmvinsch\fR, -\fBmvwinsch\fR - insert a character before cursor in a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint insch(chtype ch);\fR -.br -\fBint winsch(WINDOW *win, chtype ch);\fR -.br -\fBint mvinsch(int y, int x, chtype ch);\fR -.br -\fBint mvwinsch(WINDOW *win, int y, int x, chtype ch);\fR -.br -.SH DESCRIPTION -These routines insert the character \fIch\fR before the character under the -cursor. All characters to the right of the cursor are moved one space to the -right, with the possibility of the rightmost character on the line being lost. -The insertion operation does not change the cursor position. -.SH RETURN VALUE -All routines that return an integer return \fBERR\fR upon failure and OK (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion, unless otherwise noted in the preceding routine descriptions. -.SH NOTES -These routines do not necessarily imply use of a hardware insert character -feature. - -Note that \fBinsch\fR, \fBmvinsch\fR, and \fBmvwinsch\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_insstr.3x b/contrib/ncurses-5.4/man/curs_insstr.3x deleted file mode 100644 index ed1e13eaec..0000000000 --- a/contrib/ncurses-5.4/man/curs_insstr.3x +++ /dev/null @@ -1,95 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_insstr.3x,v 1.12 2001/11/03 19:59:03 tom Exp $ -.TH curs_insstr 3X "" -.SH NAME -\fBinsstr\fR, -\fBinsnstr\fR, -\fBwinsstr\fR, -\fBwinsnstr\fR, -\fBmvinsstr\fR, -\fBmvinsnstr\fR, -\fBmvwinsstr\fR, -\fBmvwinsnstr\fR - insert string before cursor in a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR -.br -\fBint insstr(const char *str);\fR -.br -\fBint insnstr(const char *str, int n);\fR -.br -\fBint winsstr(WINDOW *win, const char *str);\fR -.br -\fBint winsnstr(WINDOW *win, const char *str, int n);\fR -.br -\fBint mvinsstr(int y, int x, const char *str);\fR -.br -\fBint mvinsnstr(int y, int x, const char *str, int n);\fR -.br -\fBint mvwinsstr(WINDOW *win, int y, int x, const char *str);\fR -.br -\fBint mvwinsnstr(WINDOW *win, int y, int x, const char *str, int n);\fR -.br -.SH DESCRIPTION -These routines insert a character string (as many characters as will fit on the -line) before the character under the cursor. All characters to the right of -the cursor are shifted right, with the possibility of the rightmost characters -on the line being lost. The cursor position does not change (after moving to -\fIy\fR, \fIx\fR, if specified). The four routines with \fIn\fR as the last -argument insert a leading substring of at most \fIn\fR characters. If -\fIn\fR<=0, then the entire string is inserted. - -If a character in \fIstr\fR is a tab, newline, carriage return or -backspace, the cursor is moved appropriately within the window. A -newline also does a \fBclrtoeol\fR before moving. Tabs are considered -to be at every eighth column. If a character in \fIstr\fR is another -control character, it is drawn in the \fB^\fR\fIX\fR notation. -Calling \fBwinch\fR after adding a control character (and moving to -it, if necessary) does not return the control character, but instead -returns a character in the ^-representation of the control character. -.SH RETURN VALUE -All routines that return an integer return \fBERR\fR upon failure and OK (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion, unless otherwise noted in the preceding routine descriptions. -.SH NOTES -Note that all but \fBwinsnstr\fR may be macros. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4, which adds -const qualifiers to the arguments. The XSI Curses error conditions -\fBEILSEQ\fR and \fBEILOVERFLOW\fR associated with extended-level conformance -are not yet detected (this implementation does not yet support XPG4 multibyte -characters). -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_clear\fR(3X), \fBcurs_inch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_instr.3x b/contrib/ncurses-5.4/man/curs_instr.3x deleted file mode 100644 index 9a09ab278c..0000000000 --- a/contrib/ncurses-5.4/man/curs_instr.3x +++ /dev/null @@ -1,89 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_instr.3x,v 1.10 2001/11/03 19:58:56 tom Exp $ -.TH curs_instr 3X "" -.SH NAME -\fBinstr\fR, -\fBinnstr\fR, -\fBwinstr\fR, -\fBwinnstr\fR, -\fBmvinstr\fR, -\fBmvinnstr\fR, -\fBmvwinstr\fR, -\fBmvwinnstr\fR - get a string of characters from a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint instr(char *str);\fR -.br -\fBint innstr(char *str, int n);\fR -.br -\fBint winstr(WINDOW *win, char *str);\fR -.br -\fBint winnstr(WINDOW *win, char *str, int n);\fR -.br -\fBint mvinstr(int y, int x, char *str);\fR -.br -\fBint mvinnstr(int y, int x, char *str, int n);\fR -.br -\fBint mvwinstr(WINDOW *win, int y, int x, char *str);\fR -.br -\fBint mvwinnstr(WINDOW *win, int y, int x, char *str, int n);\fR -.br -.SH DESCRIPTION -These routines return a string of characters in \fIstr\fR, extracted starting -at the current cursor position in the named window. -Attributes are stripped from the characters. The four -functions with \fIn\fR as the last argument return a leading substring at most -\fIn\fR characters long (exclusive of the trailing NUL). -.SH RETURN VALUE -All of the functions return \fBERR\fR upon failure, -or the number of characters actually read into the string. -.SH NOTES -Note that all routines except \fBwinnstr\fR may be macros. -.SH PORTABILITY -The XSI Curses -error conditions \fBEILSEQ\fR and \fBEILOVERFLOW\fR associated with -extended-level conformance are not yet detected (this implementation does not -yet support XPG4 multibyte characters). -SVr4 does not -document whether a length limit includes or excludes the trailing NUL. -.PP -The ncurses library extends the XSI description by allowing a negative -value for \fIn\fR. -In this case, the functions return the string ending at the right margin. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: - diff --git a/contrib/ncurses-5.4/man/curs_inwstr.3x b/contrib/ncurses-5.4/man/curs_inwstr.3x deleted file mode 100644 index b345ce6e6f..0000000000 --- a/contrib/ncurses-5.4/man/curs_inwstr.3x +++ /dev/null @@ -1,95 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_inwstr.3x,v 1.2 2002/04/13 20:25:35 tom Exp $ -.TH curs_inwstr 3 "" -.SH NAME -.PP -\fBinwstr\fR, -\fBinnwstr\fR, -\fBwinwstr\fR, -\fBwinnwstr\fR, -\fBmvinwstr\fR, -\fBmvinnwstr\fR, -\fBmvwinwstr\fR, -\fBmvwinnwstr\fR \- get a string of \fBwchar_t\fR characters from a curses window -.SH SYNOPSIS -.nf -\fB#include \fR - -\fBint inwstr(\fR\fBwchar_t *\fR\fIstr\fR\fB);\fR -.br -\fBint innwstr(\fR\fBwchar_t *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint winwstr(\fR\fBWINDOW *\fR\fIwin\fR\fB, wchar_t *\fR\fIstr\fR\fB);\fR -.br -\fBint winnwstr(\fR\fBWINDOW *\fR\fIwin\fR\fB, wchar_t *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvinwstr(\fR\fBint \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wchar_t *\fR\fIstr\fR\fB);\fR -.br -\fBint mvinnwstr(\fR\fBint \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wchar_t *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.br -\fBint mvwinwstr(\fR\fBWINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wchar_t *\fR\fIstr\fR\fB);\fR -.br -\fBint mvwinnwstr(\fR\fBWINDOW *\fR\fIwin\fR\fB, int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, wchar_t *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR -.fi -.SH DESCRIPTION -These routines return a string of \fBwchar_t\fR characters in \fIwstr\fR, -extracted starting at the current cursor position in the named window. -Attributes are stripped from the characters. -The four functions with \fIn\fR as the last argument return a leading substring at most -\fIn\fR bytes long (exclusive of the trailing NUL). -Transfer stops at the end of the current line, or when \fIn\fR bytes have -been stored at the location referenced by \fIwstr\fR. -.PP -If the size \fIn\fR is not large enough to store a complete character, -an error is generated. -.SH NOTES -Note that all routines except -\fBwinnwstr\fR -may be macros. -.SH RETURN VALUES -All routines return -\fBERR\fR -upon failure. Upon -successful completion, the *\fBinwstr\fR -routines return -\fBOK\fR, and the *\fBinnwstr\fR -routines return the -number of characters read into the string. -.SH SEE ALSO -Functions: -\fBcurses\fR(3X), -\fBcurs_instr\fR(3X), -\fBcurs_in_wchstr\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_kernel.3x b/contrib/ncurses-5.4/man/curs_kernel.3x deleted file mode 100644 index caeb5bba0c..0000000000 --- a/contrib/ncurses-5.4/man/curs_kernel.3x +++ /dev/null @@ -1,159 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_kernel.3x,v 1.13 2001/12/08 18:01:25 tom Exp $ -.TH curs_kernel 3X "" -.SH NAME -\fBdef_prog_mode\fR, \fBdef_shell_mode\fR, -\fBreset_prog_mode\fR, \fBreset_shell_mode\fR, \fBresetty\fR, -\fBsavetty\fR, \fBgetsyx\fR, \fBsetsyx\fR, \fBripoffline\fR, -\fBcurs_set\fR, \fBnapms\fR - low-level \fBcurses\fR routines -.SH SYNOPSIS -\fB#include \fR - -\fBint def_prog_mode(void);\fR -.br -\fBint def_shell_mode(void);\fR -.br -\fBint reset_prog_mode(void);\fR -.br -\fBint reset_shell_mode(void);\fR -.br -\fBint resetty(void);\fR -.br -\fBint savetty(void);\fR -.br -\fBvoid getsyx(int y, int x);\fR -.br -\fBvoid setsyx(int y, int x);\fR -.br -\fBint ripoffline(int line, int (*init)(WINDOW *, int));\fR -.br -\fBint curs_set(int visibility);\fR -.br -\fBint napms(int ms);\fR -.br -.SH DESCRIPTION -The following routines give low-level access to various \fBcurses\fR -capabilities. Theses routines typically are used inside library -routines. - -The \fBdef_prog_mode\fR and \fBdef_shell_mode\fR routines save the -current terminal modes as the "program" (in \fBcurses\fR) or "shell" -(not in \fBcurses\fR) state for use by the \fBreset_prog_mode\fR and -\fBreset_shell_mode\fR routines. This is done automatically by -\fBinitscr\fR. There is one such save area for each screen context -allocated by \fBnewterm()\fR. - -The \fBreset_prog_mode\fR and \fBreset_shell_mode\fR routines restore -the terminal to "program" (in \fBcurses\fR) or "shell" (out of -\fBcurses\fR) state. These are done automatically by \fBendwin\fR -and, after an \fBendwin\fR, by \fBdoupdate\fR, so they normally are -not called. - -The \fBresetty\fR and \fBsavetty\fR routines save and restore the -state of the terminal modes. \fBsavetty\fR saves the current state in -a buffer and \fBresetty\fR restores the state to what it was at the -last call to \fBsavetty\fR. - -The \fBgetsyx\fR routine returns the current coordinates of the virtual screen -cursor in \fIy\fR and \fIx\fR. If \fBleaveok\fR is currently \fBTRUE\fR, then -\fB-1\fR,\fB-1\fR is returned. If lines have been removed from the top of the -screen, using \fBripoffline\fR, \fIy\fR and \fIx\fR include these lines; -therefore, \fIy\fR and \fIx\fR should be used only as arguments for -\fBsetsyx\fR. - -The \fBsetsyx\fR routine sets the virtual screen cursor to -\fIy\fR, \fIx\fR. If \fIy\fR and \fIx\fR are both \fB-1\fR, then -\fBleaveok\fR is set. The two routines \fBgetsyx\fR and \fBsetsyx\fR -are designed to be used by a library routine, which manipulates -\fBcurses\fR windows but does not want to change the current position -of the program's cursor. The library routine would call \fBgetsyx\fR -at the beginning, do its manipulation of its own windows, do a -\fBwnoutrefresh\fR on its windows, call \fBsetsyx\fR, and then call -\fBdoupdate\fR. - -The \fBripoffline\fR routine provides access to the same facility that -\fBslk_init\fR [see \fBcurs_slk\fR(3X)] uses to reduce the size of the -screen. \fBripoffline\fR must be called before \fBinitscr\fR or -\fBnewterm\fR is called. If \fIline\fR is positive, a line is removed -from the top of \fBstdscr\fR; if \fIline\fR is negative, a line is -removed from the bottom. When this is done inside \fBinitscr\fR, the -routine \fBinit\fR (supplied by the user) is called with two -arguments: a window pointer to the one-line window that has been -allocated and an integer with the number of columns in the window. -Inside this initialization routine, the integer variables \fBLINES\fR -and \fBCOLS\fR (defined in \fB\fR) are not guaranteed to be -accurate and \fBwrefresh\fR or \fBdoupdate\fR must not be called. It -is allowable to call \fBwnoutrefresh\fR during the initialization -routine. - -\fBripoffline\fR can be called up to five times before calling \fBinitscr\fR or -\fBnewterm\fR. - -The \fBcurs_set\fR routine sets the cursor state is set to invisible, -normal, or very visible for \fBvisibility\fR equal to \fB0\fR, -\fB1\fR, or \fB2\fR respectively. If the terminal supports the -\fIvisibility\fR requested, the previous \fIcursor\fR state is -returned; otherwise, \fBERR\fR is returned. - -The \fBnapms\fR routine is used to sleep for \fIms\fR milliseconds. -.SH RETURN VALUE -Except for \fBcurs_set\fR, these routines always return \fBOK\fR. -\fBcurs_set\fR returns the previous cursor state, or \fBERR\fR if the -requested \fIvisibility\fR is not supported. -.SH NOTES -Note that \fBgetsyx\fR is a macro, so \fB&\fR is not necessary before -the variables \fIy\fR and \fIx\fR. - -Older SVr4 man pages warn that the return value of \fBcurs_set\fR "is currently -incorrect". This implementation gets it right, but it may be unwise to count -on the correctness of the return value anywhere else. - -Both ncurses and SVr4 will call \fBcurs_set\fR in \fBendwin\fR -if \fBcurs_set\fR -has been called to make the cursor other than normal, i.e., either -invisible or very visible. -There is no way for ncurses to determine the initial cursor state to -restore that. -.SH PORTABILITY -The functions \fBsetsyx\fR and \fBgetsyx\fR are not described in the XSI -Curses standard, Issue 4. All other functions are as described in XSI Curses. - -The SVr4 documentation describes \fBsetsyx\fR and \fBgetsyx\fR as having return -type int. This is misleading, as they are macros with no documented semantics -for the return value. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_outopts\fR(3X), \fBcurs_refresh\fR(3X), -\fBcurs_scr_dump\fR(3X), \fBcurs_slk\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_mouse.3x b/contrib/ncurses-5.4/man/curs_mouse.3x deleted file mode 100644 index b15507629b..0000000000 --- a/contrib/ncurses-5.4/man/curs_mouse.3x +++ /dev/null @@ -1,254 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_mouse.3x,v 1.24 2003/12/27 18:47:54 tom Exp $ -.TH curs_mouse 3X "" -.SH NAME -\fBgetmouse\fR, \fBungetmouse\fR, -\fBmousemask\fR, \fBwenclose\fR, -\fBmouse_trafo\fR, \fBwmouse_trafo\fR, -\fBmouseinterval\fR - mouse interface through curses -.SH SYNOPSIS -.nf -\fB#include -.PP -\fBtypedef unsigned long mmask_t; -.PP -typedef struct -{ - short id; \fI/* ID to distinguish multiple devices */\fB - int x, y, z; \fI/* event coordinates */\fB - mmask_t bstate; \fI/* button state bits */\fB -} -MEVENT;\fR -.fi -.br -\fBint getmouse(MEVENT *event);\fR -.br -\fBint ungetmouse(MEVENT *event);\fR -.br -\fBmmask_t mousemask(mmask_t newmask, mmask_t *oldmask);\fR -.br -\fBbool wenclose(const WINDOW *win, int y, int x);\fR -.br -\fBbool mouse_trafo(int* pY, int* pX, bool to_screen);\fR -.br -\fBbool wmouse_trafo(const WINDOW* win, int* pY, int* pX,\fR -.br - \fBbool to_screen);\fR -.br -\fBint mouseinterval(int erval);\fR -.br -.SH DESCRIPTION -These functions provide an interface to mouse events from -\fBncurses\fR(3X). -Mouse events are represented by \fBKEY_MOUSE\fR -pseudo-key values in the \fBwgetch\fR input stream. -.PP -To make mouse events visible, use the \fBmousemask\fR function. -This will set -the mouse events to be reported. -By default, no mouse events are reported. -The function will return a mask to indicate which of the specified mouse events -can be reported; on complete failure it returns 0. -If oldmask is non-NULL, -this function fills the indicated location with the previous value of the given -window's mouse event mask. -.PP -As a side effect, setting a zero mousemask may turn off the mouse pointer; -setting a nonzero mask may turn it on. -Whether this happens is device-dependent. -.PP -Here are the mouse event type masks: -.PP -.TS -l l -_ _ -l l. -\fIName\fR \fIDescription\fR -BUTTON1_PRESSED mouse button 1 down -BUTTON1_RELEASED mouse button 1 up -BUTTON1_CLICKED mouse button 1 clicked -BUTTON1_DOUBLE_CLICKED mouse button 1 double clicked -BUTTON1_TRIPLE_CLICKED mouse button 1 triple clicked -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 -BUTTON4_PRESSED mouse button 4 down -BUTTON4_RELEASED mouse button 4 up -BUTTON4_CLICKED mouse button 4 clicked -BUTTON4_DOUBLE_CLICKED mouse button 4 double clicked -BUTTON4_TRIPLE_CLICKED mouse button 4 triple clicked -BUTTON_SHIFT shift was down during button state change -BUTTON_CTRL control was down during button state change -BUTTON_ALT alt was down during button state change -ALL_MOUSE_EVENTS report all button state changes -REPORT_MOUSE_POSITION report mouse movement -.TE -.PP -Once a class of mouse events have been made visible in a window, -calling the \fBwgetch\fR function on that window may return -\fBKEY_MOUSE\fR as an indicator that a mouse event has been queued. -To read the event data and pop the event off the queue, call -\fBgetmouse\fR. -This function will return \fBOK\fR if a mouse event -is actually visible in the given window, \fBERR\fR otherwise. -When \fBgetmouse\fR returns \fBOK\fR, the data deposited as y and -x in the event structure coordinates will be screen-relative character-cell -coordinates. -The returned state mask will have exactly one bit set to -indicate the event type. -.PP -The \fBungetmouse\fR function behaves analogously to \fBungetch\fR. -It pushes -a \fBKEY_MOUSE\fR event onto the input queue, and associates with that event -the given state data and screen-relative character-cell coordinates. -.PP -The \fBwenclose\fR function tests whether a given pair of screen-relative -character-cell coordinates is enclosed by a given window, returning TRUE -if it is and FALSE otherwise. -It is useful for determining what subset of -the screen windows enclose the location of a mouse event. -.PP -The \fBwmouse_trafo\fR function transforms a given pair of coordinates from -stdscr-relative coordinates to screen-relative coordinates or vice versa. -Please remember, that stdscr-relative coordinates are not always identical -to screen-relative coordinates due to the mechanism to reserve lines on top -or bottom of the screen for other purposes (ripoff() call, see also slk_... -functions). -If the parameter \fBto_screen\fR is \fBTRUE\fR, the pointers -\fBpY, pX\fR must reference the coordinates of a location inside the window -\fBwin\fR. -They are converted to screen-relative coordinates and returned -through the pointers. -If the conversion was successful, the function returns \fBTRUE\fR. -If one of the parameters was NULL or the location is -not inside the window, \fBFALSE\fR is returned. -If \fBto_screen\fR is -\fBFALSE\fR, the pointers \fBpY, pX\fR must reference screen-relative -coordinates. -They are converted to stdscr-relative coordinates if the -window \fBwin\fR encloses this point. -In this case the function returns \fBTRUE\fR. -If one of the parameters is NULL or the point is not inside the -window, \fBFALSE\fR is returned. -Please notice, that the referenced coordinates -are only replaced by the converted coordinates if the transformation was -successful. -.PP -The \fBmouseinterval\fR function sets the maximum time (in thousands of a -second) that can elapse between press and release events for them to -be recognized as a click. -Use \fBmouseinterval(-1)\fR to disable click resolution. -This function returns the previous interval value. -The default is one sixth of a second. -.PP -Note that mouse events will be ignored when input is in cooked mode, and will -cause an error beep when cooked mode is being simulated in a window by a -function such as \fBgetstr\fR that expects a linefeed for input-loop -termination. -.SH RETURN VALUE -\fBgetmouse\fR, \fBungetmouse\fR and \fBmouseinterval\fR -return the integer \fBERR\fR upon failure or \fBOK\fR -upon successful completion. -\fBmousemask\fR returns the -mask of reportable events. -\fBwenclose\fR and \fBwmouse_trafo\fR -are boolean functions returning \fBTRUE\fR or \fBFALSE\fR depending -on their test result. -.SH PORTABILITY -These calls were designed for \fBncurses\fR(3X), and are not found in SVr4 -curses, 4.4BSD curses, or any other previous version of curses. -.PP -The feature macro \fBNCURSES_MOUSE_VERSION\fR is provided so the preprocessor -can be used to test whether these features are present (its value is 1). -If the interface is changed, the value of \fBNCURSES_MOUSE_VERSION\fR will be -incremented. -.PP -The order of the \fBMEVENT\fR structure members is not guaranteed. -Additional fields may be added to the structure in the future. -.PP -Under \fBncurses\fR(3X), these calls are implemented using either -xterm's built-in mouse-tracking API or -platform-specific drivers including -.RS -Alessandro Rubini's gpm server. -.br -FreeBSD sysmouse -.br -OS/2 EMX -.RE -If you are using an unsupported configuration, -mouse events will not be visible to -\fBncurses\fR(3X) (and the \fBwmousemask\fR function will always -return \fB0\fR). -.PP -If the terminfo entry contains a \fBXM\fR string, -this is used in the xterm mouse driver to control the -way the terminal is initialized for mouse operation. -The default, if \fBXM\fR is not found, -corresponds to private mode 1000 of xterm: -.RS -\\E[?1000%?%p1%{1}%=%th%el%; -.RE -The z member in the event structure is not presently used. -It is intended -for use with touch screens (which may be pressure-sensitive) or with -3D-mice/trackballs/power gloves. -.SH BUGS -Mouse events under xterm will not in fact be ignored during cooked mode, -if they have been enabled by \fBwmousemask\fR. -Instead, the xterm mouse -report sequence will appear in the string read. -.PP -Mouse events under xterm will not be detected correctly in a window with -its keypad bit off, since they are interpreted as a variety of function key. -Your terminfo description must have \fBkmous\fR set to "\\E[M" (the beginning -of the response from xterm for mouse clicks). -.PP -Because there are no standard terminal responses that would serve to identify -terminals which support the xterm mouse protocol, \fBncurses\fR assumes that -if your $TERM environment variable contains "xterm", -or \fBkmous\fR is defined in -the terminal description, then the terminal may send mouse events. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_move.3x b/contrib/ncurses-5.4/man/curs_move.3x deleted file mode 100644 index 2fff160c2f..0000000000 --- a/contrib/ncurses-5.4/man/curs_move.3x +++ /dev/null @@ -1,63 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_move.3x,v 1.7 2001/11/03 19:58:47 tom Exp $ -.TH curs_move 3X "" -.SH NAME -\fBmove\fR, \fBwmove\fR - move \fBcurses\fR window cursor -.SH SYNOPSIS -\fB#include \fR - -\fBint move(int y, int x);\fR -.br -\fBint wmove(WINDOW *win, int y, int x);\fR -.br -.SH DESCRIPTION -These routines move the cursor associated with the window to line \fIy\fR and -column \fIx\fR. This routine does not move the physical cursor of the terminal -until \fBrefresh\fR is called. The position specified is relative to the upper -left-hand corner of the window, which is (0,0). -.SH RETURN VALUE -These routines return \fBERR\fR upon failure and OK (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBmove\fR may be a macro. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. The -standard specifies that if (y,x) is within a multi-column character, the cursor -is moved to the first column of that character; however, this implementation -does not yet support the extended-level XSI multibyte characters. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_refresh\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_outopts.3x b/contrib/ncurses-5.4/man/curs_outopts.3x deleted file mode 100644 index c5b518c12e..0000000000 --- a/contrib/ncurses-5.4/man/curs_outopts.3x +++ /dev/null @@ -1,193 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2001,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_outopts.3x,v 1.18 2003/05/10 20:33:49 jmc Exp $ -.TH curs_outopts 3X "" -.SH NAME -\fBclearok\fR, \fBidlok\fR, \fBidcok\fR, \fBimmedok\fR, -\fBleaveok\fR, \fBsetscrreg\fR, \fBwsetscrreg\fR, \fBscrollok\fR, -\fBnl\fR, \fBnonl\fR - \fBcurses\fR output options -.SH SYNOPSIS -\fB#include \fR - -\fBint clearok(WINDOW *win, bool bf);\fR -.br -\fBint idlok(WINDOW *win, bool bf);\fR -.br -\fBvoid idcok(WINDOW *win, bool bf);\fR -.br -\fBvoid immedok(WINDOW *win, bool bf);\fR -.br -\fBint leaveok(WINDOW *win, bool bf);\fR -.br -\fBint setscrreg(int top, int bot);\fR -.br -\fBint wsetscrreg(WINDOW *win, int top, int bot);\fR -.br -\fBint scrollok(WINDOW *win, bool bf);\fR -.br -\fBint nl(void);\fR -.br -\fBint nonl(void);\fR -.br -.SH DESCRIPTION -These routines set options that change the style of output within -\fBcurses\fR. -All options are initially \fBFALSE\fR, unless otherwise stated. -It is not necessary to turn these options off before calling \fBendwin\fR. - -If \fBclearok\fR is called with \fBTRUE\fR as argument, the next -call to \fBwrefresh\fR with this window will clear the screen completely and -redraw the entire screen from scratch. -This is useful when the contents of the -screen are uncertain, or in some cases for a more pleasing visual effect. -If -the \fIwin\fR argument to \fBclearok\fR is the global variable \fBcurscr\fR, -the next call to \fBwrefresh\fR with any window causes the screen to be cleared -and repainted from scratch. - -If \fBidlok\fR is called with \fBTRUE\fR as second argument, \fBcurses\fR -considers using the hardware insert/delete line feature of terminals so -equipped. -Calling \fBidlok\fR with \fBFALSE\fR as second argument disables use -of line insertion and deletion. -This option should be enabled only if the -application needs insert/delete line, for example, for a screen editor. -It is -disabled by default because insert/delete line tends to be visually annoying -when used in applications where it isn't really needed. -If insert/delete line -cannot be used, \fBcurses\fR redraws the changed portions of all lines. - -If \fBidcok\fR is called with \fBFALSE\fR as second argument, \fBcurses\fR -no longer considers using the hardware insert/delete character feature of -terminals so equipped. -Use of character insert/delete is enabled by default. -Calling \fBidcok\fR with \fBTRUE\fR as second argument re-enables use -of character insertion and deletion. - -If \fBimmedok\fR is called with \fBTRUE as argument\fR, any change -in the window image, such as the ones caused by \fBwaddch, wclrtobot, wscrl\fR, -etc., automatically cause a call to \fBwrefresh\fR. -However, it may -degrade performance considerably, due to repeated calls to \fBwrefresh\fR. -It is disabled by default. - -Normally, the hardware cursor is left at the location of the window cursor -being refreshed. -The \fBleaveok\fR option allows the cursor to be left -wherever the update happens to leave it. -It is useful for applications where -the cursor is not used, since it reduces the need for cursor motions. - -The \fBsetscrreg\fR and \fBwsetscrreg\fR routines allow the application -programmer to set a software scrolling region in a window. -\fItop\fR and -\fIbot\fR are the line numbers of the top and bottom margin of the scrolling -region. -(Line 0 is the top line of the window.) If this option and -\fBscrollok\fR are enabled, an attempt to move off the bottom margin line -causes all lines in the scrolling region to scroll one line in the direction -of the first line. -Only the text of the window is scrolled. -(Note that this -has nothing to do with the use of a physical scrolling region capability in the -terminal, like that in the VT100. -If \fBidlok\fR is enabled and the terminal -has either a scrolling region or insert/delete line capability, they will -probably be used by the output routines.) - -The \fBscrollok\fR 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 character of the last -line. -If disabled, (\fIbf\fR is \fBFALSE\fR), the cursor is left on the bottom -line. -If enabled, (\fIbf\fR is \fBTRUE\fR), the window is scrolled up one line -(Note that to get the physical scrolling effect on the terminal, it is -also necessary to call \fBidlok\fR). - -The \fBnl\fR and \fBnonl\fR routines control whether the underlying display -device translates the return key into newline on input, and whether it -translates newline into return and line-feed on output (in either case, the -call \fBaddch('\\n')\fR does the equivalent of return and line feed on the -virtual screen). -Initially, these translations do occur. -If you disable them -using \fBnonl\fR, \fBcurses\fR will be able to make better use of the line-feed -capability, resulting in faster cursor motion. -Also, \fBcurses\fR will then be -able to detect the return key. -.SH RETURN VALUE -The functions \fBsetscrreg\fR and \fBwsetscrreg\fR return \fBOK\fR upon success -and \fBERR\fR upon failure. -All other routines that return an integer always -return \fBOK\fR. -.SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. - -The XSI Curses standard is ambiguous on the question of whether \fBraw\fR() -should disable the CRLF translations controlled by \fBnl\fR() and \fBnonl\fR(). -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 does not mess with. - -Some historic curses implementations had, as an undocumented feature, the -ability to do the equivalent of \fBclearok(..., 1)\fR by saying -\fBtouchwin(stdscr)\fR or \fBclear(stdscr)\fR. -This will not work under -ncurses. - -Earlier System V curses implementations specified that with \fBscrollok\fR -enabled, any window modification triggering a scroll also forced a physical -refresh. -XSI Curses does not require this, and \fBncurses\fR avoids doing -it to perform better vertical-motion optimization at \fBwrefresh\fR -time. - -The XSI Curses standard does not mention that the cursor should be -made invisible as a side-effect of \fBleaveok\fR. -SVr4 curses documentation does this, but the code does not. -Use \fBcurs_set\fR to make the cursor invisible. -.SH NOTES -Note that \fBclearok\fR, \fBleaveok\fR, \fBscrollok\fR, \fBidcok\fR, \fBnl\fR, -\fBnonl\fR and \fBsetscrreg\fR may be macros. - -The \fBimmedok\fR routine is useful for windows that are used as terminal -emulators. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_addch\fR(3X), \fBcurs_clear\fR(3X), -\fBcurs_initscr\fR(3X), \fBcurs_scroll\fR(3X), \fBcurs_refresh\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_overlay.3x b/contrib/ncurses-5.4/man/curs_overlay.3x deleted file mode 100644 index 3d817d41c6..0000000000 --- a/contrib/ncurses-5.4/man/curs_overlay.3x +++ /dev/null @@ -1,76 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_overlay.3x,v 1.11 2002/07/20 14:53:00 tom Exp $ -.TH curs_overlay 3X "" -.SH NAME -\fBoverlay\fR, -\fBoverwrite\fR, -\fBcopywin\fR - overlay and manipulate overlapped \fBcurses\fR windows -.SH SYNOPSIS -\fB#include \fR - -\fBint overlay(const WINDOW *srcwin, WINDOW *dstwin);\fR -.br -\fBint overwrite(const WINDOW *srcwin, WINDOW *dstwin);\fR -.br -\fBint copywin(const WINDOW *srcwin, WINDOW *dstwin, int sminrow,\fR - \fBint smincol, int dminrow, int dmincol, int dmaxrow,\fR - \fBint dmaxcol, int overlay);\fR -.SH DESCRIPTION -The \fBoverlay\fR and \fBoverwrite\fR routines overlay \fIsrcwin\fR on -top of \fIdstwin\fR. \fIscrwin\fR and \fIdstwin\fR are not required -to be the same size; only text where the two windows overlap is -copied. The difference is that \fBoverlay\fR is non-destructive -(blanks are not copied) whereas \fBoverwrite\fR is destructive. - -The \fBcopywin\fR routine provides a finer granularity of control over the -\fBoverlay\fR and \fBoverwrite\fR routines. Like in the \fBprefresh\fR -routine, a rectangle is specified in the destination window, (\fIdminrow\fR, -\fIdmincol\fR) and (\fIdmaxrow\fR, \fIdmaxcol\fR), and the upper-left-corner -coordinates of the source window, (\fIsminrow\fR, \fIsmincol\fR). If the -argument \fIoverlay\fR is \fBtrue\fR, then copying is non-destructive, as in -\fBoverlay\fR. -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure, and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBoverlay\fR and \fBoverwrite\fR may be macros. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions (adding the const -qualifiers). It further specifies their behavior in the presence of characters -with multibyte renditions (not yet supported in this implementation). -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_pad\fR(3X), \fBcurs_refresh\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_pad.3x b/contrib/ncurses-5.4/man/curs_pad.3x deleted file mode 100644 index 4db08dcf44..0000000000 --- a/contrib/ncurses-5.4/man/curs_pad.3x +++ /dev/null @@ -1,133 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2003,2004 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_pad.3x,v 1.12 2004/01/04 01:36:49 tom Exp $ -.TH curs_pad 3X "" -.SH NAME -\fBnewpad\fR, \fBsubpad\fR, \fBprefresh\fR, -\fBpnoutrefresh\fR, -\fBpechochar\fR, \fBpecho_wchar\fR - create and display \fBcurses\fR pads -.SH SYNOPSIS -\fB#include \fR -.sp -\fBWINDOW *newpad(int nlines, int ncols);\fR -.br -\fBWINDOW *subpad(WINDOW *orig, int nlines, int ncols,\fR - \fBint begin_y, int begin_x);\fR -.br -\fBint prefresh(WINDOW *pad, int pminrow, int pmincol,\fR - \fBint sminrow, int smincol, int smaxrow, int smaxcol);\fR -.br -\fBint pnoutrefresh(WINDOW *pad, int pminrow, int pmincol,\fR - \fBint sminrow, int smincol, int smaxrow, int smaxcol);\fR -.br -\fBint pechochar(WINDOW *pad, chtype ch);\fR -.br -\fBint pecho_wchar(WINDOW *pad, const cchar_t *wch);\fR -.SH DESCRIPTION -The \fBnewpad\fR routine creates and returns a pointer to a new pad data -structure with the given number of lines, \fInlines\fR, and columns, -\fIncols\fR. -A pad is like a window, except that it is not restricted by the -screen size, and is not necessarily associated with a particular part of the -screen. -Pads can be used when a large window is needed, and only a part of the -window will be on the screen at one time. -Automatic refreshes of pads -(e.g., from scrolling or echoing of input) do not occur. -It is not -legal to call \fBwrefresh\fR with a \fIpad\fR as an argument; the routines -\fBprefresh\fR or \fBpnoutrefresh\fR should be called instead. -Note that these -routines require additional parameters to specify the part of the pad to be -displayed and the location on the screen to be used for the display. -.PP -The \fBsubpad\fR routine creates and returns a pointer to a subwindow within a -pad with the given number of lines, \fInlines\fR, and columns, \fIncols\fR. -Unlike \fBsubwin\fR, which uses screen coordinates, the window is at position -(\fIbegin\fR_\fIx\fR\fB,\fR \fIbegin\fR_\fIy\fR) on the pad. -The window is -made in the middle of the window \fIorig\fR, so that changes made to one window -affect both windows. -During the use of this routine, it will often be -necessary to call \fBtouchwin\fR or \fBtouchline\fR on \fIorig\fR before -calling \fBprefresh\fR. -.PP -The \fBprefresh\fR and \fBpnoutrefresh\fR routines are analogous to -\fBwrefresh\fR and \fBwnoutrefresh\fR except that they relate to pads instead -of windows. -The additional parameters are needed to indicate what part of the -pad and screen are involved. -\fIpminrow\fR and \fIpmincol\fR specify the upper -left-hand corner of the rectangle to be displayed in the pad. -\fIsminrow\fR, -\fIsmincol\fR, \fIsmaxrow\fR, and \fIsmaxcol\fR specify the edges of the -rectangle to be displayed on the screen. -The lower right-hand corner of the -rectangle to be displayed in the pad is calculated from the screen coordinates, -since the rectangles must be the same size. -Both rectangles must be entirely -contained within their respective structures. -Negative values of -\fIpminrow\fR, \fIpmincol\fR, \fIsminrow\fR, or \fIsmincol\fR are treated as if -they were zero. -.PP -The \fBpechochar\fR routine is functionally equivalent to a call to \fBaddch\fR -followed by a call to \fBrefresh\fR, a call to \fBwaddch\fR followed by a call -to \fBwrefresh\fR, or a call to \fBwaddch\fR followed by a call to -\fBprefresh\fR. -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 these routines instead of their -equivalents. -In the case of \fBpechochar\fR, the last location of the pad on -the screen is reused for the arguments to \fBprefresh\fR. -.PP -The \fBpecho_wchar\fR function is the analogous wide-character -form of \fBpechochar\fR. -It outputs one character to a pad and immediately refreshes the pad. -It does this by a call to \fBwadd_wch\fR followed by a call to \fBprefresh\fR. -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. -.PP -Routines that return pointers return \fBNULL\fR on error, and set \fBerrno\fR -to \fBENOMEM\fR. -.SH NOTES -Note that \fBpechochar\fR may be a macro. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_refresh\fR(3X), \fBcurs_touch\fR(3X), \fBcurs_addch\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_print.3x b/contrib/ncurses-5.4/man/curs_print.3x deleted file mode 100644 index 3077d34769..0000000000 --- a/contrib/ncurses-5.4/man/curs_print.3x +++ /dev/null @@ -1,74 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_print.3x,v 1.6 2003/05/10 20:33:49 jmc Exp $ -.TH curs_print 3X "" -.SH NAME -\fBmcprint\fR - ship binary data to printer -.SH SYNOPSIS -\fB#include \fR - -\fBint mcprint(char *data, int len);\fR -.SH DESCRIPTION -This function uses the \fBmc5p\fR or \fBmc4\fR and \fBmc5\fR capabilities, -if they are present, to ship given data to a printer attached to the terminal. - -Note that the \fBmcprint\fR code has no way to do flow control with the 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 typically handle 80cps, so a good conservative -rule of thumb is to sleep for a second after shipping each 80-character line. - -.SH RETURN VALUE -The \fBmcprint\fR function returns \fBERR\fR if the write operation aborted -for some reason. In this case, errno will contain either an error associated -with \fBwrite(2)\fR or one of the following: -.TP 5 -ENODEV -Capabilities for printer redirection don't exist. -.TP 5 -ENOMEM -Couldn't allocate sufficient memory to buffer the printer write. - -When \fBmcprint\fR succeeds, it returns the number of characters actually -sent to the printer. -.SH PORTABILITY -The \fBmcprint\fR call was designed for \fBncurses\fR(3X), and is not found -in SVr4 curses, 4.4BSD curses, or any other previous version of curses. -.SH BUGS -Padding in the \fBmc5p\fR, \fBmc4\fR and \fBmc5\fR capabilities will not be -interpreted. -.SH SEE ALSO -\fBcurses\fR(3X)\fR -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_printw.3x b/contrib/ncurses-5.4/man/curs_printw.3x deleted file mode 100644 index f16e2fe05e..0000000000 --- a/contrib/ncurses-5.4/man/curs_printw.3x +++ /dev/null @@ -1,84 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_printw.3x,v 1.13 2002/11/16 22:28:57 tom Exp $ -.TH curs_printw 3X "" -.SH NAME -\fBprintw\fR, -\fBwprintw\fR, -\fBmvprintw\fR, -\fBmvwprintw\fR, -\fBvwprintw\fR, \fBvw_printw\fR - print formatted output in \fBcurses\fR windows -.SH SYNOPSIS -\fB#include \fR - -\fBint printw(const char *fmt, ...);\fR -.br -\fBint wprintw(WINDOW *win, const char *fmt, ...);\fR -.br -\fBint mvprintw(int y, int x, const char *fmt, ...);\fR -.br -\fBint mvwprintw(WINDOW *win, int y, int x, const char *fmt, ...);\fR -.br -\fBint vwprintw(WINDOW *win, const char *fmt, va_list varglist);\fR -.br -\fBint vw_printw(WINDOW *win, const char *fmt, va_list varglist);\fR -.br -.SH DESCRIPTION -The \fBprintw\fR, \fBwprintw\fR, \fBmvprintw\fR and \fBmvwprintw\fR -routines are analogous to \fBprintf\fR [see \fBprintf\fR(3S)]. In -effect, the string that would be output by \fBprintf\fR is output -instead as though \fBwaddstr\fR were used on the given window. - -The \fBvwprintw\fR and \fBwv_printw\fR routines are analogous -to \fBvprintf\fR [see \fBprintf\fR(3S)] -and perform a \fBwprintw\fR using a variable argument list. -The third argument is a \fBva_list\fR, a pointer to a -list of arguments, as defined in \fB\fR. -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. The function -\fBvwprintw\fR is marked TO BE WITHDRAWN, and is to be replaced by a function -\fBvw_printw\fR using the \fB\fR interface. -The Single Unix Specification, Version 2 states that -\fBvw_printw\fR is preferred to \fBvwprintw\fR since the latter requires -including \fB\fR, which -cannot be used in the same file as \fB\fR. -This implementation uses \fB\fR for both, because that header -is included in \fB. -.SH SEE ALSO -\fBcurses\fR(3X), \fBprintf\fR(3S), \fBvprintf(3S)\fR -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_refresh.3x b/contrib/ncurses-5.4/man/curs_refresh.3x deleted file mode 100644 index 210b326a61..0000000000 --- a/contrib/ncurses-5.4/man/curs_refresh.3x +++ /dev/null @@ -1,126 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_refresh.3x,v 1.10 2001/11/03 18:57:12 tom Exp $ -.TH curs_refresh 3X "" -.SH NAME -\fBdoupdate\fR, -\fBredrawwin\fR, -\fBrefresh\fR, -\fBwnoutrefresh\fR, -\fBwredrawln\fR, -\fBwrefresh\fR - refresh \fBcurses\fR windows and lines -.SH SYNOPSIS -\fB#include \fR - -\fBint refresh(void);\fR -.br -\fBint wrefresh(WINDOW *win);\fR -.br -\fBint wnoutrefresh(WINDOW *win);\fR -.br -\fBint doupdate(void);\fR -.br -\fBint redrawwin(WINDOW *win);\fR -.br -\fBint wredrawln(WINDOW *win, int beg_line, int num_lines);\fR -.br -.SH DESCRIPTION -The \fBrefresh\fR and \fBwrefresh\fR routines (or \fBwnoutrefresh\fR and -\fBdoupdate\fR) must be called to get actual output to the terminal, as other -routines merely manipulate data structures. -The routine \fBwrefresh\fR copies -the named window to the physical terminal screen, taking into account what is -already there to do optimizations. -The \fBrefresh\fR routine is the -same, using \fBstdscr\fR as the default window. -Unless \fBleaveok\fR has been -enabled, the physical cursor of the terminal is left at the location of the -cursor for that window. - -The \fBwnoutrefresh\fR and \fBdoupdate\fR routines allow multiple updates with -more efficiency than \fBwrefresh\fR alone. -In addition to all the window -structures, \fBcurses\fR keeps two data structures representing the terminal -screen: a physical screen, describing what is actually on the screen, and a -virtual screen, describing what the programmer wants to have on the screen. - -The routine \fBwrefresh\fR works by first calling \fBwnoutrefresh\fR, which -copies the named window to the virtual screen, and then calling \fBdoupdate\fR, -which compares the virtual screen to the physical screen and does the actual -update. -If the programmer wishes to output several windows at once, a series -of calls to \fBwrefresh\fR results in alternating calls to \fBwnoutrefresh\fR -and \fBdoupdate\fR, causing several bursts of output to the screen. -By first -calling \fBwnoutrefresh\fR for each window, it is then possible to call -\fBdoupdate\fR once, resulting in only one burst of output, with fewer total -characters transmitted and less CPU time used. -If the \fIwin\fR argument to -\fBwrefresh\fR is the global variable \fBcurscr\fR, the screen is immediately -cleared and repainted from scratch. - -The phrase "copies the named window to the virtual screen" above is ambiguous. -What actually happens is that all \fItouched\fR (changed) lines in the window -are copied to the virtual screen. -This affects programs that use overlapping -windows; it means that if two windows overlap, you can refresh them in either -order and the overlap region will be modified only when it is explicitly -changed. -(But see the section on \fBPORTABILITY\fR below for a warning about -exploiting this behavior.) - -The \fBwredrawln\fR routine indicates to \fBcurses\fR that some screen lines -are corrupted and should be thrown away before anything is written over them. -It touches the indicated lines (marking them changed). -The routine \fBredrawwin\fR() touches the entire window. -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure, and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBrefresh\fR and \fBredrawwin\fR may be macros. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. - -Whether \fBwnoutrefresh()\fR copies to the virtual screen the entire contents -of a window or just its changed portions has never been well-documented in -historic curses versions (including SVr4). -It might be unwise to rely on -either behavior in programs that might have to be linked with other curses -implementations. -Instead, you can do an explicit \fBtouchwin()\fR before the -\fBwnoutrefresh()\fR call to guarantee an entire-contents copy anywhere. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_outopts\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_scanw.3x b/contrib/ncurses-5.4/man/curs_scanw.3x deleted file mode 100644 index 8b67801f7d..0000000000 --- a/contrib/ncurses-5.4/man/curs_scanw.3x +++ /dev/null @@ -1,97 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_scanw.3x,v 1.12 2002/07/20 15:48:09 tom Exp $ -.TH curs_scanw 3X "" -.SH NAME -\fBscanw\fR, -\fBwscanw\fR, -\fBmvscanw\fR, -\fBmvwscanw\fR, -\fBvwscanw\fR, \fBvw_scanw\fR - convert formatted input from a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint scanw(char *fmt, ...);\fR -.br -\fBint wscanw(WINDOW *win, char *fmt, ...);\fR -.br -\fBint mvscanw(int y, int x, char *fmt, ...);\fR -.br -\fBint mvwscanw(WINDOW *win, int y, int x, char *fmt, ...);\fR -.br -\fBint vw_scanw(WINDOW *win, char *fmt, va_list varglist);\fR -.br -\fBint vwscanw(WINDOW *win, char *fmt, va_list varglist);\fR -.SH DESCRIPTION -The \fBscanw\fR, \fBwscanw\fR and \fBmvscanw\fR routines are analogous to -\fBscanf\fR [see \fBscanf\fR(3S)]. The effect of these routines is as though -\fBwgetstr\fR were called on the window, and the resulting line used as input -for \fBsscanf\fR(3). Fields which do not map to a variable in the \fIfmt\fR -field are lost. - -The \fBvwscanw\fR and \fBvw_scanw\fR routines are analogous to \fBvscanf\fR. -They perform a \fBwscanw\fR using a variable argument list. -The third argument is a \fIva_list\fR, -a pointer to a list of arguments, as defined in \fB\fR. -.SH RETURN VALUE -\fBvwscanw\fR returns \fBERR\fR on failure and an integer equal to the -number of fields scanned on success. - -Applications may use the return value from the \fBscanw\fR, \fBwscanw\fR, -\fBmvscanw\fR and \fBmvwscanw\fR routines to determine the number of fields -which were mapped in the call. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. The function -\fBvwscanw\fR is marked TO BE WITHDRAWN, and is to be replaced by a function -\fBvw_scanw\fR using the \fB\fR interface. -The Single Unix Specification, Version 2 states that -\fBvw_scanw\fR is preferred to \fBvwscanw\fR since the latter requires -including \fB\fR, which -cannot be used in the same file as \fB\fR. -This implementation uses \fB\fR for both, because that header -is included in \fB. -.LP -Both XSI and The Single Unix Specification, Version 2 state that these -functions return ERR or OK. -Since the underlying \fBscanf\fR 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 than being done intentionally. -Portable applications should only test if the return value is ERR, -since the OK value (zero) is likely to be misleading. -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. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_getstr\fR(3X), \fBcurs_printw\fR(3X), \fBscanf\fR(3S) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_scr_dump.3x b/contrib/ncurses-5.4/man/curs_scr_dump.3x deleted file mode 100644 index a925ea56d9..0000000000 --- a/contrib/ncurses-5.4/man/curs_scr_dump.3x +++ /dev/null @@ -1,94 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_scr_dump.3x,v 1.3 2003/10/25 20:34:06 tom Exp $ -.TH curs_scr_dump 3X "" -.SH NAME -\fBscr_dump\fR, -\fBscr_restore\fR, -\fBscr_init\fR, -\fBscr_set\fR - read (write) a \fBcurses\fR screen from (to) a file -.SH SYNOPSIS -\fB#include \fR - -\fBint scr_dump(const char *filename);\fR -.br -\fBint scr_restore(const char *filename);\fR -.br -\fBint scr_init(const char *filename);\fR -.br -\fBint scr_set(const char *filename);\fR -.br -.SH DESCRIPTION -The \fBscr_dump\fR routine dumps the current contents of the virtual screen -to the file \fIfilename\fR. - -The \fBscr_restore\fR routine sets the virtual screen to the contents -of \fIfilename\fR, which must have been written using \fBscr_dump\fR. The next -call to \fBdoupdate\fR restores the screen to the way it looked in the dump -file. - -The \fBscr_init\fR routine reads in the contents of \fIfilename\fR and uses -them to initialize the \fBcurses\fR data structures about what the terminal -currently has on its screen. If the data is determined to be valid, -\fBcurses\fR bases its next update of the screen on this information rather -than clearing the screen and starting from scratch. \fBscr_init\fR is used -after \fBinitscr\fR or a \fBsystem\fR call to share -the screen with another process which has done a \fBscr_dump\fR after its -\fBendwin\fR call. The data is declared invalid if the terminfo capabilities -\fBrmcup\fR and \fBnrrmc\fR exist; also if the terminal has been written to -since the preceding \fBscr_dump\fR call. - -The \fBscr_set\fR routine is a combination of \fBscr_restore\fR and -\fBscr_init\fR. It tells the program that the information in \fIfilename\fR is -what is currently on the screen, and also what the program wants on the screen. -This can be thought of as a screen inheritance function. - -To read (write) a window from (to) a file, use the \fBgetwin\fR and -\fBputwin\fR routines [see \fBcurs_util\fR(3X)]. -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and \fBOK\fR -upon success. -.SH NOTES -Note that \fBscr_init\fR, \fBscr_set\fR, and \fBscr_restore\fR may be macros. -.SH PORTABILITY -The XSI Curses standard, Issue 4, describes these functions (adding the const -qualifiers). - -The SVr4 docs merely say under \fBscr_init\fR that the dump data is also -considered invalid "if the time-stamp of the tty is old" but don't define -"old". -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_refresh\fR(3X), -\fBcurs_util\fR(3X), \fBsystem\fR(3S) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_scroll.3x b/contrib/ncurses-5.4/man/curs_scroll.3x deleted file mode 100644 index 4e694c33b1..0000000000 --- a/contrib/ncurses-5.4/man/curs_scroll.3x +++ /dev/null @@ -1,84 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2001,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_scroll.3x,v 1.10 2003/05/10 20:33:49 jmc Exp $ -.TH curs_scroll 3X "" -.SH NAME -\fBscroll\fR, \fBscrl\fR, \fBwscrl\fR - scroll a \fBcurses\fR window -.SH SYNOPSIS -\fB#include \fR - -\fBint scroll(WINDOW *win);\fR -.br -\fBint scrl(int n);\fR -.br -\fBint wscrl(WINDOW *win, int n);\fR -.br -.SH DESCRIPTION -The \fBscroll\fR routine scrolls the window up one line. -This involves moving -the lines in the window data structure. -As an optimization, if the scrolling -region of the window is the entire screen, the physical screen may be scrolled -at the same time. - -For positive \fIn\fR, the \fBscrl\fR and \fBwscrl\fR routines scroll the -window up \fIn\fR lines (line \fIi\fR+\fIn\fR becomes \fIi\fR); otherwise -scroll the window down \fIn\fR lines. -This involves moving the lines in the -window character image structure. -The current cursor position is not changed. - -For these functions to work, scrolling must be enabled via \fBscrollok\fR. -.SH RETURN VALUE -These routines return \fBERR\fR upon failure, and \fBOK\fR (SVr4 only specifies -"an integer value other than \fBERR\fR") upon successful completion. -.SH NOTES -Note that \fBscrl\fR and \fBscroll\fR may be macros. - -The SVr4 documentation says that the optimization of physically scrolling -immediately if the scroll region is the entire screen "is" performed, not -"may be" performed. -This implementation deliberately does not guarantee -that this will occur, to leave open the possibility of smarter -optimization of multiple scroll actions on the next update. - -Neither the SVr4 nor the XSI documentation specify whether the current -attribute or -current color-pair of blanks generated by the scroll function is zeroed. -Under this implementation it is. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_outopts\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_slk.3x b/contrib/ncurses-5.4/man/curs_slk.3x deleted file mode 100644 index 1271f85969..0000000000 --- a/contrib/ncurses-5.4/man/curs_slk.3x +++ /dev/null @@ -1,149 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_slk.3x,v 1.12 2003/05/10 20:33:49 jmc Exp $ -.TH curs_slk 3X "" -.SH NAME -\fBslk_init\fR, \fBslk_set\fR, \fBslk_refresh\fR, -\fBslk_noutrefresh\fR, \fBslk_label\fR, -\fBslk_clear\fR, \fBslk_restore\fR, \fBslk_touch\fR, -\fBslk_attron\fR, \fBslk_attrset\fR, \fBslk_attroff\fR, -\fBslk_attr_on\fR, \fBslk_attr_set\fR, \fBslk_attr_off\fR, -\fBslk_attr\fR, \fBslk_color\fR - \fBcurses\fR soft label routines -.SH SYNOPSIS -\fB#include \fR - -\fBint slk_init(int fmt);\fR -.br -\fBint slk_set(int labnum, const char *label, int fmt);\fR -.br -\fBint slk_refresh(void);\fR -.br -\fBint slk_noutrefresh(void);\fR -.br -\fBchar *slk_label(int labnum);\fR -.br -\fBint slk_clear(void);\fR -.br -\fBint slk_restore(void);\fR -.br -\fBint slk_touch(void);\fR -.br -\fBint slk_attron(const chtype attrs);\fR -.br -\fBint slk_attroff(const chtype attrs);\fR -.br -\fBint slk_attrset(const chtype attrs);\fR -.br -\fBint slk_attr_on(attr_t attrs, void* opts);\fR -.br -\fBint slk_attr_off(const attr_t attrs, void * opts);\fR -.br -\fBint slk_attr_set(const attr_t attrs,\fR -.br - \fBshort color_pair_number, void* opts);\fR -.br -\fBattr_t slk_attr(void);\fR -.br -\fBint slk_color(short color_pair_number);\fR -.br -.SH DESCRIPTION -The slk* functions manipulate the set of soft function-key labels that exist on -many terminals. For those terminals that do not have soft labels, -\fBcurses\fR takes over the bottom line of \fBstdscr\fR, reducing the size of -\fBstdscr\fR and the variable \fBLINES\fR. \fBcurses\fR standardizes on eight -labels of up to eight characters each. In addition to this, the ncurses -implementation supports a mode where it simulates 12 labels of up to five -characters each. This is most common for todays PC like enduser devices. -Please note that ncurses simulates this mode by taking over up to two lines at -the bottom of the screen, it doesn't try to use any hardware support for this -mode. - -The \fBslk_init\fR routine must be called before \fBinitscr\fR or \fBnewterm\fR -is called. If \fBinitscr\fR eventually uses a line from \fBstdscr\fR to -emulate the soft labels, then \fIfmt\fR determines how the labels are arranged -on the screen. Setting \fIfmt\fR to \fB0\fR indicates a 3-2-3 arrangement of -the labels, \fB1\fR indicates a 4-4 arrangement and \fB2\fR indicates the -PC like 4-4-4 mode. If \fBfmt\fR is set to \fB3\fR, it is again the PC like -4-4-4 mode, but in addition an index line is generated, helping the user to -identify the key numbers easily. - -The \fBslk_set\fR routine requires \fIlabnum\fR to be a label number, -from \fB1\fR to \fB8\fR (resp. \fB12\fR); \fIlabel\fR must be the string -to be put on the label, up to eight (resp. five) characters in length. -A null string or a null pointer sets up a blank label. \fIfmt\fR is either -\fB0\fR, \fB1\fR, or \fB2\fR, indicating whether the label is to be -left-justified, centered, or right-justified, respectively, within the -label. - -The \fBslk_refresh\fR and \fBslk_noutrefresh\fR routines correspond to -the \fBwrefresh\fR and \fBwnoutrefresh\fR routines. - -The \fBslk_label\fR routine returns the current label for label number -\fIlabnum\fR, with leading and trailing blanks stripped. - -The \fBslk_clear\fR routine clears the soft labels from the screen. - -The \fBslk_restore\fR routine restores the soft labels to the screen -after a \fBslk_clear\fR has been performed. - -The \fBslk_touch\fR routine forces all the soft labels to be output -the next time a \fBslk_noutrefresh\fR is performed. - -The \fBslk_attron\fR, \fBslk_attrset\fR, \fBslk_attroff\fR and \fBslk_attr\fR -routines correspond to \fBattron\fR, \fBattrset\fR, \fBattroff\fR and \fBattr_get\fR. -They have an effect only if soft labels are simulated on the bottom line of -the screen. The default highlight for soft keys is A_STANDOUT (as in -System V curses, which does not document this fact). - -The \fBslk_color\fR routine corresponds to \fBcolor_set\fR. It has an effect only -if soft labels are simulated on the bottom line of the screen. - -.SH RETURN VALUE -These routines return \fBERR\fR upon failure and OK (SVr4 specifies only "an -integer value other than \fBERR\fR") upon successful completion. \fBslk_attr\fR -returns the attribute used for the soft keys. - -\fBslk_label\fR returns \fBNULL\fR on error. -.SH NOTES -Most applications would use \fBslk_noutrefresh\fR because a -\fBwrefresh\fR is likely to follow soon. -.SH PORTABILITY -The XSI Curses standard, Issue 4, describes these functions. It changes the -argument type of the attribute-manipulation functions \fBslk_attron\fR, -\fBslk_attroff\fR, \fBslk_attrset\fR to be \fBattr_t\fR, and adds \fBconst\fR -qualifiers. The format codes \fB2\fR and \fB3\fR for \fBslk_init()\fR and the -function \fBslk_attr\fR are specific to ncurses. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_attr\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_refresh\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_termattrs.3x b/contrib/ncurses-5.4/man/curs_termattrs.3x deleted file mode 100644 index 48ff21ced6..0000000000 --- a/contrib/ncurses-5.4/man/curs_termattrs.3x +++ /dev/null @@ -1,134 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_termattrs.3x,v 1.9 2003/12/27 18:37:47 tom Exp $ -.TH curs_termattrs 3X "" -.SH NAME -\fBbaudrate\fR, -\fBerasechar\fR, -\fBerasewchar\fR, -\fBhas_ic\fR, -\fBhas_il\fR, -\fBkillchar\fR, -\fBkillwchar\fR, -\fBlongname\fR, -\fBterm_attrs\fR, -\fBtermattrs\fR, -\fBtermname\fR - \fBcurses\fR environment query routines -.SH SYNOPSIS -\fB#include \fR -.PP -\fBint baudrate(void);\fR -.br -\fBchar erasechar(void);\fR -.br -\fBint erasewchar(wchar_t *\fR\fIch\fR\fB);\fR -.br -\fBbool has_ic(void);\fR -.br -\fBbool has_il(void);\fR -.br -\fBchar killchar(void);\fR -.br -\fBint killwchar(wchar_t *\fR\fIch\fR\fB);\fR -.br -\fBchar *longname(void);\fR -.br -\fBattr_t term_attrs(void);\fR -.br -\fBchtype termattrs(void);\fR -.br -\fBchar *termname(void);\fR -.br -.SH DESCRIPTION -The \fBbaudrate\fR routine returns the output speed of the terminal. The -number returned is in bits per second, for example \fB9600\fR, and is an -integer. -.PP -The \fBerasechar\fR routine returns the user's current erase character. -.PP -The \fBerasewchar\fR routine stores the current erase character -in the location referenced by \fIch\fR. -If no erase character has been defined, the routine fails -and the location referenced by \fIch\fR is not changed. -.PP -The \fBhas_ic\fR routine is true if the terminal has insert- and delete- -character capabilities. -.PP -The \fBhas_il\fR routine is true if the terminal has insert- and delete-line -capabilities, or can simulate them using scrolling regions. This might -be used to determine if it would be appropriate to turn on physical -scrolling using \fBscrollok\fR. -.PP -The \fBkillchar\fR routine returns the user's current line kill character. -.PP -The \fBkillwchar\fR routine stores the current line-kill character -in the location referenced by \fIch\fR. -If no line-kill character has been defined, -the routine fails and the location referenced by \fIch\fR is not changed. -.PP -The \fBlongname\fR routine returns a pointer to a static area -containing a verbose description of the current terminal. The maximum -length of a verbose description is 128 characters. It is defined only -after the call to \fBinitscr\fR or \fBnewterm\fR. The area is -overwritten by each call to \fBnewterm\fR and is not restored by -\fBset_term\fR, so the value should be saved between calls to -\fBnewterm\fR if \fBlongname\fR is going to be used with multiple -terminals. -.PP -If a given terminal doesn't support a video attribute that an -application program is trying to use, \fBcurses\fR may substitute a -different video attribute for it. -The \fBtermattrs\fR and \fBterm_attrs\fR functions -return a logical \fBOR\fR of all video attributes supported by the -terminal using \fIA_\fR and \fIWA_\fR constants respectively. -This information is useful when a \fBcurses\fR program -needs complete control over the appearance of the screen. -.PP -The \fBtermname\fR routine returns the terminal name used by \fBsetupterm\fR. -.SH RETURN VALUE -\fBlongname\fR and \fBtermname\fR return \fBNULL\fR on error. -.PP -Routines that return an integer return \fBERR\fR upon failure and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. -.SH NOTES -Note that \fBtermattrs\fR may be a macro. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. It changes the -return type of \fBtermattrs\fR to the new type \fBattr_t\fR. -Most versions of curses truncate the result returned by \fBtermname\fR to -14 characters. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_outopts\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_termcap.3x b/contrib/ncurses-5.4/man/curs_termcap.3x deleted file mode 100644 index c5c5517e61..0000000000 --- a/contrib/ncurses-5.4/man/curs_termcap.3x +++ /dev/null @@ -1,164 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_termcap.3x,v 1.18 2003/02/08 22:25:47 tom Exp $ -.TH curs_termcap 3X "" -.ds n 5 -.SH NAME -\fBtgetent\fR, -\fBtgetflag\fR, -\fBtgetnum\fR, -\fBtgetstr\fR, -\fBtgoto\fR, -\fBtputs\fR - direct \fBcurses\fR interface to the terminfo capability database -.SH SYNOPSIS -\fB#include \fR -.br -\fB#include \fR -.br -\fBextern char PC;\fR -\fBextern char * UP;\fR -\fBextern char * BC;\fR -\fBextern @NCURSES_OSPEED@ ospeed;\fR -.br -\fBint tgetent(char *bp, const char *name);\fR -.br -\fBint tgetflag(char *id);\fR -.br -\fBint tgetnum(char *id);\fR -.br -\fBchar *tgetstr(char *id, char **area);\fR -.br -\fBchar *tgoto(const char *cap, int col, int row);\fR -.br -\fBint tputs(const char *str, int affcnt, int (*putc)(int));\fR -.br -.SH DESCRIPTION -These routines are included as a conversion aid for programs that use -the \fItermcap\fR library. Their parameters are the same and the -routines are emulated using the \fIterminfo\fR database. Thus, they -can only be used to query the capabilities of entries for which a -terminfo entry has been compiled. - -The \fBtgetent\fR routine loads the entry for \fIname\fR. -It returns 1 on success, 0 if there is no such entry, and -1 if the -terminfo database could not be found. -The emulation ignores the buffer pointer \fIbp\fR. - -The \fBtgetflag\fR routine gets the boolean entry for \fIid\fR, -or zero if it is not available. - -The \fBtgetnum\fR routine gets the numeric entry for \fIid\fR, -or -1 if it is not available. - -The \fBtgetstr\fR routine returns the string entry for \fIid\fR, -or zero if it is not available. -Use \fBtputs\fR to output the returned string. -The return value will also be copied to the buffer pointed to by \fIarea\fR, -and the \fIarea\fR value will be updated to point past the null ending -this value. - -Only the first two characters of the \fBid\fR parameter of -\fBtgetflag\fR, -\fBtgetnum\fR and -\fBtgetstr\fR are compared in lookups. - -The \fBtgoto\fR routine instantiates the parameters into the given capability. -The output from this routine is to be passed to \fBtputs\fR. - -The \fBtputs\fR routine is described on the \fBcurs_terminfo\fR(3X) manual -page. It can retrieve capabilities by either termcap or terminfo name. - -The variables -\fBPC\fR, -\fBUP\fR and -\fBBC\fR -are set by \fBtgetent\fR to the terminfo entry's data for -\fBpad_char\fR, -\fBcursor_up\fR and -\fBbackspace_if_not_bs\fR, -respectively. -\fBUP\fR is not used by ncurses. -\fBPC\fR is used in the \fBtdelay_output\fR function. -\fBBC\fR is used in the \fBtgoto\fR emulation. -The variable \fBospeed\fR is set by ncurses in a system-specific coding -to reflect the terminal speed. - -.SH RETURN VALUE -Except where explicitly noted, -routines that return an integer return \fBERR\fR upon failure and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion. - -Routines that return pointers return \fBNULL\fR on error. -.SH BUGS -If you call \fBtgetstr\fR to fetch \fBca\fR or any other parameterized string, -be aware that it will be returned in terminfo notation, not the older and -not-quite-compatible termcap notation. This won't cause problems if all -you do with it is call \fBtgoto\fR or \fBtparm\fR, which both expand -terminfo-style strings as terminfo. -(The \fBtgoto\fR function, if configured to support termcap, will check -if the string is indeed terminfo-style by looking for "%p" parameters or -"$<..>" delays, and invoke a termcap-style parser if the string does not -appear to be terminfo). - -Because terminfo conventions for representing padding in string capabilities -differ from termcap's, \fBtputs("50");\fR will put out a literal "50" rather -than busy-waiting for 50 milliseconds. Cope with it. - -Note that termcap has nothing analogous to terminfo's \fBsgr\fR string. -One consequence of this is that termcap applications assume \fRme\fR -(terminfo \fBsgr0\fR) does not reset the alternate character set. -This implementation checks for, and modifies the data shown to the -termcap interface to accommodate termcap's limitation in this respect. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. However, they -are marked TO BE WITHDRAWN and may be removed in future versions. - -Neither the XSI Curses standard nor the SVr4 man pages documented the return -values of \fBtgetent\fR correctly, though all three were in fact returned ever -since SVr1. -In particular, an omission in the XSI Curses documentation has been -misinterpreted to mean that \fBtgetent\fR returns \fBOK\fR or \fBERR\fR. -Because the purpose of these functions is to provide compatibility with -the \fItermcap\fR library, that is a defect in XCurses, Issue 4, Version 2 -rather than in ncurses. - -External variables are provided for support of certain termcap applications. -However, termcap applications' use of those variables is poorly documented, -e.g., not distinguishing between input and output. -In particular, some applications are reported to declare and/or -modify \fBospeed\fR. -.SH SEE ALSO -\fBcurses\fR(3X), \fBterminfo\fR(\*n), \fBputc\fR(3S). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_terminfo.3x b/contrib/ncurses-5.4/man/curs_terminfo.3x deleted file mode 100644 index d5c9bf6827..0000000000 --- a/contrib/ncurses-5.4/man/curs_terminfo.3x +++ /dev/null @@ -1,294 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1999-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_terminfo.3x,v 1.18 2003/12/27 18:48:59 tom Exp $ -.TH curs_terminfo 3X "" -.ds n 5 -.SH NAME -\fBdel_curterm\fR, -\fBmvcur\fR, -\fBputp\fR, -\fBrestartterm\fR, -\fBset_curterm\fR, -\fBsetterm\fR, -\fBsetupterm\fR, -\fBtigetflag\fR, -\fBtigetnum\fR, -\fBtigetstr\fR, -\fBtparm\fR, -\fBtputs\fR, -\fBvid_attr\fR, -\fBvid_puts\fR, -\fBvidattr\fR, -\fBvidputs\fR - \fBcurses\fR interfaces to terminfo database -.SH SYNOPSIS -.nf -\fB#include \fR -.br -\fB#include \fR -.PP -\fBint setupterm(char *\fR\fIterm\fR\fB, int \fR\fIfildes\fR\fB, int *\fR\fIerrret\fR\fB);\fR -.br -\fBint setterm(char *\fR\fIterm\fR\fB);\fR -.br -\fBTERMINAL *set_curterm(TERMINAL *\fR\fInterm\fR\fB);\fR -.br -\fBint del_curterm(TERMINAL *\fR\fIoterm\fR\fB);\fR -.br -\fBint restartterm(const char *\fR\fIterm\fR\fB, int \fR\fIfildes\fR\fB, int *\fR\fIerrret\fR\fB);\fR -.br -\fBchar *tparm(char *\fR\fIstr\fR\fB, ...);\fR -.br -\fBint tputs(const char *\fR\fIstr\fR\fB, int \fR\fIaffcnt\fR\fB, int (*\fR\fIputc\fR\fB)(int));\fR -.br -\fBint putp(const char *\fR\fIstr\fR\fB);\fR -.br -\fBint vidputs(chtype \fR\fIattrs\fR\fB, int (*\fR\fIputc\fR\fB)(int));\fR -.br -\fBint vidattr(chtype \fR\fIattrs\fR\fB);\fR -.br -\fBint vid_puts(attr_t \fR\fIattrs\fR\fB, short \fR\fIpair\fR\fB, void *\fR\fIopts\fR\fB, int (*\fR\fIputc\fR\fB)(char));\fR -.br -\fBint vid_attr(attr_t \fR\fIattrs\fR\fB, short \fR\fIpair\fR\fB, void *\fR\fIopts\fR\fB);\fR -.br -\fBint mvcur(int \fR\fIoldrow\fR\fB, int \fR\fIoldcol\fR\fB, int \fR\fInewrow\fR, int \fR\fInewcol\fR\fB);\fR -.br -\fBint tigetflag(char *\fR\fIcapname\fR\fB);\fR -.br -\fBint tigetnum(char *\fR\fIcapname\fR\fB);\fR -.br -\fBchar *tigetstr(char *\fR\fIcapname\fR\fB);\fR -.br -.fi -.SH DESCRIPTION -These low-level routines must be called by programs that have to deal -directly with the \fBterminfo\fR database to handle certain terminal -capabilities, such as programming function keys. For all other -functionality, \fBcurses\fR routines are more suitable and their use is -recommended. -.PP -Initially, \fBsetupterm\fR should be called. Note that -\fBsetupterm\fR is automatically called by \fBinitscr\fR and -\fBnewterm\fR. This defines the set of terminal-dependent variables -[listed in \fBterminfo\fR(\*n)]. The \fBterminfo\fR variables -\fBlines\fR and \fBcolumns\fR are initialized by \fBsetupterm\fR as -follows: If \fBuse_env(FALSE)\fR has been called, values for -\fBlines\fR and \fBcolumns\fR specified in \fBterminfo\fR are used. -Otherwise, if the environment variables \fBLINES\fR and \fBCOLUMNS\fR -exist, their values are used. If these environment variables do not -exist and the program is running in a window, the current window size -is used. Otherwise, if the environment variables do not exist, the -values for \fBlines\fR and \fBcolumns\fR specified in the -\fBterminfo\fR database are used. -.PP -The header files \fBcurses.h\fR and \fBterm.h\fR should be included (in this -order) to get the definitions for these strings, numbers, and flags. -Parameterized strings should be passed through \fBtparm\fR to instantiate them. -All \fBterminfo\fR strings [including the output of \fBtparm\fR] should be printed -with \fBtputs\fR or \fBputp\fR. Call the \fBreset_shell_mode\fR to restore the -tty modes before exiting [see \fBcurs_kernel\fR(3X)]. Programs which use -cursor addressing should output \fBenter_ca_mode\fR upon startup and should -output \fBexit_ca_mode\fR before exiting. Programs desiring shell escapes -should call -.PP -\fBreset_shell_mode\fR and output \fBexit_ca_mode\fR before the shell -is called and should output \fBenter_ca_mode\fR and call -\fBreset_prog_mode\fR after returning from the shell. -.PP -The \fBsetupterm\fR routine reads in the \fBterminfo\fR database, -initializing the \fBterminfo\fR structures, but does not set up the -output virtualization structures used by \fBcurses\fR. The terminal -type is the character string \fIterm\fR; if \fIterm\fR is null, the -environment variable \fBTERM\fR is used. -All output is to file descriptor \fBfildes\fR which is initialized for output. -If \fIerrret\fR is not null, -then \fBsetupterm\fR returns \fBOK\fR or -\fBERR\fR and stores a status value in the integer pointed to by -\fIerrret\fR. -A return value of \fBOK\fR combined with status of \fB1\fR in \fIerrret\fR -is normal. -If \fBERR\fR is returned, examine \fIerrret\fR: -.RS -.TP 5 -.B 1 -means that the terminal is hardcopy, cannot be used for curses applications. -.TP 5 -.B 0 -means that the terminal could not be found, -or that it is a generic type, -having too little information for curses applications to run. -.TP 5 -.B -1 -means that the \fBterminfo\fR database could not be found. -.RE -.PP -If \fIerrret\fR is -null, \fBsetupterm\fR prints an error message upon finding an error -and exits. Thus, the simplest call is: - - \fBsetupterm((char *)0, 1, (int *)0);\fR, - -which uses all the defaults and sends the output to \fBstdout\fR. -.PP -The \fBsetterm\fR routine is being replaced by \fBsetupterm\fR. The call: - - \fBsetupterm(\fR\fIterm\fR\fB, 1, (int *)0)\fR - -provides the same functionality as \fBsetterm(\fR\fIterm\fR\fB)\fR. -The \fBsetterm\fR routine is included here for BSD compatibility, and -is not recommended for new programs. -.PP -The \fBset_curterm\fR routine sets the variable \fBcur_term\fR to -\fInterm\fR, and makes all of the \fBterminfo\fR boolean, numeric, and -string variables use the values from \fInterm\fR. It returns the old value -of \fBcur_term\fR. -.PP -The \fBdel_curterm\fR routine frees the space pointed to by -\fIoterm\fR and makes it available for further use. If \fIoterm\fR is -the same as \fBcur_term\fR, references to any of the \fBterminfo\fR -boolean, numeric, and string variables thereafter may refer to invalid -memory locations until another \fBsetupterm\fR has been called. -.PP -The \fBrestartterm\fR routine is similar to \fBsetupterm\fR and \fBinitscr\fR, -except that it is called after restoring memory to a previous state (for -example, when reloading a game saved as a core image dump). It assumes that -the windows and the input and output options are the same as when memory was -saved, but the terminal type and baud rate may be different. Accordingly, -it saves various tty state bits, does a setupterm, and then restores the bits. -.PP -The \fBtparm\fR routine instantiates the string \fIstr\fR with -parameters \fIpi\fR. A pointer is returned to the result of \fIstr\fR -with the parameters applied. -.PP -The \fBtputs\fR routine applies padding information to the string -\fIstr\fR and outputs it. The \fIstr\fR must be a terminfo string -variable or the return value from \fBtparm\fR, \fBtgetstr\fR, or -\fBtgoto\fR. \fIaffcnt\fR is the number of lines affected, or 1 if -not applicable. \fIputc\fR is a \fBputchar\fR-like routine to which -the characters are passed, one at a time. -.PP -The \fBputp\fR routine calls \fBtputs(\fR\fIstr\fR\fB, 1, putchar)\fR. -Note that the output of \fBputp\fR always goes to \fBstdout\fR, not to -the \fIfildes\fR specified in \fBsetupterm\fR. -.PP -The \fBvidputs\fR routine displays the string on the terminal in the -video attribute mode \fIattrs\fR, which is any combination of the -attributes listed in \fBcurses\fR(3X). The characters are passed to -the \fBputchar\fR-like routine \fIputc\fR. -.PP -The \fBvidattr\fR routine is like the \fBvidputs\fR routine, except -that it outputs through \fBputchar\fR. -.PP -The \fBvid_attr\fR and \fBvid_puts\fR routines correspond to vidattr and vidputs, -respectively. -They use a set of arguments for representing the video attributes plus color, -i.e., -one of type attr_t for the attributes and one of short for -the color_pair number. -The \fBvid_attr\fR and \fBvid_puts\fR routines -are designed to use the attribute constants with the \fIWA_\fR prefix. -The opts argument is reserved for future use. -Currently, applications must provide a null pointer for that argument. -.PP -The \fBmvcur\fR routine provides low-level cursor motion. It takes -effect immediately (rather than at the next refresh). -.PP -The \fBtigetflag\fR, \fBtigetnum\fR and \fBtigetstr\fR routines return -the value of the capability corresponding to the \fBterminfo\fR -\fIcapname\fR passed to them, such as \fBxenl\fR. -.PP -The \fBtigetflag\fR routine returns the value \fB-1\fR if -\fIcapname\fR is not a boolean capability, -or \fB0\fR if it is canceled or absent from the terminal description. -.PP -The \fBtigetnum\fR routine returns the value \fB-2\fR if -\fIcapname\fR is not a numeric capability, -or \fB-1\fR if it is canceled or absent from the terminal description. -.PP -The \fBtigetstr\fR routine returns the value \fB(char *)-1\fR -if \fIcapname\fR is not a string capability, -or \fB0\fR if it is canceled or absent from the terminal description. -.PP -The \fIcapname\fR for each capability is given in the table column entitled -\fIcapname\fR code in the capabilities section of \fBterminfo\fR(\*n). - -\fBchar *boolnames\fR, \fB*boolcodes\fR, \fB*boolfnames\fR - -\fBchar *numnames\fR, \fB*numcodes\fR, \fB*numfnames\fR - -\fBchar *strnames\fR, \fB*strcodes\fR, \fB*strfnames\fR - -These null-terminated arrays contain the \fIcapnames\fR, the -\fBtermcap\fR codes, and the full C names, for each of the -\fBterminfo\fR variables. -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure and \fBOK\fR -(SVr4 only specifies "an integer value other than \fBERR\fR") upon successful -completion, unless otherwise noted in the preceding routine descriptions. -.PP -Routines that return pointers always return \fBNULL\fR on error. -.SH NOTES -The \fBsetupterm\fR routine should be used in place of \fBsetterm\fR. -It may be useful when you want to test for terminal capabilities without -committing to the allocation of storage involved in \fBinitscr\fR. -.PP -Note that \fBvidattr\fR and \fBvidputs\fR may be macros. -.SH PORTABILITY -The function \fBsetterm\fR is not described in the XSI Curses standard and must -be considered non-portable. All other functions are as described in the XSI -curses standard. -.PP -In System V Release 4, \fBset_curterm\fR has an \fBint\fR return type and -returns \fBOK\fR or \fBERR\fR. We have chosen to implement the XSI Curses -semantics. -.PP -In System V Release 4, the third argument of \fBtputs\fR has the type -\fBint (*putc)(char)\fR. -.PP -The XSI Curses standard prototypes \fBtparm\fR with a fixed number of parameters, -rather than a variable argument list. -This implementation uses a variable argument list. -Portable applications should provide 9 parameters after the format; -zeroes are fine for this purpose. -.PP -XSI notes that after calling \fBmvcur\fR, the curses state may not match the -actual terminal state, and that an application should touch and refresh -the window before resuming normal curses calls. -Both ncurses and System V Release 4 curses implement \fBmvcur\fR using -the SCREEN data allocated in either \fBinitscr\fR or \fBnewterm\fR. -So though it is documented as a terminfo function, -\fBmvcur\fR is really a curses function which is not well specified. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_kernel\fR(3X), \fBcurs_termcap\fR(3X), -\fBputc\fR(3S), \fBterminfo\fR(\*n) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_touch.3x b/contrib/ncurses-5.4/man/curs_touch.3x deleted file mode 100644 index 58ffa9f604..0000000000 --- a/contrib/ncurses-5.4/man/curs_touch.3x +++ /dev/null @@ -1,96 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2000 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_touch.3x,v 1.8 2000/07/08 11:07:57 tom Exp $ -.TH curs_touch 3X "" -.SH NAME -\fBtouchwin\fR, -\fBtouchline\fR, -\fBuntouchwin\fR, -\fBwtouchln\fR, -\fBis_linetouched\fR, -\fBis_wintouched\fR - \fBcurses\fR refresh control routines -.SH SYNOPSIS -\fB#include \fR -.br -\fBint touchwin(WINDOW *win);\fR -.br -\fBint touchline(WINDOW *win, int start, int count);\fR -.br -\fBint untouchwin(WINDOW *win);\fR -.br -\fBint wtouchln(WINDOW *win, int y, int n, int changed);\fR -.br -\fBbool is_linetouched(WINDOW *win, int line);\fR -.br -\fBbool is_wintouched(WINDOW *win);\fR -.br -.SH DESCRIPTION -The \fBtouchwin\fR and \fBtouchline\fR routines throw away all -optimization information about which parts of the window have been -touched, by pretending that the entire window has been drawn on. This -is sometimes necessary when using overlapping windows, since a change -to one window affects the other window, but the records of which lines -have been changed in the other window do not reflect the change. The -routine \fBtouchline\fR only pretends that \fIcount\fR lines have been -changed, beginning with line \fIstart\fR. - -The \fBuntouchwin\fR routine marks all lines in the window as unchanged since -the last call to \fBwrefresh\fR. - -The \fBwtouchln\fR routine makes \fIn\fR lines in the window, starting -at line \fIy\fR, look as if they have (\fIchanged\fR\fB=1\fR) or have -not (\fIchanged\fR\fB=0\fR) been changed since the last call to -\fBwrefresh\fR. - -The \fBis_linetouched\fR and \fBis_wintouched\fR routines return -\fBTRUE\fR if the specified line/window was modified since the last -call to \fBwrefresh\fR; otherwise they return \fBFALSE\fR. In -addition, \fBis_linetouched\fR returns \fBERR\fR if \fIline\fR is not -valid for the given window. -.SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an integer value -other than \fBERR\fR upon successful completion, unless otherwise noted in the -preceding routine descriptions. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. - -Some historic curses implementations had, as an undocumented feature, the -ability to do the equivalent of \fBclearok(..., 1)\fR by saying -\fBtouchwin(stdscr)\fR or \fBclear(stdscr)\fR. This will not work under -ncurses. -.SH NOTES -Note that all routines except \fBwtouchln\fR may be macros. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_refresh\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_trace.3x b/contrib/ncurses-5.4/man/curs_trace.3x deleted file mode 100644 index 4af258da3b..0000000000 --- a/contrib/ncurses-5.4/man/curs_trace.3x +++ /dev/null @@ -1,149 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2000,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_trace.3x,v 1.5 2002/02/16 22:39:52 tom Exp $ -.TH curs_trace 3X "" -.SH NAME -\fB_tracef\fR, -\fB_tracedump\fR, -\fB_traceattr\fR, -\fB_traceattr2\fR, -\fB_nc_tracebits\fR, -\fB_tracechar\fR, -\fB_tracechtype\fR, -\fB_tracechtype2\fR, -\fB_tracemouse\fR, -\fBtrace\fR - \fBcurses\fR debugging routines -.SH SYNOPSIS -\fB#include \fR -.br -\fBvoid _tracef(const char *format, ...);\fR -.br -\fBvoid _tracedump(const char *label, WINDOW *win);\fR -.br -\fBchar *_traceattr(attr_t attr);\fR -.br -\fBchar *_traceattr2(int buffer, chtype ch);\fR -.br -\fBchar *_nc_tracebits(void);\fR -.br -\fBchar *_tracechar(const unsigned char ch);\fR -.br -\fBchar *_tracechtype(chtype ch);\fR -.br -\fBchar *_tracechtype2(int buffer, chtype ch);\fR -.br -\fBchar *_tracemouse(const MEVENT *event);\fR -.br -\fBvoid trace(const unsigned int param);\fR -.SH DESCRIPTION -The \fBtrace\fR routines are used for debugging the ncurses libraries, -as well as applications which use the ncurses libraries. -These functions are normally available only with the debugging library -\fIlibncurses_g.a\fR, but may be compiled into any model (shared, static, -profile) by defining the symbol \fBTRACE\fR. - -The principal parts of this interface are the \fBtrace\fR routine which -selectively enables different tracing features, and the \fB_tracef\fR -routine which writes formatted data to the \fItrace\fR file. - -Calling \fBtrace\fR with a nonzero parameter opens the file \fBtrace\fR -in the current directory for output. The parameter is formed by OR'ing -values from the list of \fBTRACE_\fP\fIxxx\fR definitions in \fB\fR. -These include: -.TP 5 -TRACE_DISABLE -turn off tracing. -.TP 5 -TRACE_TIMES -trace user and system times of updates. -.TP 5 -TRACE_TPUTS -trace tputs calls. -.TP 5 -TRACE_UPDATE -trace update actions, old & new screens. -.TP 5 -TRACE_MOVE -trace cursor movement and scrolling. -.TP 5 -TRACE_CHARPUT -trace all character outputs. -.TP 5 -TRACE_ORDINARY -trace all update actions. -The old and new screen contents are written to the trace file -for each refresh. -.TP 5 -TRACE_CALLS -trace all curses calls. -The parameters for each call are traced, as well as return values. -.TP 5 -TRACE_VIRTPUT -trace virtual character puts, i.e., calls to \fBaddch\fR. -.TP 5 -TRACE_IEVENT -trace low-level input processing, including timeouts. -.TP 5 -TRACE_BITS -trace state of TTY control bits. -.TP 5 -TRACE_ICALLS -trace internal/nested calls. -.TP 5 -TRACE_CCALLS -trace per-character calls. -.TP 5 -TRACE_DATABASE -trace read/write of terminfo/termcap data. -.TP 5 -TRACE_ATTRS -trace changes to video attributes and colors. -.TP 5 -TRACE_MAXIMUM -maximum trace level, enables all of the separate trace features. - -Some tracing features are enabled whenever the \fBtrace\fR parameter -is nonzero. Some features overlap. -The specific names are used as a guideline. -.SH RETURN VALUE -Routines which return a value are designed to be used as parameters -to the \fB_tracef\fR routine. -.SH PORTABILITY -These functions are not part of the XSI interface. -Some other curses implementations are known to -have similar, undocumented features, -but they are not compatible with ncurses. -.SH SEE ALSO -\fBcurses\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_util.3x b/contrib/ncurses-5.4/man/curs_util.3x deleted file mode 100644 index de19a308c8..0000000000 --- a/contrib/ncurses-5.4/man/curs_util.3x +++ /dev/null @@ -1,146 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2003,2004 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_util.3x,v 1.12 2004/01/31 17:24:53 tom Exp $ -.TH curs_util 3X "" -.SH NAME -\fBdelay_output\fR, -\fBfilter\fR, -\fBflushinp\fR, -\fBgetwin\fR, -\fBkey_name\fR, -\fBkeyname\fR, -\fBputwin\fR, -\fBunctrl\fR, -\fBuse_env\fR, -\fBwunctrl\fR - miscellaneous \fBcurses\fR utility routines -.SH SYNOPSIS -\fB#include \fR -.sp -\fBchar *unctrl(chtype c);\fR -.br -\fBchar *wunctrl(cchar_t *c);\fR -.br -\fBchar *keyname(int c);\fR -.br -\fBchar *key_name(wchar_t w);\fR -.br -\fBvoid filter(void);\fR -.br -\fBvoid use_env(bool f);\fR -.br -\fBint putwin(WINDOW *win, FILE *filep);\fR -.br -\fBWINDOW *getwin(FILE *filep);\fR -.br -\fBint delay_output(int ms);\fR -.br -\fBint flushinp(void);\fR -.br -.SH DESCRIPTION -The \fBunctrl\fR routine returns a character string which is a printable -representation of the character \fIc\fR, ignoring attributes. -Control characters are displayed in the \fB^\fR\fIX\fR notation. -Printing characters are displayed as is. -The corresponding \fBwunctrl\fR returns a printable representation of -a wide-character. -.PP -The \fBkeyname\fR routine returns a character string corresponding to the key \fIc\fR. -Control characters are displayed in the \fB^\fR\fIX\fR notation. -Values above 128 are either meta characters, shown in the \fBM-\fR\fIX\fR notation, -or the names of function keys, or null. -The corresponding \fBkey_name\fR returns a character string corresponding -to the wide-character value \fIw\fR. -The two functions do not return the same set of strings; -the latter returns null where the former would display a meta character. -.PP -The \fBfilter\fR routine, if used, must be called before \fBinitscr\fR or -\fBnewterm\fR are called. The effect is that, during those calls, \fBLINES\fR -is set to 1; the capabilities \fBclear\fR, \fBcup\fR, \fBcud\fR, \fBcud1\fR, -\fBcuu1\fR, \fBcuu\fR, \fBvpa\fR are disabled; and the \fBhome\fR string is -set to the value of \fBcr\fR. -.PP -The \fBuse_env\fR routine, if used, is called before \fBinitscr\fR or -\fBnewterm\fR are called. When called with \fBFALSE\fR as an -argument, the values of \fBlines\fR and \fBcolumns\fR specified in the -\fIterminfo\fR database will be used, even if environment variables -\fBLINES\fR and \fBCOLUMNS\fR (used by default) are set, or if -\fBcurses\fR is running in a window (in which case default behavior -would be to use the window size if \fBLINES\fR and \fBCOLUMNS\fR are -not set). -.PP -The \fBputwin\fR routine writes all data associated with window \fIwin\fR into -the file to which \fIfilep\fR points. This information can be later retrieved -using the \fBgetwin\fR function. -.PP -The \fBgetwin\fR routine reads window related data stored in the file by -\fBputwin\fR. The routine then creates and initializes a new window using that -data. It returns a pointer to the new window. -.PP -The \fBdelay_output\fR routine inserts an \fIms\fR millisecond pause -in output. This routine should not be used extensively because -padding characters are used rather than a CPU pause. -If no padding character is specified, this uses \fBnapms\fR to perform the delay. -.PP -The \fBflushinp\fR routine throws away any typeahead that has been typed by the -user and has not yet been read by the program. -.SH RETURN VALUE -Except for \fBflushinp\fR, routines that return an integer return \fBERR\fR -upon failure and \fBOK\fR (SVr4 specifies only "an integer value other than -\fBERR\fR") upon successful completion. -.PP -\fBflushinp\fR always returns \fBOK\fR. -.PP -Routines that return pointers return \fBNULL\fR on error. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. -It states that \fBunctrl\fR and \fBwunctrl\fR will return a null pointer if -unsuccessful, but does not define any error conditions. -.PP -The SVr4 documentation describes the action of \fBfilter\fR only in the vaguest -terms. The description here is adapted from the XSI Curses standard (which -erroneously fails to describe the disabling of \fBcuu\fR). -.PP -The strings returned by \fBunctrl\fR in this implementation are determined -at compile time, showing C1 controls from the upper-128 codes with a `~' -prefix rather than `^'. -Other implementations typically show both sets of control characters with `^', -and may strip the parameter to 7 bits. -This implementation uses 8 bits but does not modify the string to reflect -locale. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBcurs_initscr\fR(3X), -\fBcurs_kernel\fR(3X), -\fBcurs_scr_dump\fR(3X). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/curs_window.3x b/contrib/ncurses-5.4/man/curs_window.3x deleted file mode 100644 index 6aad4e7f49..0000000000 --- a/contrib/ncurses-5.4/man/curs_window.3x +++ /dev/null @@ -1,159 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: curs_window.3x,v 1.10 2003/05/10 20:33:49 jmc Exp $ -.TH curs_window 3X "" -.SH NAME -\fBnewwin\fR, -\fBdelwin\fR, -\fBmvwin\fR, -\fBsubwin\fR, -\fBderwin\fR, -\fBmvderwin\fR, -\fBdupwin\fR, -\fBwsyncup\fR, -\fBsyncok\fR, -\fBwcursyncup\fR, -\fBwsyncdown\fR - create \fBcurses\fR windows -.SH SYNOPSIS -\fB#include \fR - -\fBWINDOW *newwin(int nlines, int ncols, int begin_y,\fR - \fBint begin_x);\fR -.br -\fBint delwin(WINDOW *win);\fR -.br -\fBint mvwin(WINDOW *win, int y, int x);\fR -.br -\fBWINDOW *subwin(WINDOW *orig, int nlines, int ncols,\fR - \fBint begin_y, int begin_x);\fR -.br -\fBWINDOW *derwin(WINDOW *orig, int nlines, int ncols,\fR - \fBint begin_y, int begin_x);\fR -.br -\fBint mvderwin(WINDOW *win, int par_y, int par_x);\fR -.br -\fBWINDOW *dupwin(WINDOW *win);\fR -.br -\fBvoid wsyncup(WINDOW *win);\fR -.br -\fBint syncok(WINDOW *win, bool bf);\fR -.br -\fBvoid wcursyncup(WINDOW *win);\fR -.br -\fBvoid wsyncdown(WINDOW *win);\fR -.br -.SH DESCRIPTION -Calling \fBnewwin\fR creates and returns a pointer to a new window with the -given number of lines and columns. The upper left-hand corner of the window is -at line \fIbegin\fR_\fIy\fR, column \fIbegin\fR_\fIx\fR. If either -\fInlines\fR or \fIncols\fR is zero, they default to \fBLINES -\fR -\fIbegin\fR_\fIy\fR and \fBCOLS -\fR \fIbegin\fR_\fIx\fR. A new full-screen -window is created by calling \fBnewwin(0,0,0,0)\fR. - -Calling \fBdelwin\fR deletes the named window, freeing all memory -associated with it (it does not actually erase the window's screen -image). Subwindows must be deleted before the main window can be -deleted. - -Calling \fBmvwin\fR moves the window so that the upper left-hand -corner is at position (\fIx\fR, \fIy\fR). If the move would cause the -window to be off the screen, it is an error and the window is not -moved. Moving subwindows is allowed, but should be avoided. - -Calling \fBsubwin\fR creates and returns a pointer to a new window -with the given number of lines, \fInlines\fR, and columns, -\fIncols\fR. The window is at position (\fIbegin\fR_\fIy\fR, -\fIbegin\fR_\fIx\fR) on the screen. (This position is relative to the -screen, and not to the window \fIorig\fR.) The window is made in the -middle of the window \fIorig\fR, so that changes made to one window -will affect both windows. The subwindow shares memory with the window -\fIorig\fR. When using this routine, it is necessary to call -\fBtouchwin\fR or \fBtouchline\fR on \fIorig\fR before calling -\fBwrefresh\fR on the subwindow. - -Calling \fBderwin\fR is the same as calling \fBsubwin,\fR except that -\fIbegin\fR_\fIy\fR and \fIbegin\fR_\fIx\fR are relative to the origin -of the window \fIorig\fR rather than the screen. There is no -difference between the subwindows and the derived windows. - -Calling \fBmvderwin\fR moves a derived window (or subwindow) -inside its parent window. The screen-relative parameters of the -window are not changed. This routine is used to display different -parts of the parent window at the same physical position on the -screen. - -Calling \fBdupwin\fR creates an exact duplicate of the window \fIwin\fR. - -Calling \fBwsyncup\fR touches all locations in ancestors of \fIwin\fR that are -changed in \fIwin\fR. If \fBsyncok\fR is called with second argument -\fBTRUE\fR then \fBwsyncup\fR is called automatically whenever there is a -change in the window. - -The \fBwsyncdown\fR routine touches each location in \fIwin\fR that has been -touched in any of its ancestor windows. This routine is called by -\fBwrefresh\fR, so it should almost never be necessary to call it manually. - -The routine \fBwcursyncup\fR updates the current cursor position of all the -ancestors of the window to reflect the current cursor position of the -window. -.SH RETURN VALUE -Routines that return an integer return the integer \fBERR\fR upon failure and -\fBOK\fR (SVr4 only specifies "an integer value other than \fBERR\fR") upon -successful completion. - -\fBdelwin\fR returns the integer \fBERR\fR upon failure and \fBOK\fR -upon successful completion. - -Routines that return pointers return \fBNULL\fR on error. -.SH NOTES -If many small changes are made to the window, the \fBwsyncup\fR option could -degrade performance. - -Note that \fBsyncok\fR may be a macro. -.SH BUGS -The subwindow functions (\fIsubwin\fR, \fIderwin\fR, \fImvderwin\fR, -\fBwsyncup\fR, \fBwsyncdown\fR, \fBwcursyncup\fR, \fBsyncok\fR) are flaky, -incompletely implemented, and not well tested. - -The System V curses documentation is very unclear about what \fBwsyncup\fR -and \fBwsyncdown\fR actually do. It seems to imply that they are only -supposed to touch exactly those lines that are affected by ancestor changes. -The language here, and the behavior of the \fBcurses\fR implementation, -is patterned on the XPG4 curses standard. The weaker XPG4 spec may result -in slower updates. -.SH PORTABILITY -The XSI Curses standard, Issue 4 describes these functions. -.SH SEE ALSO -\fBcurses\fR(3X), \fBcurs_refresh\fR(3X), \fBcurs_touch\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/default_colors.3x b/contrib/ncurses-5.4/man/default_colors.3x deleted file mode 100644 index ae07899dcb..0000000000 --- a/contrib/ncurses-5.4/man/default_colors.3x +++ /dev/null @@ -1,125 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1997,1999,2000 -.\" -.\" $Id: default_colors.3x,v 1.17 2003/10/25 20:41:08 tom Exp $ -.TH default_colors 3X "" -.SH NAME -\fBuse_default_colors\fR, -\fBassume_default_colors\fR \- use terminal's default colors -.SH SYNOPSIS -\fB#include \fP - -\fBint use_default_colors(void);\fP -.br -\fBint assume_default_colors(int fg, int bg);\fP -.SH DESCRIPTION -The -.I use_default_colors() -and -.I assume_default_colors() -functions are extensions to the curses library. -They are used with terminals that support ISO 6429 color, or equivalent. -These terminals allow the application to reset color to an unspecified -default value (e.g., with SGR 39 or SGR 49). -.PP -Applications that paint a colored background over the whole screen -do not take advantage of SGR 39 and SGR 49. -Some applications are designed to work with the default background, -using colors only for text. -For example, there are several implementations of the \fBls\fP program -which use colors to denote different file types or permissions. -These "color ls" programs do not necessarily modify the background color, -typically using only the \fIsetaf\fP terminfo capability to set the -foreground color. -Full-screen applications that use default colors can achieve similar -visual effects. -.PP -The first function, -.I use_default_colors() -tells the curses library to assign terminal default -foreground/background colors to color number -1. So init_pair(x,COLOR_RED,-1) -will initialize pair x as red on default background and init_pair(x,-1,COLOR_BLUE) will -initialize pair x as default foreground on blue. -.PP -The other, -.I assume_default_colors() -is a refinement which tells which colors to paint for color pair 0. -This function recognizes a special color number -1, -which denotes the default terminal color. -.PP -The following are equivalent: -.RS -.br -.I use_default_colors(); -.br -.I assume_default_colors(-1,-1); -.RE -.PP -These are ncurses extensions. -For other curses implementations, color -number -1 does not mean anything, just as for ncurses before a -successful call of \fIuse_default_colors()\fP or \fIassume_default_colors()\fP. -.PP -Other curses implementations do not allow an application to modify color pair 0. -They assume that the background is COLOR_BLACK, -but do not ensure that the color pair 0 is painted to match the -assumption. -If your application does not use either -.I use_default_colors() -or -.I assume_default_colors() -ncurses will paint a white foreground (text) with black background -for color pair 0. -.SH RETURN VALUE -These functions return the integer \fBERR\fP upon failure and \fBOK\fP on success. -They will fail if either the terminal does not support -the \fIorig_pair\fP or \fIorig_colors\fP capability. -If the \fIinitialize_pair\fP capability is found, this causes an -error as well. -.SH NOTES -Associated with this extension, the \fBinit_pair\fR(3X) function accepts -negative arguments to specify default foreground or background -colors. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBcurs_color\fR(3X), -\fBded\fP(1). -.SH AUTHOR -Thomas Dickey (from an analysis of the requirements for color xterm -for XFree86 3.1.2C, February 1996). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/define_key.3x b/contrib/ncurses-5.4/man/define_key.3x deleted file mode 100644 index c11e14b1e7..0000000000 --- a/contrib/ncurses-5.4/man/define_key.3x +++ /dev/null @@ -1,64 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1997 -.\" -.\" $Id: define_key.3x,v 1.10 2003/10/25 20:33:16 tom Exp $ -.TH define_key 3X "" -.SH NAME -\fBdefine_key\fP \- define a keycode -.SH SYNOPSIS -\fB#include \fP - -\fBint define_key(const char *definition, int keycode);\fP -.SH DESCRIPTION -This is an extension to the curses library. -It permits an application to define keycodes with their corresponding control -strings, so that the ncurses library will interpret them just as it would -the predefined codes in the terminfo database. -.PP -If the given string is null, any existing definition for the keycode is -removed. -Similarly, if the given keycode is negative or zero, any existing string -for the given definition is removed. -.SH RETURN VALUE -The keycode must be greater than zero, else ERR is returned. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBkeyok\fR(3X). -.SH AUTHOR -Thomas Dickey. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form.3x b/contrib/ncurses-5.4/man/form.3x deleted file mode 100644 index 811b9ff747..0000000000 --- a/contrib/ncurses-5.4/man/form.3x +++ /dev/null @@ -1,200 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: form.3x,v 1.15 2002/01/19 22:48:05 tom Exp $ -.TH form 3X "" -.SH NAME -\fBform\fR - curses extension for programming forms -.SH SYNOPSIS -\fB#include \fR -.br -.SH DESCRIPTION -The \fBform\fR library provides terminal-independent facilities for composing -form screens on character-cell terminals. The library includes: field -routines, which create and modify form fields; and form routines, which group -fields into forms, display forms on the screen, and handle interaction with the -user. - -The \fBform\fR library uses the \fBcurses\fR libraries, and a curses -initialization routine such as \fBinitscr\fR must be called before using any of -these functions. To use the \fBform\fR library, link with the options -\fB-lform -lcurses\fR. - -.SS Current Default Values for Field Attributes - -The \fBform\fR library maintains a default value for field attributes. You -can get or set this default by calling the appropriate \fBset_\fR -or retrieval -routine with a \fBNULL\fR field pointer. Changing this default with a -\fBset_\fR function affects future field creations, but does not change the -rendering of fields already created. - -.SS Routine Name Index - -The following table lists each \fBform\fR routine and the name of -the manual page on which it is described. - -.TS -l l -l l . -\fBcurses\fR Routine Name Manual Page Name -= -current_field \fBform_page\fR(3X) -data_ahead \fBform_data\fR(3X) -data_behind \fBform_data\fR(3X) -dup_field \fBform_field_new\fR(3X) -dynamic_fieldinfo \fBform_field_info\fR(3X) -field_arg \fBform_field_validation\fR(3X) -field_back \fBform_field_attributes\fR(3X) -field_buffer \fBform_field_buffer\fR(3X) -field_count \fBform_field\fR(3X) -field_fore \fBform_field_attributes\fR(3X) -field_index \fBform_page\fR(3X) -field_info \fBform_field_info\fR(3X) -field_init \fBform_hook\fR(3X) -field_just \fBform_field_just\fR(3X) -field_opts \fBform_field_opts\fR(3X) -field_opts_off \fBform_field_opts\fR(3X) -field_opts_on \fBform_field_opts\fR(3X) -field_pad \fBform_field_attributes\fR(3X) -field_status \fBform_field_buffer\fR(3X) -field_term \fBform_hook\fR(3X) -field_type \fBform_field_validation\fR(3X) -field_userptr \fBform_field_userptr\fR(3X) -form_driver \fBform_driver\fR(3X) -form_fields \fBform_field\fR(3X) -form_init \fBform_hook\fR(3X) -form_opts \fBform_opts\fR(3X) -form_opts_off \fBform_opts\fR(3X) -form_opts_on \fBform_opts\fR(3X) -form_page \fBform_page\fR(3X) -form_request_by_name \fBform_requestname\fR(3X) -form_request_name \fBform_requestname\fR(3X) -form_sub \fBform_win\fR(3X) -form_term \fBform_hook\fR(3X) -form_userptr \fBform_userptr\fR(3X) -form_win \fBform_win\fR(3X) -free_field \fBform_field_new\fR(3X) -free_form \fBform_new\fR(3X) -link_field \fBform_field_new\fR(3X) -link_fieldtype \fBform_fieldtype\fR(3X) -move_field \fBform_field\fR(3X) -new_field \fBform_field_new\fR(3X) -new_form \fBform_new\fR(3X) -new_page \fBform_new_page\fR(3X) -pos_form_cursor \fBform_cursor\fR(3X) -post_form \fBform_post\fR(3X) -scale_form \fBform_win\fR(3X) -set_current_field \fBform_page\fR(3X) -set_field_back \fBform_field_attributes\fR(3X) -set_field_buffer \fBform_field_buffer\fR(3X) -set_field_fore \fBform_field_attributes\fR(3X) -set_field_init \fBform_hook\fR(3X) -set_field_just \fBform_field_just\fR(3X) -set_field_opts \fBform_field_opts\fR(3X) -set_field_pad \fBform_field_attributes\fR(3X) -set_field_status \fBform_field_buffer\fR(3X) -set_field_term \fBform_hook\fR(3X) -set_field_type \fBform_field_validation\fR(3X) -set_field_userptr \fBform_field_userptr\fR(3X) -set_fieldtype_arg \fBform_fieldtype\fR(3X) -set_fieldtype_choice \fBform_fieldtype\fR(3X) -set_form_fields \fBform_field\fR(3X) -set_form_init \fBform_hook\fR(3X) -set_form_opts \fBform_field_opts\fR(3X) -set_form_page \fBform_page\fR(3X) -set_form_sub \fBform_win\fR(3X) -set_form_term \fBform_hook\fR(3X) -set_form_userptr \fBform_userptr\fR(3X) -set_form_win \fBform_win\fR(3X) -set_max_field \fBform_field_buffer\fR(3X) -set_new_page \fBform_new_page\fR(3X) -unpost_form \fBform_post\fR(3X) -.TE -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Routines that return -an integer return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_CONNECTED\fR -The field is already connected to a form. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The form is already posted. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NO_ROOM\fR -Form is too large for its window. -.TP 5 -\fBE_NOT_POSTED\fR -The form has not been posted. -.TP 5 -\fBE_UNKNOWN_COMMAND\fR -The form driver code saw an unknown request code. -.TP 5 -\fBE_INVALID_FIELD\fR -Contents of a field are not valid. -.TP 5 -\fBE_NOT_CONNECTED\fR -No fields are connected to the form. -.TP 5 -\fBE_REQUEST_DENIED\fR -The form driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header files -\fB\fR and \fB\fR. - -In your library list, libform.a should be before libncurses.a; that is, -you want to say `-lform -lncurses', not the other way around (which would -give you a link error using GNU \fBld\fR(1) and many other linkers). -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for ncurses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_cursor.3x b/contrib/ncurses-5.4/man/form_cursor.3x deleted file mode 100644 index ab37c99e7f..0000000000 --- a/contrib/ncurses-5.4/man/form_cursor.3x +++ /dev/null @@ -1,74 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_cursor.3x,v 1.4 1998/11/29 01:05:43 Rick.Ohnemus Exp $ -.TH form_cursor 3X "" -.SH NAME -\fBform_cursor\fR - position a form window cursor -.SH SYNOPSIS -\fB#include \fR -.br -int pos_form_cursor(FORM *form); -.br -.SH DESCRIPTION -The function \fBpos_form_cursor\fR restores the cursor to the position required -for the forms driver to continue processing requests. This is useful after -\fBcurses\fR routines have been called to do screen-painting in response to a -form operation. -.SH RETURN VALUE -This routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_NOT_POSTED\fR -The form has not been posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_data.3x b/contrib/ncurses-5.4/man/form_data.3x deleted file mode 100644 index 3767e95459..0000000000 --- a/contrib/ncurses-5.4/man/form_data.3x +++ /dev/null @@ -1,63 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_data.3x,v 1.7 1998/11/29 01:13:22 Rick.Ohnemus Exp $ -.TH form_data 3X "" -.SH NAME -\fBform_data\fR - test for off-screen data in given forms -.SH SYNOPSIS -\fB#include \fR -.br -bool data_ahead(const FORM *form); -.br -bool data_behind(const FORM *form); -.br -.SH DESCRIPTION -The function \fBdata_ahead\fR tests whether there is off-screen data -ahead in the given form. It returns TRUE (1) or FALSE (0). - -The function \fBdata_behind\fR tests whether there is off-screen data -behind in the given form. It returns TRUE (1) or FALSE (0). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_driver.3x b/contrib/ncurses-5.4/man/form_driver.3x deleted file mode 100644 index 2354089101..0000000000 --- a/contrib/ncurses-5.4/man/form_driver.3x +++ /dev/null @@ -1,272 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_driver.3x,v 1.9 2002/02/16 22:39:52 tom Exp $ -.TH form_driver 3X "" -.SH NAME -\fBform_driver\fR - command-processing loop of the form system -.SH SYNOPSIS -\fB#include \fR -.br -int form_driver(FORM *form, int c); -.br -.SH DESCRIPTION -Once a form has been posted (displayed), you should funnel input events to it -through \fBform_driver\fR. This routine has two major input cases; either -the input is a form navigation request or it's a printable ASCII character. -The form driver requests are as follows: -.TP 5 -REQ_NEXT_PAGE -Move to the next page. -.TP 5 -REQ_PREV_PAGE -Move to the previous page. -.TP 5 -REQ_FIRST_PAGE -Move to the first page. -.TP 5 -REQ_LAST_PAGE -Move to the last field. - -.TP 5 -REQ_NEXT_FIELD -Move to the next field. -.TP 5 -REQ_PREV_FIELD -Move to the previous field. -.TP 5 -REQ_FIRST_FIELD -Move to the first field. -.TP 5 -REQ_LAST_FIELD -Move to the last field. -.TP 5 -REQ_SNEXT_FIELD -Move to the sorted next field. -.TP 5 -REQ_SPREV_FIELD -Move to the sorted previous field. -.TP 5 -REQ_SFIRST_FIELD -Move to the sorted first field. -.TP 5 -REQ_SLAST_FIELD -Move to the sorted last field. -.TP 5 -REQ_LEFT_FIELD -Move left to a field. -.TP 5 -REQ_RIGHT_FIELD -Move right to a field. -.TP 5 -REQ_UP_FIELD -Move up to a field. -.TP 5 -REQ_DOWN_FIELD -Move down to a field. - -.TP 5 -REQ_NEXT_CHAR -Move to the next char. -.TP 5 -REQ_PREV_CHAR -Move to the previous char. -.TP 5 -REQ_NEXT_LINE -Move to the next line. -.TP 5 -REQ_PREV_LINE -Move to the previous line. -.TP 5 -REQ_NEXT_WORD -Move to the next word. -.TP 5 -REQ_PREV_WORD -Move to the previous word. -.TP 5 -REQ_BEG_FIELD -Move to the beginning of the field. -.TP 5 -REQ_END_FIELD -Move to the end of the field. -.TP 5 -REQ_BEG_LINE -Move to the beginning of the line. -.TP 5 -REQ_END_LINE -Move to the end of the line. -.TP 5 -REQ_LEFT_CHAR -Move left in the field. -.TP 5 -REQ_RIGHT_CHAR -Move right in the field. -.TP 5 -REQ_UP_CHAR -Move up in the field. -.TP 5 -REQ_DOWN_CHAR -Move down in the field. - -.TP 5 -REQ_NEW_LINE -Insert or overlay a new line. -.TP 5 -REQ_INS_CHAR -Insert a blank at the cursor. -.TP 5 -REQ_INS_LINE -Insert a blank line at the cursor. -.TP 5 -REQ_DEL_CHAR -Delete character at the cursor. -.TP 5 -REQ_DEL_PREV -Delete character before the cursor. -.TP 5 -REQ_DEL_LINE -Delete line at the cursor. -.TP 5 -REQ_DEL_WORD -Delete blank-delimited word at the cursor. -.TP 5 -REQ_CLR_EOL -Clear to end of line from cursor. -.TP 5 -REQ_CLR_EOF -Clear to end of field from cursor. -.TP 5 -REQ_CLR_FIELD -Clear the entire field. -.TP 5 -REQ_OVL_MODE -Enter overlay mode. -.TP 5 -REQ_INS_MODE -Enter insert mode. - -.TP 5 -REQ_SCR_FLINE -Scroll the field forward a line. -.TP 5 -REQ_SCR_BLINE -Scroll the field backward a line. -.TP 5 -REQ_SCR_FPAGE -Scroll the field forward a page. -.TP 5 -REQ_SCR_BPAGE -Scroll the field backward a page. -.TP 5 -REQ_SCR_FHPAGE -Scroll the field forward half a page. -.TP 5 -REQ_SCR_BHPAGE -Scroll the field backward half a page. - -.TP 5 -REQ_SCR_FCHAR -Scroll the field forward a character. -.TP 5 -REQ_SCR_BCHAR -Scroll the field backward a character. -.TP 5 -REQ_SCR_HFLINE -Horizontal scroll the field forward a line. -.TP 5 -REQ_SCR_HBLINE -Horizontal scroll the field backward a line. -.TP 5 -REQ_SCR_HFHALF -Horizontal scroll the field forward half a line. -.TP 5 -REQ_SCR_HBHALF -Horizontal scroll the field backward half a line. - -.TP -REQ_VALIDATION -Validate field. -.TP -REQ_NEXT_CHOICE -Display next field choice. -.TP -REQ_PREV_CHOICE -Display previous field choice. -.PP -If the second argument is a printable ASCII character, the driver places it -in the current position in the current field. If it is one of the forms -requests listed above, that request is executed. -.PP -If the second argument is neither printable ASCII nor one of the above -pre-defined form requests, the driver assumes it is an application-specific -command and returns \fBE_UNKNOWN_COMMAND\fR. Application-defined commands -should be defined relative to \fBMAX_COMMAND\fR, the maximum value of these -pre-defined requests. -.SH RETURN VALUE -\fBform_driver\fR return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NOT_POSTED\fR -The form has not been posted. -.TP 5 -\fBE_UNKNOWN_COMMAND\fR -The form driver code saw an unknown request code. -.TP 5 -\fBE_INVALID_FIELD\fR -Contents of field is invalid. -.TP 5 -\fBE_REQUEST_DENIED\fR -The form driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header files -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field.3x b/contrib/ncurses-5.4/man/form_field.3x deleted file mode 100644 index e916bf1825..0000000000 --- a/contrib/ncurses-5.4/man/form_field.3x +++ /dev/null @@ -1,97 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field.3x,v 1.6 2003/05/10 20:33:49 jmc Exp $ -.TH form_field 3X "" -.SH NAME -\fBform_field\fR - make and break connections between fields and forms -.SH SYNOPSIS -\fB#include \fR -.br -int set_form_fields(FORM *form, FIELD **fields); -.br -FIELD **form_fields(const FORM *form); -.br -int field_count(const FORM *form); -.br -int move_field(FIELD *field, int frow, int fcol); -.br -.SH DESCRIPTION -The function \fBset_form_fields\fR changes the field pointer array of -the given \fIform\fR. The array must be terminated by a \fBNULL\fR. - -The function \fBform_fields\fR returns the field array of the given form. - -The function \fBfield_count\fR returns the count of fields in \fIform\fR. - -The function \fBmove_field\fR moves the given field (which must be disconnected) -to a specified location on the screen. -.SH RETURN VALUES -The function \fBform_fields\fR returns \fBNULL\fR on error. - -The function \fBfield_count\fR returns \fBERR\fR (the general -\fBcurses\fR error return value) on error. - -The functions \fBset_form_fields\fR and \fBmove_field\fR return one of -the following codes on error: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The form is already posted. -.TP 5 -\fBE_CONNECTED\fR -The field is already connected to a form. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. - -The SVr4 forms library documentation specifies the \fBfield_count\fR error value -as -1 (which is the value of \fBERR\fR). -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_attributes.3x b/contrib/ncurses-5.4/man/form_field_attributes.3x deleted file mode 100644 index ac7a3b53ee..0000000000 --- a/contrib/ncurses-5.4/man/form_field_attributes.3x +++ /dev/null @@ -1,91 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2001,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_attributes.3x,v 1.7 2002/01/19 22:48:14 tom Exp $ -.TH form_field_attributes 3X "" -.SH NAME -\fBform_field_attributes\fR - color and attribute control for form fields -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_fore(FIELD *field, chtype attr); -.br -chtype field_fore(const FIELD *field); -.br -int set_field_back(FIELD *field, chtype attr); -.br -chtype field_back(const FIELD *field); -.br -int set_field_pad(FIELD *field, int pad); -.br -int field_pad(const FIELD *field); -.br -.SH DESCRIPTION -The function \fBset_field_fore\fR sets the foreground attribute of -\fIfield\fR. This is the highlight used to display the field contents. The -function \fBfield_fore\fR returns the foreground attribute. The default is -\fBA_STANDOUT\fR. - -The function \fBset_field_back\fR sets the background attribute of -\fIform\fR. This is the highlight used to display the extent fields in the -form. The function \fBfield_back\fR returns the background attribute. The -default is \fBA_NORMAL\fR. - -The function \fBset_field_pad\fR sets the character used to fill the field. -The function \fBfield_pad\fR returns the given form's pad character. The -default is a blank. -.SH RETURN VALUE -These routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_buffer.3x b/contrib/ncurses-5.4/man/form_field_buffer.3x deleted file mode 100644 index 7595f53e05..0000000000 --- a/contrib/ncurses-5.4/man/form_field_buffer.3x +++ /dev/null @@ -1,99 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_buffer.3x,v 1.10 2003/05/10 20:22:01 tom Exp $ -.TH form_field_buffer 3X "" -.SH NAME -\fBform_field_buffer\fR - field buffer control -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_buffer(FIELD *field, int buf, const char *value); -.br -char *field_buffer(const FIELD *field, int buffer); -.br -int set_field_status(FIELD *field, bool status); -.br -bool field_status(const FIELD *field); -.br -int set_max_field(FIELD *field, int max); -.br -.SH DESCRIPTION -The function \fBset_field_buffer\fR sets the numbered buffer of the given field -to contain a given string. Buffer 0 is the displayed value of the field; other -numbered buffers may be allocated by applications through the \fBnbuf\fR -argument of (see \fBform_field_new\fR(3X)) but are not manipulated by the forms -library. The function \fBfield_buffer\fR returns the address of the buffer. -Please note that this buffer has always the length of the buffer, that means -that it may typically contain trailing spaces. If you entered leading spaces -the buffer may also contain them. If you want the raw data, you must write your -own routine that copies the value out of the buffer and removes the leading -and trailing spaces. Please note also, that subsequent operations on the form -will probably change the content of the buffer. So don't use it for long term -storage of the entered form data. - -The function \fBset_field_status\fR sets the associated status flag of -\fIfield\fR; \fBfield_status\fR gets the current value. The status flag -is set to a nonzero value whenever the field changes. - -The function \fBset_max_field\fR sets the maximum size for a dynamic field. -An argument of 0 turns off any maximum size threshold for that field. -.SH RETURN VALUE -The \fBfield_buffer\fR function returns NULL on error. - -The \fBfield_status\fR function returns \fBTRUE\fR or \fBFALSE\fR. - -The remaining routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_info.3x b/contrib/ncurses-5.4/man/form_field_info.3x deleted file mode 100644 index 56b81ac7da..0000000000 --- a/contrib/ncurses-5.4/man/form_field_info.3x +++ /dev/null @@ -1,84 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2001,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_info.3x,v 1.8 2002/01/19 22:48:32 tom Exp $ -.TH form_field_info 3X "" -.SH NAME -\fBform_field_info\fR - retrieve field characteristics -.SH SYNOPSIS -\fB#include \fR -.br -int field_info(const FIELD *field, int *rows, int *cols, - int *frow, int *fcol, int *nrow, int *nbuf); -.br -int dynamic_field_info(const FIELD *field, int *rows, int *cols, int *max); -.br -.SH DESCRIPTION -The function \fBfield_info\fR returns the sizes and other attributes passed in -to the field at its creation time. The attributes are: height, width, row of -upper-left corner, column of upper-left corner, number off-screen rows, and -number of working buffers. - -The function \fBdynamic_field_info\fR returns the actual size of the field, and -its maximum possible size. If the field has no size limit, the location -addressed by the third argument will be set to 0. (A field can be made dynamic -by turning off the \fBO_STATIC\fR). -.SH RETURN VALUE -These routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.PP -A null (zero pointer) is accepted for any of the return values, -to ignore that value. -Not all implementations allow this, e.g., Solaris 2.7 does not. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_just.3x b/contrib/ncurses-5.4/man/form_field_just.3x deleted file mode 100644 index 61b62b88b9..0000000000 --- a/contrib/ncurses-5.4/man/form_field_just.3x +++ /dev/null @@ -1,78 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_just.3x,v 1.7 2003/05/10 20:33:49 jmc Exp $ -.TH form_field_just 3X "" -.SH NAME -\fBform_field_just\fR - retrieve field characteristics -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_just(FIELD *field, int justification); -.br -int field_just(const FIELD *field); -.br -.SH DESCRIPTION -The function \fBset_field_just\fR sets the justification attribute of -a field; \fBfield_just\fR returns a field's justification attribute. -The attribute may be one of NO_JUSTIFICATION, JUSTIFY_RIGHT, -JUSTIFY_LEFT, or JUSTIFY_CENTER. - -.SH RETURN VALUE -The function \fBfield_just\fR returns one of: NO_JUSTIFICATION, -JUSTIFY_RIGHT, JUSTIFY_LEFT, or JUSTIFY_CENTER. - -The function \fBset_field_just\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_new.3x b/contrib/ncurses-5.4/man/form_field_new.3x deleted file mode 100644 index a8174a5cad..0000000000 --- a/contrib/ncurses-5.4/man/form_field_new.3x +++ /dev/null @@ -1,96 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_new.3x,v 1.12 2003/05/10 20:33:49 jmc Exp $ -.TH form_field_new 3X "" -.SH NAME -\fBform_field_new\fR - create and destroy form fields -.SH SYNOPSIS -\fB#include \fR -.br -FIELD *new_field(int height, int width, - int toprow, int leftcol, - int offscreen, int nbuffers); -.br -FIELD *dup_field(FIELD *field, int toprow, int leftcol); -.br -FIELD *link_field(FIELD *field, int toprow, int leftcol); -.br -int free_field(FIELD *field); -.br -.SH DESCRIPTION -The function \fBnew_field\fR allocates a new field and initializes it from the -parameters given: height, width, row of upper-left corner, column of upper-left -corner, number off-screen rows, and number of additional working buffers. - -The function \fBdup_field\fR duplicates a field at a new location. Most -attributes (including current contents, size, validation type, buffer count, -growth threshold, justification, foreground, background, pad character, -options, and user pointer) are copied. Field status and the field page bit are -not copied. - -The function \fBlink_field\fR acts like \fBdup_field\fR, but the new field -shares buffers with its parent. Attribute data is separate. - -The function \fBfree_field\fR de-allocates storage associated with a field. -.SH RETURN VALUE -The function, \fBnew_field\fR, \fBdup_field\fR, \fBlink_field\fR return -\fBNULL\fR on error. - -The function \fBfree_field\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. - -It may be unwise to count on the set of attributes copied by -\fBdup_field\fR(3X) being portable; the System V forms library documents are -not very explicit about what gets copied and what doesn't. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_opts.3x b/contrib/ncurses-5.4/man/form_field_opts.3x deleted file mode 100644 index 8a3e501840..0000000000 --- a/contrib/ncurses-5.4/man/form_field_opts.3x +++ /dev/null @@ -1,120 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_opts.3x,v 1.8 2003/05/10 20:33:49 jmc Exp $ -.TH form_field_opts 3X "" -.SH NAME -\fBform_field_opts\fR - set and get field options -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_opts(FIELD *field, OPTIONS opts); -.br -int field_opts_on(FIELD *field, OPTIONS opts); -.br -int field_opts_off(FIELD *field, OPTIONS opts); -.br -OPTIONS field_opts(const FIELD *field); -.br -.SH DESCRIPTION -The function \fBset_field_opts\fR sets all the given field's option bits (field -option bits may be logically-OR'ed together). - -The function \fBfield_opts_on\fR turns on the given option bits, and leaves -others alone. - -The function \fBfield_opts_off\fR turns off the given option bits, and leaves -others alone. - -The function \fBfield_opts\fR returns the field's current option bits. - -The following options are defined (all are on by default): -.TP 5 -O_VISIBLE -The field is displayed. If this option is off, display of the field is -suppressed. -.TP 5 -O_ACTIVE -The field is visited during processing. If this option is off, the field will -not be reachable by navigation keys. Please notice that an invisible field -appears to be inactive also. -.TP 5 -O_PUBLIC -The field contents are displayed as data is entered. -.TP 5 -O_EDIT -The field can be edited. -.TP 5 -O_WRAP -Words that don't fit on a line are wrapped to the next line. Words are -blank-separated. -.TP 5 -O_BLANK -The field is cleared whenever a character is entered at the first position. -.TP 5 -O_AUTOSKIP -Skip to the next field when this one fills. -.TP 5 -O_NULLOK -Allow a blank field. -.TP 5 -O_STATIC -Field buffers are fixed to field's original size. -.TP 5 -O_PASSOK -Validate field only if modified by user. -.SH RETURN VALUE -Except for \fBfield_opts\fR, each routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_CURRENT\fR -The field is the current field. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.TP 5 -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_userptr.3x b/contrib/ncurses-5.4/man/form_field_userptr.3x deleted file mode 100644 index 2aba2083bc..0000000000 --- a/contrib/ncurses-5.4/man/form_field_userptr.3x +++ /dev/null @@ -1,73 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_userptr.3x,v 1.6 1998/11/29 01:07:05 Rick.Ohnemus Exp $ -.TH form_field_userptr 3X "" -.SH NAME -\fBform_field_userptr\fR - associate application data with a form field -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_userptr(FIELD *field, void*userptr); -.br -void *field_userptr(const FIELD *field); -.br -.SH DESCRIPTION -Every form field has a field that can be used to hold application-specific data -(that is, the form-driver code leaves it alone). These functions get and set -that field. -.SH RETURN VALUE -The function \fBfield_userptr\fR returns \fBNULL\fR on error. The function -\fBset_field_userptr\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. - -The user pointer should be a void pointer. We leave it as a char pointer for -SVr4 compatibility. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_field_validation.3x b/contrib/ncurses-5.4/man/form_field_validation.3x deleted file mode 100644 index c82abf3c10..0000000000 --- a/contrib/ncurses-5.4/man/form_field_validation.3x +++ /dev/null @@ -1,144 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_field_validation.3x,v 1.14 2003/05/10 20:33:49 jmc Exp $ -.TH form_field_validation 3X "" -.SH NAME -\fBform_field_validation\fR - data type validation for fields -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_type(FIELD *field, FIELDTYPE *type, ...); -.br -FIELDTYPE *field_type(const FIELD *field); -.br -void *field_arg(const FIELD *field); -.sp -FIELDTYPE *TYPE_ALNUM; -.br -FIELDTYPE *TYPE_ALPHA; -.br -FIELDTYPE *TYPE_ENUM; -.br -FIELDTYPE *TYPE_INTEGER; -.br -FIELDTYPE *TYPE_NUMERIC; -.br -FIELDTYPE *TYPE_REGEXP; -.br -FIELDTYPE *TYPE_IPV4; -.br -.SH DESCRIPTION -The function \fBset_field_type\fR declares a data type for a given form field. -This is the type checked by validation functions. -The predefined types are as follows: -.TP 5 -TYPE_ALNUM -Alphanumeric data. Requires a third \fBint\fR argument, a minimum field width. -.TP 5 -TYPE_ALPHA -Character data. Requires a third \fBint\fR argument, a minimum field width. -.TP 5 -TYPE_ENUM -Accept one of a specified set of strings. Requires a third \fB(char **)\fR -argument pointing to a string list; a fourth \fBint\fR flag argument to enable -case-sensitivity; and a fifth \fBint\fR flag argument specifying whether a partial -match must be a unique one (if this flag is off, a prefix matches the first -of any set of more than one list elements with that prefix). Please notice -that the string list is not copied, only a reference to it is stored in the -field. So you should avoid using a list that lives in automatic variables -on the stack. -.TP 5 -TYPE_INTEGER -Integer data, parsable to an integer by \fBatoi(3)\fR. Requires a third -\fBint\fR argument controlling the precision, a fourth \fBlong\fR argument -constraining minimum value, and a fifth \fBlong\fR constraining maximum value. -If the maximum value is less than or equal to the minimum value, the range is -simply ignored. On return the field buffer is formatted according to the -\fBprintf\fR format specification ".*ld", where the '*' is replaced by the -precision argument. -For details of the precision handling see \fBprintf's\fR man-page. -.TP 5 -TYPE_NUMERIC -Numeric data (may have a decimal-point part). Requires a third -\fBint\fR argument controlling the precision, a fourth \fBdouble\fR -argument constraining minimum value, and a fifth \fBdouble\fR constraining -maximum value. If your system supports locales, the decimal point character -to be used must be the one specified by your locale. -If the maximum value is less than or equal to the minimum value, the range is -simply ignored. On return the field buffer is formatted according to the -\fBprintf\fR format specification ".*f", where the '*' is replaced by the -precision argument. -For details of the precision handling see \fBprintf's\fR man-page. -.TP 5 -TYPE_REGEXP -Regular expression data. Requires a regular expression \fB(char *)\fR third argument; -the data is valid if the regular expression matches it. Regular expressions -are in the format of \fBregcomp\fR(3X) and \fBregexec\fR(3X). Please notice -that the regular expression must match the whole field. If you have for -example an eight character wide field, a regular expression "^[0-9]*$" always -means that you have to fill all eight positions with digits. If you want to -allow fewer digits, you may use for example "^[0-9]* *$" which is good for -trailing spaces (up to an empty field), or "^ *[0-9]* *$" which is good for -leading and trailing spaces around the digits. -.TP 5 -TYPE_IPV4 -An Internet Protocol Version 4 address. This requires no additional argument. It -is checked whether or not the buffer has the form a.b.c.d, where a,b,c and d are -numbers between 0 and 255. Trailing blanks in the buffer are ignored. The address -itself is not validated. Please note that this is an ncurses extension. This -field type may not be available in other curses implementations. -.PP -It is possible to set up new programmer-defined field types. See the -\fBform_fieldtype\fR(3X) manual page. -.SH RETURN VALUE -The functions \fBfield_type\fR and \fBfield_arg\fR return \fBNULL\fR on -error. The function \fBset_field_type\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_fieldtype.3x b/contrib/ncurses-5.4/man/form_fieldtype.3x deleted file mode 100644 index 979258a2ba..0000000000 --- a/contrib/ncurses-5.4/man/form_fieldtype.3x +++ /dev/null @@ -1,135 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_fieldtype.3x,v 1.12 2003/05/10 20:33:49 jmc Exp $ -.TH form_fieldtype 3X "" -.SH NAME -\fBform_fieldtype\fR - define validation-field types -.SH SYNOPSIS -\fB#include \fR -.br -FIELDTYPE *new_fieldtype( - bool (* const field_check)(FIELD *, const void *), - bool (* const char_check)(int, const void *)); -.br -int free_fieldtype(FIELDTYPE *fieldtype); -.br -int set_fieldtype_arg( - FIELDTYPE *fieldtype, - void *(* const make_arg)(va_list *), - void *(* const copy_arg)(const void *), - void (* const free_arg)(void *)); -.br -int set_fieldtype_choice( - FIELDTYPE *fieldtype, - bool (* const next_choice)(FIELD *, const void *), - bool (* const prev_choice)(FIELD *, const void *)); -.br -FIELDTYPE *link_fieldtype(FIELDTYPE *type1, - FIELDTYPE *type2); -.br -.SH DESCRIPTION -The function \fBnew_fieldtype\fR creates a new field type usable for data -validation. You supply it with \fIfield_check\fR, a predicate to check the -validity of an entered data string whenever the user attempts to leave a field. -The (FIELD *) argument is passed in so the validation predicate can see the -field's buffer, sizes and other attributes; the second argument is an -argument-block structure, about which more below. - -You also supply \fBnew_fieldtype\fR with \fIchar_check\fR, -a function to validate input characters as they are entered; it will be passed -the character to be checked and a pointer to an argument-block structure. - -The function \fBfree_fieldtype\fR frees the space allocated for a given -validation type. - -The function \fBset_fieldtype_arg\fR associates three storage-management functions -with a field type. -The \fImake_arg\fR function is automatically applied to the -list of arguments you give \fBset_field_type\fR when attaching validation -to a field; its job is to bundle these into an allocated argument-block -object which can later be passed to validation predicated. -The other two hook arguments should copy and free argument-block structures. -They will be used by the forms-driver code. -You must supply the \fImake_arg\fR function, -the other two are optional, you may supply NULL for them. -In this case it is assumed -that \fImake_arg\fR does not allocate memory but simply loads the -argument into a single scalar value. - -The function \fBlink_fieldtype\fR creates -a new field type from the two given types. -They are connected by an logical 'OR'. - -The form driver requests \fBREQ_NEXT_CHOICE\fR and \fBREQ_PREV_CHOICE\fR assume -that the possible values of a field form an ordered set, and provide the forms -user with a way to move through the set. -The \fBset_fieldtype_choice\fR -function allows forms programmers to define successor and predecessor functions -for the field type. -These functions take the field pointer and an -argument-block structure as arguments. -.SH RETURN VALUE -The pointer-valued routines return NULL on error. - -The integer-valued routines return one of the following codes on -error: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_CONNECTED\fR -The field is already connected to a form. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. - -All of the \fB(char *)\fR arguments of these functions should actually be -\fB(void *)\fR. The type has been left uncorrected for strict compatibility -with System V. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_hook.3x b/contrib/ncurses-5.4/man/form_hook.3x deleted file mode 100644 index 19c1b9fbd7..0000000000 --- a/contrib/ncurses-5.4/man/form_hook.3x +++ /dev/null @@ -1,100 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_hook.3x,v 1.6 1999/03/20 22:37:15 Todd.Miller Exp $ -.TH form_hook 3X "" -.SH NAME -\fBform_hook\fR - set hooks for automatic invocation by applications -.SH SYNOPSIS -\fB#include \fR -.br -int set_field_init(FORM *form, void (*func)(FORM *)); -.br -void (*)(FORM *) field_init(const FORM *form); -.br -int set_field_term(FORM *form, void (*func)(FORM *)); -.br -void (*)(FORM *) field_term(const FORM *form); -.br -int set_form_init(FORM *form, void (*func)(FORM *)); -.br -void (*)(FORM *) form_init(const FORM *form); -.br -int set_form_term(FORM *form, void (*func)(FORM *)); -.br -void (*)(FORM *) form_term(const FORM *form); -.br -.SH DESCRIPTION -These functions make it possible to set hook functions to be called at various -points in the automatic processing of input event codes by \fBform_driver\fR. - -The function \fBset_field_init\fR sets a hook to be called at form-post time -and each time the selected field changes (after the change). \fBfield_init\fR -returns the current field init hook, if any (\fBNULL\fR if there is no such -hook). - -The function \fBset_field_term\fR sets a hook to be called at form-unpost time -and each time the selected field changes (before the change). \fBfield_term\fR -returns the current field term hook, if any (\fBNULL\fR if there is no such -hook). - -The function \fBset_form_init\fR sets a hook to be called at form-post time and -just after a page change once it is posted. \fBform_init\fR returns the -current form init hook, if any (\fBNULL\fR if there is no such hook). - -The function \fBset_form_term\fR sets a hook to be called at form-unpost time -and just before a page change once it is posted. \fBform_init\fR -returns the current form term hook, if any (\fBNULL\fR if there is no such -hook). -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Other routines -return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_new.3x b/contrib/ncurses-5.4/man/form_new.3x deleted file mode 100644 index 0f4c5015d1..0000000000 --- a/contrib/ncurses-5.4/man/form_new.3x +++ /dev/null @@ -1,79 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_new.3x,v 1.5 1998/11/29 01:07:37 Rick.Ohnemus Exp $ -.TH form_new 3X "" -.SH NAME -\fBform_new\fR - create and destroy forms -.SH SYNOPSIS -\fB#include \fR -.br -FORM *new_form(FIELD **fields); -.br -int free_form(FORM *form); -.br -.SH DESCRIPTION -The function \fBnew_form\fR creates a new form connected to a specified field -pointer array (which must be \fBNULL\fR-terminated). - -The function \fBfree_form\fR disconnects \fIform\fR from its field array -and frees the storage allocated for the form. -.SH RETURN VALUE -The function \fBnew_form\fR returns \fBNULL\fR on error. - -The function \fBfree_form\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The form has already been posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_new_page.3x b/contrib/ncurses-5.4/man/form_new_page.3x deleted file mode 100644 index 432f624f52..0000000000 --- a/contrib/ncurses-5.4/man/form_new_page.3x +++ /dev/null @@ -1,77 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_new_page.3x,v 1.6 2002/01/19 22:48:51 tom Exp $ -.TH form_new_page 3X "" -.SH NAME -\fBform_new_page\fR - form pagination functions -.SH SYNOPSIS -\fB#include \fR -.br -int set_new_page(FIELD *field, bool new_page_flag); -.br -bool new_page(const FIELD *field); -.br -.SH DESCRIPTION -The function \fBset_new_page\fR sets or resets a flag marking the given field -as the beginning of a new page on its form. - -The function \fBnew_page\fR is a predicate which tests if a given field marks -a page beginning on its form. -.SH RETURN VALUE -The function \fBnew_page\fR returns \fBTRUE\fR or \fBFALSE\fR. - -The function \fBset_new_page\fR return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_CONNECTED\fR -The given field is already connected to a form. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_opts.3x b/contrib/ncurses-5.4/man/form_opts.3x deleted file mode 100644 index 7921b37725..0000000000 --- a/contrib/ncurses-5.4/man/form_opts.3x +++ /dev/null @@ -1,90 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_opts.3x,v 1.6 1998/11/29 01:07:53 Rick.Ohnemus Exp $ -.TH form_opts 3X "" -.SH NAME -\fBform_opts\fR - set and get form options -.SH SYNOPSIS -\fB#include \fR -.br -int set_form_opts(FORM *form, OPTIONS opts); -.br -int form_opts_on(FORM *form, OPTIONS opts); -.br -int form_opts_off(FORM *form, OPTIONS opts); -.br -OPTIONS form_opts(const FORM *form); -.br -.SH DESCRIPTION -The function \fBset_form_opts\fR sets all the given form's option bits (form -option bits may be logically-OR'ed together). - -The function \fBform_opts_on\fR turns on the given option bits, and leaves -others alone. - -The function \fBform_opts_off\fR turns off the given option bits, and leaves -others alone. - -The function \fBform_opts\fR returns the form's current option bits. - -The following options are defined (all are on by default): -.TP 5 -O_NL_OVERLOAD -Overload the \fBREQ_NEW_LINE\fR forms driver request so that calling it at the -end of a field goes to the next field. -.TP 5 -O_BS_OVERLOAD -Overload the \fBREQ_DEL_PREV\fR forms driver request so that calling it at the -beginning of a field goes to the previous field. -.SH RETURN VALUE -Except for \fBform_opts\fR, each routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_page.3x b/contrib/ncurses-5.4/man/form_page.3x deleted file mode 100644 index 4b5d15aec1..0000000000 --- a/contrib/ncurses-5.4/man/form_page.3x +++ /dev/null @@ -1,95 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_page.3x,v 1.8 1998/11/29 01:08:02 Rick.Ohnemus Exp $ -.TH form_page 3X "" -.SH NAME -\fBform_page\fR - set and get form page number -.SH SYNOPSIS -\fB#include \fR -.br -int set_current_field(FORM *form, FIELD *field); -.br -FIELD *current_field(const FORM *); -.br -int set_form_page(FORM *form, int n); -.br -int form_page(const FORM *form); -.br -int field_index(const FIELD *field); -.br -.SH DESCRIPTION -The function \fBset_current field\fR sets the current field of the given -form; \fBcurrent_field\fR returns the current field of the given form. -.PP -The function \fBset_form_page\fR sets the form's page number (goes to page -\fIn\fR of the form). -.PP -The function \fBform_page\fR returns the form's current page number. -.PP -The function \fBfield_index\fR returns the index of the field in the -field array of the form it is connected to. It returns \fBERR\fR if -the argument is the null pointer or the field is not connected. -.SH RETURN VALUE -Except for \fBform_page\fR, each routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_INVALID_FIELD\fR -Contents of a field are not valid. -.TP 5 -\fBE_REQUEST_DENIED\fR -The form driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_post.3x b/contrib/ncurses-5.4/man/form_post.3x deleted file mode 100644 index 56e86ab946..0000000000 --- a/contrib/ncurses-5.4/man/form_post.3x +++ /dev/null @@ -1,90 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_post.3x,v 1.4 1998/11/29 01:08:10 Rick.Ohnemus Exp $ -.TH form_post 3X "" -.SH NAME -\fBform_post\fR - write or erase forms from associated subwindows -.SH SYNOPSIS -\fB#include \fR -.br -int post_form(FORM *form); -.br -int unpost_form(FORM *form); -.br -.SH DESCRIPTION -The function \fBpost_form\fR displays a form to its associated subwindow. To -trigger physical display of the subwindow, use \fBrefresh\fR or some equivalent -\fBcurses\fR routine (the implicit \fBdoupdate\fR triggered by an \fBcurses\fR -input request will do). - -The function \fBunpost_form\fR erases form from its associated subwindow. -.SH RETURN VALUE -These routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The form has already been posted. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NO_ROOM\fR -Form is too large for its window. -.TP 5 -\fBE_NOT_POSTED\fR -The form has not been posted. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the form. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_requestname.3x b/contrib/ncurses-5.4/man/form_requestname.3x deleted file mode 100644 index df1f701b38..0000000000 --- a/contrib/ncurses-5.4/man/form_requestname.3x +++ /dev/null @@ -1,69 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_requestname.3x,v 1.6 1998/11/29 01:08:18 Rick.Ohnemus Exp $ -.TH form_requestname 3X "" -.SH NAME -\fBform_requestname\fR - handle printable form request names -.SH SYNOPSIS -\fB#include \fR -.br -const char *form_request_name(int request); -.br -int form_request_by_name(const char *name); -.br -.SH DESCRIPTION -The function \fBform_request_name\fR returns the printable name of a form -request code. -.br -The function \fBform_request_by_name\fR searches in the name-table for a request -with the given name and returns its request code. Otherwise E_NO_MATCH is returned. -.SH RETURN VALUE -\fBform_request_name\fR returns \fBNULL\fR on error and sets errno -to \fBE_BAD_ARGUMENT\fR. -.br -\fBform_request_by_name\fR returns \fBE_NO_MATCH\fR on error. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_userptr.3x b/contrib/ncurses-5.4/man/form_userptr.3x deleted file mode 100644 index 00e3d71aa4..0000000000 --- a/contrib/ncurses-5.4/man/form_userptr.3x +++ /dev/null @@ -1,73 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_userptr.3x,v 1.9 1998/11/29 01:08:39 Rick.Ohnemus Exp $ -.TH form_userptr 3X "" -.SH NAME -\fBform_userptr\fR - associate application data with a form item -.SH SYNOPSIS -\fB#include \fR -.br -int set_form_userptr(FORM *form, void *userptr); -.br -void* form_userptr(const FORM *form); -.br -.SH DESCRIPTION -Every form and every form item has a field that can be used to hold -application-specific data (that is, the form-driver code leaves it alone). -These functions get and set the form user pointer field. -.SH RETURN VALUE -The function \fBform_userptr\fR returns \fBNULL\fR on error. -The function \fBset_form_userptr\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. - -The user pointer should be a void pointer. We leave it as a char pointer for -SVr4 compatibility. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/form_win.3x b/contrib/ncurses-5.4/man/form_win.3x deleted file mode 100644 index e565970288..0000000000 --- a/contrib/ncurses-5.4/man/form_win.3x +++ /dev/null @@ -1,95 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: form_win.3x,v 1.8 1999/04/10 23:36:08 tom Exp $ -.TH form_win 3X "" -.SH NAME -\fBform_win\fR - make and break form window and subwindow associations -.SH SYNOPSIS -\fB#include \fR -.br -int set_form_win(FORM *form, WINDOW *win); -.br -WINDOW *form_win(const FORM *form); -.br -int set_form_sub(FORM *form, WINDOW *sub); -.br -WINDOW *form_sub(const FORM *form); -.br -int scale_form(const FORM *form, int *rows, int *columns); -.br -.SH DESCRIPTION -Every form has an associated pair of \fBcurses\fR windows. The form window -displays any title and border associated with the window; the form subwindow -displays the items of the form that are currently available for selection. - -The first four functions get and set those windows. It is not necessary to set -either window; by default, the driver code uses \fBstdscr\fR for both. - -In the \fBset_\fR functions, window argument of \fBNULL\fR is treated as though -it were \fBstsdcr\fR. A form argument of \fBNULL\fR is treated as a request -to change the system default form window or subwindow. - -The function \fBscale_form\fR returns the minimum size required for the -subwindow of \fIform\fR. -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Routines that return -an integer return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The form has already been posted. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the form. -.SH SEE ALSO -\fBcurses\fR(3X), \fBform\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V forms library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/infocmp.1m b/contrib/ncurses-5.4/man/infocmp.1m deleted file mode 100644 index fe95d6f89c..0000000000 --- a/contrib/ncurses-5.4/man/infocmp.1m +++ /dev/null @@ -1,410 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: infocmp.1m,v 1.34 2003/10/25 16:19:01 tom Exp $ -.TH infocmp 1M "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBinfocmp\fR - compare or print out \fIterminfo\fR descriptions -.SH SYNOPSIS -\fBinfocmp\fR [\fB\-\ -1\ -C\ -E\ -F\ -G\ -I\ -L\ -T\ -V\ -c\ -d\ -e\ -g\ -i\ -l\ -n\ -p\ -q\ -r\ -t\ -u\ -\fR] -.br - [\fB\-v\fR \fIn\fR] [\fB\-s d\fR| \fBi\fR| \fBl\fR| \fBc\fR] [\fB\-R \fR\fBsubset\fR] -.br - [\fB\-w\fR\ \fIwidth\fR] [\fB\-A\fR\ \fIdirectory\fR] [\fB\-B\fR\ \fIdirectory\fR] -.br - [\fItermname\fR...] -.SH DESCRIPTION -\fBinfocmp\fR can be used to compare a binary \fBterminfo\fR entry with other -terminfo entries, rewrite a \fBterminfo\fR description to take advantage of the -\fBuse=\fR terminfo field, or print out a \fBterminfo\fR description from the -binary file (\fBterm\fR) in a variety of formats. In all cases, the boolean -fields will be printed first, followed by the numeric fields, followed by the -string fields. -.SS Default Options -If no options are specified and zero or one \fItermnames\fR are specified, the -\fB\-I\fR option will be assumed. If more than one \fItermname\fR is specified, -the \fB\-d\fR option will be assumed. -.SS Comparison Options [\-d] [\-c] [\-n] -\fBinfocmp\fR compares the \fBterminfo\fR description of the first terminal -\fItermname\fR with each of the descriptions given by the entries for the other -terminal's \fItermnames\fR. If a capability is defined for only one of the -terminals, the value returned will depend on the type of the capability: -\fBF\fR for boolean variables, \fB-1\fR for integer variables, and \fBNULL\fR -for string variables. - -The \fB\-d\fR option produces a list of each capability that is different -between two entries. This option is useful to show the difference between two -entries, created by different people, for the same or similar terminals. - -The \fB\-c\fR option produces a list of each capability that is common between -two entries. Capabilities that are not set are ignored. This option can be -used as a quick check to see if the \fB\-u\fR option is worth using. - -The \fB\-n\fR option produces a list of each capability that is in neither -entry. If no \fItermnames\fR are given, the environment variable \fBTERM\fR -will be used for both of the \fItermnames\fR. This can be used as a quick -check to see if anything was left out of a description. -.SS Source Listing Options [\-I] [\-L] [\-C] [\-r] -The \fB\-I\fR, \fB\-L\fR, and \fB\-C\fR options will produce a source listing for -each terminal named. - -.TS -center tab(/) ; -l l . -\fB\-I\fR/use the \fBterminfo\fR names -\fB\-L\fR/use the long C variable name listed in <\fBterm.h\fR> -\fB\-C\fR/use the \fBtermcap\fR names -\fB\-r\fR/when using \fB\-C\fR, put out all capabilities in \fBtermcap\fR form -.TE - -If no \fItermnames\fR are given, the environment variable \fBTERM\fR will be -used for the terminal name. - -The source produced by the \fB\-C\fR option may be used directly as a -\fBtermcap\fR entry, but not all parameterized strings can be changed to -the \fBtermcap\fR format. \fBinfocmp\fR will attempt to convert most of the -parameterized information, and anything not converted will be plainly marked in -the output and commented out. These should be edited by hand. - -All padding information for strings will be collected together and placed -at the beginning of the string where \fBtermcap\fR expects it. Mandatory -padding (padding information with a trailing '/') will become optional. - -All \fBtermcap\fR variables no longer supported by \fBterminfo\fR, but which -are derivable from other \fBterminfo\fR variables, will be output. Not all -\fBterminfo\fR capabilities will be translated; only those variables which were -part of \fBtermcap\fR will normally be output. Specifying the \fB\-r\fR option -will take off this restriction, allowing all capabilities to be output in -\fItermcap\fR form. - -Note that because padding is collected to the beginning of the capability, not -all capabilities are output. Mandatory padding is not supported. Because -\fBtermcap\fR strings are not as flexible, it is not always possible to convert -a \fBterminfo\fR string capability into an equivalent \fBtermcap\fR format. A -subsequent conversion of the \fBtermcap\fR file back into \fBterminfo\fR format -will not necessarily reproduce the original \fBterminfo\fR -source. - -Some common \fBterminfo\fR parameter sequences, their \fBtermcap\fR -equivalents, and some terminal types which commonly have such sequences, are: - -.TS -center tab(/) ; -l c l -l l l. -\fBterminfo/termcap\fR/Representative Terminals -= -\fB%p1%c/%.\fR/adm -\fB%p1%d/%d\fR/hp, ANSI standard, vt100 -\fB%p1%'x'%+%c/%+x\fR/concept -\fB%i/%i\fRq/ANSI standard, vt100 -\fB%p1%?%'x'%>%t%p1%'y'%+%;/%>xy\fR/concept -\fB%p2\fR is printed before \fB%p1/%r\fR/hp -.TE -.SS Use= Option [\-u] -The \fB\-u\fR option produces a \fBterminfo\fR source description of the first -terminal \fItermname\fR which is relative to the sum of the descriptions given -by the entries for the other terminals \fItermnames\fR. It does this by -analyzing the differences between the first \fItermname\fR and the other -\fItermnames\fR and producing a description with \fBuse=\fR fields for the -other terminals. In this manner, it is possible to retrofit generic terminfo -entries into a terminal's description. Or, if two similar terminals exist, but -were coded at different times or by different people so that each description -is a full description, using \fBinfocmp\fR will show what can be done to change -one description to be relative to the other. - -A capability will get printed with an at-sign (@) if it no longer exists in the -first \fItermname\fR, but one of the other \fItermname\fR entries contains a -value for it. A capability's value gets printed if the value in the first -\fItermname\fR is not found in any of the other \fItermname\fR entries, or if -the first of the other \fItermname\fR entries that has this capability gives a -different value for the capability than that in the first \fItermname\fR. - -The order of the other \fItermname\fR entries is significant. Since the -terminfo compiler \fBtic\fR does a left-to-right scan of the capabilities, -specifying two \fBuse=\fR entries that contain differing entries for the same -capabilities will produce different results depending on the order that the -entries are given in. \fBinfocmp\fR will flag any such inconsistencies between -the other \fItermname\fR entries as they are found. - -Alternatively, specifying a capability \fIafter\fR a \fBuse=\fR entry that -contains that capability will cause the second specification to be ignored. -Using \fBinfocmp\fR to recreate a description can be a useful check to make -sure that everything was specified correctly in the original source -description. - -Another error that does not cause incorrect compiled files, but will slow down -the compilation time, is specifying extra \fBuse=\fR fields that are -superfluous. \fBinfocmp\fR will flag any other \fItermname use=\fR fields that -were not needed. -.SS Changing Databases [\-A \fIdirectory\fR] [\-B \fIdirectory\fR] -The location of the compiled \fBterminfo\fR database is taken from the -environment variable \fBTERMINFO\fR . If the variable is not defined, or the -terminal is not found in that location, the system \fBterminfo\fR database, -in \fB@TERMINFO@\fR, will be used. The options \fB\-A\fR -and \fB\-B\fR may be used to override this location. The \fB\-A\fR option will -set \fBTERMINFO\fR for the first \fItermname\fR and the \fB\-B\fR option will -set \fBTERMINFO\fR for the other \fItermnames\fR. With this, it is possible to -compare descriptions for a terminal with the same name located in two different -databases. This is useful for comparing descriptions for the same terminal -created by different people. -.SS Other Options -.TP 5 -\fB\-1\fR -causes the fields to be printed out one to a line. Otherwise, -the fields will be printed several to a line to a maximum width -of 60 characters. -.TP -\fB\-a\fR -tells \fBinfocmp\fP to retain commented-out capabilities rather than discarding -them. Capabilities are commented by prefixing them with a period. -.TP 5 -\fB\-E\fR -Dump the capabilities of the given terminal as tables, needed in -the C initializer for a -TERMTYPE structure (the terminal capability structure in the \fB\fR). -This option is useful for preparing versions of the curses library hardwired -for a given terminal type. -The tables are all declared static, and are named according to the type -and the name of the corresponding terminal entry. -.sp -Before ncurses 5.0, the split between the \fB\-e\fP and \fB\-E\fP -options was not needed; but support for extended names required making -the arrays of terminal capabilities separate from the TERMTYPE structure. -.TP 5 -\fB\-e\fR -Dump the capabilities of the given terminal as a C initializer for a -TERMTYPE structure (the terminal capability structure in the \fB\fR). -This option is useful for preparing versions of the curses library hardwired -for a given terminal type. -.TP 5 -\fB\-F\fR -compare terminfo files. This assumes that two following arguments are -filenames. The files are searched for pairwise matches between -entries, with two entries considered to match if any of their names do. -The report printed to standard output lists entries with no matches in -the other file, and entries with more than one match. For entries -with exactly one match it includes a difference report. Normally, -to reduce the volume of the report, use references are -not resolved before looking for differences, but resolution can be forced -by also specifying \fB\-r\fR. -.TP 5 -\fB\-f\fR -Display complex terminfo strings which contain if/then/else/endif expressions -indented for readability. -.TP 5 -\fB\-G\fR -Display constant literals in decimal form -rather than their character equivalents. -.TP 5 -\fB\-g\fR -Display constant character literals in quoted form -rather than their decimal equivalents. -.TP 5 -\fB\-i\fR -Analyze the initialization (\fBis1\fR, \fBis2\fR, \fBis3\fR), and reset -(\fBrs1\fR, \fBrs2\fR, \fBrs3\fR), strings in the entry. For each string, the -code tries to analyze it into actions in terms of the other capabilities in the -entry, certain X3.64/ISO 6429/ECMA-48 capabilities, and certain DEC VT-series -private modes (the set of recognized special sequences has been selected for -completeness over the existing terminfo database). Each report line consists -of the capability name, followed by a colon and space, followed by a printable -expansion of the capability string with sections matching recognized actions -translated into {}-bracketed descriptions. Here is a list of the DEC/ANSI -special sequences recognized: - -.TS -center tab(/) ; -l l -l l. -Action/Meaning -= -RIS/full reset -SC/save cursor -RC/restore cursor -LL/home-down -RSR/reset scroll region - -ISO DEC G0/enable DEC graphics for G0 -ISO UK G0/enable UK chars for G0 -ISO US G0/enable US chars for G0 -ISO DEC G1/enable DEC graphics for G1 -ISO UK G1/enable UK chars for G1 -ISO US G1/enable US chars for G1 - -DECPAM/application keypad mode -DECPNM/normal keypad mode -DECANSI/enter ANSI mode - -DEC[+-]CKM/application cursor keys -DEC[+-]ANM/set VT52 mode -DEC[+-]COLM/132-column mode -DEC[+-]SCLM/smooth scroll -DEC[+-]SCNM/reverse video mode -DEC[+-]OM/origin mode -DEC[+-]AWM/wraparound mode -DEC[+-]ARM/auto-repeat mode -.TE -.sp -It also recognizes a SGR action corresponding to ANSI/ISO 6429/ECMA Set -Graphics Rendition, with the values NORMAL, BOLD, UNDERLINE, BLINK, and -REVERSE. All but NORMAL may be prefixed with `+' (turn on) or `-' (turn off). - -An SGR0 designates an empty highlight sequence (equivalent to {SGR:NORMAL}). -.TP 5 -\fB\-l\fR -Set output format to terminfo. -.TP 5 -\fB\-p\fR -Ignore padding specifications when comparing strings. -.TP 5 -\fB\-q\fR -Make the comparison listing shorter by omitting subheadings, and using -"-" for absent capabilities, "@" for canceled rather than "NULL". -.TP 5 -\fB\-R\fR\fIsubset\fR -Restrict output to a given subset. This option is for use with archaic -versions of terminfo like those on SVr1, Ultrix, or HP/UX that do not support -the full set of SVR4/XSI Curses terminfo; and variants such as AIX -that have their own extensions incompatible with SVr4/XSI. Available terminfo -subsets are "SVr1", "Ultrix", "HP", and "AIX"; see \fBterminfo\fR(\*n) for -details. You can also choose the subset "BSD" which selects only capabilities -with termcap equivalents recognized by 4.4BSD. -.TP -\fB\-s \fR\fI[d|i|l|c]\fR -The \fB\-s\fR option sorts the fields within each type according to the argument -below: -.br -.RS 5 -.TP 5 -\fBd\fR -leave fields in the order that they are stored in the \fIterminfo\fR database. -.TP 5 -\fBi\fR -sort by \fIterminfo\fR name. -.TP 5 -\fBl\fR -sort by the long C variable name. -.TP 5 -\fBc\fR -sort by the \fItermcap\fR name. -.RE -.IP -If the \fB\-s\fR option is not given, the fields printed out will be -sorted alphabetically by the \fBterminfo\fR name within each type, -except in the case of the \fB\-C\fR or the \fB\-L\fR options, which cause the -sorting to be done by the \fBtermcap\fR name or the long C variable -name, respectively. -.TP 5 -\fB\-T\fR -eliminates size-restrictions on the generated text. -This is mainly useful for testing and analysis, since the compiled -descriptions are limited (e.g., 1023 for termcap, 4096 for terminfo). -.TP -\fB\-t\fR -tells \fBtic\fP to discard commented-out capabilities. -Normally when translating from terminfo to termcap, -untranslatable capabilities are commented-out. -.TP 5 -\fB\-V\fR -reports the version of ncurses which was used in this program, and exits. -.TP 5 -\fB\-v\fR \fIn\fR -prints out tracing information on standard error as the program runs. -Higher values of n induce greater verbosity. -.TP 5 -\fB\-w\fR \fIwidth\fR -changes the output to \fIwidth\fR characters. -.SH FILES -.TP 20 -\*d -Compiled terminal description database. -.SH EXTENSIONS -The -\fB\-E\fR, -\fB\-F\fR, -\fB\-G\fR, -\fB\-R\fR, -\fB\-T\fR, -\fB\-V\fR, -\fB\-a\fR, -\fB\-e\fR, -\fB\-f\fR, -\fB\-g\fR, -\fB\-i\fR, -\fB\-l\fR, -\fB\-p\fR, -\fB\-q\fR and -\fB\-t\fR -options are not supported in SVr4 curses. - -The \fB\-r\fR option's notion of `termcap' capabilities is System V Release 4's. -Actual BSD curses versions will have a more restricted set. To see only the -4.4BSD set, use \fB\-r\fR \fB\-RBSD\fR. -.SH BUGS -The \fB\-F\fR option of \fBinfocmp\fR(1M) should be a \fBtoe\fR(1M) mode. -.SH SEE ALSO -\fBinfocmp\fR(1M), \fBcaptoinfo\fR(1M), \fBinfotocap\fR(1M), -\fBtic\fR(1M), \fBtoe\fR(1M), -\fBcurses\fR(3X), \fBterminfo\fR(\*n). -.SH AUTHOR -Eric S. Raymond -and -.br -Thomas E. Dickey -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/infotocap.1m b/contrib/ncurses-5.4/man/infotocap.1m deleted file mode 100644 index f18458426a..0000000000 --- a/contrib/ncurses-5.4/man/infotocap.1m +++ /dev/null @@ -1,74 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1999-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: infotocap.1m,v 1.4 2003/05/11 00:32:53 tom Exp $ -.TH infotocap 1M "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBinfotocap\fR - convert a \fIterminfo\fR description into a \fItermcap\fR description -.SH SYNOPSIS -\fBinfotocap\fR [\fB\-v\fR\fIn\fR \fIwidth\fR] [\fB\-V\fR] [\fB\-1\fR] [\fB\-w\fR \fIwidth\fR] \fIfile\fR . . . -.SH DESCRIPTION -\fBinfotocap\fR looks in \fIfile\fR for \fBterminfo\fR descriptions. For each -one found, an equivalent \fBtermcap\fR description is written to standard -output. Terminfo \fBuse\fR capabilities are translated directly to termcap -\fBtc\fR capabilities. -.TP 5 -\fB\-v\fR -print out tracing information on standard error as the program runs. -.TP 5 -\fB\-V\fR -print out the version of the program in use on standard error and exit. -.TP 5 -\fB\-1\fR -cause the fields to print out one to a line. Otherwise, the fields -will be printed several to a line to a maximum width of 60 -characters. -.TP 5 -\fB\-w\fR -change the output to \fIwidth\fR characters. -.SH FILES -.TP 20 -\*d -Compiled terminal description database. -.SH NOTES -This utility is actually a link to \fItic\fR(1M), running in \fI\-C\fR mode. -You can use other \fItic\fR options such as \fB\-f\fR and \fB\-x\fR. -.SH SEE ALSO -\fBcurses\fR(3X), -\fBtic\fR(1M), -\fBinfocmp\fR(1M), -\fBterminfo\fR(\*n) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/key_defined.3x b/contrib/ncurses-5.4/man/key_defined.3x deleted file mode 100644 index 574e524c27..0000000000 --- a/contrib/ncurses-5.4/man/key_defined.3x +++ /dev/null @@ -1,60 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 2003 -.\" -.\" $Id: key_defined.3x,v 1.2 2003/05/17 23:24:45 tom Exp $ -.TH key_defined 3X "" -.SH NAME -\fBdefine_key\fP \- define a keycode -.SH SYNOPSIS -\fB#include \fP - -\fBint key_defined(const char *definition);\fP -.SH DESCRIPTION -This is an extension to the curses library. -It permits an application to determine if a string is currently bound -to any keycode. -.SH RETURN VALUE -If the string is bound to a keycode, its value (greater than zero) is returned. -If no keycode is bound, zero is returned. -If the string conflicts with longer strings which are bound to keys, -1 is returned. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBdefine_key\fR(3X). -.SH AUTHOR -Thomas Dickey. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/keybound.3x b/contrib/ncurses-5.4/man/keybound.3x deleted file mode 100644 index 61074e436f..0000000000 --- a/contrib/ncurses-5.4/man/keybound.3x +++ /dev/null @@ -1,64 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1999-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1999 -.\" -.\" $Id: keybound.3x,v 1.5 2003/10/25 20:33:16 tom Exp $ -.TH keyok 3X "" -.SH NAME -\fBkeybound\fP \- return definition of keycode -.SH SYNOPSIS -\fB#include \fP - -\fBchar * keybound(int keycode, int count);\fP -.SH DESCRIPTION -This is an extension to the curses library. -It permits an application to determine the string which is defined -in the terminfo for specific keycodes. -.SH RETURN VALUE -The \fIkeycode\fP parameter must be greater than zero, else NULL is returned. -If it does not correspond to a defined key, then NULL is returned. -The \fIcount\fP parameter is used to allow the application to iterate -through multiple definitions, counting from zero. -When successful, -the function returns a string which must be freed by the caller. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBdefine_key\fR(3X), -\fBkeyok\fR(3X). -.SH AUTHOR -Thomas Dickey. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/keyok.3x b/contrib/ncurses-5.4/man/keyok.3x deleted file mode 100644 index f9209089a7..0000000000 --- a/contrib/ncurses-5.4/man/keyok.3x +++ /dev/null @@ -1,63 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1997 -.\" -.\" $Id: keyok.3x,v 1.8 2003/10/25 20:41:08 tom Exp $ -.TH keyok 3X "" -.SH NAME -\fBkeyok\fP \- enable or disable a keycode -.SH SYNOPSIS -\fB#include \fP - -\fBint keyok(int keycode, bool enable);\fP -.SH DESCRIPTION -This is an extension to the curses library. -It permits an application to disable specific keycodes, rather than -use the \fIkeypad\fP function to disable all keycodes. -Keys that have been disabled can be reenabled. -.SH RETURN VALUE -The keycode must be greater than zero, else ERR is returned. -If it does not correspond to a defined key, then ERR is returned. -If the \fIenable\fP parameter is true, then the key must have been disabled, -and vice versa. -Otherwise, the function returns OK. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH SEE ALSO -\fBdefine_key\fR(3X). -.SH AUTHOR -Thomas Dickey. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/make_sed.sh b/contrib/ncurses-5.4/man/make_sed.sh deleted file mode 100644 index 766801d551..0000000000 --- a/contrib/ncurses-5.4/man/make_sed.sh +++ /dev/null @@ -1,83 +0,0 @@ -#!/bin/sh -# $Id: make_sed.sh,v 1.7 2003/10/25 20:33:16 tom Exp $ -############################################################################## -# Copyright (c) 1998,2003 Free Software Foundation, Inc. # -# # -# Permission is hereby granted, free of charge, to any person obtaining a # -# copy of this software and associated documentation files (the "Software"), # -# to deal in the Software without restriction, including without limitation # -# the rights to use, copy, modify, merge, publish, distribute, distribute # -# with modifications, sublicense, and/or sell copies of the Software, and to # -# permit persons to whom the Software is furnished to do so, subject to the # -# following conditions: # -# # -# The above copyright notice and this permission notice shall be included in # -# all copies or substantial portions of the Software. # -# # -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL # -# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING # -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # -# DEALINGS IN THE SOFTWARE. # -# # -# Except as contained in this notice, the name(s) of the above copyright # -# holders shall not be used in advertising or otherwise to promote the sale, # -# use or other dealings in this Software without prior written # -# authorization. # -############################################################################## -# -# Author: Thomas E. Dickey 1997 -# -# Construct a sed-script to perform renaming within man-pages. Originally -# written in much simpler form, this one accounts for the common cases of -# section-names in man-pages. - -if test $# != 1 ; then - echo '? expected a single filename' - exit 1 -fi - -COL=col$$ -INPUT=input$$ -UPPER=upper$$ -SCRIPT=script$$ -RESULT=result$$ -rm -f $UPPER $SCRIPT $RESULT -trap "rm -f $COL.* $INPUT $UPPER $SCRIPT $RESULT" 0 1 2 5 15 -fgrep -v \# $1 | \ -sed -e 's/[ ][ ]*/ /g' >$INPUT - -for F in 1 2 3 4 -do -sed -e 's/\./ /g' $INPUT | \ -cut -f $F > $COL.$F -done -for F in 2 4 -do - tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ <$COL.$F >$UPPER - mv $UPPER $COL.$F -done -paste $COL.* | \ -sed -e 's/^/s\/\\$UPPER - -# Do the TH lines -sed -e 's/\//\/TH /' \ - -e 's/ / /' \ - -e 's/ / ""\/TH /' \ - -e 's/ / /' \ - -e 's/\/$/ ""\//' \ - $UPPER >>$RESULT - -# Do the embedded references -sed -e 's/>$RESULT - -# Finally, send the result to standard output -cat $RESULT diff --git a/contrib/ncurses-5.4/man/man_db.renames b/contrib/ncurses-5.4/man/man_db.renames deleted file mode 100644 index ff5546b3c9..0000000000 --- a/contrib/ncurses-5.4/man/man_db.renames +++ /dev/null @@ -1,139 +0,0 @@ -# $Id: man_db.renames,v 0.32 2003/05/31 17:27:11 tom Exp $ -# Manual-page renamings for the man_db program -# -# Files: -captoinfo.1m captoinfo.1 -clear.1 clear.1 -curs_add_wch.3x add_wch.3ncurses -curs_add_wchstr.3x add_wchstr.3ncurses -curs_addch.3x addch.3ncurses -curs_addchstr.3x addchstr.3ncurses -curs_addstr.3x addstr.3ncurses -curs_addwstr.3x addwstr.3ncurses -curs_attr.3x attr.3ncurses -curs_beep.3x beep.3ncurses -curs_bkgd.3x bkgd.3ncurses -curs_bkgrnd.3x bkgrnd.3ncurses -curs_border.3x border.3ncurses -curs_border_set.3x border_set.3ncurses -curs_clear.3x clear.3ncurses -curs_color.3x color.3ncurses -curs_delch.3x delch.3ncurses -curs_deleteln.3x deleteln.3ncurses -curs_extend.3x extensions.3ncurses -curs_get_wch.3x get_wch.3ncurses -curs_get_wstr.3x get_wstr.3ncurses -curs_getcchar.3x getcchar.3ncurses -curs_getch.3x getch.3ncurses -curs_getstr.3x getstr.3ncurses -curs_getyx.3x getyx.3ncurses -curs_in_wch.3x in_wch.3ncurses -curs_in_wchstr.3x in_wchstr.3ncurses -curs_inch.3x inch.3ncurses -curs_inchstr.3x inchstr.3ncurses -curs_initscr.3x initscr.3ncurses -curs_inopts.3x inopts.3ncurses -curs_ins_wch.3x ins_wch.3ncurses -curs_ins_wstr.3x ins_wstr.3ncurses -curs_insch.3x insch.3ncurses -curs_insstr.3x insstr.3ncurses -curs_instr.3x instr.3ncurses -curs_inwstr.3x inwstr.3ncurses -curs_kernel.3x kernel.3ncurses -curs_mouse.3x mouse.3ncurses -curs_move.3x move.3ncurses -curs_outopts.3x outopts.3ncurses -curs_overlay.3x overlay.3ncurses -curs_pad.3x pad.3ncurses -curs_print.3x print.3ncurses -curs_printw.3x printw.3ncurses -curs_refresh.3x refresh.3ncurses -curs_scanw.3x scanw.3ncurses -curs_scr_dump.3x scr_dump.3ncurses -curs_scroll.3x scroll.3ncurses -curs_slk.3x slk.3ncurses -curs_termattrs.3x termattrs.3ncurses -curs_termcap.3x termcap.3ncurses -curs_terminfo.3x terminfo.3ncurses -curs_touch.3x touch.3ncurses -curs_trace.3x trace.3ncurses -curs_util.3x util.3ncurses -curs_window.3x window.3ncurses -curses.3x ncurses.3ncurses -default_colors.3x default_colors.3ncurses -define_key.3x define_key.3ncurses -form.3x form.3form -form_cursor.3x cursor.3form -form_data.3x data.3form -form_driver.3x driver.3form -form_field.3x field.3form -form_field_attributes.3x field_attributes.3form -form_field_buffer.3x field_buffer.3form -form_field_info.3x field_info.3form -form_field_just.3x field_just.3form -form_field_new.3x field_new.3form -form_field_opts.3x field_opts.3form -form_field_userptr.3x field_userptr.3form -form_field_validation.3x field_validation.3form -form_fieldtype.3x fieldtype.3form -form_hook.3x hook.3form -form_new.3x new.3form -form_new_page.3x new_page.3form -form_opts.3x opts.3form -form_page.3x page.3form -form_post.3x post.3form -form_requestname.3x requestname.3form -form_userptr.3x userptr.3form -form_win.3x win.3form -infocmp.1m infocmp.1 -infotocap.1m infotocap.1 -keybound.3x keybound.3ncurses -keyok.3x keyok.3ncurses -key_defined.3x key_defined.3ncurses -menu.3x menu.3menu -menu_attributes.3x attributes.3menu -menu_cursor.3x cursor.3menu -menu_driver.3x driver.3menu -menu_format.3x format.3menu -menu_hook.3x hook.3menu -menu_items.3x items.3menu -menu_mark.3x mark.3menu -menu_new.3x new.3menu -menu_opts.3x opts.3menu -menu_pattern.3x pattern.3menu -menu_post.3x post.3menu -menu_requestname.3x requestname.3menu -menu_spacing.3x spacing.3menu -menu_userptr.3x userptr.3menu -menu_win.3x win.3menu -mitem_current.3x menu_current.3menu -mitem_name.3x menu_name.3menu -mitem_new.3x menu_new.3menu -mitem_opts.3x menu_opts.3menu -mitem_userptr.3x menu_userptr.3menu -mitem_value.3x menu_value.3menu -mitem_visible.3x menu_visible.3menu -ncurses.3x ncurses.3ncurses -panel.3x panel.3curses -printf.3s printf.3 -putc.3s putc.3 -resizeterm.3x resizeterm.3ncurses -scanf.3s scanf.3 -system.3s system.3 -term.5 term.5 -term.7 term.7 -terminfo.5 terminfo.5 -terminfo.\\\*n terminfo.5 -tic.1m tic.1 -toe.1m toe.1 -tput.1 tput.1 -tset.1 tset.1 -vprintf.3s vprintf.3 -wresize.3x wresize.3ncurses -# -# Other cross-references: -addch.3x addch.3ncurses -can_change_color.3x can_change_color.3ncurses -curs_attr_get.3x attr_get.3ncurses -dup_field.3x dup_field.3ncurses -init_pair.3x init_pair.3ncurses diff --git a/contrib/ncurses-5.4/man/manlinks.sed b/contrib/ncurses-5.4/man/manlinks.sed deleted file mode 100644 index 4da7790dfd..0000000000 --- a/contrib/ncurses-5.4/man/manlinks.sed +++ /dev/null @@ -1,101 +0,0 @@ -# $Id: manlinks.sed,v 1.12 2003/12/20 13:17:56 tom Exp $ -############################################################################## -# Copyright (c) 2000-2002,2003 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. # -############################################################################## -# Given a manpage (nroff) as input, writes a list of the names that are -# listed in the "NAME" section, i.e., the names that we would like to use -# as aliases for the manpage -T.Dickey -# -# eliminate formatting controls that get in the way -/^'\\"/d -/\.\\"/d -/^\.br/d -/^\.sp/d -s/^\.IX// -s/\\f.//g -s/[:,]/ /g -# -# eliminate unnecessary whitespace, convert multiple blanks to single space -s/^[ ][ ]*// -s/[ ][ ]*$// -s/[ ][ ]*/ /g -# -# convert ".SH" into a more manageable form -s/\.SH[ ][ ]*/.SH_(/ -# -# in ".SH NAME" -# change "\-" to "-", eliminate text after "-", and split the remaining lines -# at each space, making a list of names: -/^\.SH_(NAME/,/^\.SH_(SYNOPSIS/{ -s/\\-.*/ -/ -/ -/{ -s/ -.*// -s/ /\ -/g -} -/^-/{ -d -} -s/ /\ -/g -} -# -# in ".SH SYNOPSIS" -# remove any line that does not contain a '(', since we only want functions. -# then strip off return-type of each function. -# finally, remove the parameter list, which begins with a '('. -/^\.SH_(SYNOPSIS/,/^\.SH_(DESCRIPTION/{ -/^[^(]*$/d -# reduce -# .B "int add_wch( const cchar_t *\fIwch\fB );" -# to -# add_wch( const cchar_t *\fIwch\fB );" -s/^\([^ (]* [^ (]* [*]*\)//g -s/^\([^ (]* [*]*\)//g -# trim blanks in case we have -# void (*) (FORM *) field_init(const FORM *form); -s/) (/)(/g -# reduce stuff like -# void (*)(FORM *) field_init(const FORM *form); -# to -# field_init(const FORM *form); -s/^\(([^)]*)\)\(([^)]*)\)*[ ]*//g -# rename marker temporarily -s/\.SH_(/.SH_/ -# kill lines with ");", and trim off beginning of argument list. -s/[()].*// -# rename marker back -s/\.SH_/.SH_(/ -} -# -# delete ".SH DESCRIPTION" and following lines -/^\.SH_(DESCRIPTION/,${ -d -} -# -# delete any remaining directives -/^\./d diff --git a/contrib/ncurses-5.4/man/menu.3x b/contrib/ncurses-5.4/man/menu.3x deleted file mode 100644 index e81913c43c..0000000000 --- a/contrib/ncurses-5.4/man/menu.3x +++ /dev/null @@ -1,190 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2000,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu.3x,v 1.15 2002/01/19 22:48:58 tom Exp $ -.TH menu 3X "" -.SH NAME -\fBmenu\fR - curses extension for programming menus -.SH SYNOPSIS -\fB#include \fR -.br -.SH DESCRIPTION -The \fBmenu\fR library provides terminal-independent facilities for composing -menu systems on character-cell terminals. The library includes: item routines, -which create and modify menu items; and menu routines, which group items into -menus, display menus on the screen, and handle interaction with the user. - -The \fBmenu\fR library uses the \fBcurses\fR libraries, and a curses -initialization routine such as \fBinitscr\fR must be called before using any of -these functions. To use the \fBmenu\fR library, link with the options -\fB-lmenu -lcurses\fR. - -.SS Current Default Values for Item Attributes - -The \fBmenu\fR library maintains a default value for item attributes. You can -get or set this default by calling the appropriate \fBget_\fR or \fBset_\fR -routine with a \fBNULL\fR item pointer. Changing this default with a -\fBset_\fR function affects future item creations, but does not change the -rendering of items already created. - -.SS Routine Name Index - -The following table lists each \fBmenu\fR routine and the name of -the manual page on which it is described. - -.TS -l l . -\fBcurses\fR Routine Name Manual Page Name -= -current_item \fBmitem_current\fR(3X) -free_item \fBmitem_new\fR(3X) -free_menu \fBmenu_new\fR(3X) -item_count \fBmenu_items\fR(3X) -item_description \fBmitem_name\fR(3X) -item_index \fBmitem_current\fR(3X) -item_init \fBmenu_hook\fR(3X) -item_name \fBmitem_name\fR(3X) -item_opts \fBmitem_opts\fR(3X) -item_opts_off \fBmitem_opts\fR(3X) -item_opts_on \fBmitem_opts\fR(3X) -item_term \fBmenu_hook\fR(3X) -item_userptr \fBmitem_userptr\fR(3X) -item_value \fBmitem_value\fR(3X) -item_visible \fBmitem_visible\fR(3X) -menu_back \fBmenu_attributes\fR(3X) -menu_driver \fBmenu_driver\fR(3X) -menu_fore \fBmenu_attributes\fR(3X) -menu_format \fBmenu_format\fR(3X) -menu_grey \fBmenu_attributes\fR(3X) -menu_init \fBmenu_hook\fR(3X) -menu_items \fBmenu_items\fR(3X) -menu_mark \fBmenu_mark\fR(3X) -menu_opts \fBmenu_opts\fR(3X) -menu_opts_off \fBmenu_opts\fR(3X) -menu_opts_on \fBmenu_opts\fR(3X) -menu_pad \fBmenu_attributes\fR(3X) -menu_pattern \fBmenu_pattern\fR(3X) -menu_request_by_name \fBmenu_requestname\fR(3X) -menu_request_name \fBmenu_requestname\fR(3X) -menu_spacing \fBmenu_spacing\fR(3X) -menu_sub \fBmenu_win\fR(3X) -menu_term \fBmenu_hook\fR(3X) -menu_userptr \fBmenu_userptr\fR(3X) -menu_win \fBmenu_win\fR(3X) -new_item \fBmitem_new\fR(3X) -new_menu \fBmenu_new\fR(3X) -pos_menu_cursor \fBmenu_cursor\fR(3X) -post_menu \fBmenu_post\fR(3X) -scale_menu \fBmenu_win\fR(3X) -set_current_item \fBmitem_current\fR(3X) -set_item_init \fBmenu_hook\fR(3X) -set_item_opts \fBmitem_opts\fR(3X) -set_item_term \fBmenu_hook\fR(3X) -set_item_userptr \fBmitem_userptr\fR(3X) -set_item_value \fBmitem_value\fR(3X) -set_menu_back \fBmenu_attributes\fR(3X) -set_menu_fore \fBmenu_attributes\fR(3X) -set_menu_format \fBmenu_format\fR(3X) -set_menu_grey \fBmenu_attributes\fR(3X) -set_menu_init \fBmenu_hook\fR(3X) -set_menu_items \fBmenu_items\fR(3X) -set_menu_mark \fBmenu_mark\fR(3X) -set_menu_opts \fBmitem_opts\fR(3X) -set_menu_pad \fBmenu_attributes\fR(3X) -set_menu_pattern \fBmenu_pattern\fR(3X) -set_menu_spacing \fBmenu_spacing\fR(3X) -set_menu_sub \fBmenu_win\fR(3X) -set_menu_term \fBmenu_hook\fR(3X) -set_menu_userptr \fBmenu_userptr\fR(3X) -set_menu_win \fBmenu_win\fR(3X) -set_top_row \fBmitem_current\fR(3X) -top_row \fBmitem_current\fR(3X) -unpost_menu \fBmenu_post\fR(3X) -.TE -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Routines that return -an integer return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu is already posted. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NO_ROOM\fR -Menu is too large for its window. -.TP 5 -\fBE_NOT_POSTED\fR -The menu has not been posted. -.TP 5 -\fBE_UNKNOWN_COMMAND\fR -The menu driver code saw an unknown request code. -.TP 5 -\fBE_NO_MATCH\fR -Character failed to match. -.TP 5 -\fBE_NOT_SELECTABLE\fR -The designated item cannot be selected. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the menu. -.TP 5 -\fBE_REQUEST_DENIED\fR -The menu driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "menu_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header files -\fB\fR and \fB\fR. - -In your library list, libmenu.a should be before libncurses.a; that is, -you want to say `-lmenu -lncurses', not the other way around (which would -give you a link error using GNU \fBld\fR(1) and many other linkers). -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for ncurses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_attributes.3x b/contrib/ncurses-5.4/man/menu_attributes.3x deleted file mode 100644 index 99a2ac2bc1..0000000000 --- a/contrib/ncurses-5.4/man/menu_attributes.3x +++ /dev/null @@ -1,100 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_attributes.3x,v 1.7 2002/01/19 22:49:06 tom Exp $ -.TH menu_attributes 3X "" -.SH NAME -\fBmenu_attributes\fR - color and attribute control for menus -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_fore(MENU *menu, chtype attr); -.br -chtype menu_fore(const MENU *menu); -.br -int set_menu_back(MENU *menu, chtype attr); -.br -chtype menu_back(const MENU *menu); -.br -int set_menu_grey(MENU *menu, chtype attr); -.br -chtype menu_grey(const MENU *menu); -.br -int set_menu_pad(MENU *menu, int pad); -.br -int menu_pad(const MENU *menu); -.br -.SH DESCRIPTION -The function \fBset_menu_fore\fR sets the foreground attribute of -\fImenu\fR. This is the highlight used for selected menu items. -\fBmenu_fore\fR returns the foreground attribute. The default -is \fBA_STANDOUT\fR. - -The function \fBset_menu_back\fR sets the background attribute of -\fImenu\fR. This is the highlight used for selectable (but not currently -selected) menu items. The function \fBmenu_back\fR returns the background -attribute. The default is \fBA_NORMAL\fR. - -The function \fBset_menu_grey\fR sets the grey attribute of \fImenu\fR. This is -the highlight used for un-selectable menu items in menus that permit more than -one selection. The function \fBmenu_grey\fR returns the grey attribute. -The default is \fBA_UNDERLINE\fR. - -The function \fBset_menu_pad\fR sets the character used to fill the space -between the name and description parts of a menu item. \fBmenu_pad\fR returns -the given menu's pad character. The default is a blank. -.SH RETURN VALUE -These routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X) and related pages whose names begin "menu_" for detailed -descriptions of the entry points. -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_cursor.3x b/contrib/ncurses-5.4/man/menu_cursor.3x deleted file mode 100644 index 2cc58507de..0000000000 --- a/contrib/ncurses-5.4/man/menu_cursor.3x +++ /dev/null @@ -1,73 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_cursor.3x,v 1.5 1998/11/29 01:09:30 Rick.Ohnemus Exp $ -.TH menu_cursor 3X "" -.SH NAME -\fBmenu_cursor\fR - position a menu's cursor -.SH SYNOPSIS -\fB#include \fR -.br -int pos_menu_cursor(const MENU *menu); -.br -.SH DESCRIPTION -The function \fBpos_menu_cursor\fR restores the cursor to the current position -associated with the menu's selected item. This is useful after \fBcurses\fR -routines have been called to do screen-painting in response to a menu select. -.SH RETURN VALUE -This routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_NOT_POSTED\fR -The menu has not been posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_driver.3x b/contrib/ncurses-5.4/man/menu_driver.3x deleted file mode 100644 index 1651724b0b..0000000000 --- a/contrib/ncurses-5.4/man/menu_driver.3x +++ /dev/null @@ -1,170 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_driver.3x,v 1.11 2003/05/10 20:22:01 tom Exp $ -.TH menu_driver 3X "" -.SH NAME -\fBmenu_driver\fR - command-processing loop of the menu system -.SH SYNOPSIS -\fB#include \fR -.br -int menu_driver(MENU *menu, int c); -.br -.SH DESCRIPTION -Once a menu has been posted (displayed), you should funnel input events to it -through \fBmenu_driver\fR. This routine has three major input cases; either -the input is a menu navigation request, it's a printable ASCII character or it -is the KEY_MOUSE special key associated with an mouse event. -The menu driver requests are as follows: -.TP 5 -REQ_LEFT_ITEM -Move left to an item. -.TP 5 -REQ_RIGHT_ITEM -Move right to an item. -.TP 5 -REQ_UP_ITEM -Move up to an item. -.TP 5 -REQ_DOWN_ITEM -Move down to an item. -.TP 5 -REQ_SCR_ULINE -Scroll up a line. -.TP 5 -REQ_SCR_DLINE -Scroll down a line. -.TP 5 -REQ_SCR_DPAGE -Scroll down a page. -.TP 5 -REQ_SCR_UPAGE -Scroll up a page. -.TP 5 -REQ_FIRST_ITEM -Move to the first item. -.TP 5 -REQ_LAST_ITEM -Move to the last item. -.TP 5 -REQ_NEXT_ITEM -Move to the next item. -.TP 5 -REQ_PREV_ITEM -Move to the previous item. -.TP 5 -REQ_TOGGLE_ITEM -Select/deselect an item. -.TP 5 -REQ_CLEAR_PATTERN -Clear the menu pattern buffer. -.TP 5 -REQ_BACK_PATTERN -Delete the previous character from the pattern buffer. -.TP 5 -REQ_NEXT_MATCH -Move to the next item matching the pattern match. -.TP 5 -REQ_PREV_MATCH -Move to the previous item matching the pattern match. -.PP -If the second argument is a printable ASCII character, the code appends -it to the pattern buffer and attempts to move to the next item matching -the new pattern. If there is no such match, \fBmenu_driver\fR returns -\fBE_NO_MATCH\fR and deletes the appended character from the buffer. -.PP -If the second argument is one of the above pre-defined requests, the -corresponding action is performed. -.PP -If the second argument is the KEY_MOUSE special key, the associated -mouse event is translated into one of the above pre-defined requests. -Currently only clicks in the user window (e.g. inside the menu display -area or the decoration window) are handled. If you click above the -display region of the menu, a REQ_SCR_ULINE is generated, if you -doubleclick a REQ_SCR_UPAGE is generated and if you tripleclick a -REQ_FIRST_ITEM is generated. If you click below the display region of -the menu, a REQ_SCR_DLINE is generated, if you doubleclick a REQ_SCR_DPAGE -is generated and if you tripleclick a REQ_LAST_ITEM is generated. If you -click at an item inside the display area of the menu, the menu cursor -is positioned to that item. If you double-click at an item a REQ_TOGGLE_ITEM -is generated and \fBE_UNKNOWN_COMMAND\fR is returned. This return value makes -sense, because a double click usually means that an item-specific action should -be returned. It's exactly the purpose of this return value to signal that an -application specific command should be executed. If a translation -into a request was done, \fBmenu_driver\fR returns the result of this request. -If you clicked outside the user window or the mouse event couldn't be translated -into a menu request an \fBE_REQUEST_DENIED\fR is returned. -.PP -If the second argument is neither printable ASCII nor one of the above -pre-defined menu requests or KEY_MOUSE, the drive assumes it is an application-specific -command and returns \fBE_UNKNOWN_COMMAND\fR. Application-defined commands -should be defined relative to \fBMAX_COMMAND\fR, the maximum value of these -pre-defined requests. -.SH RETURN VALUE -\fBmenu_driver\fR return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NOT_POSTED\fR -The menu has not been posted. -.TP 5 -\fBE_UNKNOWN_COMMAND\fR -The menu driver code saw an unknown request code. -.TP 5 -\fBE_NO_MATCH\fR -Character failed to match. -.TP 5 -\fBE_REQUEST_DENIED\fR -The menu driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header files -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. The support for mouse events is ncurses specific. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_format.3x b/contrib/ncurses-5.4/man/menu_format.3x deleted file mode 100644 index 7dde28face..0000000000 --- a/contrib/ncurses-5.4/man/menu_format.3x +++ /dev/null @@ -1,84 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_format.3x,v 1.8 2001/08/04 20:36:19 William.Setzer Exp $ -.TH menu_format 3X "" -.SH NAME -\fBmenu_format\fR - set and get menu sizes -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_format(MENU *menu, int rows, int cols); -.br -void menu_format(const MENU *menu, int *rows, int *cols); -.br -.SH DESCRIPTION -The function \fBset_menu_format\fR sets the maximum display size of the given -menu. If this size is too small to display all menu items, the menu will be -made scrollable. If this size is larger than the menus subwindow and the -subwindow is too small to display all menu items, \fBpost_menu()\fR will fail. - -The default format is 16 rows, 1 column. Calling \fBset_menu_format\fR with a -null menu pointer will change this default. A zero row or column argument to -\fBset_menu_format\fR is interpreted as a request not to change the current -value. - -The function \fBmenu_format\fR returns the maximum-size constraints for the -given menu into the storage addressed by \fBrows\fR and \fBcols\fR. -.SH RETURN VALUE -These routines returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu is already posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_hook.3x b/contrib/ncurses-5.4/man/menu_hook.3x deleted file mode 100644 index 531528a607..0000000000 --- a/contrib/ncurses-5.4/man/menu_hook.3x +++ /dev/null @@ -1,101 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_hook.3x,v 1.6 1998/11/29 01:09:47 Rick.Ohnemus Exp $ -.TH menu_hook 3X "" -.SH NAME -\fBmenu_hook\fR - set hooks for automatic invocation by applications -.SH SYNOPSIS -\fB#include \fR -.br -int set_item_init(MENU *menu, void (*func)(MENU *)); -.br -void (*)(MENU *) item_init(const MENU *menu); -.br -int set_item_term(MENU *menu, void (*func)(MENU *)); -.br -void (*)(MENU *) item_term(const MENU *menu); -.br -int set_menu_init(MENU *menu, void (*func)(MENU *)); -.br -void (*)(MENU *) menu_init(const MENU *menu); -.br -int set_menu_term(MENU *menu, void (*func)(MENU *)); -.br -void (*)(MENU *) menu_term(const MENU *menu); -.br -.SH DESCRIPTION -These functions make it possible to set hook functions to be called at various -points in the automatic processing of input event codes by \fBmenu_driver\fR. - -The function \fBset_item_init\fR sets a hook to be called at menu-post time and -each time the selected item changes (after the change). \fBitem_init\fR -returns the current item init hook, if any (\fBNULL\fR if there is no such -hook). - -The function \fBset_item_term\fR sets a hook to be called at menu-unpost time -and each time the selected item changes (before the change). \fBitem_term\fR -returns the current item term hook, if any (\fBNULL\fR if there is no such -hook). - -The function \fBset_menu_init\fR sets a hook to be called at menu-post time and -just after the top row on the menu changes once it is posted. \fBmenu_init\fR -returns the current menu init hook, if any (\fBNULL\fR if there is no such -hook). - -The function \fBset_menu_term\fR sets a hook to be called at menu-unpost time -and just before the top row on the menu changes once it is posted. -\fBmenu_term\fR returns the current menu term hook, if any (\fBNULL\fR if there -is no such hook). -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Other routines -return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_items.3x b/contrib/ncurses-5.4/man/menu_items.3x deleted file mode 100644 index 7ec7db5604..0000000000 --- a/contrib/ncurses-5.4/man/menu_items.3x +++ /dev/null @@ -1,91 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_items.3x,v 1.5 1998/11/29 01:09:56 Rick.Ohnemus Exp $ -.TH menu_items 3X "" -.SH NAME -\fBmenu_items\fR - make and break connections between items and menus -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_items(MENU *menu, ITEM **items); -.br -ITEM **menu_items(const MENU *menu); -.br -int item_count(const MENU *menu); -.br -.SH DESCRIPTION -The function \fBset_menu_items\fR changes the item pointer array of the given -\fImenu\fR. The array must be terminated by a \fBNULL\fR. - -The function \fBmenu_items\fR returns the item array of the given menu. - -The function \fBitem_count\fR returns the count of items in \fImenu\fR. -.SH RETURN VALUES -The function \fBmenu_items\fR returns \fBNULL\fR on error. - -The function \fBitem_count\fR returns \fBERR\fR (the general \fBcurses\fR error -return value) on error. - -The function \fBset_menu_items\fR returns one of the following codes on error: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu is already posted. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the menu. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. - -The SVr4 menu library documentation specifies the \fBitem_count\fR error value -as -1 (which is the value of \fBERR\fR). -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_mark.3x b/contrib/ncurses-5.4/man/menu_mark.3x deleted file mode 100644 index 72ea000335..0000000000 --- a/contrib/ncurses-5.4/man/menu_mark.3x +++ /dev/null @@ -1,84 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_mark.3x,v 1.6 1998/11/29 01:10:03 Rick.Ohnemus Exp $ -.TH menu_mark 3X "" -.SH NAME -\fBmenu_mark\fR - get and set the menu mark string -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_mark(MENU *menu, const char *mark); -.br -const char *menu_mark(const MENU *menu); -.br -.SH DESCRIPTION -In order to make menu selections visible on older terminals without -highlighting or color capability, the menu library marks selected items -in a menu with a prefix string. - -The function \fBset_menu_mark\fR sets the mark string for the given menu. -Calling \fBset_menu_mark\fR with a null menu item will abolish the mark string. -Note that changing the length of the mark string for a menu while the -menu is posted is likely to produce unhelpful behavior. - -The default string is "-" (a dash). Calling \fBset_menu_mark\fR with -a \fBNULL\fR menu argument will change this default. - -The function \fBmenu_mark\fR returns the menu's mark string (or \fBNULL\fR if -there is none). -.SH RETURN VALUE -The function \fBmenu_mark\fR returns \fBNULL\fR on error. The function -\fBset_menu_mark\fR may return the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_new.3x b/contrib/ncurses-5.4/man/menu_new.3x deleted file mode 100644 index c53bd9b8cb..0000000000 --- a/contrib/ncurses-5.4/man/menu_new.3x +++ /dev/null @@ -1,79 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_new.3x,v 1.7 1998/11/29 01:10:13 Rick.Ohnemus Exp $ -.TH menu_new 3X "" -.SH NAME -\fBmenu_new\fR - create and destroy menus -.SH SYNOPSIS -\fB#include \fR -.br -MENU *new_menu(ITEM **items); -.br -int free_menu(MENU *menu); -.br -.SH DESCRIPTION -The function \fBnew_menu\fR creates a new menu connected to a specified item -pointer array (which must be \fBNULL\fR-terminated). - -The function \fBfree_menu\fR disconnects \fImenu\fR from its item array -and frees the storage allocated for the menu. -.SH RETURN VALUE -The function \fBnew_menu\fR returns \fBNULL\fR on error. - -The function \fBfree_menu\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu has already been posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_opts.3x b/contrib/ncurses-5.4/man/menu_opts.3x deleted file mode 100644 index 30cad58d49..0000000000 --- a/contrib/ncurses-5.4/man/menu_opts.3x +++ /dev/null @@ -1,104 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_opts.3x,v 1.7 1998/11/29 01:10:21 Rick.Ohnemus Exp $ -.TH menu_opts 3X "" -.SH NAME -\fBmenu_opts\fR - set and get menu options -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_opts(MENU *menu, OPTIONS opts); -.br -int menu_opts_on(MENU *menu, OPTIONS opts); -.br -int menu_opts_off(MENU *menu, OPTIONS opts); -.br -OPTIONS menu_opts(const MENU *menu); -.br -.SH DESCRIPTION -The function \fBset_menu_opts\fR sets all the given menu's option bits (menu -option bits may be logically-OR'ed together). - -The function \fBmenu_opts_on\fR turns on the given option bits, and leaves -others alone. - -The function \fBmenu_opts_off\fR turns off the given option bits, and leaves -others alone. - -The function \fBmenu_opts\fR returns the menu's current option bits. - -The following options are defined (all are on by default): -.TP 5 -O_ONEVALUE -Only one item can be selected for this menu. -.TP 5 -O_SHOWDESC -Display the item descriptions when the menu is posted. -.TP 5 -O_ROWMAJOR -Display the menu in row-major order. -.TP 5 -O_IGNORECASE -Ignore the case when pattern-matching. -.TP 5 -O_SHOWMATCH -Move the cursor to within the item name while pattern-matching. -.TP 5 -O_NONCYCLIC -Don't wrap around next-item and previous-item, -requests to the other end of the menu. -.SH RETURN VALUE -Except for \fBmenu_opts\fR, each routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_POSTED\fR -The menu is already posted. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_pattern.3x b/contrib/ncurses-5.4/man/menu_pattern.3x deleted file mode 100644 index 2fdc09a615..0000000000 --- a/contrib/ncurses-5.4/man/menu_pattern.3x +++ /dev/null @@ -1,82 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_pattern.3x,v 1.8 2003/05/10 20:22:01 tom Exp $ -.TH menu_pattern 3X "" -.SH NAME -\fBmenu_pattern\fR - get and set a menu's pattern buffer -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_pattern(MENU *menu, const char *pattern); -.br -char *menu_pattern(const MENU *menu); -.br -.SH DESCRIPTION -Every menu has an associated pattern match buffer. As input events that are -printable ASCII characters come in, they are appended to this match buffer -and tested for a match, as described in \fBmenu_driver\fR(3X). - -The function \fBset_menu_pattern\fR sets the pattern buffer for the given menu -and tries to find the first matching item. If it succeeds, that item becomes -current; if not, the current item does not change. - -The function \fBmenu_pattern\fR returns the pattern buffer of the given -\fImenu\fR. -.SH RETURN VALUE -The function \fBmenu_pattern\fR returns \fBNULL\fR on error. The function -\fBset_menu_pattern\fR may return the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_NO_MATCH\fR -Character failed to match. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_post.3x b/contrib/ncurses-5.4/man/menu_post.3x deleted file mode 100644 index a4182d6495..0000000000 --- a/contrib/ncurses-5.4/man/menu_post.3x +++ /dev/null @@ -1,91 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_post.3x,v 1.7 1998/11/29 01:10:33 Rick.Ohnemus Exp $ -.TH menu_post 3X "" -.SH NAME -\fBmenu_post\fR - write or erase menus from associated subwindows -.SH SYNOPSIS -\fB#include \fR -.br -int post_menu(MENU *menu); -.br -int unpost_menu(MENU *menu); -.br -.SH DESCRIPTION -The function \fBpost_menu\fR displays a menu to its associated subwindow. To -trigger physical display of the subwindow, use \fBrefresh\fR or some equivalent -\fBcurses\fR routine (the implicit \fBdoupdate\fR triggered by an \fBcurses\fR -input request will do). \fBpost_menu\fR resets the selection status of all items. - -The function \fBunpost_menu\fR erases menu from its associated subwindow. -.SH RETURN VALUE -These routines return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu has already been posted. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NO_ROOM\fR -Menu is too large for its window. You should consider to use -\fBset_menu_format()\fR to solve the problem. -.TP 5 -\fBE_NOT_POSTED\fR -The menu has not been posted. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the menu. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_requestname.3x b/contrib/ncurses-5.4/man/menu_requestname.3x deleted file mode 100644 index f4b646a455..0000000000 --- a/contrib/ncurses-5.4/man/menu_requestname.3x +++ /dev/null @@ -1,69 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_requestname.3x,v 1.6 1998/11/29 01:10:40 Rick.Ohnemus Exp $ -.TH menu_requestname 3X "" -.SH NAME -\fBmenu_requestname\fR - handle printable menu request names -.SH SYNOPSIS -\fB#include \fR -.br -const char *menu_request_name(int request); -.br -int menu_request_by_name(const char *name); -.br -.SH DESCRIPTION -The function \fBmenu_request_name\fR returns the printable name of a menu -request code. -.br -The function \fBmenu_request_by_name\fR searches in the name-table for a request -with the given name and returns its request code. Otherwise E_NO_MATCH is returned. -.SH RETURN VALUE -\fBmenu_request_name\fR returns \fBNULL\fR on error and sets errno -to \fBE_BAD_ARGUMENT\fR. -.br -\fBmenu_request_by_name\fR returns \fBE_NO_MATCH\fR on error. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_spacing.3x b/contrib/ncurses-5.4/man/menu_spacing.3x deleted file mode 100644 index 1831621932..0000000000 --- a/contrib/ncurses-5.4/man/menu_spacing.3x +++ /dev/null @@ -1,84 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2001 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_spacing.3x,v 1.6 2001/08/04 20:36:16 William.Setzer Exp $ -.TH menu_spacing 3X "" -.SH NAME -\fBmenu_spacing\fR - Control spacing between menu items. -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_spacing(MENU *menu, - int spc_description, - int spc_rows, - int spc_columns); -.br -int menu_spacing(const MENU *menu, - int* spc_description, - int* spc_rows, - int* spc_columns); -.br -.SH DESCRIPTION -The function \fBset_menu_spacing\fR sets the spacing informations for the menu. -\fBspc_description\fR controls the number of spaces between an item name and an item -description. It must not be larger than \fBTABSIZE\fR. The menu system puts in the -middle of this spacing area the pad character. The remaining parts are filled with -spaces. -\fBspc_rows\fR controls the number of rows that are used for an item. It must not be -larger than 3. The menu system inserts then blank lines between item rows, these lines -will contain the pad character in the appropriate positions. -\fBspc_columns\fR controls the number of blanks between columns of items. It must not -be larger than TABSIZE. -A value of 0 for all the spacing values resets them to the default, which is 1 for all -of them. -.br -The function \fBmenu_spacing\fR passes back the spacing info for the menu. If a -pointer is NULL, this specific info is simply not returned. -.SH RETURN VALUE -Both routines return \fBE_OK\fR on success. \fBset_menu_spacing\fR may return -\fBE_POSTED\fR if the menu is posted, or \fBE_BAD_ARGUMENT\fR if one of the -spacing values is out of range. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines are specific to ncurses. They were not supported on -Version 7, BSD or System V implementations. It is recommended that -any code depending on them be conditioned using NCURSES_VERSION. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_userptr.3x b/contrib/ncurses-5.4/man/menu_userptr.3x deleted file mode 100644 index 1fe354183d..0000000000 --- a/contrib/ncurses-5.4/man/menu_userptr.3x +++ /dev/null @@ -1,73 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_userptr.3x,v 1.6 1998/11/29 01:11:02 Rick.Ohnemus Exp $ -.TH menu_userptr 3X "" -.SH NAME -\fBmenu_userptr\fR - associate application data with a menu item -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_userptr(MENU *menu, void *userptr); -.br -void *menu_userptr(const MENU *menu); -.br -.SH DESCRIPTION -Every menu and every menu item has a field that can be used to hold -application-specific data (that is, the menu-driver code leaves it alone). -These functions get and set the menu user pointer field. -.SH RETURN VALUE -Except for \fBmenu_userptr\fR (which returns \fBNULL\fR on error), each -function returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. - -The user pointer should be a void pointer. We leave it as a char pointer for -SVr4 compatibility. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/menu_win.3x b/contrib/ncurses-5.4/man/menu_win.3x deleted file mode 100644 index 336da44b0c..0000000000 --- a/contrib/ncurses-5.4/man/menu_win.3x +++ /dev/null @@ -1,95 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: menu_win.3x,v 1.6 1998/11/29 01:11:11 Rick.Ohnemus Exp $ -.TH menu_win 3X "" -.SH NAME -\fBmenu_win\fR - make and break menu window and subwindow associations -.SH SYNOPSIS -\fB#include \fR -.br -int set_menu_win(MENU *menu, WINDOW *win); -.br -WINDOW *menu_win(const MENU *menu); -.br -int set_menu_sub(MENU *menu, WINDOW *sub); -.br -WINDOW *menu_sub(const MENU *menu); -.br -int scale_menu(const MENU *menu, int *rows, int *columns); -.br -.SH DESCRIPTION -Every menu has an associated pair of \fBcurses\fR windows. The menu window -displays any title and border associated with the window; the menu subwindow -displays the items of the menu that are currently available for selection. - -The first four functions get and set those windows. It is not necessary to set -either window; by default, the driver code uses \fBstdscr\fR for both. - -In the \fBset_\fR functions, window argument of \fBNULL\fR is treated as though -it were \fBstsdcr\fR. A menu argument of \fBNULL\fR is treated as a request -to change the system default menu window or subwindow. - -The function \fBscale_menu\fR returns the minimum size required for the -subwindow of \fImenu\fR. -.SH RETURN VALUE -Routines that return pointers return \fBNULL\fR on error. Routines that return -an integer return one of the following error codes: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_POSTED\fR -The menu has already been posted. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the menu. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_current.3x b/contrib/ncurses-5.4/man/mitem_current.3x deleted file mode 100644 index 179a23be3b..0000000000 --- a/contrib/ncurses-5.4/man/mitem_current.3x +++ /dev/null @@ -1,101 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_current.3x,v 1.9 1998/12/26 19:52:34 tom Exp $ -.TH mitem_current 3X "" -.SH NAME -\fBmitem_current\fR - set and get current_menu_item -.SH SYNOPSIS -\fB#include \fR -.br -int set_current_item(MENU *menu, const ITEM *item); -.br -ITEM *current_item(const MENU *menu); -.br -int set_top_row(MENU *menu, int row); -.br -int top_row(const MENU *menu); -.br -int item_index(const ITEM *item); -.br -.SH DESCRIPTION -The function \fBset_current_item\fR sets the current item (the item on which -the menu cursor is positioned). \fBcurrent_item\fR returns a pointer to the -current item in the given menu. - -The function \fBset_top_row\fR sets the top row of the menu to show the given -row (the top row is initially 0, and is reset to this value whenever the -\fBO_ROWMAJOR\fR option is toggled). The item leftmost on the given row -becomes current. The function \fBtop_row\fR returns the number of the top menu -row being displayed. - -The function \fBitem_index\fR returns the (zero-origin) index of \fIitem\fR in -the menu's item pointer list. -.SH RETURN VALUE -\fBcurrent_item\fR returns \fBNULL\fR on error. - -\fBtop_row\fR and \fBitem_index\fR return \fBERR\fR (the general \fBcurses\fR -error value) on error. - -\fBset_current_item\fR and \fBset_top_row\fR return one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_BAD_STATE\fR -Routine was called from an initialization or termination function. -.TP 5 -\fBE_NOT_CONNECTED\fR -No items are connected to the menu. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. - -The SVr4 menu library documentation specifies the \fBtop_row\fR and -\fBindex_item\fR error value as -1 (which is the value of \fBERR\fR). -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_name.3x b/contrib/ncurses-5.4/man/mitem_name.3x deleted file mode 100644 index 007752e0bb..0000000000 --- a/contrib/ncurses-5.4/man/mitem_name.3x +++ /dev/null @@ -1,64 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_name.3x,v 1.5 1998/11/29 01:11:29 Rick.Ohnemus Exp $ -.TH mitem_name 3X "" -.SH NAME -\fBmitem_name\fR - get menu item name and description fields -.SH SYNOPSIS -\fB#include \fR -.br -const char *item_name(const ITEM *item); -.br -const char *item_description(const ITEM *item); -.br -.SH DESCRIPTION -The function \fBitem_name\fR returns the name part of the given item. -.br -The function \fBitem_description\fR returns the description part of the given -item. -.SH RETURN VALUE -These routines returns \fBNULL\fR on error. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_new.3x b/contrib/ncurses-5.4/man/mitem_new.3x deleted file mode 100644 index afba950b13..0000000000 --- a/contrib/ncurses-5.4/man/mitem_new.3x +++ /dev/null @@ -1,83 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_new.3x,v 1.8 2003/10/25 20:08:57 Jared.Yanovich Exp $ -.TH mitem_new 3X "" -.SH NAME -\fBmitem_new\fR - create and destroy menu items -.SH SYNOPSIS -\fB#include \fR -.br -ITEM *new_item(const char *name, const char *description); -.br -int free_item(ITEM *item); -.br -.SH DESCRIPTION -The function \fBnew_item\fR allocates a new item and initializes it from the -\fBname\fR and \fBdescription\fR pointers. Please notice that the item stores -only the pointers to the name and description. Those pointers must be valid -during the lifetime of the item. So you should be very careful with names -or descriptions allocated on the stack of some routines. -.br -The function \fBfree_item\fR de-allocates an item. Please notice that it -is the responsibility of the application to release the memory for the -name or the description of the item. -.SH RETURN VALUE -The function \fBnew_item\fR returns \fBNULL\fR on error. - -The function \fBfree_item\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_BAD_ARGUMENT\fR -Routine detected an incorrect or out-of-range argument. -.TP 5 -\fBE_CONNECTED\fR -Item is connected to a menu. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_opts.3x b/contrib/ncurses-5.4/man/mitem_opts.3x deleted file mode 100644 index 99e4e5ea7e..0000000000 --- a/contrib/ncurses-5.4/man/mitem_opts.3x +++ /dev/null @@ -1,84 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_opts.3x,v 1.6 1998/11/29 01:12:37 Rick.Ohnemus Exp $ -.TH mitem_opts 3X "" -.SH NAME -\fBmitem_opts\fR - set and get menu item options -.SH SYNOPSIS -\fB#include \fR -.br -int set_item_opts(ITEM *item, OPTIONS opts); -.br -int item_opts_on(ITEM *item, OPTIONS opts); -.br -int item_opts_off(ITEM *item, OPTIONS opts); -.br -OPTIONS item_opts(const ITEM *item); -.br -.SH DESCRIPTION -The function \fBset_item_opts\fR sets all the given item's option bits (menu -option bits may be logically-OR'ed together). - -The function \fBitem_opts_on\fR turns on the given option bits, and leaves -others alone. - -The function \fBitem_opts_off\fR turns off the given option bits, and leaves -others alone. - -The function \fBitem_opts\fR returns the item's current option bits. - -There is only one defined option bit mask, \fBO_SELECTABLE\fR. When this is -on, the item may be selected during menu processing. This option defaults -to on. -.SH RETURN VALUE -Except for \fBitem_opts\fR, each routine returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_userptr.3x b/contrib/ncurses-5.4/man/mitem_userptr.3x deleted file mode 100644 index 2dd564fd61..0000000000 --- a/contrib/ncurses-5.4/man/mitem_userptr.3x +++ /dev/null @@ -1,72 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_userptr.3x,v 1.6 1998/11/29 01:12:47 Rick.Ohnemus Exp $ -.TH mitem_userptr 3X "" -.SH NAME -\fBmitem_userptr\fR - associate application data with a menu item -.SH SYNOPSIS -\fB#include \fR -.br -int set_item_userptr(ITEM *item, void *userptr); -.br -void *item_userptr(const ITEM *item); -.br -.SH DESCRIPTION -Every menu item has a field that can be used to hold application-specific data -(that is, the menu-driver code leaves it alone). These functions get and set -that field. -.SH RETURN VALUE -Except for \fBitem_userptr\fR (which returns \fBNULL\fR on error), each function returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. - -The user pointer should be a void pointer. We leave it as a char pointer for -SVr4 compatibility. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_value.3x b/contrib/ncurses-5.4/man/mitem_value.3x deleted file mode 100644 index 5817d8d277..0000000000 --- a/contrib/ncurses-5.4/man/mitem_value.3x +++ /dev/null @@ -1,76 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_value.3x,v 1.6 2002/02/16 22:40:59 tom Exp $ -.TH mitem_value 3X "" -.SH NAME -\fBmitem_value\fR - set and get menu item values -.SH SYNOPSIS -\fB#include \fR -.br -int set_item_value(ITEM *item, bool value); -.br -bool item_value(const ITEM *item); -.br -.SH DESCRIPTION -If you turn off the menu option \fBO_ONEVALUE\fR (e.g., with -\fBset_menu_opts\fR or \fBmenu_opts_off\fR; see \fBmenu_opts\fR(3X)), the menu -becomes multi-valued; that is, more than one item may simultaneously be -selected. - -In a multi_valued menu, you can used \fBset_item_value\fR to select the -given menu item (second argument \fBTRUE\fR) or deselect it (second argument -\fBFALSE\fR). -.SH RETURN VALUE -The function \fBset_item_value\fR returns one of the following: -.TP 5 -\fBE_OK\fR -The routine succeeded. -.TP 5 -\fBE_SYSTEM_ERROR\fR -System error occurred (see \fBerrno\fR). -.TP 5 -\fBE_REQUEST_DENIED\fR -The menu driver could not process the request. -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/mitem_visible.3x b/contrib/ncurses-5.4/man/mitem_visible.3x deleted file mode 100644 index 8f9039c2f6..0000000000 --- a/contrib/ncurses-5.4/man/mitem_visible.3x +++ /dev/null @@ -1,59 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998 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. * -.\"*************************************************************************** -.\" -.\" $Id: mitem_visible.3x,v 1.5 1998/11/29 01:12:55 Rick.Ohnemus Exp $ -.TH mitem_visible 3X "" -.SH NAME -\fBmitem_visible\fR - check visibility of a menu item -.SH SYNOPSIS -\fB#include \fR -.br -bool item_visible(const ITEM *item); -.br -.SH DESCRIPTION -A menu item is visible when it is in the portion of a posted menu that -is mapped onto the screen (if the menu is scrollable, in particular, this -portion will be smaller than the whole menu). -.SH SEE ALSO -\fBcurses\fR(3X), \fBmenu\fR(3X). -.SH NOTES -The header file \fB\fR automatically includes the header file -\fB\fR. -.SH PORTABILITY -These routines emulate the System V menu library. They were not supported on -Version 7 or BSD versions. -.SH AUTHORS -Juergen Pfeifer. Manual pages and adaptation for new curses by Eric -S. Raymond. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/ncurses.3x b/contrib/ncurses-5.4/man/ncurses.3x deleted file mode 100644 index 0c87dd8d35..0000000000 --- a/contrib/ncurses-5.4/man/ncurses.3x +++ /dev/null @@ -1,912 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2003,2004 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. * -.\"*************************************************************************** -.\" -.\" $Id: ncurses.3x,v 1.70 2004/01/11 01:45:54 tom Exp $ -.hy 0 -.TH ncurses 3X "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBncurses\fR - CRT screen handling and optimization package -.SH SYNOPSIS -\fB#include \fR -.br -.SH DESCRIPTION -The \fBncurses\fR library routines give the user a terminal-independent method -of updating character screens with reasonable optimization. This -implementation is ``new curses'' (ncurses) and is the approved replacement for -4.4BSD classic curses, which has been discontinued. -.PP -The \fBncurses\fR routines emulate the \fBcurses\fR(3X) library of System V -Release 4 UNIX, and the XPG4 curses standard (XSI curses) but the \fBncurses\fR -library is freely redistributable in source form. Differences from the SVr4 -curses are summarized under the EXTENSIONS and BUGS sections below and -described in detail in the EXTENSIONS and BUGS sections of individual man -pages. -.PP -A program using these routines must be linked with the \fB-lncurses\fR option, -or (if it has been generated) with the debugging library \fB-lncurses_g\fR. -(Your system integrator may also have installed these libraries under -the names \fB-lcurses\fR and \fB-lcurses_g\fR.) -The ncurses_g library generates trace logs (in a file called 'trace' in the -current directory) that describe curses actions. -.PP -The \fBncurses\fR package supports: overall screen, window and pad -manipulation; output to windows and pads; reading terminal input; control over -terminal and \fBcurses\fR input and output options; environment query -routines; color manipulation; use of soft label keys; terminfo capabilities; -and access to low-level terminal-manipulation routines. -.PP -To initialize the routines, the routine \fBinitscr\fR or \fBnewterm\fR -must be called before any of the other routines that deal with windows -and screens are used. The routine \fBendwin\fR must be called before -exiting. To get character-at-a-time input without echoing (most -interactive, screen oriented programs want this), the following -sequence should be used: -.sp - \fBinitscr(); cbreak(); noecho();\fR -.sp -Most programs would additionally use the sequence: -.sp - \fBnonl();\fR - \fBintrflush(stdscr, FALSE);\fR - \fBkeypad(stdscr, TRUE);\fR -.sp -Before a \fBcurses\fR program is run, the tab stops of the terminal -should be set and its initialization strings, if defined, must be -output. This can be done by executing the \fBtput init\fR command -after the shell environment variable \fBTERM\fR has been exported. -\fBtset(1)\fR is usually responsible for doing this. -[See \fBterminfo\fR(\*n) for further details.] -.PP -The \fBncurses\fR library permits manipulation of data structures, -called \fIwindows\fR, which can be thought of as two-dimensional -arrays of characters representing all or part of a CRT screen. A -default window called \fBstdscr\fR, which is the size of the terminal -screen, is supplied. Others may be created with \fBnewwin\fR. -.PP -Note that \fBcurses\fR does not handle overlapping windows, that's done by -the \fBpanel\fR(3X) library. This means that you can either use -\fBstdscr\fR or divide the screen into tiled windows and not using -\fBstdscr\fR at all. Mixing the two will result in unpredictable, and -undesired, effects. -.PP -Windows are referred to by variables declared as \fBWINDOW *\fR. -These data structures are manipulated with routines described here and -elsewhere in the \fBncurses\fR manual pages. Among which the most basic -routines are \fBmove\fR and \fBaddch\fR. More general versions of -these routines are included with names beginning with \fBw\fR, -allowing the user to specify a window. The routines not beginning -with \fBw\fR affect \fBstdscr\fR.) -.PP -After using routines to manipulate a window, \fBrefresh\fR is called, -telling \fBcurses\fR to make the user's CRT screen look like -\fBstdscr\fR. The characters in a window are actually of type -\fBchtype\fR, (character and attribute data) so that other information -about the character may also be stored with each character. -.PP -Special windows called \fIpads\fR may also be manipulated. These are windows -which are not constrained to the size of the screen and whose contents need not -be completely displayed. See \fBcurs_pad\fR(3X) for more information. -.PP -In addition to drawing characters on the screen, video attributes and colors -may be supported, causing the characters to show up in such modes as -underlined, in reverse video, or in color on terminals that support such -display enhancements. Line drawing characters may be specified to be output. -On input, \fBcurses\fR is also able to translate arrow and function keys that -transmit escape sequences into single values. The video attributes, line -drawing characters, and input values use names, defined in \fB\fR, -such as \fBA_REVERSE\fR, \fBACS_HLINE\fR, and \fBKEY_LEFT\fR. -.PP -If the environment variables \fBLINES\fR and \fBCOLUMNS\fR are set, or if the -program is executing in a window environment, line and column information in -the environment will override information read by \fIterminfo\fR. This would -effect a program running in an AT&T 630 layer, for example, where the size of a -screen is changeable (see \fBENVIRONMENT\fR). -.PP -If the environment variable \fBTERMINFO\fR is defined, any program using -\fBcurses\fR checks for a local terminal definition before checking in the -standard place. For example, if \fBTERM\fR is set to \fBatt4424\fR, then the -compiled terminal definition is found in -.sp - \fB\*d/a/att4424\fR. -.sp -(The \fBa\fR is copied from the first letter of \fBatt4424\fR to avoid -creation of huge directories.) However, if \fBTERMINFO\fR is set to -\fB$HOME/myterms\fR, \fBcurses\fR first checks -.sp - \fB$HOME/myterms/a/att4424\fR, -.sp -and if that fails, it then checks -.sp - \fB\*d/a/att4424\fR. -.sp -This is useful for developing experimental definitions or when write -permission in \fB\*d\fR is not available. -.PP -The integer variables \fBLINES\fR and \fBCOLS\fR are defined in -\fB\fR and will be filled in by \fBinitscr\fR with the size of the -screen. The constants \fBTRUE\fR and \fBFALSE\fR have the values \fB1\fR and -\fB0\fR, respectively. -.PP -The \fBcurses\fR routines also define the \fBWINDOW *\fR variable \fBcurscr\fR -which is used for certain low-level operations like clearing and redrawing a -screen containing garbage. The \fBcurscr\fR can be used in only a few -routines. -. -.SS Routine and Argument Names -Many \fBcurses\fR routines have two or more versions. The routines prefixed -with \fBw\fR require a window argument. The routines prefixed with \fBp\fR -require a pad argument. Those without a prefix generally use \fBstdscr\fR. -.PP -The routines prefixed with \fBmv\fR require a \fIy\fR and \fIx\fR -coordinate to move to before performing the appropriate action. The -\fBmv\fR routines imply a call to \fBmove\fR before the call to the -other routine. The coordinate \fIy\fR always refers to the row (of -the window), and \fIx\fR always refers to the column. The upper -left-hand corner is always (0,0), not (1,1). -.PP -The routines prefixed with \fBmvw\fR take both a window argument and -\fIx\fR and \fIy\fR coordinates. The window argument is always -specified before the coordinates. -.PP -In each case, \fIwin\fR is the window affected, and \fIpad\fR is the -pad affected; \fIwin\fR and \fIpad\fR are always pointers to type -\fBWINDOW\fR. -.PP -Option setting routines require a Boolean flag \fIbf\fR with the value -\fBTRUE\fR or \fBFALSE\fR; \fIbf\fR is always of type \fBbool\fR. The -variables \fIch\fR and \fIattrs\fR below are always of type -\fBchtype\fR. The types \fBWINDOW\fR, \fBSCREEN\fR, \fBbool\fR, and -\fBchtype\fR are defined in \fB\fR. The type \fBTERMINAL\fR -is defined in \fB\fR. All other arguments are integers. -.SS Routine Name Index -The following table lists each \fBcurses\fR routine and the name of -the manual page on which it is described. Routines flagged with `*' -are ncurses-specific, not described by XPG4 or present in SVr4. -.PP -.TS -center tab(/); -l l -l l . -\fBcurses\fR Routine Name/Manual Page Name -= -COLOR_PAIR/\fBcurs_color\fR(3X) -PAIR_NUMBER/\fBcurs_attr\fR(3X) -_nc_tracebits/\fBcurs_trace\fR(3X)* -_traceattr/\fBcurs_trace\fR(3X)* -_traceattr2/\fBcurs_trace\fR(3X)* -_tracechar/\fBcurs_trace\fR(3X)* -_tracechtype/\fBcurs_trace\fR(3X)* -_tracechtype2/\fBcurs_trace\fR(3X)* -_tracedump/\fBcurs_trace\fR(3X)* -_tracef/\fBcurs_trace\fR(3X)* -_tracemouse/\fBcurs_trace\fR(3X)* -add_wch/\fBcurs_add_wch\fR(3X) -add_wchnstr/\fBcurs_add_wchstr\fR(3X) -add_wchstr/\fBcurs_add_wchstr\fR(3X) -addch/\fBcurs_addch\fR(3X) -addchnstr/\fBcurs_addchstr\fR(3X) -addchstr/\fBcurs_addchstr\fR(3X) -addnstr/\fBcurs_addstr\fR(3X) -addnwstr/\fBcurs_addwstr\fR(3X) -addstr/\fBcurs_addstr\fR(3X) -addwstr/\fBcurs_addwstr\fR(3X) -assume_default_colors/\fBdefault_colors\fR(3X)* -attr_get/\fBcurs_attr\fR(3X) -attr_off/\fBcurs_attr\fR(3X) -attr_on/\fBcurs_attr\fR(3X) -attr_set/\fBcurs_attr\fR(3X) -attroff/\fBcurs_attr\fR(3X) -attron/\fBcurs_attr\fR(3X) -attrset/\fBcurs_attr\fR(3X) -baudrate/\fBcurs_termattrs\fR(3X) -beep/\fBcurs_beep\fR(3X) -bkgd/\fBcurs_bkgd\fR(3X) -bkgdset/\fBcurs_bkgd\fR(3X) -bkgrnd/\fBcurs_bkgrnd\fR(3X) -bkgrndset/\fBcurs_bkgrnd\fR(3X) -border/\fBcurs_border\fR(3X) -border_set/\fBcurs_border_set\fR(3X) -box/\fBcurs_border\fR(3X) -box_set/\fBcurs_border_set\fR(3X) -can_change_color/\fBcurs_color\fR(3X) -cbreak/\fBcurs_inopts\fR(3X) -chgat/\fBcurs_attr\fR(3X) -clear/\fBcurs_clear\fR(3X) -clearok/\fBcurs_outopts\fR(3X) -clrtobot/\fBcurs_clear\fR(3X) -clrtoeol/\fBcurs_clear\fR(3X) -color_content/\fBcurs_color\fR(3X) -color_set/\fBcurs_attr\fR(3X) -copywin/\fBcurs_overlay\fR(3X) -curs_set/\fBcurs_kernel\fR(3X) -curses_version/\fBcurs_extend\fR(3X)* -def_prog_mode/\fBcurs_kernel\fR(3X) -def_shell_mode/\fBcurs_kernel\fR(3X) -define_key/\fBdefine_key\fR(3X)* -del_curterm/\fBcurs_terminfo\fR(3X) -delay_output/\fBcurs_util\fR(3X) -delch/\fBcurs_delch\fR(3X) -deleteln/\fBcurs_deleteln\fR(3X) -delscreen/\fBcurs_initscr\fR(3X) -delwin/\fBcurs_window\fR(3X) -derwin/\fBcurs_window\fR(3X) -doupdate/\fBcurs_refresh\fR(3X) -dupwin/\fBcurs_window\fR(3X) -echo/\fBcurs_inopts\fR(3X) -echo_wchar/\fBcurs_add_wch\fR(3X) -echochar/\fBcurs_addch\fR(3X) -endwin/\fBcurs_initscr\fR(3X) -erase/\fBcurs_clear\fR(3X) -erasechar/\fBcurs_termattrs\fR(3X) -erasewchar/\fBcurs_termattrs\fR(3X) -filter/\fBcurs_util\fR(3X) -flash/\fBcurs_beep\fR(3X) -flushinp/\fBcurs_util\fR(3X) -get_wch/\fBcurs_get_wch\fR(3X) -get_wstr/\fBcurs_get_wstr\fR(3X) -getbegyx/\fBcurs_getyx\fR(3X) -getbkgd/\fBcurs_bkgd\fR(3X) -getbkgrnd/\fBcurs_bkgrnd\fR(3X) -getcchar/\fBcurs_getcchar\fR(3X) -getch/\fBcurs_getch\fR(3X) -getmaxyx/\fBcurs_getyx\fR(3X) -getmouse/\fBcurs_mouse\fR(3X)* -getn_wstr/\fBcurs_get_wstr\fR(3X) -getnstr/\fBcurs_getstr\fR(3X) -getparyx/\fBcurs_getyx\fR(3X) -getstr/\fBcurs_getstr\fR(3X) -getsyx/\fBcurs_kernel\fR(3X) -getwin/\fBcurs_util\fR(3X) -getyx/\fBcurs_getyx\fR(3X) -halfdelay/\fBcurs_inopts\fR(3X) -has_colors/\fBcurs_color\fR(3X) -has_ic/\fBcurs_termattrs\fR(3X) -has_il/\fBcurs_termattrs\fR(3X) -has_key/\fBcurs_getch\fR(3X)* -hline/\fBcurs_border\fR(3X) -hline_set/\fBcurs_border_set\fR(3X) -idcok/\fBcurs_outopts\fR(3X) -idlok/\fBcurs_outopts\fR(3X) -immedok/\fBcurs_outopts\fR(3X) -in_wch/\fBcurs_in_wch\fR(3X) -in_wchnstr/\fBcurs_in_wchstr\fR(3X) -in_wchstr/\fBcurs_in_wchstr\fR(3X) -inch/\fBcurs_inch\fR(3X) -inchnstr/\fBcurs_inchstr\fR(3X) -inchstr/\fBcurs_inchstr\fR(3X) -init_color/\fBcurs_color\fR(3X) -init_pair/\fBcurs_color\fR(3X) -initscr/\fBcurs_initscr\fR(3X) -innstr/\fBcurs_instr\fR(3X) -innwstr/\fBcurs_inwstr\fR(3X) -ins_nwstr/\fBcurs_ins_wstr\fR(3X) -ins_wch/\fBcurs_ins_wch\fR(3X) -ins_wstr/\fBcurs_ins_wstr\fR(3X) -insch/\fBcurs_insch\fR(3X) -insdelln/\fBcurs_deleteln\fR(3X) -insertln/\fBcurs_deleteln\fR(3X) -insnstr/\fBcurs_insstr\fR(3X) -insstr/\fBcurs_insstr\fR(3X) -instr/\fBcurs_instr\fR(3X) -intrflush/\fBcurs_inopts\fR(3X) -inwstr/\fBcurs_inwstr\fR(3X) -is_linetouched/\fBcurs_touch\fR(3X) -is_wintouched/\fBcurs_touch\fR(3X) -isendwin/\fBcurs_initscr\fR(3X) -key_defined/\fBkey_defined\fR(3X)* -key_name/\fBcurs_util\fR(3X) -keybound/\fBkeybound\fR(3X)* -keyname/\fBcurs_util\fR(3X) -keyok/\fBkeyok\fR(3X)* -keypad/\fBcurs_inopts\fR(3X) -killchar/\fBcurs_termattrs\fR(3X) -killwchar/\fBcurs_termattrs\fR(3X) -leaveok/\fBcurs_outopts\fR(3X) -longname/\fBcurs_termattrs\fR(3X) -mcprint/\fBcurs_print\fR(3X)* -meta/\fBcurs_inopts\fR(3X) -mouse_trafo/\fBcurs_mouse\fR(3X)* -mouseinterval/\fBcurs_mouse\fR(3X)* -mousemask/\fBcurs_mouse\fR(3X)* -move/\fBcurs_move\fR(3X) -mvadd_wch/\fBcurs_add_wch\fR(3X) -mvadd_wchnstr/\fBcurs_add_wchstr\fR(3X) -mvadd_wchstr/\fBcurs_add_wchstr\fR(3X) -mvaddch/\fBcurs_addch\fR(3X) -mvaddchnstr/\fBcurs_addchstr\fR(3X) -mvaddchstr/\fBcurs_addchstr\fR(3X) -mvaddnstr/\fBcurs_addstr\fR(3X) -mvaddnwstr/\fBcurs_addwstr\fR(3X) -mvaddstr/\fBcurs_addstr\fR(3X) -mvaddwstr/\fBcurs_addwstr\fR(3X) -mvchgat/\fBcurs_attr\fR(3X) -mvcur/\fBcurs_terminfo\fR(3X) -mvdelch/\fBcurs_delch\fR(3X) -mvderwin/\fBcurs_window\fR(3X) -mvget_wch/\fBcurs_get_wch\fR(3X) -mvget_wstr/\fBcurs_get_wstr\fR(3X) -mvgetch/\fBcurs_getch\fR(3X) -mvgetn_wstr/\fBcurs_get_wstr\fR(3X) -mvgetnstr/\fBcurs_getstr\fR(3X) -mvgetstr/\fBcurs_getstr\fR(3X) -mvhline/\fBcurs_border\fR(3X) -mvhline_set/\fBcurs_border_set\fR(3X) -mvin_wch/\fBcurs_in_wch\fR(3X) -mvin_wchnstr/\fBcurs_in_wchstr\fR(3X) -mvin_wchstr/\fBcurs_in_wchstr\fR(3X) -mvinch/\fBcurs_inch\fR(3X) -mvinchnstr/\fBcurs_inchstr\fR(3X) -mvinchstr/\fBcurs_inchstr\fR(3X) -mvinnstr/\fBcurs_instr\fR(3X) -mvinnwstr/\fBcurs_inwstr\fR(3X) -mvins_nwstr/\fBcurs_ins_wstr\fR(3X) -mvins_wch/\fBcurs_ins_wch\fR(3X) -mvins_wstr/\fBcurs_ins_wstr\fR(3X) -mvinsch/\fBcurs_insch\fR(3X) -mvinsnstr/\fBcurs_insstr\fR(3X) -mvinsstr/\fBcurs_insstr\fR(3X) -mvinstr/\fBcurs_instr\fR(3X) -mvinwstr/\fBcurs_inwstr\fR(3X) -mvprintw/\fBcurs_printw\fR(3X) -mvscanw/\fBcurs_scanw\fR(3X) -mvvline/\fBcurs_border\fR(3X) -mvvline_set/\fBcurs_border_set\fR(3X) -mvwadd_wch/\fBcurs_add_wch\fR(3X) -mvwadd_wchnstr/\fBcurs_add_wchstr\fR(3X) -mvwadd_wchstr/\fBcurs_add_wchstr\fR(3X) -mvwaddch/\fBcurs_addch\fR(3X) -mvwaddchnstr/\fBcurs_addchstr\fR(3X) -mvwaddchstr/\fBcurs_addchstr\fR(3X) -mvwaddnstr/\fBcurs_addstr\fR(3X) -mvwaddnwstr/\fBcurs_addwstr\fR(3X) -mvwaddstr/\fBcurs_addstr\fR(3X) -mvwaddwstr/\fBcurs_addwstr\fR(3X) -mvwchgat/\fBcurs_attr\fR(3X) -mvwdelch/\fBcurs_delch\fR(3X) -mvwget_wch/\fBcurs_get_wch\fR(3X) -mvwget_wstr/\fBcurs_get_wstr\fR(3X) -mvwgetch/\fBcurs_getch\fR(3X) -mvwgetn_wstr/\fBcurs_get_wstr\fR(3X) -mvwgetnstr/\fBcurs_getstr\fR(3X) -mvwgetstr/\fBcurs_getstr\fR(3X) -mvwhline/\fBcurs_border\fR(3X) -mvwhline_set/\fBcurs_border_set\fR(3X) -mvwin/\fBcurs_window\fR(3X) -mvwin_wch/\fBcurs_in_wch\fR(3X) -mvwin_wchnstr/\fBcurs_in_wchstr\fR(3X) -mvwin_wchstr/\fBcurs_in_wchstr\fR(3X) -mvwinch/\fBcurs_inch\fR(3X) -mvwinchnstr/\fBcurs_inchstr\fR(3X) -mvwinchstr/\fBcurs_inchstr\fR(3X) -mvwinnstr/\fBcurs_instr\fR(3X) -mvwinnwstr/\fBcurs_inwstr\fR(3X) -mvwins_nwstr/\fBcurs_ins_wstr\fR(3X) -mvwins_wch/\fBcurs_ins_wch\fR(3X) -mvwins_wstr/\fBcurs_ins_wstr\fR(3X) -mvwinsch/\fBcurs_insch\fR(3X) -mvwinsnstr/\fBcurs_insstr\fR(3X) -mvwinsstr/\fBcurs_insstr\fR(3X) -mvwinstr/\fBcurs_instr\fR(3X) -mvwinwstr/\fBcurs_inwstr\fR(3X) -mvwprintw/\fBcurs_printw\fR(3X) -mvwscanw/\fBcurs_scanw\fR(3X) -mvwvline/\fBcurs_border\fR(3X) -mvwvline_set/\fBcurs_border_set\fR(3X) -napms/\fBcurs_kernel\fR(3X) -newpad/\fBcurs_pad\fR(3X) -newterm/\fBcurs_initscr\fR(3X) -newwin/\fBcurs_window\fR(3X) -nl/\fBcurs_outopts\fR(3X) -nocbreak/\fBcurs_inopts\fR(3X) -nodelay/\fBcurs_inopts\fR(3X) -noecho/\fBcurs_inopts\fR(3X) -nonl/\fBcurs_outopts\fR(3X) -noqiflush/\fBcurs_inopts\fR(3X) -noraw/\fBcurs_inopts\fR(3X) -notimeout/\fBcurs_inopts\fR(3X) -overlay/\fBcurs_overlay\fR(3X) -overwrite/\fBcurs_overlay\fR(3X) -pair_content/\fBcurs_color\fR(3X) -pechochar/\fBcurs_pad\fR(3X) -pnoutrefresh/\fBcurs_pad\fR(3X) -prefresh/\fBcurs_pad\fR(3X) -printw/\fBcurs_printw\fR(3X) -putp/\fBcurs_terminfo\fR(3X) -putwin/\fBcurs_util\fR(3X) -qiflush/\fBcurs_inopts\fR(3X) -raw/\fBcurs_inopts\fR(3X) -redrawwin/\fBcurs_refresh\fR(3X) -refresh/\fBcurs_refresh\fR(3X) -reset_prog_mode/\fBcurs_kernel\fR(3X) -reset_shell_mode/\fBcurs_kernel\fR(3X) -resetty/\fBcurs_kernel\fR(3X) -resizeterm/\fBresizeterm\fR(3X)* -restartterm/\fBcurs_terminfo\fR(3X) -ripoffline/\fBcurs_kernel\fR(3X) -savetty/\fBcurs_kernel\fR(3X) -scanw/\fBcurs_scanw\fR(3X) -scr_dump/\fBcurs_scr_dump\fR(3X) -scr_init/\fBcurs_scr_dump\fR(3X) -scr_restore/\fBcurs_scr_dump\fR(3X) -scr_set/\fBcurs_scr_dump\fR(3X) -scrl/\fBcurs_scroll\fR(3X) -scroll/\fBcurs_scroll\fR(3X) -scrollok/\fBcurs_outopts\fR(3X) -set_curterm/\fBcurs_terminfo\fR(3X) -set_term/\fBcurs_initscr\fR(3X) -setcchar/\fBcurs_getcchar\fR(3X) -setscrreg/\fBcurs_outopts\fR(3X) -setsyx/\fBcurs_kernel\fR(3X) -setterm/\fBcurs_terminfo\fR(3X) -setupterm/\fBcurs_terminfo\fR(3X) -slk_attr/\fBcurs_slk\fR(3X)* -slk_attr_off/\fBcurs_slk\fR(3X) -slk_attr_on/\fBcurs_slk\fR(3X) -slk_attr_set/\fBcurs_slk\fR(3X) -slk_attroff/\fBcurs_slk\fR(3X) -slk_attron/\fBcurs_slk\fR(3X) -slk_attrset/\fBcurs_slk\fR(3X) -slk_clear/\fBcurs_slk\fR(3X) -slk_color/\fBcurs_slk\fR(3X) -slk_init/\fBcurs_slk\fR(3X) -slk_label/\fBcurs_slk\fR(3X) -slk_noutrefresh/\fBcurs_slk\fR(3X) -slk_refresh/\fBcurs_slk\fR(3X) -slk_restore/\fBcurs_slk\fR(3X) -slk_set/\fBcurs_slk\fR(3X) -slk_touch/\fBcurs_slk\fR(3X) -standend/\fBcurs_attr\fR(3X) -standout/\fBcurs_attr\fR(3X) -start_color/\fBcurs_color\fR(3X) -subpad/\fBcurs_pad\fR(3X) -subwin/\fBcurs_window\fR(3X) -syncok/\fBcurs_window\fR(3X) -term_attrs/\fBcurs_termattrs\fR(3X) -termattrs/\fBcurs_termattrs\fR(3X) -termname/\fBcurs_termattrs\fR(3X) -tgetent/\fBcurs_termcap\fR(3X) -tgetflag/\fBcurs_termcap\fR(3X) -tgetnum/\fBcurs_termcap\fR(3X) -tgetstr/\fBcurs_termcap\fR(3X) -tgoto/\fBcurs_termcap\fR(3X) -tigetflag/\fBcurs_terminfo\fR(3X) -tigetnum/\fBcurs_terminfo\fR(3X) -tigetstr/\fBcurs_terminfo\fR(3X) -timeout/\fBcurs_inopts\fR(3X) -touchline/\fBcurs_touch\fR(3X) -touchwin/\fBcurs_touch\fR(3X) -tparm/\fBcurs_terminfo\fR(3X) -tputs/\fBcurs_termcap\fR(3X) -tputs/\fBcurs_terminfo\fR(3X) -trace/\fBcurs_trace\fR(3X)* -typeahead/\fBcurs_inopts\fR(3X) -unctrl/\fBcurs_util\fR(3X) -unget_wch/\fBcurs_get_wch\fR(3X) -ungetch/\fBcurs_getch\fR(3X) -ungetmouse/\fBcurs_mouse\fR(3X)* -untouchwin/\fBcurs_touch\fR(3X) -use_default_colors/\fBdefault_colors\fR(3X)* -use_env/\fBcurs_util\fR(3X) -use_extended_names/\fBcurs_extend\fR(3X)* -vid_attr/\fBcurs_terminfo\fR(3X) -vid_puts/\fBcurs_terminfo\fR(3X) -vidattr/\fBcurs_terminfo\fR(3X) -vidputs/\fBcurs_terminfo\fR(3X) -vline/\fBcurs_border\fR(3X) -vline_set/\fBcurs_border_set\fR(3X) -vw_printw/\fBcurs_printw\fR(3X) -vw_scanw/\fBcurs_scanw\fR(3X) -vwprintw/\fBcurs_printw\fR(3X) -vwscanw/\fBcurs_scanw\fR(3X) -wadd_wch/\fBcurs_add_wch\fR(3X) -wadd_wchnstr/\fBcurs_add_wchstr\fR(3X) -wadd_wchstr/\fBcurs_add_wchstr\fR(3X) -waddch/\fBcurs_addch\fR(3X) -waddchnstr/\fBcurs_addchstr\fR(3X) -waddchstr/\fBcurs_addchstr\fR(3X) -waddnstr/\fBcurs_addstr\fR(3X) -waddnwstr/\fBcurs_addwstr\fR(3X) -waddstr/\fBcurs_addstr\fR(3X) -waddwstr/\fBcurs_addwstr\fR(3X) -wattr_get/\fBcurs_attr\fR(3X) -wattr_off/\fBcurs_attr\fR(3X) -wattr_on/\fBcurs_attr\fR(3X) -wattr_set/\fBcurs_attr\fR(3X) -wattroff/\fBcurs_attr\fR(3X) -wattron/\fBcurs_attr\fR(3X) -wattrset/\fBcurs_attr\fR(3X) -wbkgd/\fBcurs_bkgd\fR(3X) -wbkgdset/\fBcurs_bkgd\fR(3X) -wbkgrnd/\fBcurs_bkgrnd\fR(3X) -wbkgrndset/\fBcurs_bkgrnd\fR(3X) -wborder/\fBcurs_border\fR(3X) -wborder_set/\fBcurs_border_set\fR(3X) -wchgat/\fBcurs_attr\fR(3X) -wclear/\fBcurs_clear\fR(3X) -wclrtobot/\fBcurs_clear\fR(3X) -wclrtoeol/\fBcurs_clear\fR(3X) -wcolor_set/\fBcurs_attr\fR(3X) -wcursyncup/\fBcurs_window\fR(3X) -wdelch/\fBcurs_delch\fR(3X) -wdeleteln/\fBcurs_deleteln\fR(3X) -wecho_wchar/\fBcurs_add_wch\fR(3X) -wechochar/\fBcurs_addch\fR(3X) -wenclose/\fBcurs_mouse\fR(3X)* -werase/\fBcurs_clear\fR(3X) -wget_wch/\fBcurs_get_wch\fR(3X) -wget_wstr/\fBcurs_get_wstr\fR(3X) -wgetbkgrnd/\fBcurs_bkgrnd\fR(3X) -wgetch/\fBcurs_getch\fR(3X) -wgetn_wstr/\fBcurs_get_wstr\fR(3X) -wgetnstr/\fBcurs_getstr\fR(3X) -wgetstr/\fBcurs_getstr\fR(3X) -whline/\fBcurs_border\fR(3X) -whline_set/\fBcurs_border_set\fR(3X) -win_wch/\fBcurs_in_wch\fR(3X) -win_wchnstr/\fBcurs_in_wchstr\fR(3X) -win_wchstr/\fBcurs_in_wchstr\fR(3X) -winch/\fBcurs_inch\fR(3X) -winchnstr/\fBcurs_inchstr\fR(3X) -winchstr/\fBcurs_inchstr\fR(3X) -winnstr/\fBcurs_instr\fR(3X) -winnwstr/\fBcurs_inwstr\fR(3X) -wins_nwstr/\fBcurs_ins_wstr\fR(3X) -wins_wch/\fBcurs_ins_wch\fR(3X) -wins_wstr/\fBcurs_ins_wstr\fR(3X) -winsch/\fBcurs_insch\fR(3X) -winsdelln/\fBcurs_deleteln\fR(3X) -winsertln/\fBcurs_deleteln\fR(3X) -winsnstr/\fBcurs_insstr\fR(3X) -winsstr/\fBcurs_insstr\fR(3X) -winstr/\fBcurs_instr\fR(3X) -winwstr/\fBcurs_inwstr\fR(3X) -wmouse_trafo/\fBcurs_mouse\fR(3X)* -wmove/\fBcurs_move\fR(3X) -wnoutrefresh/\fBcurs_refresh\fR(3X) -wprintw/\fBcurs_printw\fR(3X) -wredrawln/\fBcurs_refresh\fR(3X) -wrefresh/\fBcurs_refresh\fR(3X) -wresize/\fBwresize\fR(3X)* -wscanw/\fBcurs_scanw\fR(3X) -wscrl/\fBcurs_scroll\fR(3X) -wsetscrreg/\fBcurs_outopts\fR(3X) -wstandend/\fBcurs_attr\fR(3X) -wstandout/\fBcurs_attr\fR(3X) -wsyncdown/\fBcurs_window\fR(3X) -wsyncup/\fBcurs_window\fR(3X) -wtimeout/\fBcurs_inopts\fR(3X) -wtouchln/\fBcurs_touch\fR(3X) -wunctrl/\fBcurs_util\fR(3X) -wvline/\fBcurs_border\fR(3X) -wvline_set/\fBcurs_border_set\fR(3X) -.TE -.SH RETURN VALUE -Routines that return an integer return \fBERR\fR upon failure and an -integer value other than \fBERR\fR upon successful completion, unless -otherwise noted in the routine descriptions. -.PP -All macros return the value of the \fBw\fR version, except \fBsetscrreg\fR, -\fBwsetscrreg\fR, \fBgetyx\fR, \fBgetbegyx\fR, and \fBgetmaxyx\fR. The return -values of \fBsetscrreg\fR, \fBwsetscrreg\fR, \fBgetyx\fR, \fBgetbegyx\fR, and -\fBgetmaxyx\fR are undefined (i.e., these should not be used as the -right-hand side of assignment statements). -.PP -Routines that return pointers return \fBNULL\fR on error. -.SH ENVIRONMENT -The following environment symbols are useful for customizing the -runtime behavior of the \fBncurses\fR library. The most important -ones have been already discussed in detail. -.TP 5 -BAUDRATE -The debugging library checks this environment symbol when the application -has redirected output to a file. -The symbol's numeric value is used for the baudrate. -If no value is found, \fBncurses\fR uses 9600. -This allows testers to construct repeatable test-cases -that take into account costs that depend on baudrate. -.TP 5 -CC -When set, change occurrences of the command_character -(i.e., the \fBcmdch\fP capability) -of the loaded terminfo entries to the value of this symbol. -Very few terminfo entries provide this feature. -.TP 5 -COLUMNS -Specify the width of the screen in characters. -Applications running in a windowing environment usually are able to -obtain the width of the window in which they are executing. -If neither the $COLUMNS value nor the terminal's screen size is available, -\fBncurses\fR uses the size which may be specified in the terminfo database -(i.e., the \fBcols\fR capability). -.IP -It is important that your application use a correct size for the screen. -However, this is not always possible because your application may be -running on a host which does not honor NAWS (Negotiations About Window -Size), or because you are temporarily running as another user. -.IP -Either COLUMNS or LINES symbols may be specified independently. -This is mainly useful to circumvent legacy misfeatures of terminal descriptions, -e.g., xterm which commonly specifies a 65 line screen. -For best results, \fBlines\fR and \fBcols\fR should not be specified in -a terminal description for terminals which are run as emulations. -.IP -Use the \fBuse_env\fR function to disable this feature. -.TP 5 -ESCDELAY -Specifies the total time, in milliseconds, for which ncurses will -await a character sequence, e.g., a function key. -The default value, 1000 milliseconds, is enough for most uses. -However, it is made a variable to accommodate unusual applications. -.IP -The most common instance where you may wish to change this value -is to work with slow hosts, e.g., running on a network. -If the host cannot read characters rapidly enough, it will have the same -effect as if the terminal did not send characters rapidly enough. -The library will still see a timeout. -.IP -Note that xterm mouse events are built up from character sequences -received from the xterm. -If your application makes heavy use of multiple-clicking, you may -wish to lengthen this default value because the timeout applies -to the composed multi-click event as well as the individual clicks. -.TP 5 -HOME -Tells \fBncurses\fR where your home directory is. -That is where it may read and write auxiliary terminal descriptions: -.IP -$HOME/.termcap -.br -$HOME/.terminfo -.TP 5 -LINES -Like COLUMNS, specify the height of the screen in characters. -See COLUMNS for a detailed description. -.TP 5 -MOUSE_BUTTONS_123 -This applies only to the OS/2 EMX port. -It specifies the order of buttons on the mouse. -OS/2 numbers a 3-button mouse inconsistently from other -platforms: -.sp -1 = left -.br -2 = right -.br -3 = middle. -.sp -This symbol lets you customize the mouse. -The symbol must be three numeric digits 1-3 in any order, e.g., 123 or 321. -If it is not specified, \fBncurses\fR uses 132. -.TP 5 -NCURSES_ASSUMED_COLORS -Override the compiled-in assumption that the -terminal's default colors are white-on-black -(see \fBassume_default_colors\fR(3X)). -You may set the foreground and background color values with this environment -variable by proving a 2-element list: foreground,background. -For example, to tell ncurses to not assume anything -about the colors, set this to "-1,-1". -To make it green-on-black, set it to "2,0". -Any positive value from zero to the terminfo \fBmax_colors\fR value is allowed. -.TP 5 -NCURSES_NO_PADDING -Most of the terminal descriptions in the terminfo database are written -for real "hardware" terminals. -Many people use terminal emulators -which run in a windowing environment and use curses-based applications. -Terminal emulators can duplicate -all of the important aspects of a hardware terminal, but they do not -have the same limitations. -The chief limitation of a hardware terminal from the standpoint -of your application is the management of dataflow, i.e., timing. -Unless a hardware terminal is interfaced into a terminal concentrator -(which does flow control), -it (or your application) must manage dataflow, preventing overruns. -The cheapest solution (no hardware cost) -is for your program to do this by pausing after -operations that the terminal does slowly, such as clearing the display. -.IP -As a result, many terminal descriptions (including the vt100) -have delay times embedded. You may wish to use these descriptions, -but not want to pay the performance penalty. -.IP -Set the NCURSES_NO_PADDING symbol to disable all but mandatory -padding. Mandatory padding is used as a part of special control -sequences such as \fIflash\fR. -.TP 5 -NCURSES_NO_SETBUF -Normally \fBncurses\fR enables buffered output during terminal initialization. -This is done (as in SVr4 curses) for performance reasons. -For testing purposes, both of \fBncurses\fR and certain applications, -this feature is made optional. Setting the NCURSES_NO_SETBUF variable -disables output buffering, leaving the output in the original (usually -line buffered) mode. -.TP 5 -NCURSES_TRACE -During initialization, the \fBncurses\fR debugging library -checks the NCURSES_TRACE symbol. -If it is defined, to a numeric value, \fBncurses\fR calls the \fBtrace\fR -function, using that value as the argument. -.IP -The argument values, which are defined in \fBcurses.h\fR, provide several -types of information. -When running with traces enabled, your application will write the -file \fBtrace\fR to the current directory. -.TP 5 -TERM -Denotes your terminal type. -Each terminal type is distinct, though many are similar. -.TP 5 -TERMCAP -If the \fBncurses\fR library has been configured with \fItermcap\fR -support, \fBncurses\fR will check for a terminal's description in -termcap form if it is not available in the terminfo database. -.IP -The TERMCAP symbol contains either a terminal description (with -newlines stripped out), -or a file name telling where the information denoted by the TERM symbol exists. -In either case, setting it directs \fBncurses\fR to ignore -the usual place for this information, e.g., /etc/termcap. -.TP 5 -TERMINFO -Overrides the directory in which \fBncurses\fR searches for your terminal -description. -This is the simplest, but not the only way to change the list of directories. -The complete list of directories in order follows: -.RS -.TP 3 -- -the last directory to which \fBncurses\fR wrote, if any, is searched first -.TP 3 -- -the directory specified by the TERMINFO symbol -.TP 3 -- -$HOME/.terminfo -.TP 3 -- -directories listed in the TERMINFO_DIRS symbol -.TP 3 -- -one or more directories whose names are configured and compiled into the -ncurses library, e.g., -@TERMINFO@ -.RE -.TP 5 -TERMINFO_DIRS -Specifies a list of directories to search for terminal descriptions. -The list is separated by colons (i.e., ":") on Unix, semicolons on OS/2 EMX. -All of the terminal descriptions are in terminfo form, which makes -a subdirectory named for the first letter of the terminal names therein. -.TP 5 -TERMPATH -If TERMCAP does not hold a file name then \fBncurses\fR checks -the TERMPATH symbol. -This is a list of filenames separated by spaces or colons (i.e., ":") on Unix, semicolons on OS/2 EMX. -If the TERMPATH symbol is not set, \fBncurses\fR looks in the files -/etc/termcap, /usr/share/misc/termcap and $HOME/.termcap, in that order. -.PP -The library may be configured to disregard the following variables when the -current user is the superuser (root), or if the application uses setuid or -setgid permissions: -$TERMINFO, $TERMINFO_DIRS, $TERMPATH, as well as $HOME. -.SH FILES -.TP 5 -@DATADIR@/tabset -directory containing initialization files for the terminal capability database -@TERMINFO@ -terminal capability database -.SH SEE ALSO -\fBterminfo\fR(\*n) and related pages whose names begin "curs_" for detailed routine -descriptions. -.SH EXTENSIONS -The \fBncurses\fR library can be compiled with an option (\fB\-DUSE_GETCAP\fR) -that falls back to the old-style /etc/termcap file if the terminal setup code -cannot find a terminfo entry corresponding to \fBTERM\fR. Use of this feature -is not recommended, as it essentially includes an entire termcap compiler in -the \fBncurses\fR startup code, at significant cost in core and startup cycles. -.PP -The \fBncurses\fR library includes facilities for capturing mouse events on -certain terminals (including xterm). See the \fBcurs_mouse\fR(3X) -manual page for details. -.PP -The \fBncurses\fR library includes facilities for responding to window -resizing events, e.g., when running in an xterm. -See the \fBresizeterm\fR(3X) -and \fBwresize\fR(3X) manual pages for details. -In addition, the library may be configured with a SIGWINCH handler. -.PP -The \fBncurses\fR library extends the fixed set of function key capabilities -of terminals by allowing the application designer to define additional -key sequences at runtime. -See the \fBdefine_key\fR(3X) -\fBkey_defined\fR(3X), -and \fBkeyok\fR(3X) manual pages for details. -.PP -The \fBncurses\fR library can exploit the capabilities of terminals which -implement the ISO-6429 SGR 39 and SGR 49 controls, which allow an application -to reset the terminal to its original foreground and background colors. -From the users' perspective, the application is able to draw colored -text on a background whose color is set independently, providing better -control over color contrasts. -See the \fBdefault_colors\fR(3X) manual page for details. -.PP -The \fBncurses\fR library includes a function for directing application output -to a printer attached to the terminal device. See the \fBcurs_print\fR(3X) -manual page for details. -.SH PORTABILITY -The \fBncurses\fR library is intended to be BASE-level conformant with the XSI -Curses standard. The EXTENDED XSI Curses functionality -(including color support) is supported. -.PP -A small number of local differences (that is, individual differences between -the XSI Curses and \fBncurses\fR calls) are described in \fBPORTABILITY\fR -sections of the library man pages. -.PP -The routine \fBhas_key\fR is not part of XPG4, nor is it present in SVr4. See -the \fBcurs_getch\fR(3X) manual page for details. -.PP -The routine \fBslk_attr\fR is not part of XPG4, nor is it present in SVr4. See -the \fBcurs_slk\fR(3X) manual page for details. -.PP -The routines \fBgetmouse\fR, \fBmousemask\fR, \fBungetmouse\fR, -\fBmouseinterval\fR, and \fBwenclose\fR relating to mouse interfacing are not -part of XPG4, nor are they present in SVr4. See the \fBcurs_mouse\fR(3X) -manual page for details. -.PP -The routine \fBmcprint\fR was not present in any previous curses -implementation. See the \fBcurs_print\fR(3X) manual page for details. -.PP -The routine \fBwresize\fR is not part of XPG4, nor is it present in SVr4. See -the \fBwresize\fR(3X) manual page for details. -.PP -In historic curses versions, delays embedded in the capabilities \fBcr\fR, -\fBind\fR, \fBcub1\fR, \fBff\fR and \fBtab\fR activated corresponding delay -bits in the UNIX tty driver. In this implementation, all padding is done by -NUL sends. This method is slightly more expensive, but narrows the interface -to the UNIX kernel significantly and increases the package's portability -correspondingly. -.SH NOTES -The header file \fB\fR automatically includes the header files -\fB\fR and \fB\fR. -.PP -If standard output from a \fBncurses\fR program is re-directed to something -which is not a tty, screen updates will be directed to standard error. This -was an undocumented feature of AT&T System V Release 3 curses. -.SH AUTHORS -Zeyd M. Ben-Halim, Eric S. Raymond, Thomas E. Dickey. -Based on pcurses by Pavel Curtis. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/panel.3x b/contrib/ncurses-5.4/man/panel.3x deleted file mode 100644 index 800ad32ee1..0000000000 --- a/contrib/ncurses-5.4/man/panel.3x +++ /dev/null @@ -1,182 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: panel.3x,v 1.11 2003/05/17 22:44:09 jmc Exp $ -.TH panel 3X "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -panel - panel stack extension for curses -.SH SYNOPSIS -\fB#include \fR -.P -\fBcc [flags] sourcefiles -lpanel -lncurses\fR -.P -\fBPANEL *new_panel(WINDOW *win)\fR -.br -\fBint bottom_panel(PANEL *pan)\fR -.br -\fBint top_panel(PANEL *pan)\fR -.br -\fBint show_panel(PANEL *pan)\fR -.br -\fBvoid update_panels();\fR -.br -\fBint hide_panel(PANEL *pan)\fR -.br -\fBWINDOW *panel_window(const PANEL *pan)\fR -.br -\fBint replace_panel(PANEL *pan, WINDOW *window)\fR -.br -\fBint move_panel(PANEL *pan, int starty, int startx)\fR -.br -\fBint panel_hidden(const PANEL *pan)\fR -.br -\fBPANEL *panel_above(const PANEL *pan)\fR -.br -\fBPANEL *panel_below(const PANEL *pan)\fR -.br -\fBint set_panel_userptr(PANEL *pan, const void *ptr)\fR -.br -\fBconst void *panel_userptr(const PANEL *pan)\fR -.br -\fBint del_panel(PANEL *pan)\fR -.br -.SH DESCRIPTION -Panels are \fBcurses\fR(3X) windows with the added feature of -depth. Panel functions allow the use of stacked windows and ensure -the proper portions of each window and the curses \fBstdscr\fR window are -hidden or displayed when panels are added, moved, modified or removed. -The set of currently visible panels is the stack of panels. The -\fBstdscr\fR window is beneath all panels, and is not considered part -of the stack. -.P -A window is associated with every panel. The panel routines enable -you to create, move, hide, and show panels, as well as position a -panel at any desired location in the stack. -.P -Panel routines are a functional layer added to \fBcurses\fR(3X), make only -high-level curses calls, and work anywhere terminfo curses does. -.SH FUNCTIONS -.TP -\fBnew_panel(win)\fR -allocates a \fBPANEL\fR structure, associates it with -\fBwin\fR, places the panel on the top of the stack (causes it -to be displayed above any other panel) and returns a -pointer to the new panel. -.TP -\fBvoid update_panels()\fR -refreshes the virtual screen to reflect the relations between the -panels in the stack, but does not call doupdate() to refresh the -physical screen. Use this function and not wrefresh or wnoutrefresh. -update_panels() may be called more than once before a call to -doupdate(), but doupdate() is the function responsible for updating -the physical screen. -.TP -\fBdel_panel(pan)\fR -removes the given panel from the stack and deallocates the -\fBPANEL\fR structure (but not its associated window). -.TP -\fBhide_panel(pan)\fR -removes the given panel from the panel stack and thus hides it from -view. The \fBPANEL\fR structure is not lost, merely removed from the stack. -.TP -\fBshow_panel(pan)\fR -makes a hidden panel visible by placing it on top of the panels in the -panel stack. See COMPATIBILITY below. -.TP -\fBtop_panel(pan)\fR -puts the given visible panel on top of all panels in the stack. See -COMPATIBILITY below. -.TP -\fBbottom_panel(pan)\fR -puts panel at the bottom of all panels. -.TP -\fBmove_panel(pan,starty,startx)\fR -moves the given panel window so that its upper-left corner is at -\fBstarty\fR, \fBstartx\fR. It does not change the position of the -panel in the stack. Be sure to use this function, not \fBmvwin()\fR, -to move a panel window. -.TP -\fBreplace_panel(pan,window)\fR -replaces the current window of panel with \fBwindow\fR (useful, for -example if you want to resize a panel; if you're using \fBncurses\fR, -you can call \fBreplace_panel\fR on the output of \fBwresize\fR(3X)). -It does not change the position of the panel in the stack. -.TP -\fBpanel_above(pan)\fR -returns a pointer to the panel above pan. If the panel argument is -\fB(PANEL *)0\fR, it returns a pointer to the bottom panel in the stack. -.TP -\fBpanel_below(pan)\fR -returns a pointer to the panel just below pan. If the panel argument -is \fB(PANEL *)0\fR, it returns a pointer to the top panel in the stack. -.TP -\fBset_panel_userptr(pan,ptr)\fR -sets the panel's user pointer. -.TP -\fBpanel_userptr(pan)\fR -returns the user pointer for a given panel. -.TP -\fBpanel_window(pan)\fR -returns a pointer to the window of the given panel. -.SH DIAGNOSTICS -Each routine that returns a pointer returns \fBNULL\fR if an error -occurs. Each routine that returns an int value returns \fBOK\fR if it -executes successfully and \fBERR\fR if not. -.SH COMPATIBILITY -Reasonable care has been taken to ensure compatibility -with the native panel facility introduced in SVr3.2 (inspection of -the SVr4 manual pages suggests the programming interface is unchanged). -The \fBPANEL\fR data structures are merely similar. The programmer -is cautioned not to directly use \fBPANEL\fR fields. -.P -The functions \fBshow_panel()\fR and \fBtop_panel()\fR are identical -in this implementation, and work equally well with displayed or hidden -panels. In the native System V implementation, \fBshow_panel()\fR is -intended for making a hidden panel visible (at the top of the stack) -and \fBtop_panel()\fR is intended for making an already-visible panel -move to the top of the stack. You are cautioned to use the correct -function to ensure compatibility with native panel libraries. -.SH NOTE -In your library list, libpanel.a should be before libncurses.a; that is, -you want to say `-lpanel -lncurses', not the other way around (which would -give you a link error using GNU \fBld\fR(1) and some other linkers). -.SH FILES -.P -panel.h -interface for the panels library -.P -libpanel.a -the panels library itself -.SH SEE ALSO -\fBcurses\fR(3X) -.SH AUTHOR -Originally written by Warren Tucker , -primarily to assist in porting u386mon to systems without a native -panels library. Repackaged for ncurses by Zeyd ben-Halim. diff --git a/contrib/ncurses-5.4/man/resizeterm.3x b/contrib/ncurses-5.4/man/resizeterm.3x deleted file mode 100644 index da5d84df74..0000000000 --- a/contrib/ncurses-5.4/man/resizeterm.3x +++ /dev/null @@ -1,92 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1996,1997,2002 -.\" -.\" $Id: resizeterm.3x,v 1.10 2003/10/25 20:41:08 tom Exp $ -.TH resizeterm 3X "" -.SH NAME -\fBis_term_resized\fR, -\fBresize_term\fR, -\fBresizeterm\fR - change the curses terminal size -.SH SYNOPSIS -\fB#include \fR - -\fBbool is_term_resized(int lines, int columns);\fR -.br -\fBint resize_term(int lines, int columns);\fR -.br -\fBint resizeterm(int lines, int columns);\fR -.SH DESCRIPTION -This is an extension to the curses library. -It provides callers with a hook into the \fBncurses\fR data to resize windows, -primarily for use by programs running in an X Window terminal (e.g., xterm). -The function \fBresizeterm\fR resizes the standard and current windows -to the specified dimensions, and adjusts other bookkeeping data used by -the \fBncurses\fR library that record the window dimensions. - -Most of the work is done by the inner function \fBresize_term\fR. -The outer function \fBresizeterm\fR adds bookkeeping for the SIGWINCH handler. -When resizing the windows, -\fBresize_term\fR blank-fills the areas that are extended. -The calling application should fill in these areas with appropriate data. -The \fBresize_term\fR function attempts to resize all windows. -However, due to the calling convention of pads, -it is not possible to resize these -without additional interaction with the application. - -A support function \fBis_term_resized\fR is provided so that applications -can check if the \fBresize_term\fR function would modify the window structures. -It returns TRUE if the windows would be modified, and FALSE otherwise. -.SH RETURN VALUE -Except as notes, these function return -the integer \fBERR\fR upon failure and \fBOK\fR on success. -They will fail if either of the dimensions are less than or equal to zero, -or if an error occurs while (re)allocating memory for the windows. -.SH NOTES -While these functions are intended to be used to support a signal handler -(i.e., for SIGWINCH), care should be taken to avoid invoking them in a -context where \fBmalloc\fR or \fBrealloc\fR may have been interrupted, -since it uses those functions. -.PP -If ncurses is configured to supply its own SIGWINCH handler, -the \fBresizeterm\fR function ungetch's a \fBKEY_RESIZE\fR which -will be read on the next call to \fBgetch\fR. -This is used to alert an application that the screen size has changed, -and that it should repaint special features such as pads that cannot -be done automatically. -.SH SEE ALSO -\fBwresize\fR(3X). -.SH AUTHOR -Thomas Dickey (from an equivalent function written in 1988 for BSD curses). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/term.5 b/contrib/ncurses-5.4/man/term.5 deleted file mode 100644 index 94b6df5111..0000000000 --- a/contrib/ncurses-5.4/man/term.5 +++ /dev/null @@ -1,208 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: term.5,v 1.15 2003/05/10 20:33:49 jmc Exp $ -.TH TERM 5 -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -term \- format of compiled term file. -.SH SYNOPSIS -.B term -.SH DESCRIPTION -.PP -Compiled terminfo descriptions are placed under the directory \fB\*d\fP. -In order to avoid a linear search of a huge \s-1UNIX\s+1 system directory, a -two-level scheme is used: \fB\*d/c/name\fP -where -.I name -is the name of the terminal, and -.I c -is the first character of -.IR name . -Thus, -.I act4 -can be found in the file \fB\*d/a/act4\fP. -Synonyms for the same terminal are implemented by multiple -links to the same compiled file. -.PP -The format has been chosen so that it will be the same on all hardware. -An 8 or more bit byte is assumed, but no assumptions about byte ordering -or sign extension are made. -.PP -The compiled file is created with the -.I tic -program, and read by the routine -.IR setupterm . -The file is divided into six parts: -the header, -terminal names, -boolean flags, -numbers, -strings, -and -string table. -.PP -The header section begins the file. -This section contains six short integers in the format -described below. -These integers are -(1) the magic number (octal 0432); -(2) the size, in bytes, of the names section; -(3) the number of bytes in the boolean section; -(4) the number of short integers in the numbers section; -(5) the number of offsets (short integers) in the strings section; -(6) the size, in bytes, of the string table. -.PP -Short integers are stored in two 8-bit bytes. -The first byte contains the least significant 8 bits of the value, -and the second byte contains the most significant 8 bits. -(Thus, the value represented is 256*second+first.) -The value \-1 is represented by the two bytes 0377, 0377; other negative -values are illegal. This value generally -means that the corresponding capability is missing from this terminal. -Note that this format corresponds to the hardware of the \s-1VAX\s+1 -and \s-1PDP\s+1-11 (that is, little-endian machines). -Machines where this does not correspond to the hardware must read the -integers as two bytes and compute the little-endian value. -.PP -The terminal names section comes next. -It contains the first line of the terminfo description, -listing the various names for the terminal, -separated by the `|' character. -The section is terminated with an \s-1ASCII NUL\s+1 character. -.PP -The boolean flags have one byte for each flag. -This byte is either 0 or 1 as the flag is present or absent. -The capabilities are in the same order as the file . -.PP -Between the boolean section and the number section, -a null byte will be inserted, if necessary, -to ensure that the number section begins on an even byte (this is a -relic of the PDP-11's word-addressed architecture, originally -designed in to avoid IOT traps induced by addressing a word on an -odd byte boundary). -All short integers are aligned on a short word boundary. -.PP -The numbers section is similar to the flags section. -Each capability takes up two bytes, -and is stored as a little-endian short integer. -If the value represented is \-1, the capability is taken to be missing. -.PP -The strings section is also similar. -Each capability is stored as a short integer, in the format above. -A value of \-1 means the capability is missing. -Otherwise, the value is taken as an offset from the beginning -of the string table. -Special characters in ^X or \ec notation are stored in their -interpreted form, not the printing representation. -Padding information $ and parameter information %x are -stored intact in uninterpreted form. -.PP -The final section is the string table. -It contains all the values of string capabilities referenced in -the string section. -Each string is null terminated. -.PP -Note that it is possible for -.I setupterm -to expect a different set of capabilities -than are actually present in the file. -Either the database may have been updated since -.I setupterm -has been recompiled -(resulting in extra unrecognized entries in the file) -or the program may have been recompiled more recently -than the database was updated -(resulting in missing entries). -The routine -.I setupterm -must be prepared for both possibilities \- -this is why the numbers and sizes are included. -Also, new capabilities must always be added at the end of the lists -of boolean, number, and string capabilities. -.PP -Despite the consistent use of little-endian for numbers and the otherwise -self-describing format, it is not wise to count on portability of binary -terminfo entries between commercial UNIX versions. The problem is that there -are at least three versions of terminfo (under HP-UX, AIX, and OSF/1) which -diverged from System V terminfo after SVr1, and have added extension -capabilities to the string table that (in the binary format) collide with -System V and XSI Curses extensions. See \fBterminfo\fR(\*n) for detailed -discussion of terminfo source compatibility issues. -.PP -As an example, here is a hex dump of the description for the Lear-Siegler -ADM-3, a popular though rather stupid early terminal: -.nf -.sp -adm3a|lsi adm3a, - am, - cols#80, lines#24, - bel=^G, clear=\032$<1>, cr=^M, cub1=^H, cud1=^J, - cuf1=^L, cup=\\E=%p1%{32}%+%c%p2%{32}%+%c, cuu1=^K, - home=^^, ind=^J, -.sp -.ft CW -\s-20000 1a 01 10 00 02 00 03 00 82 00 31 00 61 64 6d 33 ........ ..1.adm3 -0010 61 7c 6c 73 69 20 61 64 6d 33 61 00 00 01 50 00 a|lsi ad m3a...P. -0020 ff ff 18 00 ff ff 00 00 02 00 ff ff ff ff 04 00 ........ ........ -0030 ff ff ff ff ff ff ff ff 0a 00 25 00 27 00 ff ff ........ ..%.'... -0040 29 00 ff ff ff ff 2b 00 ff ff 2d 00 ff ff ff ff ).....+. ..-..... -0050 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0060 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0070 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0080 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0090 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00a0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00b0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00c0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00d0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00e0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -00f0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0100 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0110 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ........ ........ -0120 ff ff ff ff ff ff 2f 00 07 00 0d 00 1a 24 3c 31 ....../. .....$<1 -0130 3e 00 1b 3d 25 70 31 25 7b 33 32 7d 25 2b 25 63 >..=%p1% {32}%+%c -0140 25 70 32 25 7b 33 32 7d 25 2b 25 63 00 0a 00 1e %p2%{32} %+%c.... -0150 00 08 00 0c 00 0b 00 0a 00 ........ .\s+2 -.ft R -.fi -.sp -.PP -Some limitations: total compiled entries cannot exceed 4096 bytes. -The name field cannot exceed 128 bytes. -.SH FILES -\*d/*/* compiled terminal capability data base -.SH SEE ALSO -\fBcurses\fR(3X), \fBterminfo\fR(\*n). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/term.7 b/contrib/ncurses-5.4/man/term.7 deleted file mode 100644 index e3be223b04..0000000000 --- a/contrib/ncurses-5.4/man/term.7 +++ /dev/null @@ -1,204 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: term.7,v 1.14 2003/05/10 20:33:49 jmc Exp $ -.TH TERM 7 -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -term \- conventions for naming terminal types -.SH DESCRIPTION -.PP -The environment variable \fBTERM\fR should normally contain the type name of -the terminal, console or display-device type you are using. This information -is critical for all screen-oriented programs, including your editor and mailer. -.PP -A default \fBTERM\fR value will be set on a per-line basis by either -\fB/etc/inittab\fR (Linux and System-V-like UNIXes) or \fB/etc/ttys\fR (BSD -UNIXes). This will nearly always suffice for workstation and microcomputer -consoles. -.PP -If you use a dialup line, the type of device attached to it may vary. Older -UNIX systems pre-set a very dumb terminal type like `dumb' or `dialup' on -dialup lines. Newer ones may pre-set `vt100', reflecting the prevalence of DEC -VT100-compatible terminals and personal-computer emulators. -.PP -Modern telnets pass your \fBTERM\fR environment variable from the local side to -the remote one. There can be problems if the remote terminfo or termcap entry -for your type is not compatible with yours, but this situation is rare and -can almost always be avoided by explicitly exporting `vt100' (assuming you -are in fact using a VT100-superset console, terminal, or terminal emulator.) -.PP -In any case, you are free to override the system \fBTERM\fR setting to your -taste in your shell profile. The \fBtset\fP(1) utility may be of assistance; -you can give it a set of rules for deducing or requesting a terminal type based -on the tty device and baud rate. -.PP -Setting your own \fBTERM\fR value may also be useful if you have created a -custom entry incorporating options (such as visual bell or reverse-video) -which you wish to override the system default type for your line. -.PP -Terminal type descriptions are stored as files of capability data underneath -\*d. To browse a list of all terminal names recognized by the system, do - - toe | more - -from your shell. These capability files are in a binary format optimized for -retrieval speed (unlike the old text-based \fBtermcap\fR format they replace); -to examine an entry, you must use the \fBinfocmp\fR(1) command. Invoke it as -follows: - - infocmp \fIentry-name\fR - -where \fIentry-name\fR is the name of the type you wish to examine (and the -name of its capability file the subdirectory of \*d named for its first -letter). This command dumps a capability file in the text format described by -\fBterminfo\fR(\*n). -.PP -The first line of a \fBterminfo\fR(\*n) description gives the names by which -terminfo knows a terminal, separated by `|' (pipe-bar) characters with the last -name field terminated by a comma. The first name field is the type's -\fIprimary name\fR, and is the one to use when setting \fBTERM\fR. The last -name field (if distinct from the first) is actually a description of the -terminal type (it may contain blanks; the others must be single words). Name -fields between the first and last (if present) are aliases for the terminal, -usually historical names retained for compatibility. -.PP -There are some conventions for how to choose terminal primary names that help -keep them informative and unique. Here is a step-by-step guide to naming -terminals that also explains how to parse them: -.PP -First, choose a root name. The root will consist of a lower-case letter -followed by up to seven lower-case letters or digits. You need to avoid using -punctuation characters in root names, because they are used and interpreted as -filenames and shell meta-characters (such as !, $, *, ?, etc.) embedded in them -may cause odd and unhelpful behavior. The slash (/), or any other character -that may be interpreted by anyone's file system (\e, $, [, ]), is especially -dangerous (terminfo is platform-independent, and choosing names with special -characters could someday make life difficult for users of a future port). The -dot (.) character is relatively safe as long as there is at most one per root -name; some historical terminfo names use it. -.PP -The root name for a terminal or workstation console type should almost always -begin with a vendor prefix (such as \fBhp\fR for Hewlett-Packard, \fBwy\fR for -Wyse, or \fBatt\fR for AT&T terminals), or a common name of the terminal line -(\fBvt\fR for the VT series of terminals from DEC, or \fBsun\fR for Sun -Microsystems workstation consoles, or \fBregent\fR for the ADDS Regent series. -You can list the terminfo tree to see what prefixes are already in common use. -The root name prefix should be followed when appropriate by a model number; -thus \fBvt100\fR, \fBhp2621\fR, \fBwy50\fR. -.PP -The root name for a PC-Unix console type should be the OS name, -i.e. \fBlinux\fR, \fBbsdos\fR, \fBfreebsd\fR, \fBnetbsd\fR. It should -\fInot\fR be \fBconsole\fR or any other generic that might cause confusion in a -multi-platform environment! If a model number follows, it should indicate -either the OS release level or the console driver release level. -.PP -The root name for a terminal emulator (assuming it doesn't fit one of the -standard ANSI or vt100 types) should be the program name or a readily -recognizable abbreviation of it (i.e. \fBversaterm\fR, \fBctrm\fR). -.PP -Following the root name, you may add any reasonable number of hyphen-separated -feature suffixes. -.TP 5 -2p -Has two pages of memory. Likewise 4p, 8p, etc. -.TP 5 -mc -Magic-cookie. Some terminals (notably older Wyses) can only support one -attribute without magic-cookie lossage. Their base entry is usually paired -with another that has this suffix and uses magic cookies to support multiple -attributes. -.TP 5 --am -Enable auto-margin (right-margin wraparound). -.TP 5 --m -Mono mode - suppress color support. -.TP 5 --na -No arrow keys - termcap ignores arrow keys which are actually there on the -terminal, so the user can use the arrow keys locally. -.TP 5 --nam -No auto-margin - suppress am capability. -.TP 5 --nl -No labels - suppress soft labels. -.TP 5 --nsl -No status line - suppress status line. -.TP 5 --pp -Has a printer port which is used. -.TP 5 --rv -Terminal in reverse video mode (black on white). -.TP 5 --s -Enable status line. -.TP 5 --vb -Use visible bell (flash) rather than beep. -.TP 5 --w -Wide; terminal is in 132 column mode. -.PP -Conventionally, if your terminal type is a variant intended to specify a -line height, that suffix should go first. So, for a hypothetical FuBarCo -model 2317 terminal in 30-line mode with reverse video, best form would be -\fBfubar-30-rv\fR (rather than, say, `fubar-rv-30'). -.PP -Terminal types that are written not as standalone entries, but rather as -components to be plugged into other entries via \fBuse\fP capabilities, -are distinguished by using embedded plus signs rather than dashes. -.PP -Commands which use a terminal type to control display often accept a -T -option that accepts a terminal name argument. Such programs should fall back -on the \fBTERM\fR environment variable when no -T option is specified. -.SH PORTABILITY -For maximum compatibility with older System V UNIXes, names and aliases -should be unique within the first 14 characters. -.SH FILES -.TP 5 -\*d/?/* -compiled terminal capability data base -.TP 5 -/etc/inittab -tty line initialization (AT&T-like UNIXes) -.TP 5 -/etc/ttys -tty line initialization (BSD-like UNIXes) -.SH SEE ALSO -\fBcurses\fR(3X), \fBterminfo\fR(\*n), \fBterm\fR(\*n). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/terminfo.head b/contrib/ncurses-5.4/man/terminfo.head deleted file mode 100644 index 3869cca0ba..0000000000 --- a/contrib/ncurses-5.4/man/terminfo.head +++ /dev/null @@ -1,95 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2002 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. * -.\"*************************************************************************** -.\" -.\" $Id: terminfo.head,v 1.10 2002/08/17 23:37:10 tom Exp $ -.TH TERMINFO 5 "" "" "File Formats" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -terminfo \- terminal capability data base -.SH SYNOPSIS -\*d/*/* -.SH DESCRIPTION -.I Terminfo -is a data base describing terminals, used by screen-oriented programs such as -\fBnvi\fR(1), -\fBrogue\fR(1) -and libraries such as -\fBcurses\fR(3X). -.I Terminfo -describes terminals by giving a set of capabilities which they -have, by specifying how to perform screen operations, and by -specifying padding requirements and initialization sequences. -.PP -Entries in -.I terminfo -consist of a sequence of `,' separated fields (embedded commas may be -escaped with a backslash or notated as \e054). -White space after the `,' separator is ignored. -The first entry for each terminal gives the names which are known for the -terminal, separated by `|' characters. -The first name given is the most common abbreviation for the terminal, -the last name given should be a long name fully identifying the terminal, -and all others are understood as synonyms for the terminal name. -All names but the last should be in lower case and contain no blanks; -the last name may well contain upper case and blanks for readability. -.PP -Terminal names (except for the last, verbose entry) should -be chosen using the following conventions. -The particular piece of hardware making up the terminal should -have a root name, thus ``hp2621''. -This name should not contain hyphens. -Modes that the hardware can be in, or user preferences, should -be indicated by appending a hyphen and a mode suffix. -Thus, a vt100 in 132 column mode would be vt100-w. -The following suffixes should be used where possible: -.PP -.TS -center ; -l c l -l l l. -\fBSuffix Meaning Example\fP --\fInn\fP Number of lines on the screen aaa-60 --\fIn\fPp Number of pages of memory c100-4p --am With automargins (usually the default) vt100-am --m Mono mode; suppress color ansi-m --mc Magic cookie; spaces when highlighting wy30-mc --na No arrow keys (leave them in local) c100-na --nam Without automatic margins vt100-nam --nl No status line att4415-nl --ns No status line hp2626-ns --rv Reverse video c100-rv --s Enable status line vt100-s --vb Use visible bell instead of beep wy370-vb --w Wide mode (> 80 columns, usually 132) vt100-w -.TE -.PP -For more on terminal naming conventions, see the \fBterm(7)\fR manual page. -.SS Capabilities -.\" Head of terminfo man page ends here -.ps -1 diff --git a/contrib/ncurses-5.4/man/terminfo.tail b/contrib/ncurses-5.4/man/terminfo.tail deleted file mode 100644 index fc6af2e035..0000000000 --- a/contrib/ncurses-5.4/man/terminfo.tail +++ /dev/null @@ -1,1643 +0,0 @@ -.\" $Id: terminfo.tail,v 1.38 2003/01/05 22:47:05 tom Exp $ -.\" Beginning of terminfo.tail file -.ps +1 -.PP -.SS A Sample Entry -.PP -The following entry, describing an ANSI-standard terminal, is representative -of what a \fBterminfo\fR entry for a modern terminal typically looks like. -.PP -.nf -.in -2 -.ta .3i -.ft CW -\s-2ansi|ansi/pc-term compatible with color, - mc5i, - colors#8, ncv#3, pairs#64, - cub=\\E[%p1%dD, cud=\\E[%p1%dB, cuf=\\E[%p1%dC, - cuu=\\E[%p1%dA, dch=\\E[%p1%dP, dl=\\E[%p1%dM, - ech=\\E[%p1%dX, el1=\\E[1K, hpa=\\E[%p1%dG, ht=\\E[I, - ich=\\E[%p1%d@, il=\\E[%p1%dL, indn=\\E[%p1%dS, .indn=\\E[%p1%dT, - kbs=^H, kcbt=\\E[Z, kcub1=\\E[D, kcud1=\\E[B, - kcuf1=\\E[C, kcuu1=\\E[A, kf1=\\E[M, kf10=\\E[V, - kf11=\\E[W, kf12=\\E[X, kf2=\\E[N, kf3=\\E[O, kf4=\\E[P, - kf5=\\E[Q, kf6=\\E[R, kf7=\\E[S, kf8=\\E[T, kf9=\\E[U, - kich1=\\E[L, mc4=\\E[4i, mc5=\\E[5i, nel=\\r\\E[S, - op=\\E[37;40m, rep=%p1%c\\E[%p2%{1}%-%db, - rin=\\E[%p1%dT, s0ds=\\E(B, s1ds=\\E)B, s2ds=\\E*B, - s3ds=\\E+B, setab=\\E[4%p1%dm, setaf=\\E[3%p1%dm, - setb=\\E[4%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6}%=%t3%e%p1%d%;m, - setf=\\E[3%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6}%=%t3%e%p1%d%;m, - sgr=\\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1%;%?%p7%t;8%;%?%p8%t;11%;%?%p9%t;12%;m, - sgr0=\\E[0;10m, tbc=\\E[2g, u6=\\E[%d;%dR, u7=\\E[6n, - u8=\\E[?%[;0123456789]c, u9=\\E[c, vpa=\\E[%p1%dd,\s+2 -.in +2 -.fi -.ft R -.PP -Entries may continue onto multiple lines by placing white space at -the beginning of each line except the first. -Comments may be included on lines beginning with ``#''. -Capabilities in -.I terminfo -are of three types: -Boolean capabilities which indicate that the terminal has -some particular feature, numeric capabilities giving the size of the terminal -or the size of particular delays, and string -capabilities, which give a sequence which can be used to perform particular -terminal operations. -.PP -.SS Types of Capabilities -.PP -All capabilities have names. -For instance, the fact that -ANSI-standard terminals have -.I "automatic margins" -(i.e., an automatic return and line-feed -when the end of a line is reached) is indicated by the capability \fBam\fR. -Hence the description of ansi includes \fBam\fR. -Numeric capabilities are followed by the character `#' and then a positive value. -Thus \fBcols\fR, which indicates the number of columns the terminal has, -gives the value `80' for ansi. -Values for numeric capabilities may be specified in decimal, octal or hexadecimal, -using the C programming language conventions (e.g., 255, 0377 and 0xff or 0xFF). -.PP -Finally, string valued capabilities, such as \fBel\fR (clear to end of line -sequence) are given by the two-character code, an `=', and then a string -ending at the next following `,'. -.PP -A number of escape sequences are provided in the string valued capabilities -for easy encoding of characters there. -Both \fB\eE\fR and \fB\ee\fR -map to an \s-1ESCAPE\s0 character, -\fB^x\fR maps to a control-x for any appropriate x, and the sequences -\fB\en \el \er \et \eb \ef \es\fR give -a newline, line-feed, return, tab, backspace, form-feed, and space. -Other escapes include \fB\e^\fR for \fB^\fR, -\fB\e\e\fR for \fB\e\fR, -\fB\e\fR, for comma, -\fB\e:\fR for \fB:\fR, -and \fB\e0\fR for null. -(\fB\e0\fR will produce \e200, which does not terminate a string but behaves -as a null character on most terminals, providing CS7 is specified. -See stty(1).) -Finally, characters may be given as three octal digits after a \fB\e\fR. -.PP -A delay in milliseconds may appear anywhere in a string capability, enclosed in -$<..> brackets, as in \fBel\fP=\eEK$<5>, and padding characters are supplied by -.I tputs -to provide this delay. -The delay must be a number with at most one decimal -place of precision; it may be followed by suffixes `*' or '/' or both. -A `*' -indicates that the padding required is proportional to the number of lines -affected by the operation, and the amount given is the per-affected-unit -padding required. -(In the case of insert character, the factor is still the -number of -.IR lines -affected.) Normally, padding is advisory if the device has the \fBxon\fR -capability; it is used for cost computation but does not trigger delays. -A `/' -suffix indicates that the padding is mandatory and forces a delay of the given -number of milliseconds even on devices for which \fBxon\fR is present to -indicate flow control. -.PP -Sometimes individual capabilities must be commented out. -To do this, put a period before the capability name. -For example, see the second -.B ind -in the example above. -.br -.ne 5 -.PP -.SS Fetching Compiled Descriptions -.PP -If the environment variable TERMINFO is set, it is interpreted as the pathname -of a directory containing the compiled description you are working on. -Only -that directory is searched. -.PP -If TERMINFO is not set, the \fBncurses\fR version of the terminfo reader code -will instead look in the directory \fB$HOME/.terminfo\fR -for a compiled description. -If it fails to find one there, and the environment variable TERMINFO_DIRS is -set, it will interpret the contents of that variable as a list of colon- -separated directories to be searched (an empty entry is interpreted as a -command to search \fI\*d\fR). -If no description is found in any of the -TERMINFO_DIRS directories, the fetch fails. -.PP -If neither TERMINFO nor TERMINFO_DIRS is set, the last place tried will be the -system terminfo directory, \fI\*d\fR. -.PP -(Neither the \fB$HOME/.terminfo\fR lookups nor TERMINFO_DIRS extensions are -supported under stock System V terminfo/curses.) -.PP -.SS Preparing Descriptions -.PP -We now outline how to prepare descriptions of terminals. -The most effective way to prepare a terminal description is by imitating -the description of a similar terminal in -.I terminfo -and to build up a description gradually, using partial descriptions -with -.I vi -or some other screen-oriented program to check that they are correct. -Be aware that a very unusual terminal may expose deficiencies in -the ability of the -.I terminfo -file to describe it -or bugs in the screen-handling code of the test program. -.PP -To get the padding for insert line right (if the terminal manufacturer -did not document it) a severe test is to edit a large file at 9600 baud, -delete 16 or so lines from the middle of the screen, then hit the `u' -key several times quickly. -If the terminal messes up, more padding is usually needed. -A similar test can be used for insert character. -.PP -.SS Basic Capabilities -.PP -The number of columns on each line for the terminal is given by the -\fBcols\fR numeric capability. -If the terminal is a \s-1CRT\s0, then the -number of lines on the screen is given by the \fBlines\fR capability. -If the terminal wraps around to the beginning of the next line when -it reaches the right margin, then it should have the \fBam\fR capability. -If the terminal can clear its screen, leaving the cursor in the home -position, then this is given by the \fBclear\fR string capability. -If the terminal overstrikes -(rather than clearing a position when a character is struck over) -then it should have the \fBos\fR capability. -If the terminal is a printing terminal, with no soft copy unit, -give it both -.B hc -and -.BR os . -.RB ( os -applies to storage scope terminals, such as \s-1TEKTRONIX\s+1 4010 -series, as well as hard copy and APL terminals.) -If there is a code to move the cursor to the left edge of the current -row, give this as -.BR cr . -(Normally this will be carriage return, control M.) -If there is a code to produce an audible signal (bell, beep, etc) -give this as -.BR bel . -.PP -If there is a code to move the cursor one position to the left -(such as backspace) that capability should be given as -.BR cub1 . -Similarly, codes to move to the right, up, and down should be -given as -.BR cuf1 , -.BR cuu1 , -and -.BR cud1 . -These local cursor motions should not alter the text they pass over, -for example, you would not normally use `\fBcuf1\fP=\ ' because the -space would erase the character moved over. -.PP -A very important point here is that the local cursor motions encoded -in -.I terminfo -are undefined at the left and top edges of a \s-1CRT\s0 terminal. -Programs should never attempt to backspace around the left edge, -unless -.B bw -is given, -and never attempt to go up locally off the top. -In order to scroll text up, a program will go to the bottom left corner -of the screen and send the -.B ind -(index) string. -.PP -To scroll text down, a program goes to the top left corner -of the screen and sends the -.B ri -(reverse index) string. -The strings -.B ind -and -.B ri -are undefined when not on their respective corners of the screen. -.PP -Parameterized versions of the scrolling sequences are -.B indn -and -.B rin -which have the same semantics as -.B ind -and -.B ri -except that they take one parameter, and scroll that many lines. -They are also undefined except at the appropriate edge of the screen. -.PP -The \fBam\fR capability tells whether the cursor sticks at the right -edge of the screen when text is output, but this does not necessarily -apply to a -.B cuf1 -from the last column. -The only local motion which is defined from the left edge is if -.B bw -is given, then a -.B cub1 -from the left edge will move to the right edge of the previous row. -If -.B bw -is not given, the effect is undefined. -This is useful for drawing a box around the edge of the screen, for example. -If the terminal has switch selectable automatic margins, -the -.I terminfo -file usually assumes that this is on; i.e., \fBam\fR. -If the terminal has a command which moves to the first column of the next -line, that command can be given as -.B nel -(newline). -It does not matter if the command clears the remainder of the current line, -so if the terminal has no -.B cr -and -.B lf -it may still be possible to craft a working -.B nel -out of one or both of them. -.PP -These capabilities suffice to describe hard-copy and \*(lqglass-tty\*(rq terminals. -Thus the model 33 teletype is described as -.PP -.DT -.nf -.ft CW -.in -7 - \s-133\||\|tty33\||\|tty\||\|model 33 teletype, - bel=^G, cols#72, cr=^M, cud1=^J, hc, ind=^J, os,\s+1 -.in +7 -.ft R -.PP -while the Lear Siegler \s-1ADM\-3\s0 is described as -.PP -.DT -.nf -.ft CW -.in -7 - \s-1adm3\||\|3\||\|lsi adm3, - am, bel=^G, clear=^Z, cols#80, cr=^M, cub1=^H, cud1=^J, - ind=^J, lines#24,\s+1 -.in +7 -.ft R -.fi -.PP -.SS Parameterized Strings -.PP -Cursor addressing and other strings requiring parameters -in the terminal are described by a -parameterized string capability, with -.IR printf (3S) -like escapes \fB%x\fR in it. -For example, to address the cursor, the -.B cup -capability is given, using two parameters: -the row and column to address to. -(Rows and columns are numbered from zero and refer to the -physical screen visible to the user, not to any unseen memory.) -If the terminal has memory relative cursor addressing, -that can be indicated by -.BR mrcup . -.PP -The parameter mechanism uses a stack and special \fB%\fP codes -to manipulate it. -Typically a sequence will push one of the -parameters onto the stack and then print it in some format. -Print (e.g., "%d") is a special case. -Other operations, including "%t" pop their operand from the stack. -It is noted that more complex operations are often necessary, -e.g., in the \fBsgr\fP string. -.PP -The \fB%\fR encodings have the following meanings: -.PP -.TP 5 -\s-1%% -outputs `%' -.TP -%\fI[[\fP:\fI]flags][width[.precision]][\fPdoxXs\fI]\fP -as in \fBprintf\fP, flags are [-+#] and space -.TP -%c -print pop() like %c in \fBprintf\fP -.TP -%s -print pop() like %s in \fBprintf\fP -.TP -%p[1-9] -push \fIi\fP'th parameter -.TP -%P[a-z] -set dynamic variable [a-z] to pop() -.TP -%g[a-z] -get dynamic variable [a-z] and push it -.TP -%P[A-Z] -set static variable [a-z] to pop() -.TP -%g[A-Z] -get static variable [a-z] and push it -.IP -The terms "static" and "dynamic" are misleading. -Historically, these are simply two different sets of variables, -whose values are not reset between calls to \fBtparm\fP. -However, that fact is not documented in other implementations. -Relying on it will adversely impact portability to other implementations. -.TP -%'\fIc\fP' -char constant \fIc\fP -.TP -%{\fInn\fP} -integer constant \fInn\fP -.TP -%l -push strlen(pop) -.TP -%+ %- %* %/ %m -arithmetic (%m is mod): push(pop() op pop()) -.TP -%& %| %^ -bit operations: push(pop() op pop()) -.TP -%= %> %< -logical operations: push(pop() op pop()) -.TP -%A, %O -logical and & or operations (for conditionals) -.TP -%! %~ -unary operations push(op pop()) -.TP -%i -add 1 to first two parameters (for ANSI terminals) -.TP -%? \fIexpr\fP %t \fIthenpart\fP %e \fIelsepart\fP %; -if-then-else, %e \fIelsepart\fP is optional. -else-if's are possible a la Algol 68: -.br -%? c\d1\u %t b\d1\u %e c\d2\u %t b\d2\u %e c\d3\u %t b\d3\u %e c\d4\u %t b\d4\u %e %; -.br -c\di\u are conditions, b\di\u are bodies. -.PP -Binary operations are in postfix form with the operands in the usual order. -That is, to get x-5 one would use "%gx%{5}%-". -%P and %g variables are -persistent across escape-string evaluations. -.PP -Consider the HP2645, which, to get to row 3 and column 12, needs -to be sent \eE&a12c03Y padded for 6 milliseconds. -Note that the order -of the rows and columns is inverted here, and that the row and column -are printed as two digits. -Thus its \fBcup\fR capability is \*(lqcup=6\eE&%p2%2dc%p1%2dY\*(rq. -.PP -The Microterm \s-1ACT-IV\s0 needs the current row and column sent -preceded by a \fB^T\fR, with the row and column simply encoded in binary, -\*(lqcup=^T%p1%c%p2%c\*(rq. -Terminals which use \*(lq%c\*(rq need to be able to -backspace the cursor (\fBcub1\fR), -and to move the cursor up one line on the screen (\fBcuu1\fR). -This is necessary because it is not always safe to transmit \fB\en\fR -\fB^D\fR and \fB\er\fR, as the system may change or discard them. -(The library routines dealing with terminfo set tty modes so that -tabs are never expanded, so \et is safe to send. -This turns out to be essential for the Ann Arbor 4080.) -.PP -A final example is the \s-1LSI ADM\s0-3a, which uses row and column -offset by a blank character, thus \*(lqcup=\eE=%p1%' '%+%c%p2%' '%+%c\*(rq. -After sending `\eE=', this pushes the first parameter, pushes the -ASCII value for a space (32), adds them (pushing the sum on the stack -in place of the two previous values) and outputs that value as a character. -Then the same is done for the second parameter. -More complex arithmetic is possible using the stack. -.PP -.SS Cursor Motions -.PP -If the terminal has a fast way to home the cursor -(to very upper left corner of screen) then this can be given as -\fBhome\fR; similarly a fast way of getting to the lower left-hand corner -can be given as \fBll\fR; this may involve going up with \fBcuu1\fR -from the home position, -but a program should never do this itself (unless \fBll\fR does) because it -can make no assumption about the effect of moving up from the home position. -Note that the home position is the same as addressing to (0,0): -to the top left corner of the screen, not of memory. -(Thus, the \eEH sequence on HP terminals cannot be used for -.BR home .) -.PP -If the terminal has row or column absolute cursor addressing, -these can be given as single parameter capabilities -.B hpa -(horizontal position absolute) -and -.B vpa -(vertical position absolute). -Sometimes these are shorter than the more general two parameter -sequence (as with the hp2645) and can be used in preference to -.BR cup . -If there are parameterized local motions (e.g., move -.I n -spaces to the right) these can be given as -.BR cud , -.BR cub , -.BR cuf , -and -.BR cuu -with a single parameter indicating how many spaces to move. -These are primarily useful if the terminal does not have -.BR cup , -such as the \s-1TEKTRONIX\s+1 4025. -.PP -If the terminal needs to be in a special mode when running -a program that uses these capabilities, -the codes to enter and exit this mode can be given as \fBsmcup\fR and \fBrmcup\fR. -This arises, for example, from terminals like the Concept with more than -one page of memory. -If the terminal has only memory relative cursor addressing and not screen -relative cursor addressing, a one screen-sized window must be fixed into -the terminal for cursor addressing to work properly. -This is also used for the \s-1TEKTRONIX\s+1 4025, -where -.B smcup -sets the command character to be the one used by terminfo. -If the \fBsmcup\fP sequence will not restore the screen after an -\fBrmcup\fP sequence is output (to the state prior to outputting -\fBrmcup\fP), specify \fBnrrmc\fP. -.PP -.SS Area Clears -.PP -If the terminal can clear from the current position to the end of the -line, leaving the cursor where it is, this should be given as \fBel\fR. -If the terminal can clear from the beginning of the line to the current -position inclusive, leaving -the cursor where it is, this should be given as \fBel1\fP. -If the terminal can clear from the current position to the end of the -display, then this should be given as \fBed\fR. -\fBEd\fR is only defined from the first column of a line. -(Thus, it can be simulated by a request to delete a large number of lines, -if a true -.B ed -is not available.) -.PP -.SS Insert/delete line and vertical motions -.PP -If the terminal can open a new blank line before the line where the cursor -is, this should be given as \fBil1\fR; this is done only from the first -position of a line. -The cursor must then appear on the newly blank line. -If the terminal can delete the line which the cursor is on, then this -should be given as \fBdl1\fR; this is done only from the first position on -the line to be deleted. -Versions of -.B il1 -and -.B dl1 -which take a single parameter and insert or delete that many lines can -be given as -.B il -and -.BR dl . -.PP -If the terminal has a settable scrolling region (like the vt100) -the command to set this can be described with the -.B csr -capability, which takes two parameters: -the top and bottom lines of the scrolling region. -The cursor position is, alas, undefined after using this command. -.PP -It is possible to get the effect of insert or delete line using -.B csr -on a properly chosen region; the -.B sc -and -.B rc -(save and restore cursor) commands may be useful for ensuring that -your synthesized insert/delete string does not move the cursor. -(Note that the \fBncurses\fR(3X) library does this synthesis -automatically, so you need not compose insert/delete strings for -an entry with \fBcsr\fR). -.PP -Yet another way to construct insert and delete might be to use a combination of -index with the memory-lock feature found on some terminals (like the HP-700/90 -series, which however also has insert/delete). -.PP -Inserting lines at the top or bottom of the screen can also be -done using -.B ri -or -.B ind -on many terminals without a true insert/delete line, -and is often faster even on terminals with those features. -.PP -The boolean \fBnon_dest_scroll_region\fR should be set if each scrolling -window is effectively a view port on a screen-sized canvas. -To test for -this capability, create a scrolling region in the middle of the screen, -write something to the bottom line, move the cursor to the top of the region, -and do \fBri\fR followed by \fBdl1\fR or \fBind\fR. -If the data scrolled -off the bottom of the region by the \fBri\fR re-appears, then scrolling -is non-destructive. -System V and XSI Curses expect that \fBind\fR, \fBri\fR, -\fBindn\fR, and \fBrin\fR will simulate destructive scrolling; their -documentation cautions you not to define \fBcsr\fR unless this is true. -This \fBcurses\fR implementation is more liberal and will do explicit erases -after scrolling if \fBndstr\fR is defined. -.PP -If the terminal has the ability to define a window as part of -memory, which all commands affect, -it should be given as the parameterized string -.BR wind . -The four parameters are the starting and ending lines in memory -and the starting and ending columns in memory, in that order. -.PP -If the terminal can retain display memory above, then the -\fBda\fR capability should be given; if display memory can be retained -below, then \fBdb\fR should be given. -These indicate -that deleting a line or scrolling may bring non-blank lines up from below -or that scrolling back with \fBri\fR may bring down non-blank lines. -.PP -.SS Insert/Delete Character -.PP -There are two basic kinds of intelligent terminals with respect to -insert/delete character which can be described using -.I terminfo. -The most common insert/delete character operations affect only the characters -on the current line and shift characters off the end of the line rigidly. -Other terminals, such as the Concept 100 and the Perkin Elmer Owl, make -a distinction between typed and untyped blanks on the screen, shifting -upon an insert or delete only to an untyped blank on the screen which is -either eliminated, or expanded to two untyped blanks. -You can determine the -kind of terminal you have by clearing the screen and then typing -text separated by cursor motions. -Type \*(lqabc\ \ \ \ def\*(rq using local -cursor motions (not spaces) between the \*(lqabc\*(rq and the \*(lqdef\*(rq. -Then position the cursor before the \*(lqabc\*(rq and put the terminal in insert -mode. -If typing characters causes the rest of the line to shift -rigidly and characters to fall off the end, then your terminal does -not distinguish between blanks and untyped positions. -If the \*(lqabc\*(rq -shifts over to the \*(lqdef\*(rq which then move together around the end of the -current line and onto the next as you insert, you have the second type of -terminal, and should give the capability \fBin\fR, which stands for -\*(lqinsert null\*(rq. -While these are two logically separate attributes (one line versus multi-line -insert mode, and special treatment of untyped spaces) we have seen no -terminals whose insert mode cannot be described with the single attribute. -.PP -Terminfo can describe both terminals which have an insert mode, and terminals -which send a simple sequence to open a blank position on the current line. -Give as \fBsmir\fR the sequence to get into insert mode. -Give as \fBrmir\fR the sequence to leave insert mode. -Now give as \fBich1\fR any sequence needed to be sent just before sending -the character to be inserted. -Most terminals with a true insert mode -will not give \fBich1\fR; terminals which send a sequence to open a screen -position should give it here. -.PP -If your terminal has both, insert mode is usually preferable to \fBich1\fR. -Technically, you should not give both unless the terminal actually requires -both to be used in combination. -Accordingly, some non-curses applications get -confused if both are present; the symptom is doubled characters in an update -using insert. -This requirement is now rare; most \fBich\fR sequences do not -require previous smir, and most smir insert modes do not require \fBich1\fR -before each character. -Therefore, the new \fBcurses\fR actually assumes this -is the case and uses either \fBrmir\fR/\fBsmir\fR or \fBich\fR/\fBich1\fR as -appropriate (but not both). -If you have to write an entry to be used under -new curses for a terminal old enough to need both, include the -\fBrmir\fR/\fBsmir\fR sequences in \fBich1\fR. -.PP -If post insert padding is needed, give this as a number of milliseconds -in \fBip\fR (a string option). -Any other sequence which may need to be -sent after an insert of a single character may also be given in \fBip\fR. -If your terminal needs both to be placed into an `insert mode' and -a special code to precede each inserted character, then both -.BR smir / rmir -and -.B ich1 -can be given, and both will be used. -The -.B ich -capability, with one parameter, -.IR n , -will repeat the effects of -.B ich1 -.I n -times. -.PP -If padding is necessary between characters typed while not -in insert mode, give this as a number of milliseconds padding in \fBrmp\fP. -.PP -It is occasionally necessary to move around while in insert mode -to delete characters on the same line (e.g., if there is a tab after -the insertion position). -If your terminal allows motion while in -insert mode you can give the capability \fBmir\fR to speed up inserting -in this case. -Omitting \fBmir\fR will affect only speed. -Some terminals -(notably Datamedia's) must not have \fBmir\fR because of the way their -insert mode works. -.PP -Finally, you can specify -.B dch1 -to delete a single character, -.B dch -with one parameter, -.IR n , -to delete -.I n characters, -and delete mode by giving \fBsmdc\fR and \fBrmdc\fR -to enter and exit delete mode (any mode the terminal needs to be placed -in for -.B dch1 -to work). -.PP -A command to erase -.I n -characters (equivalent to outputting -.I n -blanks without moving the cursor) -can be given as -.B ech -with one parameter. -.PP -.SS "Highlighting, Underlining, and Visible Bells" -.PP -If your terminal has one or more kinds of display attributes, -these can be represented in a number of different ways. -You should choose one display form as -\f2standout mode\fR, -representing a good, high contrast, easy-on-the-eyes, -format for highlighting error messages and other attention getters. -(If you have a choice, reverse video plus half-bright is good, -or reverse video alone.) -The sequences to enter and exit standout mode -are given as \fBsmso\fR and \fBrmso\fR, respectively. -If the code to change into or out of standout -mode leaves one or even two blank spaces on the screen, -as the TVI 912 and Teleray 1061 do, -then \fBxmc\fR should be given to tell how many spaces are left. -.PP -Codes to begin underlining and end underlining can be given as \fBsmul\fR -and \fBrmul\fR respectively. -If the terminal has a code to underline the current character and move -the cursor one space to the right, -such as the Microterm Mime, -this can be given as \fBuc\fR. -.PP -Other capabilities to enter various highlighting modes include -.B blink -(blinking) -.B bold -(bold or extra bright) -.B dim -(dim or half-bright) -.B invis -(blanking or invisible text) -.B prot -(protected) -.B rev -(reverse video) -.B sgr0 -(turn off -.I all -attribute modes) -.B smacs -(enter alternate character set mode) -and -.B rmacs -(exit alternate character set mode). -Turning on any of these modes singly may or may not turn off other modes. -.PP -If there is a sequence to set arbitrary combinations of modes, -this should be given as -.B sgr -(set attributes), -taking 9 parameters. -Each parameter is either 0 or nonzero, as the corresponding attribute is on or off. -The 9 parameters are, in order: -standout, underline, reverse, blink, dim, bold, blank, protect, alternate -character set. -Not all modes need be supported by -.BR sgr , -only those for which corresponding separate attribute commands exist. -.PP -For example, the DEC vt220 supports most of the modes: -.PP -.TS -center; -l c c -l c c -lw28 lw6 lw2 lw20. -\fBtparm parameter attribute escape sequence\fP - -none none \\E[0m -p1 standout \\E[0;1;7m -p2 underline \\E[0;4m -p3 reverse \\E[0;7m -p4 blink \\E[0;5m -p5 dim not available -p6 bold \\E[0;1m -p7 invis \\E[0;8m -p8 protect not used -p9 altcharset ^O (off) ^N (on) -.TE -.PP -We begin each escape sequence by turning off any existing modes, since -there is no quick way to determine whether they are active. -Standout is set up to be the combination of reverse and bold. -The vt220 terminal has a protect mode, -though it is not commonly used in sgr -because it protects characters on the screen from the host's erasures. -The altcharset mode also is different in that it is either ^O or ^N, -depending on whether it is off or on. -If all modes are turned on, the resulting sequence is \\E[0;1;4;5;7;8m^N. -.PP -Some sequences are common to different modes. -For example, ;7 is output when either p1 or p3 is true, that is, if -either standout or reverse modes are turned on. -.PP -Writing out the above sequences, along with their dependencies yields -.PP -.TS -center; -l c c -l c c -lw28 lw6 lw2 lw20. -\fBsequence when to output terminfo translation\fP - -\\E[0 always \\E[0 -;1 if p1 or p6 %?%p1%p6%|%t;1%; -;4 if p2 %?%p2%|%t;4%; -;5 if p4 %?%p4%|%t;5%; -;7 if p1 or p3 %?%p1%p3%|%t;7%; -;8 if p7 %?%p7%|%t;8%; -m always m -^N or ^O if p9 ^N, else ^O %?%p9%t^N%e^O%; -.TE -.PP -Putting this all together into the sgr sequence gives: -.PP -.nf - sgr=\\E[0%?%p1%p6%|%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%; - %?%p4%t;5%;%?%p7%t;8%;m%?%p9%t\\016%e\\017%;, -.fi -.PP -Remember that if you specify sgr, you must also specify sgr0. -.PP -Terminals with the ``magic cookie'' glitch -.RB ( xmc ) -deposit special ``cookies'' when they receive mode-setting sequences, -which affect the display algorithm rather than having extra bits for -each character. -Some terminals, such as the HP 2621, automatically leave standout -mode when they move to a new line or the cursor is addressed. -Programs using standout mode should exit standout mode before -moving the cursor or sending a newline, -unless the -.B msgr -capability, asserting that it is safe to move in standout mode, is present. -.PP -If the terminal has -a way of flashing the screen to indicate an error quietly (a bell replacement) -then this can be given as \fBflash\fR; it must not move the cursor. -.PP -If the cursor needs to be made more visible than normal when it is -not on the bottom line (to make, for example, a non-blinking underline into an -easier to find block or blinking underline) -give this sequence as -.BR cvvis . -If there is a way to make the cursor completely invisible, give that as -.BR civis . -The capability -.BR cnorm -should be given which undoes the effects of both of these modes. -.PP -If your terminal correctly generates underlined characters -(with no special codes needed) -even though it does not overstrike, -then you should give the capability \fBul\fR. -If a character overstriking another leaves both characters on the screen, -specify the capability \fBos\fP. -If overstrikes are erasable with a blank, -then this should be indicated by giving \fBeo\fR. -.PP -.SS Keypad and Function Keys -.PP -If the terminal has a keypad that transmits codes when the keys are pressed, -this information can be given. -Note that it is not possible to handle -terminals where the keypad only works in local (this applies, for example, -to the unshifted HP 2621 keys). -If the keypad can be set to transmit or not transmit, -give these codes as \fBsmkx\fR and \fBrmkx\fR. -Otherwise the keypad is assumed to always transmit. -The codes sent by the left arrow, right arrow, up arrow, down arrow, -and home keys can be given as -\fBkcub1, kcuf1, kcuu1, kcud1, \fRand\fB khome\fR respectively. -If there are function keys such as f0, f1, ..., f10, the codes they send -can be given as \fBkf0, kf1, ..., kf10\fR. -If these keys have labels other than the default f0 through f10, the labels -can be given as \fBlf0, lf1, ..., lf10\fR. -The codes transmitted by certain other special keys can be given: -.B kll -(home down), -.B kbs -(backspace), -.B ktbc -(clear all tabs), -.B kctab -(clear the tab stop in this column), -.B kclr -(clear screen or erase key), -.B kdch1 -(delete character), -.B kdl1 -(delete line), -.B krmir -(exit insert mode), -.B kel -(clear to end of line), -.B ked -(clear to end of screen), -.B kich1 -(insert character or enter insert mode), -.B kil1 -(insert line), -.B knp -(next page), -.B kpp -(previous page), -.B kind -(scroll forward/down), -.B kri -(scroll backward/up), -.B khts -(set a tab stop in this column). -In addition, if the keypad has a 3 by 3 array of keys including the four -arrow keys, the other five keys can be given as -.BR ka1 , -.BR ka3 , -.BR kb2 , -.BR kc1 , -and -.BR kc3 . -These keys are useful when the effects of a 3 by 3 directional pad are needed. -.PP -Strings to program function keys can be given as -.BR pfkey , -.BR pfloc , -and -.BR pfx . -A string to program screen labels should be specified as \fBpln\fP. -Each of these strings takes two parameters: the function key number to -program (from 0 to 10) and the string to program it with. -Function key numbers out of this range may program undefined keys in -a terminal dependent manner. -The difference between the capabilities is that -.B pfkey -causes pressing the given key to be the same as the user typing the -given string; -.B pfloc -causes the string to be executed by the terminal in local; and -.B pfx -causes the string to be transmitted to the computer. -.PP -The capabilities \fBnlab\fP, \fBlw\fP and \fBlh\fP -define the number of programmable -screen labels and their width and height. -If there are commands to turn the labels on and off, -give them in \fBsmln\fP and \fBrmln\fP. -\fBsmln\fP is normally output after one or more pln -sequences to make sure that the change becomes visible. -.PP -.SS Tabs and Initialization -.PP -If the terminal has hardware tabs, the command to advance to the next -tab stop can be given as -.B ht -(usually control I). -A ``back-tab'' command which moves leftward to the preceding tab stop can -be given as -.BR cbt . -By convention, if the teletype modes indicate that tabs are being -expanded by the computer rather than being sent to the terminal, -programs should not use -.B ht -or -.B cbt -even if they are present, since the user may not have the tab stops -properly set. -If the terminal has hardware tabs which are initially set every -.I n -spaces when the terminal is powered up, -the numeric parameter -.B it -is given, showing the number of spaces the tabs are set to. -This is normally used by the -.IR tset -command to determine whether to set the mode for hardware tab expansion, -and whether to set the tab stops. -If the terminal has tab stops that can be saved in non-volatile memory, -the terminfo description can assume that they are properly set. -.PP -Other capabilities -include -.BR is1 , -.BR is2 , -and -.BR is3 , -initialization strings for the terminal, -.BR iprog , -the path name of a program to be run to initialize the terminal, -and \fBif\fR, the name of a file containing long initialization strings. -These strings are expected to set the terminal into modes consistent -with the rest of the terminfo description. -They are normally sent to the terminal, by the -.I init -option of the -.IR tput -program, each time the user logs in. -They will be printed in the following order: -run the program -.BR iprog ; -output -.BR is1 ; -.BR is2 ; -set the margins using -.BR mgc , -.BR smgl -and -.BR smgr ; -set tabs using -.B tbc -and -.BR hts ; -print the file -.BR if ; -and finally -output -.BR is3 . -.PP -Most initialization is done with -.BR is2 . -Special terminal modes can be set up without duplicating strings -by putting the common sequences in -.B is2 -and special cases in -.B is1 -and -.BR is3 . -A pair of sequences that does a harder reset from a totally unknown state -can be analogously given as -.BR rs1 , -.BR rs2 , -.BR rf , -and -.BR rs3 , -analogous to -.B is2 -and -.BR if . -These strings are output by the -.IR reset -program, which is used when the terminal gets into a wedged state. -Commands are normally placed in -.BR rs1 , -.BR rs2 -.B rs3 -and -.B rf -only if they produce annoying effects on the screen and are not -necessary when logging in. -For example, the command to set the vt100 into 80-column mode would -normally be part of -.BR is2 , -but it causes an annoying glitch of the screen and is not normally -needed since the terminal is usually already in 80 column mode. -.PP -If there are commands to set and clear tab stops, they can be given as -.B tbc -(clear all tab stops) -and -.B hts -(set a tab stop in the current column of every row). -If a more complex sequence is needed to set the tabs than can be -described by this, the sequence can be placed in -.B is2 -or -.BR if . -.SS Delays and Padding -.PP -Many older and slower terminals don't support either XON/XOFF or DTR -handshaking, including hard copy terminals and some very archaic CRTs -(including, for example, DEC VT100s). -These may require padding characters -after certain cursor motions and screen changes. -.PP -If the terminal uses xon/xoff handshaking for flow control (that is, -it automatically emits ^S back to the host when its input buffers are -close to full), set -.BR xon . -This capability suppresses the emission of padding. -You can also set it -for memory-mapped console devices effectively that don't have a speed limit. -Padding information should still be included so that routines can -make better decisions about relative costs, but actual pad characters will -not be transmitted. -.PP -If \fBpb\fR (padding baud rate) is given, padding is suppressed at baud rates -below the value of \fBpb\fR. -If the entry has no padding baud rate, then -whether padding is emitted or not is completely controlled by \fBxon\fR. -.PP -If the terminal requires other than a null (zero) character as a pad, -then this can be given as \fBpad\fR. -Only the first character of the -.B pad -string is used. -.PP -.SS Status Lines -Some terminals have an extra `status line' which is not normally used by -software (and thus not counted in the terminal's \fBlines\fR capability). -.PP -The simplest case is a status line which is cursor-addressable but not -part of the main scrolling region on the screen; the Heathkit H19 has -a status line of this kind, as would a 24-line VT100 with a 23-line -scrolling region set up on initialization. -This situation is indicated -by the \fBhs\fR capability. -.PP -Some terminals with status lines need special sequences to access the -status line. -These may be expressed as a string with single parameter -\fBtsl\fR which takes the cursor to a given zero-origin column on the -status line. -The capability \fBfsl\fR must return to the main-screen -cursor positions before the last \fBtsl\fR. -You may need to embed the -string values of \fBsc\fR (save cursor) and \fBrc\fR (restore cursor) -in \fBtsl\fR and \fBfsl\fR to accomplish this. -.PP -The status line is normally assumed to be the same width as the width -of the terminal. -If this is untrue, you can specify it with the numeric -capability \fBwsl\fR. -.PP -A command to erase or blank the status line may be specified as \fBdsl\fR. -.PP -The boolean capability \fBeslok\fR specifies that escape sequences, tabs, -etc., work ordinarily in the status line. -.PP -The \fBncurses\fR implementation does not yet use any of these capabilities. -They are documented here in case they ever become important. -.PP -.SS Line Graphics -.PP -Many terminals have alternate character sets useful for forms-drawing. -Terminfo and \fBcurses\fR build in support for the drawing characters -supported by the VT100, with some characters from the AT&T 4410v1 added. -This alternate character set may be specified by the \fBacsc\fR capability. -.PP -.TS H -center expand; -c l l c -c l l c -lw28 lw6 lw2 lw20. -.\".TH -\fBGlyph ACS Ascii VT100\fR -\fBName Name Default Name\fR -UK pound sign ACS_STERLING f } -arrow pointing down ACS_DARROW v . -arrow pointing left ACS_LARROW < , -arrow pointing right ACS_RARROW > + -arrow pointing up ACS_UARROW ^ - -board of squares ACS_BOARD # h -bullet ACS_BULLET o ~ -checker board (stipple) ACS_CKBOARD : a -degree symbol ACS_DEGREE \e f -diamond ACS_DIAMOND + ` -greater-than-or-equal-to ACS_GEQUAL > z -greek pi ACS_PI * { -horizontal line ACS_HLINE - q -lantern symbol ACS_LANTERN # i -large plus or crossover ACS_PLUS + n -less-than-or-equal-to ACS_LEQUAL < y -lower left corner ACS_LLCORNER + m -lower right corner ACS_LRCORNER + j -not-equal ACS_NEQUAL ! | -plus/minus ACS_PLMINUS # g -scan line 1 ACS_S1 ~ o -scan line 3 ACS_S3 - p -scan line 7 ACS_S7 - r -scan line 9 ACS_S9 \&_ s -solid square block ACS_BLOCK # 0 -tee pointing down ACS_TTEE + w -tee pointing left ACS_RTEE + u -tee pointing right ACS_LTEE + t -tee pointing up ACS_BTEE + v -upper left corner ACS_ULCORNER + l -upper right corner ACS_URCORNER + k -vertical line ACS_VLINE | x -.TE -.PP -The best way to define a new device's graphics set is to add a column -to a copy of this table for your terminal, giving the character which -(when emitted between \fBsmacs\fR/\fBrmacs\fR switches) will be rendered -as the corresponding graphic. -Then read off the VT100/your terminal -character pairs right to left in sequence; these become the ACSC string. -.PP -.SS Color Handling -.PP -Most color terminals are either `Tektronix-like' or `HP-like'. -Tektronix-like -terminals have a predefined set of N colors (where N usually 8), and can set -character-cell foreground and background characters independently, mixing them -into N * N color-pairs. -On HP-like terminals, the use must set each color -pair up separately (foreground and background are not independently settable). -Up to M color-pairs may be set up from 2*M different colors. -ANSI-compatible -terminals are Tektronix-like. -.PP -Some basic color capabilities are independent of the color method. -The numeric -capabilities \fBcolors\fR and \fBpairs\fR specify the maximum numbers of colors -and color-pairs that can be displayed simultaneously. -The \fBop\fR (original -pair) string resets foreground and background colors to their default values -for the terminal. -The \fBoc\fR string resets all colors or color-pairs to -their default values for the terminal. -Some terminals (including many PC -terminal emulators) erase screen areas with the current background color rather -than the power-up default background; these should have the boolean capability -\fBbce\fR. -.PP -To change the current foreground or background color on a Tektronix-type -terminal, use \fBsetaf\fR (set ANSI foreground) and \fBsetab\fR (set ANSI -background) or \fBsetf\fR (set foreground) and \fBsetb\fR (set background). -These take one parameter, the color number. -The SVr4 documentation describes -only \fBsetaf\fR/\fBsetab\fR; the XPG4 draft says that "If the terminal -supports ANSI escape sequences to set background and foreground, they should -be coded as \fBsetaf\fR and \fBsetab\fR, respectively. -If the terminal -supports other escape sequences to set background and foreground, they should -be coded as \fBsetf\fR and \fBsetb\fR, respectively. -The \fIvidputs()\fR -function and the refresh functions use \fBsetaf\fR and \fBsetab\fR if they are -defined." -.PP -The \fBsetaf\fR/\fBsetab\fR and \fBsetf\fR/\fBsetb\fR capabilities take a -single numeric argument each. -Argument values 0-7 of \fBsetaf\fR/\fBsetab\fR are portably defined as -follows (the middle column is the symbolic #define available in the header for -the \fBcurses\fR or \fBncurses\fR libraries). -The terminal hardware is free to -map these as it likes, but the RGB values indicate normal locations in color -space. -.PP -.TS H -center; -l c c c -l l n l. -\fBColor #define Value RGB\fR -black \fBCOLOR_BLACK\fR 0 0, 0, 0 -red \fBCOLOR_RED\ \fR 1 max,0,0 -green \fBCOLOR_GREEN\fR 2 0,max,0 -yellow \fBCOLOR_YELLOW\fR 3 max,max,0 -blue \fBCOLOR_BLUE\fR 4 0,0,max -magenta \fBCOLOR_MAGENTA\fR 5 max,0,max -cyan \fBCOLOR_CYAN\fR 6 0,max,max -white \fBCOLOR_WHITE\fR 7 max,max,max -.TE -.PP -The argument values of \fBsetf\fR/\fBsetb\fR historically correspond to -a different mapping, i.e., -.TS H -center; -l c c c -l l n l. -\fBColor #define Value RGB\fR -black \fBCOLOR_BLACK\fR 0 0, 0, 0 -blue \fBCOLOR_BLUE\fR 1 0,0,max -green \fBCOLOR_GREEN\fR 2 0,max,0 -cyan \fBCOLOR_CYAN\fR 3 0,max,max -red \fBCOLOR_RED\ \fR 4 max,0,0 -magenta \fBCOLOR_MAGENTA\fR 5 max,0,max -yellow \fBCOLOR_YELLOW\fR 6 max,max,0 -white \fBCOLOR_WHITE\fR 7 max,max,max -.TE -It is important to not confuse the two sets of color capabilities; -otherwise red/blue will be interchanged on the display. -.PP -On an HP-like terminal, use \fBscp\fR with a color-pair number parameter to set -which color pair is current. -.PP -On a Tektronix-like terminal, the capability \fBccc\fR may be present to -indicate that colors can be modified. -If so, the \fBinitc\fR capability will -take a color number (0 to \fBcolors\fR - 1)and three more parameters which -describe the color. -These three parameters default to being interpreted as RGB -(Red, Green, Blue) values. -If the boolean capability \fBhls\fR is present, -they are instead as HLS (Hue, Lightness, Saturation) indices. -The ranges are -terminal-dependent. -.PP -On an HP-like terminal, \fBinitp\fR may give a capability for changing a -color-pair value. -It will take seven parameters; a color-pair number (0 to -\fBmax_pairs\fR - 1), and two triples describing first background and then -foreground colors. -These parameters must be (Red, Green, Blue) or -(Hue, Lightness, Saturation) depending on \fBhls\fR. -.PP -On some color terminals, colors collide with highlights. -You can register -these collisions with the \fBncv\fR capability. -This is a bit-mask of -attributes not to be used when colors are enabled. -The correspondence with the -attributes understood by \fBcurses\fR is as follows: -.PP -.TS -center; -l c c -lw25 lw2 lw10. -\fBAttribute Bit Decimal\fR -A_STANDOUT 0 1 -A_UNDERLINE 1 2 -A_REVERSE 2 4 -A_BLINK 3 8 -A_DIM 4 16 -A_BOLD 5 32 -A_INVIS 6 64 -A_PROTECT 7 128 -A_ALTCHARSET 8 256 -.TE -.PP -For example, on many IBM PC consoles, the underline attribute collides with the -foreground color blue and is not available in color mode. -These should have -an \fBncv\fR capability of 2. -.PP -SVr4 curses does nothing with \fBncv\fR, ncurses recognizes it and optimizes -the output in favor of colors. -.PP -.SS Miscellaneous -If the terminal requires other than a null (zero) character as a pad, then this -can be given as pad. -Only the first character of the pad string is used. -If the terminal does not have a pad character, specify npc. -Note that ncurses implements the termcap-compatible \fBPC\fR variable; -though the application may set this value to something other than -a null, ncurses will test \fBnpc\fR first and use napms if the terminal -has no pad character. -.PP -If the terminal can move up or down half a line, -this can be indicated with -.B hu -(half-line up) -and -.B hd -(half-line down). -This is primarily useful for superscripts and subscripts on hard-copy terminals. -If a hard-copy terminal can eject to the next page (form feed), give this as -.B ff -(usually control L). -.PP -If there is a command to repeat a given character a given number of -times (to save time transmitting a large number of identical characters) -this can be indicated with the parameterized string -.BR rep . -The first parameter is the character to be repeated and the second -is the number of times to repeat it. -Thus, tparm(repeat_char, 'x', 10) is the same as `xxxxxxxxxx'. -.PP -If the terminal has a settable command character, such as the \s-1TEKTRONIX\s+1 4025, -this can be indicated with -.BR cmdch . -A prototype command character is chosen which is used in all capabilities. -This character is given in the -.B cmdch -capability to identify it. -The following convention is supported on some UNIX systems: -The environment is to be searched for a -.B CC -variable, and if found, all -occurrences of the prototype character are replaced with the character -in the environment variable. -.PP -Terminal descriptions that do not represent a specific kind of known -terminal, such as -.IR switch , -.IR dialup , -.IR patch , -and -.IR network , -should include the -.B gn -(generic) capability so that programs can complain that they do not know -how to talk to the terminal. -(This capability does not apply to -.I virtual -terminal descriptions for which the escape sequences are known.) -.PP -If the terminal has a ``meta key'' which acts as a shift key, -setting the 8th bit of any character transmitted, this fact can -be indicated with -.BR km . -Otherwise, software will assume that the 8th bit is parity and it -will usually be cleared. -If strings exist to turn this ``meta mode'' on and off, they -can be given as -.B smm -and -.BR rmm . -.PP -If the terminal has more lines of memory than will fit on the screen -at once, the number of lines of memory can be indicated with -.BR lm . -A value of -.BR lm #0 -indicates that the number of lines is not fixed, -but that there is still more memory than fits on the screen. -.PP -If the terminal is one of those supported by the \s-1UNIX\s+1 virtual -terminal protocol, the terminal number can be given as -.BR vt . -.PP -Media copy -strings which control an auxiliary printer connected to the terminal -can be given as -.BR mc0 : -print the contents of the screen, -.BR mc4 : -turn off the printer, and -.BR mc5 : -turn on the printer. -When the printer is on, all text sent to the terminal will be sent -to the printer. -It is undefined whether the text is also displayed on the terminal screen -when the printer is on. -A variation -.B mc5p -takes one parameter, and leaves the printer on for as many characters -as the value of the parameter, then turns the printer off. -The parameter should not exceed 255. -All text, including -.BR mc4 , -is transparently passed to the printer while an -.B mc5p -is in effect. -.PP -.SS Glitches and Braindamage -.PP -Hazeltine terminals, which do not allow `~' characters to be displayed should -indicate \fBhz\fR. -.PP -Terminals which ignore a line-feed immediately after an \fBam\fR wrap, -such as the Concept and vt100, -should indicate \fBxenl\fR. -.PP -If -.B el -is required to get rid of standout -(instead of merely writing normal text on top of it), -\fBxhp\fP should be given. -.PP -Teleray terminals, where tabs turn all characters moved over to blanks, -should indicate \fBxt\fR (destructive tabs). -Note: the variable indicating this is now `dest_tabs_magic_smso'; in -older versions, it was teleray_glitch. -This glitch is also taken to mean that it is not possible to position -the cursor on top of a ``magic cookie'', -that to erase standout mode it is instead necessary to use -delete and insert line. -The ncurses implementation ignores this glitch. -.PP -The Beehive Superbee, which is unable to correctly transmit the escape -or control C characters, has -.BR xsb , -indicating that the f1 key is used for escape and f2 for control C. -(Only certain Superbees have this problem, depending on the ROM.) -Note that in older terminfo versions, this capability was called -`beehive_glitch'; it is now `no_esc_ctl_c'. -.PP -Other specific terminal problems may be corrected by adding more -capabilities of the form \fBx\fR\fIx\fR. -.PP -.SS Similar Terminals -.PP -If there are two very similar terminals, one (the variant) can be defined as -being just like the other (the base) with certain exceptions. -In the -definition of the variant, the string capability \fBuse\fR can be given with -the name of the base terminal. -The capabilities given before -.B use -override those in the base type named by -.BR use . -If there are multiple \fBuse\fR capabilities, they are merged in reverse order. -That is, the rightmost \fBuse\fR reference is processed first, then the one to -its left, and so forth. -Capabilities given explicitly in the entry override -those brought in by \fBuse\fR references. -.PP -A capability can be canceled by placing \fBxx@\fR to the left of the -use reference that imports it, where \fIxx\fP is the capability. -For example, the entry -.PP - 2621-nl, smkx@, rmkx@, use=2621, -.PP -defines a 2621-nl that does not have the \fBsmkx\fR or \fBrmkx\fR capabilities, -and hence does not turn on the function key labels when in visual mode. -This is useful for different modes for a terminal, or for different -user preferences. -.PP -.SS Pitfalls of Long Entries -.PP -Long terminfo entries are unlikely to be a problem; to date, no entry has even -approached terminfo's 4K string-table maximum. -Unfortunately, the termcap -translations are much more strictly limited (to 1K), thus termcap translations -of long terminfo entries can cause problems. -.PP -The man pages for 4.3BSD and older versions of tgetent() instruct the user to -allocate a 1K buffer for the termcap entry. -The entry gets null-terminated by -the termcap library, so that makes the maximum safe length for a termcap entry -1k-1 (1023) bytes. -Depending on what the application and the termcap library -being used does, and where in the termcap file the terminal type that tgetent() -is searching for is, several bad things can happen. -.PP -Some termcap libraries print a warning message or exit if they find an -entry that's longer than 1023 bytes; others don't; others truncate the -entries to 1023 bytes. -Some application programs allocate more than -the recommended 1K for the termcap entry; others don't. -.PP -Each termcap entry has two important sizes associated with it: before -"tc" expansion, and after "tc" expansion. -"tc" is the capability that -tacks on another termcap entry to the end of the current one, to add -on its capabilities. -If a termcap entry doesn't use the "tc" -capability, then of course the two lengths are the same. -.PP -The "before tc expansion" length is the most important one, because it -affects more than just users of that particular terminal. -This is the -length of the entry as it exists in /etc/termcap, minus the -backslash-newline pairs, which tgetent() strips out while reading it. -Some termcap libraries strip off the final newline, too (GNU termcap does not). -Now suppose: -.TP 5 -* -a termcap entry before expansion is more than 1023 bytes long, -.TP 5 -* -and the application has only allocated a 1k buffer, -.TP 5 -* -and the termcap library (like the one in BSD/OS 1.1 and GNU) reads -the whole entry into the buffer, no matter what its length, to see -if it's the entry it wants, -.TP 5 -* -and tgetent() is searching for a terminal type that either is the -long entry, appears in the termcap file after the long entry, or -doesn't appear in the file at all (so that tgetent() has to search -the whole termcap file). -.PP -Then tgetent() will overwrite memory, perhaps its stack, and probably core dump -the program. -Programs like telnet are particularly vulnerable; modern telnets -pass along values like the terminal type automatically. -The results are almost -as undesirable with a termcap library, like SunOS 4.1.3 and Ultrix 4.4, that -prints warning messages when it reads an overly long termcap entry. -If a -termcap library truncates long entries, like OSF/1 3.0, it is immune to dying -here but will return incorrect data for the terminal. -.PP -The "after tc expansion" length will have a similar effect to the -above, but only for people who actually set TERM to that terminal -type, since tgetent() only does "tc" expansion once it's found the -terminal type it was looking for, not while searching. -.PP -In summary, a termcap entry that is longer than 1023 bytes can cause, -on various combinations of termcap libraries and applications, a core -dump, warnings, or incorrect operation. -If it's too long even before -"tc" expansion, it will have this effect even for users of some other -terminal types and users whose TERM variable does not have a termcap -entry. -.PP -When in -C (translate to termcap) mode, the \fBncurses\fR implementation of -\fBtic\fR(1) issues warning messages when the pre-tc length of a termcap -translation is too long. -The -c (check) option also checks resolved (after tc -expansion) lengths. -.SS Binary Compatibility -It is not wise to count on portability of binary terminfo entries between -commercial UNIX versions. -The problem is that there are at least two versions -of terminfo (under HP-UX and AIX) which diverged from System V terminfo after -SVr1, and have added extension capabilities to the string table that (in the -binary format) collide with System V and XSI Curses extensions. -.SH EXTENSIONS -Some SVr4 \fBcurses\fR implementations, and all previous to SVr4, don't -interpret the %A and %O operators in parameter strings. -.PP -SVr4/XPG4 do not specify whether \fBmsgr\fR licenses movement while in -an alternate-character-set mode (such modes may, among other things, map -CR and NL to characters that don't trigger local motions). -The \fBncurses\fR implementation ignores \fBmsgr\fR in \fBALTCHARSET\fR -mode. -This raises the possibility that an XPG4 -implementation making the opposite interpretation may need terminfo -entries made for \fBncurses\fR to have \fBmsgr\fR turned off. -.PP -The \fBncurses\fR library handles insert-character and insert-character modes -in a slightly non-standard way to get better update efficiency. -See -the \fBInsert/Delete Character\fR subsection above. -.PP -The parameter substitutions for \fBset_clock\fR and \fBdisplay_clock\fR are -not documented in SVr4 or the XSI Curses standard. -They are deduced from the -documentation for the AT&T 505 terminal. -.PP -Be careful assigning the \fBkmous\fR capability. -The \fBncurses\fR wants to -interpret it as \fBKEY_MOUSE\fR, for use by terminals and emulators like xterm -that can return mouse-tracking information in the keyboard-input stream. -.PP -Different commercial ports of terminfo and curses support different subsets of -the XSI Curses standard and (in some cases) different extension sets. -Here -is a summary, accurate as of October 1995: -.PP -\fBSVR4, Solaris, ncurses\fR -- -These support all SVr4 capabilities. -.PP -\fBSGI\fR -- -Supports the SVr4 set, adds one undocumented extended string -capability (\fBset_pglen\fR). -.PP -\fBSVr1, Ultrix\fR -- -These support a restricted subset of terminfo capabilities. -The booleans -end with \fBxon_xoff\fR; the numerics with \fBwidth_status_line\fR; and the -strings with \fBprtr_non\fR. -.PP -\fBHP/UX\fR -- -Supports the SVr1 subset, plus the SVr[234] numerics \fBnum_labels\fR, -\fBlabel_height\fR, \fBlabel_width\fR, plus function keys 11 through 63, plus -\fBplab_norm\fR, \fBlabel_on\fR, and \fBlabel_off\fR, plus some incompatible -extensions in the string table. -.PP -\fBAIX\fR -- -Supports the SVr1 subset, plus function keys 11 through 63, plus a number -of incompatible string table extensions. -.PP -\fBOSF\fR -- -Supports both the SVr4 set and the AIX extensions. -.SH FILES -.TP 25 -\*d/?/* -files containing terminal descriptions -.SH SEE ALSO -\fBtic\fR(1M), \fBcurses\fR(3X), \fBprintf\fR(3S), \fBterm\fR(\*n). -.SH AUTHORS -Zeyd M. Ben-Halim, Eric S. Raymond, Thomas E. Dickey. -Based on pcurses by Pavel Curtis. -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/tic.1m b/contrib/ncurses-5.4/man/tic.1m deleted file mode 100644 index 29d5261972..0000000000 --- a/contrib/ncurses-5.4/man/tic.1m +++ /dev/null @@ -1,311 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: tic.1m,v 1.35 2003/05/11 00:32:53 tom Exp $ -.TH tic 1M "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBtic\fR - the \fIterminfo\fR entry-description compiler -.SH SYNOPSIS -\fBtic\fR -[\fB\-\ -1\ -C\ -G\ -I\ -L\ -N\ -T\ -V\ -a\ -c\ -f\ -g\ -r\ -s\ -t\ -x\ -\fR] -[\fB\-e\fR \fInames\fR] -[\fB\-o\fR \fIdir\fR] -[\fB\-R\fR \fIsubset\fR] -[\fB\-v\fR[\fIn\fR]] -[\fB\-w\fR[\fIn\fR]] -\fIfile\fR -.br -.SH DESCRIPTION -The command \fBtic\fR translates a \fBterminfo\fR file from source -format into compiled format. The compiled format is necessary for use with -the library routines in \fBncurses\fR(3X). -.PP -The results are normally placed in the system terminfo -directory \fB\*d\fR. There are two ways to change this behavior. -.PP -First, you may override the system default by setting the variable -\fBTERMINFO\fR in your shell environment to a valid (existing) directory name. -.PP -Secondly, if \fBtic\fR cannot get access to \fI\*d\fR or your TERMINFO -directory, it looks for the directory \fI$HOME/.terminfo\fR; if that directory -exists, the entry is placed there. -.PP -Libraries that read terminfo entries are expected to check for a TERMINFO -directory first, look at \fI$HOME/.terminfo\fR if TERMINFO is not set, and -finally look in \fI\*d\fR. -.TP -\fB\-1\fR -restricts the output to a single column -.TP -\fB\-a\fR -tells \fBtic\fP to retain commented-out capabilities rather than discarding -them. Capabilities are commented by prefixing them with a period. -This sets the \fB\-x\fR option, because it treats the commented-out -entries as user-defined names. -.TP -\fB\-C\fR -Force source translation to termcap format. Note: this differs from the \fB\-C\fR -option of \fIinfocmp\fR(1M) in that it does not merely translate capability -names, but also translates terminfo strings to termcap format. Capabilities -that are not translatable are left in the entry under their terminfo names -but commented out with two preceding dots. -.TP -\fB\-c\fR -tells \fBtic\fP to only check \fIfile\fR for errors, including syntax problems and -bad use links. If you specify \fB\-C\fR (\fB\-I\fR) with this option, the code -will print warnings about entries which, after use resolution, are more than -1023 (4096) bytes long. Due to a fixed buffer length in older termcap -libraries (and a documented limit in terminfo), these entries may cause core -dumps. -.TP -\fB\-e \fR\fInames\fR -Limit writes and translations to the following comma-separated list of -terminals. -If any name or alias of a terminal matches one of the names in -the list, the entry will be written or translated as normal. -Otherwise no output will be generated for it. -The option value is interpreted as a file containing the list if it -contains a '/'. -(Note: depending on how tic was compiled, this option may require \fB\-I\fR or \fB\-C\fR.) -.TP -\fB\-f\fR -Display complex terminfo strings which contain if/then/else/endif expressions -indented for readability. -.TP -\fB\-G\fR -Display constant literals in decimal form -rather than their character equivalents. -.TP -\fB\-g\fR -Display constant character literals in quoted form -rather than their decimal equivalents. -.TP -\fB\-I\fR -Force source translation to terminfo format. -.TP -\fB\-L\fR -Force source translation to terminfo format -using the long C variable names listed in <\fBterm.h\fR> -.TP -\fB\-N\fR -Disable smart defaults. -Normally, when translating from termcap to terminfo, the compiler makes -a number of assumptions about the defaults of string capabilities -\fBreset1_string\fR, \fBcarriage_return\fR, \fBcursor_left\fR, -\fBcursor_down\fR, \fBscroll_forward\fR, \fBtab\fR, \fBnewline\fR, -\fBkey_backspace\fR, \fBkey_left\fR, and \fBkey_down\fR, then attempts -to use obsolete termcap capabilities to deduce correct values. It also -normally suppresses output of obsolete termcap capabilities such as \fBbs\fR. -This option forces a more literal translation that also preserves the -obsolete capabilities. -.TP -\fB\-o\fR\fIdir\fR -Write compiled entries to given directory. Overrides the TERMINFO environment -variable. -.TP -\fB\-R\fR\fIsubset\fR -Restrict output to a given subset. This option is for use with archaic -versions of terminfo like those on SVr1, Ultrix, or HP/UX that do not support -the full set of SVR4/XSI Curses terminfo; and outright broken ports like AIX 3.x -that have their own extensions incompatible with SVr4/XSI. Available subsets -are "SVr1", "Ultrix", "HP", "BSD" and "AIX"; see \fBterminfo\fR(\*n) for details. -.TP -\fB\-r\fR -Force entry resolution (so there are no remaining tc capabilities) even -when doing translation to termcap format. This may be needed if you are -preparing a termcap file for a termcap library (such as GNU termcap through -version 1.3 or BSD termcap through 4.3BSD) that does not handle multiple -tc capabilities per entry. -.TP -\fB\-s\fR -Summarize the compile by showing the directory into which entries -are written, and the number of entries which are compiled. -.TP -\fB\-T\fR -eliminates size-restrictions on the generated text. -This is mainly useful for testing and analysis, since the compiled -descriptions are limited (e.g., 1023 for termcap, 4096 for terminfo). -.TP -\fB\-t\fR -tells \fBtic\fP to discard commented-out capabilities. -Normally when translating from terminfo to termcap, -untranslatable capabilities are commented-out. -.TP -\fB\-V\fR -reports the version of ncurses which was used in this program, and exits. -.TP -\fB\-v\fR\fIn\fR -specifies that (verbose) output be written to standard error trace -information showing \fBtic\fR's progress. The optional integer -\fIn\fR is a number from 1 to 10, inclusive, indicating the desired -level of detail of information. If \fIn\fR is omitted, the default -level is 1. If \fIn\fR is specified and greater than 1, the level of -detail is increased. -.TP -\fB\-w\fR\fIn\fR -specifies the width of the output. -.TP -\fB\-x\fR -Treat unknown capabilities as user-defined. -That is, if you supply a capability name which \fBtic\fP does not recognize, -it will infer its type (boolean, number or string) from the syntax and -make an extended table entry for that. -.TP -\fIfile\fR -contains one or more \fBterminfo\fR terminal descriptions in source -format [see \fBterminfo\fR(\*n)]. Each description in the file -describes the capabilities of a particular terminal. -.PP -The debug flag levels are as follows: -.TP -1 -Names of files created and linked -.TP -2 -Information related to the ``use'' facility -.TP -3 -Statistics from the hashing algorithm -.TP -5 -String-table memory allocations -.TP -7 -Entries into the string-table -.TP -8 -List of tokens encountered by scanner -.TP -9 -All values computed in construction of the hash table -.LP -If the debug level \fIn\fR is not given, it is taken to be one. -.PP -All but one of the capabilities recognized by \fBtic\fR are documented -in \fBterminfo\fR(\*n). The exception is the \fBuse\fR capability. - -When a \fBuse\fR=\fIentry\fR-\fIname\fR field is discovered in a -terminal entry currently being compiled, \fBtic\fR reads in the binary -from \fB\*d\fR to complete the entry. (Entries created from -\fIfile\fR will be used first. If the environment variable -\fBTERMINFO\fR is set, that directory is searched instead of -\fB\*d\fR.) \fBtic\fR duplicates the capabilities in -\fIentry\fR-\fIname\fR for the current entry, with the exception of -those capabilities that explicitly are defined in the current entry. - -When an entry, e.g., \fBentry_name_1\fR, contains a -\fBuse=\fR\fIentry\fR_\fIname\fR_\fI2\fR field, any canceled -capabilities in \fIentry\fR_\fIname\fR_\fI2\fR must also appear in -\fBentry_name_1\fR before \fBuse=\fR for these capabilities to be -canceled in \fBentry_name_1\fR. - -If the environment variable \fBTERMINFO\fR is set, the compiled -results are placed there instead of \fB\*d\fR. - -Total compiled entries cannot exceed 4096 bytes. The name field cannot -exceed 512 bytes. Terminal names exceeding the maximum alias length -(32 characters on systems with long filenames, 14 characters otherwise) -will be truncated to the maximum alias length and a warning message will be printed. -.SH COMPATIBILITY -There is some evidence that historic \fBtic\fR implementations treated -description fields with no whitespace in them as additional aliases or -short names. This \fBtic\fR does not do that, but it does warn when -description fields may be treated that way and check them for dangerous -characters. -.SH EXTENSIONS -Unlike the stock SVr4 \fBtic\fR command, this implementation can actually -compile termcap sources. In fact, entries in terminfo and termcap syntax can -be mixed in a single source file. See \fBterminfo\fR(\*n) for the list of -termcap names taken to be equivalent to terminfo names. - -The SVr4 manual pages are not clear on the resolution rules for \fBuse\fR -capabilities. -This implementation of \fBtic\fR will find \fBuse\fR targets anywhere -in the source file, or anywhere in the file tree rooted at \fBTERMINFO\fR (if -\fBTERMINFO\fR is defined), or in the user's \fI$HOME/.terminfo\fR directory -(if it exists), or (finally) anywhere in the system's file tree of -compiled entries. - -The error messages from this \fBtic\fR have the same format as GNU C -error messages, and can be parsed by GNU Emacs's compile facility. - -The -\fB\-C\fR, -\fB\-G\fR, -\fB\-I\fR, -\fB\-N\fR, -\fB\-R\fR, -\fB\-T\fR, -\fB\-V\fR, -\fB\-a\fR, -\fB\-e\fR, -\fB\-f\fR, -\fB\-g\fR, -\fB\-o\fR, -\fB\-r\fR, -\fB\-s\fR, -\fB\-t\fR and -\fB\-x\fR -options -are not supported under SVr4. -The SVr4 \fB\-c\fR mode does not report bad use links. - -System V does not compile entries to or read entries from your -\fI$HOME/.terminfo\fR directory unless TERMINFO is explicitly set to it. -.SH FILES -.TP 5 -\fB\*d/?/*\fR -Compiled terminal description database. -.SH SEE ALSO -\fB@INFOCMP@\fR(1M), \fB@CAPTOINFO@\fR(1M), \fB@INFOTOCAP@\fR(1M), -\fB@TOE@\fR(1M), \fBcurses\fR(3X), \fBterminfo\fR(\*n). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/toe.1m b/contrib/ncurses-5.4/man/toe.1m deleted file mode 100644 index 4e69f55f33..0000000000 --- a/contrib/ncurses-5.4/man/toe.1m +++ /dev/null @@ -1,81 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: toe.1m,v 1.12 2003/05/11 00:32:53 tom Exp $ -.TH toe 1M "" -.ds n 5 -.ds d @TERMINFO@ -.SH NAME -\fBtoe\fR - table of (terminfo) entries -.SH SYNOPSIS -\fBtoe\fR [\fB\-v\fR[\fIn\fR]] [\fB\-huUV\fR] \fIfile...\fR -.br -.SH DESCRIPTION -.PP -With no options, \fBtoe\fR lists all available terminal types by primary name -with descriptions. File arguments specify the directories to be scanned; if no -such arguments are given, your default terminfo directory is scanned. If you -also specify the \fB\-h\fR option, a directory header will be issued as each -directory is entered. -.PP -There are other options intended for use by terminfo file maintainers: -.TP -\fB\-u\fR \fIfile\fR -says to issue a report on dependencies in the given file. This report condenses -the `use' relation: each line consists of the primary name of a terminal that -has use capabilities, followed by a colon, followed by the -whitespace-separated primary names of all terminals which occur in those use -capabilities, followed by a newline -.TP -\fB\-U\fR \fIfile\fR -says to issue a report on reverse dependencies in the given file. This report -reverses the `use' relation: each line consists of the primary name of a -terminal that occurs in use capabilities, followed by a colon, followed by the -whitespace-separated primary names of all terminals which depend on it, -followed by a newline. -.TP -\fB\-v\fR\fIn\fR -specifies that (verbose) output be written to standard error trace -information showing \fBtoe\fR's progress. The optional integer -\fIn\fR is a number from 1 to 10, interpreted as for \fBtic\fR(1). -.TP 5 -\fB\-V\fR -reports the version of ncurses which was used in this program, and exits. -.SH FILES -.TP 5 -\fB\*d/?/*\fR -Compiled terminal description database. -.SH SEE ALSO -\fB@TIC@\fR(1M), \fB@INFOCMP@\fR(1M), \fB@CAPTOINFO@\fR(1M), -\fB@INFOTOCAP@\fR(1M), \fBcurses\fR(3X), \fBterminfo\fR(\*n). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/tput.1 b/contrib/ncurses-5.4/man/tput.1 deleted file mode 100644 index c657a162d1..0000000000 --- a/contrib/ncurses-5.4/man/tput.1 +++ /dev/null @@ -1,288 +0,0 @@ -'\" t -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: tput.1,v 1.20 2003/05/11 00:32:53 tom Exp $ -.TH tput 1 "" -.ds d @TERMINFO@ -.ds n 1 -.SH NAME -\fBtput\fR, \fBreset\fR - initialize a terminal or query terminfo database -.SH SYNOPSIS -\fBtput\fR [\fB\-T\fR\fItype\fR] \fIcapname\fR [\fIparms\fR ... ] -.br -\fBtput\fR [\fB\-T\fR\fItype\fR] \fBinit\fR -.br -\fBtput\fR [\fB\-T\fR\fItype\fR] \fBreset\fR -.br -\fBtput\fR [\fB\-T\fR\fItype\fR] \fBlongname\fR -.br -\fBtput \-S\fR \fB<<\fR -.br -\fBtput \-V\fR -.br -.SH DESCRIPTION -The \fBtput\fR utility uses the \fBterminfo\fR database to make the -values of terminal-dependent capabilities and information available to -the shell (see \fBsh\fR(1)), to initialize or reset the terminal, or -return the long name of the requested terminal type. \fBtput\fR -outputs a string if the attribute (\fIcap\fRability \fIname\fR) is of -type string, or an integer if the attribute is of type integer. If -the attribute is of type boolean, \fBtput\fR simply sets the exit code -(\fB0\fR for TRUE if the terminal has the capability, \fB1\fR for -FALSE if it does not), and produces no output. Before using a value -returned on standard output, the user should test the exit code -[\fB$?\fR, see \fBsh\fR(1)] to be sure it is \fB0\fR. -(See the \fBEXIT CODES\fR and \fBDIAGNOSTICS\fR sections.) -For a complete list of capabilities -and the \fIcapname\fR associated with each, see \fBterminfo\fR(\*n). -.TP -\fB\-T\fR\fItype\fR -indicates the \fItype\fR of terminal. Normally this option is -unnecessary, because the default is taken from the environment -variable \fBTERM\fR. If \fB\-T\fR is specified, then the shell -variables \fBLINES\fR and \fBCOLUMNS\fR will be ignored,and the -operating system will not be queried for the actual screen size. -.TP -\fIcapname\fR -indicates the attribute from the \fBterminfo\fR database. When -\fBtermcap\fR support is compiled in, the \fBtermcap\fR name for -the attribute is also accepted. -.TP -\fIparms\fR -If the attribute is a string that takes parameters, the arguments -\fIparms\fR will be instantiated into the string. -An all-numeric argument will be passed to the attribute as a number. -.IP -Only a few terminfo capabilities require string parameters; -\fBtput\fR uses a table to decide which to pass as strings. -Normally \fBtput\fR uses \fBtparm\fR (3X) to perform the substitution. -If no parameters are given for the attribute, -\fBtput\fR writes the string without performing the substitution. -.TP -\fB\-S\fR -allows more than one capability per invocation of \fBtput\fR. The -capabilities must be passed to \fBtput\fR from the standard input -instead of from the command line (see example). -Only one \fIcapname\fR is allowed per line. -The \fB\-S\fR option changes the -meaning of the \fB0\fR and \fB1\fR boolean and string exit codes (see the -EXIT CODES section). -.IP -Again, \fBtput\fR uses a table and the presence of parameters in its input -to decide whether to use \fBtparm\fR (3X), -and how to interpret the parameters. -.TP -\fB\-V\fR -reports the version of ncurses which was used in this program, and exits. -.TP -\fBinit\fR -If the \fBterminfo\fR database is present and an entry for the user's -terminal exists (see \fB\-T\fR\fItype\fR, above), the following will -occur: (1) if present, the terminal's initialization strings will be -output (\fBis1\fR, \fBis2\fR, \fBis3\fR, \fBif\fR, \fBiprog\fR), (2) -any delays (e.g., newline) specified in the entry will be set in the -tty driver, (3) tabs expansion will be turned on or off according to -the specification in the entry, and (4) if tabs are not expanded, -standard tabs will be set (every 8 spaces). If an entry does not -contain the information needed for any of the four above activities, -that activity will silently be skipped. -.TP -\fBreset\fR -Instead of putting out initialization strings, the terminal's -reset strings will be output if present (\fBrs1\fR, \fBrs2\fR, \fBrs3\fR, \fBrf\fR). -If the reset strings are not present, but initialization -strings are, the initialization strings will be output. -Otherwise, \fBreset\fR acts identically to \fBinit\fR. -.TP -\fBlongname\fR -If the \fBterminfo\fR database is present and an entry for the -user's terminal exists (see \fB\-T\fR\fItype\fR above), then the long name -of the terminal will be put out. The long name is the last -name in the first line of the terminal's description in the -\fBterminfo\fR database [see \fBterm\fR(5)]. -.PP -If \fBtput\fR is invoked by a link named \fBreset\fR, this has the -same effect as \fBtput reset\fR. -See \fBtset\fR for comparison, which has similar behavior. -.SH EXAMPLES -.TP 5 -\fBtput init\fR -Initialize the terminal according to the type of -terminal in the environmental variable \fBTERM\fR. This -command should be included in everyone's .profile after -the environmental variable \fBTERM\fR has been exported, as -illustrated on the \fBprofile\fR(5) manual page. -.TP 5 -\fBtput \-T5620 reset\fR -Reset an AT&T 5620 terminal, overriding the type of -terminal in the environmental variable \fBTERM\fR. -.TP 5 -\fBtput cup 0 0\fR -Send the sequence to move the cursor to row \fB0\fR, column \fB0\fR -(the upper left corner of the screen, usually known as the "home" -cursor position). -.TP 5 -\fBtput clear\fR -Echo the clear-screen sequence for the current terminal. -.TP 5 -\fBtput cols\fR -Print the number of columns for the current terminal. -.TP 5 -\fBtput \-T450 cols\fR -Print the number of columns for the 450 terminal. -.TP 5 -\fBbold=`tput smso` offbold=`tput rmso`\fR -Set the shell variables \fBbold\fR, to begin stand-out mode -sequence, and \fBoffbold\fR, to end standout mode sequence, -for the current terminal. This might be followed by a -prompt: \fBecho "${bold}Please type in your name: ${offbold}\\c"\fR -.TP 5 -\fBtput hc\fR -Set exit code to indicate if the current terminal is a hard copy terminal. -.TP 5 -\fBtput cup 23 4\fR -Send the sequence to move the cursor to row 23, column 4. -.TP 5 -\fBtput cup\fR -Send the terminfo string for cursor-movement, with no parameters substituted. -.TP 5 -\fBtput longname\fR -Print the long name from the \fBterminfo\fR database for the -type of terminal specified in the environmental -variable \fBTERM\fR. -.PP -.RS 5 -\fBtput \-S < clear\fR -.br -\fB> cup 10 10\fR -.br -\fB> bold\fR -.br -\fB> !\fR -.RE -.TP 5 -\& -This example shows \fBtput\fR processing several capabilities in one invocation. -It clears the screen, -moves the cursor to position 10, 10 -and turns on bold (extra bright) mode. -The list is terminated by an exclamation mark (\fB!\fR) on a line by itself. -.SH FILES -.TP -\fB\*d\fR -compiled terminal description database -.TP -\fB/usr/include/curses.h\fR -\fBcurses\fR(3X) header file -.TP -\fB/usr/include/term.h\fR -\fBterminfo\fR header file -.TP -\fB@DATADIR@/tabset/*\fR -tab settings for some terminals, in a format -appropriate to be output to the terminal (escape -sequences that set margins and tabs); for more -information, see the "Tabs and Initialization" -section of \fBterminfo\fR(5) -.SH EXIT CODES -If the \fB\-S\fR option is used, -\fBtput\fR checks for errors from each line, -and if any errors are found, will set the exit code to 4 plus the -number of lines with errors. -If no errors are found, the exit code is \fB0\fR. -No indication of which line failed can be given so -exit code \fB1\fR will never appear. Exit codes \fB2\fR, \fB3\fR, and -\fB4\fR retain their usual interpretation. -If the \fB\-S\fR option is not used, -the exit code depends on the type of \fIcapname\fR: -.RS 5 -.TP -.I boolean -a value of \fB0\fR is set for TRUE and \fB1\fR for FALSE. -.TP -.I string -a value of \fB0\fR is set if the -\fIcapname\fR is defined for this terminal \fItype\fR (the value of -\fIcapname\fR is returned on standard output); -a value of \fB1\fR is set if \fIcapname\fR -is not defined for this terminal \fItype\fR -(nothing is written to standard output). -.TP -.I integer -a value of \fB0\fR is always set, -whether or not \fIcapname\fR is defined for this terminal \fItype\fR. -To determine if \fIcapname\fR is defined for this terminal \fItype\fR, -the user must test the value written to standard output. -A value of \fB\-1\fR -means that \fIcapname\fR is not defined for this terminal \fItype\fR. -.TP -.I other -\fBreset\fR or \fBinit\fR may fail to find their respective files. -In that case, the exit code is set to 4 + \fBerrno\fR. -.RE -.PP -Any other exit code indicates an error; see the DIAGNOSTICS section. -.SH DIAGNOSTICS -\fBtput\fR prints the following error messages and sets the corresponding exit -codes. -.PP -.ne 15 -.TS -l l. -exit code error message -= -\fB0\fR T{ -(\fIcapname\fR is a numeric variable that is not specified in the -\fBterminfo\fR(\*n) database for this terminal type, e.g. -\fBtput \-T450 lines\fR and \fBtput \-T2621 xmc\fR) -T} -\fB1\fR no error message is printed, see the \fBEXIT CODES\fR section. -\fB2\fR usage error -\fB3\fR unknown terminal \fItype\fR or no \fBterminfo\fR database -\fB4\fR unknown \fBterminfo\fR capability \fIcapname\fR -\fB>4\fR error occurred in \-S -= -.TE -.SH PORTABILITY -The \fBlongname\fR and \fB\-S\fR options, and the parameter-substitution -features used in the \fBcup\fR example, are not supported in BSD curses or in -AT&T/USL curses before SVr4. -.SH SEE ALSO -\fB@CLEAR@\fR(1), -\fBstty\fR(1), -\fBtabs\fR(\*n), -\fBterminfo\fR(5). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/man/tset.1 b/contrib/ncurses-5.4/man/tset.1 deleted file mode 100644 index 3a78b37b47..0000000000 --- a/contrib/ncurses-5.4/man/tset.1 +++ /dev/null @@ -1,253 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2000,2003 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. * -.\"*************************************************************************** -.\" -.\" $Id: tset.1,v 1.13 2003/05/11 00:32:53 tom Exp $ -.TH tset 1 "" -.SH NAME -\fBtset\fR, \fBreset\fR - terminal initialization -.SH SYNOPSIS -tset [\-IQVqrs] [\-] [\-e \fIch\fR] [\-i \fIch\fR] [\-k \fIch\fR] [\-m \fImapping\fR] [\fIterminal\fR] -.br -reset [\-IQVqrs] [\-] [\-e \fIch\fR] [\-i \fIch\fR] [\-k \fIch\fR] [\-m \fImapping\fR] [\fIterminal\fR] -.SH DESCRIPTION -\&\fBTset\fR initializes terminals. -\fBTset\fR first determines the type of terminal that you are using. -This determination is done as follows, using the first terminal type found. -.PP -1. The \fBterminal\fR argument specified on the command line. -.PP -2. The value of the \fBTERM\fR environmental variable. -.PP -3. (BSD systems only.) The terminal type associated with the standard -error output device in the \fI/etc/ttys\fR file. (On Linux and -System-V-like UNIXes, \fIgetty\fR does this job by setting -\fBTERM\fR according to the type passed to it by \fI/etc/inittab\fR.) -.PP -4. The default terminal type, ``unknown''. -.PP -If the terminal type was not specified on the command-line, the \fB\-m\fR -option mappings are then applied (see below for more information). -Then, if the terminal type begins with a question mark (``?''), the -user is prompted for confirmation of the terminal type. An empty -response confirms the type, or, another type can be entered to specify -a new type. Once the terminal type has been determined, the terminfo -entry for the terminal is retrieved. If no terminfo entry is found -for the type, the user is prompted for another terminal type. -.PP -Once the terminfo entry is retrieved, the window size, backspace, interrupt -and line kill characters (among many other things) are set and the terminal -and tab initialization strings are sent to the standard error output. -Finally, if the erase, interrupt and line kill characters have changed, -or are not set to their default values, their values are displayed to the -standard error output. -.PP -When invoked as \fBreset\fR, \fBtset\fR sets cooked and echo modes, -turns off cbreak and raw modes, turns on newline translation and -resets any unset special characters to their default values before -doing the terminal initialization described above. This is useful -after a program dies leaving a terminal in an abnormal state. Note, -you may have to type - - \fBreset\fR - -(the line-feed character is normally control-J) to get the terminal -to work, as carriage-return may no longer work in the abnormal state. -Also, the terminal will often not echo the command. -.PP -The options are as follows: -.TP 5 -.B \-q -The terminal type is displayed to the standard output, and the terminal is -not initialized in any way. The option `-' by itself is equivalent but -archaic. -.TP -.B \-e -Set the erase character to \fIch\fR. -.TP -.B \-I -Do not send the terminal or tab initialization strings to the terminal. -.TP -.B \-Q -Don't display any values for the erase, interrupt and line kill characters. -.TP -.B \-V -reports the version of ncurses which was used in this program, and exits. -.TP -.B \-i -Set the interrupt character to \fIch\fR. -.TP -.B \-k -Set the line kill character to \fIch\fR. -.TP -.B \-m -Specify a mapping from a port type to a terminal. -See below for more information. -.TP -.B \-r -Print the terminal type to the standard error output. -.TP -.B \-s -Print the sequence of shell commands to initialize the environment variable -\fBTERM\fR to the standard output. -See the section below on setting the environment for details. -.PP -The arguments for the \fB-e\fR, \fB-i\fR, and \fB-k\fR -options may either be entered as actual characters or by using the `hat' -notation, i.e. control-h may be specified as ``^H'' or ``^h''. -.SH SETTING THE ENVIRONMENT -It is often desirable to enter the terminal type and information about -the terminal's capabilities into the shell's environment. -This is done using the \fB\-s\fR option. -.PP -When the \fB\-s\fR option is specified, the commands to enter the information -into the shell's environment are written to the standard output. If -the \fBSHELL\fR environmental variable ends in ``csh'', the commands -are for \fBcsh\fR, otherwise, they are for \fBsh\fR. -Note, the \fBcsh\fR commands set and unset the shell variable -\fBnoglob\fR, leaving it unset. The following line in the \fB.login\fR -or \fB.profile\fR files will initialize the environment correctly: - - eval \`tset \-s options ... \` - -.SH TERMINAL TYPE MAPPING -When the terminal is not hardwired into the system (or the current -system information is incorrect) the terminal type derived from the -\fI/etc/ttys\fR file or the \fBTERM\fR environmental variable is often -something generic like \fBnetwork\fR, \fBdialup\fR, or \fBunknown\fR. -When \fBtset\fR is used in a startup script it is often desirable to -provide information about the type of terminal used on such ports. -.PP -The purpose of the \fB\-m\fR option is to map -from some set of conditions to a terminal type, that is, to -tell \fBtset\fR -``If I'm on this port at a particular speed, guess that I'm on that -kind of terminal''. -.PP -The argument to the \fB\-m\fR option consists of an optional port type, an -optional operator, an optional baud rate specification, an optional -colon (``:'') character and a terminal type. The port type is a -string (delimited by either the operator or the colon character). The -operator may be any combination of ``>'', ``<'', ``@'', and ``!''; ``>'' -means greater than, ``<'' means less than, ``@'' means equal to -and ``!'' inverts the sense of the test. -The baud rate is specified as a number and is compared with the speed -of the standard error output (which should be the control terminal). -The terminal type is a string. -.PP -If the terminal type is not specified on the command line, the \fB\-m\fR -mappings are applied to the terminal type. If the port type and baud -rate match the mapping, the terminal type specified in the mapping -replaces the current type. If more than one mapping is specified, the -first applicable mapping is used. -.PP -For example, consider the following mapping: \fBdialup>9600:vt100\fR. -The port type is dialup , the operator is >, the baud rate -specification is 9600, and the terminal type is vt100. The result of -this mapping is to specify that if the terminal type is \fBdialup\fR, -and the baud rate is greater than 9600 baud, a terminal type of -\fBvt100\fR will be used. -.PP -If no baud rate is specified, the terminal type will match any baud rate. -If no port type is specified, the terminal type will match any port type. -For example, \fB\-m dialup:vt100 \-m :?xterm\fR -will cause any dialup port, regardless of baud rate, to match the terminal -type vt100, and any non-dialup port type to match the terminal type ?xterm. -Note, because of the leading question mark, the user will be -queried on a default port as to whether they are actually using an xterm -terminal. -.PP -No whitespace characters are permitted in the \fB\-m\fR option argument. -Also, to avoid problems with meta-characters, it is suggested that the -entire \fB\-m\fR option argument be placed within single quote characters, -and that \fBcsh\fR users insert a backslash character (``\e'') before -any exclamation marks (``!''). -.SH HISTORY -The \fBtset\fR command appeared in BSD 3.0. The \fBncurses\fR implementation -was lightly adapted from the 4.4BSD sources for a terminfo environment by Eric -S. Raymond . -.SH COMPATIBILITY -The \fBtset\fR utility has been provided for backward-compatibility with BSD -environments (under most modern UNIXes, \fB/etc/inittab\fR and \fIgetty\fR(1) -can set \fBTERM\fR appropriately for each dial-up line; this obviates what was -\fBtset\fR's most important use). This implementation behaves like 4.4BSD -tset, with a few exceptions specified here. -.PP -The \fB\-S\fR option of BSD tset no longer works; it prints an error message to stderr -and dies. The \fB\-s\fR option only sets \fBTERM\fR, not \fBTERMCAP\fP. Both these -changes are because the \fBTERMCAP\fR variable is no longer supported under -terminfo-based \fBncurses\fR, which makes \fBtset \-S\fR useless (we made it die -noisily rather than silently induce lossage). -.PP -There was an undocumented 4.4BSD feature that invoking tset via a link named -`TSET` (or via any other name beginning with an upper-case letter) set the -terminal to use upper-case only. This feature has been omitted. -.PP -The \fB\-A\fR, \fB\-E\fR, \fB\-h\fR, \fB\-u\fR and \fB\-v\fR -options were deleted from the \fBtset\fR -utility in 4.4BSD. -None of them were documented in 4.3BSD and all are -of limited utility at best. -The \fB\-a\fR, -\fB\d\fR, and -\fB\p\fR options are similarly -not documented or useful, but were retained as they appear to be in -widespread use. It is strongly recommended that any usage of these -three options be changed to use the \fB\-m\fR option instead. The --n option remains, but has no effect. The \fB\-adnp\fR options are therefore -omitted from the usage summary above. -.PP -It is still permissible to specify the \fB\-e\fR, \fB\-i\fR, and \fB\-k\fR options without -arguments, although it is strongly recommended that such usage be fixed to -explicitly specify the character. -.PP -As of 4.4BSD, executing \fBtset\fR as \fBreset\fR no longer implies the \fB\-Q\fR -option. Also, the interaction between the - option and the \fIterminal\fR -argument in some historic implementations of \fBtset\fR has been removed. -.SH ENVIRONMENT -The \fBtset\fR command uses the \fBSHELL\fR and \fBTERM\fR -environment variables. -.SH FILES -.TP 5 -/etc/ttys -system port name to terminal type mapping database (BSD versions only). -.TP -@TERMINFO@ -terminal capability database -.SH SEE ALSO -csh(1), -sh(1), -stty(1), -tty(4), -termcap(5), -ttys(5), -environ(7) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: - diff --git a/contrib/ncurses-5.4/man/wresize.3x b/contrib/ncurses-5.4/man/wresize.3x deleted file mode 100644 index ce7c10b8d9..0000000000 --- a/contrib/ncurses-5.4/man/wresize.3x +++ /dev/null @@ -1,64 +0,0 @@ -.\"*************************************************************************** -.\" Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * -.\" * -.\" Permission is hereby granted, free of charge, to any person obtaining a * -.\" copy of this software and associated documentation files (the * -.\" "Software"), to deal in the Software without restriction, including * -.\" without limitation the rights to use, copy, modify, merge, publish, * -.\" distribute, distribute with modifications, sublicense, and/or sell * -.\" copies of the Software, and to permit persons to whom the Software is * -.\" furnished to do so, subject to the following conditions: * -.\" * -.\" The above copyright notice and this permission notice shall be included * -.\" in all copies or substantial portions of the Software. * -.\" * -.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * -.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * -.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * -.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * -.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * -.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * -.\" * -.\" Except as contained in this notice, the name(s) of the above copyright * -.\" holders shall not be used in advertising or otherwise to promote the * -.\" sale, use or other dealings in this Software without prior written * -.\" authorization. * -.\"*************************************************************************** -.\" -.\" Author: Thomas E. Dickey 1996 -.\" -.\" $Id: wresize.3x,v 1.8 2003/10/25 20:41:08 tom Exp $ -.TH wresize 3X "" -.SH NAME -\fBwresize\fR - resize a curses window -.SH SYNOPSIS -\fB#include \fR - -\fBint wresize(WINDOW *win, int lines, int columns);\fR -.SH DESCRIPTION -The \fBwresize\fR function reallocates storage for an \fBncurses\fR -window to adjust its dimensions to the specified values. -If either dimension is larger than the current values, the -window's data is filled with blanks that have the current background rendition -(as set by \fBwbkgndset\fR) merged into them. -.SH RETURN VALUE -The function returns the integer \fBERR\fR upon failure and \fBOK\fR on success. -It will fail if either of the dimensions less than or equal to zero, -or if an error occurs while (re)allocating memory for the window. -.SH NOTES -The only restriction placed on the dimensions is that they be greater than zero. -The dimensions are not compared to \fBcurses\fR screen dimensions to -simplify the logic of \fBresizeterm\fR. -The caller must ensure that the window's dimensions fit within the -actual screen dimensions. -.SH SEE ALSO -\fBresizeterm\fR(3X). -.SH AUTHOR -Thomas Dickey (from an equivalent function written in 1988 for BSD curses). -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: diff --git a/contrib/ncurses-5.4/ANNOUNCE b/contrib/ncurses/ANNOUNCE similarity index 100% rename from contrib/ncurses-5.4/ANNOUNCE rename to contrib/ncurses/ANNOUNCE diff --git a/contrib/ncurses-5.4/INSTALL b/contrib/ncurses/INSTALL similarity index 100% rename from contrib/ncurses-5.4/INSTALL rename to contrib/ncurses/INSTALL diff --git a/contrib/ncurses-5.4/MANIFEST b/contrib/ncurses/MANIFEST similarity index 100% rename from contrib/ncurses-5.4/MANIFEST rename to contrib/ncurses/MANIFEST diff --git a/contrib/ncurses-5.4/Makefile.in b/contrib/ncurses/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/Makefile.in rename to contrib/ncurses/Makefile.in diff --git a/contrib/ncurses-5.4/Makefile.os2 b/contrib/ncurses/Makefile.os2 similarity index 100% rename from contrib/ncurses-5.4/Makefile.os2 rename to contrib/ncurses/Makefile.os2 diff --git a/contrib/ncurses-5.4/NEWS b/contrib/ncurses/NEWS similarity index 100% rename from contrib/ncurses-5.4/NEWS rename to contrib/ncurses/NEWS diff --git a/contrib/ncurses-5.4/README b/contrib/ncurses/README similarity index 100% rename from contrib/ncurses-5.4/README rename to contrib/ncurses/README diff --git a/contrib/ncurses-5.4/README.DELETED b/contrib/ncurses/README.DELETED similarity index 100% rename from contrib/ncurses-5.4/README.DELETED rename to contrib/ncurses/README.DELETED diff --git a/contrib/ncurses-5.4/README.DRAGONFLY b/contrib/ncurses/README.DRAGONFLY similarity index 100% rename from contrib/ncurses-5.4/README.DRAGONFLY rename to contrib/ncurses/README.DRAGONFLY diff --git a/contrib/ncurses-5.4/README.emx b/contrib/ncurses/README.emx similarity index 100% rename from contrib/ncurses-5.4/README.emx rename to contrib/ncurses/README.emx diff --git a/contrib/ncurses-5.4/TO-DO b/contrib/ncurses/TO-DO similarity index 100% rename from contrib/ncurses-5.4/TO-DO rename to contrib/ncurses/TO-DO diff --git a/contrib/ncurses-5.4/aclocal.m4 b/contrib/ncurses/aclocal.m4 similarity index 100% rename from contrib/ncurses-5.4/aclocal.m4 rename to contrib/ncurses/aclocal.m4 diff --git a/contrib/ncurses-5.4/announce.html.in b/contrib/ncurses/announce.html.in similarity index 100% rename from contrib/ncurses-5.4/announce.html.in rename to contrib/ncurses/announce.html.in diff --git a/contrib/ncurses-5.4/c++/Makefile.in b/contrib/ncurses/c++/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/c++/Makefile.in rename to contrib/ncurses/c++/Makefile.in diff --git a/contrib/ncurses-5.4/c++/NEWS b/contrib/ncurses/c++/NEWS similarity index 100% rename from contrib/ncurses-5.4/c++/NEWS rename to contrib/ncurses/c++/NEWS diff --git a/contrib/ncurses-5.4/c++/PROBLEMS b/contrib/ncurses/c++/PROBLEMS similarity index 100% rename from contrib/ncurses-5.4/c++/PROBLEMS rename to contrib/ncurses/c++/PROBLEMS diff --git a/contrib/ncurses-5.4/c++/README-first b/contrib/ncurses/c++/README-first similarity index 100% rename from contrib/ncurses-5.4/c++/README-first rename to contrib/ncurses/c++/README-first diff --git a/contrib/ncurses-5.4/c++/cursesapp.cc b/contrib/ncurses/c++/cursesapp.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesapp.cc rename to contrib/ncurses/c++/cursesapp.cc diff --git a/contrib/ncurses-5.4/c++/cursesapp.h b/contrib/ncurses/c++/cursesapp.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursesapp.h rename to contrib/ncurses/c++/cursesapp.h diff --git a/contrib/ncurses-5.4/c++/cursesf.cc b/contrib/ncurses/c++/cursesf.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesf.cc rename to contrib/ncurses/c++/cursesf.cc diff --git a/contrib/ncurses-5.4/c++/cursesf.h b/contrib/ncurses/c++/cursesf.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursesf.h rename to contrib/ncurses/c++/cursesf.h diff --git a/contrib/ncurses-5.4/c++/cursesm.cc b/contrib/ncurses/c++/cursesm.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesm.cc rename to contrib/ncurses/c++/cursesm.cc diff --git a/contrib/ncurses-5.4/c++/cursesm.h b/contrib/ncurses/c++/cursesm.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursesm.h rename to contrib/ncurses/c++/cursesm.h diff --git a/contrib/ncurses-5.4/c++/cursesmain.cc b/contrib/ncurses/c++/cursesmain.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesmain.cc rename to contrib/ncurses/c++/cursesmain.cc diff --git a/contrib/ncurses-5.4/c++/cursesp.cc b/contrib/ncurses/c++/cursesp.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesp.cc rename to contrib/ncurses/c++/cursesp.cc diff --git a/contrib/ncurses-5.4/c++/cursesp.h b/contrib/ncurses/c++/cursesp.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursesp.h rename to contrib/ncurses/c++/cursesp.h diff --git a/contrib/ncurses-5.4/c++/cursespad.cc b/contrib/ncurses/c++/cursespad.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursespad.cc rename to contrib/ncurses/c++/cursespad.cc diff --git a/contrib/ncurses-5.4/c++/cursesw.cc b/contrib/ncurses/c++/cursesw.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursesw.cc rename to contrib/ncurses/c++/cursesw.cc diff --git a/contrib/ncurses-5.4/c++/cursesw.h b/contrib/ncurses/c++/cursesw.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursesw.h rename to contrib/ncurses/c++/cursesw.h diff --git a/contrib/ncurses-5.4/c++/cursslk.cc b/contrib/ncurses/c++/cursslk.cc similarity index 100% rename from contrib/ncurses-5.4/c++/cursslk.cc rename to contrib/ncurses/c++/cursslk.cc diff --git a/contrib/ncurses-5.4/c++/cursslk.h b/contrib/ncurses/c++/cursslk.h similarity index 100% rename from contrib/ncurses-5.4/c++/cursslk.h rename to contrib/ncurses/c++/cursslk.h diff --git a/contrib/ncurses-5.4/c++/demo.cc b/contrib/ncurses/c++/demo.cc similarity index 100% rename from contrib/ncurses-5.4/c++/demo.cc rename to contrib/ncurses/c++/demo.cc diff --git a/contrib/ncurses-5.4/c++/edit_cfg.sh b/contrib/ncurses/c++/edit_cfg.sh similarity index 100% rename from contrib/ncurses-5.4/c++/edit_cfg.sh rename to contrib/ncurses/c++/edit_cfg.sh diff --git a/contrib/ncurses-5.4/c++/etip.h.in b/contrib/ncurses/c++/etip.h.in similarity index 100% rename from contrib/ncurses-5.4/c++/etip.h.in rename to contrib/ncurses/c++/etip.h.in diff --git a/contrib/ncurses-5.4/c++/headers b/contrib/ncurses/c++/headers similarity index 100% rename from contrib/ncurses-5.4/c++/headers rename to contrib/ncurses/c++/headers diff --git a/contrib/ncurses-5.4/c++/internal.h b/contrib/ncurses/c++/internal.h similarity index 100% rename from contrib/ncurses-5.4/c++/internal.h rename to contrib/ncurses/c++/internal.h diff --git a/contrib/ncurses-5.4/c++/modules b/contrib/ncurses/c++/modules similarity index 100% rename from contrib/ncurses-5.4/c++/modules rename to contrib/ncurses/c++/modules diff --git a/contrib/ncurses-5.4/configure.in b/contrib/ncurses/configure.in similarity index 100% rename from contrib/ncurses-5.4/configure.in rename to contrib/ncurses/configure.in diff --git a/contrib/ncurses-5.4/convert_configure.pl b/contrib/ncurses/convert_configure.pl similarity index 100% rename from contrib/ncurses-5.4/convert_configure.pl rename to contrib/ncurses/convert_configure.pl diff --git a/contrib/ncurses-5.4/dist.mk b/contrib/ncurses/dist.mk similarity index 100% rename from contrib/ncurses-5.4/dist.mk rename to contrib/ncurses/dist.mk diff --git a/contrib/ncurses-5.4/doc/hackguide.doc b/contrib/ncurses/doc/hackguide.doc similarity index 100% rename from contrib/ncurses-5.4/doc/hackguide.doc rename to contrib/ncurses/doc/hackguide.doc diff --git a/contrib/ncurses-5.4/doc/html/Ada95.html b/contrib/ncurses/doc/html/Ada95.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/Ada95.html rename to contrib/ncurses/doc/html/Ada95.html diff --git a/contrib/ncurses-5.4/doc/html/ada/files.htm b/contrib/ncurses/doc/html/ada/files.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/files.htm rename to contrib/ncurses/doc/html/ada/files.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/files/T.htm b/contrib/ncurses/doc/html/ada/files/T.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/files/T.htm rename to contrib/ncurses/doc/html/ada/files/T.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs.htm b/contrib/ncurses/doc/html/ada/funcs.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs.htm rename to contrib/ncurses/doc/html/ada/funcs.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/A.htm b/contrib/ncurses/doc/html/ada/funcs/A.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/A.htm rename to contrib/ncurses/doc/html/ada/funcs/A.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/B.htm b/contrib/ncurses/doc/html/ada/funcs/B.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/B.htm rename to contrib/ncurses/doc/html/ada/funcs/B.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/C.htm b/contrib/ncurses/doc/html/ada/funcs/C.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/C.htm rename to contrib/ncurses/doc/html/ada/funcs/C.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/D.htm b/contrib/ncurses/doc/html/ada/funcs/D.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/D.htm rename to contrib/ncurses/doc/html/ada/funcs/D.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/E.htm b/contrib/ncurses/doc/html/ada/funcs/E.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/E.htm rename to contrib/ncurses/doc/html/ada/funcs/E.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/F.htm b/contrib/ncurses/doc/html/ada/funcs/F.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/F.htm rename to contrib/ncurses/doc/html/ada/funcs/F.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/G.htm b/contrib/ncurses/doc/html/ada/funcs/G.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/G.htm rename to contrib/ncurses/doc/html/ada/funcs/G.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/H.htm b/contrib/ncurses/doc/html/ada/funcs/H.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/H.htm rename to contrib/ncurses/doc/html/ada/funcs/H.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/I.htm b/contrib/ncurses/doc/html/ada/funcs/I.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/I.htm rename to contrib/ncurses/doc/html/ada/funcs/I.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/K.htm b/contrib/ncurses/doc/html/ada/funcs/K.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/K.htm rename to contrib/ncurses/doc/html/ada/funcs/K.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/L.htm b/contrib/ncurses/doc/html/ada/funcs/L.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/L.htm rename to contrib/ncurses/doc/html/ada/funcs/L.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/M.htm b/contrib/ncurses/doc/html/ada/funcs/M.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/M.htm rename to contrib/ncurses/doc/html/ada/funcs/M.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/N.htm b/contrib/ncurses/doc/html/ada/funcs/N.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/N.htm rename to contrib/ncurses/doc/html/ada/funcs/N.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/O.htm b/contrib/ncurses/doc/html/ada/funcs/O.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/O.htm rename to contrib/ncurses/doc/html/ada/funcs/O.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/P.htm b/contrib/ncurses/doc/html/ada/funcs/P.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/P.htm rename to contrib/ncurses/doc/html/ada/funcs/P.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/Q.htm b/contrib/ncurses/doc/html/ada/funcs/Q.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/Q.htm rename to contrib/ncurses/doc/html/ada/funcs/Q.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/R.htm b/contrib/ncurses/doc/html/ada/funcs/R.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/R.htm rename to contrib/ncurses/doc/html/ada/funcs/R.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/S.htm b/contrib/ncurses/doc/html/ada/funcs/S.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/S.htm rename to contrib/ncurses/doc/html/ada/funcs/S.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/T.htm b/contrib/ncurses/doc/html/ada/funcs/T.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/T.htm rename to contrib/ncurses/doc/html/ada/funcs/T.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/U.htm b/contrib/ncurses/doc/html/ada/funcs/U.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/U.htm rename to contrib/ncurses/doc/html/ada/funcs/U.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/V.htm b/contrib/ncurses/doc/html/ada/funcs/V.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/V.htm rename to contrib/ncurses/doc/html/ada/funcs/V.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/funcs/W.htm b/contrib/ncurses/doc/html/ada/funcs/W.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/funcs/W.htm rename to contrib/ncurses/doc/html/ada/funcs/W.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/index.htm b/contrib/ncurses/doc/html/ada/index.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/index.htm rename to contrib/ncurses/doc/html/ada/index.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/main.htm b/contrib/ncurses/doc/html/ada/main.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/main.htm rename to contrib/ncurses/doc/html/ada/main.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/table.html b/contrib/ncurses/doc/html/ada/table.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/table.html rename to contrib/ncurses/doc/html/ada/table.html diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-aux__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-aux__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-aux__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-aux__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-aux__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-aux__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-aux__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-aux__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alpha__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-alphanumeric__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration-ada__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-enumeration__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-intfield__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-ipv4_address__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-numeric__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-regexp__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user-choice__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types-user__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types-user__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_types__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_types__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_user_data__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_user_data__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_user_data__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_user_data__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_user_data__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_user_data__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-field_user_data__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-field_user_data__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-form_user_data__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-form_user_data__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-form_user_data__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-form_user_data__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-form_user_data__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-form_user_data__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms-form_user_data__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms-form_user_data__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-forms__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-forms__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-forms__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-item_user_data__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-item_user_data__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-item_user_data__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-item_user_data__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-item_user_data__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-item_user_data__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-item_user_data__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-item_user_data__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-menu_user_data__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-menu_user_data__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-menu_user_data__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-menu_user_data__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-menu_user_data__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-menu_user_data__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus-menu_user_data__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus-menu_user_data__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-menus__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-menus__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-menus__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-mouse__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-mouse__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-mouse__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-mouse__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-mouse__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-mouse__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-mouse__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-mouse__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels-user_data__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-panels-user_data__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels-user_data__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-panels-user_data__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels-user_data__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-panels-user_data__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels-user_data__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-panels-user_data__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-panels__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-panels__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-panels__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-panels__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-panels__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-putwin__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-putwin__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-putwin__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-putwin__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-putwin__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-putwin__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-putwin__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-putwin__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-termcap__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-termcap__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-termcap__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-termcap__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-termcap__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-termcap__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-termcap__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-termcap__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-terminfo__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-terminfo__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-terminfo__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-terminfo__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-terminfo__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-terminfo__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-terminfo__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-terminfo__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-aux__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-aux__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-aux__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-aux__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-aux__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-aux__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-aux__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-aux__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-complex_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-complex_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-complex_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-complex_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-complex_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-complex_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-complex_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-complex_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-decimal_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-decimal_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-decimal_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-decimal_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-decimal_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-decimal_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-decimal_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-decimal_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-enumeration_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-fixed_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-fixed_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-fixed_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-fixed_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-fixed_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-fixed_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-fixed_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-fixed_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-float_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-float_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-float_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-float_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-float_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-float_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-float_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-float_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-integer_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-integer_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-integer_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-integer_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-integer_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-integer_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-integer_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-integer_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-modular_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-modular_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-modular_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-modular_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-modular_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-modular_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io-modular_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io-modular_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-text_io__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-text_io__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-trace__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-trace__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-trace__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-trace__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-trace__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses-trace__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses-trace__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses-trace__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses__adb.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses__adb.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses__adb.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses__adb.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface-curses__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface-curses__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface-curses__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/ada/terminal_interface__ads.htm b/contrib/ncurses/doc/html/ada/terminal_interface__ads.htm similarity index 100% rename from contrib/ncurses-5.4/doc/html/ada/terminal_interface__ads.htm rename to contrib/ncurses/doc/html/ada/terminal_interface__ads.htm diff --git a/contrib/ncurses-5.4/doc/html/announce.html b/contrib/ncurses/doc/html/announce.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/announce.html rename to contrib/ncurses/doc/html/announce.html diff --git a/contrib/ncurses-5.4/doc/html/hackguide.html b/contrib/ncurses/doc/html/hackguide.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/hackguide.html rename to contrib/ncurses/doc/html/hackguide.html diff --git a/contrib/ncurses-5.4/doc/html/index.html b/contrib/ncurses/doc/html/index.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/index.html rename to contrib/ncurses/doc/html/index.html diff --git a/contrib/ncurses-5.4/doc/html/man/captoinfo.1m.html b/contrib/ncurses/doc/html/man/captoinfo.1m.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/captoinfo.1m.html rename to contrib/ncurses/doc/html/man/captoinfo.1m.html diff --git a/contrib/ncurses-5.4/doc/html/man/clear.1.html b/contrib/ncurses/doc/html/man/clear.1.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/clear.1.html rename to contrib/ncurses/doc/html/man/clear.1.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_add_wch.3x.html b/contrib/ncurses/doc/html/man/curs_add_wch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_add_wch.3x.html rename to contrib/ncurses/doc/html/man/curs_add_wch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_add_wchstr.3x.html b/contrib/ncurses/doc/html/man/curs_add_wchstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_add_wchstr.3x.html rename to contrib/ncurses/doc/html/man/curs_add_wchstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_addch.3x.html b/contrib/ncurses/doc/html/man/curs_addch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_addch.3x.html rename to contrib/ncurses/doc/html/man/curs_addch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_addchstr.3x.html b/contrib/ncurses/doc/html/man/curs_addchstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_addchstr.3x.html rename to contrib/ncurses/doc/html/man/curs_addchstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_addstr.3x.html b/contrib/ncurses/doc/html/man/curs_addstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_addstr.3x.html rename to contrib/ncurses/doc/html/man/curs_addstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_addwstr.3x.html b/contrib/ncurses/doc/html/man/curs_addwstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_addwstr.3x.html rename to contrib/ncurses/doc/html/man/curs_addwstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_attr.3x.html b/contrib/ncurses/doc/html/man/curs_attr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_attr.3x.html rename to contrib/ncurses/doc/html/man/curs_attr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_beep.3x.html b/contrib/ncurses/doc/html/man/curs_beep.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_beep.3x.html rename to contrib/ncurses/doc/html/man/curs_beep.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_bkgd.3x.html b/contrib/ncurses/doc/html/man/curs_bkgd.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_bkgd.3x.html rename to contrib/ncurses/doc/html/man/curs_bkgd.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_bkgrnd.3x.html b/contrib/ncurses/doc/html/man/curs_bkgrnd.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_bkgrnd.3x.html rename to contrib/ncurses/doc/html/man/curs_bkgrnd.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_border.3x.html b/contrib/ncurses/doc/html/man/curs_border.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_border.3x.html rename to contrib/ncurses/doc/html/man/curs_border.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_border_set.3x.html b/contrib/ncurses/doc/html/man/curs_border_set.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_border_set.3x.html rename to contrib/ncurses/doc/html/man/curs_border_set.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_clear.3x.html b/contrib/ncurses/doc/html/man/curs_clear.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_clear.3x.html rename to contrib/ncurses/doc/html/man/curs_clear.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_color.3x.html b/contrib/ncurses/doc/html/man/curs_color.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_color.3x.html rename to contrib/ncurses/doc/html/man/curs_color.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_delch.3x.html b/contrib/ncurses/doc/html/man/curs_delch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_delch.3x.html rename to contrib/ncurses/doc/html/man/curs_delch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_deleteln.3x.html b/contrib/ncurses/doc/html/man/curs_deleteln.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_deleteln.3x.html rename to contrib/ncurses/doc/html/man/curs_deleteln.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_extend.3x.html b/contrib/ncurses/doc/html/man/curs_extend.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_extend.3x.html rename to contrib/ncurses/doc/html/man/curs_extend.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_get_wch.3x.html b/contrib/ncurses/doc/html/man/curs_get_wch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_get_wch.3x.html rename to contrib/ncurses/doc/html/man/curs_get_wch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_get_wstr.3x.html b/contrib/ncurses/doc/html/man/curs_get_wstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_get_wstr.3x.html rename to contrib/ncurses/doc/html/man/curs_get_wstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_getcchar.3x.html b/contrib/ncurses/doc/html/man/curs_getcchar.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_getcchar.3x.html rename to contrib/ncurses/doc/html/man/curs_getcchar.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_getch.3x.html b/contrib/ncurses/doc/html/man/curs_getch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_getch.3x.html rename to contrib/ncurses/doc/html/man/curs_getch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_getstr.3x.html b/contrib/ncurses/doc/html/man/curs_getstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_getstr.3x.html rename to contrib/ncurses/doc/html/man/curs_getstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_getyx.3x.html b/contrib/ncurses/doc/html/man/curs_getyx.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_getyx.3x.html rename to contrib/ncurses/doc/html/man/curs_getyx.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_in_wch.3x.html b/contrib/ncurses/doc/html/man/curs_in_wch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_in_wch.3x.html rename to contrib/ncurses/doc/html/man/curs_in_wch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_in_wchstr.3x.html b/contrib/ncurses/doc/html/man/curs_in_wchstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_in_wchstr.3x.html rename to contrib/ncurses/doc/html/man/curs_in_wchstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_inch.3x.html b/contrib/ncurses/doc/html/man/curs_inch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_inch.3x.html rename to contrib/ncurses/doc/html/man/curs_inch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_inchstr.3x.html b/contrib/ncurses/doc/html/man/curs_inchstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_inchstr.3x.html rename to contrib/ncurses/doc/html/man/curs_inchstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_initscr.3x.html b/contrib/ncurses/doc/html/man/curs_initscr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_initscr.3x.html rename to contrib/ncurses/doc/html/man/curs_initscr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_inopts.3x.html b/contrib/ncurses/doc/html/man/curs_inopts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_inopts.3x.html rename to contrib/ncurses/doc/html/man/curs_inopts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_ins_wch.3x.html b/contrib/ncurses/doc/html/man/curs_ins_wch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_ins_wch.3x.html rename to contrib/ncurses/doc/html/man/curs_ins_wch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_ins_wstr.3x.html b/contrib/ncurses/doc/html/man/curs_ins_wstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_ins_wstr.3x.html rename to contrib/ncurses/doc/html/man/curs_ins_wstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_insch.3x.html b/contrib/ncurses/doc/html/man/curs_insch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_insch.3x.html rename to contrib/ncurses/doc/html/man/curs_insch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_insstr.3x.html b/contrib/ncurses/doc/html/man/curs_insstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_insstr.3x.html rename to contrib/ncurses/doc/html/man/curs_insstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_instr.3x.html b/contrib/ncurses/doc/html/man/curs_instr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_instr.3x.html rename to contrib/ncurses/doc/html/man/curs_instr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_inwstr.3x.html b/contrib/ncurses/doc/html/man/curs_inwstr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_inwstr.3x.html rename to contrib/ncurses/doc/html/man/curs_inwstr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_kernel.3x.html b/contrib/ncurses/doc/html/man/curs_kernel.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_kernel.3x.html rename to contrib/ncurses/doc/html/man/curs_kernel.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_mouse.3x.html b/contrib/ncurses/doc/html/man/curs_mouse.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_mouse.3x.html rename to contrib/ncurses/doc/html/man/curs_mouse.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_move.3x.html b/contrib/ncurses/doc/html/man/curs_move.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_move.3x.html rename to contrib/ncurses/doc/html/man/curs_move.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_outopts.3x.html b/contrib/ncurses/doc/html/man/curs_outopts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_outopts.3x.html rename to contrib/ncurses/doc/html/man/curs_outopts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_overlay.3x.html b/contrib/ncurses/doc/html/man/curs_overlay.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_overlay.3x.html rename to contrib/ncurses/doc/html/man/curs_overlay.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_pad.3x.html b/contrib/ncurses/doc/html/man/curs_pad.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_pad.3x.html rename to contrib/ncurses/doc/html/man/curs_pad.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_print.3x.html b/contrib/ncurses/doc/html/man/curs_print.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_print.3x.html rename to contrib/ncurses/doc/html/man/curs_print.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_printw.3x.html b/contrib/ncurses/doc/html/man/curs_printw.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_printw.3x.html rename to contrib/ncurses/doc/html/man/curs_printw.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_refresh.3x.html b/contrib/ncurses/doc/html/man/curs_refresh.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_refresh.3x.html rename to contrib/ncurses/doc/html/man/curs_refresh.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_scanw.3x.html b/contrib/ncurses/doc/html/man/curs_scanw.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_scanw.3x.html rename to contrib/ncurses/doc/html/man/curs_scanw.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_scr_dump.3x.html b/contrib/ncurses/doc/html/man/curs_scr_dump.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_scr_dump.3x.html rename to contrib/ncurses/doc/html/man/curs_scr_dump.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_scroll.3x.html b/contrib/ncurses/doc/html/man/curs_scroll.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_scroll.3x.html rename to contrib/ncurses/doc/html/man/curs_scroll.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_slk.3x.html b/contrib/ncurses/doc/html/man/curs_slk.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_slk.3x.html rename to contrib/ncurses/doc/html/man/curs_slk.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_termattrs.3x.html b/contrib/ncurses/doc/html/man/curs_termattrs.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_termattrs.3x.html rename to contrib/ncurses/doc/html/man/curs_termattrs.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_termcap.3x.html b/contrib/ncurses/doc/html/man/curs_termcap.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_termcap.3x.html rename to contrib/ncurses/doc/html/man/curs_termcap.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_terminfo.3x.html b/contrib/ncurses/doc/html/man/curs_terminfo.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_terminfo.3x.html rename to contrib/ncurses/doc/html/man/curs_terminfo.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_touch.3x.html b/contrib/ncurses/doc/html/man/curs_touch.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_touch.3x.html rename to contrib/ncurses/doc/html/man/curs_touch.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_trace.3x.html b/contrib/ncurses/doc/html/man/curs_trace.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_trace.3x.html rename to contrib/ncurses/doc/html/man/curs_trace.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_util.3x.html b/contrib/ncurses/doc/html/man/curs_util.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_util.3x.html rename to contrib/ncurses/doc/html/man/curs_util.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/curs_window.3x.html b/contrib/ncurses/doc/html/man/curs_window.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/curs_window.3x.html rename to contrib/ncurses/doc/html/man/curs_window.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/default_colors.3x.html b/contrib/ncurses/doc/html/man/default_colors.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/default_colors.3x.html rename to contrib/ncurses/doc/html/man/default_colors.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/define_key.3x.html b/contrib/ncurses/doc/html/man/define_key.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/define_key.3x.html rename to contrib/ncurses/doc/html/man/define_key.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form.3x.html b/contrib/ncurses/doc/html/man/form.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form.3x.html rename to contrib/ncurses/doc/html/man/form.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_cursor.3x.html b/contrib/ncurses/doc/html/man/form_cursor.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_cursor.3x.html rename to contrib/ncurses/doc/html/man/form_cursor.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_data.3x.html b/contrib/ncurses/doc/html/man/form_data.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_data.3x.html rename to contrib/ncurses/doc/html/man/form_data.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_driver.3x.html b/contrib/ncurses/doc/html/man/form_driver.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_driver.3x.html rename to contrib/ncurses/doc/html/man/form_driver.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field.3x.html b/contrib/ncurses/doc/html/man/form_field.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field.3x.html rename to contrib/ncurses/doc/html/man/form_field.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_attributes.3x.html b/contrib/ncurses/doc/html/man/form_field_attributes.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_attributes.3x.html rename to contrib/ncurses/doc/html/man/form_field_attributes.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_buffer.3x.html b/contrib/ncurses/doc/html/man/form_field_buffer.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_buffer.3x.html rename to contrib/ncurses/doc/html/man/form_field_buffer.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_info.3x.html b/contrib/ncurses/doc/html/man/form_field_info.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_info.3x.html rename to contrib/ncurses/doc/html/man/form_field_info.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_just.3x.html b/contrib/ncurses/doc/html/man/form_field_just.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_just.3x.html rename to contrib/ncurses/doc/html/man/form_field_just.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_new.3x.html b/contrib/ncurses/doc/html/man/form_field_new.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_new.3x.html rename to contrib/ncurses/doc/html/man/form_field_new.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_opts.3x.html b/contrib/ncurses/doc/html/man/form_field_opts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_opts.3x.html rename to contrib/ncurses/doc/html/man/form_field_opts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_userptr.3x.html b/contrib/ncurses/doc/html/man/form_field_userptr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_userptr.3x.html rename to contrib/ncurses/doc/html/man/form_field_userptr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_field_validation.3x.html b/contrib/ncurses/doc/html/man/form_field_validation.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_field_validation.3x.html rename to contrib/ncurses/doc/html/man/form_field_validation.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_fieldtype.3x.html b/contrib/ncurses/doc/html/man/form_fieldtype.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_fieldtype.3x.html rename to contrib/ncurses/doc/html/man/form_fieldtype.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_hook.3x.html b/contrib/ncurses/doc/html/man/form_hook.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_hook.3x.html rename to contrib/ncurses/doc/html/man/form_hook.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_new.3x.html b/contrib/ncurses/doc/html/man/form_new.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_new.3x.html rename to contrib/ncurses/doc/html/man/form_new.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_new_page.3x.html b/contrib/ncurses/doc/html/man/form_new_page.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_new_page.3x.html rename to contrib/ncurses/doc/html/man/form_new_page.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_opts.3x.html b/contrib/ncurses/doc/html/man/form_opts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_opts.3x.html rename to contrib/ncurses/doc/html/man/form_opts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_page.3x.html b/contrib/ncurses/doc/html/man/form_page.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_page.3x.html rename to contrib/ncurses/doc/html/man/form_page.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_post.3x.html b/contrib/ncurses/doc/html/man/form_post.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_post.3x.html rename to contrib/ncurses/doc/html/man/form_post.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_requestname.3x.html b/contrib/ncurses/doc/html/man/form_requestname.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_requestname.3x.html rename to contrib/ncurses/doc/html/man/form_requestname.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_userptr.3x.html b/contrib/ncurses/doc/html/man/form_userptr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_userptr.3x.html rename to contrib/ncurses/doc/html/man/form_userptr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/form_win.3x.html b/contrib/ncurses/doc/html/man/form_win.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/form_win.3x.html rename to contrib/ncurses/doc/html/man/form_win.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/infocmp.1m.html b/contrib/ncurses/doc/html/man/infocmp.1m.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/infocmp.1m.html rename to contrib/ncurses/doc/html/man/infocmp.1m.html diff --git a/contrib/ncurses-5.4/doc/html/man/infotocap.1m.html b/contrib/ncurses/doc/html/man/infotocap.1m.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/infotocap.1m.html rename to contrib/ncurses/doc/html/man/infotocap.1m.html diff --git a/contrib/ncurses-5.4/doc/html/man/key_defined.3x.html b/contrib/ncurses/doc/html/man/key_defined.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/key_defined.3x.html rename to contrib/ncurses/doc/html/man/key_defined.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/keybound.3x.html b/contrib/ncurses/doc/html/man/keybound.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/keybound.3x.html rename to contrib/ncurses/doc/html/man/keybound.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/keyok.3x.html b/contrib/ncurses/doc/html/man/keyok.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/keyok.3x.html rename to contrib/ncurses/doc/html/man/keyok.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu.3x.html b/contrib/ncurses/doc/html/man/menu.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu.3x.html rename to contrib/ncurses/doc/html/man/menu.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_attributes.3x.html b/contrib/ncurses/doc/html/man/menu_attributes.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_attributes.3x.html rename to contrib/ncurses/doc/html/man/menu_attributes.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_cursor.3x.html b/contrib/ncurses/doc/html/man/menu_cursor.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_cursor.3x.html rename to contrib/ncurses/doc/html/man/menu_cursor.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_driver.3x.html b/contrib/ncurses/doc/html/man/menu_driver.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_driver.3x.html rename to contrib/ncurses/doc/html/man/menu_driver.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_format.3x.html b/contrib/ncurses/doc/html/man/menu_format.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_format.3x.html rename to contrib/ncurses/doc/html/man/menu_format.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_hook.3x.html b/contrib/ncurses/doc/html/man/menu_hook.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_hook.3x.html rename to contrib/ncurses/doc/html/man/menu_hook.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_items.3x.html b/contrib/ncurses/doc/html/man/menu_items.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_items.3x.html rename to contrib/ncurses/doc/html/man/menu_items.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_mark.3x.html b/contrib/ncurses/doc/html/man/menu_mark.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_mark.3x.html rename to contrib/ncurses/doc/html/man/menu_mark.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_new.3x.html b/contrib/ncurses/doc/html/man/menu_new.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_new.3x.html rename to contrib/ncurses/doc/html/man/menu_new.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_opts.3x.html b/contrib/ncurses/doc/html/man/menu_opts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_opts.3x.html rename to contrib/ncurses/doc/html/man/menu_opts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_pattern.3x.html b/contrib/ncurses/doc/html/man/menu_pattern.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_pattern.3x.html rename to contrib/ncurses/doc/html/man/menu_pattern.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_post.3x.html b/contrib/ncurses/doc/html/man/menu_post.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_post.3x.html rename to contrib/ncurses/doc/html/man/menu_post.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_requestname.3x.html b/contrib/ncurses/doc/html/man/menu_requestname.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_requestname.3x.html rename to contrib/ncurses/doc/html/man/menu_requestname.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_spacing.3x.html b/contrib/ncurses/doc/html/man/menu_spacing.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_spacing.3x.html rename to contrib/ncurses/doc/html/man/menu_spacing.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_userptr.3x.html b/contrib/ncurses/doc/html/man/menu_userptr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_userptr.3x.html rename to contrib/ncurses/doc/html/man/menu_userptr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/menu_win.3x.html b/contrib/ncurses/doc/html/man/menu_win.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/menu_win.3x.html rename to contrib/ncurses/doc/html/man/menu_win.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_current.3x.html b/contrib/ncurses/doc/html/man/mitem_current.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_current.3x.html rename to contrib/ncurses/doc/html/man/mitem_current.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_name.3x.html b/contrib/ncurses/doc/html/man/mitem_name.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_name.3x.html rename to contrib/ncurses/doc/html/man/mitem_name.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_new.3x.html b/contrib/ncurses/doc/html/man/mitem_new.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_new.3x.html rename to contrib/ncurses/doc/html/man/mitem_new.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_opts.3x.html b/contrib/ncurses/doc/html/man/mitem_opts.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_opts.3x.html rename to contrib/ncurses/doc/html/man/mitem_opts.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_userptr.3x.html b/contrib/ncurses/doc/html/man/mitem_userptr.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_userptr.3x.html rename to contrib/ncurses/doc/html/man/mitem_userptr.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_value.3x.html b/contrib/ncurses/doc/html/man/mitem_value.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_value.3x.html rename to contrib/ncurses/doc/html/man/mitem_value.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/mitem_visible.3x.html b/contrib/ncurses/doc/html/man/mitem_visible.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/mitem_visible.3x.html rename to contrib/ncurses/doc/html/man/mitem_visible.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/ncurses.3x.html b/contrib/ncurses/doc/html/man/ncurses.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/ncurses.3x.html rename to contrib/ncurses/doc/html/man/ncurses.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/panel.3x.html b/contrib/ncurses/doc/html/man/panel.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/panel.3x.html rename to contrib/ncurses/doc/html/man/panel.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/resizeterm.3x.html b/contrib/ncurses/doc/html/man/resizeterm.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/resizeterm.3x.html rename to contrib/ncurses/doc/html/man/resizeterm.3x.html diff --git a/contrib/ncurses-5.4/doc/html/man/term.5.html b/contrib/ncurses/doc/html/man/term.5.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/term.5.html rename to contrib/ncurses/doc/html/man/term.5.html diff --git a/contrib/ncurses-5.4/doc/html/man/term.7.html b/contrib/ncurses/doc/html/man/term.7.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/term.7.html rename to contrib/ncurses/doc/html/man/term.7.html diff --git a/contrib/ncurses-5.4/doc/html/man/terminfo.5.html b/contrib/ncurses/doc/html/man/terminfo.5.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/terminfo.5.html rename to contrib/ncurses/doc/html/man/terminfo.5.html diff --git a/contrib/ncurses-5.4/doc/html/man/tic.1m.html b/contrib/ncurses/doc/html/man/tic.1m.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/tic.1m.html rename to contrib/ncurses/doc/html/man/tic.1m.html diff --git a/contrib/ncurses-5.4/doc/html/man/toe.1m.html b/contrib/ncurses/doc/html/man/toe.1m.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/toe.1m.html rename to contrib/ncurses/doc/html/man/toe.1m.html diff --git a/contrib/ncurses-5.4/doc/html/man/tput.1.html b/contrib/ncurses/doc/html/man/tput.1.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/tput.1.html rename to contrib/ncurses/doc/html/man/tput.1.html diff --git a/contrib/ncurses-5.4/doc/html/man/tset.1.html b/contrib/ncurses/doc/html/man/tset.1.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/tset.1.html rename to contrib/ncurses/doc/html/man/tset.1.html diff --git a/contrib/ncurses-5.4/doc/html/man/wresize.3x.html b/contrib/ncurses/doc/html/man/wresize.3x.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/man/wresize.3x.html rename to contrib/ncurses/doc/html/man/wresize.3x.html diff --git a/contrib/ncurses-5.4/doc/html/ncurses-intro.html b/contrib/ncurses/doc/html/ncurses-intro.html similarity index 100% rename from contrib/ncurses-5.4/doc/html/ncurses-intro.html rename to contrib/ncurses/doc/html/ncurses-intro.html diff --git a/contrib/ncurses-5.4/doc/ncurses-intro.doc b/contrib/ncurses/doc/ncurses-intro.doc similarity index 100% rename from contrib/ncurses-5.4/doc/ncurses-intro.doc rename to contrib/ncurses/doc/ncurses-intro.doc diff --git a/contrib/ncurses-5.4/form/Makefile.in b/contrib/ncurses/form/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/form/Makefile.in rename to contrib/ncurses/form/Makefile.in diff --git a/contrib/ncurses-5.4/form/READ.ME b/contrib/ncurses/form/READ.ME similarity index 100% rename from contrib/ncurses-5.4/form/READ.ME rename to contrib/ncurses/form/READ.ME diff --git a/contrib/ncurses-5.4/form/fld_arg.c b/contrib/ncurses/form/fld_arg.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_arg.c rename to contrib/ncurses/form/fld_arg.c diff --git a/contrib/ncurses-5.4/form/fld_attr.c b/contrib/ncurses/form/fld_attr.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_attr.c rename to contrib/ncurses/form/fld_attr.c diff --git a/contrib/ncurses-5.4/form/fld_current.c b/contrib/ncurses/form/fld_current.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_current.c rename to contrib/ncurses/form/fld_current.c diff --git a/contrib/ncurses-5.4/form/fld_def.c b/contrib/ncurses/form/fld_def.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_def.c rename to contrib/ncurses/form/fld_def.c diff --git a/contrib/ncurses-5.4/form/fld_dup.c b/contrib/ncurses/form/fld_dup.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_dup.c rename to contrib/ncurses/form/fld_dup.c diff --git a/contrib/ncurses-5.4/form/fld_ftchoice.c b/contrib/ncurses/form/fld_ftchoice.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_ftchoice.c rename to contrib/ncurses/form/fld_ftchoice.c diff --git a/contrib/ncurses-5.4/form/fld_ftlink.c b/contrib/ncurses/form/fld_ftlink.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_ftlink.c rename to contrib/ncurses/form/fld_ftlink.c diff --git a/contrib/ncurses-5.4/form/fld_info.c b/contrib/ncurses/form/fld_info.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_info.c rename to contrib/ncurses/form/fld_info.c diff --git a/contrib/ncurses-5.4/form/fld_just.c b/contrib/ncurses/form/fld_just.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_just.c rename to contrib/ncurses/form/fld_just.c diff --git a/contrib/ncurses-5.4/form/fld_link.c b/contrib/ncurses/form/fld_link.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_link.c rename to contrib/ncurses/form/fld_link.c diff --git a/contrib/ncurses-5.4/form/fld_max.c b/contrib/ncurses/form/fld_max.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_max.c rename to contrib/ncurses/form/fld_max.c diff --git a/contrib/ncurses-5.4/form/fld_move.c b/contrib/ncurses/form/fld_move.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_move.c rename to contrib/ncurses/form/fld_move.c diff --git a/contrib/ncurses-5.4/form/fld_newftyp.c b/contrib/ncurses/form/fld_newftyp.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_newftyp.c rename to contrib/ncurses/form/fld_newftyp.c diff --git a/contrib/ncurses-5.4/form/fld_opts.c b/contrib/ncurses/form/fld_opts.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_opts.c rename to contrib/ncurses/form/fld_opts.c diff --git a/contrib/ncurses-5.4/form/fld_pad.c b/contrib/ncurses/form/fld_pad.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_pad.c rename to contrib/ncurses/form/fld_pad.c diff --git a/contrib/ncurses-5.4/form/fld_page.c b/contrib/ncurses/form/fld_page.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_page.c rename to contrib/ncurses/form/fld_page.c diff --git a/contrib/ncurses-5.4/form/fld_stat.c b/contrib/ncurses/form/fld_stat.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_stat.c rename to contrib/ncurses/form/fld_stat.c diff --git a/contrib/ncurses-5.4/form/fld_type.c b/contrib/ncurses/form/fld_type.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_type.c rename to contrib/ncurses/form/fld_type.c diff --git a/contrib/ncurses-5.4/form/fld_user.c b/contrib/ncurses/form/fld_user.c similarity index 100% rename from contrib/ncurses-5.4/form/fld_user.c rename to contrib/ncurses/form/fld_user.c diff --git a/contrib/ncurses-5.4/form/form.h b/contrib/ncurses/form/form.h similarity index 100% rename from contrib/ncurses-5.4/form/form.h rename to contrib/ncurses/form/form.h diff --git a/contrib/ncurses-5.4/form/form.priv.h b/contrib/ncurses/form/form.priv.h similarity index 100% rename from contrib/ncurses-5.4/form/form.priv.h rename to contrib/ncurses/form/form.priv.h diff --git a/contrib/ncurses-5.4/form/frm_cursor.c b/contrib/ncurses/form/frm_cursor.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_cursor.c rename to contrib/ncurses/form/frm_cursor.c diff --git a/contrib/ncurses-5.4/form/frm_data.c b/contrib/ncurses/form/frm_data.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_data.c rename to contrib/ncurses/form/frm_data.c diff --git a/contrib/ncurses-5.4/form/frm_def.c b/contrib/ncurses/form/frm_def.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_def.c rename to contrib/ncurses/form/frm_def.c diff --git a/contrib/ncurses-5.4/form/frm_driver.c b/contrib/ncurses/form/frm_driver.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_driver.c rename to contrib/ncurses/form/frm_driver.c diff --git a/contrib/ncurses-5.4/form/frm_hook.c b/contrib/ncurses/form/frm_hook.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_hook.c rename to contrib/ncurses/form/frm_hook.c diff --git a/contrib/ncurses-5.4/form/frm_opts.c b/contrib/ncurses/form/frm_opts.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_opts.c rename to contrib/ncurses/form/frm_opts.c diff --git a/contrib/ncurses-5.4/form/frm_page.c b/contrib/ncurses/form/frm_page.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_page.c rename to contrib/ncurses/form/frm_page.c diff --git a/contrib/ncurses-5.4/form/frm_post.c b/contrib/ncurses/form/frm_post.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_post.c rename to contrib/ncurses/form/frm_post.c diff --git a/contrib/ncurses-5.4/form/frm_req_name.c b/contrib/ncurses/form/frm_req_name.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_req_name.c rename to contrib/ncurses/form/frm_req_name.c diff --git a/contrib/ncurses-5.4/form/frm_scale.c b/contrib/ncurses/form/frm_scale.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_scale.c rename to contrib/ncurses/form/frm_scale.c diff --git a/contrib/ncurses-5.4/form/frm_sub.c b/contrib/ncurses/form/frm_sub.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_sub.c rename to contrib/ncurses/form/frm_sub.c diff --git a/contrib/ncurses-5.4/form/frm_user.c b/contrib/ncurses/form/frm_user.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_user.c rename to contrib/ncurses/form/frm_user.c diff --git a/contrib/ncurses-5.4/form/frm_win.c b/contrib/ncurses/form/frm_win.c similarity index 100% rename from contrib/ncurses-5.4/form/frm_win.c rename to contrib/ncurses/form/frm_win.c diff --git a/contrib/ncurses-5.4/form/fty_alnum.c b/contrib/ncurses/form/fty_alnum.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_alnum.c rename to contrib/ncurses/form/fty_alnum.c diff --git a/contrib/ncurses-5.4/form/fty_alpha.c b/contrib/ncurses/form/fty_alpha.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_alpha.c rename to contrib/ncurses/form/fty_alpha.c diff --git a/contrib/ncurses-5.4/form/fty_enum.c b/contrib/ncurses/form/fty_enum.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_enum.c rename to contrib/ncurses/form/fty_enum.c diff --git a/contrib/ncurses-5.4/form/fty_int.c b/contrib/ncurses/form/fty_int.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_int.c rename to contrib/ncurses/form/fty_int.c diff --git a/contrib/ncurses-5.4/form/fty_ipv4.c b/contrib/ncurses/form/fty_ipv4.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_ipv4.c rename to contrib/ncurses/form/fty_ipv4.c diff --git a/contrib/ncurses-5.4/form/fty_num.c b/contrib/ncurses/form/fty_num.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_num.c rename to contrib/ncurses/form/fty_num.c diff --git a/contrib/ncurses-5.4/form/fty_regex.c b/contrib/ncurses/form/fty_regex.c similarity index 100% rename from contrib/ncurses-5.4/form/fty_regex.c rename to contrib/ncurses/form/fty_regex.c diff --git a/contrib/ncurses-5.4/form/headers b/contrib/ncurses/form/headers similarity index 100% rename from contrib/ncurses-5.4/form/headers rename to contrib/ncurses/form/headers diff --git a/contrib/ncurses-5.4/form/llib-lform b/contrib/ncurses/form/llib-lform similarity index 100% rename from contrib/ncurses-5.4/form/llib-lform rename to contrib/ncurses/form/llib-lform diff --git a/contrib/ncurses-5.4/form/llib-lformw b/contrib/ncurses/form/llib-lformw similarity index 100% rename from contrib/ncurses-5.4/form/llib-lformw rename to contrib/ncurses/form/llib-lformw diff --git a/contrib/ncurses-5.4/form/modules b/contrib/ncurses/form/modules similarity index 100% rename from contrib/ncurses-5.4/form/modules rename to contrib/ncurses/form/modules diff --git a/contrib/ncurses-5.4/include/Caps b/contrib/ncurses/include/Caps similarity index 100% rename from contrib/ncurses-5.4/include/Caps rename to contrib/ncurses/include/Caps diff --git a/contrib/ncurses-5.4/include/Caps.aix4 b/contrib/ncurses/include/Caps.aix4 similarity index 100% rename from contrib/ncurses-5.4/include/Caps.aix4 rename to contrib/ncurses/include/Caps.aix4 diff --git a/contrib/ncurses-5.4/include/Caps.hpux11 b/contrib/ncurses/include/Caps.hpux11 similarity index 100% rename from contrib/ncurses-5.4/include/Caps.hpux11 rename to contrib/ncurses/include/Caps.hpux11 diff --git a/contrib/ncurses-5.4/include/Caps.keys b/contrib/ncurses/include/Caps.keys similarity index 100% rename from contrib/ncurses-5.4/include/Caps.keys rename to contrib/ncurses/include/Caps.keys diff --git a/contrib/ncurses-5.4/include/Caps.osf1r5 b/contrib/ncurses/include/Caps.osf1r5 similarity index 100% rename from contrib/ncurses-5.4/include/Caps.osf1r5 rename to contrib/ncurses/include/Caps.osf1r5 diff --git a/contrib/ncurses-5.4/include/Caps.uwin b/contrib/ncurses/include/Caps.uwin similarity index 100% rename from contrib/ncurses-5.4/include/Caps.uwin rename to contrib/ncurses/include/Caps.uwin diff --git a/contrib/ncurses-5.4/include/MKhashsize.sh b/contrib/ncurses/include/MKhashsize.sh similarity index 100% rename from contrib/ncurses-5.4/include/MKhashsize.sh rename to contrib/ncurses/include/MKhashsize.sh diff --git a/contrib/ncurses-5.4/include/MKkey_defs.sh b/contrib/ncurses/include/MKkey_defs.sh similarity index 100% rename from contrib/ncurses-5.4/include/MKkey_defs.sh rename to contrib/ncurses/include/MKkey_defs.sh diff --git a/contrib/ncurses-5.4/include/MKncurses_def.sh b/contrib/ncurses/include/MKncurses_def.sh similarity index 100% rename from contrib/ncurses-5.4/include/MKncurses_def.sh rename to contrib/ncurses/include/MKncurses_def.sh diff --git a/contrib/ncurses-5.4/include/MKparametrized.sh b/contrib/ncurses/include/MKparametrized.sh similarity index 100% rename from contrib/ncurses-5.4/include/MKparametrized.sh rename to contrib/ncurses/include/MKparametrized.sh diff --git a/contrib/ncurses-5.4/include/MKterm.h.awk.in b/contrib/ncurses/include/MKterm.h.awk.in similarity index 100% rename from contrib/ncurses-5.4/include/MKterm.h.awk.in rename to contrib/ncurses/include/MKterm.h.awk.in diff --git a/contrib/ncurses-5.4/include/Makefile.in b/contrib/ncurses/include/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/include/Makefile.in rename to contrib/ncurses/include/Makefile.in diff --git a/contrib/ncurses-5.4/include/capdefaults.c b/contrib/ncurses/include/capdefaults.c similarity index 100% rename from contrib/ncurses-5.4/include/capdefaults.c rename to contrib/ncurses/include/capdefaults.c diff --git a/contrib/ncurses-5.4/include/curses.h.in b/contrib/ncurses/include/curses.h.in similarity index 100% rename from contrib/ncurses-5.4/include/curses.h.in rename to contrib/ncurses/include/curses.h.in diff --git a/contrib/ncurses-5.4/include/curses.tail b/contrib/ncurses/include/curses.tail similarity index 100% rename from contrib/ncurses-5.4/include/curses.tail rename to contrib/ncurses/include/curses.tail diff --git a/contrib/ncurses-5.4/include/curses.wide b/contrib/ncurses/include/curses.wide similarity index 100% rename from contrib/ncurses-5.4/include/curses.wide rename to contrib/ncurses/include/curses.wide diff --git a/contrib/ncurses-5.4/include/edit_cfg.sh b/contrib/ncurses/include/edit_cfg.sh similarity index 100% rename from contrib/ncurses-5.4/include/edit_cfg.sh rename to contrib/ncurses/include/edit_cfg.sh diff --git a/contrib/ncurses-5.4/include/headers b/contrib/ncurses/include/headers similarity index 100% rename from contrib/ncurses-5.4/include/headers rename to contrib/ncurses/include/headers diff --git a/contrib/ncurses-5.4/include/nc_alloc.h b/contrib/ncurses/include/nc_alloc.h similarity index 100% rename from contrib/ncurses-5.4/include/nc_alloc.h rename to contrib/ncurses/include/nc_alloc.h diff --git a/contrib/ncurses-5.4/include/nc_panel.h b/contrib/ncurses/include/nc_panel.h similarity index 100% rename from contrib/ncurses-5.4/include/nc_panel.h rename to contrib/ncurses/include/nc_panel.h diff --git a/contrib/ncurses-5.4/include/ncurses_cfg.hin b/contrib/ncurses/include/ncurses_cfg.hin similarity index 100% rename from contrib/ncurses-5.4/include/ncurses_cfg.hin rename to contrib/ncurses/include/ncurses_cfg.hin diff --git a/contrib/ncurses-5.4/include/ncurses_defs b/contrib/ncurses/include/ncurses_defs similarity index 100% rename from contrib/ncurses-5.4/include/ncurses_defs rename to contrib/ncurses/include/ncurses_defs diff --git a/contrib/ncurses-5.4/include/ncurses_dll.h b/contrib/ncurses/include/ncurses_dll.h similarity index 100% rename from contrib/ncurses-5.4/include/ncurses_dll.h rename to contrib/ncurses/include/ncurses_dll.h diff --git a/contrib/ncurses-5.4/include/term_entry.h b/contrib/ncurses/include/term_entry.h similarity index 100% rename from contrib/ncurses-5.4/include/term_entry.h rename to contrib/ncurses/include/term_entry.h diff --git a/contrib/ncurses-5.4/include/termcap.h.in b/contrib/ncurses/include/termcap.h.in similarity index 100% rename from contrib/ncurses-5.4/include/termcap.h.in rename to contrib/ncurses/include/termcap.h.in diff --git a/contrib/ncurses-5.4/include/tic.h b/contrib/ncurses/include/tic.h similarity index 100% rename from contrib/ncurses-5.4/include/tic.h rename to contrib/ncurses/include/tic.h diff --git a/contrib/ncurses-5.4/include/unctrl.h.in b/contrib/ncurses/include/unctrl.h.in similarity index 100% rename from contrib/ncurses-5.4/include/unctrl.h.in rename to contrib/ncurses/include/unctrl.h.in diff --git a/contrib/ncurses-5.4/install-sh b/contrib/ncurses/install-sh similarity index 100% rename from contrib/ncurses-5.4/install-sh rename to contrib/ncurses/install-sh diff --git a/contrib/ncurses-5.4/menu/Makefile.in b/contrib/ncurses/menu/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/menu/Makefile.in rename to contrib/ncurses/menu/Makefile.in diff --git a/contrib/ncurses-5.4/menu/READ.ME b/contrib/ncurses/menu/READ.ME similarity index 100% rename from contrib/ncurses-5.4/menu/READ.ME rename to contrib/ncurses/menu/READ.ME diff --git a/contrib/ncurses-5.4/menu/eti.h b/contrib/ncurses/menu/eti.h similarity index 100% rename from contrib/ncurses-5.4/menu/eti.h rename to contrib/ncurses/menu/eti.h diff --git a/contrib/ncurses-5.4/menu/headers b/contrib/ncurses/menu/headers similarity index 100% rename from contrib/ncurses-5.4/menu/headers rename to contrib/ncurses/menu/headers diff --git a/contrib/ncurses-5.4/menu/llib-lmenu b/contrib/ncurses/menu/llib-lmenu similarity index 100% rename from contrib/ncurses-5.4/menu/llib-lmenu rename to contrib/ncurses/menu/llib-lmenu diff --git a/contrib/ncurses-5.4/menu/llib-lmenuw b/contrib/ncurses/menu/llib-lmenuw similarity index 100% rename from contrib/ncurses-5.4/menu/llib-lmenuw rename to contrib/ncurses/menu/llib-lmenuw diff --git a/contrib/ncurses-5.4/menu/m_attribs.c b/contrib/ncurses/menu/m_attribs.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_attribs.c rename to contrib/ncurses/menu/m_attribs.c diff --git a/contrib/ncurses-5.4/menu/m_cursor.c b/contrib/ncurses/menu/m_cursor.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_cursor.c rename to contrib/ncurses/menu/m_cursor.c diff --git a/contrib/ncurses-5.4/menu/m_driver.c b/contrib/ncurses/menu/m_driver.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_driver.c rename to contrib/ncurses/menu/m_driver.c diff --git a/contrib/ncurses-5.4/menu/m_format.c b/contrib/ncurses/menu/m_format.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_format.c rename to contrib/ncurses/menu/m_format.c diff --git a/contrib/ncurses-5.4/menu/m_global.c b/contrib/ncurses/menu/m_global.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_global.c rename to contrib/ncurses/menu/m_global.c diff --git a/contrib/ncurses-5.4/menu/m_hook.c b/contrib/ncurses/menu/m_hook.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_hook.c rename to contrib/ncurses/menu/m_hook.c diff --git a/contrib/ncurses-5.4/menu/m_item_cur.c b/contrib/ncurses/menu/m_item_cur.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_cur.c rename to contrib/ncurses/menu/m_item_cur.c diff --git a/contrib/ncurses-5.4/menu/m_item_nam.c b/contrib/ncurses/menu/m_item_nam.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_nam.c rename to contrib/ncurses/menu/m_item_nam.c diff --git a/contrib/ncurses-5.4/menu/m_item_new.c b/contrib/ncurses/menu/m_item_new.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_new.c rename to contrib/ncurses/menu/m_item_new.c diff --git a/contrib/ncurses-5.4/menu/m_item_opt.c b/contrib/ncurses/menu/m_item_opt.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_opt.c rename to contrib/ncurses/menu/m_item_opt.c diff --git a/contrib/ncurses-5.4/menu/m_item_top.c b/contrib/ncurses/menu/m_item_top.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_top.c rename to contrib/ncurses/menu/m_item_top.c diff --git a/contrib/ncurses-5.4/menu/m_item_use.c b/contrib/ncurses/menu/m_item_use.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_use.c rename to contrib/ncurses/menu/m_item_use.c diff --git a/contrib/ncurses-5.4/menu/m_item_val.c b/contrib/ncurses/menu/m_item_val.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_val.c rename to contrib/ncurses/menu/m_item_val.c diff --git a/contrib/ncurses-5.4/menu/m_item_vis.c b/contrib/ncurses/menu/m_item_vis.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_item_vis.c rename to contrib/ncurses/menu/m_item_vis.c diff --git a/contrib/ncurses-5.4/menu/m_items.c b/contrib/ncurses/menu/m_items.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_items.c rename to contrib/ncurses/menu/m_items.c diff --git a/contrib/ncurses-5.4/menu/m_new.c b/contrib/ncurses/menu/m_new.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_new.c rename to contrib/ncurses/menu/m_new.c diff --git a/contrib/ncurses-5.4/menu/m_opts.c b/contrib/ncurses/menu/m_opts.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_opts.c rename to contrib/ncurses/menu/m_opts.c diff --git a/contrib/ncurses-5.4/menu/m_pad.c b/contrib/ncurses/menu/m_pad.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_pad.c rename to contrib/ncurses/menu/m_pad.c diff --git a/contrib/ncurses-5.4/menu/m_pattern.c b/contrib/ncurses/menu/m_pattern.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_pattern.c rename to contrib/ncurses/menu/m_pattern.c diff --git a/contrib/ncurses-5.4/menu/m_post.c b/contrib/ncurses/menu/m_post.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_post.c rename to contrib/ncurses/menu/m_post.c diff --git a/contrib/ncurses-5.4/menu/m_req_name.c b/contrib/ncurses/menu/m_req_name.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_req_name.c rename to contrib/ncurses/menu/m_req_name.c diff --git a/contrib/ncurses-5.4/menu/m_scale.c b/contrib/ncurses/menu/m_scale.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_scale.c rename to contrib/ncurses/menu/m_scale.c diff --git a/contrib/ncurses-5.4/menu/m_spacing.c b/contrib/ncurses/menu/m_spacing.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_spacing.c rename to contrib/ncurses/menu/m_spacing.c diff --git a/contrib/ncurses-5.4/menu/m_sub.c b/contrib/ncurses/menu/m_sub.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_sub.c rename to contrib/ncurses/menu/m_sub.c diff --git a/contrib/ncurses-5.4/menu/m_userptr.c b/contrib/ncurses/menu/m_userptr.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_userptr.c rename to contrib/ncurses/menu/m_userptr.c diff --git a/contrib/ncurses-5.4/menu/m_win.c b/contrib/ncurses/menu/m_win.c similarity index 100% rename from contrib/ncurses-5.4/menu/m_win.c rename to contrib/ncurses/menu/m_win.c diff --git a/contrib/ncurses-5.4/menu/menu.h b/contrib/ncurses/menu/menu.h similarity index 100% rename from contrib/ncurses-5.4/menu/menu.h rename to contrib/ncurses/menu/menu.h diff --git a/contrib/ncurses-5.4/menu/menu.priv.h b/contrib/ncurses/menu/menu.priv.h similarity index 100% rename from contrib/ncurses-5.4/menu/menu.priv.h rename to contrib/ncurses/menu/menu.priv.h diff --git a/contrib/ncurses-5.4/menu/mf_common.h b/contrib/ncurses/menu/mf_common.h similarity index 100% rename from contrib/ncurses-5.4/menu/mf_common.h rename to contrib/ncurses/menu/mf_common.h diff --git a/contrib/ncurses-5.4/menu/modules b/contrib/ncurses/menu/modules similarity index 100% rename from contrib/ncurses-5.4/menu/modules rename to contrib/ncurses/menu/modules diff --git a/contrib/ncurses-5.4/misc/Makefile.in b/contrib/ncurses/misc/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/misc/Makefile.in rename to contrib/ncurses/misc/Makefile.in diff --git a/contrib/ncurses-5.4/misc/chkdef.cmd b/contrib/ncurses/misc/chkdef.cmd similarity index 100% rename from contrib/ncurses-5.4/misc/chkdef.cmd rename to contrib/ncurses/misc/chkdef.cmd diff --git a/contrib/ncurses-5.4/misc/cleantic.cmd b/contrib/ncurses/misc/cleantic.cmd similarity index 100% rename from contrib/ncurses-5.4/misc/cleantic.cmd rename to contrib/ncurses/misc/cleantic.cmd diff --git a/contrib/ncurses-5.4/misc/cmpdef.cmd b/contrib/ncurses/misc/cmpdef.cmd similarity index 100% rename from contrib/ncurses-5.4/misc/cmpdef.cmd rename to contrib/ncurses/misc/cmpdef.cmd diff --git a/contrib/ncurses-5.4/misc/csort b/contrib/ncurses/misc/csort similarity index 100% rename from contrib/ncurses-5.4/misc/csort rename to contrib/ncurses/misc/csort diff --git a/contrib/ncurses-5.4/misc/emx.src b/contrib/ncurses/misc/emx.src similarity index 100% rename from contrib/ncurses-5.4/misc/emx.src rename to contrib/ncurses/misc/emx.src diff --git a/contrib/ncurses-5.4/misc/form.def b/contrib/ncurses/misc/form.def similarity index 100% rename from contrib/ncurses-5.4/misc/form.def rename to contrib/ncurses/misc/form.def diff --git a/contrib/ncurses-5.4/misc/form.ref b/contrib/ncurses/misc/form.ref similarity index 100% rename from contrib/ncurses-5.4/misc/form.ref rename to contrib/ncurses/misc/form.ref diff --git a/contrib/ncurses-5.4/misc/indent.pro b/contrib/ncurses/misc/indent.pro similarity index 100% rename from contrib/ncurses-5.4/misc/indent.pro rename to contrib/ncurses/misc/indent.pro diff --git a/contrib/ncurses-5.4/misc/makedef.cmd b/contrib/ncurses/misc/makedef.cmd similarity index 100% rename from contrib/ncurses-5.4/misc/makedef.cmd rename to contrib/ncurses/misc/makedef.cmd diff --git a/contrib/ncurses-5.4/misc/makellib b/contrib/ncurses/misc/makellib similarity index 100% rename from contrib/ncurses-5.4/misc/makellib rename to contrib/ncurses/misc/makellib diff --git a/contrib/ncurses-5.4/misc/menu.def b/contrib/ncurses/misc/menu.def similarity index 100% rename from contrib/ncurses-5.4/misc/menu.def rename to contrib/ncurses/misc/menu.def diff --git a/contrib/ncurses-5.4/misc/menu.ref b/contrib/ncurses/misc/menu.ref similarity index 100% rename from contrib/ncurses-5.4/misc/menu.ref rename to contrib/ncurses/misc/menu.ref diff --git a/contrib/ncurses-5.4/misc/ncurses.def b/contrib/ncurses/misc/ncurses.def similarity index 100% rename from contrib/ncurses-5.4/misc/ncurses.def rename to contrib/ncurses/misc/ncurses.def diff --git a/contrib/ncurses-5.4/misc/ncurses.ref b/contrib/ncurses/misc/ncurses.ref similarity index 100% rename from contrib/ncurses-5.4/misc/ncurses.ref rename to contrib/ncurses/misc/ncurses.ref diff --git a/contrib/ncurses-5.4/misc/panel.def b/contrib/ncurses/misc/panel.def similarity index 100% rename from contrib/ncurses-5.4/misc/panel.def rename to contrib/ncurses/misc/panel.def diff --git a/contrib/ncurses-5.4/misc/panel.ref b/contrib/ncurses/misc/panel.ref similarity index 100% rename from contrib/ncurses-5.4/misc/panel.ref rename to contrib/ncurses/misc/panel.ref diff --git a/contrib/ncurses-5.4/misc/run_tic.in b/contrib/ncurses/misc/run_tic.in similarity index 100% rename from contrib/ncurses-5.4/misc/run_tic.in rename to contrib/ncurses/misc/run_tic.in diff --git a/contrib/ncurses-5.4/misc/shlib b/contrib/ncurses/misc/shlib similarity index 100% rename from contrib/ncurses-5.4/misc/shlib rename to contrib/ncurses/misc/shlib diff --git a/contrib/ncurses-5.4/misc/tabset/std b/contrib/ncurses/misc/tabset/std similarity index 100% rename from contrib/ncurses-5.4/misc/tabset/std rename to contrib/ncurses/misc/tabset/std diff --git a/contrib/ncurses-5.4/misc/tabset/stdcrt b/contrib/ncurses/misc/tabset/stdcrt similarity index 100% rename from contrib/ncurses-5.4/misc/tabset/stdcrt rename to contrib/ncurses/misc/tabset/stdcrt diff --git a/contrib/ncurses-5.4/misc/tabset/vt100 b/contrib/ncurses/misc/tabset/vt100 similarity index 100% rename from contrib/ncurses-5.4/misc/tabset/vt100 rename to contrib/ncurses/misc/tabset/vt100 diff --git a/contrib/ncurses-5.4/misc/tabset/vt300 b/contrib/ncurses/misc/tabset/vt300 similarity index 100% rename from contrib/ncurses-5.4/misc/tabset/vt300 rename to contrib/ncurses/misc/tabset/vt300 diff --git a/contrib/ncurses-5.4/misc/tdlint b/contrib/ncurses/misc/tdlint similarity index 100% rename from contrib/ncurses-5.4/misc/tdlint rename to contrib/ncurses/misc/tdlint diff --git a/contrib/ncurses-5.4/misc/terminfo.src b/contrib/ncurses/misc/terminfo.src similarity index 100% rename from contrib/ncurses-5.4/misc/terminfo.src rename to contrib/ncurses/misc/terminfo.src diff --git a/contrib/ncurses-5.4/mk-0th.awk b/contrib/ncurses/mk-0th.awk similarity index 100% rename from contrib/ncurses-5.4/mk-0th.awk rename to contrib/ncurses/mk-0th.awk diff --git a/contrib/ncurses-5.4/mk-1st.awk b/contrib/ncurses/mk-1st.awk similarity index 100% rename from contrib/ncurses-5.4/mk-1st.awk rename to contrib/ncurses/mk-1st.awk diff --git a/contrib/ncurses-5.4/mk-2nd.awk b/contrib/ncurses/mk-2nd.awk similarity index 100% rename from contrib/ncurses-5.4/mk-2nd.awk rename to contrib/ncurses/mk-2nd.awk diff --git a/contrib/ncurses-5.4/mkinstalldirs b/contrib/ncurses/mkinstalldirs similarity index 100% rename from contrib/ncurses-5.4/mkinstalldirs rename to contrib/ncurses/mkinstalldirs diff --git a/contrib/ncurses-5.4/ncurses/Makefile.in b/contrib/ncurses/ncurses/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/ncurses/Makefile.in rename to contrib/ncurses/ncurses/Makefile.in diff --git a/contrib/ncurses-5.4/ncurses/README b/contrib/ncurses/ncurses/README similarity index 100% rename from contrib/ncurses-5.4/ncurses/README rename to contrib/ncurses/ncurses/README diff --git a/contrib/ncurses-5.4/ncurses/README.IZ b/contrib/ncurses/ncurses/README.IZ similarity index 100% rename from contrib/ncurses-5.4/ncurses/README.IZ rename to contrib/ncurses/ncurses/README.IZ diff --git a/contrib/ncurses-5.4/ncurses/SigAction.h b/contrib/ncurses/ncurses/SigAction.h similarity index 100% rename from contrib/ncurses-5.4/ncurses/SigAction.h rename to contrib/ncurses/ncurses/SigAction.h diff --git a/contrib/ncurses-5.4/ncurses/base/MKkeyname.awk b/contrib/ncurses/ncurses/base/MKkeyname.awk similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/MKkeyname.awk rename to contrib/ncurses/ncurses/base/MKkeyname.awk diff --git a/contrib/ncurses-5.4/ncurses/base/MKlib_gen.sh b/contrib/ncurses/ncurses/base/MKlib_gen.sh similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/MKlib_gen.sh rename to contrib/ncurses/ncurses/base/MKlib_gen.sh diff --git a/contrib/ncurses-5.4/ncurses/base/MKunctrl.awk b/contrib/ncurses/ncurses/base/MKunctrl.awk similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/MKunctrl.awk rename to contrib/ncurses/ncurses/base/MKunctrl.awk diff --git a/contrib/ncurses-5.4/ncurses/base/README b/contrib/ncurses/ncurses/base/README similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/README rename to contrib/ncurses/ncurses/base/README diff --git a/contrib/ncurses-5.4/ncurses/base/define_key.c b/contrib/ncurses/ncurses/base/define_key.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/define_key.c rename to contrib/ncurses/ncurses/base/define_key.c diff --git a/contrib/ncurses-5.4/ncurses/base/key_defined.c b/contrib/ncurses/ncurses/base/key_defined.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/key_defined.c rename to contrib/ncurses/ncurses/base/key_defined.c diff --git a/contrib/ncurses-5.4/ncurses/base/keybound.c b/contrib/ncurses/ncurses/base/keybound.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/keybound.c rename to contrib/ncurses/ncurses/base/keybound.c diff --git a/contrib/ncurses-5.4/ncurses/base/keyok.c b/contrib/ncurses/ncurses/base/keyok.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/keyok.c rename to contrib/ncurses/ncurses/base/keyok.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_addch.c b/contrib/ncurses/ncurses/base/lib_addch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_addch.c rename to contrib/ncurses/ncurses/base/lib_addch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_addstr.c b/contrib/ncurses/ncurses/base/lib_addstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_addstr.c rename to contrib/ncurses/ncurses/base/lib_addstr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_beep.c b/contrib/ncurses/ncurses/base/lib_beep.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_beep.c rename to contrib/ncurses/ncurses/base/lib_beep.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_bkgd.c b/contrib/ncurses/ncurses/base/lib_bkgd.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_bkgd.c rename to contrib/ncurses/ncurses/base/lib_bkgd.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_box.c b/contrib/ncurses/ncurses/base/lib_box.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_box.c rename to contrib/ncurses/ncurses/base/lib_box.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_chgat.c b/contrib/ncurses/ncurses/base/lib_chgat.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_chgat.c rename to contrib/ncurses/ncurses/base/lib_chgat.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_clear.c b/contrib/ncurses/ncurses/base/lib_clear.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_clear.c rename to contrib/ncurses/ncurses/base/lib_clear.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_clearok.c b/contrib/ncurses/ncurses/base/lib_clearok.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_clearok.c rename to contrib/ncurses/ncurses/base/lib_clearok.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_clrbot.c b/contrib/ncurses/ncurses/base/lib_clrbot.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_clrbot.c rename to contrib/ncurses/ncurses/base/lib_clrbot.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_clreol.c b/contrib/ncurses/ncurses/base/lib_clreol.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_clreol.c rename to contrib/ncurses/ncurses/base/lib_clreol.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_color.c b/contrib/ncurses/ncurses/base/lib_color.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_color.c rename to contrib/ncurses/ncurses/base/lib_color.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_colorset.c b/contrib/ncurses/ncurses/base/lib_colorset.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_colorset.c rename to contrib/ncurses/ncurses/base/lib_colorset.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_delch.c b/contrib/ncurses/ncurses/base/lib_delch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_delch.c rename to contrib/ncurses/ncurses/base/lib_delch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_delwin.c b/contrib/ncurses/ncurses/base/lib_delwin.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_delwin.c rename to contrib/ncurses/ncurses/base/lib_delwin.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_dft_fgbg.c b/contrib/ncurses/ncurses/base/lib_dft_fgbg.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_dft_fgbg.c rename to contrib/ncurses/ncurses/base/lib_dft_fgbg.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_echo.c b/contrib/ncurses/ncurses/base/lib_echo.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_echo.c rename to contrib/ncurses/ncurses/base/lib_echo.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_endwin.c b/contrib/ncurses/ncurses/base/lib_endwin.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_endwin.c rename to contrib/ncurses/ncurses/base/lib_endwin.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_erase.c b/contrib/ncurses/ncurses/base/lib_erase.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_erase.c rename to contrib/ncurses/ncurses/base/lib_erase.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_flash.c b/contrib/ncurses/ncurses/base/lib_flash.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_flash.c rename to contrib/ncurses/ncurses/base/lib_flash.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_freeall.c b/contrib/ncurses/ncurses/base/lib_freeall.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_freeall.c rename to contrib/ncurses/ncurses/base/lib_freeall.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_getch.c b/contrib/ncurses/ncurses/base/lib_getch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_getch.c rename to contrib/ncurses/ncurses/base/lib_getch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_getstr.c b/contrib/ncurses/ncurses/base/lib_getstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_getstr.c rename to contrib/ncurses/ncurses/base/lib_getstr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_hline.c b/contrib/ncurses/ncurses/base/lib_hline.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_hline.c rename to contrib/ncurses/ncurses/base/lib_hline.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_immedok.c b/contrib/ncurses/ncurses/base/lib_immedok.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_immedok.c rename to contrib/ncurses/ncurses/base/lib_immedok.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_inchstr.c b/contrib/ncurses/ncurses/base/lib_inchstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_inchstr.c rename to contrib/ncurses/ncurses/base/lib_inchstr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_initscr.c b/contrib/ncurses/ncurses/base/lib_initscr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_initscr.c rename to contrib/ncurses/ncurses/base/lib_initscr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_insch.c b/contrib/ncurses/ncurses/base/lib_insch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_insch.c rename to contrib/ncurses/ncurses/base/lib_insch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_insdel.c b/contrib/ncurses/ncurses/base/lib_insdel.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_insdel.c rename to contrib/ncurses/ncurses/base/lib_insdel.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_instr.c b/contrib/ncurses/ncurses/base/lib_instr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_instr.c rename to contrib/ncurses/ncurses/base/lib_instr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_isendwin.c b/contrib/ncurses/ncurses/base/lib_isendwin.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_isendwin.c rename to contrib/ncurses/ncurses/base/lib_isendwin.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_leaveok.c b/contrib/ncurses/ncurses/base/lib_leaveok.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_leaveok.c rename to contrib/ncurses/ncurses/base/lib_leaveok.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_mouse.c b/contrib/ncurses/ncurses/base/lib_mouse.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_mouse.c rename to contrib/ncurses/ncurses/base/lib_mouse.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_move.c b/contrib/ncurses/ncurses/base/lib_move.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_move.c rename to contrib/ncurses/ncurses/base/lib_move.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_mvwin.c b/contrib/ncurses/ncurses/base/lib_mvwin.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_mvwin.c rename to contrib/ncurses/ncurses/base/lib_mvwin.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_newterm.c b/contrib/ncurses/ncurses/base/lib_newterm.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_newterm.c rename to contrib/ncurses/ncurses/base/lib_newterm.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_newwin.c b/contrib/ncurses/ncurses/base/lib_newwin.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_newwin.c rename to contrib/ncurses/ncurses/base/lib_newwin.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_nl.c b/contrib/ncurses/ncurses/base/lib_nl.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_nl.c rename to contrib/ncurses/ncurses/base/lib_nl.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_overlay.c b/contrib/ncurses/ncurses/base/lib_overlay.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_overlay.c rename to contrib/ncurses/ncurses/base/lib_overlay.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_pad.c b/contrib/ncurses/ncurses/base/lib_pad.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_pad.c rename to contrib/ncurses/ncurses/base/lib_pad.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_printw.c b/contrib/ncurses/ncurses/base/lib_printw.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_printw.c rename to contrib/ncurses/ncurses/base/lib_printw.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_redrawln.c b/contrib/ncurses/ncurses/base/lib_redrawln.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_redrawln.c rename to contrib/ncurses/ncurses/base/lib_redrawln.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_refresh.c b/contrib/ncurses/ncurses/base/lib_refresh.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_refresh.c rename to contrib/ncurses/ncurses/base/lib_refresh.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_restart.c b/contrib/ncurses/ncurses/base/lib_restart.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_restart.c rename to contrib/ncurses/ncurses/base/lib_restart.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_scanw.c b/contrib/ncurses/ncurses/base/lib_scanw.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_scanw.c rename to contrib/ncurses/ncurses/base/lib_scanw.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_screen.c b/contrib/ncurses/ncurses/base/lib_screen.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_screen.c rename to contrib/ncurses/ncurses/base/lib_screen.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_scroll.c b/contrib/ncurses/ncurses/base/lib_scroll.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_scroll.c rename to contrib/ncurses/ncurses/base/lib_scroll.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_scrollok.c b/contrib/ncurses/ncurses/base/lib_scrollok.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_scrollok.c rename to contrib/ncurses/ncurses/base/lib_scrollok.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_scrreg.c b/contrib/ncurses/ncurses/base/lib_scrreg.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_scrreg.c rename to contrib/ncurses/ncurses/base/lib_scrreg.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_set_term.c b/contrib/ncurses/ncurses/base/lib_set_term.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_set_term.c rename to contrib/ncurses/ncurses/base/lib_set_term.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slk.c b/contrib/ncurses/ncurses/base/lib_slk.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slk.c rename to contrib/ncurses/ncurses/base/lib_slk.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkatr_set.c b/contrib/ncurses/ncurses/base/lib_slkatr_set.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkatr_set.c rename to contrib/ncurses/ncurses/base/lib_slkatr_set.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkatrof.c b/contrib/ncurses/ncurses/base/lib_slkatrof.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkatrof.c rename to contrib/ncurses/ncurses/base/lib_slkatrof.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkatron.c b/contrib/ncurses/ncurses/base/lib_slkatron.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkatron.c rename to contrib/ncurses/ncurses/base/lib_slkatron.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkatrset.c b/contrib/ncurses/ncurses/base/lib_slkatrset.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkatrset.c rename to contrib/ncurses/ncurses/base/lib_slkatrset.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkattr.c b/contrib/ncurses/ncurses/base/lib_slkattr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkattr.c rename to contrib/ncurses/ncurses/base/lib_slkattr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkclear.c b/contrib/ncurses/ncurses/base/lib_slkclear.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkclear.c rename to contrib/ncurses/ncurses/base/lib_slkclear.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkcolor.c b/contrib/ncurses/ncurses/base/lib_slkcolor.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkcolor.c rename to contrib/ncurses/ncurses/base/lib_slkcolor.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkinit.c b/contrib/ncurses/ncurses/base/lib_slkinit.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkinit.c rename to contrib/ncurses/ncurses/base/lib_slkinit.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slklab.c b/contrib/ncurses/ncurses/base/lib_slklab.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slklab.c rename to contrib/ncurses/ncurses/base/lib_slklab.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkrefr.c b/contrib/ncurses/ncurses/base/lib_slkrefr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkrefr.c rename to contrib/ncurses/ncurses/base/lib_slkrefr.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slkset.c b/contrib/ncurses/ncurses/base/lib_slkset.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slkset.c rename to contrib/ncurses/ncurses/base/lib_slkset.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_slktouch.c b/contrib/ncurses/ncurses/base/lib_slktouch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_slktouch.c rename to contrib/ncurses/ncurses/base/lib_slktouch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_touch.c b/contrib/ncurses/ncurses/base/lib_touch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_touch.c rename to contrib/ncurses/ncurses/base/lib_touch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_ungetch.c b/contrib/ncurses/ncurses/base/lib_ungetch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_ungetch.c rename to contrib/ncurses/ncurses/base/lib_ungetch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_vline.c b/contrib/ncurses/ncurses/base/lib_vline.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_vline.c rename to contrib/ncurses/ncurses/base/lib_vline.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_wattroff.c b/contrib/ncurses/ncurses/base/lib_wattroff.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_wattroff.c rename to contrib/ncurses/ncurses/base/lib_wattroff.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_wattron.c b/contrib/ncurses/ncurses/base/lib_wattron.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_wattron.c rename to contrib/ncurses/ncurses/base/lib_wattron.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_winch.c b/contrib/ncurses/ncurses/base/lib_winch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_winch.c rename to contrib/ncurses/ncurses/base/lib_winch.c diff --git a/contrib/ncurses-5.4/ncurses/base/lib_window.c b/contrib/ncurses/ncurses/base/lib_window.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/lib_window.c rename to contrib/ncurses/ncurses/base/lib_window.c diff --git a/contrib/ncurses-5.4/ncurses/base/memmove.c b/contrib/ncurses/ncurses/base/memmove.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/memmove.c rename to contrib/ncurses/ncurses/base/memmove.c diff --git a/contrib/ncurses-5.4/ncurses/base/nc_panel.c b/contrib/ncurses/ncurses/base/nc_panel.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/nc_panel.c rename to contrib/ncurses/ncurses/base/nc_panel.c diff --git a/contrib/ncurses-5.4/ncurses/base/resizeterm.c b/contrib/ncurses/ncurses/base/resizeterm.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/resizeterm.c rename to contrib/ncurses/ncurses/base/resizeterm.c diff --git a/contrib/ncurses-5.4/ncurses/base/safe_sprintf.c b/contrib/ncurses/ncurses/base/safe_sprintf.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/safe_sprintf.c rename to contrib/ncurses/ncurses/base/safe_sprintf.c diff --git a/contrib/ncurses-5.4/ncurses/base/sigaction.c b/contrib/ncurses/ncurses/base/sigaction.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/sigaction.c rename to contrib/ncurses/ncurses/base/sigaction.c diff --git a/contrib/ncurses-5.4/ncurses/base/tries.c b/contrib/ncurses/ncurses/base/tries.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/tries.c rename to contrib/ncurses/ncurses/base/tries.c diff --git a/contrib/ncurses-5.4/ncurses/base/version.c b/contrib/ncurses/ncurses/base/version.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/version.c rename to contrib/ncurses/ncurses/base/version.c diff --git a/contrib/ncurses-5.4/ncurses/base/vsscanf.c b/contrib/ncurses/ncurses/base/vsscanf.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/vsscanf.c rename to contrib/ncurses/ncurses/base/vsscanf.c diff --git a/contrib/ncurses-5.4/ncurses/base/wresize.c b/contrib/ncurses/ncurses/base/wresize.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/base/wresize.c rename to contrib/ncurses/ncurses/base/wresize.c diff --git a/contrib/ncurses-5.4/ncurses/curses.priv.h b/contrib/ncurses/ncurses/curses.priv.h similarity index 100% rename from contrib/ncurses-5.4/ncurses/curses.priv.h rename to contrib/ncurses/ncurses/curses.priv.h diff --git a/contrib/ncurses-5.4/ncurses/fifo_defs.h b/contrib/ncurses/ncurses/fifo_defs.h similarity index 100% rename from contrib/ncurses-5.4/ncurses/fifo_defs.h rename to contrib/ncurses/ncurses/fifo_defs.h diff --git a/contrib/ncurses-5.4/ncurses/llib-lncurses b/contrib/ncurses/ncurses/llib-lncurses similarity index 100% rename from contrib/ncurses-5.4/ncurses/llib-lncurses rename to contrib/ncurses/ncurses/llib-lncurses diff --git a/contrib/ncurses-5.4/ncurses/llib-lncursesw b/contrib/ncurses/ncurses/llib-lncursesw similarity index 100% rename from contrib/ncurses-5.4/ncurses/llib-lncursesw rename to contrib/ncurses/ncurses/llib-lncursesw diff --git a/contrib/ncurses-5.4/ncurses/modules b/contrib/ncurses/ncurses/modules similarity index 100% rename from contrib/ncurses-5.4/ncurses/modules rename to contrib/ncurses/ncurses/modules diff --git a/contrib/ncurses-5.4/ncurses/tinfo/MKcaptab.awk b/contrib/ncurses/ncurses/tinfo/MKcaptab.awk similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/MKcaptab.awk rename to contrib/ncurses/ncurses/tinfo/MKcaptab.awk diff --git a/contrib/ncurses-5.4/ncurses/tinfo/MKfallback.sh b/contrib/ncurses/ncurses/tinfo/MKfallback.sh similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/MKfallback.sh rename to contrib/ncurses/ncurses/tinfo/MKfallback.sh diff --git a/contrib/ncurses-5.4/ncurses/tinfo/MKkeys_list.sh b/contrib/ncurses/ncurses/tinfo/MKkeys_list.sh similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/MKkeys_list.sh rename to contrib/ncurses/ncurses/tinfo/MKkeys_list.sh diff --git a/contrib/ncurses-5.4/ncurses/tinfo/MKnames.awk b/contrib/ncurses/ncurses/tinfo/MKnames.awk similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/MKnames.awk rename to contrib/ncurses/ncurses/tinfo/MKnames.awk diff --git a/contrib/ncurses-5.4/ncurses/tinfo/README b/contrib/ncurses/ncurses/tinfo/README similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/README rename to contrib/ncurses/ncurses/tinfo/README diff --git a/contrib/ncurses-5.4/ncurses/tinfo/access.c b/contrib/ncurses/ncurses/tinfo/access.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/access.c rename to contrib/ncurses/ncurses/tinfo/access.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/add_tries.c b/contrib/ncurses/ncurses/tinfo/add_tries.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/add_tries.c rename to contrib/ncurses/ncurses/tinfo/add_tries.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/alloc_entry.c b/contrib/ncurses/ncurses/tinfo/alloc_entry.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/alloc_entry.c rename to contrib/ncurses/ncurses/tinfo/alloc_entry.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/alloc_ttype.c b/contrib/ncurses/ncurses/tinfo/alloc_ttype.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/alloc_ttype.c rename to contrib/ncurses/ncurses/tinfo/alloc_ttype.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/captoinfo.c b/contrib/ncurses/ncurses/tinfo/captoinfo.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/captoinfo.c rename to contrib/ncurses/ncurses/tinfo/captoinfo.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/comp_error.c b/contrib/ncurses/ncurses/tinfo/comp_error.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/comp_error.c rename to contrib/ncurses/ncurses/tinfo/comp_error.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/comp_expand.c b/contrib/ncurses/ncurses/tinfo/comp_expand.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/comp_expand.c rename to contrib/ncurses/ncurses/tinfo/comp_expand.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/comp_hash.c b/contrib/ncurses/ncurses/tinfo/comp_hash.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/comp_hash.c rename to contrib/ncurses/ncurses/tinfo/comp_hash.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/comp_parse.c b/contrib/ncurses/ncurses/tinfo/comp_parse.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/comp_parse.c rename to contrib/ncurses/ncurses/tinfo/comp_parse.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/comp_scan.c b/contrib/ncurses/ncurses/tinfo/comp_scan.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/comp_scan.c rename to contrib/ncurses/ncurses/tinfo/comp_scan.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/doalloc.c b/contrib/ncurses/ncurses/tinfo/doalloc.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/doalloc.c rename to contrib/ncurses/ncurses/tinfo/doalloc.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/free_ttype.c b/contrib/ncurses/ncurses/tinfo/free_ttype.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/free_ttype.c rename to contrib/ncurses/ncurses/tinfo/free_ttype.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/getenv_num.c b/contrib/ncurses/ncurses/tinfo/getenv_num.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/getenv_num.c rename to contrib/ncurses/ncurses/tinfo/getenv_num.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/home_terminfo.c b/contrib/ncurses/ncurses/tinfo/home_terminfo.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/home_terminfo.c rename to contrib/ncurses/ncurses/tinfo/home_terminfo.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/init_keytry.c b/contrib/ncurses/ncurses/tinfo/init_keytry.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/init_keytry.c rename to contrib/ncurses/ncurses/tinfo/init_keytry.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_acs.c b/contrib/ncurses/ncurses/tinfo/lib_acs.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_acs.c rename to contrib/ncurses/ncurses/tinfo/lib_acs.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_baudrate.c b/contrib/ncurses/ncurses/tinfo/lib_baudrate.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_baudrate.c rename to contrib/ncurses/ncurses/tinfo/lib_baudrate.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_cur_term.c b/contrib/ncurses/ncurses/tinfo/lib_cur_term.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_cur_term.c rename to contrib/ncurses/ncurses/tinfo/lib_cur_term.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_data.c b/contrib/ncurses/ncurses/tinfo/lib_data.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_data.c rename to contrib/ncurses/ncurses/tinfo/lib_data.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_has_cap.c b/contrib/ncurses/ncurses/tinfo/lib_has_cap.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_has_cap.c rename to contrib/ncurses/ncurses/tinfo/lib_has_cap.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_kernel.c b/contrib/ncurses/ncurses/tinfo/lib_kernel.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_kernel.c rename to contrib/ncurses/ncurses/tinfo/lib_kernel.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_longname.c b/contrib/ncurses/ncurses/tinfo/lib_longname.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_longname.c rename to contrib/ncurses/ncurses/tinfo/lib_longname.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_napms.c b/contrib/ncurses/ncurses/tinfo/lib_napms.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_napms.c rename to contrib/ncurses/ncurses/tinfo/lib_napms.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_options.c b/contrib/ncurses/ncurses/tinfo/lib_options.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_options.c rename to contrib/ncurses/ncurses/tinfo/lib_options.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_print.c b/contrib/ncurses/ncurses/tinfo/lib_print.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_print.c rename to contrib/ncurses/ncurses/tinfo/lib_print.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_raw.c b/contrib/ncurses/ncurses/tinfo/lib_raw.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_raw.c rename to contrib/ncurses/ncurses/tinfo/lib_raw.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_setup.c b/contrib/ncurses/ncurses/tinfo/lib_setup.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_setup.c rename to contrib/ncurses/ncurses/tinfo/lib_setup.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_termcap.c b/contrib/ncurses/ncurses/tinfo/lib_termcap.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_termcap.c rename to contrib/ncurses/ncurses/tinfo/lib_termcap.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_termname.c b/contrib/ncurses/ncurses/tinfo/lib_termname.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_termname.c rename to contrib/ncurses/ncurses/tinfo/lib_termname.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_tgoto.c b/contrib/ncurses/ncurses/tinfo/lib_tgoto.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_tgoto.c rename to contrib/ncurses/ncurses/tinfo/lib_tgoto.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_ti.c b/contrib/ncurses/ncurses/tinfo/lib_ti.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_ti.c rename to contrib/ncurses/ncurses/tinfo/lib_ti.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_tparm.c b/contrib/ncurses/ncurses/tinfo/lib_tparm.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_tparm.c rename to contrib/ncurses/ncurses/tinfo/lib_tparm.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_tputs.c b/contrib/ncurses/ncurses/tinfo/lib_tputs.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_tputs.c rename to contrib/ncurses/ncurses/tinfo/lib_tputs.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/lib_ttyflags.c b/contrib/ncurses/ncurses/tinfo/lib_ttyflags.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/lib_ttyflags.c rename to contrib/ncurses/ncurses/tinfo/lib_ttyflags.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/make_keys.c b/contrib/ncurses/ncurses/tinfo/make_keys.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/make_keys.c rename to contrib/ncurses/ncurses/tinfo/make_keys.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/name_match.c b/contrib/ncurses/ncurses/tinfo/name_match.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/name_match.c rename to contrib/ncurses/ncurses/tinfo/name_match.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/parse_entry.c b/contrib/ncurses/ncurses/tinfo/parse_entry.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/parse_entry.c rename to contrib/ncurses/ncurses/tinfo/parse_entry.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/read_entry.c b/contrib/ncurses/ncurses/tinfo/read_entry.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/read_entry.c rename to contrib/ncurses/ncurses/tinfo/read_entry.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/read_termcap.c b/contrib/ncurses/ncurses/tinfo/read_termcap.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/read_termcap.c rename to contrib/ncurses/ncurses/tinfo/read_termcap.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/setbuf.c b/contrib/ncurses/ncurses/tinfo/setbuf.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/setbuf.c rename to contrib/ncurses/ncurses/tinfo/setbuf.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/strings.c b/contrib/ncurses/ncurses/tinfo/strings.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/strings.c rename to contrib/ncurses/ncurses/tinfo/strings.c diff --git a/contrib/ncurses-5.4/ncurses/tinfo/write_entry.c b/contrib/ncurses/ncurses/tinfo/write_entry.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tinfo/write_entry.c rename to contrib/ncurses/ncurses/tinfo/write_entry.c diff --git a/contrib/ncurses-5.4/ncurses/trace/README b/contrib/ncurses/ncurses/trace/README similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/README rename to contrib/ncurses/ncurses/trace/README diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_trace.c b/contrib/ncurses/ncurses/trace/lib_trace.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/lib_trace.c rename to contrib/ncurses/ncurses/trace/lib_trace.c diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_traceatr.c b/contrib/ncurses/ncurses/trace/lib_traceatr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/lib_traceatr.c rename to contrib/ncurses/ncurses/trace/lib_traceatr.c diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_tracebits.c b/contrib/ncurses/ncurses/trace/lib_tracebits.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/lib_tracebits.c rename to contrib/ncurses/ncurses/trace/lib_tracebits.c diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_tracechr.c b/contrib/ncurses/ncurses/trace/lib_tracechr.c similarity index 99% rename from contrib/ncurses-5.4/ncurses/trace/lib_tracechr.c rename to contrib/ncurses/ncurses/trace/lib_tracechr.c index 5ceeed2aa9..05647b8809 100644 --- a/contrib/ncurses-5.4/ncurses/trace/lib_tracechr.c +++ b/contrib/ncurses/ncurses/trace/lib_tracechr.c @@ -45,7 +45,7 @@ NCURSES_EXPORT(char *) _tracechar(int ch) { static char result[40]; - char *name; + const char *name; if (ch > KEY_MIN || ch < 0) { name = keyname(ch); diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_tracedmp.c b/contrib/ncurses/ncurses/trace/lib_tracedmp.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/lib_tracedmp.c rename to contrib/ncurses/ncurses/trace/lib_tracedmp.c diff --git a/contrib/ncurses-5.4/ncurses/trace/lib_tracemse.c b/contrib/ncurses/ncurses/trace/lib_tracemse.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/lib_tracemse.c rename to contrib/ncurses/ncurses/trace/lib_tracemse.c diff --git a/contrib/ncurses-5.4/ncurses/trace/trace_buf.c b/contrib/ncurses/ncurses/trace/trace_buf.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/trace_buf.c rename to contrib/ncurses/ncurses/trace/trace_buf.c diff --git a/contrib/ncurses-5.4/ncurses/trace/trace_tries.c b/contrib/ncurses/ncurses/trace/trace_tries.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/trace_tries.c rename to contrib/ncurses/ncurses/trace/trace_tries.c diff --git a/contrib/ncurses-5.4/ncurses/trace/trace_xnames.c b/contrib/ncurses/ncurses/trace/trace_xnames.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/trace_xnames.c rename to contrib/ncurses/ncurses/trace/trace_xnames.c diff --git a/contrib/ncurses-5.4/ncurses/trace/varargs.c b/contrib/ncurses/ncurses/trace/varargs.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/varargs.c rename to contrib/ncurses/ncurses/trace/varargs.c diff --git a/contrib/ncurses-5.4/ncurses/trace/visbuf.c b/contrib/ncurses/ncurses/trace/visbuf.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/trace/visbuf.c rename to contrib/ncurses/ncurses/trace/visbuf.c diff --git a/contrib/ncurses-5.4/ncurses/tty/MKexpanded.sh b/contrib/ncurses/ncurses/tty/MKexpanded.sh similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/MKexpanded.sh rename to contrib/ncurses/ncurses/tty/MKexpanded.sh diff --git a/contrib/ncurses-5.4/ncurses/tty/hardscroll.c b/contrib/ncurses/ncurses/tty/hardscroll.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/hardscroll.c rename to contrib/ncurses/ncurses/tty/hardscroll.c diff --git a/contrib/ncurses-5.4/ncurses/tty/hashmap.c b/contrib/ncurses/ncurses/tty/hashmap.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/hashmap.c rename to contrib/ncurses/ncurses/tty/hashmap.c diff --git a/contrib/ncurses-5.4/ncurses/tty/lib_mvcur.c b/contrib/ncurses/ncurses/tty/lib_mvcur.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/lib_mvcur.c rename to contrib/ncurses/ncurses/tty/lib_mvcur.c diff --git a/contrib/ncurses-5.4/ncurses/tty/lib_tstp.c b/contrib/ncurses/ncurses/tty/lib_tstp.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/lib_tstp.c rename to contrib/ncurses/ncurses/tty/lib_tstp.c diff --git a/contrib/ncurses-5.4/ncurses/tty/lib_twait.c b/contrib/ncurses/ncurses/tty/lib_twait.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/lib_twait.c rename to contrib/ncurses/ncurses/tty/lib_twait.c diff --git a/contrib/ncurses-5.4/ncurses/tty/lib_vidattr.c b/contrib/ncurses/ncurses/tty/lib_vidattr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/lib_vidattr.c rename to contrib/ncurses/ncurses/tty/lib_vidattr.c diff --git a/contrib/ncurses-5.4/ncurses/tty/tty_display.h b/contrib/ncurses/ncurses/tty/tty_display.h similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/tty_display.h rename to contrib/ncurses/ncurses/tty/tty_display.h diff --git a/contrib/ncurses-5.4/ncurses/tty/tty_input.h b/contrib/ncurses/ncurses/tty/tty_input.h similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/tty_input.h rename to contrib/ncurses/ncurses/tty/tty_input.h diff --git a/contrib/ncurses-5.4/ncurses/tty/tty_update.c b/contrib/ncurses/ncurses/tty/tty_update.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/tty/tty_update.c rename to contrib/ncurses/ncurses/tty/tty_update.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/charable.c b/contrib/ncurses/ncurses/widechar/charable.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/charable.c rename to contrib/ncurses/ncurses/widechar/charable.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_add_wch.c b/contrib/ncurses/ncurses/widechar/lib_add_wch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_add_wch.c rename to contrib/ncurses/ncurses/widechar/lib_add_wch.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_box_set.c b/contrib/ncurses/ncurses/widechar/lib_box_set.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_box_set.c rename to contrib/ncurses/ncurses/widechar/lib_box_set.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_cchar.c b/contrib/ncurses/ncurses/widechar/lib_cchar.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_cchar.c rename to contrib/ncurses/ncurses/widechar/lib_cchar.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_erasewchar.c b/contrib/ncurses/ncurses/widechar/lib_erasewchar.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_erasewchar.c rename to contrib/ncurses/ncurses/widechar/lib_erasewchar.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_get_wch.c b/contrib/ncurses/ncurses/widechar/lib_get_wch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_get_wch.c rename to contrib/ncurses/ncurses/widechar/lib_get_wch.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_get_wstr.c b/contrib/ncurses/ncurses/widechar/lib_get_wstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_get_wstr.c rename to contrib/ncurses/ncurses/widechar/lib_get_wstr.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_hline_set.c b/contrib/ncurses/ncurses/widechar/lib_hline_set.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_hline_set.c rename to contrib/ncurses/ncurses/widechar/lib_hline_set.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_in_wch.c b/contrib/ncurses/ncurses/widechar/lib_in_wch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_in_wch.c rename to contrib/ncurses/ncurses/widechar/lib_in_wch.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_in_wchnstr.c b/contrib/ncurses/ncurses/widechar/lib_in_wchnstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_in_wchnstr.c rename to contrib/ncurses/ncurses/widechar/lib_in_wchnstr.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_ins_wch.c b/contrib/ncurses/ncurses/widechar/lib_ins_wch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_ins_wch.c rename to contrib/ncurses/ncurses/widechar/lib_ins_wch.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_inwstr.c b/contrib/ncurses/ncurses/widechar/lib_inwstr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_inwstr.c rename to contrib/ncurses/ncurses/widechar/lib_inwstr.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_pecho_wchar.c b/contrib/ncurses/ncurses/widechar/lib_pecho_wchar.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_pecho_wchar.c rename to contrib/ncurses/ncurses/widechar/lib_pecho_wchar.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_slk_wset.c b/contrib/ncurses/ncurses/widechar/lib_slk_wset.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_slk_wset.c rename to contrib/ncurses/ncurses/widechar/lib_slk_wset.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_unget_wch.c b/contrib/ncurses/ncurses/widechar/lib_unget_wch.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_unget_wch.c rename to contrib/ncurses/ncurses/widechar/lib_unget_wch.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_vid_attr.c b/contrib/ncurses/ncurses/widechar/lib_vid_attr.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_vid_attr.c rename to contrib/ncurses/ncurses/widechar/lib_vid_attr.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_vline_set.c b/contrib/ncurses/ncurses/widechar/lib_vline_set.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_vline_set.c rename to contrib/ncurses/ncurses/widechar/lib_vline_set.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_wacs.c b/contrib/ncurses/ncurses/widechar/lib_wacs.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_wacs.c rename to contrib/ncurses/ncurses/widechar/lib_wacs.c diff --git a/contrib/ncurses-5.4/ncurses/widechar/lib_wunctrl.c b/contrib/ncurses/ncurses/widechar/lib_wunctrl.c similarity index 100% rename from contrib/ncurses-5.4/ncurses/widechar/lib_wunctrl.c rename to contrib/ncurses/ncurses/widechar/lib_wunctrl.c diff --git a/contrib/ncurses-5.4/panel/Makefile.in b/contrib/ncurses/panel/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/panel/Makefile.in rename to contrib/ncurses/panel/Makefile.in diff --git a/contrib/ncurses-5.4/panel/headers b/contrib/ncurses/panel/headers similarity index 100% rename from contrib/ncurses-5.4/panel/headers rename to contrib/ncurses/panel/headers diff --git a/contrib/ncurses-5.4/panel/llib-lpanel b/contrib/ncurses/panel/llib-lpanel similarity index 100% rename from contrib/ncurses-5.4/panel/llib-lpanel rename to contrib/ncurses/panel/llib-lpanel diff --git a/contrib/ncurses-5.4/panel/llib-lpanelw b/contrib/ncurses/panel/llib-lpanelw similarity index 100% rename from contrib/ncurses-5.4/panel/llib-lpanelw rename to contrib/ncurses/panel/llib-lpanelw diff --git a/contrib/ncurses-5.4/panel/modules b/contrib/ncurses/panel/modules similarity index 100% rename from contrib/ncurses-5.4/panel/modules rename to contrib/ncurses/panel/modules diff --git a/contrib/ncurses-5.4/panel/p_above.c b/contrib/ncurses/panel/p_above.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_above.c rename to contrib/ncurses/panel/p_above.c diff --git a/contrib/ncurses-5.4/panel/p_below.c b/contrib/ncurses/panel/p_below.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_below.c rename to contrib/ncurses/panel/p_below.c diff --git a/contrib/ncurses-5.4/panel/p_bottom.c b/contrib/ncurses/panel/p_bottom.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_bottom.c rename to contrib/ncurses/panel/p_bottom.c diff --git a/contrib/ncurses-5.4/panel/p_delete.c b/contrib/ncurses/panel/p_delete.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_delete.c rename to contrib/ncurses/panel/p_delete.c diff --git a/contrib/ncurses-5.4/panel/p_hidden.c b/contrib/ncurses/panel/p_hidden.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_hidden.c rename to contrib/ncurses/panel/p_hidden.c diff --git a/contrib/ncurses-5.4/panel/p_hide.c b/contrib/ncurses/panel/p_hide.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_hide.c rename to contrib/ncurses/panel/p_hide.c diff --git a/contrib/ncurses-5.4/panel/p_move.c b/contrib/ncurses/panel/p_move.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_move.c rename to contrib/ncurses/panel/p_move.c diff --git a/contrib/ncurses-5.4/panel/p_new.c b/contrib/ncurses/panel/p_new.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_new.c rename to contrib/ncurses/panel/p_new.c diff --git a/contrib/ncurses-5.4/panel/p_replace.c b/contrib/ncurses/panel/p_replace.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_replace.c rename to contrib/ncurses/panel/p_replace.c diff --git a/contrib/ncurses-5.4/panel/p_show.c b/contrib/ncurses/panel/p_show.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_show.c rename to contrib/ncurses/panel/p_show.c diff --git a/contrib/ncurses-5.4/panel/p_top.c b/contrib/ncurses/panel/p_top.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_top.c rename to contrib/ncurses/panel/p_top.c diff --git a/contrib/ncurses-5.4/panel/p_update.c b/contrib/ncurses/panel/p_update.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_update.c rename to contrib/ncurses/panel/p_update.c diff --git a/contrib/ncurses-5.4/panel/p_user.c b/contrib/ncurses/panel/p_user.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_user.c rename to contrib/ncurses/panel/p_user.c diff --git a/contrib/ncurses-5.4/panel/p_win.c b/contrib/ncurses/panel/p_win.c similarity index 100% rename from contrib/ncurses-5.4/panel/p_win.c rename to contrib/ncurses/panel/p_win.c diff --git a/contrib/ncurses-5.4/panel/panel.c b/contrib/ncurses/panel/panel.c similarity index 100% rename from contrib/ncurses-5.4/panel/panel.c rename to contrib/ncurses/panel/panel.c diff --git a/contrib/ncurses-5.4/panel/panel.h b/contrib/ncurses/panel/panel.h similarity index 100% rename from contrib/ncurses-5.4/panel/panel.h rename to contrib/ncurses/panel/panel.h diff --git a/contrib/ncurses-5.4/panel/panel.priv.h b/contrib/ncurses/panel/panel.priv.h similarity index 100% rename from contrib/ncurses-5.4/panel/panel.priv.h rename to contrib/ncurses/panel/panel.priv.h diff --git a/contrib/ncurses-5.4/progs/MKtermsort.sh b/contrib/ncurses/progs/MKtermsort.sh similarity index 100% rename from contrib/ncurses-5.4/progs/MKtermsort.sh rename to contrib/ncurses/progs/MKtermsort.sh diff --git a/contrib/ncurses-5.4/progs/Makefile.in b/contrib/ncurses/progs/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/progs/Makefile.in rename to contrib/ncurses/progs/Makefile.in diff --git a/contrib/ncurses-5.4/progs/capconvert b/contrib/ncurses/progs/capconvert similarity index 100% rename from contrib/ncurses-5.4/progs/capconvert rename to contrib/ncurses/progs/capconvert diff --git a/contrib/ncurses-5.4/progs/clear.c b/contrib/ncurses/progs/clear.c similarity index 100% rename from contrib/ncurses-5.4/progs/clear.c rename to contrib/ncurses/progs/clear.c diff --git a/contrib/ncurses-5.4/progs/clear.sh b/contrib/ncurses/progs/clear.sh similarity index 100% rename from contrib/ncurses-5.4/progs/clear.sh rename to contrib/ncurses/progs/clear.sh diff --git a/contrib/ncurses-5.4/progs/dump_entry.c b/contrib/ncurses/progs/dump_entry.c similarity index 100% rename from contrib/ncurses-5.4/progs/dump_entry.c rename to contrib/ncurses/progs/dump_entry.c diff --git a/contrib/ncurses-5.4/progs/dump_entry.h b/contrib/ncurses/progs/dump_entry.h similarity index 100% rename from contrib/ncurses-5.4/progs/dump_entry.h rename to contrib/ncurses/progs/dump_entry.h diff --git a/contrib/ncurses-5.4/progs/infocmp.c b/contrib/ncurses/progs/infocmp.c similarity index 100% rename from contrib/ncurses-5.4/progs/infocmp.c rename to contrib/ncurses/progs/infocmp.c diff --git a/contrib/ncurses-5.4/progs/modules b/contrib/ncurses/progs/modules similarity index 100% rename from contrib/ncurses-5.4/progs/modules rename to contrib/ncurses/progs/modules diff --git a/contrib/ncurses-5.4/progs/progs.priv.h b/contrib/ncurses/progs/progs.priv.h similarity index 100% rename from contrib/ncurses-5.4/progs/progs.priv.h rename to contrib/ncurses/progs/progs.priv.h diff --git a/contrib/ncurses-5.4/progs/tic.c b/contrib/ncurses/progs/tic.c similarity index 100% rename from contrib/ncurses-5.4/progs/tic.c rename to contrib/ncurses/progs/tic.c diff --git a/contrib/ncurses-5.4/progs/toe.c b/contrib/ncurses/progs/toe.c similarity index 100% rename from contrib/ncurses-5.4/progs/toe.c rename to contrib/ncurses/progs/toe.c diff --git a/contrib/ncurses-5.4/progs/tput.c b/contrib/ncurses/progs/tput.c similarity index 100% rename from contrib/ncurses-5.4/progs/tput.c rename to contrib/ncurses/progs/tput.c diff --git a/contrib/ncurses-5.4/progs/tset.c b/contrib/ncurses/progs/tset.c similarity index 100% rename from contrib/ncurses-5.4/progs/tset.c rename to contrib/ncurses/progs/tset.c diff --git a/contrib/ncurses-5.4/tack/COPYING b/contrib/ncurses/tack/COPYING similarity index 100% rename from contrib/ncurses-5.4/tack/COPYING rename to contrib/ncurses/tack/COPYING diff --git a/contrib/ncurses-5.4/tack/HISTORY b/contrib/ncurses/tack/HISTORY similarity index 100% rename from contrib/ncurses-5.4/tack/HISTORY rename to contrib/ncurses/tack/HISTORY diff --git a/contrib/ncurses-5.4/tack/Makefile.in b/contrib/ncurses/tack/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/tack/Makefile.in rename to contrib/ncurses/tack/Makefile.in diff --git a/contrib/ncurses-5.4/tack/README b/contrib/ncurses/tack/README similarity index 100% rename from contrib/ncurses-5.4/tack/README rename to contrib/ncurses/tack/README diff --git a/contrib/ncurses-5.4/tack/ansi.c b/contrib/ncurses/tack/ansi.c similarity index 100% rename from contrib/ncurses-5.4/tack/ansi.c rename to contrib/ncurses/tack/ansi.c diff --git a/contrib/ncurses-5.4/tack/charset.c b/contrib/ncurses/tack/charset.c similarity index 100% rename from contrib/ncurses-5.4/tack/charset.c rename to contrib/ncurses/tack/charset.c diff --git a/contrib/ncurses-5.4/tack/color.c b/contrib/ncurses/tack/color.c similarity index 100% rename from contrib/ncurses-5.4/tack/color.c rename to contrib/ncurses/tack/color.c diff --git a/contrib/ncurses-5.4/tack/control.c b/contrib/ncurses/tack/control.c similarity index 100% rename from contrib/ncurses-5.4/tack/control.c rename to contrib/ncurses/tack/control.c diff --git a/contrib/ncurses-5.4/tack/crum.c b/contrib/ncurses/tack/crum.c similarity index 100% rename from contrib/ncurses-5.4/tack/crum.c rename to contrib/ncurses/tack/crum.c diff --git a/contrib/ncurses-5.4/tack/edit.c b/contrib/ncurses/tack/edit.c similarity index 100% rename from contrib/ncurses-5.4/tack/edit.c rename to contrib/ncurses/tack/edit.c diff --git a/contrib/ncurses-5.4/tack/fun.c b/contrib/ncurses/tack/fun.c similarity index 100% rename from contrib/ncurses-5.4/tack/fun.c rename to contrib/ncurses/tack/fun.c diff --git a/contrib/ncurses-5.4/tack/init.c b/contrib/ncurses/tack/init.c similarity index 100% rename from contrib/ncurses-5.4/tack/init.c rename to contrib/ncurses/tack/init.c diff --git a/contrib/ncurses-5.4/tack/menu.c b/contrib/ncurses/tack/menu.c similarity index 100% rename from contrib/ncurses-5.4/tack/menu.c rename to contrib/ncurses/tack/menu.c diff --git a/contrib/ncurses-5.4/tack/modes.c b/contrib/ncurses/tack/modes.c similarity index 100% rename from contrib/ncurses-5.4/tack/modes.c rename to contrib/ncurses/tack/modes.c diff --git a/contrib/ncurses-5.4/tack/modules b/contrib/ncurses/tack/modules similarity index 100% rename from contrib/ncurses-5.4/tack/modules rename to contrib/ncurses/tack/modules diff --git a/contrib/ncurses-5.4/tack/output.c b/contrib/ncurses/tack/output.c similarity index 100% rename from contrib/ncurses-5.4/tack/output.c rename to contrib/ncurses/tack/output.c diff --git a/contrib/ncurses-5.4/tack/pad.c b/contrib/ncurses/tack/pad.c similarity index 100% rename from contrib/ncurses-5.4/tack/pad.c rename to contrib/ncurses/tack/pad.c diff --git a/contrib/ncurses-5.4/tack/scan.c b/contrib/ncurses/tack/scan.c similarity index 100% rename from contrib/ncurses-5.4/tack/scan.c rename to contrib/ncurses/tack/scan.c diff --git a/contrib/ncurses-5.4/tack/sync.c b/contrib/ncurses/tack/sync.c similarity index 100% rename from contrib/ncurses-5.4/tack/sync.c rename to contrib/ncurses/tack/sync.c diff --git a/contrib/ncurses-5.4/tack/sysdep.c b/contrib/ncurses/tack/sysdep.c similarity index 100% rename from contrib/ncurses-5.4/tack/sysdep.c rename to contrib/ncurses/tack/sysdep.c diff --git a/contrib/ncurses-5.4/tack/tack.1 b/contrib/ncurses/tack/tack.1 similarity index 100% rename from contrib/ncurses-5.4/tack/tack.1 rename to contrib/ncurses/tack/tack.1 diff --git a/contrib/ncurses-5.4/tack/tack.c b/contrib/ncurses/tack/tack.c similarity index 100% rename from contrib/ncurses-5.4/tack/tack.c rename to contrib/ncurses/tack/tack.c diff --git a/contrib/ncurses-5.4/tack/tack.h b/contrib/ncurses/tack/tack.h similarity index 100% rename from contrib/ncurses-5.4/tack/tack.h rename to contrib/ncurses/tack/tack.h diff --git a/contrib/ncurses-5.4/tar-copy.sh b/contrib/ncurses/tar-copy.sh similarity index 100% rename from contrib/ncurses-5.4/tar-copy.sh rename to contrib/ncurses/tar-copy.sh diff --git a/contrib/ncurses-5.4/test/Makefile.in b/contrib/ncurses/test/Makefile.in similarity index 100% rename from contrib/ncurses-5.4/test/Makefile.in rename to contrib/ncurses/test/Makefile.in diff --git a/contrib/ncurses-5.4/test/README b/contrib/ncurses/test/README similarity index 100% rename from contrib/ncurses-5.4/test/README rename to contrib/ncurses/test/README diff --git a/contrib/ncurses-5.4/test/aclocal.m4 b/contrib/ncurses/test/aclocal.m4 similarity index 100% rename from contrib/ncurses-5.4/test/aclocal.m4 rename to contrib/ncurses/test/aclocal.m4 diff --git a/contrib/ncurses-5.4/test/background.c b/contrib/ncurses/test/background.c similarity index 100% rename from contrib/ncurses-5.4/test/background.c rename to contrib/ncurses/test/background.c diff --git a/contrib/ncurses-5.4/test/blue.c b/contrib/ncurses/test/blue.c similarity index 100% rename from contrib/ncurses-5.4/test/blue.c rename to contrib/ncurses/test/blue.c diff --git a/contrib/ncurses-5.4/test/bs.6 b/contrib/ncurses/test/bs.6 similarity index 100% rename from contrib/ncurses-5.4/test/bs.6 rename to contrib/ncurses/test/bs.6 diff --git a/contrib/ncurses-5.4/test/bs.c b/contrib/ncurses/test/bs.c similarity index 100% rename from contrib/ncurses-5.4/test/bs.c rename to contrib/ncurses/test/bs.c diff --git a/contrib/ncurses-5.4/test/cardfile.c b/contrib/ncurses/test/cardfile.c similarity index 100% rename from contrib/ncurses-5.4/test/cardfile.c rename to contrib/ncurses/test/cardfile.c diff --git a/contrib/ncurses-5.4/test/cardfile.dat b/contrib/ncurses/test/cardfile.dat similarity index 100% rename from contrib/ncurses-5.4/test/cardfile.dat rename to contrib/ncurses/test/cardfile.dat diff --git a/contrib/ncurses-5.4/test/color_set.c b/contrib/ncurses/test/color_set.c similarity index 100% rename from contrib/ncurses-5.4/test/color_set.c rename to contrib/ncurses/test/color_set.c diff --git a/contrib/ncurses-5.4/test/configure b/contrib/ncurses/test/configure similarity index 100% rename from contrib/ncurses-5.4/test/configure rename to contrib/ncurses/test/configure diff --git a/contrib/ncurses-5.4/test/configure.in b/contrib/ncurses/test/configure.in similarity index 100% rename from contrib/ncurses-5.4/test/configure.in rename to contrib/ncurses/test/configure.in diff --git a/contrib/ncurses-5.4/test/demo_defkey.c b/contrib/ncurses/test/demo_defkey.c similarity index 100% rename from contrib/ncurses-5.4/test/demo_defkey.c rename to contrib/ncurses/test/demo_defkey.c diff --git a/contrib/ncurses-5.4/test/demo_forms.c b/contrib/ncurses/test/demo_forms.c similarity index 100% rename from contrib/ncurses-5.4/test/demo_forms.c rename to contrib/ncurses/test/demo_forms.c diff --git a/contrib/ncurses-5.4/test/demo_keyok.c b/contrib/ncurses/test/demo_keyok.c similarity index 100% rename from contrib/ncurses-5.4/test/demo_keyok.c rename to contrib/ncurses/test/demo_keyok.c diff --git a/contrib/ncurses-5.4/test/demo_menus.c b/contrib/ncurses/test/demo_menus.c similarity index 100% rename from contrib/ncurses-5.4/test/demo_menus.c rename to contrib/ncurses/test/demo_menus.c diff --git a/contrib/ncurses-5.4/test/demo_panels.c b/contrib/ncurses/test/demo_panels.c similarity index 100% rename from contrib/ncurses-5.4/test/demo_panels.c rename to contrib/ncurses/test/demo_panels.c diff --git a/contrib/ncurses-5.4/test/ditto.c b/contrib/ncurses/test/ditto.c similarity index 100% rename from contrib/ncurses-5.4/test/ditto.c rename to contrib/ncurses/test/ditto.c diff --git a/contrib/ncurses-5.4/test/dots.c b/contrib/ncurses/test/dots.c similarity index 100% rename from contrib/ncurses-5.4/test/dots.c rename to contrib/ncurses/test/dots.c diff --git a/contrib/ncurses-5.4/test/edit_field.c b/contrib/ncurses/test/edit_field.c similarity index 100% rename from contrib/ncurses-5.4/test/edit_field.c rename to contrib/ncurses/test/edit_field.c diff --git a/contrib/ncurses-5.4/test/edit_field.h b/contrib/ncurses/test/edit_field.h similarity index 100% rename from contrib/ncurses-5.4/test/edit_field.h rename to contrib/ncurses/test/edit_field.h diff --git a/contrib/ncurses-5.4/test/filter.c b/contrib/ncurses/test/filter.c similarity index 100% rename from contrib/ncurses-5.4/test/filter.c rename to contrib/ncurses/test/filter.c diff --git a/contrib/ncurses-5.4/test/firework.c b/contrib/ncurses/test/firework.c similarity index 100% rename from contrib/ncurses-5.4/test/firework.c rename to contrib/ncurses/test/firework.c diff --git a/contrib/ncurses-5.4/test/firstlast.c b/contrib/ncurses/test/firstlast.c similarity index 100% rename from contrib/ncurses-5.4/test/firstlast.c rename to contrib/ncurses/test/firstlast.c diff --git a/contrib/ncurses-5.4/test/gdc.6 b/contrib/ncurses/test/gdc.6 similarity index 100% rename from contrib/ncurses-5.4/test/gdc.6 rename to contrib/ncurses/test/gdc.6 diff --git a/contrib/ncurses-5.4/test/gdc.c b/contrib/ncurses/test/gdc.c similarity index 100% rename from contrib/ncurses-5.4/test/gdc.c rename to contrib/ncurses/test/gdc.c diff --git a/contrib/ncurses-5.4/test/hanoi.c b/contrib/ncurses/test/hanoi.c similarity index 100% rename from contrib/ncurses-5.4/test/hanoi.c rename to contrib/ncurses/test/hanoi.c diff --git a/contrib/ncurses-5.4/test/hashtest.c b/contrib/ncurses/test/hashtest.c similarity index 100% rename from contrib/ncurses-5.4/test/hashtest.c rename to contrib/ncurses/test/hashtest.c diff --git a/contrib/ncurses-5.4/test/ins_wide.c b/contrib/ncurses/test/ins_wide.c similarity index 100% rename from contrib/ncurses-5.4/test/ins_wide.c rename to contrib/ncurses/test/ins_wide.c diff --git a/contrib/ncurses-5.4/test/inserts.c b/contrib/ncurses/test/inserts.c similarity index 100% rename from contrib/ncurses-5.4/test/inserts.c rename to contrib/ncurses/test/inserts.c diff --git a/contrib/ncurses-5.4/test/keynames.c b/contrib/ncurses/test/keynames.c similarity index 100% rename from contrib/ncurses-5.4/test/keynames.c rename to contrib/ncurses/test/keynames.c diff --git a/contrib/ncurses-5.4/test/knight.c b/contrib/ncurses/test/knight.c similarity index 100% rename from contrib/ncurses-5.4/test/knight.c rename to contrib/ncurses/test/knight.c diff --git a/contrib/ncurses-5.4/test/listused.sh b/contrib/ncurses/test/listused.sh similarity index 100% rename from contrib/ncurses-5.4/test/listused.sh rename to contrib/ncurses/test/listused.sh diff --git a/contrib/ncurses-5.4/test/lrtest.c b/contrib/ncurses/test/lrtest.c similarity index 100% rename from contrib/ncurses-5.4/test/lrtest.c rename to contrib/ncurses/test/lrtest.c diff --git a/contrib/ncurses-5.4/test/modules b/contrib/ncurses/test/modules similarity index 100% rename from contrib/ncurses-5.4/test/modules rename to contrib/ncurses/test/modules diff --git a/contrib/ncurses-5.4/test/ncurses.c b/contrib/ncurses/test/ncurses.c similarity index 100% rename from contrib/ncurses-5.4/test/ncurses.c rename to contrib/ncurses/test/ncurses.c diff --git a/contrib/ncurses-5.4/test/ncurses_tst.hin b/contrib/ncurses/test/ncurses_tst.hin similarity index 100% rename from contrib/ncurses-5.4/test/ncurses_tst.hin rename to contrib/ncurses/test/ncurses_tst.hin diff --git a/contrib/ncurses-5.4/test/newdemo.c b/contrib/ncurses/test/newdemo.c similarity index 100% rename from contrib/ncurses-5.4/test/newdemo.c rename to contrib/ncurses/test/newdemo.c diff --git a/contrib/ncurses-5.4/test/railroad.c b/contrib/ncurses/test/railroad.c similarity index 100% rename from contrib/ncurses-5.4/test/railroad.c rename to contrib/ncurses/test/railroad.c diff --git a/contrib/ncurses-5.4/test/rain.c b/contrib/ncurses/test/rain.c similarity index 100% rename from contrib/ncurses-5.4/test/rain.c rename to contrib/ncurses/test/rain.c diff --git a/contrib/ncurses-5.4/test/tclock.c b/contrib/ncurses/test/tclock.c similarity index 100% rename from contrib/ncurses-5.4/test/tclock.c rename to contrib/ncurses/test/tclock.c diff --git a/contrib/ncurses-5.4/test/test.priv.h b/contrib/ncurses/test/test.priv.h similarity index 100% rename from contrib/ncurses-5.4/test/test.priv.h rename to contrib/ncurses/test/test.priv.h diff --git a/contrib/ncurses-5.4/test/testaddch.c b/contrib/ncurses/test/testaddch.c similarity index 100% rename from contrib/ncurses-5.4/test/testaddch.c rename to contrib/ncurses/test/testaddch.c diff --git a/contrib/ncurses-5.4/test/testcurs.c b/contrib/ncurses/test/testcurs.c similarity index 100% rename from contrib/ncurses-5.4/test/testcurs.c rename to contrib/ncurses/test/testcurs.c diff --git a/contrib/ncurses-5.4/test/testscanw.c b/contrib/ncurses/test/testscanw.c similarity index 100% rename from contrib/ncurses-5.4/test/testscanw.c rename to contrib/ncurses/test/testscanw.c diff --git a/contrib/ncurses-5.4/test/tracemunch b/contrib/ncurses/test/tracemunch similarity index 100% rename from contrib/ncurses-5.4/test/tracemunch rename to contrib/ncurses/test/tracemunch diff --git a/contrib/ncurses-5.4/test/view.c b/contrib/ncurses/test/view.c similarity index 100% rename from contrib/ncurses-5.4/test/view.c rename to contrib/ncurses/test/view.c diff --git a/contrib/ncurses-5.4/test/worm.c b/contrib/ncurses/test/worm.c similarity index 100% rename from contrib/ncurses-5.4/test/worm.c rename to contrib/ncurses/test/worm.c diff --git a/contrib/ncurses-5.4/test/xmas.c b/contrib/ncurses/test/xmas.c similarity index 100% rename from contrib/ncurses-5.4/test/xmas.c rename to contrib/ncurses/test/xmas.c