| form.h | | form.h | |
| /**************************************************************************
** | | /**************************************************************************
** | |
|
| * Copyright (c) 1998 Free Software Foundation, Inc.
* | | * Copyright (c) 1998,2000 Free Software Foundation, Inc.
* | |
| *
* | | *
* | |
| * Permission is hereby granted, free of charge, to any person obtaining a
* | | * Permission is hereby granted, free of charge, to any person obtaining a
* | |
| * copy of this software and associated documentation files (the
* | | * copy of this software and associated documentation files (the
* | |
| * "Software"), to deal in the Software without restriction, including
* | | * "Software"), to deal in the Software without restriction, including
* | |
| * without limitation the rights to use, copy, modify, merge, publish,
* | | * without limitation the rights to use, copy, modify, merge, publish,
* | |
| * distribute, distribute with modifications, sublicense, and/or sell
* | | * distribute, distribute with modifications, sublicense, and/or sell
* | |
| * copies of the Software, and to permit persons to whom the Software is
* | | * copies of the Software, and to permit persons to whom the Software is
* | |
| * furnished to do so, subject to the following conditions:
* | | * furnished to do so, subject to the following conditions:
* | |
| *
* | | *
* | |
| * The above copyright notice and this permission notice shall be included
* | | * The above copyright notice and this permission notice shall be included
* | |
| | | | |
| skipping to change at line 30 | | skipping to change at line 30 | |
| * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | | * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | |
| * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | | * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | |
| *
* | | *
* | |
| * Except as contained in this notice, the name(s) of the above copyright
* | | * Except as contained in this notice, the name(s) of the above copyright
* | |
| * holders shall not be used in advertising or otherwise to promote the
* | | * holders shall not be used in advertising or otherwise to promote the
* | |
| * sale, use or other dealings in this Software without prior written
* | | * sale, use or other dealings in this Software without prior written
* | |
| * authorization.
* | | * authorization.
* | |
| **************************************************************************
**/ | | **************************************************************************
**/ | |
| | | | |
| /**************************************************************************
** | | /**************************************************************************
** | |
|
| * Author: Juergen Pfeifer <Juergen.Pfeifer@T-Online.de> 1995,1997 | | * Author: Juergen Pfeifer, 1995,1997 | |
| * | | * | |
| | | * Contact: http://www.familiepfeifer.de/Contact.aspx?Lang=en | |
| | | * | |
| **************************************************************************
**/ | | **************************************************************************
**/ | |
| | | | |
| #ifndef FORM_H | | #ifndef FORM_H | |
| #define FORM_H | | #define FORM_H | |
| | | | |
|
| #include <curses.h> | | #include <ncurses/curses.h> | |
| #include <eti.h> | | #include <ncurses/eti.h> | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| extern "C" { | | extern "C" { | |
| #endif | | #endif | |
| | | | |
| typedef int Form_Options; | | typedef int Form_Options; | |
| typedef int Field_Options; | | typedef int Field_Options; | |
| | | | |
| /********** | | /********** | |
| * _PAGE * | | * _PAGE * | |
| | | | |
| skipping to change at line 249 | | skipping to change at line 250 | |
| # elif (MAX_COMMAND != (KEY_MAX + 128)) | | # elif (MAX_COMMAND != (KEY_MAX + 128)) | |
| # error Something is wrong -- MAX_COMMAND is already inconsistently defi
ned. | | # error Something is wrong -- MAX_COMMAND is already inconsistently defi
ned. | |
| # endif | | # endif | |
| #else | | #else | |
| # define MAX_COMMAND (KEY_MAX + 128) | | # define MAX_COMMAND (KEY_MAX + 128) | |
| #endif | | #endif | |
| | | | |
| /************************* | | /************************* | |
| * standard field types * | | * standard field types * | |
| *************************/ | | *************************/ | |
|
| extern FIELDTYPE *TYPE_ALPHA, | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_ALPHA; | |
| *TYPE_ALNUM, | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_ALNUM; | |
| *TYPE_ENUM, | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_ENUM; | |
| *TYPE_INTEGER, | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_INTEGER; | |
| *TYPE_NUMERIC, | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_NUMERIC; | |
| *TYPE_REGEXP; | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_REGEXP; | |
| | | | |
| /************************************ | | /************************************ | |
| * built-in additional field types * | | * built-in additional field types * | |
| * They are not defined in SVr4 * | | * They are not defined in SVr4 * | |
| ************************************/ | | ************************************/ | |
|
| extern FIELDTYPE *TYPE_IPV4; /* Internet IP Version 4 address */ | | extern NCURSES_EXPORT_VAR(FIELDTYPE *) TYPE_IPV4; /* Internet IP Versi
on 4 address */ | |
| | | | |
| /*********************** | | /*********************** | |
| * Default objects * | | * Default objects * | |
| ***********************/ | | ***********************/ | |
|
| extern FORM *_nc_Default_Form; | | extern NCURSES_EXPORT_VAR(FORM *) _nc_Default_Form; | |
| extern FIELD *_nc_Default_Field; | | extern NCURSES_EXPORT_VAR(FIELD *) _nc_Default_Field; | |
| | | | |
| /*********************** | | /*********************** | |
| * FIELDTYPE routines * | | * FIELDTYPE routines * | |
| ***********************/ | | ***********************/ | |
|
| extern FIELDTYPE | | extern NCURSES_EXPORT(FIELDTYPE *) new_fieldtype ( | |
| *new_fieldtype( | | | |
| bool (* const field_check)(FIELD *,const void *), | | bool (* const field_check)(FIELD *,const void *), | |
| bool (* const char_check)(int,const void *)), | | bool (* const char_check)(int,const void *)), | |
| *link_fieldtype(FIELDTYPE *,FIELDTYPE *); | | *link_fieldtype(FIELDTYPE *,FIELDTYPE *); | |
| | | | |
|
| extern int free_fieldtype(FIELDTYPE *), | | extern NCURSES_EXPORT(int) free_fieldtype (FIELDTYPE *); | |
| set_fieldtype_arg(FIELDTYPE *, | | extern NCURSES_EXPORT(int) set_fieldtype_arg (FIELDTYPE *, | |
| void * (* const make_arg)(va_list *), | | void * (* const make_arg)(va_list *), | |
| void * (* const copy_arg)(const void *), | | void * (* const copy_arg)(const void *), | |
|
| void (* const free_arg)(void *)), | | void (* const free_arg)(void *)); | |
| set_fieldtype_choice (FIELDTYPE *, | | extern NCURSES_EXPORT(int) set_fieldtype_choice (FIELDTYPE *, | |
| bool (* const next_choice)(FIELD *,const void *), | | bool (* const next_choice)(FIELD *,const void *), | |
| bool (* const prev_choice)(FIELD *,const void *)); | | bool (* const prev_choice)(FIELD *,const void *)); | |
| | | | |
| /******************* | | /******************* | |
| * FIELD routines * | | * FIELD routines * | |
| *******************/ | | *******************/ | |
|
| extern FIELD *new_field(int,int,int,int,int,int), | | extern NCURSES_EXPORT(FIELD *) new_field (int,int,int,int,int,int); | |
| *dup_field(FIELD *,int,int), | | extern NCURSES_EXPORT(FIELD *) dup_field (FIELD *,int,int); | |
| *link_field(FIELD *,int,int); | | extern NCURSES_EXPORT(FIELD *) link_field (FIELD *,int,int); | |
| | | | |
|
| extern int free_field(FIELD *), | | extern NCURSES_EXPORT(int) free_field (FIELD *); | |
| field_info(const FIELD *,int *,int *,int *,int *,int *,int | | extern NCURSES_EXPORT(int) field_info (const FIELD *,int *,int *,int *, | |
| *), | | int *,int *,int *); | |
| dynamic_field_info(const FIELD *,int *,int *,int *), | | extern NCURSES_EXPORT(int) dynamic_field_info (const FIELD *,int *,int | |
| set_max_field( FIELD *,int), | | *,int *); | |
| move_field(FIELD *,int,int), | | extern NCURSES_EXPORT(int) set_max_field ( FIELD *,int); | |
| set_field_type(FIELD *,FIELDTYPE *,...), | | extern NCURSES_EXPORT(int) move_field (FIELD *,int,int); | |
| set_new_page(FIELD *,bool), | | extern NCURSES_EXPORT(int) set_field_type (FIELD *,FIELDTYPE *,...); | |
| set_field_just(FIELD *,int), | | extern NCURSES_EXPORT(int) set_new_page (FIELD *,bool); | |
| field_just(const FIELD *), | | extern NCURSES_EXPORT(int) set_field_just (FIELD *,int); | |
| set_field_fore(FIELD *,chtype), | | extern NCURSES_EXPORT(int) field_just (const FIELD *); | |
| set_field_back(FIELD *,chtype), | | extern NCURSES_EXPORT(int) set_field_fore (FIELD *,chtype); | |
| set_field_pad(FIELD *,int), | | extern NCURSES_EXPORT(int) set_field_back (FIELD *,chtype); | |
| field_pad(const FIELD *), | | extern NCURSES_EXPORT(int) set_field_pad (FIELD *,int); | |
| set_field_buffer(FIELD *,int,const char *), | | extern NCURSES_EXPORT(int) field_pad (const FIELD *); | |
| set_field_status(FIELD *,bool), | | extern NCURSES_EXPORT(int) set_field_buffer (FIELD *,int,const char *); | |
| set_field_userptr(FIELD *, void *), | | extern NCURSES_EXPORT(int) set_field_status (FIELD *,bool); | |
| set_field_opts(FIELD *,Field_Options), | | extern NCURSES_EXPORT(int) set_field_userptr (FIELD *, void *); | |
| field_opts_on(FIELD *,Field_Options), | | extern NCURSES_EXPORT(int) set_field_opts (FIELD *,Field_Options); | |
| field_opts_off(FIELD *,Field_Options); | | extern NCURSES_EXPORT(int) field_opts_on (FIELD *,Field_Options); | |
| | | extern NCURSES_EXPORT(int) field_opts_off (FIELD *,Field_Options); | |
| | | | |
|
| extern chtype field_fore(const FIELD *), | | extern NCURSES_EXPORT(chtype) field_fore (const FIELD *); | |
| field_back(const FIELD *); | | extern NCURSES_EXPORT(chtype) field_back (const FIELD *); | |
| | | | |
|
| extern bool new_page(const FIELD *), | | extern NCURSES_EXPORT(bool) new_page (const FIELD *); | |
| field_status(const FIELD *); | | extern NCURSES_EXPORT(bool) field_status (const FIELD *); | |
| | | | |
|
| extern void *field_arg(const FIELD *); | | extern NCURSES_EXPORT(void *) field_arg (const FIELD *); | |
| | | | |
|
| extern void *field_userptr(const FIELD *); | | extern NCURSES_EXPORT(void *) field_userptr (const FIELD *); | |
| | | | |
|
| extern FIELDTYPE | | extern NCURSES_EXPORT(FIELDTYPE *) field_type (const FIELD *); | |
| *field_type(const FIELD *); | | | |
| | | | |
|
| extern char* field_buffer(const FIELD *,int); | | extern NCURSES_EXPORT(char *) field_buffer (const FIELD *,int); | |
| | | | |
|
| extern Field_Options | | extern NCURSES_EXPORT(Field_Options) field_opts (const FIELD *); | |
| field_opts(const FIELD *); | | | |
| | | | |
| /****************** | | /****************** | |
| * FORM routines * | | * FORM routines * | |
| ******************/ | | ******************/ | |
|
| extern FORM *new_form(FIELD **); | | | |
| | | | |
|
| extern FIELD **form_fields(const FORM *), | | extern NCURSES_EXPORT(FORM *) new_form (FIELD **); | |
| *current_field(const FORM *); | | | |
| | | | |
|
| extern WINDOW *form_win(const FORM *), | | extern NCURSES_EXPORT(FIELD **) form_fields (const FORM *); | |
| *form_sub(const FORM *); | | extern NCURSES_EXPORT(FIELD *) current_field (const FORM *); | |
| | | | |
|
| extern Form_Hook | | extern NCURSES_EXPORT(WINDOW *) form_win (const FORM *); | |
| form_init(const FORM *), | | extern NCURSES_EXPORT(WINDOW *) form_sub (const FORM *); | |
| form_term(const FORM *), | | | |
| field_init(const FORM *), | | | |
| field_term(const FORM *); | | | |
| | | | |
|
| extern int free_form(FORM *), | | extern NCURSES_EXPORT(Form_Hook) form_init (const FORM *); | |
| set_form_fields(FORM *,FIELD **), | | extern NCURSES_EXPORT(Form_Hook) form_term (const FORM *); | |
| field_count(const FORM *), | | extern NCURSES_EXPORT(Form_Hook) field_init (const FORM *); | |
| set_form_win(FORM *,WINDOW *), | | extern NCURSES_EXPORT(Form_Hook) field_term (const FORM *); | |
| set_form_sub(FORM *,WINDOW *), | | | |
| set_current_field(FORM *,FIELD *), | | | |
| field_index(const FIELD *), | | | |
| set_form_page(FORM *,int), | | | |
| form_page(const FORM *), | | | |
| scale_form(const FORM *,int *,int *), | | | |
| set_form_init(FORM *,Form_Hook), | | | |
| set_form_term(FORM *,Form_Hook), | | | |
| set_field_init(FORM *,Form_Hook), | | | |
| set_field_term(FORM *,Form_Hook), | | | |
| post_form(FORM *), | | | |
| unpost_form(FORM *), | | | |
| pos_form_cursor(FORM *), | | | |
| form_driver(FORM *,int), | | | |
| set_form_userptr(FORM *,void *), | | | |
| set_form_opts(FORM *,Form_Options), | | | |
| form_opts_on(FORM *,Form_Options), | | | |
| form_opts_off(FORM *,Form_Options), | | | |
| form_request_by_name(const char *); | | | |
| | | | |
|
| extern const char | | extern NCURSES_EXPORT(int) free_form (FORM *); | |
| *form_request_name(int); | | extern NCURSES_EXPORT(int) set_form_fields (FORM *,FIELD **); | |
| | | extern NCURSES_EXPORT(int) field_count (const FORM *); | |
| | | extern NCURSES_EXPORT(int) set_form_win (FORM *,WINDOW *); | |
| | | extern NCURSES_EXPORT(int) set_form_sub (FORM *,WINDOW *); | |
| | | extern NCURSES_EXPORT(int) set_current_field (FORM *,FIELD *); | |
| | | extern NCURSES_EXPORT(int) field_index (const FIELD *); | |
| | | extern NCURSES_EXPORT(int) set_form_page (FORM *,int); | |
| | | extern NCURSES_EXPORT(int) form_page (const FORM *); | |
| | | extern NCURSES_EXPORT(int) scale_form (const FORM *,int *,int *); | |
| | | extern NCURSES_EXPORT(int) set_form_init (FORM *,Form_Hook); | |
| | | extern NCURSES_EXPORT(int) set_form_term (FORM *,Form_Hook); | |
| | | extern NCURSES_EXPORT(int) set_field_init (FORM *,Form_Hook); | |
| | | extern NCURSES_EXPORT(int) set_field_term (FORM *,Form_Hook); | |
| | | extern NCURSES_EXPORT(int) post_form (FORM *); | |
| | | extern NCURSES_EXPORT(int) unpost_form (FORM *); | |
| | | extern NCURSES_EXPORT(int) pos_form_cursor (FORM *); | |
| | | extern NCURSES_EXPORT(int) form_driver (FORM *,int); | |
| | | extern NCURSES_EXPORT(int) set_form_userptr (FORM *,void *); | |
| | | extern NCURSES_EXPORT(int) set_form_opts (FORM *,Form_Options); | |
| | | extern NCURSES_EXPORT(int) form_opts_on (FORM *,Form_Options); | |
| | | extern NCURSES_EXPORT(int) form_opts_off (FORM *,Form_Options); | |
| | | extern NCURSES_EXPORT(int) form_request_by_name (const char *); | |
| | | | |
|
| extern void *form_userptr(const FORM *); | | extern NCURSES_EXPORT(const char *) form_request_name (int); | |
| | | | |
|
| extern Form_Options | | extern NCURSES_EXPORT(void *) form_userptr (const FORM *); | |
| form_opts(const FORM *); | | | |
| | | | |
|
| extern bool data_ahead(const FORM *), | | extern NCURSES_EXPORT(Form_Options) form_opts (const FORM *); | |
| data_behind(const FORM *); | | | |
| | | extern NCURSES_EXPORT(bool) data_ahead (const FORM *); | |
| | | extern NCURSES_EXPORT(bool) data_behind (const FORM *); | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| } | | } | |
| #endif | | #endif | |
| | | | |
| #endif /* FORM_H */ | | #endif /* FORM_H */ | |
| | | | |
End of changes. 27 change blocks. |
| 94 lines changed or deleted | | 92 lines changed or added | |
|
| menu.h | | menu.h | |
| /**************************************************************************
** | | /**************************************************************************
** | |
|
| * Copyright (c) 1998 Free Software Foundation, Inc.
* | | * Copyright (c) 1998,2000 Free Software Foundation, Inc.
* | |
| *
* | | *
* | |
| * Permission is hereby granted, free of charge, to any person obtaining a
* | | * Permission is hereby granted, free of charge, to any person obtaining a
* | |
| * copy of this software and associated documentation files (the
* | | * copy of this software and associated documentation files (the
* | |
| * "Software"), to deal in the Software without restriction, including
* | | * "Software"), to deal in the Software without restriction, including
* | |
| * without limitation the rights to use, copy, modify, merge, publish,
* | | * without limitation the rights to use, copy, modify, merge, publish,
* | |
| * distribute, distribute with modifications, sublicense, and/or sell
* | | * distribute, distribute with modifications, sublicense, and/or sell
* | |
| * copies of the Software, and to permit persons to whom the Software is
* | | * copies of the Software, and to permit persons to whom the Software is
* | |
| * furnished to do so, subject to the following conditions:
* | | * furnished to do so, subject to the following conditions:
* | |
| *
* | | *
* | |
| * The above copyright notice and this permission notice shall be included
* | | * The above copyright notice and this permission notice shall be included
* | |
| | | | |
| skipping to change at line 30 | | skipping to change at line 30 | |
| * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | | * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | |
| * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | | * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | |
| *
* | | *
* | |
| * Except as contained in this notice, the name(s) of the above copyright
* | | * Except as contained in this notice, the name(s) of the above copyright
* | |
| * holders shall not be used in advertising or otherwise to promote the
* | | * holders shall not be used in advertising or otherwise to promote the
* | |
| * sale, use or other dealings in this Software without prior written
* | | * sale, use or other dealings in this Software without prior written
* | |
| * authorization.
* | | * authorization.
* | |
| **************************************************************************
**/ | | **************************************************************************
**/ | |
| | | | |
| /**************************************************************************
** | | /**************************************************************************
** | |
|
| * Author: Juergen Pfeifer <Juergen.Pfeifer@T-Online.de> 1995,1997 | | * Author: Juergen Pfeifer, 1995,1997 | |
| * | | * | |
| | | * Contact: http://www.familiepfeifer.de/Contact.aspx?Lang=en | |
| | | * | |
| **************************************************************************
**/ | | **************************************************************************
**/ | |
| | | | |
| #ifndef ETI_MENU | | #ifndef ETI_MENU | |
| #define ETI_MENU | | #define ETI_MENU | |
| | | | |
|
| #include <curses.h> | | #ifdef AMIGA | |
| #include <eti.h> | | #define TEXT TEXT_ncurses | |
| | | #endif | |
| | | | |
| | | #include <ncurses/curses.h> | |
| | | #include <ncurses/eti.h> | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| extern "C" { | | extern "C" { | |
| #endif | | #endif | |
| | | | |
| typedef int Menu_Options; | | typedef int Menu_Options; | |
| typedef int Item_Options; | | typedef int Item_Options; | |
| | | | |
| /* Menu options: */ | | /* Menu options: */ | |
| #define O_ONEVALUE (0x01) | | #define O_ONEVALUE (0x01) | |
| | | | |
| skipping to change at line 167 | | skipping to change at line 172 | |
| # error Something is wrong -- MAX_MENU_COMMAND is greater than MAX_COMMA
ND | | # error Something is wrong -- MAX_MENU_COMMAND is greater than MAX_COMMA
ND | |
| # elif (MAX_COMMAND != (KEY_MAX + 128)) | | # elif (MAX_COMMAND != (KEY_MAX + 128)) | |
| # error Something is wrong -- MAX_COMMAND is already inconsistently defi
ned. | | # error Something is wrong -- MAX_COMMAND is already inconsistently defi
ned. | |
| # endif | | # endif | |
| #else | | #else | |
| # define MAX_COMMAND (KEY_MAX + 128) | | # define MAX_COMMAND (KEY_MAX + 128) | |
| #endif | | #endif | |
| | | | |
| /* --------- prototypes for libmenu functions -----------------------------
*/ | | /* --------- prototypes for libmenu functions -----------------------------
*/ | |
| | | | |
|
| extern ITEM **menu_items(const MENU *), | | extern NCURSES_EXPORT(ITEM **) menu_items (const MENU *); | |
| *current_item(const MENU *), | | extern NCURSES_EXPORT(ITEM *) current_item (const MENU *); | |
| *new_item(const char *,const char *); | | extern NCURSES_EXPORT(ITEM *) new_item (const char *,const char *); | |
| | | | |
|
| extern MENU *new_menu(ITEM **); | | extern NCURSES_EXPORT(MENU *) new_menu (ITEM **); | |
| | | | |
|
| extern Item_Options item_opts(const ITEM *); | | extern NCURSES_EXPORT(Item_Options) item_opts (const ITEM *); | |
| extern Menu_Options menu_opts(const MENU *); | | extern NCURSES_EXPORT(Menu_Options) menu_opts (const MENU *); | |
| | | | |
|
| Menu_Hook item_init(const MENU *), | | extern NCURSES_EXPORT(Menu_Hook) item_init (const MENU *); | |
| item_term(const MENU *), | | extern NCURSES_EXPORT(Menu_Hook) item_term (const MENU *); | |
| menu_init(const MENU *), | | extern NCURSES_EXPORT(Menu_Hook) menu_init (const MENU *); | |
| menu_term(const MENU *); | | extern NCURSES_EXPORT(Menu_Hook) menu_term (const MENU *); | |
| | | | |
|
| extern WINDOW *menu_sub(const MENU *), | | extern NCURSES_EXPORT(WINDOW *) menu_sub (const MENU *); | |
| *menu_win(const MENU *); | | extern NCURSES_EXPORT(WINDOW *) menu_win (const MENU *); | |
| | | | |
|
| extern const char *item_description(const ITEM *), | | extern NCURSES_EXPORT(const char *) item_description (const ITEM *); | |
| *item_name(const ITEM *), | | extern NCURSES_EXPORT(const char *) item_name (const ITEM *); | |
| *menu_mark(const MENU *), | | extern NCURSES_EXPORT(const char *) menu_mark (const MENU *); | |
| *menu_request_name(int); | | extern NCURSES_EXPORT(const char *) menu_request_name (int); | |
| | | | |
|
| extern char *menu_pattern(const MENU *); | | extern NCURSES_EXPORT(char *) menu_pattern (const MENU *); | |
| | | | |
|
| extern void *menu_userptr(const MENU *), | | extern NCURSES_EXPORT(void *) menu_userptr (const MENU *); | |
| *item_userptr(const ITEM *); | | extern NCURSES_EXPORT(void *) item_userptr (const ITEM *); | |
| | | | |
|
| extern chtype menu_back(const MENU *), | | extern NCURSES_EXPORT(chtype) menu_back (const MENU *); | |
| menu_fore(const MENU *), | | extern NCURSES_EXPORT(chtype) menu_fore (const MENU *); | |
| menu_grey(const MENU *); | | extern NCURSES_EXPORT(chtype) menu_grey (const MENU *); | |
| | | | |
|
| extern int free_item(ITEM *), | | extern NCURSES_EXPORT(int) free_item (ITEM *); | |
| free_menu(MENU *), | | extern NCURSES_EXPORT(int) free_menu (MENU *); | |
| item_count(const MENU *), | | extern NCURSES_EXPORT(int) item_count (const MENU *); | |
| item_index(const ITEM *), | | extern NCURSES_EXPORT(int) item_index (const ITEM *); | |
| item_opts_off(ITEM *,Item_Options), | | extern NCURSES_EXPORT(int) item_opts_off (ITEM *,Item_Options); | |
| item_opts_on(ITEM *,Item_Options), | | extern NCURSES_EXPORT(int) item_opts_on (ITEM *,Item_Options); | |
| menu_driver(MENU *,int), | | extern NCURSES_EXPORT(int) menu_driver (MENU *,int); | |
| menu_opts_off(MENU *,Menu_Options), | | extern NCURSES_EXPORT(int) menu_opts_off (MENU *,Menu_Options); | |
| menu_opts_on(MENU *,Menu_Options), | | extern NCURSES_EXPORT(int) menu_opts_on (MENU *,Menu_Options); | |
| menu_pad(const MENU *), | | extern NCURSES_EXPORT(int) menu_pad (const MENU *); | |
| pos_menu_cursor(const MENU *), | | extern NCURSES_EXPORT(int) pos_menu_cursor (const MENU *); | |
| post_menu(MENU *), | | extern NCURSES_EXPORT(int) post_menu (MENU *); | |
| scale_menu(const MENU *,int *,int *), | | extern NCURSES_EXPORT(int) scale_menu (const MENU *,int *,int *); | |
| set_current_item(MENU *menu,ITEM *item), | | extern NCURSES_EXPORT(int) set_current_item (MENU *menu,ITEM *item); | |
| set_item_init(MENU *,void(*)(MENU *)), | | extern NCURSES_EXPORT(int) set_item_init (MENU *,void(*)(MENU *)); | |
| set_item_opts(ITEM *,Item_Options), | | extern NCURSES_EXPORT(int) set_item_opts (ITEM *,Item_Options); | |
| set_item_term(MENU *,void(*)(MENU *)), | | extern NCURSES_EXPORT(int) set_item_term (MENU *,void(*)(MENU *)); | |
| set_item_userptr(ITEM *, void *), | | extern NCURSES_EXPORT(int) set_item_userptr (ITEM *, void *); | |
| set_item_value(ITEM *,bool), | | extern NCURSES_EXPORT(int) set_item_value (ITEM *,bool); | |
| set_menu_back(MENU *,chtype), | | extern NCURSES_EXPORT(int) set_menu_back (MENU *,chtype); | |
| set_menu_fore(MENU *,chtype), | | extern NCURSES_EXPORT(int) set_menu_fore (MENU *,chtype); | |
| set_menu_format(MENU *,int,int), | | extern NCURSES_EXPORT(int) set_menu_format (MENU *,int,int); | |
| set_menu_grey(MENU *,chtype), | | extern NCURSES_EXPORT(int) set_menu_grey (MENU *,chtype); | |
| set_menu_init(MENU *,void(*)(MENU *)), | | extern NCURSES_EXPORT(int) set_menu_init (MENU *,void(*)(MENU *)); | |
| set_menu_items(MENU *,ITEM **), | | extern NCURSES_EXPORT(int) set_menu_items (MENU *,ITEM **); | |
| set_menu_mark(MENU *, const char *), | | extern NCURSES_EXPORT(int) set_menu_mark (MENU *, const char *); | |
| set_menu_opts(MENU *,Menu_Options), | | extern NCURSES_EXPORT(int) set_menu_opts (MENU *,Menu_Options); | |
| set_menu_pad(MENU *,int), | | extern NCURSES_EXPORT(int) set_menu_pad (MENU *,int); | |
| set_menu_pattern(MENU *,const char *), | | extern NCURSES_EXPORT(int) set_menu_pattern (MENU *,const char *); | |
| set_menu_sub(MENU *,WINDOW *), | | extern NCURSES_EXPORT(int) set_menu_sub (MENU *,WINDOW *); | |
| set_menu_term(MENU *,void(*)(MENU *)), | | extern NCURSES_EXPORT(int) set_menu_term (MENU *,void(*)(MENU *)); | |
| set_menu_userptr(MENU *,void *), | | extern NCURSES_EXPORT(int) set_menu_userptr (MENU *,void *); | |
| set_menu_win(MENU *,WINDOW *), | | extern NCURSES_EXPORT(int) set_menu_win (MENU *,WINDOW *); | |
| set_top_row(MENU *,int), | | extern NCURSES_EXPORT(int) set_top_row (MENU *,int); | |
| top_row(const MENU *), | | extern NCURSES_EXPORT(int) top_row (const MENU *); | |
| unpost_menu(MENU *), | | extern NCURSES_EXPORT(int) unpost_menu (MENU *); | |
| menu_request_by_name(const char *), | | extern NCURSES_EXPORT(int) menu_request_by_name (const char *); | |
| set_menu_spacing(MENU *,int,int,int), | | extern NCURSES_EXPORT(int) set_menu_spacing (MENU *,int,int,int); | |
| menu_spacing(const MENU *,int *,int *,int *); | | extern NCURSES_EXPORT(int) menu_spacing (const MENU *,int *,int *,int * | |
| | | ); | |
| | | | |
|
| extern bool item_value(const ITEM *), | | extern NCURSES_EXPORT(bool) item_value (const ITEM *); | |
| item_visible(const ITEM *); | | extern NCURSES_EXPORT(bool) item_visible (const ITEM *); | |
| | | | |
|
| void menu_format(const MENU *,int *,int *); | | extern NCURSES_EXPORT(void) menu_format (const MENU *,int *,int *); | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| } | | } | |
| #endif | | #endif | |
| | | | |
| #endif /* ETI_MENU */ | | #endif /* ETI_MENU */ | |
| | | | |
End of changes. 15 change blocks. |
| 69 lines changed or deleted | | 76 lines changed or added | |
|
| term.h | | term.h | |
| /**************************************************************************
** | | /**************************************************************************
** | |
|
| * Copyright (c) 1998 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
* | | * Permission is hereby granted, free of charge, to any person obtaining a
* | |
| * copy of this software and associated documentation files (the
* | | * copy of this software and associated documentation files (the
* | |
|
| * ), to deal in the Software without restriction, including * | | * "Software"), to deal in the Software without restriction, including
* | |
| * without limitation the rights to use, copy, modify, merge, publish,
* | | * without limitation the rights to use, copy, modify, merge, publish,
* | |
| * distribute, distribute with modifications, sublicense, and/or sell
* | | * distribute, distribute with modifications, sublicense, and/or sell
* | |
| * copies of the Software, and to permit persons to whom the Software is
* | | * copies of the Software, and to permit persons to whom the Software is
* | |
| * furnished to do so, subject to the following conditions:
* | | * furnished to do so, subject to the following conditions:
* | |
| *
* | | *
* | |
| * The above copyright notice and this permission notice shall be included
* | | * The above copyright notice and this permission notice shall be included
* | |
| * in all copies or substantial portions of the Software.
* | | * in all copies or substantial portions of the Software.
* | |
| *
* | | *
* | |
|
| * THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND, EXPRESS * | | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* | |
| * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* | | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* | |
| * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* | | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* | |
| * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* | | * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* | |
| * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
* | | * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
* | |
| * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | | * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
* | |
| * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | | * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* | |
| *
* | | *
* | |
| * Except as contained in this notice, the name(s) of the above copyright
* | | * Except as contained in this notice, the name(s) of the above copyright
* | |
| * holders shall not be used in advertising or otherwise to promote the
* | | * holders shall not be used in advertising or otherwise to promote the
* | |
| * sale, use or other dealings in this Software without prior written
* | | * sale, use or other dealings in this Software without prior written
* | |
| * authorization.
* | | * authorization.
* | |
| **************************************************************************
**/ | | **************************************************************************
**/ | |
| | | | |
| /**************************************************************************
**/ | | /**************************************************************************
**/ | |
| /* Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995
*/ | | /* Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995
*/ | |
| /* and: Eric S. Raymond <esr@snark.thyrsus.com>
*/ | | /* and: Eric S. Raymond <esr@snark.thyrsus.com>
*/ | |
| /**************************************************************************
**/ | | /**************************************************************************
**/ | |
| | | | |
|
| /* $Id: MKterm.h.awk.in,v 1.23 1998/02/11 12:13:46 tom Exp $ */ | | /* $Id: MKterm.h.awk.in,v 1.41 2001/12/23 01:04:38 tom Exp $ */ | |
| | | | |
| /* | | /* | |
| ** term.h -- Definition of struct term | | ** term.h -- Definition of struct term | |
| */ | | */ | |
| | | | |
|
| #ifndef _TERM_H | | #ifndef NCURSES_TERM_H_incl | |
| #define _TERM_H | | #define NCURSES_TERM_H_incl 1 | |
| | | | |
| #undef NCURSES_VERSION | | #undef NCURSES_VERSION | |
|
| #define NCURSES_VERSION "4.2" | | #define NCURSES_VERSION "5.3" | |
| | | | |
| | | #include <ncurses/ncurses_dll.h> | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| extern "C" { | | extern "C" { | |
| #endif | | #endif | |
| | | | |
| /* Make this file self-contained by providing defaults for the HAVE_TERMIO[
S]_H | | /* Make this file self-contained by providing defaults for the HAVE_TERMIO[
S]_H | |
|
| * and BROKEN_LINKER definition (based on the system for which this was con
figured). | | * definition (based on the system for which this was configured). | |
| */ | | */ | |
| | | | |
|
| #ifndef HAVE_TERMIOS_H | | #undef HAVE_TERMIOS_H | |
| #define HAVE_TERMIOS_H 1 | | #define HAVE_TERMIOS_H 1 | |
|
| #endif | | | |
| | | | |
|
| #ifndef HAVE_TERMIO_H | | #undef HAVE_TCGETATTR | |
| #define HAVE_TERMIO_H 1 | | | |
| #endif | | | |
| | | | |
| #ifndef HAVE_TCGETATTR | | | |
| #define HAVE_TCGETATTR 1 | | #define HAVE_TCGETATTR 1 | |
|
| #endif | | | |
| | | | |
| #ifndef BROKEN_LINKER | | | |
| #define BROKEN_LINKER 0 | | | |
| #endif | | | |
| | | | |
|
| #ifndef NCURSES_CONST | | #undef NCURSES_CONST | |
| #define NCURSES_CONST /*nothing*/ | | #define NCURSES_CONST /*nothing*/ | |
|
| #endif | | | |
| | | | |
|
| /* Assume Posix termio if we have the header and function */ | | #undef NCURSES_XNAMES | |
| | | #define NCURSES_XNAMES 1 | |
| | | | |
| | | /* We will use these symbols to hide differences between | |
| | | * termios/termio/sgttyb interfaces. | |
| | | */ | |
| | | #undef TTY | |
| | | #undef SET_TTY | |
| | | #undef GET_TTY | |
| | | | |
| | | /* Assume POSIX termio if we have the header and function */ | |
| #if HAVE_TERMIOS_H && HAVE_TCGETATTR | | #if HAVE_TERMIOS_H && HAVE_TCGETATTR | |
|
| #ifndef TERMIOS | | | |
| | | #undef TERMIOS | |
| #define TERMIOS 1 | | #define TERMIOS 1 | |
|
| #endif | | | |
| #include <termios.h> | | #include <termios.h> | |
| #define TTY struct termios | | #define TTY struct termios | |
| | | | |
| #else /* !HAVE_TERMIOS_H */ | | #else /* !HAVE_TERMIOS_H */ | |
| | | | |
|
| #if HAVE_TERMIO_H | | #if 1 /* HAVE_TERMIO_H */ | |
| #ifndef TERMIOS | | | |
| | | #undef TERMIOS | |
| #define TERMIOS 1 | | #define TERMIOS 1 | |
|
| #endif | | | |
| #include <termio.h> | | #include <termio.h> | |
| #define TTY struct termio | | #define TTY struct termio | |
|
| | | | |
| | | /* Add definitions to make termio look like termios. | |
| | | * But ifdef it, since there are some implementations | |
| | | * that try to do this for us in a fake <termio.h>. | |
| | | */ | |
| | | #ifndef TCSANOW | |
| #define TCSANOW TCSETA | | #define TCSANOW TCSETA | |
|
| | | #endif | |
| | | #ifndef TCSADRAIN | |
| #define TCSADRAIN TCSETAW | | #define TCSADRAIN TCSETAW | |
|
| | | #endif | |
| | | #ifndef TCSAFLUSH | |
| #define TCSAFLUSH TCSETAF | | #define TCSAFLUSH TCSETAF | |
|
| | | #endif | |
| | | #ifndef tcsetattr | |
| #define tcsetattr(fd, cmd, arg) ioctl(fd, cmd, arg) | | #define tcsetattr(fd, cmd, arg) ioctl(fd, cmd, arg) | |
|
| | | #endif | |
| | | #ifndef tcgetattr | |
| #define tcgetattr(fd, arg) ioctl(fd, TCGETA, arg) | | #define tcgetattr(fd, arg) ioctl(fd, TCGETA, arg) | |
|
| | | #endif | |
| | | #ifndef cfgetospeed | |
| #define cfgetospeed(t) ((t)->c_cflag & CBAUD) | | #define cfgetospeed(t) ((t)->c_cflag & CBAUD) | |
|
| | | #endif | |
| | | #ifndef TCIFLUSH | |
| #define TCIFLUSH 0 | | #define TCIFLUSH 0 | |
|
| | | #endif | |
| | | #ifndef TCOFLUSH | |
| #define TCOFLUSH 1 | | #define TCOFLUSH 1 | |
|
| | | #endif | |
| | | #ifndef TCIOFLUSH | |
| #define TCIOFLUSH 2 | | #define TCIOFLUSH 2 | |
|
| | | #endif | |
| | | #ifndef tcflush | |
| #define tcflush(fd, arg) ioctl(fd, TCFLSH, arg) | | #define tcflush(fd, arg) ioctl(fd, TCFLSH, arg) | |
|
| | | #endif | |
| | | | |
| #else /* !HAVE_TERMIO_H */ | | #else /* !HAVE_TERMIO_H */ | |
| | | | |
| #undef TERMIOS | | #undef TERMIOS | |
| #include <sgtty.h> | | #include <sgtty.h> | |
| #include <sys/ioctl.h> | | #include <sys/ioctl.h> | |
| #define TTY struct sgttyb | | #define TTY struct sgttyb | |
| | | | |
| #endif /* HAVE_TERMIO_H */ | | #endif /* HAVE_TERMIO_H */ | |
| | | | |
| #endif /* HAVE_TERMIOS_H */ | | #endif /* HAVE_TERMIOS_H */ | |
| | | | |
| #ifdef TERMIOS | | #ifdef TERMIOS | |
| #define GET_TTY(fd, buf) tcgetattr(fd, buf) | | #define GET_TTY(fd, buf) tcgetattr(fd, buf) | |
| #define SET_TTY(fd, buf) tcsetattr(fd, TCSADRAIN, buf) | | #define SET_TTY(fd, buf) tcsetattr(fd, TCSADRAIN, buf) | |
| #else | | #else | |
| #define GET_TTY(fd, buf) gtty(fd, buf) | | #define GET_TTY(fd, buf) gtty(fd, buf) | |
| #define SET_TTY(fd, buf) stty(fd, buf) | | #define SET_TTY(fd, buf) stty(fd, buf) | |
| #endif | | #endif | |
| | | | |
|
| extern char ttytype[]; | | | |
| #define NAMESIZE 256 | | #define NAMESIZE 256 | |
| | | | |
| #define CUR cur_term->type. | | #define CUR cur_term->type. | |
| | | | |
| #define auto_left_margin CUR Booleans[0] | | #define auto_left_margin CUR Booleans[0] | |
| #define auto_right_margin CUR Booleans[1] | | #define auto_right_margin CUR Booleans[1] | |
| #define no_esc_ctlc CUR Booleans[2] | | #define no_esc_ctlc CUR Booleans[2] | |
| #define ceol_standout_glitch CUR Booleans[3] | | #define ceol_standout_glitch CUR Booleans[3] | |
| #define eat_newline_glitch CUR Booleans[4] | | #define eat_newline_glitch CUR Booleans[4] | |
| #define erase_overstrike CUR Booleans[5] | | #define erase_overstrike CUR Booleans[5] | |
| | | | |
| skipping to change at line 183 | | skipping to change at line 210 | |
| #define max_attributes CUR Numbers[11] | | #define max_attributes CUR Numbers[11] | |
| #define maximum_windows CUR Numbers[12] | | #define maximum_windows CUR Numbers[12] | |
| #define max_colors CUR Numbers[13] | | #define max_colors CUR Numbers[13] | |
| #define max_pairs CUR Numbers[14] | | #define max_pairs CUR Numbers[14] | |
| #define no_color_video CUR Numbers[15] | | #define no_color_video CUR Numbers[15] | |
| #define buffer_capacity CUR Numbers[16] | | #define buffer_capacity CUR Numbers[16] | |
| #define dot_vert_spacing CUR Numbers[17] | | #define dot_vert_spacing CUR Numbers[17] | |
| #define dot_horz_spacing CUR Numbers[18] | | #define dot_horz_spacing CUR Numbers[18] | |
| #define max_micro_address CUR Numbers[19] | | #define max_micro_address CUR Numbers[19] | |
| #define max_micro_jump CUR Numbers[20] | | #define max_micro_jump CUR Numbers[20] | |
|
| #define micro_char_size CUR Numbers[21] | | #define micro_col_size CUR Numbers[21] | |
| #define micro_line_size CUR Numbers[22] | | #define micro_line_size CUR Numbers[22] | |
| #define number_of_pins CUR Numbers[23] | | #define number_of_pins CUR Numbers[23] | |
| #define output_res_char CUR Numbers[24] | | #define output_res_char CUR Numbers[24] | |
| #define output_res_line CUR Numbers[25] | | #define output_res_line CUR Numbers[25] | |
| #define output_res_horz_inch CUR Numbers[26] | | #define output_res_horz_inch CUR Numbers[26] | |
| #define output_res_vert_inch CUR Numbers[27] | | #define output_res_vert_inch CUR Numbers[27] | |
| #define print_rate CUR Numbers[28] | | #define print_rate CUR Numbers[28] | |
| #define wide_char_size CUR Numbers[29] | | #define wide_char_size CUR Numbers[29] | |
| #define buttons CUR Numbers[30] | | #define buttons CUR Numbers[30] | |
| #define bit_image_entwining CUR Numbers[31] | | #define bit_image_entwining CUR Numbers[31] | |
| | | | |
| skipping to change at line 587 | | skipping to change at line 614 | |
| #define exit_scancode_mode CUR Strings[382] | | #define exit_scancode_mode CUR Strings[382] | |
| #define pc_term_options CUR Strings[383] | | #define pc_term_options CUR Strings[383] | |
| #define scancode_escape CUR Strings[384] | | #define scancode_escape CUR Strings[384] | |
| #define alt_scancode_esc CUR Strings[385] | | #define alt_scancode_esc CUR Strings[385] | |
| #define enter_horizontal_hl_mode CUR Strings[386] | | #define enter_horizontal_hl_mode CUR Strings[386] | |
| #define enter_left_hl_mode CUR Strings[387] | | #define enter_left_hl_mode CUR Strings[387] | |
| #define enter_low_hl_mode CUR Strings[388] | | #define enter_low_hl_mode CUR Strings[388] | |
| #define enter_right_hl_mode CUR Strings[389] | | #define enter_right_hl_mode CUR Strings[389] | |
| #define enter_top_hl_mode CUR Strings[390] | | #define enter_top_hl_mode CUR Strings[390] | |
| #define enter_vertical_hl_mode CUR Strings[391] | | #define enter_vertical_hl_mode CUR Strings[391] | |
|
| | | #define set_a_attributes CUR Strings[392] | |
| | | #define set_pglen_inch CUR Strings[393] | |
| | | | |
| #define BOOLWRITE 37 | | #define BOOLWRITE 37 | |
| #define NUMWRITE 33 | | #define NUMWRITE 33 | |
|
| #define STRWRITE 392 | | #define STRWRITE 394 | |
| | | | |
| /* older synonyms for some capabilities */ | | /* older synonyms for some capabilities */ | |
| #define beehive_glitch no_esc_ctlc | | #define beehive_glitch no_esc_ctlc | |
| #define teleray_glitch dest_tabs_magic_smso | | #define teleray_glitch dest_tabs_magic_smso | |
|
| | | #define micro_char_size micro_col_size | |
| /* XSI synonyms */ | | | |
| #define micro_col_size micro_char_size | | | |
| | | | |
| #ifdef __INTERNAL_CAPS_VISIBLE | | #ifdef __INTERNAL_CAPS_VISIBLE | |
|
| #define termcap_init2 CUR Strings[392] | | #define termcap_init2 CUR Strings[394] | |
| #define termcap_reset CUR Strings[393] | | #define termcap_reset CUR Strings[395] | |
| #define magic_cookie_glitch_ul CUR Numbers[33] | | #define magic_cookie_glitch_ul CUR Numbers[33] | |
| #define backspaces_with_bs CUR Booleans[37] | | #define backspaces_with_bs CUR Booleans[37] | |
| #define crt_no_scrolling CUR Booleans[38] | | #define crt_no_scrolling CUR Booleans[38] | |
| #define no_correctly_working_cr CUR Booleans[39] | | #define no_correctly_working_cr CUR Booleans[39] | |
| #define carriage_return_delay CUR Numbers[34] | | #define carriage_return_delay CUR Numbers[34] | |
| #define new_line_delay CUR Numbers[35] | | #define new_line_delay CUR Numbers[35] | |
|
| #define linefeed_if_not_lf CUR Strings[394] | | #define linefeed_if_not_lf CUR Strings[396] | |
| #define backspace_if_not_bs CUR Strings[395] | | #define backspace_if_not_bs CUR Strings[397] | |
| #define gnu_has_meta_key CUR Booleans[40] | | #define gnu_has_meta_key CUR Booleans[40] | |
| #define linefeed_is_newline CUR Booleans[41] | | #define linefeed_is_newline CUR Booleans[41] | |
| #define backspace_delay CUR Numbers[36] | | #define backspace_delay CUR Numbers[36] | |
| #define horizontal_tab_delay CUR Numbers[37] | | #define horizontal_tab_delay CUR Numbers[37] | |
| #define number_of_function_keys CUR Numbers[38] | | #define number_of_function_keys CUR Numbers[38] | |
|
| #define other_non_function_keys CUR Strings[396] | | #define other_non_function_keys CUR Strings[398] | |
| #define arrow_key_map CUR Strings[397] | | #define arrow_key_map CUR Strings[399] | |
| #define has_hardware_tabs CUR Booleans[42] | | #define has_hardware_tabs CUR Booleans[42] | |
| #define return_does_clr_eol CUR Booleans[43] | | #define return_does_clr_eol CUR Booleans[43] | |
|
| #define acs_ulcorner CUR Strings[398] | | #define acs_ulcorner CUR Strings[400] | |
| #define acs_llcorner CUR Strings[399] | | #define acs_llcorner CUR Strings[401] | |
| #define acs_urcorner CUR Strings[400] | | #define acs_urcorner CUR Strings[402] | |
| #define acs_lrcorner CUR Strings[401] | | #define acs_lrcorner CUR Strings[403] | |
| #define acs_ltee CUR Strings[402] | | #define acs_ltee CUR Strings[404] | |
| #define acs_rtee CUR Strings[403] | | #define acs_rtee CUR Strings[405] | |
| #define acs_btee CUR Strings[404] | | #define acs_btee CUR Strings[406] | |
| #define acs_ttee CUR Strings[405] | | #define acs_ttee CUR Strings[407] | |
| #define acs_hline CUR Strings[406] | | #define acs_hline CUR Strings[408] | |
| #define acs_vline CUR Strings[407] | | #define acs_vline CUR Strings[409] | |
| #define acs_plus CUR Strings[408] | | #define acs_plus CUR Strings[410] | |
| #define memory_lock CUR Strings[409] | | #define memory_lock CUR Strings[411] | |
| #define memory_unlock CUR Strings[410] | | #define memory_unlock CUR Strings[412] | |
| #define box_chars_1 CUR Strings[411] | | #define box_chars_1 CUR Strings[413] | |
| #endif /* __INTERNAL_CAPS_VISIBLE */ | | #endif /* __INTERNAL_CAPS_VISIBLE */ | |
| | | | |
|
| | | /* | |
| | | * Predefined terminfo array sizes | |
| | | */ | |
| #define BOOLCOUNT 44 | | #define BOOLCOUNT 44 | |
| #define NUMCOUNT 39 | | #define NUMCOUNT 39 | |
|
| #define STRCOUNT 412 | | #define STRCOUNT 414 | |
| | | | |
| | | /* used by code for comparing entries */ | |
| | | #define acs_chars_index 146 | |
| | | | |
| typedef struct termtype { /* in-core form of terminfo data */ | | typedef struct termtype { /* in-core form of terminfo data */ | |
| char *term_names; /* str_table offset of term names */ | | char *term_names; /* str_table offset of term names */ | |
| char *str_table; /* pointer to string table */ | | char *str_table; /* pointer to string table */ | |
|
| char Booleans[BOOLCOUNT]; /* array of values */ | | char *Booleans; /* array of boolean values */ | |
| short Numbers[NUMCOUNT]; /* array of values */ | | short *Numbers; /* array of integer values */ | |
| char *Strings[STRCOUNT]; /* array of string offsets */ | | char **Strings; /* array of string offsets */ | |
| | | | |
| | | #if NCURSES_XNAMES | |
| | | char *ext_str_table; /* pointer to extended string table */ | |
| | | char **ext_Names; /* corresponding names */ | |
| | | | |
| | | unsigned short num_Booleans;/* count total Booleans */ | |
| | | unsigned short num_Numbers; /* count total Numbers */ | |
| | | unsigned short num_Strings; /* count total Strings */ | |
| | | | |
| | | unsigned short ext_Booleans;/* count extensions to Booleans */ | |
| | | unsigned short ext_Numbers; /* count extensions to Numbers */ | |
| | | unsigned short ext_Strings; /* count extensions to Strings */ | |
| | | #endif /* NCURSES_XNAMES */ | |
| | | | |
| } TERMTYPE; | | } TERMTYPE; | |
| | | | |
| typedef struct term { /* describe an actual terminal */ | | typedef struct term { /* describe an actual terminal */ | |
| TERMTYPE type; /* terminal type description */ | | TERMTYPE type; /* terminal type description */ | |
|
| short Filedes; /* file description being written to */ | | short Filedes; /* file description being written to */ | |
| TTY Ottyb, /* original state of the terminal */ | | TTY Ottyb, /* original state of the terminal */ | |
| Nttyb; /* current state of the terminal */ | | Nttyb; /* current state of the terminal */ | |
| int _baudrate; /* used to compute padding */ | | int _baudrate; /* used to compute padding */ | |
| } TERMINAL; | | } TERMINAL; | |
| | | | |
|
| extern TERMINAL *cur_term; | | extern NCURSES_EXPORT_VAR(TERMINAL *) cur_term; | |
| | | | |
|
| #if BROKEN_LINKER | | #if 0 /* BROKEN_LINKER */ | |
| #define boolnames _nc_boolnames() | | #define boolnames _nc_boolnames() | |
| #define boolcodes _nc_boolcodes() | | #define boolcodes _nc_boolcodes() | |
| #define boolfnames _nc_boolfnames() | | #define boolfnames _nc_boolfnames() | |
| #define numnames _nc_numnames() | | #define numnames _nc_numnames() | |
| #define numcodes _nc_numcodes() | | #define numcodes _nc_numcodes() | |
| #define numfnames _nc_numfnames() | | #define numfnames _nc_numfnames() | |
| #define strnames _nc_strnames() | | #define strnames _nc_strnames() | |
| #define strcodes _nc_strcodes() | | #define strcodes _nc_strcodes() | |
| #define strfnames _nc_strfnames() | | #define strfnames _nc_strfnames() | |
| | | | |
|
| extern NCURSES_CONST char * const *_nc_boolnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_boolnames (void); | |
| extern NCURSES_CONST char * const *_nc_boolcodes(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_boolcodes (void); | |
| extern NCURSES_CONST char * const *_nc_boolfnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_boolfnames (void); | |
| extern NCURSES_CONST char * const *_nc_numnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_numnames (void); | |
| extern NCURSES_CONST char * const *_nc_numcodes(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_numcodes (void); | |
| extern NCURSES_CONST char * const *_nc_numfnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_numfnames (void); | |
| extern NCURSES_CONST char * const *_nc_strnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_strnames (void); | |
| extern NCURSES_CONST char * const *_nc_strcodes(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_strcodes (void); | |
| extern NCURSES_CONST char * const *_nc_strfnames(void); | | extern NCURSES_EXPORT(NCURSES_CONST char * const *) _nc_strfnames (void); | |
| | | | |
| #else | | #else | |
| | | | |
|
| extern NCURSES_CONST char *const boolnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolnames[]; | |
| extern NCURSES_CONST char *const boolcodes[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolcodes[]; | |
| extern NCURSES_CONST char *const boolfnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolfnames[]; | |
| extern NCURSES_CONST char *const numnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numnames[]; | |
| extern NCURSES_CONST char *const numcodes[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numcodes[]; | |
| extern NCURSES_CONST char *const numfnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) numfnames[]; | |
| extern NCURSES_CONST char *const strnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strnames[]; | |
| extern NCURSES_CONST char *const strcodes[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strcodes[]; | |
| extern NCURSES_CONST char *const strfnames[]; | | extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) strfnames[]; | |
| | | | |
| #endif | | #endif | |
| | | | |
| /* internals */ | | /* internals */ | |
|
| extern int _nc_set_curterm(TTY *buf); | | extern NCURSES_EXPORT(int) _nc_set_tty_mode (TTY *buf); | |
| extern int _nc_get_curterm(TTY *buf); | | extern NCURSES_EXPORT(int) _nc_get_tty_mode (TTY *buf); | |
| extern int _nc_read_entry(const char * const, char * const, TERMTYPE *const | | extern NCURSES_EXPORT(int) _nc_read_entry (const char * const, char * const | |
| ); | | , TERMTYPE *const); | |
| extern int _nc_read_file_entry(const char *const, TERMTYPE *); | | extern NCURSES_EXPORT(int) _nc_read_file_entry (const char *const, TERMTYPE | |
| extern char *_nc_first_name(const char *const); | | *); | |
| extern int _nc_name_match(const char *const, const char *const, const char | | extern NCURSES_EXPORT(char *) _nc_first_name (const char *const); | |
| *const); | | extern NCURSES_EXPORT(int) _nc_name_match (const char *const, const char *c | |
| extern int _nc_read_termcap_entry(const char *const, TERMTYPE *const); | | onst, const char *const); | |
| extern const TERMTYPE *_nc_fallback(const char *); | | extern NCURSES_EXPORT(int) _nc_read_termcap_entry (const char *const, TERMT | |
| | | YPE *const); | |
| | | extern NCURSES_EXPORT(const TERMTYPE *) _nc_fallback (const char *); | |
| | | | |
| /* entry points */ | | /* entry points */ | |
|
| extern TERMINAL *set_curterm(TERMINAL *); | | extern NCURSES_EXPORT(TERMINAL *) set_curterm (TERMINAL *); | |
| extern int del_curterm(TERMINAL *); | | extern NCURSES_EXPORT(int) del_curterm (TERMINAL *); | |
| | | | |
| /* miscellaneous entry points */ | | /* miscellaneous entry points */ | |
|
| extern int putp(const char *); | | extern NCURSES_EXPORT(int) restartterm (NCURSES_CONST char *, int, int *); | |
| extern int restartterm(const char *, int, int *); | | extern NCURSES_EXPORT(int) setupterm (NCURSES_CONST char *,int,int *); | |
| extern int setupterm(const char *,int,int *); | | | |
| extern int tputs(const char *, int, int (*)(int)); | | | |
| | | | |
|
| /* terminfo entry points */ | | /* terminfo entry points, also declared in curses.h */ | |
| extern int tigetflag(const char *); | | #if !defined(__NCURSES_H) | |
| extern int tigetnum(const char *); | | extern NCURSES_EXPORT(char *) tigetstr (NCURSES_CONST char *); | |
| extern char *tigetstr(const char *); | | extern NCURSES_EXPORT(char *) tparm (NCURSES_CONST char *, ...); | |
| extern char *tparm(const char *, ...); | | extern NCURSES_EXPORT_VAR(char) ttytype[]; | |
| | | extern NCURSES_EXPORT(int) putp (const char *); | |
| | | extern NCURSES_EXPORT(int) tigetflag (NCURSES_CONST char *); | |
| | | extern NCURSES_EXPORT(int) tigetnum (NCURSES_CONST char *); | |
| | | #endif /* __NCURSES_H */ | |
| | | | |
| /* termcap database emulation (XPG4 uses const only for 2nd param of tgeten
t) */ | | /* termcap database emulation (XPG4 uses const only for 2nd param of tgeten
t) */ | |
|
| extern int tgetent(char *, const char *); | | #if !defined(NCURSES_TERMCAP_H_incl) | |
| extern int tgetflag(const char *); | | extern NCURSES_EXPORT(char *) tgetstr (NCURSES_CONST char *, char **); | |
| extern int tgetnum(const char *); | | extern NCURSES_EXPORT(char *) tgoto (const char *, int, int); | |
| extern char *tgetstr(const char *, char **); | | extern NCURSES_EXPORT(int) tgetent (char *, const char *); | |
| extern char *tgoto(const char *, int, int); | | extern NCURSES_EXPORT(int) tgetflag (NCURSES_CONST char *); | |
| | | extern NCURSES_EXPORT(int) tgetnum (NCURSES_CONST char *); | |
| | | extern NCURSES_EXPORT(int) tputs (const char *, int, int (*)(int)); | |
| | | #endif /* NCURSES_TERMCAP_H_incl */ | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| } | | } | |
| #endif | | #endif | |
| | | | |
|
| #endif /* TERM_H */ | | #endif /* NCURSES_TERM_H_incl */ | |
| | | | |
End of changes. 52 change blocks. |
| 108 lines changed or deleted | | 162 lines changed or added | |
|