This commit was generated by cvs2svn to compensate for changes in r97049,

which included commits to RCS files with non-trunk default branches.
This commit is contained in:
Peter Wemm 2002-05-21 05:30:25 +00:00
commit 7467abe828
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=97050
277 changed files with 24148 additions and 5935 deletions

View File

@ -1,4 +1,4 @@
-- $Id: INSTALL,v 1.47 2000/11/05 01:57:24 tom Exp $
-- $Id: INSTALL,v 1.52 2002/01/12 22:56:44 tom Exp $
---------------------------------------------------------------------
How to install Ncurses/Terminfo on your system
---------------------------------------------------------------------
@ -277,7 +277,9 @@ SUMMARY OF CONFIGURE OPTIONS:
Use only built-in data. The ncurses libraries normally read terminfo
and termcap data from disk. You can configure ncurses to have a
built-in database, aka "fallback" entries. Embedded applications may
have no need for an external database.
have no need for an external database. Some, but not all of the
programs are useful in this configuration, e.g., reset and tput versus
infocmp and tic.
--disable-ext-funcs
Disable function-extensions. Configure ncurses without the functions
@ -464,6 +466,41 @@ SUMMARY OF CONFIGURE OPTIONS:
--with-ada-objects=DIR
Tell where to install the Ada objects (default: PREFIX/lib/ada/adalib)
--with-bool=TYPE
If --without-cxx is specified, override the type used for the "bool"
declared in curses.h (normally the type is automatically chosen to
correspond with that in <stdbool.h>, or defaults to platform-specific
sizes).
--with-build-cc=XXX
If cross-compiling, specify a host C compiler, which is needed to
compile a few utilties which generate source modules for ncurses.
If you do not give this option, the configure script checks if the
$BUILD_CC variable is set, and otherwise defaults to gcc or cc.
--with-build-cflags=XXX
If cross-compiling, specify the host C compiler-flags. You might need
to do this if the target compiler has unusual flags which confuse the
host compiler.
--with-build-ldflags=XXX
If cross-compiling, specify the host linker-flags. You might need to
do this if the target linker has unusual flags which confuse the host
compiler.
--with-build-libs=XXX
If cross-compiling, the host libraries. You might need to do this if
the target environment requires unusual libraries.
--with-caps=XXX
Specify an alternate terminfo capabilities file, which makes the
configure script look for "include/Caps.XXX". A few systems, e.g.,
AIX 4.x use the same overall file-format as ncurses for terminfo
data, but use different alignments within the tables to support
legacy applications. For those systems, you can configure ncurses
to use a terminfo database which is compatible with the native
applications.
--with-database=XXX
Specify the terminfo source file to install. Usually you will wish
to install ncurses' default (misc/terminfo.src). Certain systems
@ -586,6 +623,10 @@ SUMMARY OF CONFIGURE OPTIONS:
(libtinfo). This is done to accommodate applications that use only
the latter. The terminfo library is about half the size of the total.
--with-termpath=XXX
Specify a search-list of termcap files which will be compiled into the
ncurses library (default: /etc/termcap:/usr/share/misc/termcap)
--without-ada
Suppress the configure script's check for Ada95, do not build the
Ada95 binding and related demo.

View File

@ -312,28 +312,41 @@
./doc/html/index.html
./doc/html/man/captoinfo.1m.html
./doc/html/man/clear.1.html
./doc/html/man/curs_add_wch.3x.html
./doc/html/man/curs_add_wchstr.3x.html
./doc/html/man/curs_addch.3x.html
./doc/html/man/curs_addchstr.3x.html
./doc/html/man/curs_addstr.3x.html
./doc/html/man/curs_addwstr.3x.html
./doc/html/man/curs_attr.3x.html
./doc/html/man/curs_beep.3x.html
./doc/html/man/curs_bkgd.3x.html
./doc/html/man/curs_bkgrnd.3x.html
./doc/html/man/curs_border.3x.html
./doc/html/man/curs_border_set.3x.html
./doc/html/man/curs_clear.3x.html
./doc/html/man/curs_color.3x.html
./doc/html/man/curs_delch.3x.html
./doc/html/man/curs_deleteln.3x.html
./doc/html/man/curs_extend.3x.html
./doc/html/man/curs_get_wch.3x.html
./doc/html/man/curs_get_wstr.3x.html
./doc/html/man/curs_getcchar.3x.html
./doc/html/man/curs_getch.3x.html
./doc/html/man/curs_getstr.3x.html
./doc/html/man/curs_getyx.3x.html
./doc/html/man/curs_in_wch.3x.html
./doc/html/man/curs_in_wchstr.3x.html
./doc/html/man/curs_inch.3x.html
./doc/html/man/curs_inchstr.3x.html
./doc/html/man/curs_initscr.3x.html
./doc/html/man/curs_inopts.3x.html
./doc/html/man/curs_ins_wch.3x.html
./doc/html/man/curs_ins_wstr.3x.html
./doc/html/man/curs_insch.3x.html
./doc/html/man/curs_insstr.3x.html
./doc/html/man/curs_instr.3x.html
./doc/html/man/curs_inwstr.3x.html
./doc/html/man/curs_kernel.3x.html
./doc/html/man/curs_mouse.3x.html
./doc/html/man/curs_move.3x.html
@ -466,13 +479,20 @@
./form/llib-lform
./form/modules
./include/Caps
./include/Caps.aix4
./include/Caps.keys
./include/Caps.osf1r5
./include/Caps.uwin
./include/MKhashsize.sh
./include/MKkey_defs.sh
./include/MKncurses_def.sh
./include/MKparametrized.sh
./include/MKterm.h.awk.in
./include/Makefile.in
./include/capdefaults.c
./include/curses.h.in
./include/curses.tail
./include/curses.wide
./include/edit_cfg.sh
./include/headers
./include/nc_alloc.h
@ -489,28 +509,41 @@
./man/Makefile.in
./man/captoinfo.1m
./man/clear.1
./man/curs_add_wch.3x
./man/curs_add_wchstr.3x
./man/curs_addch.3x
./man/curs_addchstr.3x
./man/curs_addstr.3x
./man/curs_addwstr.3x
./man/curs_attr.3x
./man/curs_beep.3x
./man/curs_bkgd.3x
./man/curs_bkgrnd.3x
./man/curs_border.3x
./man/curs_border_set.3x
./man/curs_clear.3x
./man/curs_color.3x
./man/curs_delch.3x
./man/curs_deleteln.3x
./man/curs_extend.3x
./man/curs_get_wch.3x
./man/curs_get_wstr.3x
./man/curs_getcchar.3x
./man/curs_getch.3x
./man/curs_getstr.3x
./man/curs_getyx.3x
./man/curs_in_wch.3x
./man/curs_in_wchstr.3x
./man/curs_inch.3x
./man/curs_inchstr.3x
./man/curs_initscr.3x
./man/curs_inopts.3x
./man/curs_ins_wch.3x
./man/curs_ins_wstr.3x
./man/curs_insch.3x
./man/curs_insstr.3x
./man/curs_instr.3x
./man/curs_inwstr.3x
./man/curs_kernel.3x
./man/curs_mouse.3x
./man/curs_move.3x
@ -753,9 +786,11 @@
./ncurses/curses.priv.h
./ncurses/fifo_defs.h
./ncurses/llib-lncurses
./ncurses/llib-lncursesw
./ncurses/modules
./ncurses/tinfo/MKcaptab.awk
./ncurses/tinfo/MKfallback.sh
./ncurses/tinfo/MKkeys_list.sh
./ncurses/tinfo/MKnames.awk
./ncurses/tinfo/README
./ncurses/tinfo/access.c
@ -773,7 +808,6 @@
./ncurses/tinfo/getenv_num.c
./ncurses/tinfo/home_terminfo.c
./ncurses/tinfo/init_keytry.c
./ncurses/tinfo/keys.list
./ncurses/tinfo/lib_acs.c
./ncurses/tinfo/lib_baudrate.c
./ncurses/tinfo/lib_cur_term.c
@ -811,6 +845,8 @@
./ncurses/trace/trace_buf.c
./ncurses/trace/trace_tries.c
./ncurses/trace/trace_xnames.c
./ncurses/trace/varargs.c
./ncurses/trace/visbuf.c
./ncurses/tty/MKexpanded.sh
./ncurses/tty/hardscroll.c
./ncurses/tty/hashmap.c
@ -821,6 +857,22 @@
./ncurses/tty/tty_display.h
./ncurses/tty/tty_input.h
./ncurses/tty/tty_update.c
./ncurses/widechar/lib_box_set.c
./ncurses/widechar/lib_cchar.c
./ncurses/widechar/lib_erasewchar.c
./ncurses/widechar/lib_get_wch.c
./ncurses/widechar/lib_get_wstr.c
./ncurses/widechar/lib_hline_set.c
./ncurses/widechar/lib_in_wch.c
./ncurses/widechar/lib_in_wchnstr.c
./ncurses/widechar/lib_ins_nwstr.c
./ncurses/widechar/lib_ins_wch.c
./ncurses/widechar/lib_inwstr.c
./ncurses/widechar/lib_unget_wch.c
./ncurses/widechar/lib_vid_attr.c
./ncurses/widechar/lib_vline_set.c
./ncurses/widechar/lib_wacs.c
./ncurses/widechar/lib_wunctrl.c
./panel/Makefile.in
./panel/headers
./panel/llib-lpanel

View File

@ -219,12 +219,14 @@ libncurses-routines = \
trace/trace_buf \
trace/trace_tries \
trace/trace_xnames \
trace/varargs \
trace/visbuf \
tty/hardscroll \
tty/hashmap \
tty/lib_mvcur \
tty/lib_tstp \
tty/lib_vidattr \
tty/lib_twait \
tty/lib_vidattr \
tty/tty_update \
unctrl

View File

@ -1,4 +1,4 @@
# $Id: Makefile.in,v 1.20 2000/08/19 19:11:56 tom Exp $
# $Id: Makefile.in,v 1.22 2001/10/27 18:17:22 tom Exp $
##############################################################################
# Copyright (c) 1998 Free Software Foundation, Inc. #
# #
@ -69,7 +69,7 @@ preinstall :
@ echo ' lib directory: '$(libdir)
@ echo ' include directory: '$(includedir)
@ echo ' man directory: '$(mandir)
@ echo ' terminfo directory: '$(ticdir)
@MAKE_TERMINFO@ @ echo ' terminfo directory: '$(ticdir)
@ echo ''
@ test "$(includedir)" = "$(prefix)/include" || \
echo '** Include-directory is not in a standard location'
@ -87,6 +87,7 @@ clean \
distclean \
mostlyclean \
realclean \
depend \
sources \
uninstall \
install ::

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
# $Id: Makefile.in,v 1.58 2001/04/21 21:31:08 tom Exp $
# $Id: Makefile.in,v 1.64 2002/01/19 20:25:31 NIIBE.Yutaka Exp $
##############################################################################
# Copyright (c) 1998,1999,2000,2001 Free Software Foundation, Inc. #
# Copyright (c) 1998,1999,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"), #
@ -55,6 +55,9 @@ INSTALL_DATA = @INSTALL_DATA@
AR = @AR@
AR_OPTS = @AR_OPTS@
CXX_AR = @CXX_AR@
CXX_AR_OPTS = @CXX_AR_OPTS@
RANLIB = @RANLIB@
CXX = @CXX@
@ -88,9 +91,9 @@ LIBNAME_LIBTOOL = @LIB_PREFIX@$(LIBROOT)@LIB_SUFFIX@.la
LIBNAME_NORMAL = @LIB_PREFIX@$(LIBROOT)@LIB_SUFFIX@.a
LIBNAME = @LIB_PREFIX@$(LIBROOT)@CXX_LIB_SUFFIX@
LINK_FLAGS = @EXTRA_LDFLAGS@ -L../lib -L$(libdir) -l$(LIBROOT)@LIB_SUFFIX@
LINK_FLAGS = @EXTRA_LDFLAGS@ -L../lib -l$(LIBROOT)@LIB_SUFFIX@
LINK_LIBTOOL = @EXTRA_LDFLAGS@ -L../lib -L$(libdir) ../lib/$(LIBNAME)
LINK_LIBTOOL = @EXTRA_LDFLAGS@ -L../lib ../lib/$(LIBNAME)
LINK_NORMAL = $(LINK_FLAGS)
LINK_DEBUG = $(LINK_FLAGS)
LINK_PROFILE = $(LINK_FLAGS)
@ -117,6 +120,8 @@ all :: demo$x
sources : $(AUTO_SRC)
depend :
# Build a conventional library for installing, since a shared library would
# pull in all of the ncurses libraries (panel, menu, form, ncurses) as direct
# dependencies.
@ -131,7 +136,7 @@ LIB_OBJS = \
$(MODEL)/cursesmain.o
../lib/$(LIBNAME_NORMAL) : $(LIB_OBJS)
$(AR) $(AR_OPTS) $@ $?
$(CXX_AR) $(CXX_AR_OPTS) $@ $?
$(RANLIB) $@
../lib/$(LIBNAME_LIBTOOL) : $(LIB_OBJS)
@ -154,7 +159,7 @@ etip.h: $(srcdir)/etip.h.in $(srcdir)/edit_cfg.sh
sh $(srcdir)/edit_cfg.sh ../include/ncurses_cfg.h $@
$(DESTDIR)$(libdir) :
$(srcdir)/../mkinstalldirs $@
sh $(srcdir)/../mkinstalldirs $@
install \
install.libs:: ../lib/$(LIBNAME) $(DESTDIR)$(libdir)
@ -165,9 +170,10 @@ uninstall.libs::
-$(LIBTOOL) rm -f $(DESTDIR)$(libdir)/$(LIBNAME)
mostlyclean ::
-rm -f core tags TAGS *~ *.i *.ii *.ln *.atac trace
-rm -f core tags TAGS *~ *.bak *.i *.ii *.ln *.atac trace
clean :: mostlyclean
-rm -rf $(MODEL)/SunWS_cache
-$(LIBTOOL) rm -f demo$x $(AUTO_SRC) ../lib/$(LIBNAME) $(LIB_OBJS) $(LIB_OBJS:.o=.lo) $(OBJS_DEMO)
-rm -rf .libs

View File

