switch source tree from k&r to c99
This commit is contained in:
@@ -707,8 +707,8 @@ struct instance_globals {
|
||||
struct entity occupants[ENTITIES];
|
||||
|
||||
/* decl.c */
|
||||
int NDECL((*occupation));
|
||||
int NDECL((*afternmv));
|
||||
int (*occupation)(void);
|
||||
int (*afternmv)(void);
|
||||
const char *hname; /* name of the game (argv[0] of main) */
|
||||
int hackpid; /* current process id */
|
||||
char chosen_windowtype[WINTYPELEN];
|
||||
|
||||
@@ -44,7 +44,7 @@ typedef struct dlb_library {
|
||||
#define DLBFILE dlbfilename
|
||||
#define DLBBASENAME "nhdat"
|
||||
extern char dlbfilename[MAX_DLB_FILENAME];
|
||||
extern char *FDECL(build_dlb_filename, (const char *));
|
||||
extern char *build_dlb_filename(const char *);
|
||||
#endif
|
||||
#endif
|
||||
#ifndef FILENAME_CMP
|
||||
@@ -75,16 +75,16 @@ typedef struct dlb_handle {
|
||||
#define DLB_P dlb *
|
||||
#endif
|
||||
|
||||
boolean NDECL(dlb_init);
|
||||
void NDECL(dlb_cleanup);
|
||||
boolean dlb_init(void);
|
||||
void dlb_cleanup(void);
|
||||
|
||||
dlb *FDECL(dlb_fopen, (const char *, const char *));
|
||||
int FDECL(dlb_fclose, (DLB_P));
|
||||
int FDECL(dlb_fread, (char *, int, int, DLB_P));
|
||||
int FDECL(dlb_fseek, (DLB_P, long, int));
|
||||
char *FDECL(dlb_fgets, (char *, int, DLB_P));
|
||||
int FDECL(dlb_fgetc, (DLB_P));
|
||||
long FDECL(dlb_ftell, (DLB_P));
|
||||
dlb *dlb_fopen(const char *, const char *);
|
||||
int dlb_fclose(DLB_P);
|
||||
int dlb_fread(char *, int, int, DLB_P);
|
||||
int dlb_fseek(DLB_P, long, int);
|
||||
char *dlb_fgets(char *, int, DLB_P);
|
||||
int dlb_fgetc(DLB_P);
|
||||
long dlb_ftell(DLB_P);
|
||||
|
||||
/* Resource DLB entry points */
|
||||
#ifdef DLBRSRC
|
||||
|
||||
5111
include/extern.h
5111
include/extern.h
File diff suppressed because it is too large
Load Diff
@@ -16,7 +16,7 @@
|
||||
struct ext_func_tab {
|
||||
uchar key;
|
||||
const char *ef_txt, *ef_desc;
|
||||
int NDECL((*ef_funct));
|
||||
int (*ef_funct)(void);
|
||||
int flags;
|
||||
const char *f_text;
|
||||
};
|
||||
|
||||
@@ -302,7 +302,7 @@ extern struct cross_target_s cross_target;
|
||||
if nethack is built with MONITOR_HEAP enabled and they aren't; this
|
||||
declaration has been moved out of the '#else' below to avoid getting
|
||||
a complaint from -Wmissing-prototypes when building with MONITOR_HEAP */
|
||||
extern char *FDECL(dupstr, (const char *));
|
||||
extern char *dupstr(const char *);
|
||||
|
||||
/*
|
||||
* MONITOR_HEAP is conditionally used for primitive memory leak debugging.
|
||||
@@ -314,9 +314,9 @@ extern char *FDECL(dupstr, (const char *));
|
||||
*/
|
||||
#ifdef MONITOR_HEAP
|
||||
/* plain alloc() is not declared except in alloc.c */
|
||||
extern long *FDECL(nhalloc, (unsigned int, const char *, int));
|
||||
extern void FDECL(nhfree, (genericptr_t, const char *, int));
|
||||
extern char *FDECL(nhdupstr, (const char *, const char *, int));
|
||||
extern long *nhalloc(unsigned int, const char *, int);
|
||||
extern void nhfree(genericptr_t, const char *, int);
|
||||
extern char *nhdupstr(const char *, const char *, int);
|
||||
/* this predates C99's __func__; that is trickier to use conditionally
|
||||
because it is not implemented as a preprocessor macro; MONITOR_HEAP
|
||||
wouldn't gain much benefit from it anyway so continue to live without it;
|
||||
@@ -332,7 +332,7 @@ extern char *FDECL(nhdupstr, (const char *, const char *, int));
|
||||
#define dupstr(s) nhdupstr(s, __FILE__, (int) __LINE__)
|
||||
#else /* !MONITOR_HEAP */
|
||||
/* declare alloc.c's alloc(); allocations made with it use ordinary free() */
|
||||
extern long *FDECL(alloc, (unsigned int)); /* alloc.c */
|
||||
extern long *alloc(unsigned int); /* alloc.c */
|
||||
#endif /* ?MONITOR_HEAP */
|
||||
|
||||
/* Used for consistency checks of various data files; declare it here so
|
||||
|
||||
@@ -18,15 +18,15 @@
|
||||
* 2. Add a pointer to your new struct to the mextra struct in this
|
||||
* file.
|
||||
* 3. Add a referencing macro at bottom of this file after the mextra
|
||||
* struct (see MNAME, EGD, EPRI, ESHK, EMIN, or EDOG for examples).
|
||||
* struct (see MGIVENNAME, EGD, EPRI, ESHK, EMIN, or EDOG for examples).
|
||||
* 4. If your new field isn't a pointer and requires a non-zero value
|
||||
* on initialization, add code to init_mextra() in src/makemon.c
|
||||
* 5. Create a newXX(mtmp) function and possibly a free_XX(mtmp)
|
||||
* function in an appropriate new or existing source file and add
|
||||
* a prototype for it to include/extern.h.
|
||||
*
|
||||
* void FDECL(newXX, (struct monst *));
|
||||
* void FDECL(free_XX, (struct monst *));
|
||||
* void newXX(struct monst *);
|
||||
* void free_XX(struct monst *);
|
||||
*
|
||||
* void
|
||||
* newXX(mtmp)
|
||||
|
||||
@@ -91,9 +91,8 @@
|
||||
/* Stuff to help the user with some common, yet significant errors */
|
||||
#define INTERJECT_PANIC 0
|
||||
#define INTERJECTION_TYPES (INTERJECT_PANIC + 1)
|
||||
extern void FDECL(interject_assistance,
|
||||
(int, int, genericptr_t, genericptr_t));
|
||||
extern void FDECL(interject, (int));
|
||||
extern void interject_assistance(int, int, genericptr_t, genericptr_t);
|
||||
extern void interject(int);
|
||||
|
||||
/*
|
||||
*===============================================
|
||||
@@ -108,7 +107,7 @@ extern void FDECL(interject, (int));
|
||||
#ifdef strcasecmp
|
||||
#undef strcasecmp
|
||||
#endif
|
||||
/* extern int NDECL(getlock); */
|
||||
/* extern int getlock(void); */
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER
|
||||
@@ -223,14 +222,14 @@ extern const char *alllevels, *allbones;
|
||||
#define ABORT C('a')
|
||||
#define getuid() 1
|
||||
#define getlogin() ((char *) 0)
|
||||
extern void NDECL(win32_abort);
|
||||
extern void FDECL(nttty_preference_update, (const char *));
|
||||
extern void NDECL(toggle_mouse_support);
|
||||
extern void FDECL(map_subkeyvalue, (char *));
|
||||
extern void win32_abort(void);
|
||||
extern void nttty_preference_update(const char *);
|
||||
extern void toggle_mouse_support(void);
|
||||
extern void map_subkeyvalue(char *);
|
||||
#if defined(WIN32CON)
|
||||
extern void FDECL(set_altkeyhandler, (const char *));
|
||||
extern void set_altkeyhandler(const char *);
|
||||
#endif
|
||||
extern void NDECL(raw_clear_screen);
|
||||
extern void raw_clear_screen(void);
|
||||
|
||||
#include <fcntl.h>
|
||||
#ifndef __BORLANDC__
|
||||
@@ -265,19 +264,19 @@ int _RTLENTRY _EXPFUNC read(int __handle, void _FAR *__buf, unsigned __len);
|
||||
#define ALLOCA_HACK /* used in util/panic.c */
|
||||
#endif
|
||||
|
||||
extern int FDECL(set_win32_option, (const char *, const char *));
|
||||
extern int set_win32_option(const char *, const char *);
|
||||
#define LEFTBUTTON FROM_LEFT_1ST_BUTTON_PRESSED
|
||||
#define RIGHTBUTTON RIGHTMOST_BUTTON_PRESSED
|
||||
#define MIDBUTTON FROM_LEFT_2ND_BUTTON_PRESSED
|
||||
#define MOUSEMASK (LEFTBUTTON | RIGHTBUTTON | MIDBUTTON)
|
||||
#ifdef CHANGE_COLOR
|
||||
extern int FDECL(alternative_palette, (char *));
|
||||
extern int alternative_palette(char *);
|
||||
#endif
|
||||
|
||||
#define nethack_enter(argc, argv) nethack_enter_winnt()
|
||||
extern void FDECL(nethack_exit, (int)) NORETURN;
|
||||
extern boolean FDECL(file_exists, (const char *));
|
||||
extern boolean FDECL(file_newer, (const char *, const char *));
|
||||
extern void nethack_exit(int) NORETURN;
|
||||
extern boolean file_exists(const char *);
|
||||
extern boolean file_newer(const char *, const char *);
|
||||
#ifndef SYSTEM_H
|
||||
#include "system.h"
|
||||
#endif
|
||||
@@ -287,7 +286,7 @@ extern boolean FDECL(file_newer, (const char *, const char *));
|
||||
* compatible with compilers which do not support macro stringization (i.e.
|
||||
* #x to turn x into its string form).
|
||||
*/
|
||||
extern void FDECL(nt_assert_failed, (const char *, const char *, int));
|
||||
extern void nt_assert_failed(const char *, const char *, int);
|
||||
#define nhassert(expression) (void)((!!(expression)) || \
|
||||
(nt_assert_failed(#expression, __FILE__, __LINE__), 0))
|
||||
|
||||
|
||||
@@ -417,8 +417,8 @@ struct obj {
|
||||
* for it to include/extern.h. The majority of these are currently
|
||||
* located in mkobj.c for convenience.
|
||||
*
|
||||
* void FDECL(newXX, (struct obj *));
|
||||
* void FDECL(free_XX, (struct obj *));
|
||||
* void newXX(struct obj *);
|
||||
* void free_XX(struct obj *);
|
||||
*
|
||||
* void
|
||||
* newxx(otmp)
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
* updates that should accompany your change.
|
||||
*/
|
||||
|
||||
static int FDECL(optfn_boolean, (int, int, BOOLEAN_P, char *, char *));
|
||||
static int optfn_boolean(int, int, boolean, char *, char *);
|
||||
enum OptType {BoolOpt, CompOpt};
|
||||
enum Y_N {No, Yes};
|
||||
enum Off_On {Off, On};
|
||||
@@ -29,7 +29,7 @@ struct allopt_t {
|
||||
enum Y_N dupeok;
|
||||
enum Y_N pfx;
|
||||
boolean opt_in_out, *addr;
|
||||
int FDECL((*optfn), (int, int, BOOLEAN_P, char *, char *));
|
||||
int (*optfn)(int, int, boolean, char *, char *);
|
||||
const char *alias;
|
||||
const char *descr;
|
||||
const char *prefixgw;
|
||||
@@ -45,9 +45,9 @@ struct allopt_t {
|
||||
#if defined(NHOPT_PROTO)
|
||||
#define NHOPTB(a, b, c, s, i, n, v, d, al, bp)
|
||||
#define NHOPTC(a, b, c, s, n, v, d, h, al, z) \
|
||||
static int FDECL(optfn_##a, (int, int, BOOLEAN_P, char *, char *));
|
||||
static int optfn_##a(int, int, boolean, char *, char *);
|
||||
#define NHOPTP(a, b, c, s, n, v, d, h, al, z) \
|
||||
static int FDECL(pfxfn_##a, (int, int, BOOLEAN_P, char *, char *));
|
||||
static int pfxfn_##a(int, int, boolean, char *, char *);
|
||||
|
||||
#elif defined(NHOPT_ENUM)
|
||||
#define NHOPTB(a, b, c, s, i, n, v, d, al, bp) \
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
/* generic callback function */
|
||||
|
||||
typedef boolean FDECL((*callback_proc), (genericptr_t, genericptr_t));
|
||||
typedef boolean (*callback_proc)(genericptr_t, genericptr_t);
|
||||
|
||||
/*
|
||||
* player_flags
|
||||
|
||||
@@ -650,8 +650,8 @@ typedef struct {
|
||||
* includes config.h instead of hack.h so doesn't see extern.h.
|
||||
*/
|
||||
/* ### drawing.c ### */
|
||||
extern int FDECL(def_char_to_objclass, (CHAR_P));
|
||||
extern int FDECL(def_char_to_monclass, (CHAR_P));
|
||||
extern int FDECL(def_char_is_furniture, (CHAR_P));
|
||||
extern int def_char_to_objclass(char);
|
||||
extern int def_char_to_monclass(char);
|
||||
extern int def_char_is_furniture(char);
|
||||
|
||||
#endif /* RM_H */
|
||||
|
||||
@@ -60,7 +60,7 @@ typedef long off_t;
|
||||
#endif
|
||||
#ifndef SIG_RET_TYPE
|
||||
#if defined(NHSTDC) || defined(POSIX_TYPES) || defined(OS2) || defined(__DECC)
|
||||
#define SIG_RET_TYPE void (*)()
|
||||
#define SIG_RET_TYPE void (*)(int)
|
||||
#endif
|
||||
#endif
|
||||
#ifndef SIG_RET_TYPE
|
||||
@@ -95,8 +95,8 @@ E int FDECL(srandom, (unsigned int));
|
||||
E long NDECL(lrand48);
|
||||
E void FDECL(srand48, (long));
|
||||
#else
|
||||
E long lrand48();
|
||||
E void srand48();
|
||||
extern long lrand48(void);
|
||||
extern void srand48(long);
|
||||
#endif /* MACOSX */
|
||||
#endif /* BSD || ULTRIX || RANDOM */
|
||||
|
||||
@@ -355,7 +355,7 @@ E char *FDECL(memset, (char *, int, int));
|
||||
E void sleep();
|
||||
#endif
|
||||
#if defined(ULTRIX) || defined(SYSV)
|
||||
E unsigned sleep();
|
||||
extern unsigned int sleep(unsigned int);
|
||||
#endif
|
||||
#if defined(HPUX)
|
||||
E unsigned int FDECL(sleep, (unsigned int));
|
||||
@@ -365,7 +365,7 @@ E int FDECL(sleep, (unsigned));
|
||||
#endif
|
||||
|
||||
E char *FDECL(getenv, (const char *));
|
||||
E char *getlogin();
|
||||
extern char *getlogin(void);
|
||||
#if defined(HPUX) && !defined(_POSIX_SOURCE)
|
||||
E long NDECL(getuid);
|
||||
E long NDECL(getgid);
|
||||
@@ -519,7 +519,7 @@ E char *FDECL(tgoto, (const char *, int, int));
|
||||
#else
|
||||
#if !(defined(HPUX) && defined(_POSIX_SOURCE))
|
||||
E int FDECL(tgetent, (char *, const char *));
|
||||
E void FDECL(tputs, (const char *, int, int (*)()));
|
||||
extern void tputs(const char *, int, int (*)(int));
|
||||
#endif
|
||||
E int FDECL(tgetnum, (const char *));
|
||||
E int FDECL(tgetflag, (const char *));
|
||||
|
||||
@@ -16,16 +16,16 @@ struct TileImage {
|
||||
unsigned char *indexes; /* for paletted images */
|
||||
};
|
||||
|
||||
boolean FDECL(read_tiles, (const char *filename, BOOLEAN_P true_color));
|
||||
const struct Pixel *NDECL(get_palette);
|
||||
void FDECL(set_tile_type, (BOOLEAN_P true_color));
|
||||
void NDECL(free_tiles);
|
||||
const struct TileImage *FDECL(get_tile, (unsigned tile_index));
|
||||
boolean read_tiles(const char *filename, boolean true_color);
|
||||
const struct Pixel *get_palette(void);
|
||||
void set_tile_type(boolean true_color);
|
||||
void free_tiles(void);
|
||||
const struct TileImage *get_tile(unsigned tile_index);
|
||||
|
||||
/* For resizing tiles */
|
||||
struct TileImage *FDECL(stretch_tile, (const struct TileImage *,
|
||||
unsigned, unsigned));
|
||||
void FDECL(free_tile, (struct TileImage *));
|
||||
struct TileImage *stretch_tile(const struct TileImage *, unsigned,
|
||||
unsigned);
|
||||
void free_tile(struct TileImage *);
|
||||
|
||||
/* Used internally by the tile set code */
|
||||
struct TileSetImage {
|
||||
@@ -42,11 +42,8 @@ struct TileSetImage {
|
||||
unsigned tile_width, tile_height;
|
||||
};
|
||||
|
||||
boolean FDECL(read_bmp_tiles, (const char *filename,
|
||||
struct TileSetImage *image));
|
||||
boolean FDECL(read_gif_tiles, (const char *filename,
|
||||
struct TileSetImage *image));
|
||||
boolean FDECL(read_png_tiles, (const char *filename,
|
||||
struct TileSetImage *image));
|
||||
boolean read_bmp_tiles(const char *filename, struct TileSetImage *image);
|
||||
boolean read_gif_tiles(const char *filename, struct TileSetImage *image);
|
||||
boolean read_png_tiles(const char *filename, struct TileSetImage *image);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#define TIMEOUT_H
|
||||
|
||||
/* generic timeout function */
|
||||
typedef void FDECL((*timeout_proc), (ANY_P *, long));
|
||||
typedef void (*timeout_proc)(ANY_P *, long);
|
||||
|
||||
/* kind of timer */
|
||||
enum timer_type {
|
||||
|
||||
309
include/winX.h
309
include/winX.h
@@ -16,10 +16,6 @@
|
||||
#include "wintype.h" /* winid */
|
||||
#endif
|
||||
|
||||
#ifndef E
|
||||
#define E extern
|
||||
#endif
|
||||
|
||||
#if defined(BOS) || defined(NHSTDC)
|
||||
#define DIMENSION_P int
|
||||
#else
|
||||
@@ -258,17 +254,17 @@ struct xwindow {
|
||||
#define MAX_HISTORY 60 /* max history saved on message window */
|
||||
|
||||
/* Window variables (winX.c). */
|
||||
E struct xwindow window_list[MAX_WINDOWS];
|
||||
E XtAppContext app_context; /* context of application */
|
||||
E Widget toplevel; /* toplevel widget */
|
||||
E Atom wm_delete_window; /* delete window protocol */
|
||||
E boolean exit_x_event; /* exit condition for event loop */
|
||||
extern struct xwindow window_list[MAX_WINDOWS];
|
||||
extern XtAppContext app_context; /* context of application */
|
||||
extern Widget toplevel; /* toplevel widget */
|
||||
extern Atom wm_delete_window; /* delete window protocol */
|
||||
extern boolean exit_x_event; /* exit condition for event loop */
|
||||
#define EXIT_ON_KEY_PRESS 0 /* valid values for exit_x_event */
|
||||
#define EXIT_ON_KEY_OR_BUTTON_PRESS 1
|
||||
#define EXIT_ON_EXIT 2
|
||||
#define EXIT_ON_SENT_EVENT 3
|
||||
E int click_x, click_y, click_button, updated_inventory;
|
||||
E boolean plsel_ask_name;
|
||||
extern int click_x, click_y, click_button, updated_inventory;
|
||||
extern boolean plsel_ask_name;
|
||||
|
||||
typedef struct {
|
||||
Boolean slow; /* issue prompts between map and message wins */
|
||||
@@ -294,8 +290,8 @@ typedef struct {
|
||||
#endif
|
||||
} AppResources;
|
||||
|
||||
E AppResources appResources;
|
||||
E void (*input_func)();
|
||||
extern AppResources appResources;
|
||||
extern void (*input_func)(Widget, XEvent *, String *, Cardinal *);
|
||||
|
||||
extern struct window_procs X11_procs;
|
||||
|
||||
@@ -308,183 +304,178 @@ extern struct window_procs X11_procs;
|
||||
} while (0)
|
||||
|
||||
/* ### Window.c ### */
|
||||
E Font FDECL(WindowFont, (Widget));
|
||||
E XFontStruct *FDECL(WindowFontStruct, (Widget));
|
||||
extern Font WindowFont(Widget);
|
||||
extern XFontStruct *WindowFontStruct(Widget);
|
||||
|
||||
/* ### dialogs.c ### */
|
||||
E Widget FDECL(CreateDialog, (Widget, String, XtCallbackProc, XtCallbackProc));
|
||||
E void FDECL(SetDialogPrompt, (Widget, String));
|
||||
E String FDECL(GetDialogResponse, (Widget));
|
||||
E void FDECL(SetDialogResponse, (Widget, String, unsigned));
|
||||
E void FDECL(positionpopup, (Widget, BOOLEAN_P));
|
||||
extern Widget CreateDialog(Widget, String, XtCallbackProc, XtCallbackProc);
|
||||
extern void SetDialogPrompt(Widget, String);
|
||||
extern String GetDialogResponse(Widget);
|
||||
extern void SetDialogResponse(Widget, String, unsigned);
|
||||
extern void positionpopup(Widget, boolean);
|
||||
|
||||
/* ### winX.c ### */
|
||||
E struct xwindow *FDECL(find_widget, (Widget));
|
||||
E XColor FDECL(get_nhcolor, (struct xwindow *, int));
|
||||
E void FDECL(init_menu_nhcolors, (struct xwindow *));
|
||||
E void FDECL(load_boldfont, (struct xwindow *, Widget));
|
||||
E Boolean FDECL(nhApproxColor, (Screen *, Colormap, char *, XColor *));
|
||||
E Boolean FDECL(nhCvtStringToPixel, (Display *, XrmValuePtr, Cardinal *,
|
||||
XrmValuePtr, XrmValuePtr, XtPointer *));
|
||||
E void FDECL(get_window_frame_extents, (Widget,
|
||||
long *, long *, long *, long *));
|
||||
E void FDECL(get_widget_window_geometry, (Widget, int *, int *, int *, int *));
|
||||
E char *FDECL(fontname_boldify, (const char *));
|
||||
E Dimension FDECL(nhFontHeight, (Widget));
|
||||
E char FDECL(key_event_to_char, (XKeyEvent *));
|
||||
E void FDECL(msgkey, (Widget, XtPointer, XEvent *));
|
||||
E void FDECL(highlight_yn, (BOOLEAN_P));
|
||||
E void FDECL(nh_XtPopup, (Widget, int, Widget));
|
||||
E void FDECL(nh_XtPopdown, (Widget));
|
||||
E void FDECL(win_X11_init, (int));
|
||||
E void FDECL(find_scrollbars, (Widget, Widget *, Widget *));
|
||||
E void FDECL(nh_keyscroll, (Widget, XEvent *, String *, Cardinal *));
|
||||
extern struct xwindow *find_widget(Widget);
|
||||
extern XColor get_nhcolor(struct xwindow *, int);
|
||||
extern void init_menu_nhcolors(struct xwindow *);
|
||||
extern void load_boldfont(struct xwindow *, Widget);
|
||||
extern Boolean nhApproxColor(Screen *, Colormap, char *, XColor *);
|
||||
extern Boolean nhCvtStringToPixel(Display *, XrmValuePtr, Cardinal *,
|
||||
XrmValuePtr, XrmValuePtr, XtPointer *);
|
||||
extern void get_window_frame_extents(Widget, long *, long *, long *, long *);
|
||||
extern void get_widget_window_geometry(Widget, int *, int *, int *, int *);
|
||||
extern char *fontname_boldify(const char *);
|
||||
extern Dimension nhFontHeight(Widget);
|
||||
extern char key_event_to_char(XKeyEvent *);
|
||||
extern void msgkey(Widget, XtPointer, XEvent *);
|
||||
extern void highlight_yn(boolean);
|
||||
extern void nh_XtPopup(Widget, int, Widget);
|
||||
extern void nh_XtPopdown(Widget);
|
||||
extern void win_X11_init(int);
|
||||
extern void find_scrollbars(Widget, Widget *, Widget *);
|
||||
extern void nh_keyscroll(Widget, XEvent *, String *, Cardinal *);
|
||||
|
||||
/* ### winmesg.c ### */
|
||||
E void FDECL(set_message_slider, (struct xwindow *));
|
||||
E void FDECL(create_message_window, (struct xwindow *, BOOLEAN_P, Widget));
|
||||
E void FDECL(destroy_message_window, (struct xwindow *));
|
||||
E void FDECL(display_message_window, (struct xwindow *));
|
||||
E void FDECL(append_message, (struct xwindow *, const char *));
|
||||
E void FDECL(set_last_pause, (struct xwindow *));
|
||||
extern void set_message_slider(struct xwindow *);
|
||||
extern void create_message_window(struct xwindow *, boolean, Widget);
|
||||
extern void destroy_message_window(struct xwindow *);
|
||||
extern void display_message_window(struct xwindow *);
|
||||
extern void append_message(struct xwindow *, const char *);
|
||||
extern void set_last_pause(struct xwindow *);
|
||||
|
||||
/* ### winmap.c ### */
|
||||
E void NDECL(post_process_tiles);
|
||||
E void FDECL(check_cursor_visibility, (struct xwindow *));
|
||||
E void FDECL(display_map_window, (struct xwindow *));
|
||||
E void FDECL(clear_map_window, (struct xwindow *));
|
||||
E void FDECL(map_input, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(set_map_size, (struct xwindow *, DIMENSION_P, DIMENSION_P));
|
||||
E void FDECL(create_map_window, (struct xwindow *, BOOLEAN_P, Widget));
|
||||
E void FDECL(destroy_map_window, (struct xwindow *));
|
||||
E int FDECL(x_event, (int));
|
||||
extern void post_process_tiles(void);
|
||||
extern void check_cursor_visibility(struct xwindow *);
|
||||
extern void display_map_window(struct xwindow *);
|
||||
extern void clear_map_window(struct xwindow *);
|
||||
extern void map_input(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void set_map_size(struct xwindow *, Dimension, Dimension);
|
||||
extern void create_map_window(struct xwindow *, boolean, Widget);
|
||||
extern void destroy_map_window(struct xwindow *);
|
||||
extern int x_event(int);
|
||||
|
||||
/* ### winmenu.c ### */
|
||||
E void FDECL(menu_delete, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(menu_key, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(create_menu_window, (struct xwindow *));
|
||||
E void FDECL(destroy_menu_window, (struct xwindow *));
|
||||
extern void menu_delete(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void menu_key(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void create_menu_window(struct xwindow *);
|
||||
extern void destroy_menu_window(struct xwindow *);
|
||||
|
||||
/* ### winmisc.c ### */
|
||||
E XtPointer FDECL(i2xtp, (int));
|
||||
E int FDECL(xtp2i, (XtPointer));
|
||||
E void FDECL(ps_key, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* player selection action */
|
||||
E void FDECL(race_key, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* race selection action */
|
||||
E void FDECL(gend_key, (Widget, XEvent *, String *, Cardinal *)); /* gender */
|
||||
E void FDECL(algn_key,
|
||||
(Widget, XEvent *, String *, Cardinal *)); /* alignment */
|
||||
E void FDECL(ec_delete, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(ec_key, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* extended command action */
|
||||
E void FDECL(plsel_quit, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* player selection dialog */
|
||||
E void FDECL(plsel_play, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* player selection dialog */
|
||||
E void FDECL(plsel_randomize, (Widget, XEvent *, String *,
|
||||
Cardinal *)); /* player selection dialog */
|
||||
E void NDECL(release_extended_cmds);
|
||||
extern XtPointer i2xtp(int);
|
||||
extern int xtp2i(XtPointer);
|
||||
extern void ps_key(Widget, XEvent *, String *,
|
||||
Cardinal *); /* player selection action */
|
||||
extern void race_key(Widget, XEvent *, String *,
|
||||
Cardinal *); /* race selection action */
|
||||
extern void gend_key(Widget, XEvent *, String *, Cardinal *); /* gender */
|
||||
extern void algn_key(Widget, XEvent *, String *, Cardinal *); /* alignment */
|
||||
extern void ec_delete(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void ec_key(Widget, XEvent *, String *,
|
||||
Cardinal *); /* extended command action */
|
||||
extern void plsel_quit(Widget, XEvent *, String *,
|
||||
Cardinal *); /* player selection dialog */
|
||||
extern void plsel_play(Widget, XEvent *, String *,
|
||||
Cardinal *); /* player selection dialog */
|
||||
extern void plsel_randomize(Widget, XEvent *, String *,
|
||||
Cardinal *); /* player selection dialog */
|
||||
extern void release_extended_cmds(void);
|
||||
|
||||
/* ### winstatus.c ### */
|
||||
E void FDECL(create_status_window, (struct xwindow *, BOOLEAN_P, Widget));
|
||||
E void FDECL(destroy_status_window, (struct xwindow *));
|
||||
E void FDECL(adjust_status, (struct xwindow *, const char *));
|
||||
E void NDECL(null_out_status);
|
||||
E void NDECL(check_turn_events);
|
||||
extern void create_status_window(struct xwindow *, boolean, Widget);
|
||||
extern void destroy_status_window(struct xwindow *);
|
||||
extern void adjust_status(struct xwindow *, const char *);
|
||||
extern void null_out_status(void);
|
||||
extern void check_turn_events(void);
|
||||
|
||||
/* ### wintext.c ### */
|
||||
E void FDECL(delete_text, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(dismiss_text, (Widget, XEvent *, String *, Cardinal *));
|
||||
E void FDECL(key_dismiss_text, (Widget, XEvent *, String *, Cardinal *));
|
||||
extern void delete_text(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void dismiss_text(Widget, XEvent *, String *, Cardinal *);
|
||||
extern void key_dismiss_text(Widget, XEvent *, String *, Cardinal *);
|
||||
#ifdef GRAPHIC_TOMBSTONE
|
||||
E void FDECL(rip_dismiss_text, (Widget, XEvent *, String *, Cardinal *));
|
||||
extern void rip_dismiss_text(Widget, XEvent *, String *, Cardinal *);
|
||||
#endif
|
||||
E void FDECL(add_to_text_window, (struct xwindow *, int, const char *));
|
||||
E void FDECL(display_text_window, (struct xwindow *, BOOLEAN_P));
|
||||
E void FDECL(create_text_window, (struct xwindow *));
|
||||
E void FDECL(destroy_text_window, (struct xwindow *));
|
||||
E void FDECL(clear_text_window, (struct xwindow *));
|
||||
E void FDECL(append_text_buffer, (struct text_buffer *, const char *,
|
||||
BOOLEAN_P)); /* text buffer routines */
|
||||
E void FDECL(init_text_buffer, (struct text_buffer *));
|
||||
E void FDECL(clear_text_buffer, (struct text_buffer *));
|
||||
E void FDECL(free_text_buffer, (struct text_buffer *));
|
||||
extern void add_to_text_window(struct xwindow *, int, const char *);
|
||||
extern void display_text_window(struct xwindow *, boolean);
|
||||
extern void create_text_window(struct xwindow *);
|
||||
extern void destroy_text_window(struct xwindow *);
|
||||
extern void clear_text_window(struct xwindow *);
|
||||
extern void append_text_buffer(struct text_buffer *, const char *,
|
||||
boolean); /* text buffer routines */
|
||||
extern void init_text_buffer(struct text_buffer *);
|
||||
extern void clear_text_buffer(struct text_buffer *);
|
||||
extern void free_text_buffer(struct text_buffer *);
|
||||
#ifdef GRAPHIC_TOMBSTONE
|
||||
E void FDECL(calculate_rip_text, (int, time_t));
|
||||
extern void calculate_rip_text(int, time_t);
|
||||
#endif
|
||||
|
||||
/* ### winval.c ### */
|
||||
E Widget FDECL(create_value, (Widget, const char *));
|
||||
E void FDECL(set_name, (Widget, const char *));
|
||||
E void FDECL(set_name_width, (Widget, int));
|
||||
E int FDECL(get_name_width, (Widget));
|
||||
E Widget FDECL(get_value_widget, (Widget));
|
||||
E void FDECL(set_value, (Widget, const char *));
|
||||
E void FDECL(set_value_width, (Widget, int));
|
||||
E int FDECL(get_value_width, (Widget));
|
||||
E void FDECL(hilight_value, (Widget));
|
||||
E void FDECL(swap_fg_bg, (Widget));
|
||||
|
||||
extern Widget create_value(Widget, const char *);
|
||||
extern void set_name(Widget, const char *);
|
||||
extern void set_name_width(Widget, int);
|
||||
extern int get_name_width(Widget);
|
||||
extern Widget get_value_widget(Widget);
|
||||
extern void set_value_width(Widget, int);
|
||||
extern int get_value_width(Widget);
|
||||
extern void hilight_value(Widget);
|
||||
extern void swap_fg_bg(Widget);
|
||||
extern void set_value(Widget w, const char *new_value);
|
||||
/* external declarations */
|
||||
E char *FDECL(X11_getmsghistory, (BOOLEAN_P));
|
||||
E void FDECL(X11_putmsghistory, (const char *, BOOLEAN_P));
|
||||
E void FDECL(X11_init_nhwindows, (int *, char **));
|
||||
E void NDECL(X11_player_selection);
|
||||
E void NDECL(X11_askname);
|
||||
E void NDECL(X11_get_nh_event);
|
||||
E void FDECL(X11_exit_nhwindows, (const char *));
|
||||
E void FDECL(X11_suspend_nhwindows, (const char *));
|
||||
E void NDECL(X11_resume_nhwindows);
|
||||
E winid FDECL(X11_create_nhwindow, (int));
|
||||
E void FDECL(X11_clear_nhwindow, (winid));
|
||||
E void FDECL(X11_display_nhwindow, (winid, BOOLEAN_P));
|
||||
E void FDECL(X11_destroy_nhwindow, (winid));
|
||||
E void FDECL(X11_curs, (winid, int, int));
|
||||
E void FDECL(X11_putstr, (winid, int, const char *));
|
||||
E void FDECL(X11_display_file, (const char *, BOOLEAN_P));
|
||||
E void FDECL(X11_start_menu, (winid, unsigned long));
|
||||
E void FDECL(X11_add_menu, (winid, const glyph_info *, const ANY_P *,
|
||||
CHAR_P, CHAR_P, int,
|
||||
const char *, unsigned int));
|
||||
E void FDECL(X11_end_menu, (winid, const char *));
|
||||
E int FDECL(X11_select_menu, (winid, int, MENU_ITEM_P **));
|
||||
E void NDECL(X11_update_inventory);
|
||||
E void NDECL(X11_mark_synch);
|
||||
E void NDECL(X11_wait_synch);
|
||||
extern char *X11_getmsghistory(boolean);
|
||||
extern void X11_putmsghistory(const char *, boolean);
|
||||
extern void X11_init_nhwindows(int *, char **);
|
||||
extern void X11_player_selection(void);
|
||||
extern void X11_askname(void);
|
||||
extern void X11_get_nh_event(void);
|
||||
extern void X11_exit_nhwindows(const char *);
|
||||
extern void X11_suspend_nhwindows(const char *);
|
||||
extern void X11_resume_nhwindows(void);
|
||||
extern winid X11_create_nhwindow(int);
|
||||
extern void X11_clear_nhwindow(winid);
|
||||
extern void X11_display_nhwindow(winid, boolean);
|
||||
extern void X11_destroy_nhwindow(winid);
|
||||
extern void X11_curs(winid, int, int);
|
||||
extern void X11_putstr(winid, int, const char *);
|
||||
extern void X11_display_file(const char *, boolean);
|
||||
extern void X11_start_menu(winid, unsigned long);
|
||||
extern void X11_add_menu(winid, const glyph_info *, const ANY_P *, char,
|
||||
char, int, const char *, unsigned int);
|
||||
extern void X11_end_menu(winid, const char *);
|
||||
extern int X11_select_menu(winid, int, MENU_ITEM_P **);
|
||||
extern void X11_update_inventory(void);
|
||||
extern void X11_mark_synch(void);
|
||||
extern void X11_wait_synch(void);
|
||||
#ifdef CLIPPING
|
||||
E void FDECL(X11_cliparound, (int, int));
|
||||
extern void X11_cliparound(int, int);
|
||||
#endif
|
||||
E void FDECL(X11_print_glyph, (winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *, const glyph_info *));
|
||||
E void FDECL(X11_raw_print, (const char *));
|
||||
E void FDECL(X11_raw_print_bold, (const char *));
|
||||
E int NDECL(X11_nhgetch);
|
||||
E int FDECL(X11_nh_poskey, (int *, int *, int *));
|
||||
E void NDECL(X11_nhbell);
|
||||
E int NDECL(X11_doprev_message);
|
||||
E char FDECL(X11_yn_function, (const char *, const char *, CHAR_P));
|
||||
E void FDECL(X11_getlin, (const char *, char *));
|
||||
E int NDECL(X11_get_ext_cmd);
|
||||
E void FDECL(X11_number_pad, (int));
|
||||
E void NDECL(X11_delay_output);
|
||||
E void NDECL(X11_status_init);
|
||||
E void NDECL(X11_status_finish);
|
||||
E void FDECL(X11_status_enablefield, (int, const char *, const char *,
|
||||
BOOLEAN_P));
|
||||
E void FDECL(X11_status_update, (int, genericptr_t, int, int, int,
|
||||
unsigned long *));
|
||||
extern void X11_print_glyph(winid, xchar, xchar, const glyph_info *,
|
||||
const glyph_info *);
|
||||
extern void X11_raw_print(const char *);
|
||||
extern void X11_raw_print_bold(const char *);
|
||||
extern int X11_nhgetch(void);
|
||||
extern int X11_nh_poskey(int *, int *, int *);
|
||||
extern void X11_nhbell(void);
|
||||
extern int X11_doprev_message(void);
|
||||
extern char X11_yn_function(const char *, const char *, char);
|
||||
extern void X11_getlin(const char *, char *);
|
||||
extern int X11_get_ext_cmd(void);
|
||||
extern void X11_number_pad(int);
|
||||
extern void X11_delay_output(void);
|
||||
extern void X11_status_init(void);
|
||||
extern void X11_status_finish(void);
|
||||
extern void X11_status_enablefield(int, const char *, const char *, boolean);
|
||||
extern void X11_status_update(int, genericptr_t, int, int, int,
|
||||
unsigned long *);
|
||||
|
||||
/* other defs that really should go away (they're tty specific) */
|
||||
E void NDECL(X11_start_screen);
|
||||
E void NDECL(X11_end_screen);
|
||||
extern void X11_start_screen(void);
|
||||
extern void X11_end_screen(void);
|
||||
|
||||
#ifdef GRAPHIC_TOMBSTONE
|
||||
E void FDECL(X11_outrip, (winid, int, time_t));
|
||||
extern void X11_outrip(winid, int, time_t);
|
||||
#else
|
||||
E void FDECL(genl_outrip, (winid, int, time_t));
|
||||
extern void genl_outrip(winid, int, time_t);
|
||||
#endif
|
||||
|
||||
E void FDECL(X11_preference_update, (const char *));
|
||||
extern void X11_preference_update(const char *);
|
||||
|
||||
#endif /* WINX_H */
|
||||
|
||||
@@ -74,15 +74,15 @@ extern void curses_suspend_nhwindows(const char *str);
|
||||
extern void curses_resume_nhwindows(void);
|
||||
extern winid curses_create_nhwindow(int type);
|
||||
extern void curses_clear_nhwindow(winid wid);
|
||||
extern void curses_display_nhwindow(winid wid, BOOLEAN_P block);
|
||||
extern void curses_display_nhwindow(winid wid, boolean block);
|
||||
extern void curses_destroy_nhwindow(winid wid);
|
||||
extern void curses_curs(winid wid, int x, int y);
|
||||
extern void curses_putstr(winid wid, int attr, const char *text);
|
||||
extern void curses_display_file(const char *filename, BOOLEAN_P must_exist);
|
||||
extern void curses_display_file(const char *filename, boolean must_exist);
|
||||
extern void curses_start_menu(winid wid, unsigned long);
|
||||
extern void curses_add_menu(winid wid, const glyph_info *,
|
||||
const ANY_P * identifier,
|
||||
CHAR_P accelerator, CHAR_P group_accel, int attr,
|
||||
char accelerator, char group_accel, int attr,
|
||||
const char *str, unsigned int itemflags);
|
||||
extern void curses_end_menu(winid wid, const char *prompt);
|
||||
extern int curses_select_menu(winid wid, int how, MENU_ITEM_P **selected);
|
||||
@@ -90,7 +90,7 @@ extern void curses_update_inventory(void);
|
||||
extern void curses_mark_synch(void);
|
||||
extern void curses_wait_synch(void);
|
||||
extern void curses_cliparound(int x, int y);
|
||||
extern void curses_print_glyph(winid wid, XCHAR_P x, XCHAR_P y,
|
||||
extern void curses_print_glyph(winid wid, xchar x, xchar y,
|
||||
const glyph_info *, const glyph_info *);
|
||||
extern void curses_raw_print(const char *str);
|
||||
extern void curses_raw_print_bold(const char *str);
|
||||
@@ -99,7 +99,7 @@ extern int curses_nh_poskey(int *x, int *y, int *mod);
|
||||
extern void curses_nhbell(void);
|
||||
extern int curses_doprev_message(void);
|
||||
extern char curses_yn_function(const char *question, const char *choices,
|
||||
CHAR_P def);
|
||||
char def);
|
||||
extern void curses_getlin(const char *question, char *input);
|
||||
extern int curses_get_ext_cmd(void);
|
||||
extern void curses_number_pad(int state);
|
||||
@@ -172,12 +172,12 @@ extern void curses_mouse_support(int);
|
||||
extern void curses_line_input_dialog(const char *prompt,
|
||||
char *answer, int buffer);
|
||||
extern int curses_character_input_dialog(const char *prompt,
|
||||
const char *choices, CHAR_P def);
|
||||
const char *choices, char def);
|
||||
extern int curses_ext_cmd(void);
|
||||
extern void curses_create_nhmenu(winid wid, unsigned long);
|
||||
extern void curses_add_nhmenu_item(winid wid, const glyph_info *,
|
||||
const ANY_P *identifier, CHAR_P accelerator,
|
||||
CHAR_P group_accel, int attr,
|
||||
const ANY_P *identifier, char accelerator,
|
||||
char group_accel, int attr,
|
||||
const char *str, unsigned itemflags);
|
||||
extern void curs_menu_set_bottom_heavy(winid);
|
||||
extern void curses_finalize_nhmenu(winid wid, const char *prompt);
|
||||
@@ -196,7 +196,7 @@ extern void curses_status_update(int, genericptr_t, int, int, int,
|
||||
|
||||
extern void curses_update_inv(void);
|
||||
extern void curses_add_inv(int, const glyph_info *,
|
||||
CHAR_P, attr_t, const char *);
|
||||
char, attr_t, const char *);
|
||||
|
||||
/* cursinit.c */
|
||||
|
||||
@@ -222,8 +222,8 @@ extern void curses_init_mesg_history(void);
|
||||
extern void curses_teardown_messages(void);
|
||||
extern void curses_prev_mesg(void);
|
||||
extern void curses_count_window(const char *count_text);
|
||||
char *curses_getmsghistory(BOOLEAN_P);
|
||||
void curses_putmsghistory(const char *, BOOLEAN_P);
|
||||
char *curses_getmsghistory(boolean);
|
||||
void curses_putmsghistory(const char *, boolean);
|
||||
|
||||
#endif /* WINCURS_H */
|
||||
|
||||
|
||||
145
include/wingem.h
145
include/wingem.h
@@ -5,8 +5,6 @@
|
||||
#ifndef WINGEM_H
|
||||
#define WINGEM_H
|
||||
|
||||
#define E extern
|
||||
|
||||
/* menu structure */
|
||||
typedef struct Gmi {
|
||||
struct Gmi *Gmi_next;
|
||||
@@ -25,90 +23,89 @@ extern struct window_procs Gem_procs;
|
||||
|
||||
/* ### wingem1.c ### */
|
||||
#ifdef CLIPPING
|
||||
E void NDECL(setclipped);
|
||||
extern void setclipped(void);
|
||||
#endif
|
||||
E void FDECL(docorner, (int, int));
|
||||
E void NDECL(end_glyphout);
|
||||
E void FDECL(g_putch, (int));
|
||||
E void FDECL(win_Gem_init, (int));
|
||||
E int NDECL(mar_gem_init);
|
||||
E char NDECL(mar_ask_class);
|
||||
E char *NDECL(mar_ask_name);
|
||||
E int FDECL(mar_create_window, (int));
|
||||
E void FDECL(mar_destroy_nhwindow, (int));
|
||||
E void FDECL(mar_print_glyph, (int, int, int, const glyph_info *, const glyph_info *));
|
||||
E void FDECL(mar_print_line, (int, int, int, char *));
|
||||
E void FDECL(mar_set_message, (char *, char *, char *));
|
||||
E Gem_menu_item *NDECL(mar_hol_inv);
|
||||
E void FDECL(mar_set_menu_type, (int));
|
||||
E void NDECL(mar_reverse_menu);
|
||||
E void FDECL(mar_set_menu_title, (const char *));
|
||||
E void NDECL(mar_set_accelerators);
|
||||
E void FDECL(mar_add_menu, (winid, Gem_menu_item *));
|
||||
E void FDECL(mar_change_menu_2_text, (winid));
|
||||
E void FDECL(mar_add_message, (const char *));
|
||||
E void NDECL(mar_status_dirty);
|
||||
E int FDECL(mar_hol_win_type, (int));
|
||||
E void NDECL(mar_clear_messagewin);
|
||||
E void FDECL(mar_set_no_glyph, (int));
|
||||
E void NDECL(mar_map_curs_weiter);
|
||||
extern void docorner(int, int);
|
||||
extern void end_glyphout(void);
|
||||
extern void g_putch(int);
|
||||
extern void win_Gem_init(int);
|
||||
extern int mar_gem_init(void);
|
||||
extern char mar_ask_class(void);
|
||||
extern char *mar_ask_name(void);
|
||||
extern int mar_create_window(int);
|
||||
extern void mar_destroy_nhwindow(int);
|
||||
extern void mar_print_glyph(int, int, int, const glyph_info *,
|
||||
const glyph_info *);
|
||||
extern void mar_print_line(int, int, int, char *);
|
||||
extern void mar_set_message(char *, char *, char *);
|
||||
extern Gem_menu_item *mar_hol_inv(void);
|
||||
extern void mar_set_menu_type(int);
|
||||
extern void mar_reverse_menu(void);
|
||||
extern void mar_set_menu_title(const char *);
|
||||
extern void mar_set_accelerators(void);
|
||||
extern void mar_add_menu(winid, Gem_menu_item *);
|
||||
extern void mar_change_menu_2_text(winid);
|
||||
extern void mar_add_message(const char *);
|
||||
extern void mar_status_dirty(void);
|
||||
extern int mar_hol_win_type(int);
|
||||
extern void mar_clear_messagewin(void);
|
||||
extern void mar_set_no_glyph(int);
|
||||
extern void mar_map_curs_weiter(void);
|
||||
|
||||
/* external declarations */
|
||||
E void FDECL(Gem_init_nhwindows, (int *, char **));
|
||||
E void NDECL(Gem_player_selection);
|
||||
E void NDECL(Gem_askname);
|
||||
E void NDECL(Gem_get_nh_event);
|
||||
E void FDECL(Gem_exit_nhwindows, (const char *));
|
||||
E void FDECL(Gem_suspend_nhwindows, (const char *));
|
||||
E void NDECL(Gem_resume_nhwindows);
|
||||
E winid FDECL(Gem_create_nhwindow, (int));
|
||||
E void FDECL(Gem_clear_nhwindow, (winid));
|
||||
E void FDECL(Gem_display_nhwindow, (winid, BOOLEAN_P));
|
||||
E void FDECL(Gem_dismiss_nhwindow, (winid));
|
||||
E void FDECL(Gem_destroy_nhwindow, (winid));
|
||||
E void FDECL(Gem_curs, (winid, int, int));
|
||||
E void FDECL(Gem_putstr, (winid, int, const char *));
|
||||
E void FDECL(Gem_display_file, (const char *, BOOLEAN_P));
|
||||
E void FDECL(Gem_start_menu, (winid, unsigned long));
|
||||
E void FDECL(Gem_add_menu, (winid, const glyph_info *,
|
||||
const ANY_P *, CHAR_P, CHAR_P, int,
|
||||
const char *, unsigned int));
|
||||
E void FDECL(Gem_end_menu, (winid, const char *));
|
||||
E int FDECL(Gem_select_menu, (winid, int, MENU_ITEM_P **));
|
||||
E char FDECL(Gem_message_menu, (CHAR_P, int, const char *));
|
||||
E void NDECL(Gem_update_inventory);
|
||||
E void NDECL(Gem_mark_synch);
|
||||
E void NDECL(Gem_wait_synch);
|
||||
extern void Gem_init_nhwindows(int *, char **);
|
||||
extern void Gem_player_selection(void);
|
||||
extern void Gem_askname(void);
|
||||
extern void Gem_get_nh_event(void);
|
||||
extern void Gem_exit_nhwindows(const char *);
|
||||
extern void Gem_suspend_nhwindows(const char *);
|
||||
extern void Gem_resume_nhwindows(void);
|
||||
extern winid Gem_create_nhwindow(int);
|
||||
extern void Gem_clear_nhwindow(winid);
|
||||
extern void Gem_display_nhwindow(winid, boolean);
|
||||
extern void Gem_dismiss_nhwindow(winid);
|
||||
extern void Gem_destroy_nhwindow(winid);
|
||||
extern void Gem_curs(winid, int, int);
|
||||
extern void Gem_putstr(winid, int, const char *);
|
||||
extern void Gem_display_file(const char *, boolean);
|
||||
extern void Gem_start_menu(winid, unsigned long);
|
||||
extern void Gem_add_menu(winid, const glyph_info *, const ANY_P *, char, char,
|
||||
int, const char *, unsigned int);
|
||||
extern void Gem_end_menu(winid, const char *);
|
||||
extern int Gem_select_menu(winid, int, MENU_ITEM_P **);
|
||||
extern char Gem_message_menu(char, int, const char *);
|
||||
extern void Gem_update_inventory(void);
|
||||
extern void Gem_mark_synch(void);
|
||||
extern void Gem_wait_synch(void);
|
||||
#ifdef CLIPPING
|
||||
E void FDECL(Gem_cliparound, (int, int));
|
||||
extern void Gem_cliparound(int, int);
|
||||
#endif
|
||||
#ifdef POSITIONBAR
|
||||
E void FDECL(Gem_update_positionbar, (char *));
|
||||
extern void Gem_update_positionbar(char *);
|
||||
#endif
|
||||
E void FDECL(Gem_print_glyph, (winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *, const glyph_info *));
|
||||
E void FDECL(Gem_raw_print, (const char *));
|
||||
E void FDECL(Gem_raw_print_bold, (const char *));
|
||||
E int NDECL(Gem_nhgetch);
|
||||
E int FDECL(Gem_nh_poskey, (int *, int *, int *));
|
||||
E void NDECL(Gem_nhbell);
|
||||
E int NDECL(Gem_doprev_message);
|
||||
E char FDECL(Gem_yn_function, (const char *, const char *, CHAR_P));
|
||||
E void FDECL(Gem_getlin, (const char *, char *));
|
||||
E int NDECL(Gem_get_ext_cmd);
|
||||
E void FDECL(Gem_number_pad, (int));
|
||||
E void NDECL(Gem_delay_output);
|
||||
extern void Gem_print_glyph(winid, xchar, xchar, const glyph_info *,
|
||||
const glyph_info *);
|
||||
extern void Gem_raw_print(const char *);
|
||||
extern void Gem_raw_print_bold(const char *);
|
||||
extern int Gem_nhgetch(void);
|
||||
extern int Gem_nh_poskey(int *, int *, int *);
|
||||
extern void Gem_nhbell(void);
|
||||
extern int Gem_doprev_message(void);
|
||||
extern char Gem_yn_function(const char *, const char *, char);
|
||||
extern void Gem_getlin(const char *, char *);
|
||||
extern int Gem_get_ext_cmd(void);
|
||||
extern void Gem_number_pad(int);
|
||||
extern void Gem_delay_output(void);
|
||||
#ifdef CHANGE_COLOR
|
||||
E void FDECL(Gem_change_color, (int color, long rgb, int reverse));
|
||||
E char *NDECL(Gem_get_color_string);
|
||||
extern void Gem_change_color(int color, long rgb, int reverse);
|
||||
extern char *Gem_get_color_string(void);
|
||||
#endif
|
||||
|
||||
/* other defs that really should go away (they're tty specific) */
|
||||
E void NDECL(Gem_start_screen);
|
||||
E void NDECL(Gem_end_screen);
|
||||
extern void Gem_start_screen(void);
|
||||
extern void Gem_end_screen(void);
|
||||
|
||||
E void FDECL(genl_outrip, (winid, int, time_t));
|
||||
extern void genl_outrip(winid, int, time_t);
|
||||
|
||||
#undef E
|
||||
|
||||
#endif /* WINGEM_H */
|
||||
|
||||
@@ -15,74 +15,74 @@ struct window_procs {
|
||||
unsigned long wincap; /* window port capability options supported */
|
||||
unsigned long wincap2; /* additional window port capability options */
|
||||
boolean has_color[CLR_MAX];
|
||||
void FDECL((*win_init_nhwindows), (int *, char **));
|
||||
void NDECL((*win_player_selection));
|
||||
void NDECL((*win_askname));
|
||||
void NDECL((*win_get_nh_event));
|
||||
void FDECL((*win_exit_nhwindows), (const char *));
|
||||
void FDECL((*win_suspend_nhwindows), (const char *));
|
||||
void NDECL((*win_resume_nhwindows));
|
||||
winid FDECL((*win_create_nhwindow), (int));
|
||||
void FDECL((*win_clear_nhwindow), (winid));
|
||||
void FDECL((*win_display_nhwindow), (winid, BOOLEAN_P));
|
||||
void FDECL((*win_destroy_nhwindow), (winid));
|
||||
void FDECL((*win_curs), (winid, int, int));
|
||||
void FDECL((*win_putstr), (winid, int, const char *));
|
||||
void FDECL((*win_putmixed), (winid, int, const char *));
|
||||
void FDECL((*win_display_file), (const char *, BOOLEAN_P));
|
||||
void FDECL((*win_start_menu), (winid, unsigned long));
|
||||
void FDECL((*win_add_menu), (winid, const glyph_info *, const ANY_P *,
|
||||
CHAR_P, CHAR_P, int,
|
||||
const char *, unsigned int));
|
||||
void FDECL((*win_end_menu), (winid, const char *));
|
||||
int FDECL((*win_select_menu), (winid, int, MENU_ITEM_P **));
|
||||
char FDECL((*win_message_menu), (CHAR_P, int, const char *));
|
||||
void NDECL((*win_update_inventory));
|
||||
void NDECL((*win_mark_synch));
|
||||
void NDECL((*win_wait_synch));
|
||||
void (*win_init_nhwindows)(int *, char **);
|
||||
void (*win_player_selection)(void);
|
||||
void (*win_askname)(void);
|
||||
void (*win_get_nh_event)(void);
|
||||
void (*win_exit_nhwindows)(const char *);
|
||||
void (*win_suspend_nhwindows)(const char *);
|
||||
void (*win_resume_nhwindows)(void);
|
||||
winid (*win_create_nhwindow)(int);
|
||||
void (*win_clear_nhwindow)(winid);
|
||||
void (*win_display_nhwindow)(winid, boolean);
|
||||
void (*win_destroy_nhwindow)(winid);
|
||||
void (*win_curs)(winid, int, int);
|
||||
void (*win_putstr)(winid, int, const char *);
|
||||
void (*win_putmixed)(winid, int, const char *);
|
||||
void (*win_display_file)(const char *, boolean);
|
||||
void (*win_start_menu)(winid, unsigned long);
|
||||
void (*win_add_menu)(winid, const glyph_info *, const ANY_P *,
|
||||
char, char, int,
|
||||
const char *, unsigned int);
|
||||
void (*win_end_menu)(winid, const char *);
|
||||
int (*win_select_menu)(winid, int, MENU_ITEM_P **);
|
||||
char (*win_message_menu)(char, int, const char *);
|
||||
void (*win_update_inventory)(void);
|
||||
void (*win_mark_synch)(void);
|
||||
void (*win_wait_synch)(void);
|
||||
#ifdef CLIPPING
|
||||
void FDECL((*win_cliparound), (int, int));
|
||||
void (*win_cliparound)(int, int);
|
||||
#endif
|
||||
#ifdef POSITIONBAR
|
||||
void FDECL((*win_update_positionbar), (char *));
|
||||
void (*win_update_positionbar)(char *);
|
||||
#endif
|
||||
void FDECL((*win_print_glyph), (winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *, const glyph_info *));
|
||||
void FDECL((*win_raw_print), (const char *));
|
||||
void FDECL((*win_raw_print_bold), (const char *));
|
||||
int NDECL((*win_nhgetch));
|
||||
int FDECL((*win_nh_poskey), (int *, int *, int *));
|
||||
void NDECL((*win_nhbell));
|
||||
int NDECL((*win_doprev_message));
|
||||
char FDECL((*win_yn_function), (const char *, const char *, CHAR_P));
|
||||
void FDECL((*win_getlin), (const char *, char *));
|
||||
int NDECL((*win_get_ext_cmd));
|
||||
void FDECL((*win_number_pad), (int));
|
||||
void NDECL((*win_delay_output));
|
||||
void (*win_print_glyph)(winid, xchar, xchar,
|
||||
const glyph_info *, const glyph_info *);
|
||||
void (*win_raw_print)(const char *);
|
||||
void (*win_raw_print_bold)(const char *);
|
||||
int (*win_nhgetch)(void);
|
||||
int (*win_nh_poskey)(int *, int *, int *);
|
||||
void (*win_nhbell)(void);
|
||||
int (*win_doprev_message)(void);
|
||||
char (*win_yn_function)(const char *, const char *, char);
|
||||
void (*win_getlin)(const char *, char *);
|
||||
int (*win_get_ext_cmd)(void);
|
||||
void (*win_number_pad)(int);
|
||||
void (*win_delay_output)(void);
|
||||
#ifdef CHANGE_COLOR
|
||||
void FDECL((*win_change_color), (int, long, int));
|
||||
void (*win_change_color)(int, long, int);
|
||||
#ifdef MAC
|
||||
void FDECL((*win_change_background), (int));
|
||||
short FDECL((*win_set_font_name), (winid, char *));
|
||||
void (*win_change_background)(int);
|
||||
short (*win_set_font_name)(winid, char *);
|
||||
#endif
|
||||
char *NDECL((*win_get_color_string));
|
||||
char *(*win_get_color_string)(void);
|
||||
#endif
|
||||
|
||||
/* other defs that really should go away (they're tty specific) */
|
||||
void NDECL((*win_start_screen));
|
||||
void NDECL((*win_end_screen));
|
||||
void (*win_start_screen)(void);
|
||||
void (*win_end_screen)(void);
|
||||
|
||||
void FDECL((*win_outrip), (winid, int, time_t));
|
||||
void FDECL((*win_preference_update), (const char *));
|
||||
char *FDECL((*win_getmsghistory), (BOOLEAN_P));
|
||||
void FDECL((*win_putmsghistory), (const char *, BOOLEAN_P));
|
||||
void NDECL((*win_status_init));
|
||||
void NDECL((*win_status_finish));
|
||||
void FDECL((*win_status_enablefield),
|
||||
(int, const char *, const char *, BOOLEAN_P));
|
||||
void FDECL((*win_status_update), (int, genericptr_t, int, int, int,
|
||||
unsigned long *));
|
||||
boolean NDECL((*win_can_suspend));
|
||||
void (*win_outrip)(winid, int, time_t);
|
||||
void (*win_preference_update)(const char *);
|
||||
char *(*win_getmsghistory)(boolean);
|
||||
void (*win_putmsghistory)(const char *, boolean);
|
||||
void (*win_status_init)(void);
|
||||
void (*win_status_finish)(void);
|
||||
void (*win_status_enablefield)(int, const char *, const char *,
|
||||
boolean);
|
||||
void (*win_status_update)(int, genericptr_t, int, int, int,
|
||||
unsigned long *);
|
||||
boolean (*win_can_suspend)(void);
|
||||
};
|
||||
|
||||
extern
|
||||
@@ -317,76 +317,76 @@ struct chain_procs {
|
||||
* '+' are reserved for processors. */
|
||||
unsigned long wincap; /* window port capability options supported */
|
||||
unsigned long wincap2; /* additional window port capability options */
|
||||
void FDECL((*win_init_nhwindows), (CARGS, int *, char **));
|
||||
void FDECL((*win_player_selection), (CARGS));
|
||||
void FDECL((*win_askname), (CARGS));
|
||||
void FDECL((*win_get_nh_event), (CARGS));
|
||||
void FDECL((*win_exit_nhwindows), (CARGS, const char *));
|
||||
void FDECL((*win_suspend_nhwindows), (CARGS, const char *));
|
||||
void FDECL((*win_resume_nhwindows), (CARGS));
|
||||
winid FDECL((*win_create_nhwindow), (CARGS, int));
|
||||
void FDECL((*win_clear_nhwindow), (CARGS, winid));
|
||||
void FDECL((*win_display_nhwindow), (CARGS, winid, BOOLEAN_P));
|
||||
void FDECL((*win_destroy_nhwindow), (CARGS, winid));
|
||||
void FDECL((*win_curs), (CARGS, winid, int, int));
|
||||
void FDECL((*win_putstr), (CARGS, winid, int, const char *));
|
||||
void FDECL((*win_putmixed), (CARGS, winid, int, const char *));
|
||||
void FDECL((*win_display_file), (CARGS, const char *, BOOLEAN_P));
|
||||
void FDECL((*win_start_menu), (CARGS, winid, unsigned long));
|
||||
void FDECL((*win_add_menu), (CARGS, winid, const glyph_info *,
|
||||
const ANY_P *, CHAR_P, CHAR_P, int,
|
||||
const char *, unsigned int));
|
||||
void FDECL((*win_end_menu), (CARGS, winid, const char *));
|
||||
int FDECL((*win_select_menu), (CARGS, winid, int, MENU_ITEM_P **));
|
||||
char FDECL((*win_message_menu), (CARGS, CHAR_P, int, const char *));
|
||||
void FDECL((*win_update_inventory), (CARGS));
|
||||
void FDECL((*win_mark_synch), (CARGS));
|
||||
void FDECL((*win_wait_synch), (CARGS));
|
||||
void (*win_init_nhwindows)(CARGS, int *, char **);
|
||||
void (*win_player_selection)(CARGS);
|
||||
void (*win_askname)(CARGS);
|
||||
void (*win_get_nh_event)(CARGS);
|
||||
void (*win_exit_nhwindows)(CARGS, const char *);
|
||||
void (*win_suspend_nhwindows)(CARGS, const char *);
|
||||
void (*win_resume_nhwindows)(CARGS);
|
||||
winid (*win_create_nhwindow)(CARGS, int);
|
||||
void (*win_clear_nhwindow)(CARGS, winid);
|
||||
void (*win_display_nhwindow)(CARGS, winid, boolean);
|
||||
void (*win_destroy_nhwindow)(CARGS, winid);
|
||||
void (*win_curs)(CARGS, winid, int, int);
|
||||
void (*win_putstr)(CARGS, winid, int, const char *);
|
||||
void (*win_putmixed)(CARGS, winid, int, const char *);
|
||||
void (*win_display_file)(CARGS, const char *, boolean);
|
||||
void (*win_start_menu)(CARGS, winid, unsigned long);
|
||||
void (*win_add_menu)(CARGS, winid, const glyph_info *,
|
||||
const ANY_P *, char, char, int,
|
||||
const char *, unsigned int);
|
||||
void (*win_end_menu)(CARGS, winid, const char *);
|
||||
int (*win_select_menu)(CARGS, winid, int, MENU_ITEM_P **);
|
||||
char (*win_message_menu)(CARGS, char, int, const char *);
|
||||
void (*win_update_inventory)(CARGS);
|
||||
void (*win_mark_synch)(CARGS);
|
||||
void (*win_wait_synch)(CARGS);
|
||||
#ifdef CLIPPING
|
||||
void FDECL((*win_cliparound), (CARGS, int, int));
|
||||
void (*win_cliparound)(CARGS, int, int);
|
||||
#endif
|
||||
#ifdef POSITIONBAR
|
||||
void FDECL((*win_update_positionbar), (CARGS, char *));
|
||||
void (*win_update_positionbar)(CARGS, char *);
|
||||
#endif
|
||||
void FDECL((*win_print_glyph), (CARGS, winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *,
|
||||
const glyph_info *));
|
||||
void FDECL((*win_raw_print), (CARGS, const char *));
|
||||
void FDECL((*win_raw_print_bold), (CARGS, const char *));
|
||||
int FDECL((*win_nhgetch), (CARGS));
|
||||
int FDECL((*win_nh_poskey), (CARGS, int *, int *, int *));
|
||||
void FDECL((*win_nhbell), (CARGS));
|
||||
int FDECL((*win_doprev_message), (CARGS));
|
||||
char FDECL((*win_yn_function),
|
||||
(CARGS, const char *, const char *, CHAR_P));
|
||||
void FDECL((*win_getlin), (CARGS, const char *, char *));
|
||||
int FDECL((*win_get_ext_cmd), (CARGS));
|
||||
void FDECL((*win_number_pad), (CARGS, int));
|
||||
void FDECL((*win_delay_output), (CARGS));
|
||||
void (*win_print_glyph)(CARGS, winid, xchar, xchar,
|
||||
const glyph_info *,
|
||||
const glyph_info *);
|
||||
void (*win_raw_print)(CARGS, const char *);
|
||||
void (*win_raw_print_bold)(CARGS, const char *);
|
||||
int (*win_nhgetch)(CARGS);
|
||||
int (*win_nh_poskey)(CARGS, int *, int *, int *);
|
||||
void (*win_nhbell)(CARGS);
|
||||
int (*win_doprev_message)(CARGS);
|
||||
char (*win_yn_function),
|
||||
(CARGS, const char *, const char *, char);
|
||||
void (*win_getlin)(CARGS, const char *, char *);
|
||||
int (*win_get_ext_cmd)(CARGS);
|
||||
void (*win_number_pad)(CARGS, int);
|
||||
void (*win_delay_output)(CARGS);
|
||||
#ifdef CHANGE_COLOR
|
||||
void FDECL((*win_change_color), (CARGS, int, long, int));
|
||||
void (*win_change_color)(CARGS, int, long, int);
|
||||
#ifdef MAC
|
||||
void FDECL((*win_change_background), (CARGS, int));
|
||||
short FDECL((*win_set_font_name), (CARGS, winid, char *));
|
||||
void (*win_change_background)(CARGS, int);
|
||||
short (*win_set_font_name)(CARGS, winid, char *);
|
||||
#endif
|
||||
char *FDECL((*win_get_color_string), (CARGS));
|
||||
char *(*win_get_color_string)(CARGS);
|
||||
#endif
|
||||
|
||||
/* other defs that really should go away (they're tty specific) */
|
||||
void FDECL((*win_start_screen), (CARGS));
|
||||
void FDECL((*win_end_screen), (CARGS));
|
||||
void (*win_start_screen)(CARGS);
|
||||
void (*win_end_screen)(CARGS);
|
||||
|
||||
void FDECL((*win_outrip), (CARGS, winid, int, time_t));
|
||||
void FDECL((*win_preference_update), (CARGS, const char *));
|
||||
char *FDECL((*win_getmsghistory), (CARGS, BOOLEAN_P));
|
||||
void FDECL((*win_putmsghistory), (CARGS, const char *, BOOLEAN_P));
|
||||
void FDECL((*win_status_init), (CARGS));
|
||||
void FDECL((*win_status_finish), (CARGS));
|
||||
void FDECL((*win_status_enablefield),
|
||||
(CARGS, int, const char *, const char *, BOOLEAN_P));
|
||||
void FDECL((*win_status_update), (CARGS, int, genericptr_t, int, int, int,
|
||||
unsigned long *));
|
||||
boolean FDECL((*win_can_suspend), (CARGS));
|
||||
void (*win_outrip)(CARGS, winid, int, time_t);
|
||||
void (*win_preference_update)(CARGS, const char *);
|
||||
char *(*win_getmsghistory)(CARGS, boolean);
|
||||
void (*win_putmsghistory)(CARGS, const char *, boolean);
|
||||
void (*win_status_init)(CARGS);
|
||||
void (*win_status_finish)(CARGS);
|
||||
void (*win_status_enablefield),
|
||||
(CARGS, int, const char *, const char *, boolean);
|
||||
void (*win_status_update)(CARGS, int, genericptr_t, int, int, int,
|
||||
unsigned long *);
|
||||
boolean (*win_can_suspend)(CARGS);
|
||||
};
|
||||
#endif /* WINCHAIN */
|
||||
|
||||
@@ -394,76 +394,76 @@ struct chain_procs {
|
||||
/*
|
||||
* window port routines available in sys/share/safeproc.c
|
||||
*/
|
||||
extern struct window_procs *FDECL(get_safe_procs, (int));
|
||||
extern void FDECL(safe_init_nhwindows, (int *, char **));
|
||||
extern void NDECL(safe_player_selection);
|
||||
extern void NDECL(safe_askname);
|
||||
extern void NDECL(safe_get_nh_event);
|
||||
extern void FDECL(safe_exit_nhwindows, (const char *));
|
||||
extern void FDECL(safe_suspend_nhwindows, (const char *));
|
||||
extern void NDECL(safe_resume_nhwindows);
|
||||
extern winid FDECL(safe_create_nhwindow, (int));
|
||||
extern void FDECL(safe_clear_nhwindow, (winid));
|
||||
extern void FDECL(safe_display_nhwindow, (winid, BOOLEAN_P));
|
||||
extern void FDECL(safe_destroy_nhwindow, (winid));
|
||||
extern void FDECL(safe_curs, (winid, int, int));
|
||||
extern void FDECL(safe_putstr, (winid, int, const char *));
|
||||
extern void FDECL(safe_putmixed, (winid, int, const char *));
|
||||
extern void FDECL(safe_display_file, (const char *, BOOLEAN_P));
|
||||
extern void FDECL(safe_start_menu, (winid, unsigned long));
|
||||
extern void FDECL(safe_add_menu, (winid, const glyph_info *, const ANY_P *,
|
||||
CHAR_P, CHAR_P, int, const char *,
|
||||
unsigned int));
|
||||
extern void FDECL(safe_end_menu, (winid, const char *));
|
||||
extern int FDECL(safe_select_menu, (winid, int, MENU_ITEM_P **));
|
||||
extern char FDECL(safe_message_menu, (CHAR_P, int, const char *));
|
||||
extern void NDECL(safe_update_inventory);
|
||||
extern void NDECL(safe_mark_synch);
|
||||
extern void NDECL(safe_wait_synch);
|
||||
extern struct window_procs *get_safe_procs(int);
|
||||
extern void safe_init_nhwindows(int *, char **);
|
||||
extern void safe_player_selection(void);
|
||||
extern void safe_askname(void);
|
||||
extern void safe_get_nh_event(void);
|
||||
extern void safe_exit_nhwindows(const char *);
|
||||
extern void safe_suspend_nhwindows(const char *);
|
||||
extern void safe_resume_nhwindows(void);
|
||||
extern winid safe_create_nhwindow(int);
|
||||
extern void safe_clear_nhwindow(winid);
|
||||
extern void safe_display_nhwindow(winid, boolean);
|
||||
extern void safe_destroy_nhwindow(winid);
|
||||
extern void safe_curs(winid, int, int);
|
||||
extern void safe_putstr(winid, int, const char *);
|
||||
extern void safe_putmixed(winid, int, const char *);
|
||||
extern void safe_display_file(const char *, boolean);
|
||||
extern void safe_start_menu(winid, unsigned long);
|
||||
extern void safe_add_menu(winid, const glyph_info *, const ANY_P *,
|
||||
char, char, int, const char *,
|
||||
unsigned int);
|
||||
extern void safe_end_menu(winid, const char *);
|
||||
extern int safe_select_menu(winid, int, MENU_ITEM_P **);
|
||||
extern char safe_message_menu(char, int, const char *);
|
||||
extern void safe_update_inventory(void);
|
||||
extern void safe_mark_synch(void);
|
||||
extern void safe_wait_synch(void);
|
||||
#ifdef CLIPPING
|
||||
extern void FDECL(safe_cliparound, (int, int));
|
||||
extern void safe_cliparound(int, int);
|
||||
#endif
|
||||
#ifdef POSITIONBAR
|
||||
extern void FDECL(safe_update_positionbar, (char *));
|
||||
extern void safe_update_positionbar(char *);
|
||||
#endif
|
||||
extern void FDECL(safe_print_glyph, (winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *, const glyph_info *));
|
||||
extern void FDECL(safe_raw_print, (const char *));
|
||||
extern void FDECL(safe_raw_print_bold, (const char *));
|
||||
extern int NDECL(safe_nhgetch);
|
||||
extern int FDECL(safe_nh_poskey, (int *, int *, int *));
|
||||
extern void NDECL(safe_nhbell);
|
||||
extern int NDECL(safe_doprev_message);
|
||||
extern char FDECL(safe_yn_function, (const char *, const char *, CHAR_P));
|
||||
extern void FDECL(safe_getlin, (const char *, char *));
|
||||
extern int NDECL(safe_get_ext_cmd);
|
||||
extern void FDECL(safe_number_pad, (int));
|
||||
extern void NDECL(safe_delay_output);
|
||||
extern void safe_print_glyph(winid, xchar, xchar,
|
||||
const glyph_info *, const glyph_info *);
|
||||
extern void safe_raw_print(const char *);
|
||||
extern void safe_raw_print_bold(const char *);
|
||||
extern int safe_nhgetch(void);
|
||||
extern int safe_nh_poskey(int *, int *, int *);
|
||||
extern void safe_nhbell(void);
|
||||
extern int safe_doprev_message(void);
|
||||
extern char safe_yn_function(const char *, const char *, char);
|
||||
extern void safe_getlin(const char *, char *);
|
||||
extern int safe_get_ext_cmd(void);
|
||||
extern void safe_number_pad(int);
|
||||
extern void safe_delay_output(void);
|
||||
#ifdef CHANGE_COLOR
|
||||
extern void FDECL(safe_change_color, (int, long, int));
|
||||
extern void safe_change_color(int, long, int);
|
||||
#ifdef MAC
|
||||
extern void FDECL(safe_change_background, (int));
|
||||
extern short FDECL(safe_set_font_name, (winid, char *));
|
||||
extern void safe_change_background(int);
|
||||
extern short safe_set_font_name(winid, char *);
|
||||
#endif
|
||||
extern char *NDECL(safe_get_color_string);
|
||||
extern char *safe_get_color_string(void);
|
||||
#endif
|
||||
extern void NDECL(safe_start_screen);
|
||||
extern void NDECL(safe_end_screen);
|
||||
extern void FDECL(safe_outrip, (winid, int, time_t));
|
||||
extern void FDECL(safe_preference_update, (const char *));
|
||||
extern char *FDECL(safe_getmsghistory, (BOOLEAN_P));
|
||||
extern void FDECL(safe_putmsghistory, (const char *, BOOLEAN_P));
|
||||
extern void NDECL(safe_status_init);
|
||||
extern void NDECL(safe_status_finish);
|
||||
extern void FDECL(safe_status_enablefield, (int, const char *, const char *,
|
||||
BOOLEAN_P));
|
||||
extern void FDECL(safe_status_update, (int, genericptr_t, int, int, int,
|
||||
unsigned long *));
|
||||
extern boolean NDECL(safe_can_suspend);
|
||||
extern void FDECL(stdio_raw_print, (const char *));
|
||||
extern void FDECL(stdio_nonl_raw_print, (const char *));
|
||||
extern void FDECL(stdio_raw_print_bold, (const char *));
|
||||
extern void NDECL(stdio_wait_synch);
|
||||
extern int NDECL(stdio_nhgetch);
|
||||
extern void safe_start_screen(void);
|
||||
extern void safe_end_screen(void);
|
||||
extern void safe_outrip(winid, int, time_t);
|
||||
extern void safe_preference_update(const char *);
|
||||
extern char *safe_getmsghistory(boolean);
|
||||
extern void safe_putmsghistory(const char *, boolean);
|
||||
extern void safe_status_init(void);
|
||||
extern void safe_status_finish(void);
|
||||
extern void safe_status_enablefield(int, const char *, const char *,
|
||||
boolean);
|
||||
extern void safe_status_update(int, genericptr_t, int, int, int,
|
||||
unsigned long *);
|
||||
extern boolean safe_can_suspend(void);
|
||||
extern void stdio_raw_print(const char *);
|
||||
extern void stdio_nonl_raw_print(const char *);
|
||||
extern void stdio_raw_print_bold(const char *);
|
||||
extern void stdio_wait_synch(void);
|
||||
extern int stdio_nhgetch(void);
|
||||
#endif /* SAFEPROCS */
|
||||
#endif /* WINPROCS_H */
|
||||
|
||||
190
include/wintty.h
190
include/wintty.h
@@ -114,35 +114,35 @@ extern char defmorestr[]; /* default --more-- prompt */
|
||||
/* port specific external function references */
|
||||
|
||||
/* ### getline.c ### */
|
||||
E void FDECL(xwaitforspace, (const char *));
|
||||
E void xwaitforspace(const char *);
|
||||
|
||||
/* ### termcap.c, video.c ### */
|
||||
|
||||
E void FDECL(tty_startup, (int *, int *));
|
||||
E void tty_startup(int *, int *);
|
||||
#ifndef NO_TERMS
|
||||
E void NDECL(tty_shutdown);
|
||||
E void tty_shutdown(void);
|
||||
#endif
|
||||
E int FDECL(xputc, (int));
|
||||
E void FDECL(xputs, (const char *));
|
||||
E int xputc(int);
|
||||
E void xputs(const char *);
|
||||
#if defined(SCREEN_VGA) || defined(SCREEN_8514)
|
||||
E void FDECL(xputg, (int, int, unsigned));
|
||||
E void xputg(int, int, unsigned);
|
||||
#endif
|
||||
E void NDECL(cl_end);
|
||||
E void NDECL(clear_screen);
|
||||
E void NDECL(home);
|
||||
E void NDECL(standoutbeg);
|
||||
E void NDECL(standoutend);
|
||||
E void cl_end(void);
|
||||
E void clear_screen(void);
|
||||
E void home(void);
|
||||
E void standoutbeg(void);
|
||||
E void standoutend(void);
|
||||
#if 0
|
||||
E void NDECL(revbeg);
|
||||
E void NDECL(boldbeg);
|
||||
E void NDECL(blinkbeg);
|
||||
E void NDECL(dimbeg);
|
||||
E void NDECL(m_end);
|
||||
E void revbeg(void);
|
||||
E void boldbeg(void);
|
||||
E void blinkbeg(void);
|
||||
E void dimbeg(void);
|
||||
E void m_end(void);
|
||||
#endif
|
||||
E void NDECL(backsp);
|
||||
E void NDECL(graph_on);
|
||||
E void NDECL(graph_off);
|
||||
E void NDECL(cl_eos);
|
||||
E void backsp(void);
|
||||
E void graph_on(void);
|
||||
E void graph_off(void);
|
||||
E void cl_eos(void);
|
||||
|
||||
/*
|
||||
* termcap.c (or facsimiles in other ports) is the right place for doing
|
||||
@@ -150,102 +150,100 @@ E void NDECL(cl_eos);
|
||||
* a color or whatever. wintty.c should concern itself with WHERE to put
|
||||
* stuff in a window.
|
||||
*/
|
||||
E int FDECL(term_attr_fixup, (int));
|
||||
E void FDECL(term_start_attr, (int attr));
|
||||
E void FDECL(term_end_attr, (int attr));
|
||||
E void NDECL(term_start_raw_bold);
|
||||
E void NDECL(term_end_raw_bold);
|
||||
E int term_attr_fixup(int);
|
||||
E void term_start_attr(int attr);
|
||||
E void term_end_attr(int attr);
|
||||
E void term_start_raw_bold(void);
|
||||
E void term_end_raw_bold(void);
|
||||
|
||||
#ifdef TEXTCOLOR
|
||||
E void NDECL(term_end_color);
|
||||
E void FDECL(term_start_color, (int color));
|
||||
E void term_end_color(void);
|
||||
E void term_start_color(int color);
|
||||
#endif /* TEXTCOLOR */
|
||||
|
||||
/* ### topl.c ### */
|
||||
|
||||
E void FDECL(show_topl, (const char *));
|
||||
E void NDECL(remember_topl);
|
||||
E void FDECL(addtopl, (const char *));
|
||||
E void NDECL(more);
|
||||
E void FDECL(update_topl, (const char *));
|
||||
E void FDECL(putsyms, (const char *));
|
||||
E void show_topl(const char *);
|
||||
E void remember_topl(void);
|
||||
E void addtopl(const char *);
|
||||
E void more(void);
|
||||
E void update_topl(const char *);
|
||||
E void putsyms(const char *);
|
||||
|
||||
/* ### wintty.c ### */
|
||||
#ifdef CLIPPING
|
||||
E void NDECL(setclipped);
|
||||
E void setclipped(void);
|
||||
#endif
|
||||
E void FDECL(docorner, (int, int));
|
||||
E void NDECL(end_glyphout);
|
||||
E void FDECL(g_putch, (int));
|
||||
E void FDECL(win_tty_init, (int));
|
||||
E void docorner(int, int);
|
||||
E void end_glyphout(void);
|
||||
E void g_putch(int);
|
||||
E void win_tty_init(int);
|
||||
|
||||
/* external declarations */
|
||||
E void FDECL(tty_init_nhwindows, (int *, char **));
|
||||
E void FDECL(tty_preference_update, (const char *));
|
||||
E void NDECL(tty_player_selection);
|
||||
E void NDECL(tty_askname);
|
||||
E void NDECL(tty_get_nh_event);
|
||||
E void FDECL(tty_exit_nhwindows, (const char *));
|
||||
E void FDECL(tty_suspend_nhwindows, (const char *));
|
||||
E void NDECL(tty_resume_nhwindows);
|
||||
E winid FDECL(tty_create_nhwindow, (int));
|
||||
E void FDECL(tty_clear_nhwindow, (winid));
|
||||
E void FDECL(tty_display_nhwindow, (winid, BOOLEAN_P));
|
||||
E void FDECL(tty_dismiss_nhwindow, (winid));
|
||||
E void FDECL(tty_destroy_nhwindow, (winid));
|
||||
E void FDECL(tty_curs, (winid, int, int));
|
||||
E void FDECL(tty_putstr, (winid, int, const char *));
|
||||
E void FDECL(tty_display_file, (const char *, BOOLEAN_P));
|
||||
E void FDECL(tty_start_menu, (winid, unsigned long));
|
||||
E void FDECL(tty_add_menu, (winid, const glyph_info *, const ANY_P *,
|
||||
CHAR_P, CHAR_P, int, const char *,
|
||||
unsigned int));
|
||||
E void FDECL(tty_end_menu, (winid, const char *));
|
||||
E int FDECL(tty_select_menu, (winid, int, MENU_ITEM_P **));
|
||||
E char FDECL(tty_message_menu, (CHAR_P, int, const char *));
|
||||
E void NDECL(tty_update_inventory);
|
||||
E void NDECL(tty_mark_synch);
|
||||
E void NDECL(tty_wait_synch);
|
||||
E void tty_init_nhwindows(int *, char **);
|
||||
E void tty_preference_update(const char *);
|
||||
E void tty_player_selection(void);
|
||||
E void tty_askname(void);
|
||||
E void tty_get_nh_event(void);
|
||||
E void tty_exit_nhwindows(const char *);
|
||||
E void tty_suspend_nhwindows(const char *);
|
||||
E void tty_resume_nhwindows(void);
|
||||
E winid tty_create_nhwindow(int);
|
||||
E void tty_clear_nhwindow(winid);
|
||||
E void tty_display_nhwindow(winid, boolean);
|
||||
E void tty_dismiss_nhwindow(winid);
|
||||
E void tty_destroy_nhwindow(winid);
|
||||
E void tty_curs(winid, int, int);
|
||||
E void tty_putstr(winid, int, const char *);
|
||||
E void tty_display_file(const char *, boolean);
|
||||
E void tty_start_menu(winid, unsigned long);
|
||||
E void tty_add_menu(winid, const glyph_info *, const ANY_P *, char, char,
|
||||
int, const char *, unsigned int);
|
||||
E void tty_end_menu(winid, const char *);
|
||||
E int tty_select_menu(winid, int, MENU_ITEM_P **);
|
||||
E char tty_message_menu(char, int, const char *);
|
||||
E void tty_update_inventory(void);
|
||||
E void tty_mark_synch(void);
|
||||
E void tty_wait_synch(void);
|
||||
#ifdef CLIPPING
|
||||
E void FDECL(tty_cliparound, (int, int));
|
||||
E void tty_cliparound(int, int);
|
||||
#endif
|
||||
#ifdef POSITIONBAR
|
||||
E void FDECL(tty_update_positionbar, (char *));
|
||||
E void tty_update_positionbar(char *);
|
||||
#endif
|
||||
E void FDECL(tty_print_glyph, (winid, XCHAR_P, XCHAR_P,
|
||||
const glyph_info *, const glyph_info *));
|
||||
E void FDECL(tty_raw_print, (const char *));
|
||||
E void FDECL(tty_raw_print_bold, (const char *));
|
||||
E int NDECL(tty_nhgetch);
|
||||
E int FDECL(tty_nh_poskey, (int *, int *, int *));
|
||||
E void NDECL(tty_nhbell);
|
||||
E int NDECL(tty_doprev_message);
|
||||
E char FDECL(tty_yn_function, (const char *, const char *, CHAR_P));
|
||||
E void FDECL(tty_getlin, (const char *, char *));
|
||||
E int NDECL(tty_get_ext_cmd);
|
||||
E void FDECL(tty_number_pad, (int));
|
||||
E void NDECL(tty_delay_output);
|
||||
E void tty_print_glyph(winid, xchar, xchar, const glyph_info *,
|
||||
const glyph_info *);
|
||||
E void tty_raw_print(const char *);
|
||||
E void tty_raw_print_bold(const char *);
|
||||
E int tty_nhgetch(void);
|
||||
E int tty_nh_poskey(int *, int *, int *);
|
||||
E void tty_nhbell(void);
|
||||
E int tty_doprev_message(void);
|
||||
E char tty_yn_function(const char *, const char *, char);
|
||||
E void tty_getlin(const char *, char *);
|
||||
E int tty_get_ext_cmd(void);
|
||||
E void tty_number_pad(int);
|
||||
E void tty_delay_output(void);
|
||||
#ifdef CHANGE_COLOR
|
||||
E void FDECL(tty_change_color, (int color, long rgb, int reverse));
|
||||
E void tty_change_color(int color, long rgb, int reverse);
|
||||
#ifdef MAC
|
||||
E void FDECL(tty_change_background, (int white_or_black));
|
||||
E short FDECL(set_tty_font_name, (winid, char *));
|
||||
E void tty_change_background(int white_or_black);
|
||||
E short set_tty_font_name(winid, char *);
|
||||
#endif
|
||||
E char *NDECL(tty_get_color_string);
|
||||
E char *tty_get_color_string(void);
|
||||
#endif
|
||||
E void FDECL(tty_status_enablefield,
|
||||
(int, const char *, const char *, BOOLEAN_P));
|
||||
E void NDECL(tty_status_init);
|
||||
E void FDECL(tty_status_update, (int, genericptr_t, int, int, int, unsigned long *));
|
||||
E void tty_status_enablefield(int, const char *, const char *, boolean);
|
||||
E void tty_status_init(void);
|
||||
E void tty_status_update(int, genericptr_t, int, int, int, unsigned long *);
|
||||
|
||||
/* other defs that really should go away (they're tty specific) */
|
||||
E void NDECL(tty_start_screen);
|
||||
E void NDECL(tty_end_screen);
|
||||
E void tty_start_screen(void);
|
||||
E void tty_end_screen(void);
|
||||
|
||||
E void FDECL(genl_outrip, (winid, int, time_t));
|
||||
E void genl_outrip(winid, int, time_t);
|
||||
|
||||
E char *FDECL(tty_getmsghistory, (BOOLEAN_P));
|
||||
E void FDECL(tty_putmsghistory, (const char *, BOOLEAN_P));
|
||||
E char *tty_getmsghistory(boolean);
|
||||
E void tty_putmsghistory(const char *, boolean);
|
||||
|
||||
#ifdef NO_TERMS
|
||||
#ifdef MAC
|
||||
@@ -256,9 +254,9 @@ E void FDECL(tty_putmsghistory, (const char *, BOOLEAN_P));
|
||||
#define putchar term_putc
|
||||
#define fflush term_flush
|
||||
#define puts term_puts
|
||||
E int FDECL(term_putc, (int c));
|
||||
E int FDECL(term_flush, (void *desc));
|
||||
E int FDECL(term_puts, (const char *str));
|
||||
E int term_putc(int c);
|
||||
E int term_flush(void *desc);
|
||||
E int term_puts(const char *str);
|
||||
#endif /* MAC */
|
||||
#if defined(MSDOS) || defined(WIN32)
|
||||
#if defined(SCREEN_BIOS) || defined(SCREEN_DJGPPFAST) || defined(WIN32)
|
||||
@@ -270,7 +268,7 @@ E int FDECL(term_puts, (const char *str));
|
||||
#define puts(x) xputs(x)
|
||||
#endif /*SCREEN_BIOS || SCREEN_DJGPPFAST || WIN32 */
|
||||
#ifdef POSITIONBAR
|
||||
E void FDECL(video_update_positionbar, (char *));
|
||||
E void video_update_positionbar(char *);
|
||||
#endif
|
||||
#endif /*MSDOS*/
|
||||
#endif /*NO_TERMS*/
|
||||
|
||||
@@ -24,7 +24,7 @@ typedef union any {
|
||||
unsigned long *a_ulptr;
|
||||
unsigned *a_uptr;
|
||||
const char *a_string;
|
||||
int NDECL((*a_nfunc));
|
||||
int (*a_nfunc)(void);
|
||||
unsigned long a_mask32; /* used by status highlighting */
|
||||
/* add types as needed */
|
||||
} anything;
|
||||
|
||||
Reference in New Issue
Block a user