@ -35,7 +35,7 @@
#include "cursesf.h"
#include "cursesapp.h"
MODULE_ID("$Id: cursesf.cc,v 1.13 2001/03/24 20:03:51 tom Exp $")
MODULE_ID("$Id: cursesf.cc,v 1.14 2001/07/14 20:54:43 juergen Exp $")
NCursesFormField::~NCursesFormField () {
if (field)
@ -267,7 +267,7 @@ NCursesForm::operator()(void) {
show();
refresh();
while (((drvCmnd = virtualize((c=getch()))) != CMD_QUIT)) {
while (((drvCmnd = virtualize((c=getKey()))) != CMD_QUIT)) {
switch((err=driver(drvCmnd))) {
case E_REQUEST_DENIED:
On_Request_Denied(c);

View File

@ -31,7 +31,7 @@
* Author: Juergen Pfeifer <juergen.pfeifer@gmx.net> 1997 *
****************************************************************************/
// $Id: cursesf.h,v 1.15 2001/03/24 21:41:23 tom Exp $
// $Id: cursesf.h,v 1.16 2001/07/15 00:02:53 tom Exp $
#ifndef NCURSES_CURSESF_H_incl
#define NCURSES_CURSESF_H_incl 1
@ -265,7 +265,7 @@ class NCURSES_IMPEXP NCursesFormField {
OnError(::set_field_buffer(field,buffer,val));
}
// Retrieve the value of a fields buffer. The defaukt buffer is nr. 0
// Retrieve the value of a fields buffer. The default buffer is nr. 0
inline char* value(int buffer = 0) const {
return ::field_buffer(field,buffer);
}

View File

@ -35,7 +35,7 @@
#include "cursesm.h"
#include "cursesapp.h"
MODULE_ID("$Id: cursesm.cc,v 1.15 2001/03/24 20:03:56 tom Exp $")
MODULE_ID("$Id: cursesm.cc,v 1.16 2001/07/14 20:54:43 juergen Exp $")
NCursesMenuItem::~NCursesMenuItem() {
if (item)
@ -290,9 +290,9 @@ NCursesMenu::operator()(void) {
post();
show();
refresh();
while (!b_action && ((drvCmnd = virtualize((c=getch()))) != CMD_QUIT)) {
while (!b_action && ((drvCmnd = virtualize((c=getKey()))) != CMD_QUIT)) {
switch((err=driver(drvCmnd))) {
case E_REQUEST_DENIED:
On_Request_Denied(c);

View File

@ -34,7 +34,7 @@
#include "internal.h"
#include "cursesapp.h"
MODULE_ID("$Id: cursesmain.cc,v 1.7 2001/03/24 21:25:47 tom Exp $")
MODULE_ID("$Id: cursesmain.cc,v 1.8 2001/07/14 20:54:43 juergen Exp $")
/* This is the default implementation of main() for a NCursesApplication.
* You only have to instantiate a static NCursesApplication object in your
@ -45,7 +45,13 @@ int main(int argc, char* argv[])
NCursesApplication* A = NCursesApplication::getApplication();
if (!A)
return(1);
A->handleArgs(argc,argv);
::endwin();
return((*A)());
else {
int res;
A->handleArgs(argc,argv);
::endwin();
res = (*A)();
::endwin();
return(res);
}
}

View File

@ -35,7 +35,7 @@
#include "cursesp.h"
#include <string.h>
MODULE_ID("$Id: cursesp.cc,v 1.18 2001/03/24 20:04:04 tom Exp $")
MODULE_ID("$Id: cursesp.cc,v 1.19 2001/07/14 20:54:43 juergen Exp $")
NCursesPanel* NCursesPanel::dummy = (NCursesPanel*)0;
@ -122,3 +122,8 @@ NCursesPanel::centertext(int row,const char *label) {
OnError(addstr(row, x, label, width()));
}
}
int
NCursesPanel::getKey(void) {
return getch();
}

View File

@ -1,6 +1,6 @@
// * This makes emacs happy -*-Mode: C++;-*-
/****************************************************************************
* Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. *
* Copyright (c) 1998,1999,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 *
@ -34,7 +34,7 @@
#ifndef NCURSES_CURSESP_H_incl
#define NCURSES_CURSESP_H_incl 1
// $Id: cursesp.h,v 1.14 2001/03/24 21:41:35 tom Exp $
// $Id: cursesp.h,v 1.15 2001/07/14 20:56:18 juergen Exp $
#include <cursesw.h>
@ -79,6 +79,9 @@ class NCURSES_IMPEXP NCursesPanel : public NCursesWindow {
// If err is equal to the curses error indicator ERR, an error handler
// is called.
// Get a keystroke. Default implementation calls getch()
virtual int getKey(void);
public:
NCursesPanel(int lines,
int cols,

View File

@ -25,7 +25,7 @@
#include "internal.h"
#include "cursesw.h"
MODULE_ID("$Id: cursesw.cc,v 1.21 2001/04/07 22:11:39 tom Exp $")
MODULE_ID("$Id: cursesw.cc,v 1.24 2001/12/08 21:02:33 tom Exp $")
#define COLORS_NEED_INITIALIZATION -1
#define COLORS_NOT_INITIALIZED 0
@ -36,6 +36,14 @@ MODULE_ID("$Id: cursesw.cc,v 1.21 2001/04/07 22:11:39 tom Exp $")
long NCursesWindow::count = 0L;
bool NCursesWindow::b_initialized = FALSE;
/*
* The ncurses library has a fallback for vsscanf(), which may work...
*/
#if !(USE_STRSTREAM_VSCAN || USE_STRSTREAM_VSCAN_CAST)
# undef USE_STDIO_VSCAN
# define USE_STDIO_VSCAN 1
#endif
#if defined(__GNUG__)
# ifndef _IO_va_list
# define _IO_va_list char *
@ -46,23 +54,25 @@ int
NCursesWindow::scanw(const char* fmt, ...)
{
int result = ERR;
#if defined(__GNUG__)
char buf[BUFSIZ];
if (::wgetnstr(w, buf, sizeof(buf)) != ERR) {
va_list args;
va_start(args, fmt);
#if USE_STDIO_VSCAN
if (::vscanf(fmt, args) != -1)
if (::vsscanf(buf, fmt, args) != -1)
result = OK;
#elif USE_STRSTREAM_VSCAN /* pre-gcc 3.0 */
#elif USE_STRSTREAM_VSCAN /* powerpc, os390 */
strstreambuf ss(buf, sizeof(buf));
if (ss.vscan(fmt, args) != -1)
result = OK;
#elif USE_STRSTREAM_VSCAN_CAST /* pre-gcc 3.0 */
strstreambuf ss(buf, sizeof(buf));
if (ss.vscan(fmt, (_IO_va_list)args) != -1)
result = OK;
#endif
va_end(args);
}
#endif
return result;
}
@ -71,7 +81,6 @@ int
NCursesWindow::scanw(int y, int x, const char* fmt, ...)
{
int result = ERR;
#if defined(__GNUG__)
char buf[BUFSIZ];
if (::wmove(w, y, x) != ERR) {
@ -79,9 +88,13 @@ NCursesWindow::scanw(int y, int x, const char* fmt, ...)
va_list args;
va_start(args, fmt);
#if USE_STDIO_VSCAN
if (::vscanf(fmt, args) != -1)
if (::vsscanf(buf, fmt, args) != -1)
result = OK;
#elif USE_STRSTREAM_VSCAN /* pre-gcc 3.0 */
#elif USE_STRSTREAM_VSCAN /* powerpc, os390 */
strstreambuf ss(buf, sizeof(buf));
if (ss.vscan(fmt, args) != -1)
result = OK;
#elif USE_STRSTREAM_VSCAN_CAST /* pre-gcc 3.0 */
strstreambuf ss(buf, sizeof(buf));
if (ss.vscan(fmt, (_IO_va_list)args) != -1)
result = OK;
@ -89,7 +102,6 @@ NCursesWindow::scanw(int y, int x, const char* fmt, ...)
va_end(args);
}
}
#endif
return result;
}

View File

@ -30,13 +30,13 @@
#ifndef NCURSES_CURSESW_H_incl
#define NCURSES_CURSESW_H_incl 1
// $Id: cursesw.h,v 1.25 2001/04/07 22:44:07 tom Exp $
// $Id: cursesw.h,v 1.28 2001/07/15 01:17:56 tom Exp $
#include <etip.h>
#include <stdio.h>
#include <stdarg.h>
#if HAVE_STRSTREAM_H && USE_STRSTREAM_VSCAN
#if HAVE_STRSTREAM_H && (USE_STRSTREAM_VSCAN||USE_STRSTREAM_VSCAN_CAST)
#include <strstream.h>
#endif
@ -752,7 +752,7 @@ class NCURSES_IMPEXP NCursesWindow
int cols, // number of columns
int begin_y, // absolute or relative
int begin_x, // origins:
char absrel = 'a');// if `a', by & bx are
char absrel = 'a');// if `a', begin_y & begin_x are
// absolute screen pos, else if `r', they are relative to par origin
NCursesWindow(NCursesWindow& par,// parent window
@ -778,7 +778,7 @@ class NCURSES_IMPEXP NCursesWindow
// lowlevel ripoffline() function because it uses the internal
// implementation that allows to remove more than just a single line.
// This function must be called before any other ncurses function. The
// creation of the window is defered until ncurses gets initialized.
// creation of the window is deferred until ncurses gets initialized.
// The initialization function is then called.
// -------------------------------------------------------------------------
@ -796,7 +796,7 @@ class NCURSES_IMPEXP NCursesWindow
static int NumberOfColors();
// Number of available colors
int colors() const { return NumberOfColors(); }
int colors() const { return NumberOfColors(); }
// Number of available colors
// -------------------------------------------------------------------------
@ -820,25 +820,25 @@ class NCURSES_IMPEXP NCursesWindow
int maxy() const { return w->_maxy; }
// Largest y coord in window
short getcolor() const;
short getcolor() const;
// Actual color pair
short foreground() const { return getcolor(0); }
short foreground() const { return getcolor(0); }
// Actual foreground color
short background() const { return getcolor(1); }
short background() const { return getcolor(1); }
// Actual background color
int setpalette(short fore, short back);
int setpalette(short fore, short back);
// Set color palette entry
int setcolor(short pair);
int setcolor(short pair);
// Set actually used palette entry
// -------------------------------------------------------------------------
// window positioning
// -------------------------------------------------------------------------
virtual int mvwin(int begin_y, int begin_x) {
virtual int mvwin(int begin_y, int begin_x) {
return ::mvwin(w,begin_y,begin_x); }
// Move window to new position with the new position as top left corner.
// This is virtual because it is redefined in NCursesPanel.
@ -887,8 +887,7 @@ class NCURSES_IMPEXP NCursesWindow
// as described above.
int scanw(const char* fmt, ...)
// Perform a scanw function from the window. This only works if you're
// using the GNU C++ compiler.
// Perform a scanw function from the window.
#if __GNUG__ >= 2
__attribute__ ((format (scanf, 2, 3)));
#else
@ -897,7 +896,7 @@ class NCURSES_IMPEXP NCursesWindow
int scanw(int y, int x, const char* fmt, ...)
// Move the cursor to the requested position and then perform a scanw
// from the window. This nly works if you're using the GNU C++ compiler.
// from the window.
#if __GNUG__ >= 2
__attribute__ ((format (scanf, 4, 5)));
#else
@ -930,7 +929,7 @@ class NCURSES_IMPEXP NCursesWindow
int printw(const char* fmt, ...)
// Do a formatted print to the window.
#if __GNUG__ >= 2
#if (__GNUG__ >= 2) && !defined(printf)
__attribute__ ((format (printf, 2, 3)));
#else
;
@ -938,7 +937,7 @@ class NCURSES_IMPEXP NCursesWindow
int printw(int y, int x, const char * fmt, ...)
// Move the cursor and then do a formatted print to the window.
#if __GNUG__ >= 2
#if (__GNUG__ >= 2) && !defined(printf)
__attribute__ ((format (printf, 4, 5)));
#else
;
@ -1021,7 +1020,7 @@ class NCURSES_IMPEXP NCursesWindow
int box(chtype vert=0, chtype hor=0) {
return ::wborder(w, vert, vert, hor, hor, 0, 0 ,0, 0); }
// Draw a box around the window with the given vertical and horizontal
// drawing characters. If you specifiy a zero as character, curses will try
// drawing characters. If you specify a zero as character, curses will try
// to find a "nice" character.
int border(chtype left=0, chtype right=0,

View File

@ -6,7 +6,7 @@
* Demo code for NCursesMenu and NCursesForm written by
* Juergen Pfeifer <juergen.pfeifer@gmx.net>
*
* $Id: demo.cc,v 1.20 2001/01/28 02:26:27 tom Exp $
* $Id: demo.cc,v 1.21 2001/07/15 01:15:26 tom Exp $
*/
#include "cursesapp.h"
@ -19,7 +19,7 @@
extern "C" unsigned int sleep(unsigned int);
#undef index // needed for NeXT
#undef index // needed for NeXT
//
// -------------------------------------------------------------------------
@ -140,7 +140,7 @@ template<class T> class MyAction : public NCursesUserItem<T>
{
public:
MyAction (const char* p_name,
const T* p_UserData)
const T* p_UserData)
: NCursesUserItem<T>(p_name, (const char*)0, p_UserData)
{};
@ -170,7 +170,7 @@ class Label : public NCursesFormField
{
public:
Label(const char* title,
int row, int col)
int row, int col)
: NCursesFormField(1,(int)::strlen(title),row,col) {
set_value(title);
options_off(O_EDIT|O_ACTIVE);
@ -293,18 +293,18 @@ public:
for (int i=0; i < PADSIZE; i++) {
for (int j=0; j < PADSIZE; j++) {
if (i % GRIDSIZE == 0 && j % GRIDSIZE == 0) {
if (i==0 || j==0)
FP.addch('+');
else
FP.addch((chtype)('A' + (gridcount++ % 26)));
}
else if (i % GRIDSIZE == 0)
FP.addch('-');
else if (j % GRIDSIZE == 0)
FP.addch('|');
else
FP.addch(' ');
if (i % GRIDSIZE == 0 && j % GRIDSIZE == 0) {
if (i==0 || j==0)
FP.addch('+');
else
FP.addch((chtype)('A' + (gridcount++ % 26)));
}
else if (i % GRIDSIZE == 0)
FP.addch('-');
else if (j % GRIDSIZE == 0)
FP.addch('|');
else
FP.addch(' ');
}
}
@ -324,6 +324,49 @@ public:
options_off(O_SELECTABLE);
}
};
//
// -------------------------------------------------------------------------
//
class ScanAction : public NCursesMenuItem
{
public:
ScanAction(const char* s) : NCursesMenuItem(s) {
}
bool action() {
NCursesPanel *std = new NCursesPanel();
NCursesPanel *w = new NCursesPanel(std->lines() - 2, std->cols() - 2, 1, 1);
w->box();
w->refresh();
NCursesPanel *s = new NCursesPanel(w->lines() - 6, w->cols() - 6, 3, 3);
s->scrollok(TRUE);
::echo();
s->printw("Enter decimal integers. The running total will be shown\n");
int value = -1;
int result = 0;
while (value != 0) {
value = 0;
s->scanw("%d", &value);
if (value != 0) {
s->printw("%d: ", result += value);
}
s->refresh();
}
s->printw("\nPress any key to continue...");
s->getch();
delete s;
delete w;
delete std;
::noecho();
return FALSE;
}
};
//
// -------------------------------------------------------------------------
//
@ -346,7 +389,7 @@ public:
I[2] = new MyAction<UserData> ("Silly", u);
I[3] = new FormAction("Form");
I[4] = new PadAction("Pad");
I[5] = new PassiveItem("Six");
I[5] = new ScanAction("Scan");
I[6] = new QuitItem();
I[7] = new NCursesMenuItem(); // Terminating empty item

View File

@ -1,7 +1,7 @@
#!/bin/sh
# $Id: edit_cfg.sh,v 1.10 2001/04/07 22:45:11 tom Exp $
# $Id: edit_cfg.sh,v 1.12 2001/12/08 20:44:59 tom Exp $
##############################################################################
# Copyright (c) 1998,2000 Free Software Foundation, Inc. #
# 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"), #
@ -47,8 +47,8 @@ for name in \
HAVE_STRSTREAM_H \
HAVE_TYPEINFO \
HAVE_VALUES_H \
USE_STDIO_VSCAN \
USE_STRSTREAM_VSCAN
USE_STRSTREAM_VSCAN \
USE_STRSTREAM_VSCAN_CAST
do
mv $2 $2.bak
if ( grep "[ ]$name[ ]1" $1 2>&1 >/dev/null)

View File

@ -1,6 +1,6 @@
// * This makes emacs happy -*-Mode: C++;-*-
/****************************************************************************
* Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. *
* Copyright (c) 1998,1999,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 *
@ -31,7 +31,7 @@
* Author: Juergen Pfeifer <juergen.pfeifer@gmx.net> 1997 *
****************************************************************************/
// $Id: etip.h.in,v 1.18 2001/04/07 22:45:04 tom Exp $
// $Id: etip.h.in,v 1.22 2001/12/08 21:26:49 tom Exp $
#ifndef NCURSES_ETIP_H_incl
#define NCURSES_ETIP_H_incl 1
@ -73,14 +73,14 @@
#define CPP_HAS_PARAM_INIT 0
#endif
#ifndef USE_STDIO_VSCAN
#define USE_STDIO_VSCAN 0
#endif
#ifndef USE_STRSTREAM_VSCAN
#define USE_STRSTREAM_VSCAN 0
#endif
#ifndef USE_STRSTREAM_VSCAN_CAST
#define USE_STRSTREAM_VSCAN_CAST 0
#endif
#ifdef __GNUG__
# if ((__GNUG__ <= 2) && (__GNUC_MINOR__ < 8))
# if HAVE_TYPEINFO
@ -274,7 +274,11 @@ inline void THROW(const NCursesException *e) {
throw *e;
#endif
#elif defined(__SUNPRO_CC)
# if !defined(__SUNPRO_CC_COMPAT) || (__SUNPRO_CC_COMPAT < 5)
genericerror(1, ((e != 0) ? (char *)(e->message) : ""));
#else
throw *e;
#endif
#else
if (e)
cerr << e->message << endl;

View File

@ -1,9 +1,9 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
# Free Software Foundation, Inc.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
# 2000, 2001, 2002 Free Software Foundation, Inc.
timestamp='2001-03-16'
timestamp='2002-03-20'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@ -24,8 +24,9 @@ timestamp='2001-03-16'
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Written by Per Bothner <bothner@cygnus.com>.
# Please send patches to <config-patches@gnu.org>.
# Originally written by Per Bothner <per@bothner.com>.
# Please send patches to <config-patches@gnu.org>. Submit a context
# diff and a properly formatted ChangeLog entry.
#
# This script attempts to guess a canonical system name similar to
# config.sub. If it succeeds, it prints the system name on stdout, and
@ -52,7 +53,7 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
Copyright (C) 1992, 93, 94, 95, 96, 97, 98, 99, 2000
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@ -95,25 +96,25 @@ trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15
# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
# use `HOST_CC' if defined, but it is deprecated.
case $CC_FOR_BUILD,$HOST_CC,$CC in
,,) echo "int dummy(){}" > $dummy.c
for c in cc gcc c89 ; do
($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1
set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in
,,) echo "int dummy(){}" > $dummy.c ;
for c in cc gcc c89 c99 ; do
($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ;
if test $? = 0 ; then
CC_FOR_BUILD="$c"; break
fi
done
rm -f $dummy.c $dummy.o $dummy.rel
CC_FOR_BUILD="$c"; break ;
fi ;
done ;
rm -f $dummy.c $dummy.o $dummy.rel ;
if test x"$CC_FOR_BUILD" = x ; then
CC_FOR_BUILD=no_compiler_found
CC_FOR_BUILD=no_compiler_found ;
fi
;;
,,*) CC_FOR_BUILD=$CC ;;
,*,*) CC_FOR_BUILD=$HOST_CC ;;
esac
esac'
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi@noc.rutgers.edu 8/24/94.)
# (ghazi@noc.rutgers.edu 1994-08-24)
if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
PATH=$PATH:/.attbin ; export PATH
fi
@ -127,29 +128,30 @@ UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
*:NetBSD:*:*)
# Netbsd (nbsd) targets should (where applicable) match one or
# NetBSD (nbsd) targets should (where applicable) match one or
# more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
# switched to ELF, *-*-netbsd* would select the old
# object file format. This provides both forward
# compatibility and a consistent mechanism for selecting the
# object file format.
# Determine the machine/vendor (is the vendor relevant).
case "${UNAME_MACHINE}" in
amiga) machine=m68k-unknown ;;
arm32) machine=arm-unknown ;;
atari*) machine=m68k-atari ;;
sun3*) machine=m68k-sun ;;
mac68k) machine=m68k-apple ;;
macppc) machine=powerpc-apple ;;
hp3[0-9][05]) machine=m68k-hp ;;
ibmrt|romp-ibm) machine=romp-ibm ;;
*) machine=${UNAME_MACHINE}-unknown ;;
#
# Note: NetBSD doesn't particularly care about the vendor
# portion of the name. We always set it to "unknown".
sysctl="sysctl -n hw.machine_arch"
UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
/usr/sbin/$sysctl 2>/dev/null || echo unknown)`
case "${UNAME_MACHINE_ARCH}" in
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
sh3eb) machine=sh-unknown ;;
*) machine=${UNAME_MACHINE_ARCH}-unknown ;;
esac
# The Operating System including object format, if it has switched
# to ELF recently, or will in the future.
case "${UNAME_MACHINE}" in
i386|sparc|amiga|arm*|hp300|mvme68k|vax|atari|luna68k|mac68k|news68k|next68k|pc532|sun3*|x68k)
case "${UNAME_MACHINE_ARCH}" in
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
eval $set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep __ELF__ >/dev/null
then
@ -171,6 +173,45 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
exit 0 ;;
amiga:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
arc:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
hp300:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mac68k:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
macppc:OpenBSD:*:*)
echo powerpc-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mvme68k:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mvme88k:OpenBSD:*:*)
echo m88k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mvmeppc:OpenBSD:*:*)
echo powerpc-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
pmax:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
sgi:OpenBSD:*:*)
echo mipseb-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
sun3:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
wgrisc:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
*:OpenBSD:*:*)
echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
alpha:OSF1:*:*)
if test $UNAME_RELEASE = "V4.0"; then
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
@ -204,6 +245,7 @@ main:
jsr \$26,exit
.end main
EOF
eval $set_cc_for_build
$CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
if test "$?" = 0 ; then
case `./$dummy` in
@ -225,6 +267,9 @@ EOF
2-307)
UNAME_MACHINE="alphaev67"
;;
2-1307)
UNAME_MACHINE="alphaev68"
;;
esac
fi
rm -f $dummy.s $dummy
@ -242,29 +287,11 @@ EOF
Amiga*:UNIX_System_V:4.0:*)
echo m68k-unknown-sysv4
exit 0;;
amiga:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
*:[Aa]miga[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-amigaos
exit 0 ;;
arc64:OpenBSD:*:*)
echo mips64el-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
arc:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
hkmips:OpenBSD:*:*)
echo mips-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
pmax:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
sgi:OpenBSD:*:*)
echo mips-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
wgrisc:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
*:[Mm]orph[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-morphos
exit 0 ;;
*:OS/390:*:*)
echo i370-ibm-openedition
@ -314,7 +341,7 @@ EOF
echo m68k-sun-sunos${UNAME_RELEASE}
exit 0 ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(head -1 /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
case "`/bin/arch`" in
sun3)
@ -328,9 +355,6 @@ EOF
aushp:SunOS:*:*)
echo sparc-auspex-sunos${UNAME_RELEASE}
exit 0 ;;
atari*:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
# The situation for MiNT is a little confusing. The machine name
# can be virtually everything (everything which is not
# "atarist" or "atariste" at least should have a processor
@ -357,18 +381,6 @@ EOF
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
echo m68k-unknown-mint${UNAME_RELEASE}
exit 0 ;;
sun3*:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mac68k:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mvme68k:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
mvme88k:OpenBSD:*:*)
echo m88k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
powerpc:machten:*:*)
echo powerpc-apple-machten${UNAME_RELEASE}
exit 0 ;;
@ -385,6 +397,7 @@ EOF
echo clipper-intergraph-clix${UNAME_RELEASE}
exit 0 ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#ifdef __cplusplus
#include <stdio.h> /* for printf() prototype */
@ -412,6 +425,9 @@ EOF
rm -f $dummy.c $dummy
echo mips-mips-riscos${UNAME_RELEASE}
exit 0 ;;
Motorola:PowerMAX_OS:*:*)
echo powerpc-motorola-powermax
exit 0 ;;
Night_Hawk:Power_UNIX:*:*)
echo powerpc-harris-powerunix
exit 0 ;;
@ -459,7 +475,7 @@ EOF
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX '
i?86:AIX:*:*)
i*86:AIX:*:*)
echo i386-ibm-aix
exit 0 ;;
ia64:AIX:*:*)
@ -472,6 +488,7 @@ EOF
exit 0 ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#include <sys/systemcfg.h>
@ -493,7 +510,7 @@ EOF
fi
exit 0 ;;
*:AIX:*:[45])
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | head -1 | awk '{ print $1 }'`
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
IBM_ARCH=rs6000
else
@ -533,10 +550,8 @@ EOF
9000/31? ) HP_ARCH=m68000 ;;
9000/[34]?? ) HP_ARCH=m68k ;;
9000/[678][0-9][0-9])
case "${HPUX_REV}" in
11.[0-9][0-9])
if [ -x /usr/bin/getconf ]; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
if [ -x /usr/bin/getconf ]; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
case "${sc_cpu_version}" in
523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
@ -545,12 +560,13 @@ EOF
case "${sc_kernel_bits}" in
32) HP_ARCH="hppa2.0n" ;;
64) HP_ARCH="hppa2.0w" ;;
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
esac ;;
esac
fi ;;
esac
if [ "${HP_ARCH}" = "" ]; then
sed 's/^ //' << EOF >$dummy.c
fi
if [ "${HP_ARCH}" = "" ]; then
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#define _HPUX_SOURCE
#include <stdlib.h>
@ -583,10 +599,10 @@ EOF
exit (0);
}
EOF
(CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null ) && HP_ARCH=`./$dummy`
if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi
rm -f $dummy.c $dummy
fi ;;
(CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`./$dummy`
if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi
rm -f $dummy.c $dummy
fi ;;
esac
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
exit 0 ;;
@ -595,6 +611,7 @@ EOF
echo ia64-hp-hpux${HPUX_REV}
exit 0 ;;
3050*:HI-UX:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#include <unistd.h>
int
@ -630,7 +647,7 @@ EOF
9000/8??:4.3bsd:*:*)
echo hppa1.0-hp-bsd
exit 0 ;;
*9??*:MPE/iX:*:*)
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
echo hppa1.0-hp-mpeix
exit 0 ;;
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
@ -639,7 +656,7 @@ EOF
hp8??:OSF1:*:*)
echo hppa1.0-hp-osf
exit 0 ;;
i?86:OSF1:*:*)
i*86:OSF1:*:*)
if [ -x /usr/sbin/sysversion ] ; then
echo ${UNAME_MACHINE}-unknown-osf1mk
else
@ -649,9 +666,6 @@ EOF
parisc*:Lites*:*:*)
echo hppa1.1-hp-lites
exit 0 ;;
hppa*:OpenBSD:*:*)
echo hppa-unknown-openbsd
exit 0 ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
exit 0 ;;
@ -670,16 +684,14 @@ EOF
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
echo c4-convex-bsd
exit 0 ;;
CRAY*X-MP:*:*:*)
echo xmp-cray-unicos
exit 0 ;;
CRAY*Y-MP:*:*:*)
echo ymp-cray-unicos${UNAME_RELEASE}
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit 0 ;;
CRAY*[A-Z]90:*:*:*)
echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
-e 's/\.[^.]*$/.X/'
exit 0 ;;
CRAY*TS:*:*:*)
echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
@ -693,19 +705,13 @@ EOF
CRAY*SV1:*:*:*)
echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit 0 ;;
CRAY-2:*:*:*)
echo cray2-cray-unicos
exit 0 ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit 0 ;;
hp300:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
i?86:BSD/386:*:* | i?86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
exit 0 ;;
sparc*:BSD/OS:*:*)
@ -717,9 +723,6 @@ EOF
*:FreeBSD:*:*)
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
exit 0 ;;
*:OpenBSD:*:*)
echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
exit 0 ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
exit 0 ;;
@ -729,6 +732,9 @@ EOF
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
exit 0 ;;
x86:Interix*:3*)
echo i386-pc-interix3
exit 0 ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
@ -754,103 +760,49 @@ EOF
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
m68*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
mips:Linux:*:*)
cat >$dummy.c <<EOF
#ifdef __cplusplus
#include <stdio.h> /* for printf() prototype */
int main (int argc, char *argv[]) {
#else
int main (argc, argv) int argc; char *argv[]; {
#endif
#ifdef __MIPSEB__
printf ("%s-unknown-linux-gnu\n", argv[1]);
#endif
#ifdef __MIPSEL__
printf ("%sel-unknown-linux-gnu\n", argv[1]);
#endif
return 0;
}
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#undef CPU
#undef mips
#undef mipsel
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
CPU=mipsel
#else
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
CPU=mips
#else
CPU=
#endif
#endif
EOF
$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm -f $dummy.c $dummy && exit 0
rm -f $dummy.c $dummy
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
rm -f $dummy.c
test x"${CPU}" != x && echo "${CPU}-pc-linux-gnu" && exit 0
;;
ppc:Linux:*:*)
# Determine Lib Version
cat >$dummy.c <<EOF
#include <features.h>
#if defined(__GLIBC__)
extern char __libc_version[];
extern char __libc_release[];
#endif
main(argc, argv)
int argc;
char *argv[];
{
#if defined(__GLIBC__)
printf("%s %s\n", __libc_version, __libc_release);
#else
printf("unknown\n");
#endif
return 0;
}
EOF
LIBC=""
$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null
if test "$?" = 0 ; then
./$dummy | grep 1\.99 > /dev/null
if test "$?" = 0 ; then LIBC="libc1" ; fi
fi
rm -f $dummy.c $dummy
echo powerpc-unknown-linux-gnu${LIBC}
echo powerpc-unknown-linux-gnu
exit 0 ;;
ppc64:Linux:*:*)
echo powerpc64-unknown-linux-gnu
exit 0 ;;
alpha:Linux:*:*)
cat <<EOF >$dummy.s
.data
\$Lformat:
.byte 37,100,45,37,120,10,0 # "%d-%x\n"
.text
.globl main
.align 4
.ent main
main:
.frame \$30,16,\$26,0
ldgp \$29,0(\$27)
.prologue 1
.long 0x47e03d80 # implver \$0
lda \$2,-1
.long 0x47e20c21 # amask \$2,\$1
lda \$16,\$Lformat
mov \$0,\$17
not \$1,\$18
jsr \$26,printf
ldgp \$29,0(\$26)
mov 0,\$16
jsr \$26,exit
.end main
EOF
LIBC=""
$CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
if test "$?" = 0 ; then
case `./$dummy` in
0-0) UNAME_MACHINE="alpha" ;;
1-0) UNAME_MACHINE="alphaev5" ;;
1-1) UNAME_MACHINE="alphaev56" ;;
1-101) UNAME_MACHINE="alphapca56" ;;
2-303) UNAME_MACHINE="alphaev6" ;;
2-307) UNAME_MACHINE="alphaev67" ;;
esac
objdump --private-headers $dummy | \
grep ld.so.1 > /dev/null
if test "$?" = 0 ; then
LIBC="libc1"
fi
fi
rm -f $dummy.s $dummy
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
EV5) UNAME_MACHINE=alphaev5 ;;
EV56) UNAME_MACHINE=alphaev56 ;;
PCA56) UNAME_MACHINE=alphapca56 ;;
PCA57) UNAME_MACHINE=alphapca56 ;;
EV6) UNAME_MACHINE=alphaev6 ;;
EV67) UNAME_MACHINE=alphaev67 ;;
EV68*) UNAME_MACHINE=alphaev68 ;;
esac
objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
exit 0 ;;
parisc:Linux:*:* | hppa:Linux:*:*)
@ -876,78 +828,67 @@ EOF
x86_64:Linux:*:*)
echo x86_64-unknown-linux-gnu
exit 0 ;;
i?86:Linux:*:*)
i*86:Linux:*:*)
# The BFD linker knows what the default object file format is, so
# first see if it will tell us. cd to the root directory to prevent
# problems with other programs or directories called `ld' in the path.
ld_supported_emulations=`cd /; ld --help 2>&1 \
| sed -ne '/supported emulations:/!d
# Set LC_ALL=C to ensure ld outputs messages in English.
ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
| sed -ne '/supported targets:/!d
s/[ ][ ]*/ /g
s/.*supported emulations: *//
s/.*supported targets: *//
s/ .*//
p'`
case "$ld_supported_emulations" in
i?86linux)
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
exit 0
;;
elf_i?86)
case "$ld_supported_targets" in
elf32-i386)
TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
;;
i?86coff)
a.out-i386-linux)
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
exit 0 ;;
coff-i386)
echo "${UNAME_MACHINE}-pc-linux-gnucoff"
exit 0
;;
esac
# Either a pre-BFD a.out linker (linux-gnuoldld)
# or one that does not give us useful --help.
# GCC wants to distinguish between linux-gnuoldld and linux-gnuaout.
# If ld does not provide *any* "supported emulations:"
# that means it is gnuoldld.
test -z "$ld_supported_emulations" && echo "${UNAME_MACHINE}-pc-linux-gnuoldld" && exit 0
case "${UNAME_MACHINE}" in
i?86)
VENDOR=pc;
;;
*)
VENDOR=unknown;
;;
exit 0 ;;
"")
# Either a pre-BFD a.out linker (linux-gnuoldld) or
# one that does not give us useful --help.
echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
exit 0 ;;
esac
# Determine whether the default compiler is a.out or elf
cat >$dummy.c <<EOF
#include <features.h>
#ifdef __cplusplus
#include <stdio.h> /* for printf() prototype */
int main (int argc, char *argv[]) {
#else
int main (argc, argv) int argc; char *argv[]; {
#endif
#ifdef __ELF__
# ifdef __GLIBC__
# if __GLIBC__ >= 2
printf ("%s-${VENDOR}-linux-gnu\n", argv[1]);
# else
printf ("%s-${VENDOR}-linux-gnulibc1\n", argv[1]);
# endif
# else
printf ("%s-${VENDOR}-linux-gnulibc1\n", argv[1]);
# endif
#else
printf ("%s-${VENDOR}-linux-gnuaout\n", argv[1]);
#endif
return 0;
}
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#include <features.h>
#ifdef __ELF__
# ifdef __GLIBC__
# if __GLIBC__ >= 2
LIBC=gnu
# else
LIBC=gnulibc1
# endif
# else
LIBC=gnulibc1
# endif
#else
#ifdef __INTEL_COMPILER
LIBC=gnu
#else
LIBC=gnuaout
#endif
#endif
EOF
$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm -f $dummy.c $dummy && exit 0
rm -f $dummy.c $dummy
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
rm -f $dummy.c
test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
;;
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. earlier versions
# are messed up and put the nodename in both sysname and nodename.
i?86:DYNIX/ptx:4*:*)
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
# sysname and nodename.
echo i386-sequent-sysv4
exit 0 ;;
i?86:UNIX_SV:4.2MP:2.*)
i*86:UNIX_SV:4.2MP:2.*)
# Unixware is an offshoot of SVR4, but it has its own version
# number series starting with 2...
# I am not positive that other SVR4 systems won't match this,
@ -955,7 +896,7 @@ EOF
# Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
exit 0 ;;
i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*)
i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
@ -963,16 +904,15 @@ EOF
echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
fi
exit 0 ;;
i?86:*:5:7*)
# Fixed at (any) Pentium or better
UNAME_MACHINE=i586
if [ ${UNAME_SYSTEM} = "UnixWare" ] ; then
echo ${UNAME_MACHINE}-sco-sysv${UNAME_RELEASE}uw${UNAME_VERSION}
else
echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE}
fi
i*86:*:5:[78]*)
case `/bin/uname -X | grep "^Machine"` in
*486*) UNAME_MACHINE=i486 ;;
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
exit 0 ;;
i?86:*:3.2:*)
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
@ -990,7 +930,7 @@ EOF
echo ${UNAME_MACHINE}-pc-sysv32
fi
exit 0 ;;
i?86:*DOS:*:*)
i*86:*DOS:*:*)
echo ${UNAME_MACHINE}-pc-msdosdjgpp
exit 0 ;;
pc:*:*:*)
@ -1018,7 +958,7 @@ EOF
exit 0 ;;
M68*:*:R3V[567]*:*)
test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0)
3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0)
OS_REL=''
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
@ -1029,13 +969,13 @@ EOF
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
&& echo i486-ncr-sysv4 && exit 0 ;;
m68*:LynxOS:2.*:*)
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
echo m68k-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
mc68030:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
exit 0 ;;
i?86:LynxOS:2.*:* | i?86:LynxOS:3.[01]*:*)
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
echo i386-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
TSUNAMI:LynxOS:2.*:*)
@ -1044,7 +984,7 @@ EOF
rs6000:LynxOS:2.*:*)
echo rs6000-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:*)
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
echo powerpc-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
SM[BE]S:UNIX_SV:*:*)
@ -1064,8 +1004,8 @@ EOF
echo ns32k-sni-sysv
fi
exit 0 ;;
PENTIUM:CPunix:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
# says <Richard.M.Bartel@ccMail.Census.GOV>
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
# says <Richard.M.Bartel@ccMail.Census.GOV>
echo i586-unisys-sysv4
exit 0 ;;
*:UNIX_System_V:4*:FTX*)
@ -1077,6 +1017,10 @@ EOF
# From seanf@swdc.stratus.com.
echo i860-stratus-sysv4
exit 0 ;;
*:VOS:*:*)
# From Paul.Green@stratus.com.
echo hppa1.1-stratus-vos
exit 0 ;;
mc68*:A/UX:*:*)
echo m68k-apple-aux${UNAME_RELEASE}
exit 0 ;;
@ -1115,15 +1059,17 @@ EOF
echo `uname -p`-apple-darwin${UNAME_RELEASE}
exit 0 ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
if test "${UNAME_MACHINE}" = "x86pc"; then
UNAME_PROCESSOR=`uname -p`
if test "$UNAME_PROCESSOR" = "x86"; then
UNAME_PROCESSOR=i386
UNAME_MACHINE=pc
fi
echo `uname -p`-${UNAME_MACHINE}-nto-qnx
echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
exit 0 ;;
*:QNX:*:4*)
echo i386-pc-qnx
exit 0 ;;
NSR-[KW]:NONSTOP_KERNEL:*:*)
NSR-[GKLNPTVW]:NONSTOP_KERNEL:*:*)
echo nsr-tandem-nsk${UNAME_RELEASE}
exit 0 ;;
*:NonStop-UX:*:*)
@ -1146,7 +1092,7 @@ EOF
fi
echo ${UNAME_MACHINE}-unknown-plan9
exit 0 ;;
i?86:OS/2:*:*)
i*86:OS/2:*:*)
# If we were able to find `uname', then EMX Unix compatibility
# is probably installed.
echo ${UNAME_MACHINE}-pc-os2-emx
@ -1169,11 +1115,18 @@ EOF
*:ITS:*:*)
echo pdp10-unknown-its
exit 0 ;;
i*86:XTS-300:*:STOP)
echo ${UNAME_MACHINE}-unknown-stop
exit 0 ;;
i*86:atheos:*:*)
echo ${UNAME_MACHINE}-unknown-atheos
exit 0 ;;
esac
#echo '(No uname command or uname output not recognized.)' 1>&2
#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
eval $set_cc_for_build
cat >$dummy.c <<EOF
#ifdef _SEQUENT_
# include <sys/types.h>

View File

@ -1,9 +1,9 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
# Free Software Foundation, Inc.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
# 2000, 2001, 2002 Free Software Foundation, Inc.
timestamp='2001-03-09'
timestamp='2002-04-26'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@ -29,7 +29,8 @@ timestamp='2001-03-09'
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Please send patches to <config-patches@gnu.org>.
# Please send patches to <config-patches@gnu.org>. Submit a context
# diff and a properly formatted ChangeLog entry.
#
# Configuration subroutine to validate and canonicalize a configuration type.
# Supply the specified configuration type as an argument.
@ -117,7 +118,7 @@ esac
# Here we must recognize all the valid KERNEL-OS combinations.
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
case $maybe_os in
nto-qnx* | linux-gnu* | storm-chaos* | os2-emx*)
nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
os=-$maybe_os
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
;;
@ -157,6 +158,14 @@ case $os in
os=-vxworks
basic_machine=$1
;;
-chorusos*)
os=-chorusos
basic_machine=$1
;;
-chorusrdb)
os=-chorusrdb
basic_machine=$1
;;
-hiux*)
os=-hiuxwe2
;;
@ -215,24 +224,36 @@ esac
case $basic_machine in
# Recognize the basic CPU types without company name.
# Some are omitted here because they have special meanings below.
tahoe | i860 | ia64 | m32r | m68k | m68000 | m88k | ns32k | arc \
| arm | arme[lb] | arm[bl]e | armv[2345] | armv[345][lb] | strongarm | xscale \
| pyramid | mn10200 | mn10300 | tron | a29k \
| 580 | i960 | h8300 \
| x86 | ppcbe | mipsbe | mipsle | shbe | shle \
| hppa | hppa1.0 | hppa1.1 | hppa2.0 | hppa2.0w | hppa2.0n \
| hppa64 \
| alpha | alphaev[4-8] | alphaev56 | alphapca5[67] \
| alphaev6[78] \
| we32k | ns16k | clipper | i370 | sh | sh[34] \
| powerpc | powerpcle \
| 1750a | dsp16xx | pdp10 | pdp11 \
| mips16 | mips64 | mipsel | mips64el \
| mips64orion | mips64orionel | mipstx39 | mipstx39el \
| mips64vr4300 | mips64vr4300el | mips64vr4100 | mips64vr4100el \
| mips64vr5000 | miprs64vr5000el | mcore | s390 | s390x \
| sparc | sparclet | sparclite | sparc64 | sparcv9 | v850 | c4x \
| thumb | d10v | d30v | fr30 | avr | openrisc)
1750a | 580 \
| a29k \
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
| c4x | clipper \
| d10v | d30v | dsp16xx \
| fr30 \
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
| i370 | i860 | i960 | ia64 \
| m32r | m68000 | m68k | m88k | mcore \
| mips | mips16 | mips64 | mips64el | mips64orion | mips64orionel \
| mips64vr4100 | mips64vr4100el | mips64vr4300 \
| mips64vr4300el | mips64vr5000 | mips64vr5000el \
| mipsbe | mipseb | mipsel | mipsle | mipstx39 | mipstx39el \
| mipsisa32 | mipsisa64 \
| mn10200 | mn10300 \
| ns16k | ns32k \
| openrisc | or32 \
| pdp10 | pdp11 | pj | pjl \
| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
| pyramid \
| sh | sh[34] | sh[34]eb | shbe | shle | sh64 \
| sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
| strongarm \
| tahoe | thumb | tic80 | tron \
| v850 | v850e \
| we32k \
| x86 | xscale | xstormy16 | xtensa \
| z8k)
basic_machine=$basic_machine-unknown
;;
m6811 | m68hc11 | m6812 | m68hc12)
@ -240,13 +261,13 @@ case $basic_machine in
basic_machine=$basic_machine-unknown
os=-none
;;
m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | z8k | v70 | h8500 | w65 | pj | pjl)
m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
;;
# We use `pc' rather than `unknown'
# because (1) that's what they normally are, and
# (2) the word "unknown" tends to confuse beginning users.
i[234567]86 | x86_64)
i*86 | x86_64)
basic_machine=$basic_machine-pc
;;
# Object if more than one company name word.
@ -255,30 +276,45 @@ case $basic_machine in
exit 1
;;
# Recognize the basic CPU types with company name.
# FIXME: clean up the formatting here.
vax-* | tahoe-* | i[234567]86-* | i860-* | ia64-* | m32r-* | m68k-* | m68000-* \
| m88k-* | sparc-* | ns32k-* | fx80-* | arc-* | c[123]* \
| arm-* | armbe-* | armle-* | armv*-* | strongarm-* | xscale-* \
| mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
| power-* | none-* | 580-* | cray2-* | h8300-* | h8500-* | i960-* \
| xmp-* | ymp-* \
| x86-* | ppcbe-* | mipsbe-* | mipsle-* | shbe-* | shle-* \
| hppa-* | hppa1.0-* | hppa1.1-* | hppa2.0-* | hppa2.0w-* \
| hppa2.0n-* | hppa64-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphapca5[67]-* \
| alphaev6[78]-* \
| we32k-* | cydra-* | ns16k-* | pn-* | np1-* | xps100-* \
| clipper-* | orion-* \
| sparclite-* | pdp10-* | pdp11-* | sh-* | powerpc-* | powerpcle-* \
| sparc64-* | sparcv9-* | sparc86x-* | mips16-* | mips64-* | mipsel-* \
| mips64el-* | mips64orion-* | mips64orionel-* \
| mips64vr4100-* | mips64vr4100el-* | mips64vr4300-* | mips64vr4300el-* \
| mipstx39-* | mipstx39el-* | mcore-* \
| f30[01]-* | f700-* | s390-* | s390x-* | sv1-* | t3e-* \
| [cjt]90-* \
| m88110-* | m680[01234]0-* | m683?2-* | m68360-* | z8k-* | d10v-* \
| thumb-* | v850-* | d30v-* | tic30-* | c30-* | fr30-* \
| bs2000-* | tic54x-* | c54x-* | x86_64-*)
580-* \
| a29k-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
| arm-* | armbe-* | armle-* | armv*-* \
| avr-* \
| bs2000-* \
| c[123]* | c30-* | [cjt]90-* | c54x-* \
| clipper-* | cydra-* \
| d10v-* | d30v-* \
| elxsi-* \
| f30[01]-* | f700-* | fr30-* | fx80-* \
| h8300-* | h8500-* \
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
| i*86-* | i860-* | i960-* | ia64-* \
| m32r-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
| m88110-* | m88k-* | mcore-* \
| mips-* | mips16-* | mips64-* | mips64el-* | mips64orion-* \
| mips64orionel-* | mips64vr4100-* | mips64vr4100el-* \
| mips64vr4300-* | mips64vr4300el-* | mipsbe-* | mipseb-* \
| mipsle-* | mipsel-* | mipstx39-* | mipstx39el-* \
| none-* | np1-* | ns16k-* | ns32k-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
| pyramid-* \
| romp-* | rs6000-* \
| sh-* | sh[34]-* | sh[34]eb-* | shbe-* | shle-* | sh64-* \
| sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
| sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
| tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \
| v850-* | v850e-* | vax-* \
| we32k-* \
| x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
| xtensa-* \
| ymp-* \
| z8k-*)
;;
# Recognize the various machine names and aliases which stand
# for a CPU type and a company and sometimes even an OS.
@ -341,6 +377,10 @@ case $basic_machine in
basic_machine=ns32k-sequent
os=-dynix
;;
c90)
basic_machine=c90-cray
os=-unicos
;;
convex-c1)
basic_machine=c1-convex
os=-bsd
@ -361,16 +401,8 @@ case $basic_machine in
basic_machine=c38-convex
os=-bsd
;;
cray | ymp)
basic_machine=ymp-cray
os=-unicos
;;
cray2)
basic_machine=cray2-cray
os=-unicos
;;
[cjt]90)
basic_machine=${basic_machine}-cray
cray | j90)
basic_machine=j90-cray
os=-unicos
;;
crds | unos)
@ -385,6 +417,14 @@ case $basic_machine in
decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
basic_machine=mips-dec
;;
decsystem10* | dec10*)
basic_machine=pdp10-dec
os=-tops10
;;
decsystem20* | dec20*)
basic_machine=pdp10-dec
os=-tops20
;;
delta | 3300 | motorola-3300 | motorola-delta \
| 3300-motorola | delta-motorola)
basic_machine=m68k-motorola
@ -505,19 +545,19 @@ case $basic_machine in
basic_machine=i370-ibm
;;
# I'm not sure what "Sysv32" means. Should this be sysv3.2?
i[34567]86v32)
i*86v32)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv32
;;
i[34567]86v4*)
i*86v4*)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv4
;;
i[34567]86v)
i*86v)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv
;;
i[34567]86sol2)
i*86sol2)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-solaris2
;;
@ -565,14 +605,6 @@ case $basic_machine in
basic_machine=m68k-atari
os=-mint
;;
mipsel*-linux*)
basic_machine=mipsel-unknown
os=-linux-gnu
;;
mips*-linux*)
basic_machine=mips-unknown
os=-linux-gnu
;;
mips3*-*)
basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
;;
@ -587,6 +619,10 @@ case $basic_machine in
basic_machine=m68k-rom68k
os=-coff
;;
morphos)
basic_machine=powerpc-unknown
os=-morphos
;;
msdos)
basic_machine=i386-pc
os=-msdos
@ -666,6 +702,10 @@ case $basic_machine in
basic_machine=hppa1.1-oki
os=-proelf
;;
or32 | or32-*)
basic_machine=or32-unknown
os=-coff
;;
OSE68000 | ose68000)
basic_machine=m68000-ericsson
os=-ose
@ -691,7 +731,7 @@ case $basic_machine in
pc532 | pc532-*)
basic_machine=ns32k-pc532
;;
pentium | p5 | k5 | k6 | nexgen)
pentium | p5 | k5 | k6 | nexgen | viac3)
basic_machine=i586-pc
;;
pentiumpro | p6 | 6x86 | athlon)
@ -700,7 +740,7 @@ case $basic_machine in
pentiumii | pentium2)
basic_machine=i686-pc
;;
pentium-* | p5-* | k5-* | k6-* | nexgen-*)
pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
pentiumpro-* | p6-* | 6x86-* | athlon-*)
@ -724,6 +764,16 @@ case $basic_machine in
ppcle-* | powerpclittle-*)
basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppc64) basic_machine=powerpc64-unknown
;;
ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppc64le | powerpc64little | ppc64-le | powerpc64-little)
basic_machine=powerpc64le-unknown
;;
ppc64le-* | powerpc64little-*)
basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ps2)
basic_machine=i386-ibm
;;
@ -741,6 +791,12 @@ case $basic_machine in
rtpc | rtpc-*)
basic_machine=romp-ibm
;;
s390 | s390-*)
basic_machine=s390-ibm
;;
s390x | s390x-*)
basic_machine=s390x-ibm
;;
sa29200)
basic_machine=a29k-amd
os=-udi
@ -752,7 +808,7 @@ case $basic_machine in
basic_machine=sh-hitachi
os=-hms
;;
sparclite-wrs)
sparclite-wrs | simso-wrs)
basic_machine=sparclite-wrs
os=-vxworks
;;
@ -810,7 +866,7 @@ case $basic_machine in
sun386 | sun386i | roadrunner)
basic_machine=i386-sun
;;
sv1)
sv1)
basic_machine=sv1-cray
os=-unicos
;;
@ -818,8 +874,16 @@ case $basic_machine in
basic_machine=i386-sequent
os=-dynix
;;
t3d)
basic_machine=alpha-cray
os=-unicos
;;
t3e)
basic_machine=t3e-cray
basic_machine=alphaev5-cray
os=-unicos
;;
t90)
basic_machine=t90-cray
os=-unicos
;;
tic54x | c54x*)
@ -832,6 +896,10 @@ case $basic_machine in
tx39el)
basic_machine=mipstx39el-unknown
;;
toad1)
basic_machine=pdp10-xkl
os=-tops20
;;
tower | tower-32)
basic_machine=m68k-ncr
;;
@ -878,13 +946,17 @@ case $basic_machine in
basic_machine=hppa1.1-winbond
os=-proelf
;;
xmp)
basic_machine=xmp-cray
os=-unicos
windows32)
basic_machine=i386-pc
os=-windows32-msvcrt
;;
xps | xps100)
basic_machine=xps100-honeywell
;;
ymp)
basic_machine=ymp-cray
os=-unicos
;;
z8k-*-coff)
basic_machine=z8k-unknown
os=-sim
@ -905,13 +977,6 @@ case $basic_machine in
op60c)
basic_machine=hppa1.1-oki
;;
mips)
if [ x$os = x-linux-gnu ]; then
basic_machine=mips-unknown
else
basic_machine=mips-mips
fi
;;
romp)
basic_machine=romp-ibm
;;
@ -931,10 +996,13 @@ case $basic_machine in
we32k)
basic_machine=we32k-att
;;
sh3 | sh4)
sh3 | sh4 | sh3eb | sh4eb)
basic_machine=sh-unknown
;;
sparc | sparcv9)
sh64)
basic_machine=sh64-unknown
;;
sparc | sparcv9 | sparcv9b)
basic_machine=sparc-sun
;;
cydra)
@ -956,6 +1024,9 @@ case $basic_machine in
basic_machine=c4x-none
os=-coff
;;
*-unknown)
# Make sure to match an already-canonicalized machine name.
;;
*)
echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
exit 1
@ -1012,16 +1083,19 @@ case $os in
| -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
| -chorusos* | -chorusrdb* \
| -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
| -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* | -os2*)
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* )
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
case $basic_machine in
x86-* | i[34567]86-*)
x86-* | i*86-*)
;;
*)
os=-nto$os
@ -1068,12 +1142,18 @@ case $os in
-acis*)
os=-aos
;;
-atheos*)
os=-atheos
;;
-386bsd)
os=-bsd
;;
-ctix* | -uts*)
os=-sysv
;;
-nova*)
os=-rtmk-nova
;;
-ns2 )
os=-nextstep2
;;
@ -1148,6 +1228,7 @@ case $basic_machine in
arm*-semi)
os=-aout
;;
# This must come before the *-dec entry.
pdp10-*)
os=-tops20
;;
@ -1178,6 +1259,9 @@ case $basic_machine in
mips*-*)
os=-elf
;;
or32-*)
os=-coff
;;
*-tti) # must be before sparc entry or we get the wrong os.
os=-sysv3
;;
@ -1325,7 +1409,7 @@ case $basic_machine in
-ptx*)
vendor=sequent
;;
-vxsim* | -vxworks*)
-vxsim* | -vxworks* | -windiss*)
vendor=wrs
;;
-aux*)
@ -1340,6 +1424,9 @@ case $basic_machine in
-*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
vendor=atari
;;
-vos*)
vendor=stratus
;;
esac
basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
;;

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,5 @@
dnl***************************************************************************
dnl Copyright (c) 1998,1999,2000,2001 Free Software Foundation, Inc. *
dnl Copyright (c) 1998,1999,2000,2001,2002 Free Software Foundation, Inc. *
dnl *
dnl Permission is hereby granted, free of charge, to any person obtaining a *
dnl copy of this software and associated documentation files (the *
@ -28,14 +28,14 @@ dnl***************************************************************************
dnl
dnl Author: Thomas E. Dickey <dickey@clark.net> 1996,1997
dnl
dnl $Id: configure.in,v 1.233 2001/04/07 22:09:57 tom Exp $
dnl $Id: configure.in,v 1.267 2002/05/18 21:14:13 tom Exp $
dnl Process this file with autoconf to produce a configure script.
dnl
dnl See http://dickey.his.com/autoconf/ for additional information.
dnl
dnl ---------------------------------------------------------------------------
AC_PREREQ(2.13.20000819)
AC_REVISION($Revision: 1.233 $)
AC_REVISION($Revision: 1.267 $)
AC_INIT(ncurses/base/lib_initscr.c)
AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
@ -80,16 +80,40 @@ CF_CFG_DEFAULTS
### Checks for programs.
AC_PROG_CC
GCC_VERSION=none
if test "$GCC" = yes ; then
AC_MSG_CHECKING(version of gcc)
eval "$CC --version"
GCC_VERSION="`${CC} --version|head -1`"
AC_MSG_RESULT($GCC_VERSION)
fi
if test "$host" != $build; then
AC_CHECK_PROGS(BUILD_CC, $CC gcc cc)
else
BUILD_CC="$CC"
# If we're cross-compiling, allow the user to override the tools and their
# options. The configure script is oriented toward identifying the target
# compiler, etc., but we need a host compiler to generate parts of the source.
BUILD_CC='$(CC)'
BUILD_CFLAGS='$(CFLAGS)'
BUILD_LDFLAGS='$(LDFLAGS)'
BUILD_LIBS='$(LIBS)'
if test "$host_alias" != "$target_alias" ; then
AC_ARG_WITH(build-cc,
[ --with-build-cc=XXX if cross-compiling, the host C compiler (\$BUILD_CC)],
[BUILD_CC="$withval"],
[AC_CHECK_PROGS(BUILD_CC, $CC gcc cc)])
AC_ARG_WITH(build-cflags,
[ --with-build-cflags=XXX if cross-compiling, the host C compiler-flags],
[BUILD_CFLAGS="$withval"])
AC_ARG_WITH(build-ldflags,
[ --with-build-ldflags=XXX if cross-compiling, the host linker-flags],
[BUILD_LDFLAGS="$withval"])
AC_ARG_WITH(build-libs,
[ --with-build-libs=XXX if cross-compiling, the host libraries],
[BUILD_LIBS="$withval"])
fi
AC_SUBST(BUILD_CC)
AC_SUBST(BUILD_CFLAGS)
AC_SUBST(BUILD_LDFLAGS)
AC_SUBST(BUILD_LIBS)
AC_PROG_CPP
AC_PROG_GCC_TRADITIONAL
AC_ISC_POSIX
@ -126,12 +150,16 @@ else
popdef([AC_MSG_ERROR])dnl
fi
GXX_VERSION=none
if test "$GXX" = yes; then
case "`${CXX-g++} --version`" in
AC_MSG_CHECKING(version of g++)
GXX_VERSION="`${CXX-g++} --version|head -1`"
AC_MSG_RESULT($GXX_VERSION)
case $GXX_VERSION in
1*|2.[[0-6]]*)
GXX=""; CXX=""; ac_cv_prog_gxx=no
cf_cxx_library=no
echo No: templates do not work
AC_MSG_WARN(templates do not work)
;;
esac
fi
@ -195,7 +223,7 @@ dnl adjust the location into which the actual install is done, so that an
dnl archive can be built without modifying the host system's configuration.
AC_MSG_CHECKING(if you have specified an install-prefix)
AC_ARG_WITH(install-prefix,
[ --with-install-prefix prefixes actual install-location],
[ --with-install-prefix prefixes actual install-location (\$DESTDIR)],
[case "$withval" in #(vi
yes|no) #(vi
;;
@ -394,7 +422,7 @@ AC_MSG_RESULT($with_overwrite)
AC_MSG_CHECKING(if external terminfo-database is used)
AC_ARG_ENABLE(database,
[ --disable-database use only built-in data],
[ --disable-database do not use terminfo, only fallbacks/termcap],
[use_database=$enableval],
[use_database=yes])
AC_MSG_RESULT($use_database)
@ -409,6 +437,7 @@ os2*) #(vi
esac
AC_SUBST(TERMINFO_SRC)
CF_PATHSEP
if test "$use_database" != no ; then
AC_DEFINE(USE_DATABASE)
AC_MSG_CHECKING(which terminfo source-file will be installed)
@ -427,11 +456,10 @@ AC_MSG_RESULT($with_fallback)
FALLBACK_LIST=`echo $with_fallback|sed -e 's/,/ /g'`
AC_SUBST(FALLBACK_LIST)
MAKE_TERMINFO=
if test "$use_database" = no ; then
if test -z $with_fallback ; then
AC_ERROR(You have disabled the database w/o specifying fallbacks)
fi
TERMINFO="${datadir}/terminfo"
MAKE_TERMINFO="#"
else
AC_MSG_CHECKING(for list of terminfo directories)
@ -455,6 +483,7 @@ AC_DEFINE_UNQUOTED(TERMINFO,"$TERMINFO")
fi
AC_SUBST(TERMINFO)
AC_SUBST(MAKE_TERMINFO)
### use option --disable-big-core to make tic run on small machines
### We need 4Mb, check if we can allocate 50% more than that.
@ -487,9 +516,23 @@ AC_ARG_ENABLE(termcap,
AC_MSG_RESULT($with_termcap)
if test "$with_termcap" != "yes" ; then
if test "$use_database" = no ; then
if test -z $with_fallback ; then
AC_ERROR(You have disabled the database w/o specifying fallbacks)
fi
fi
AC_DEFINE(PURE_TERMINFO)
else
AC_DEFINE(USE_TERMCAP)
AC_MSG_CHECKING(for list of termcap files)
CF_WITH_PATHLIST(termpath,
[ --with-termpath=XXX specify list of termcap files],
TERMPATH,
/etc/termcap:/usr/share/misc/termcap)
AC_MSG_RESULT($TERMPATH)
test -n "$TERMPATH" && AC_DEFINE_UNQUOTED(TERMPATH,"$TERMPATH")
### use option --enable-getcap to use a hacked getcap for reading termcaps
AC_MSG_CHECKING(if fast termcap-loader is needed)
AC_ARG_ENABLE(getcap,
@ -551,13 +594,36 @@ AC_ARG_ENABLE(broken_linker,
[with_broken_linker=$enableval],
[with_broken_linker=$BROKEN_LINKER])
AC_MSG_RESULT($with_broken_linker)
test "$with_broken_linker" = yes && AC_DEFINE(BROKEN_LINKER)
BROKEN_LINKER=0
if test "$with_broken_linker" = yes ; then
AC_DEFINE(BROKEN_LINKER)
BROKEN_LINKER=1
elif test $DFT_LWR_MODEL = shared ; then
case $cf_cv_system_name in #(vi
cygwin*)
AC_DEFINE(BROKEN_LINKER)
BROKEN_LINKER=1
CF_VERBOSE(cygwin linker is broken anyway)
;;
esac
fi
AC_SUBST(BROKEN_LINKER)
### use option --with-bool to override bool's type
AC_MSG_CHECKING(for type of bool)
AC_ARG_WITH(bool,
[ --with-bool=TYPE override fallback type of bool variable],
[NCURSES_BOOL="$withval"],
[NCURSES_BOOL=auto])
AC_MSG_RESULT($NCURSES_BOOL)
AC_SUBST(NCURSES_BOOL)
### use option --with-ospeed to override ospeed's type
AC_MSG_CHECKING(for type of ospeed)
AC_ARG_WITH(ospeed,
[ --with-ospeed=TYPE override type of ospeed variable],
[NCURSES_OSPEED=$withval],
[NCURSES_OSPEED="$withval"],
[NCURSES_OSPEED=short])
AC_MSG_RESULT($NCURSES_OSPEED)
AC_SUBST(NCURSES_OSPEED)
@ -594,13 +660,17 @@ AC_ARG_ENABLE(ext-funcs,
[with_ext_funcs=yes])
AC_MSG_RESULT($with_ext_funcs)
if test "$with_ext_funcs" = yes ; then
NCURSES_EXT_FUNCS=1
AC_DEFINE(HAVE_CURSES_VERSION)
AC_DEFINE(HAVE_HAS_KEY)
AC_DEFINE(HAVE_RESIZETERM)
AC_DEFINE(HAVE_USE_DEFAULT_COLORS)
AC_DEFINE(HAVE_WRESIZE)
AC_DEFINE(NCURSES_EXT_FUNCS)
else
NCURSES_EXT_FUNCS=0
fi
AC_SUBST(NCURSES_EXT_FUNCS)
### use option --enable-const to turn on use of const beyond that in XSI.
AC_MSG_CHECKING(for extended use of const keyword)
@ -655,7 +725,7 @@ AC_MSG_RESULT($with_develop)
### use option --enable-colorfgbg to turn on use of $COLORFGBG environment
AC_MSG_CHECKING(if you want colorfgbg code)
AC_ARG_ENABLE(hard-tabs,
AC_ARG_ENABLE(enable-colorfgbg,
[ --enable-colorfgbg compile with \$COLORFGBG code],
[with_colorfgbg=$enableval],
[with_colorfgbg=$with_develop])
@ -730,6 +800,9 @@ test "$with_scroll_hints" = yes && AC_DEFINE(USE_SCROLL_HINTS)
fi
### use option --enable-widec to turn on use of wide-character support
NCURSES_CH_T=chtype
NCURSES_LIBUTF8=0
NCURSES_MBSTATE_T=0
AC_MSG_CHECKING(if you want experimental wide-character code)
AC_ARG_ENABLE(widec,
[ --enable-widec compile with experimental wide-char/UTF-8 code],
@ -739,7 +812,33 @@ AC_MSG_RESULT($with_widec)
if test "$with_widec" = yes ; then
LIB_SUFFIX="w${LIB_SUFFIX}"
AC_DEFINE(USE_WIDEC_SUPPORT)
CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
with_overwrite=no
NCURSES_CH_T=cchar_t
AC_CHECK_FUNC(putwc)
if test "$ac_cv_func_putwc" != yes ; then
CF_LIBUTF8
if test "$cf_cv_libutf8" = yes ; then
NCURSES_LIBUTF8=1
fi
fi
CF_MBSTATE_T
if test $cf_cv_mbstate_t = yes ; then
NCURSES_MBSTATE_T=1
fi
fi
AC_SUBST(NCURSES_CH_T)
AC_SUBST(NCURSES_LIBUTF8)
AC_SUBST(NCURSES_MBSTATE_T)
AC_MSG_CHECKING(for terminal capabilities file)
AC_ARG_WITH(caps,
[ --with-caps=alt compile with experimental alternate Caps file],
[TERMINFO_CAPS=Caps.$withval],
[TERMINFO_CAPS=Caps])
test -f ${srcdir}/include/${TERMINFO_CAPS} || TERMINFO_CAPS=Caps
AC_MSG_RESULT($TERMINFO_CAPS)
AC_SUBST(TERMINFO_CAPS)
###############################################################################
CF_HELP_MESSAGE(Testing/development Options:)
@ -818,8 +917,10 @@ CF_MATH_LIB(MATH_LIB,sin(x))
AC_SUBST(MATH_LIB)
### Checks for header files.
CF_GNU_SOURCE
AC_STDC_HEADERS
AC_HEADER_DIRENT
AC_HEADER_TIME
CF_REGEX
dnl These are some other potentially nonportable headers.
@ -857,7 +958,6 @@ AC_C_INLINE
test "$ac_cv_c_inline" != no && AC_DEFINE(CC_HAS_INLINE_FUNCS)
CF_TYPEOF_CHTYPE
CF_WIDEC_SHIFT
### Checks for external-data
CF_ERRNO
@ -871,7 +971,6 @@ geteuid \
getttynam \
issetugid \
memccpy \
mkstemp \
nanosleep \
poll \
remove \
@ -885,9 +984,7 @@ strdup \
strstr \
tcgetpgrp \
times \
vfscanf \
vsnprintf \
vsscanf \
)
if test "$with_getcap" = "yes" ; then
CF_CGETENT
@ -896,6 +993,16 @@ fi
CF_ISASCII
CF_STRUCT_SIGACTION
CF_FUNC_TERMIOS
CF_FUNC_VSSCANF
CF_MKSTEMP
# setup for prototype of fallback for vsscanf()
if test "$cf_cv_func_vsscanf" = vsscanf ; then
HAVE_VSSCANF=1
else
HAVE_VSSCANF=0
fi
AC_SUBST(HAVE_VSSCANF)
dnl FIXME (may need this) AC_SYS_RESTARTABLE_SYSCALLS
if test "$cross_compiling" = yes ; then
@ -921,23 +1028,17 @@ if test -n "$CXX" ; then
AC_LANG_CPLUSPLUS
CF_STDCPP_LIBRARY
if test "$GXX" = yes; then
AC_MSG_CHECKING(version of ${CXX-g++})
eval "${CXX-g++} --version"
case "`${CXX-g++} --version`" in
1*|2.[0-6]*)
cf_cxx_library=yes
;;
*-2.7*|2.7*)
CF_GPP_LIBRARY
;;
*)
cf_cxx_library=no
;;
esac
else
case $GXX_VERSION in
1*|2.[0-6]*)
cf_cxx_library=yes
;;
*-2.7*|2.7*)
CF_GPP_LIBRARY
;;
*)
cf_cxx_library=no
fi
;;
esac
AC_CHECK_HEADERS(typeinfo)
@ -947,12 +1048,28 @@ if test -n "$CXX" ; then
CF_CPP_PARAM_INIT
CF_CPP_VSCAN_FUNC
CXX_AR='$(AR)'
CXX_AR_OPTS='$(AR_OPTS)'
case $cf_cv_system_name in #(vi
sco3.2v5*)
irix*) #(vi
if test "$GXX" != yes ; then
CXX_AR='$(CXX)'
CXX_AR_OPTS='-ar -o'
fi
;;
sco3.2v5*) #(vi
CXXLDFLAGS="-u main"
;;
solaris2*)
if test "$GXX" != yes ; then
CXX_AR='$(CXX)'
CXX_AR_OPTS='-xar -o'
fi
;;
esac
AC_SUBST(CXXLDFLAGS)
AC_SUBST(CXX_AR)
AC_SUBST(CXX_AR_OPTS)
else
cf_cxx_library=no
cf_cv_builtin_bool=1
@ -966,12 +1083,20 @@ else
# Caveat: since the storage of the bool type is not standardized, it
# may change.
AC_MSG_CHECKING(for fallback type of bool)
case "$host_cpu" in #(vi
i?86) cf_cv_type_of_bool=char ;; #(vi
*) cf_cv_type_of_bool=int ;;
esac
AC_MSG_RESULT($cf_cv_type_of_bool)
if test "$NCURSES_BOOL" != auto ; then
cf_cv_type_of_bool=$NCURSES_AUTO
else
if test "$cf_cv_header_stdbool_h" = 1 ; then
CF_BOOL_SIZE
else
AC_MSG_CHECKING(for fallback type of bool)
case "$host_cpu" in #(vi
i?86) cf_cv_type_of_bool=char ;; #(vi
*) cf_cv_type_of_bool=int ;;
esac
AC_MSG_RESULT($cf_cv_type_of_bool)
fi
fi
fi
AC_SUBST(CXXLIBS)
@ -1043,18 +1168,16 @@ fi
### using a 'char' for bools. gcc 2.7.0's conversion-warnings are broken too
### badly to consider using for development purposes, but 2.5.8 is okay.
if test -n "$with_warnings"; then
if test "$GCC" = yes; then
case "`$CC --version`" in
2.6.3)
if test "$cf_cv_type_of_bool" != "char"; then
EXTRA_CFLAGS="$EXTRA_CFLAGS -Wconversion"
fi
;;
2.5*)
case $GCC_VERSION in
2.6.3)
if test "$cf_cv_type_of_bool" != "char"; then
EXTRA_CFLAGS="$EXTRA_CFLAGS -Wconversion"
;;
esac
fi
fi
;;
2.5*)
EXTRA_CFLAGS="$EXTRA_CFLAGS -Wconversion"
;;
esac
fi
### Construct the library-subsets, if any, from this set of keywords:
@ -1066,6 +1189,7 @@ else
LIB_SUBSETS="termlib+"
fi
LIB_SUBSETS="${LIB_SUBSETS}base"
test "$with_widec" = yes && LIB_SUBSETS="${LIB_SUBSETS}+widechar"
test "$with_ext_funcs" = yes && LIB_SUBSETS="${LIB_SUBSETS}+ext_funcs"
AC_MSG_RESULT($LIB_SUBSETS)
@ -1091,6 +1215,13 @@ AC_MSG_RESULT($DFT_ARG_SUFFIX)
AC_MSG_CHECKING(default library-dependency suffix)
CF_LIB_SUFFIX($DFT_LWR_MODEL,DFT_DEP_SUFFIX)dnl
if test $DFT_LWR_MODEL = shared ; then
case $cf_cv_system_name in #(vi
cygwin*)
DFT_DEP_SUFFIX=".dll.a"
;;
esac
fi
AC_SUBST(DFT_DEP_SUFFIX)dnl the corresponding library-suffix (".a")
AC_MSG_RESULT($DFT_DEP_SUFFIX)
@ -1149,7 +1280,7 @@ CFLAGS="$CFLAGS $EXTRA_CFLAGS"
################################################################################
AC_OUTPUT( \
include/MKterm.h.awk \
include/curses.h \
include/curses.head:include/curses.h.in \
include/termcap.h \
include/unctrl.h \
misc/run_tic.sh:misc/run_tic.in \
@ -1165,22 +1296,25 @@ CF_LIST_MODELS="$cf_list_models"
DFT_LWR_MODEL="$DFT_LWR_MODEL"
LDCONFIG="$LDCONFIG"
LIB_NAME="$LIB_NAME"
LIB_SUFFIX="$LIB_SUFFIX"
LIB_SUBSETS="$LIB_SUBSETS"
LIB_SUFFIX="$LIB_SUFFIX"
LIB_TRACING="$LIB_TRACING"
MAKE_TERMINFO="$MAKE_TERMINFO"
NCURSES_OSPEED="$NCURSES_OSPEED"
SRC_SUBDIRS="$SRC_SUBDIRS"
TERMINFO="$TERMINFO"
TINFO_NAME="$TINFO_NAME"
WITH_CURSES_H="$with_curses_h"
WITH_ECHO="$with_echo"
WITH_OVERWRITE="$with_overwrite"
WITH_CURSES_H="$with_curses_h"
cf_cv_abi_version="$cf_cv_abi_version"
cf_cv_do_symlinks="$cf_cv_do_symlinks"
cf_cv_rel_version="$cf_cv_rel_version"
cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
cf_cv_shlib_version="$cf_cv_shlib_version"
cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
cf_cv_system_name="$cf_cv_system_name"
cf_with_cxx_binding="$cf_with_cxx_binding"
cf_cv_shlib_version="$cf_cv_shlib_version"
target="$target"
],sort)dnl

View File

@ -1,4 +1,4 @@
# $Id: dist.mk,v 1.247 2001/05/12 18:18:37 tom Exp $
# $Id: dist.mk,v 1.303 2002/05/18 19:18:04 tom Exp $
# Makefile for creating ncurses distributions.
#
# This only needs to be used directly as a makefile by developers, but
@ -10,7 +10,7 @@ SHELL = /bin/sh
# These define the major/minor/patch versions of ncurses.
NCURSES_MAJOR = 5
NCURSES_MINOR = 2
NCURSES_PATCH = 20010512
NCURSES_PATCH = 20020518
# We don't append the patch to the version, since this only applies to releases
VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
@ -63,17 +63,33 @@ manhtml: MANIFEST
echo "s/$${xu}/$${x}/g" >> subst.tmp ;\
fi ;\
done
# change some things to make weblint happy:
@echo 's/<B>/<STRONG>/g' >> subst.tmp
@echo 's/<\/B>/<\/STRONG>/g' >> subst.tmp
@echo 's/<I>/<EM>/g' >> subst.tmp
@echo 's/<\/I>/<\/EM>/g' >> subst.tmp
@echo 's/<\/TITLE>/<\/TITLE><link rev=made href="mailto:bug-ncurses@gnu.org">/' >> subst.tmp
@sort < subst.tmp | uniq > subst.sed
@rm -f subst.tmp
@for f in man/*.[0-9]* ; do \
m=`basename $$f` ;\
T=`egrep '^.TH' $$f|sed -e 's/^.TH //' -e s'/"//g' -e 's/[ ]\+$$//'` ; \
g=$${m}.html ;\
if [ -f doc/html/$$g ]; then chmod +w doc/html/$$g; fi;\
echo "Converting $$m to HTML" ;\
man/edit_man.sh editing /usr/man man $$f | $(MANPROG) | tr '\255' '-' | $(MAN2HTML) | \
echo '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">' > doc/html/man/$$g ;\
echo '<!-- ' >> doc/html/man/$$g ;\
egrep '^.\\"[^#]' $$f | \
sed -e 's/\$$/@/g' \
-e 's/^.../ */' \
-e 's/</\&lt;/g' \
-e 's/>/\&gt;/g' \
>> doc/html/man/$$g ;\
echo '-->' >> doc/html/man/$$g ;\
man/edit_man.sh editing /usr/man man $$f | $(MANPROG) | tr '\255' '-' | $(MAN2HTML) -title "$$T" | \
sed -f subst.sed |\
sed -e 's/"curses.3x.html"/"ncurses.3x.html"/g' \
> doc/html/man/$$g ;\
>> doc/html/man/$$g ;\
done
@rm -f subst.sed
@sed -e "\%./doc/html/man/%d" < MANIFEST > MANIFEST.tmp

View File

@ -1,6 +1,6 @@
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 3.0//EN">
<!--
$Id: ncurses-intro.html,v 1.34 2000/06/11 00:03:55 tom Exp $
$Id: ncurses-intro.html,v 1.35 2001/09/02 00:23:11 tom Exp $
-->
<HTML>
<HEAD>
@ -704,7 +704,11 @@ restore the ncurses screen from before the escape.
<CODE>newterm()</CODE> instead of <CODE>initscr()</CODE>. <CODE>newterm()</CODE> should
be called once for each terminal. It returns a variable of type
<CODE>SCREEN *</CODE> which should be saved as a reference to that
terminal. The arguments are the type of the terminal (a string) and
terminal.
(NOTE: a SCREEN variable is not a <em>screen</em> in the sense we
are describing in this introduction, but a collection of
parameters used to assist in optimizing the display.)
The arguments are the type of the terminal (a string) and
<CODE>FILE</CODE> pointers for the output and input of the terminal. If
type is NULL then the environment variable <CODE>$TERM</CODE> is used.
<CODE>endwin()</CODE> should called once at wrapup time for each terminal

View File

@ -1,6 +1,6 @@
# $Id: Makefile.in,v 1.32 2001/03/24 19:53:31 tom Exp $
# $Id: Makefile.in,v 1.36 2002/01/20 01:49:17 tom Exp $
##############################################################################
# Copyright (c) 1998,1999,2000,2001 Free Software Foundation, Inc. #
# Copyright (c) 1998,1999,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"), #
@ -50,6 +50,7 @@ DESTDIR = @DESTDIR@
srcdir = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
includedir = @includedir@
@ -57,6 +58,7 @@ LIBTOOL = @LIBTOOL@
INSTALL = @INSTALL@
INSTALL_LIB = @INSTALL@ @INSTALL_LIB@
INSTALL_PROG = @INSTALL_PROG@
INSTALL_DATA = @INSTALL_DATA@
AR = @AR@
@ -85,7 +87,7 @@ CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
LINK = $(LIBTOOL) $(CC)
LDFLAGS = @LDFLAGS@ @LD_MODEL@ @LIBS@
SHLIB_DIRS = -L../lib -L$(libdir)
SHLIB_DIRS = -L../lib
SHLIB_LIST = $(SHLIB_DIRS) -lncurses@LIB_SUFFIX@ @SHLIB_LIST@
MK_SHARED_LIB = @MK_SHARED_LIB@
@ -97,6 +99,8 @@ ABI_VERSION = @cf_cv_abi_version@
RANLIB = @RANLIB@
IMPORT_LIB = @IMPORT_LIB@
SHARED_LIB = @SHARED_LIB@
LIBRARIES = @LIBS_TO_MAKE@
LINT = @LINT@
@ -113,8 +117,9 @@ install :: $(AUTO_SRC) $(LIBRARIES)
sources : $(AUTO_SRC)
$(DESTDIR)$(bindir) \
$(DESTDIR)$(libdir) :
$(srcdir)/../mkinstalldirs $@
sh $(srcdir)/../mkinstalldirs $@
# make copies to simplify include-paths while still keeping form's include
# file in this directory.
@ -136,7 +141,7 @@ tags:
@MAKE_UPPER_TAGS@ etags *.[ch]
mostlyclean ::
-rm -f core tags TAGS *~ *.i *.ln *.atac trace
-rm -f core tags TAGS *~ *.bak *.i *.ln *.atac trace
clean :: mostlyclean
-rm -f $(AUTO_SRC)

View File

@ -332,7 +332,7 @@ extern NCURSES_EXPORT(Field_Options) field_opts (const FIELD *);
extern NCURSES_EXPORT(FORM *) new_form (FIELD **);
extern NCURSES_EXPORT(FIELD **)form_fields (const FORM *);
extern NCURSES_EXPORT(FIELD **) form_fields (const FORM *);
extern NCURSES_EXPORT(FIELD *) current_field (const FORM *);
extern NCURSES_EXPORT(WINDOW *) form_win (const FORM *);

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,162 @@
#! /bin/sh
# $Id: MKkey_defs.sh,v 1.7 2002/01/13 01:36:32 tom Exp $
##############################################################################
# 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. #
##############################################################################
#
# MKkey_defs.sh -- generate function-key definitions for curses.h
#
# Author: Thomas E. Dickey <dickey@herndon4.his.com> 2001
#
# Extract function-key definitions from the Caps file
#
: ${AWK-awk}
DATA=${1-Caps}
data=data$$
pass1=pass1_$$
pass2=pass2_$$
pass3=pass3_$$
pass4=pass4_$$
trap 'rm -f $data pass[1234]_$$' 0 1 2 5 15
sed -e 's/[ ]\+/ /g' < $DATA |sort -n +5 >$data
cat <<EOF
/*
* These definitions were generated by $0 $DATA
*/
EOF
# KEY_RESIZE
maxkey=410
for pass in 1 2 3 4
do
output=pass${pass}_$$
${AWK-awk} >$output <$data '
function print_cols(text,cols) {
printf "%s", text
len = length(text);
while (len < cols) {
printf " "
len += 8;
}
}
function decode(keycode) {
result = 0;
if (substr(keycode, 1, 2) == "0x") {
digits="0123456789abcdef";
} else if (substr(keycode, 1, 1) == "0") {
digits="01234567";
} else {
digits="0123456789";
}
while (length(keycode) != 0) {
digit=substr(keycode, 1, 1);
keycode=substr(keycode, 2);
result = result * length(digits) + index(digits, digit) - 1;
}
return result;
}
BEGIN {
maxkey='$maxkey';
pass='$pass';
key_max=1;
bits=1;
while (key_max < maxkey) {
bits = bits + 1;
key_max = (key_max * 2) + 1;
}
octal_fmt = sprintf ("%%0%do", (bits + 2) / 3 + 1);
}
/^$/ {next;}
/^#/ {next;}
/^capalias/ {next;}
/^infoalias/ {next;}
$5 != "-" && $6 != "-" {
if ($6 == "+") {
if (pass == 1 || pass == 2)
next;
thiskey=maxkey + 1;
} else {
if (pass == 3)
next;
thiskey=decode($6);
}
if (thiskey > maxkey)
maxkey = thiskey;
if (pass == 2 || pass == 3) {
showkey=sprintf(octal_fmt, thiskey);
if ($5 == "KEY_F(0)" ) {
printf "#define "
print_cols("KEY_F0", 16);
print_cols(showkey, 16);
print "/* Function keys. Space for 64 */";
printf "#define "
print_cols("KEY_F(n)", 16);
print_cols("(KEY_F0+(n))", 16);
print "/* Value of function key n */"
} else {
printf "#define "
print_cols($5, 16);
print_cols(showkey, 16);
printf "/*"
for (i = 8; i <= NF; i++)
printf " %s", $i
print " */"
}
}
}
END {
if (pass == 1) {
print maxkey;
} else if (pass == 4) {
print "";
printf "#define ";
print_cols("KEY_MAX", 16);
result = sprintf (octal_fmt, key_max);
print_cols(result, 16);
printf "/* Maximum key value is ";
printf octal_fmt, maxkey;
print " */";
}
}
'
if test $pass = 1 ; then
maxkey=`cat $pass1`
fi
done
cat $pass2
cat $pass3
cat $pass4

View File

@ -1,7 +1,6 @@
BEGIN {
print "/****************************************************************************"
print " * Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. *"
print " * Copyright (c) 1998,1999,2000,2001 Free Software Foundation, Inc. *"
print " * *"
print " * Permission is hereby granted, free of charge, to any person obtaining a *"
print " * copy of this software and associated documentation files (the *"
@ -33,7 +32,7 @@ BEGIN {
print "/* and: Eric S. Raymond <esr@snark.thyrsus.com> */"
print "/****************************************************************************/"
print ""
print "/* $Id: MKterm.h.awk.in,v 1.39 2001/03/24 21:53:32 tom Exp $ */"
print "/* $Id: MKterm.h.awk.in,v 1.41 2001/12/23 01:04:38 tom Exp $ */"
print ""
print "/*"
print "** term.h -- Definition of struct term"
@ -52,22 +51,15 @@ BEGIN {
print "#endif"
print ""
print "/* Make this file self-contained by providing defaults for the HAVE_TERMIO[S]_H"
print " * and BROKEN_LINKER definition (based on the system for which this was"
print " * configured)."
print " * definition (based on the system for which this was configured)."
print " */"
print ""
print "#undef HAVE_TERMIOS_H"
print "#define HAVE_TERMIOS_H 1/*default*/"
print ""
print "#undef HAVE_TERMIO_H"
print "#define HAVE_TERMIO_H 0/*default*/"
print ""
print "#undef HAVE_TCGETATTR"
print "#define HAVE_TCGETATTR 1/*default*/"
print ""
print "#undef BROKEN_LINKER"
print "#define BROKEN_LINKER 0/*default*/"
print ""
print "#undef NCURSES_CONST"
print "#define NCURSES_CONST @NCURSES_CONST@"
print ""
@ -81,7 +73,7 @@ BEGIN {
print "#undef SET_TTY"
print "#undef GET_TTY"
print ""
print "/* Assume Posix termio if we have the header and function */"
print "/* Assume POSIX termio if we have the header and function */"
print "#if HAVE_TERMIOS_H && HAVE_TCGETATTR"
print ""
print "#undef TERMIOS"
@ -228,7 +220,7 @@ END {
print ""
print "typedef struct term { /* describe an actual terminal */"
print " TERMTYPE type; /* terminal type description */"
print " short Filedes; /* file description being written to */"
print " short Filedes; /* file description being written to */"
print " TTY Ottyb, /* original state of the terminal */"
print " Nttyb; /* current state of the terminal */"
print " int _baudrate; /* used to compute padding */"

View File

@ -1,4 +1,4 @@
# $Id: Makefile.in,v 1.27 2001/03/24 19:53:31 tom Exp $
# $Id: Makefile.in,v 1.35 2001/12/08 18:50:06 tom Exp $
##############################################################################
# Copyright (c) 1998,2000,2001 Free Software Foundation, Inc. #
# #
@ -27,7 +27,7 @@
# authorization. #
##############################################################################
#
# Author: Thomas E. Dickey <dickey@clark.net> 1996,1997
# Author: Thomas E. Dickey 1996-2001
#
# Makefile for ncurses source code.
#
@ -56,15 +56,20 @@ LN_S = @LN_S@
VERSION = @cf_cv_rel_version@
# The "Caps" file specifies the terminfo database format, as well as the list
# of function keys.
TERMINFO_CAPS = $(srcdir)/@TERMINFO_CAPS@
# These files are generated by the configure script
CONFIG_SRC = \
MKterm.h.awk \
curses.h \
curses.head \
termcap.h \
unctrl.h
# These files are generated by this makefile
AUTO_SRC = \
curses.h \
hashsize.h \
ncurses_def.h \
parametrized.h \
@ -73,21 +78,31 @@ AUTO_SRC = \
################################################################################
all \
libs \
depend \
sources \
install :: $(AUTO_SRC)
term.h: $(srcdir)/Caps MKterm.h.awk
$(AWK) -f MKterm.h.awk $(srcdir)/Caps > $@
curses.h : $(TERMINFO_CAPS) \
curses.head \
$(srcdir)/curses.tail \
$(srcdir)/MKkey_defs.sh
cat curses.head >$@
AWK=$(AWK) sh $(srcdir)/MKkey_defs.sh $(TERMINFO_CAPS) >>$@
sh -c 'if test "@NCURSES_CH_T@" = "cchar_t" ; then cat $(srcdir)/curses.wide >>$@ ; fi'
cat $(srcdir)/curses.tail >>$@
term.h: $(TERMINFO_CAPS) MKterm.h.awk
$(AWK) -f MKterm.h.awk $(TERMINFO_CAPS) > $@
sh $(srcdir)/edit_cfg.sh ../include/ncurses_cfg.h $@
hashsize.h: $(srcdir)/Caps $(srcdir)/MKhashsize.sh
sh $(srcdir)/MKhashsize.sh $(srcdir)/Caps >$@
hashsize.h: $(TERMINFO_CAPS) $(srcdir)/MKhashsize.sh
sh $(srcdir)/MKhashsize.sh $(TERMINFO_CAPS) >$@
ncurses_def.h: $(srcdir)/ncurses_defs $(srcdir)/MKncurses_def.sh
AWK=$(AWK) sh $(srcdir)/MKncurses_def.sh $(srcdir)/ncurses_defs >$@
parametrized.h: $(srcdir)/Caps $(srcdir)/MKparametrized.sh
AWK=$(AWK) sh $(srcdir)/MKparametrized.sh $(srcdir)/Caps >$@
parametrized.h: $(TERMINFO_CAPS) $(srcdir)/MKparametrized.sh
AWK=$(AWK) sh $(srcdir)/MKparametrized.sh $(TERMINFO_CAPS) >$@
tags:
ctags *.[ch]
@ -96,7 +111,7 @@ tags:
@MAKE_UPPER_TAGS@ etags *.[ch]
mostlyclean ::
-rm -f core tags TAGS *~ *.i *.ln *.atac trace
-rm -f core tags TAGS *~ *.bak *.i *.ln *.atac trace
clean :: mostlyclean
-rm -f $(AUTO_SRC)

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,134 @@
/* $Id: curses.tail,v 1.5 2001/12/30 00:01:16 tom Exp $ */
/* mouse interface */
#define NCURSES_MOUSE_VERSION 1
/* event masks */
#define BUTTON1_RELEASED 000000000001L
#define BUTTON1_PRESSED 000000000002L
#define BUTTON1_CLICKED 000000000004L
#define BUTTON1_DOUBLE_CLICKED 000000000010L
#define BUTTON1_TRIPLE_CLICKED 000000000020L
#define BUTTON1_RESERVED_EVENT 000000000040L
#define BUTTON2_RELEASED 000000000100L
#define BUTTON2_PRESSED 000000000200L
#define BUTTON2_CLICKED 000000000400L
#define BUTTON2_DOUBLE_CLICKED 000000001000L
#define BUTTON2_TRIPLE_CLICKED 000000002000L
#define BUTTON2_RESERVED_EVENT 000000004000L
#define BUTTON3_RELEASED 000000010000L
#define BUTTON3_PRESSED 000000020000L
#define BUTTON3_CLICKED 000000040000L
#define BUTTON3_DOUBLE_CLICKED 000000100000L
#define BUTTON3_TRIPLE_CLICKED 000000200000L
#define BUTTON3_RESERVED_EVENT 000000400000L
#define BUTTON4_RELEASED 000001000000L
#define BUTTON4_PRESSED 000002000000L
#define BUTTON4_CLICKED 000004000000L
#define BUTTON4_DOUBLE_CLICKED 000010000000L
#define BUTTON4_TRIPLE_CLICKED 000020000000L
#define BUTTON4_RESERVED_EVENT 000040000000L
#define BUTTON_CTRL 000100000000L
#define BUTTON_SHIFT 000200000000L
#define BUTTON_ALT 000400000000L
#define ALL_MOUSE_EVENTS 000777777777L
#define REPORT_MOUSE_POSITION 001000000000L
/* macros to extract single event-bits from masks */
#define BUTTON_RELEASE(e, x) ((e) & (001 << (6 * ((x) - 1))))
#define BUTTON_PRESS(e, x) ((e) & (002 << (6 * ((x) - 1))))
#define BUTTON_CLICK(e, x) ((e) & (004 << (6 * ((x) - 1))))
#define BUTTON_DOUBLE_CLICK(e, x) ((e) & (010 << (6 * ((x) - 1))))
#define BUTTON_TRIPLE_CLICK(e, x) ((e) & (020 << (6 * ((x) - 1))))
#define BUTTON_RESERVED_EVENT(e, x) ((e) & (040 << (6 * ((x) - 1))))
typedef unsigned long mmask_t;
typedef struct
{
short id; /* ID to distinguish multiple devices */
int x, y, z; /* event coordinates (character-cell) */
mmask_t bstate; /* button state bits */
}
MEVENT;
extern NCURSES_EXPORT(int) getmouse (MEVENT *);
extern NCURSES_EXPORT(int) ungetmouse (MEVENT *);
extern NCURSES_EXPORT(mmask_t) mousemask (mmask_t, mmask_t *);
extern NCURSES_EXPORT(bool) wenclose (const WINDOW *, int, int);
extern NCURSES_EXPORT(int) mouseinterval (int);
extern NCURSES_EXPORT(bool) wmouse_trafo (const WINDOW* win,int* y, int* x, bool to_screen);
extern NCURSES_EXPORT(bool) mouse_trafo (int*, int*, bool); /* generated */
#define mouse_trafo(y,x,to_screen) wmouse_trafo(stdscr,y,x,to_screen)
/* other non-XSI functions */
extern NCURSES_EXPORT(int) mcprint (char *, int); /* direct data to printer */
extern NCURSES_EXPORT(int) has_key (int); /* do we have given key? */
/* Debugging : use with libncurses_g.a */
extern NCURSES_EXPORT(void) _tracef (const char *, ...) GCC_PRINTFLIKE(1,2);
extern NCURSES_EXPORT(void) _tracedump (const char *, WINDOW *);
extern NCURSES_EXPORT(char *) _traceattr (attr_t);
extern NCURSES_EXPORT(char *) _traceattr2 (int, chtype);
extern NCURSES_EXPORT(char *) _nc_tracebits (void);
extern NCURSES_EXPORT(char *) _tracechar (int);
extern NCURSES_EXPORT(char *) _tracechtype (chtype);
extern NCURSES_EXPORT(char *) _tracechtype2 (int, chtype);
#ifdef _XOPEN_SOURCE_EXTENDED
#define _tracech_t _tracecchar_t
extern NCURSES_EXPORT(char *) _tracecchar_t (const cchar_t *);
#define _tracech_t2 _tracecchar_t2
extern NCURSES_EXPORT(char *) _tracecchar_t2 (int, const cchar_t *);
#else
#define _tracech_t _tracechtype
#define _tracech_t2 _tracechtype2
#endif
extern NCURSES_EXPORT(char *) _tracemouse (const MEVENT *);
extern NCURSES_EXPORT(void) trace (const unsigned int);
/* trace masks */
#define TRACE_DISABLE 0x0000 /* turn off tracing */
#define TRACE_TIMES 0x0001 /* trace user and system times of updates */
#define TRACE_TPUTS 0x0002 /* trace tputs calls */
#define TRACE_UPDATE 0x0004 /* trace update actions, old & new screens */
#define TRACE_MOVE 0x0008 /* trace cursor moves and scrolls */
#define TRACE_CHARPUT 0x0010 /* trace all character outputs */
#define TRACE_ORDINARY 0x001F /* trace all update actions */
#define TRACE_CALLS 0x0020 /* trace all curses calls */
#define TRACE_VIRTPUT 0x0040 /* trace virtual character puts */
#define TRACE_IEVENT 0x0080 /* trace low-level input processing */
#define TRACE_BITS 0x0100 /* trace state of TTY control bits */
#define TRACE_ICALLS 0x0200 /* trace internal/nested calls */
#define TRACE_CCALLS 0x0400 /* trace per-character calls */
#define TRACE_DATABASE 0x0800 /* trace read/write of terminfo/termcap data */
#define TRACE_ATTRS 0x1000 /* trace attribute updates */
#define TRACE_MAXIMUM 0xffff /* maximum trace level */
#if defined(TRACE) || defined(NCURSES_TEST)
extern NCURSES_EXPORT_VAR(int) _nc_optimize_enable; /* enable optimizations */
#ifdef _XOPEN_SOURCE_EXTENDED
extern NCURSES_EXPORT(const char *) _nc_viswbuf(const wchar_t *);
#endif
extern NCURSES_EXPORT(const char *) _nc_visbuf (const char *);
#define OPTIMIZE_MVCUR 0x01 /* cursor movement optimization */
#define OPTIMIZE_HASHMAP 0x02 /* diff hashing to detect scrolls */
#define OPTIMIZE_SCROLL 0x04 /* scroll optimization */
#define OPTIMIZE_ALL 0xff /* enable all optimizations (dflt) */
#endif
#ifdef __cplusplus
/* these names conflict with STL */
#undef box
#undef clear
#undef erase
#undef move
#undef refresh
}
#endif
#endif /* __NCURSES_H */

View File

@ -0,0 +1,237 @@
#ifdef _XOPEN_SOURCE_EXTENDED
/* $Id: curses.wide,v 1.23 2002/05/11 22:25:33 tom Exp $ */
extern NCURSES_EXPORT_VAR(cchar_t *) _nc_wacs;
#define WACS_BSSB (&_nc_wacs['l'])
#define WACS_SSBB (&_nc_wacs['m'])
#define WACS_BBSS (&_nc_wacs['k'])
#define WACS_SBBS (&_nc_wacs['j'])
#define WACS_SBSS (&_nc_wacs['u'])
#define WACS_SSSB (&_nc_wacs['t'])
#define WACS_SSBS (&_nc_wacs['v'])
#define WACS_BSSS (&_nc_wacs['w'])
#define WACS_BSBS (&_nc_wacs['q'])
#define WACS_SBSB (&_nc_wacs['x'])
#define WACS_SSSS (&_nc_wacs['n'])
#define WACS_ULCORNER WACS_BSSB
#define WACS_LLCORNER WACS_SSBB
#define WACS_URCORNER WACS_BBSS
#define WACS_LRCORNER WACS_SBBS
#define WACS_RTEE WACS_SBSS
#define WACS_LTEE WACS_SSSB
#define WACS_BTEE WACS_SSBS
#define WACS_TTEE WACS_BSSS
#define WACS_HLINE WACS_BSBS
#define WACS_VLINE WACS_SBSB
#define WACS_PLUS WACS_SSSS
#define WACS_S1 (&_nc_wacs['o']) /* scan line 1 */
#define WACS_S9 (&_nc_wacs['s']) /* scan line 9 */
#define WACS_DIAMOND (&_nc_wacs['`']) /* diamond */
#define WACS_CKBOARD (&_nc_wacs['a']) /* checker board */
#define WACS_DEGREE (&_nc_wacs['f']) /* degree symbol */
#define WACS_PLMINUS (&_nc_wacs['g']) /* plus/minus */
#define WACS_BULLET (&_nc_wacs['~']) /* bullet */
/* Teletype 5410v1 symbols */
#define WACS_LARROW (&_nc_wacs[',']) /* arrow left */
#define WACS_RARROW (&_nc_wacs['+']) /* arrow right */
#define WACS_DARROW (&_nc_wacs['.']) /* arrow down */
#define WACS_UARROW (&_nc_wacs['-']) /* arrow up */
#define WACS_BOARD (&_nc_wacs['h']) /* board of squares */
#define WACS_LANTERN (&_nc_wacs['i']) /* lantern symbol */
#define WACS_BLOCK (&_nc_wacs['0']) /* solid square block */
/* ncurses extensions */
#define WACS_S3 (&_nc_wacs['p']) /* scan line 3 */
#define WACS_S7 (&_nc_wacs['r']) /* scan line 7 */
#define WACS_LEQUAL (&_nc_wacs['y']) /* less/equal */
#define WACS_GEQUAL (&_nc_wacs['z']) /* greater/equal */
#define WACS_PI (&_nc_wacs['{']) /* Pi */
#define WACS_NEQUAL (&_nc_wacs['|']) /* not equal */
#define WACS_STERLING (&_nc_wacs['}']) /* UK pound sign */
/*
* Function prototypes for wide-character operations.
*
* "generated" comments should include ":WIDEC" to make the corresponding
* functions ifdef'd in lib_gen.c
*
* "implemented" comments do not need this marker.
*/
extern NCURSES_EXPORT(int) add_wch (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) add_wchnstr (const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) add_wchstr (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) addnwstr (const wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) addwstr (const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) bkgrnd (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(void) bkgrndset (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) border_set (const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*); /* generated:WIDEC */
extern NCURSES_EXPORT(int) box_set (WINDOW *, const cchar_t *, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) echo_wchar (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) erasewchar (wchar_t*); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) get_wch (wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) get_wstr (wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) getbkgrnd (cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) getcchar (const cchar_t *, wchar_t*, attr_t*, short*, void*); /* implemented */
extern NCURSES_EXPORT(int) getn_wstr (wint_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) hline_set (const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) in_wch (NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) in_wchnstr (NCURSES_CONST cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) in_wchstr (NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) innwstr (wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) ins_nwstr (const wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) ins_wch (const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) ins_wstr (const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) inwstr (wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(char*) key_name (wchar_t); /* implemented */
extern NCURSES_EXPORT(int) killwchar (wchar_t *); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) mvadd_wch (int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvadd_wchnstr (int, int, const cchar_t *, int);/* generated:WIDEC */
extern NCURSES_EXPORT(int) mvadd_wchstr (int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvaddnwstr (int, int, const wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvaddwstr (int, int, const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvget_wch (int, int, wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvget_wstr (int, int, wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvgetn_wstr (int, int, wint_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvhline_set (int, int, const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvin_wch (int, int, NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvin_wchnstr (int, int, NCURSES_CONST cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvin_wchstr (int, int, NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvinnwstr (int, int, wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvins_nwstr (int, int, const wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvins_wch (int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvins_wstr (int, int, const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvinwstr (int, int, wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvvline_set (int, int, const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwadd_wch (WINDOW *, int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwadd_wchnstr (WINDOW *, int, int, const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwadd_wchstr (WINDOW *, int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwaddnwstr (WINDOW *, int, int, const wchar_t *, int);/* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwaddwstr (WINDOW *, int, int, const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwget_wch (WINDOW *, int, int, wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwget_wstr (WINDOW *, int, int, wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwgetn_wstr (WINDOW *, int, int, wint_t *, int);/* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwhline_set (WINDOW *, int, int, const cchar_t *, int);/* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwin_wch (WINDOW *, int, int, NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwin_wchnstr (WINDOW *, int,int, NCURSES_CONST cchar_t *,int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwin_wchstr (WINDOW *, int, int, NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwinnwstr (WINDOW *, int, int, wchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwins_nwstr (WINDOW *, int,int, const wchar_t *,int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwins_wch (WINDOW *, int, int, const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwins_wstr (WINDOW *, int, int, const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwinwstr (WINDOW *, int, int, wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) mvwvline_set (WINDOW *, int,int, const cchar_t *,int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) pecho_wchar (WINDOW *, const cchar_t *); /* missing */
extern NCURSES_EXPORT(int) setcchar (cchar_t *, const wchar_t *, const attr_t, short, const void *); /* implemented */
extern NCURSES_EXPORT(int) slk_wset (int, const wchar_t *, int); /* missing */
extern NCURSES_EXPORT(attr_t) term_attrs (void); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) unget_wch (const wchar_t); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) vid_attr (attr_t, short, void *); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) vid_puts (attr_t, short, void *, int (*)(int)); /* implemented:WIDEC */
extern NCURSES_EXPORT(int) vline_set (const cchar_t *, int); /* generated:WIDEC */
extern NCURSES_EXPORT(int) wadd_wch (WINDOW *,const cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wadd_wchnstr (WINDOW *,const cchar_t *,int); /* implemented */
extern NCURSES_EXPORT(int) wadd_wchstr (WINDOW *,const cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) waddnwstr (WINDOW *,const wchar_t *,int); /* implemented */
extern NCURSES_EXPORT(int) waddwstr (WINDOW *,const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) wbkgrnd (WINDOW *,const cchar_t *); /* implemented */
extern NCURSES_EXPORT(void) wbkgrndset (WINDOW *,const cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wborder_set (WINDOW *,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*,const cchar_t*); /* implemented */
extern NCURSES_EXPORT(int) wecho_wchar (WINDOW *, const cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wget_wch (WINDOW *, wint_t *); /* implemented */
extern NCURSES_EXPORT(int) wget_wstr (WINDOW *, wint_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) wgetbkgrnd (WINDOW *, cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wgetn_wstr (WINDOW *,wint_t *, int); /* implemented */
extern NCURSES_EXPORT(int) whline_set (WINDOW *, const cchar_t *, int); /* implemented */
extern NCURSES_EXPORT(int) win_wch (WINDOW *, NCURSES_CONST cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) win_wchnstr (WINDOW *, NCURSES_CONST cchar_t *, int); /* implemented */
extern NCURSES_EXPORT(int) win_wchstr (WINDOW *, NCURSES_CONST cchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) winnwstr (WINDOW *, wchar_t *, int); /* implemented */
extern NCURSES_EXPORT(int) wins_nwstr (WINDOW *, const wchar_t *, int); /* implemented */
extern NCURSES_EXPORT(int) wins_wch (WINDOW *, const cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wins_wstr (WINDOW *, const wchar_t *); /* generated:WIDEC */
extern NCURSES_EXPORT(int) winwstr (WINDOW *, wchar_t *); /* implemented */
extern NCURSES_EXPORT(wchar_t*) wunctrl (cchar_t *); /* implemented */
extern NCURSES_EXPORT(int) wvline_set (WINDOW *, const cchar_t *, int); /* implemented */
/*
* XSI curses macros for XPG4 conformance.
*/
#define add_wch(c) wadd_wch(stdscr,c)
#define add_wchnstr(str,n) wadd_wchnstr(stdscr,str,n)
#define add_wchstr(str) wadd_wchstr(stdscr,str)
#define addnwstr(wstr,n) waddnwstr(stdscr,wstr,n)
#define addwstr(wstr) waddwstr(stdscr,wstr)
#define bkgrnd(c) wbkgrnd(stdscr,c)
#define bkgrndset(c) wbkgrndset(stdscr,c)
#define border_set(l,r,t,b,tl,tr,bl,br) wborder_set(stdscr,l,r,t,b,tl,tr,bl,br)
#define box_set(w,v,h) wborder_set(w,v,v,h,h,0,0,0,0)
#define echo_wchar(c) wecho_wchar(stdscr,c)
#define get_wch(c) wget_wch(stdscr,c)
#define get_wstr(t) wget_wstr(stdscr,t)
#define getbkgrnd(wch) wgetbkgrnd(stdscr,wch)
#define getn_wstr(t,n) wgetn_wstr(stdscr,t,n)
#define hline_set(c,n) whline_set(stdscr,c,n)
#define in_wch(c) win_wch(stdscr,c)
#define in_wchnstr(c,n) win_wchnstr(stdscr,c,n)
#define in_wchstr(c) win_wchstr(stdscr,c)
#define innwstr(c,n) winnwstr(stdscr,c,n)
#define ins_nwstr(t,n) wins_nwstr(stdscr,t,n)
#define ins_wch(c) wins_wch(stdscr,c)
#define ins_wstr(t) wins_wstr(stdscr,t)
#define inwstr(c) winwstr(stdscr,c)
#define vid_attr(a,pair,opts) vidattr(a)
#define vline_set(c,n) wvline_set(stdscr,c,n)
#define wadd_wchstr(win,str) wadd_wchnstr(win,str,-1)
#define waddwstr(win,wstr) waddnwstr(win,wstr,-1)
#define wattr_set(win,a,p,opts) ((win)->_attrs = (((a) & ~A_COLOR) | COLOR_PAIR(p)), OK)
#define wget_wstr(w,t) wgetn_wstr(w,t,-1)
#define wgetbkgrnd(win,wch) (*wch = win->_bkgrnd, OK)
#define win_wchstr(w,c) win_wchnstr(w,c,-1)
#define wins_wstr(w,t) wins_nwstr(w,t,-1)
#define mvadd_wch(y,x,c) mvwadd_wch(stdscr,y,x,c)
#define mvadd_wchnstr(y,x,s,n) mvwadd_wchnstr(stdscr,y,x,s,n)
#define mvadd_wchstr(y,x,s) mvwadd_wchstr(stdscr,y,x,s)
#define mvaddnwstr(y,x,wstr,n) mvwaddnwstr(stdscr,y,x,wstr,n)
#define mvaddwstr(y,x,wstr) mvwaddwstr(stdscr,y,x,wstr)
#define mvget_wch(y,x,c) mvwget_wch(stdscr,y,x,c)
#define mvget_wstr(y,x,t) mvwget_wstr(stdscr,y,x,t)
#define mvgetn_wstr(y,x,t,n) mvwgetn_wstr(stdscr,y,x,t,n)
#define mvhline_set(y,x,c,n) mvwhline_set(stdscr,y,x,c,n)
#define mvin_wch(y,x,c) mvwin_wch(stdscr,y,x,c)
#define mvin_wchnstr(y,x,c,n) mvwin_wchnstr(stdscr,y,x,c,n)
#define mvin_wchstr(y,x,c) mvwin_wchstr(stdscr,y,x,c)
#define mvinnwstr(y,x,c,n) mvwinnwstr(stdscr,y,x,c,n)
#define mvins_nwstr(y,x,t,n) mvwins_nwstr(stdscr,y,x,t,n)
#define mvins_wch(y,x,c) mvwins_wch(stdscr,y,x,c)
#define mvins_wstr(y,x,t) mvwins_wstr(stdscr,y,x,t)
#define mvinwstr(y,x,c) mvwinwstr(stdscr,y,x,c)
#define mvvline_set(y,x,c,n) mvwvline_set(stdscr,y,x,c,n)
#define mvwadd_wch(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : wadd_wch(win,c))
#define mvwadd_wchnstr(win,y,x,s,n) (wmove(win,y,x) == ERR ? ERR : wadd_wchnstr(win,s,n))
#define mvwadd_wchstr(win,y,x,s) (wmove(win,y,x) == ERR ? ERR : wadd_wchstr(win,s))
#define mvwaddnwstr(win,y,x,wstr,n) (wmove(win,y,x) == ERR ? ERR : waddnwstr(win,wstr,n))
#define mvwaddwstr(win,y,x,wstr) (wmove(win,y,x) == ERR ? ERR : waddwstr(win,wstr))
#define mvwget_wch(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : wget_wch(win,c))
#define mvwget_wstr(win,y,x,t) (wmove(win,y,x) == ERR ? ERR : wget_wstr(win,t))
#define mvwgetn_wstr(win,y,x,t,n) (wmove(win,y,x) == ERR ? ERR : wgetn_wstr(win,t,n))
#define mvwhline_set(win,y,x,c,n) (wmove(win,y,x) == ERR ? ERR : whline_set(win,c,n))
#define mvwin_wch(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : win_wch(win,c))
#define mvwin_wchnstr(win,y,x,c,n) (wmove(win,y,x) == ERR ? ERR : win_wchnstr(win,c,n))
#define mvwin_wchstr(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : win_wchstr(win,c))
#define mvwinnwstr(win,y,x,c,n) (wmove(win,y,x) == ERR ? ERR : winnwstr(win,c,n))
#define mvwins_nwstr(win,y,x,t,n) (wmove(win,y,x) == ERR ? ERR : wins_nwstr(win,t,n))
#define mvwins_wch(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : wins_wch(win,c))
#define mvwins_wstr(win,y,x,t) (wmove(win,y,x) == ERR ? ERR : wins_wstr(win,t))
#define mvwinwstr(win,y,x,c) (wmove(win,y,x) == ERR ? ERR : winwstr(win,c))
#define mvwvline_set(win,y,x,c,n) (wmove(win,y,x) == ERR ? ERR : wvline_set(win,c,n))
#endif /* _XOPEN_SOURCE_EXTENDED */

View File

@ -1,7 +1,7 @@
#!/bin/sh
# $Id: edit_cfg.sh,v 1.10 2000/09/09 20:29:58 tom Exp $
# $Id: edit_cfg.sh,v 1.12 2001/12/23 00:52:40 tom Exp $
##############################################################################
# Copyright (c) 1998,2000 Free Software Foundation, Inc. #
# 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"), #
@ -48,18 +48,20 @@ do
mv $2 $BAK
if ( grep "[ ]$name[ ]" $1 2>&1 >$TMP )
then
sed -e 's@#define '$name'.*$@'"`cat $TMP`@" $BAK >$2
elif test "$name" = "NCURSES_CONST" ; then
sed -e 's/define '$name'.*$/define '$name' \/\*nothing\*\//' $BAK >$2
value=1
else
sed -e 's/define '$name'.*$/define '$name' 0/' $BAK >$2
value=0
fi
echo '** edit: '$name $value
sed \
-e "s@#define ${name}.*\$@#define $name $value@" \
-e "s@#if $name\$@#if $value /* $name */@" \
-e "s@#if !$name\$@#if $value /* !$name */@" \
$BAK >$2
if (cmp -s $2 $BAK)
then
echo '** same: '$name
mv $BAK $2
else
echo '** edit: '$name
rm -f $BAK
fi
done

View File

@ -29,7 +29,7 @@
/****************************************************************************
* Author: Thomas E. Dickey <dickey@clark.net> 1996,1997 *
****************************************************************************/
/* $Id: nc_alloc.h,v 1.8 2000/04/08 23:42:57 tom Exp $ */
/* $Id: nc_alloc.h,v 1.10 2001/12/08 23:49:44 tom Exp $ */
#ifndef NC_ALLOC_included
#define NC_ALLOC_included 1
@ -66,14 +66,14 @@ extern void _nc_leaks_dump_entry(void);
#endif
#ifndef ExitProgram
#define ExitProgram(code) return code
#define ExitProgram(code) exit(code)
#endif
/* doalloc.c */
extern void *_nc_doalloc(void *, size_t);
extern NCURSES_EXPORT(void *) _nc_doalloc(void *, size_t);
#if !HAVE_STRDUP
#define strdup _nc_strdup
extern char *_nc_strdup(const char *);
extern NCURSES_EXPORT(char *) _nc_strdup(const char *);
#endif
#define typeMalloc(type,elts) (type *)malloc((elts)*sizeof(type))

View File

@ -1,6 +1,6 @@
# $Id: ncurses_defs,v 1.7 2001/04/07 22:53:10 tom Exp $
# $Id: ncurses_defs,v 1.14 2002/05/11 19:18:32 tom Exp $
##############################################################################
# Copyright (c) 2000 Free Software Foundation, Inc. #
# Copyright (c) 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"), #
@ -37,6 +37,8 @@ CC_HAS_INLINE_FUNCS
CC_HAS_PROTOS
CPP_HAS_PARAM_INIT
CPP_HAS_VSCAN_FUNC
CURSES_ACS_ARRAY acs_map
CURSES_WACS_ARRAY _nc_wacs
DECL_ERRNO
ETIP_NEEDS_MATH_H
GCC_NORETURN /* nothing */
@ -51,6 +53,7 @@ HAVE_FORM_H
HAVE_GETCWD
HAVE_GETEGID
HAVE_GETEUID
HAVE_GETNSTR
HAVE_GETOPT_H
HAVE_GETTIMEOFDAY
HAVE_GETTTYNAM
@ -109,6 +112,7 @@ HAVE_TERMIO_H
HAVE_TIMES
HAVE_TTYENT_H
HAVE_TYPEINFO
HAVE_TYPE_ATTR_T
HAVE_TYPE_SIGACTION
HAVE_UNISTD_H
HAVE_UNLINK
@ -118,11 +122,13 @@ HAVE_VSNPRINTF
HAVE_VSSCANF
HAVE_WORKING_POLL
HAVE_WRESIZE
HAVE__DOSCAN
MIXEDCASE_FILENAMES
NCURSES_EXPANDED
NCURSES_EXT_FUNCS
NCURSES_NOMACROS
NCURSES_NO_PADDING
NCURSES_PATHSEP ':'
NDEBUG
NEED_PTEM_H
NO_LEAKS
@ -133,6 +139,8 @@ SVR4_ACTION
SVR4_TERMIO
SYSTEM_NAME "unknown"
TERMINFO "none"
TERMPATH "none"
TIME_WITH_SYS_TIME
TYPEOF_CHTYPE
USE_COLORFGBG
USE_DATABASE
@ -149,6 +157,8 @@ USE_SCROLL_HINTS
USE_SIGWINCH
USE_STDIO_VSCAN
USE_STRSTREAM_VSCAN
USE_STRSTREAM_VSCAN_CAST
USE_SYMLINKS
USE_TERMCAP
USE_WIDEC_SUPPORT
USE_XMC_SUPPORT

View File

@ -1,5 +1,10 @@
/* $Id: ncurses_dll.h,v 1.1 2000/12/10 00:05:35 tom Exp $ */
/* $Id: ncurses_dll.h,v 1.2 2001/12/09 01:36:34 tom Exp $ */
#ifndef NCURSES_DLL_H_incl
#define NCURSES_DLL_H_incl 1
#undef NCURSES_DLL /* cygwin dll not implemented */
#define NCURSES_STATIC /* cygwin dll not implemented */
#if defined(__CYGWIN__)
# if defined(NCURSES_DLL)
@ -39,3 +44,5 @@
#if !defined(NCURSES_EXPORT_VAR)
# define NCURSES_EXPORT_VAR(type) NCURSES_IMPEXP type
#endif
#endif /* NCURSES_DLL_H_incl */

View File

@ -1,5 +1,5 @@
/****************************************************************************
* Copyright (c) 1998-2000 Free Software Foundation, Inc. *
* 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 *
@ -32,7 +32,7 @@
****************************************************************************/
/*
* $Id: tic.h,v 1.38 2001/03/11 15:12:08 tom Exp $
* $Id: tic.h,v 1.40 2001/08/12 00:45:57 tom Exp $
* tic.h - Global variables and structures for the terminfo
* compiler.
*/
@ -216,16 +216,16 @@ extern NCURSES_EXPORT(const struct name_table_entry * const *) _nc_get_hash_tabl
#define NOTFOUND ((struct name_table_entry *) 0)
/* out-of-band values for representing absent capabilities */
#define ABSENT_BOOLEAN -1
#define ABSENT_NUMERIC -1
#define ABSENT_BOOLEAN (-1) /* 255 */
#define ABSENT_NUMERIC (-1)
#define ABSENT_STRING (char *)0
/* out-of-band values for representing cancels */
#define CANCELLED_BOOLEAN (char)(-2)
#define CANCELLED_NUMERIC -2
#define CANCELLED_STRING (char *)-1
#define CANCELLED_BOOLEAN (char)(-2) /* 254 */
#define CANCELLED_NUMERIC (-2)
#define CANCELLED_STRING (char *)(-1)
#define VALID_BOOLEAN(s) ((s) >= 0)
#define VALID_BOOLEAN(s) ((unsigned char)(s) <= 1) /* reject "-1" */
#define VALID_NUMERIC(s) ((s) >= 0)
#define VALID_STRING(s) ((s) != CANCELLED_STRING && (s) != ABSENT_STRING)
@ -241,6 +241,7 @@ extern NCURSES_EXPORT(const struct name_table_entry * const *) _nc_get_hash_tabl
/* access.c */
extern NCURSES_EXPORT(char *) _nc_basename (char *);
extern NCURSES_EXPORT(char *) _nc_rootname (char *);
/* comp_hash.c: name lookup */
extern NCURSES_EXPORT(struct name_table_entry const *) _nc_find_entry

View File

@ -1,6 +1,6 @@
#!/bin/sh
#***************************************************************************
# Copyright (c) 1998-2000 Free Software Foundation, Inc. *
# 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 *
@ -27,7 +27,7 @@
# authorization. *
#***************************************************************************
#
# $Id: MKterminfo.sh,v 1.6 2000/01/25 11:31:57 tom Exp $
# $Id: MKterminfo.sh,v 1.9 2001/09/01 23:06:18 tom Exp $
#
# MKterminfo.sh -- generate terminfo.5 from Caps tabular data
#
@ -68,8 +68,9 @@ sed -n <$caps "\
/%%-STOP-HERE-%%/q
/^#%/s///p
/^#/d
s/[ ]\+/ /g
s/$/T}/
s/ [Y\-][B\-][C\-][G\-][E\-]\** / T{/
s/ [A-Z0-9_()\-]\+ [0-9\-]\+ [Y\-][B\-][C\-][G\-][EK\-]\** / T{/
s/ bool / /p
s/ num / /p
s/ str / /p
@ -80,6 +81,7 @@ rm -f $temp
saved=no
while true
do
data=
read data
test -z "$data" && break
case "$data" in #(vi

View File

@ -1,6 +1,6 @@
# $Id: Makefile.in,v 1.28 2000/08/19 19:15:44 tom Exp $
# $Id: Makefile.in,v 1.33 2002/01/19 22:49:44 tom Exp $
##############################################################################
# Copyright (c) 1998,2000 Free Software Foundation, Inc. #
# 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"), #
@ -47,10 +47,11 @@ INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
all \
sources: terminfo.5
sources : terminfo.5
depend :
$(DESTDIR)$(mandir) :
$(srcdir)/../mkinstalldirs $@
sh $(srcdir)/../mkinstalldirs $@
EDITARGS = $(DESTDIR)$(mandir) $(srcdir) terminfo.5 $(srcdir)/*.[0-9]*
@ -61,15 +62,18 @@ uninstall uninstall.man :
-sh ./edit_man.sh removing $(EDITARGS)
# We compose terminfo.5 from the real sources...
CAPLIST=$(srcdir)/../include/Caps
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 *~ *.ln *.atac trace
-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.*

View File

@ -0,0 +1,134 @@
.\"***************************************************************************
.\" 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 <curses.h>\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:

View File

@ -0,0 +1,98 @@
.\"***************************************************************************
.\" 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_add_wchstr.3x,v 1.1 2002/02/23 22:15:55 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 <curses.h>
.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:

View File

@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_addstr.3x,v 1.9 2000/07/01 19:54:05 tom Exp $
.\" $Id: curs_addstr.3x,v 1.10 2002/03/09 23:09:29 tom Exp $
.TH curs_addstr 3X ""
.SH NAME
\fBaddstr\fR,
@ -38,29 +38,34 @@
\fBmvwaddstr\fR,
\fBmvwaddnstr\fR - add a string of characters to a \fBcurses\fR window and advance cursor
.SH SYNOPSIS
.nf
\fB#include <curses.h>\fR
\fBint addstr(const char *str);\fR
\fBint addstr(const char *\fR\fIstr\fR\fB);\fR
.br
\fBint addnstr(const char *str, int n);\fR
\fBint addnstr(const char *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR
.br
\fBint waddstr(WINDOW *win, const char *str);\fR
\fBint waddstr(WINDOW *\fR\fIwin\fR\fB, const char *\fR\fIstr\fR\fB);\fR
.br
\fBint waddnstr(WINDOW *win, const char *str, int n);\fR
\fBint waddnstr(WINDOW *\fR\fIwin\fR\fB, const char *\fR\fIstr\fR\fB, int \fR\fIn\fR\fB);\fR
.br
\fBint mvaddstr(int y, int x, const char *str);\fR
\fBint mvaddstr(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, const char *\fR\fIstr\fR\fB);\fR
.br
\fBint mvaddnstr(int y, int x, const char *str, int n);\fR
\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 *win, int y, int x, const char *str);\fR
\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 *win, int y, int x, const char *str, int n);\fR
\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.
\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

View File

@ -0,0 +1,91 @@
.\"***************************************************************************
.\" 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_addwstr.3x,v 1.2 2002/03/09 23:16:59 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 <curses.h>\fR
\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:

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_attr.3x,v 1.22 2000/07/08 11:59:58 tom Exp $
.\" $Id: curs_attr.3x,v 1.24 2002/02/16 22:38:32 tom Exp $
.TH curs_attr 3X ""
.SH NAME
\fBattroff\fR, \fBwattroff\fR, \fBattron\fR, \fBwattron\fR,
@ -159,10 +159,10 @@ l l .
The following macro is the reverse of \fBCOLOR_PAIR(\fR\fIn\fR\fB)\fR:
.DS C
.br
\fBPAIR_NUMBER(\fR\fIattrs\fR) Returns the pair number associated
with the \fBCOLOR_PAIR(\fR\fIn\fR\fB)\fR attribute.
.DE
.br
The return values of many of these routines are not meaningful (they are
implemented as macro-expanded assignments and simply return their argument).

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,13 +26,13 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_bkgd.3x,v 1.14 2000/07/01 17:39:31 tom Exp $
.\" $Id: curs_bkgd.3x,v 1.16 2002/02/16 22:38:32 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 <curses.h>\fR
@ -46,7 +46,6 @@
.br
\fBchtype getbkgd(WINDOW *win);\fR
.br
..
.SH DESCRIPTION
The \fBbkgdset\fR and \fBwbkgdset\fR routines manipulate the
background of the named window.
@ -77,21 +76,17 @@ appears, it is changed to the new background character.
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. The draft
does not include \fBconst\fR qualifiers on the arguments. The standard
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_outopts\fR(3X)
.\"#

View File

@ -0,0 +1,107 @@
.\"***************************************************************************
.\" 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 <curses.h>
\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:

View File

@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_border.3x,v 1.14 2000/07/01 19:54:58 tom Exp $
.\" $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,
@ -63,15 +63,45 @@
\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. The argument \fIls\fR is a character and attributes used
for the left side of the border, \fIrs\fR - right side, \fIts\fR - top side,
\fIbs\fR - bottom side, \fItl\fR - top left-hand corner, \fItr\fR - top
right-hand corner, \fIbl\fR - bottom left-hand corner, and \fIbr\fR - bottom
right-hand corner. If any of these arguments is zero, then the following
default values (defined in \fBcurses.h\fR) are used instead: \fBACS_VLINE\fR,
\fBACS_VLINE\fR, \fBACS_HLINE\fR, \fBACS_HLINE\fR, \fB\fBACS_ULCORNER\fR,
\fBACS_URCORNER\fR, \fBACS_LLCORNER\fR, \fBACS_LRCORNER\fR.
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
@ -95,11 +125,9 @@ 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. Additional
functions \fBmvhline\fR, \fBmvvline\fR, \fBmvwhline\fR, and \fBmvwvline\fR are
described there which this implementation does not yet support. The standard
specifies that they return \fBERR\fR on failure, but specifies no error
conditions.
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).
.\"#

View File

@ -0,0 +1,202 @@
.\"***************************************************************************
.\" 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 <curses.h>\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:

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_color.3x,v 1.16 2000/07/15 22:57:03 tom Exp $
.\" $Id: curs_color.3x,v 1.19 2002/02/16 22:38:32 tom Exp $
.TH curs_color 3X ""
.SH NAME
\fBstart_color\fR,
@ -100,8 +100,8 @@ 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 is
changed to the new definition.
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
@ -202,7 +202,7 @@ but only if that routine has been first invoked.
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),

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1999,2000 Free Software Foundation, Inc. *
.\" Copyright (c) 1999-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 *
@ -28,20 +28,18 @@
.\"
.\" Author: Thomas E. Dickey <dickey@clark.net> 1999
.\"
.\" $Id: curs_extend.3x,v 1.6 2000/07/15 22:57:20 tom Exp $
.\" $Id: curs_extend.3x,v 1.9 2002/02/16 22:39:04 tom Exp $
.TH curs_extend 3X ""
.SH NAME
\fBcurs_extend\fR:
\fBcurses_version\fP,
\fBuse_extended_names\fP \- miscellaneous curses extensions
..
.SH SYNOPSIS
\fB#include <curses.h>\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.
@ -62,12 +60,10 @@ 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 compatiblity 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),
@ -78,7 +74,6 @@ any code depending on them be conditioned using NCURSES_VERSION.
\fBkeyok\fR(3X),
\fBresizeterm\fR(3X),
\fBwresize\fR(3X).
..
.SH AUTHOR
Thomas Dickey.
.\"#

View File

@ -0,0 +1,161 @@
.\"***************************************************************************
.\" 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_get_wch.3x,v 1.3 2002/05/18 21:48:53 tom 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 <curses.h>\fR
.sp
\fBint get_wch(win_t *\fR\fIwch\fR\fB);\fR
.br
\fBint wget_wch(WINDOW *\fR\fIwin\fR\fB, win_t *\fR\fIwch\fR\fB);\fR
.br
\fBint mvget_wch(int \fR\fIy\fR\fB, int \fR\fIx\fR\fB, win_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, win_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<curses.h>\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<curses.h>\fR
automatically
includes the header file
\fB<stdio.h>\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)

View File

@ -0,0 +1,164 @@
.\"***************************************************************************
.\" 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_get_wstr.3x,v 1.2 2002/05/18 21:48:15 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 <curses.h>\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<wchar.h>\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.
.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:

View File

@ -0,0 +1,144 @@
.\"***************************************************************************
.\" 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_getcchar.3x,v 1.6 2002/03/24 01:08:55 tom 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 <curses.h>\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:

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_getch.3x,v 1.18 2001/02/25 00:20:30 tom Exp $
.\" $Id: curs_getch.3x,v 1.21 2002/03/17 14:36:21 tom Exp $
.TH curs_getch 3X ""
.SH NAME
\fBgetch\fR,
@ -53,14 +53,19 @@
.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
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.
Unless \fBnoecho\fR has been set, then the character will also be echoed into the
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
@ -74,26 +79,30 @@ call to \fBwrefresh\fR, \fBwrefresh\fR will be called before another character
is read.
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
that function key is returned instead of the raw characters.
Possible function
keys are defined in \fB<curses.h>\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.
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
(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.
The \fBungetch\fR routine places \fIch\fR back onto the input queue to be
returned by the next call to \fBwgetch\fR. Note that there is, in effect,
just one input queue for all windows.
returned by the next call to \fBwgetch\fR.
There is just one input queue for all windows.
.SS Function Keys
The following function keys, defined in \fB<curses.h>\fR, might be returned by
\fBgetch\fR if \fBkeypad\fR has been enabled. Note that not all of these are
\fBgetch\fR if \fBkeypad\fR has been enabled.
Note that not all of these are
necessarily supported on any particular terminal.
.sp
.TS
@ -211,8 +220,8 @@ c c c .
.TE
.sp
The \fBhas_key\fR routine takes a key value from the above list, and
returns TRUE or FALSE according as the current terminal type recognizes
a key with that value.
returns TRUE or FALSE according to whether
the current terminal type recognizes a key with that value.
.SH RETURN VALUE
All routines return the integer \fBERR\fR upon failure and an integer value
@ -234,30 +243,38 @@ when you press control/M.
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
(\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.
Note that \fBgetch\fR, \fBmvgetch\fR, and \fBmvwgetch\fR may be macros.
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
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
\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
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.
The echo behavior of these functions on input of \fBKEY_\fR or backspace
characters was not specified in the SVr4 documentation. This description is
characters was not specified in the SVr4 documentation.
This description is
adopted from the XSI Curses standard.
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
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
@ -266,10 +283,12 @@ input timeout or non-blocking mode hsd been set.
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
\fBEINTR\fR.
Under the \fBncurses\fR implementation, handled signals never
interrupt \fBgetch\fR.
The \fBhas_key\fR function is unique to \fBncurses\fR. We recommend that
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),

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_getstr.3x,v 1.9 2000/07/01 17:39:31 tom Exp $
.\" $Id: curs_getstr.3x,v 1.11 2002/04/13 22:14:30 tom Exp $
.TH curs_getstr 3X ""
.SH NAME
\fBgetstr\fR,
@ -82,11 +82,11 @@ 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 specifies that they return \fBERR\fR
on failure, but the single error condition \fBEOVERFLOW\fR associated with
extended-level conformance is not yet returned (the XSI curses support for
multi-byte characters is not yet present).
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

View File

@ -0,0 +1,68 @@
.\"***************************************************************************
.\" 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 <curses.h>\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:

View File

@ -0,0 +1,117 @@
.\"***************************************************************************
.\" 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 <curses.h>\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:

View File

@ -0,0 +1,65 @@
.\"***************************************************************************
.\" 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 <curses.h>
\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:

View File

@ -0,0 +1,104 @@
.\"***************************************************************************
.\" 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 <curses.h>\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:

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_insstr.3x,v 1.11 2000/07/01 19:57:49 tom Exp $
.\" $Id: curs_insstr.3x,v 1.12 2001/11/03 19:59:03 tom Exp $
.TH curs_insstr 3X ""
.SH NAME
\fBinsstr\fR,
@ -83,7 +83,7 @@ Note that all but \fBwinsnstr\fR may be macros.
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 multi-byte
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).

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_instr.3x,v 1.9 2000/07/01 20:05:03 tom Exp $
.\" $Id: curs_instr.3x,v 1.10 2001/11/03 19:58:56 tom Exp $
.TH curs_instr 3X ""
.SH NAME
\fBinstr\fR,
@ -71,7 +71,7 @@ Note that all routines except \fBwinnstr\fR may be macros.
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 multi-byte characters).
yet support XPG4 multibyte characters).
SVr4 does not
document whether a length limit includes or excludes the trailing NUL.
.PP

View File

@ -0,0 +1,95 @@
.\"***************************************************************************
.\" 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 <curses.h> \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:

View File

@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_kernel.3x,v 1.12 2000/02/27 01:37:46 tom Exp $
.\" $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,
@ -138,7 +138,7 @@ 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
visible or very visible.
invisible or very visible.
There is no way for ncurses to determine the initial cursor state to
restore that.
.SH PORTABILITY

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: curs_mouse.3x,v 1.15 2000/07/08 12:50:08 tom Exp $
.\" $Id: curs_mouse.3x,v 1.19 2002/02/16 22:39:04 tom Exp $
.TH curs_mouse 3X ""
.SH NAME
\fBgetmouse\fR, \fBungetmouse\fR,
@ -67,19 +67,23 @@ MEVENT;\fR
.br
.SH DESCRIPTION
These functions provide an interface to mouse events from
\fBncurses\fR(3X). Mouse events are represented by \fBKEY_MOUSE\fR
\fBncurses\fR(3X).
Mouse events are represented by \fBKEY_MOUSE\fR
pseudo-key values in the \fBwgetch\fR input stream.
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.
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,
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.
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.
setting a nonzero mask may turn it on.
Whether this happens is device-dependent.
Here are the mouse event type masks:
@ -119,20 +123,24 @@ 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
\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
coordinates.
The returned state mask will have exactly one bit set to
indicate the event type.
The \fBungetmouse\fR function behaves analogously to \fBungetch\fR. It pushes
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.
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
if it is and FALSE otherwise.
It is useful for determining what subset of
the screen windows enclose the location of a mouse event.
The \fBwmouse_trafo\fR function transforms a given pair of coordinates from
@ -140,24 +148,33 @@ 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
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
\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
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.
The \fBmouseinterval\fR function sets the maximum time (in thousands of a
second) that can elapse between press and release events in order for them to
be recognized as a click. This function returns the previous interval value.
The default is one fifth of a second.
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.
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
@ -167,8 +184,10 @@ 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
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
@ -190,12 +209,14 @@ running on your machine, mouse events will not be visible to
\fBncurses\fR(3X) (and the \fBwmousemask\fR function will always
return \fB0\fR).
The z member in the event structure is not presently used. It is intended
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
if they have been enabled by \fBwmousemask\fR.
Instead, the xterm mouse
report sequence will appear in the string read.
Mouse events under xterm will not be detected correctly in a window with
@ -205,7 +226,8 @@ of the response from xterm for mouse clicks).
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 $DISPLAY environment variable is set, and \fBkmous\fR is defined in
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).

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_move.3x,v 1.6 1998/03/11 21:12:53 juergen Exp $
.\" $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
@ -52,7 +52,7 @@ Note that \fBmove\fR may be a macro.
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 multi-byte characters.
does not yet support the extended-level XSI multibyte characters.
.SH SEE ALSO
\fBcurses\fR(3X), \fBcurs_refresh\fR(3X)
.\"#

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_outopts.3x,v 1.16 2001/03/31 23:47:31 tom Exp $
.\" $Id: curs_outopts.3x,v 1.17 2001/10/14 00:50:30 tom Exp $
.TH curs_outopts 3X ""
.SH NAME
\fBclearok\fR, \fBidlok\fR, \fBidcok\fR, \fBimmedok\fR,
@ -57,74 +57,96 @@
.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.
\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
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
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
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.
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,
\fIetc\fR., automatically cause a call to \fBwrefresh\fR. However, it may
\fIetc\fR., 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
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
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
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
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
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 in order to get the physical scrolling effect on the terminal, it is
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
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
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
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.
@ -132,19 +154,22 @@ 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
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
\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 in order to perform better vertical-motion optimization at \fBwrefresh\fR
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

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_overlay.3x,v 1.9 2000/07/01 20:05:31 tom Exp $
.\" $Id: curs_overlay.3x,v 1.10 2001/11/03 19:58:30 tom Exp $
.TH curs_overlay 3X ""
.SH NAME
\fBoverlay\fR,
@ -65,7 +65,7 @@ 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 multi-byte renditions (not yet supported in this implementation).
with multibyte renditions (not yet supported in this implementation).
.SH SEE ALSO
\fBcurses\fR(3X), \fBcurs_pad\fR(3X), \fBcurs_refresh\fR(3X)
.\"#

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: curs_print.3x,v 1.3 1998/03/11 21:12:53 juergen Exp $
.\" $Id: curs_print.3x,v 1.5 2002/02/16 22:39:04 tom Exp $
.TH curs_print 3X ""
.SH NAME
\fBmcprint\fR - ship binary data to printer

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,15 +26,15 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_refresh.3x,v 1.8 2000/07/01 20:06:14 tom Exp $
.\" $Id: curs_refresh.3x,v 1.10 2001/11/03 18:57:12 tom Exp $
.TH curs_refresh 3X ""
.SH NAME
\fBrefresh\fR,
\fBwrefresh\fR,
\fBwnoutrefresh\fR,
\fBdoupdate\fR,
\fBredrawwin\fR,
\fBwredrawln\fR - refresh \fBcurses\fR windows and lines
\fBrefresh\fR,
\fBwnoutrefresh\fR,
\fBwredrawln\fR,
\fBwrefresh\fR - refresh \fBcurses\fR windows and lines
.SH SYNOPSIS
\fB#include <curses.h>\fR
@ -53,15 +53,19 @@
.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
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 in order to do optimizations. The \fBrefresh\fR routine is the
same, using \fBstdscr\fR as the default window. Unless \fBleaveok\fR has been
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
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.
@ -69,21 +73,26 @@ 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
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
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
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
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
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
@ -101,9 +110,11 @@ 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
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
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)

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_scroll.3x,v 1.8 2000/07/01 17:54:23 tom Exp $
.\" $Id: curs_scroll.3x,v 1.9 2001/10/14 00:51:56 tom Exp $
.TH curs_scroll 3X ""
.SH NAME
\fBscroll\fR, \fBscrl\fR, \fBwscrl\fR - scroll a \fBcurses\fR window
@ -40,15 +40,19 @@
\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
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.
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
@ -59,8 +63,9 @@ 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, in order to leave open the possibility of smarter
"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

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,11 +26,19 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_termattrs.3x,v 1.6 2000/07/08 12:53:34 tom Exp $
.\" $Id: curs_termattrs.3x,v 1.8 2002/05/11 21:32:26 tom Exp $
.TH curs_termattrs 3X ""
.SH NAME
\fBbaudrate\fR, \fBerasechar\fR, \fBhas_ic\fR,
\fBhas_il\fR, \fBkillchar\fR, \fBlongname\fR, \fBtermattrs\fR,
\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 <curses.h>\fR
@ -39,15 +47,21 @@
.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 termattrs(void);\fR
\fBattr_t term_attrs(void);\fR
.br
\fBchtype termattrs(void);\fR
.br
\fBchar *termname(void);\fR
.br
@ -58,6 +72,11 @@ integer.
The \fBerasechar\fR routine returns the user's current erase character.
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.
The \fBhas_ic\fR routine is true if the terminal has insert- and delete-
character capabilities.
@ -68,6 +87,11 @@ scrolling using \fBscrollok\fR.
The \fBkillchar\fR routine returns the user's current line kill character.
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.
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
@ -79,9 +103,11 @@ terminals.
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 function
returns a logical \fBOR\fR of all video attributes supported by the
terminal. This information is useful when a \fBcurses\fR program
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.
The \fBtermname\fR routine returns the value of the environmental

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_termcap.3x,v 1.14 2000/12/02 22:47:14 tom Exp $
.\" $Id: curs_termcap.3x,v 1.16 2002/02/16 19:26:41 tom Exp $
.TH curs_termcap 3X ""
.ds n 5
.SH NAME
@ -41,6 +41,11 @@
.br
\fB#include <term.h>\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
@ -89,6 +94,21 @@ 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
@ -117,6 +137,17 @@ 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).
.\"#

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1999,2000 Free Software Foundation, Inc. *
.\" Copyright (c) 1999-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 *
@ -26,57 +26,65 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_terminfo.3x,v 1.14 2000/12/03 00:07:23 tom Exp $
.\" $Id: curs_terminfo.3x,v 1.15 2002/05/11 21:19:29 tom Exp $
.TH curs_terminfo 3X ""
.ds n 5
.SH NAME
\fBsetupterm\fR,
\fBsetterm\fR,
\fBset_curterm\fR,
\fBdel_curterm\fR,
\fBrestartterm\fR,
\fBtparm\fR,
\fBtputs\fR,
\fBputp\fR,
\fBvidputs\fR,
\fBvidattr\fR,
\fBmvcur\fR,
\fBputp\fR,
\fBrestartterm\fR,
\fBset_curterm\fR,
\fBsetterm\fR,
\fBsetupterm\fR,
\fBtigetflag\fR,
\fBtigetnum\fR,
\fBtigetstr\fR - \fBcurses\fR interfaces to terminfo database
\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 <curses.h>\fR
.br
\fB#include <term.h>\fR
\fBint setupterm(const char *term, int fildes, int *errret);\fR
\fBint setupterm(const char *\fR\fIterm\fR\fB, int \fR\fIfildes\fR\fB, int *\fR\fIerrret\fR\fB);\fR
.br
\fBint setterm(const char *term);\fR
\fBint setterm(const char *\fR\fIterm\fR\fB);\fR
.br
\fBTERMINAL *set_curterm(TERMINAL *nterm);\fR
\fBTERMINAL *set_curterm(TERMINAL *\fR\fInterm\fR\fB);\fR
.br
\fBint del_curterm(TERMINAL *oterm);\fR
\fBint del_curterm(TERMINAL *\fR\fIoterm\fR\fB);\fR
.br
\fBint restartterm(const char *term, int fildes, int *errret);\fR
\fBint restartterm(const char *\fR\fIterm\fR\fB, int \fR\fIfildes\fR\fB, int *\fR\fIerrret\fR\fB);\fR
.br
\fBchar *tparm(const char *str, ...);\fR
\fBchar *tparm(const char *\fR\fIstr\fR\fB, ...);\fR
.br
\fBint tputs(const char *str, int affcnt, int (*putc)(int));\fR
\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 *str);\fR
\fBint putp(const char *\fR\fIstr\fR\fB);\fR
.br
\fBint vidputs(chtype attrs, int (*putc)(char));\fR
\fBint vidputs(chtype \fR\fIattrs\fR\fB, int (*\fR\fIputc\fR\fB)(char));\fR
.br
\fBint vidattr(chtype attrs);\fR
\fBint vidattr(chtype \fR\fIattrs\fR\fB);\fR
.br
\fBint mvcur(int oldrow, int oldcol, int newrow, int newcol);\fR
\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 tigetflag(const char *capname);\fR
\fBint vid_attr(attr_t \fR\fIattrs\fR\fB, short \fR\fIpair\fR\fB, void *\fR\fIopts\fR\fB);\fR
.br
\fBint tigetnum(const char *capname);\fR
\fBint mvcur(int \fR\fIoldrow\fR\fB, int \fR\fIoldcol\fR\fB, int \fR\fInewrow\fR, int \fR\fInewcol\fR\fB);\fR
.br
\fBchar *tigetstr(const char *capname);\fR
\fBint tigetflag(const char *\fR\fIcapname\fR\fB);\fR
.br
\fBint tigetnum(const char *\fR\fIcapname\fR\fB);\fR
.br
\fBchar *tigetstr(const 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
@ -196,6 +204,17 @@ the \fBputchar\fR-like routine \fIputc\fR.
The \fBvidattr\fR routine is like the \fBvidputs\fR routine, except
that it outputs through \fBputchar\fR.
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.
The \fBmvcur\fR routine provides low-level cursor motion. It takes
effect immediately (rather than at the next refresh).

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 2000 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_trace.3x,v 1.3 2000/07/29 16:34:24 tom Exp $
.\" $Id: curs_trace.3x,v 1.5 2002/02/16 22:39:52 tom Exp $
.TH curs_trace 3X ""
.SH NAME
\fB_tracef\fR,
@ -131,7 +131,6 @@ 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.

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,22 +26,33 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: curs_util.3x,v 1.6 1998/03/11 21:12:53 juergen Exp $
.\" $Id: curs_util.3x,v 1.8 2002/02/23 22:55:47 tom Exp $
.TH curs_util 3X ""
.SH NAME
\fBunctrl\fR, \fBkeyname\fR, \fBfilter\fR,
\fBuse_env\fR, \fBputwin\fR, \fBgetwin\fR, \fBdelay_output\fR,
\fBflushinp\fR - miscellaneous \fBcurses\fR utility routines
\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 <curses.h>\fR
\fBchar *unctrl(chtype c);\fR
.br
\fBchar *wunctrl(wchar_t w);\fR
.br
\fBchar *keyname(int c);\fR
.br
\fBchar *key_name(wchar_t w);\fR
.br
\fBvoid filter(void);\fR
.br
\fBvoid use_env(char bool);\fR
\fBvoid use_env(bool f);\fR
.br
\fBint putwin(WINDOW *win, FILE *filep);\fR
.br
@ -52,12 +63,22 @@
\fBint flushinp(void);\fR
.br
.SH DESCRIPTION
The \fBunctrl\fR macro expands to a character string which is a printable
representation of the character \fIc\fR. Control characters are displayed in
the \fB^\fR\fIX\fR notation. Printing characters are displayed as is.
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.
The \fBkeyname\fR routine returns a character string corresponding to
the key \fIc\fR.
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
"UNKNOWN STRING".
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 "UNKNOWN STRING" where the former would display a meta character.
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
@ -98,12 +119,12 @@ upon failure and \fBOK\fR (SVr4 specifies only "an integer value other than
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.
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).
.SH NOTES
Note that \fBunctrl\fR is a macro, which is defined in <\fBunctrl.h\fR>.
.SH SEE ALSO
\fBcurses\fR(3X), \fBcurs_initscr\fR(3X), \fBcurs_scr_dump\fR(3X).
.\"#

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -28,20 +28,17 @@
.\"
.\" Author: Thomas E. Dickey <dickey@clark.net> 1997,1999,2000
.\"
.\" $Id: default_colors.3x,v 1.13 2000/07/15 22:06:50 tom Exp $
.\" $Id: default_colors.3x,v 1.16 2002/02/16 22:39:52 tom Exp $
.TH default_colors 3X ""
.SH NAME
\fBdefault_colors\fR:
\fBuse_default_colors\fR,
\fBassume_default_colors\fR \- use terminal's default colors
..
.SH SYNOPSIS
\fB#include <curses.h>\fP
\fBint use_default_colors(void);\fP
.br
\fBint assume_default_colors(int fg, int bg);\fP
..
.SH DESCRIPTION
The
.I use_default_colors()
@ -100,28 +97,23 @@ 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).

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -28,16 +28,14 @@
.\"
.\" Author: Thomas E. Dickey <dickey@clark.net> 1997
.\"
.\" $Id: define_key.3x,v 1.6 1999/02/19 11:43:17 tom Exp $
.\" $Id: define_key.3x,v 1.8 2002/02/16 22:39:52 tom Exp $
.TH define_key 3X ""
.SH NAME
\fBdefine_key\fP \- define a keycode
..
.SH SYNOPSIS
\fB#include <curses.h>\fP
\fBint define_key(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
@ -48,18 +46,14 @@ 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.
.\"#

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form.3x,v 1.13 1999/07/10 21:53:03 tom Exp $
.\" $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
@ -177,7 +177,7 @@ No fields are connected to the form.
\fBE_REQUEST_DENIED\fR
The form driver could not process the request.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header files

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: form_driver.3x,v 1.7 1999/07/10 23:13:18 tom Exp $
.\" $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

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_field_attributes.3x,v 1.5 1998/11/29 01:06:02 Rick.Ohnemus Exp $
.\" $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
@ -44,7 +44,7 @@ chtype field_back(const FIELD *field);
.br
int set_field_pad(FIELD *field, int pad);
.br
chtype field_pad(const FIELD *field);
int field_pad(const FIELD *field);
.br
.SH DESCRIPTION
The function \fBset_field_fore\fR sets the foreground attribute of
@ -72,7 +72,7 @@ System error occurred (see \fBerrno\fR).
\fBE_BAD_ARGUMENT\fR
Routine detected an incorrect or out-of-range argument.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header file

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_field_buffer.3x,v 1.8 1999/06/16 00:37:09 juergen Exp $
.\" $Id: form_field_buffer.3x,v 1.9 2002/01/19 22:48:23 tom Exp $
.TH form_field_buffer 3X ""
.SH NAME
\fBform_field_buffer\fR - field buffer control
@ -80,7 +80,7 @@ System error occurred (see \fBerrno\fR).
\fBE_BAD_ARGUMENT\fR
Routine detected an incorrect or out-of-range argument.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header file

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_field_info.3x,v 1.6 2000/04/15 22:21:31 tom Exp $
.\" $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
@ -37,7 +37,7 @@
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, *max);
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
@ -61,7 +61,7 @@ System error occurred (see \fBerrno\fR).
\fBE_BAD_ARGUMENT\fR
Routine detected an incorrect or out-of-range argument.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header file

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_field_just.3x,v 1.5 1998/11/29 01:06:32 Rick.Ohnemus Exp $
.\" $Id: form_field_just.3x,v 1.6 2002/01/19 22:48:41 tom Exp $
.TH form_field_just 3X ""
.SH NAME
\fBform_field_just\fR - retrieve field characteristics
@ -59,7 +59,7 @@ System error occurred (see \fBerrno\fR).
\fBE_BAD_ARGUMENT\fR
Routine detected an incorrect or out-of-range argument.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header file

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: form_field_new.3x,v 1.9 1998/11/29 01:06:44 Rick.Ohnemus Exp $
.\" $Id: form_field_new.3x,v 1.11 2002/02/16 22:39:52 tom Exp $
.TH form_field_new 3X ""
.SH NAME
\fBform_field_new\fR - create and destroy form fields

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: form_field_validation.3x,v 1.10 1998/03/11 21:12:53 juergen Exp $
.\" $Id: form_field_validation.3x,v 1.12 2002/02/16 22:39:52 tom Exp $
.TH form_field_validation 3X ""
.SH NAME
\fBform_field_validation\fR - data type validation for fields

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_fieldtype.3x,v 1.8 2000/07/15 22:02:03 tom Exp $
.\" $Id: form_fieldtype.3x,v 1.9 2001/08/04 20:36:25 William.Setzer Exp $
.TH form_fieldtype 3X ""
.SH NAME
\fBform_fieldtype\fR - define validation-field types
@ -47,7 +47,7 @@ int set_fieldtype_arg(
void (* const free_arg)(void *));
.br
int set_fieldtype_choice(
FIELDTYPE *fieldtype
FIELDTYPE *fieldtype,
bool (* const next_choice)(FIELD *, const void *),
bool (* const prev_choice)(FIELD *, const void *));
.br

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: form_new_page.3x,v 1.5 1998/11/29 01:07:45 Rick.Ohnemus Exp $
.\" $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
@ -58,7 +58,7 @@ System error occurred (see \fBerrno\fR).
\fBE_CONNECTED\fR
The given field is already connected to a form.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "form_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "form_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<form.h>\fR automatically includes the header file

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: infocmp.1m,v 1.27 2000/08/19 18:51:05 tom Exp $
.\" $Id: infocmp.1m,v 1.29 2002/02/16 22:40:59 tom Exp $
.TH infocmp 1M ""
.ds n 5
.ds d @TERMINFO@
@ -46,12 +46,10 @@ terminfo entries, rewrite a \fBterminfo\fR description to take advantage of 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
@ -72,7 +70,6 @@ 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.
@ -166,7 +163,6 @@ 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
@ -178,11 +174,9 @@ 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 [-s d|i|l|c] [-1FTVefip] [-Rsubset] [-v \fIn\fR] [-w \fIwidth\fR]
The \fB-s\fR option sorts the fields within each type according to the argument
below:
..
.TP 5
\fBd\fR
leave fields in the order that they are stored in the \fIterminfo\fR database.
@ -334,12 +328,10 @@ 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,

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1999 Free Software Foundation, Inc. *
.\" Copyright (c) 1999,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 *
@ -28,35 +28,29 @@
.\"
.\" Author: Thomas E. Dickey <dickey@clark.net> 1999
.\"
.\" $Id: keybound.3x,v 1.1 1999/02/19 11:59:24 tom Exp $
.\" $Id: keybound.3x,v 1.3 2002/02/16 22:30:36 tom Exp $
.TH keyok 3X ""
.SH NAME
\fBkeybound\fP \- return definition of keycode
..
.SH SYNOPSIS
\fB#include <curses.h>\fP
\fBint keybound(int keycode, int count);\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 keycode must be greater than zero, else NULL is returned.
If it does not correspond to a defined key, then NULL is returned.
Otherwise, 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.
.\"#

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -28,37 +28,31 @@
.\"
.\" Author: Thomas E. Dickey <dickey@clark.net> 1997
.\"
.\" $Id: keyok.3x,v 1.5 1998/03/14 23:43:07 tom Exp $
.\" $Id: keyok.3x,v 1.7 2002/02/16 22:40:59 tom Exp $
.TH keyok 3X ""
.SH NAME
\fBkeyok\fP \- enable or disable a keycode
..
.SH SYNOPSIS
\fB#include <curses.h>\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.
.\"#

View File

@ -1,30 +1,44 @@
# $Id: man_db.renames,v 0.20 2000/07/15 22:58:35 tom Exp $
# $Id: man_db.renames,v 0.31 2002/04/13 21:49:08 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
@ -115,3 +129,10 @@ 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

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998,2000 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: menu.3x,v 1.14 2000/07/15 22:55:59 tom Exp $
.\" $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
@ -167,7 +167,7 @@ No items are connected to the menu.
\fBE_REQUEST_DENIED\fR
The menu driver could not process the request.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "menu_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "menu_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<menu.h>\fR automatically includes the header files

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: menu_attributes.3x,v 1.6 1998/11/29 01:09:20 Rick.Ohnemus Exp $
.\" $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
@ -81,7 +81,7 @@ System error occurred (see \fBerrno\fR).
\fBE_BAD_ARGUMENT\fR
Routine detected an incorrect or out-of-range argument.
.SH SEE ALSO
\fBcurses\fR(3X) and 3X pages whose names begin "menu_" for detailed
\fBcurses\fR(3X) and related pages whose names begin "menu_" for detailed
descriptions of the entry points.
.SH NOTES
The header file \fB<menu.h>\fR automatically includes the header file

View File

@ -1,5 +1,5 @@
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -26,7 +26,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.'" $Id: menu_driver.3x,v 1.8 1999/01/09 22:55:18 tom Exp $
.\" $Id: menu_driver.3x,v 1.10 2002/02/16 22:40:59 tom Exp $
.TH menu_driver 3X ""
.SH NAME
\fBmenu_driver\fR - command-processing loop of the menu system

View File

@ -1,6 +1,6 @@
'\" t
.\"***************************************************************************
.\" Copyright (c) 1998 Free Software Foundation, Inc. *
.\" 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 *
@ -27,7 +27,7 @@
.\" authorization. *
.\"***************************************************************************
.\"
.\" $Id: menu_format.3x,v 1.7 1998/11/29 01:09:39 Rick.Ohnemus Exp $
.\" $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
@ -36,7 +36,7 @@
.br
int set_menu_format(MENU *menu, int rows, int cols);
.br
int menu_format(const MENU *menu, int *rows, int *cols);
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

Some files were not shown because too many files have changed in this diff Show More