some tty updates

Add a note about NO_TERMS to include/wintty.h for clarity.

Rename tty_startup and tty_shutdown to term_startup() and
term_shutdown(). They are found in termcap.c for !NO_TERMS
like most of the other term_ routines, as well as having
versions for several of the NO_TERMS platforms. They aren't
part of the tty_interface called from the core. The tty
implementation does call and rely on them.

Remove some conditional #ifdef's around term_shutdown()
(formerly tty_shutdown()) and just ensure that all the
tty platforms have an implementation that they can link
with, even if it is just a stub presently.

Put the protype for nethack_exit in extern.h to reduce
maintenance to a single spot, and remove it from other
locations. A warning in the msdos cross-compile led to
this change.
This commit is contained in:
nhmall
2025-01-04 19:01:34 -05:00
parent 7982c72e8b
commit 37758c7e48
18 changed files with 293 additions and 100 deletions
+9 -2
View File
@@ -55,6 +55,7 @@
#endif
#define GETCURPOS 0x03 /* Get Cursor Position */
#define SETCURTYP 0x01 /* Set Cursor Type */
#define GETMODE 0x0f /* Get Video Mode */
#define SETMODE 0x00 /* Set Video Mode */
#define SETPAGE 0x05 /* Set Video Page */
@@ -248,6 +249,8 @@ extern void txt_nhbell(void);
extern void txt_startup(int *, int *);
extern void txt_xputs(const char *, int, int);
extern void txt_xputc(char, int);
extern void txt_hide_cursor(void);
extern void txt_show_cursor(void);
/* ### vidvga.c ### */
@@ -258,6 +261,8 @@ extern void vga_clear_screen(int);
extern void vga_cl_end(int, int);
extern void vga_cl_eos(int);
extern int vga_detect(void);
extern void vga_hide_cursor(void);
extern void vga_show_cursor(void);
#ifdef SIMULATE_CURSOR
extern void vga_DrawCursor(void);
#endif
@@ -273,7 +278,7 @@ extern void vga_HideCursor(void);
#endif
extern void vga_Init(void);
extern void vga_tty_end_screen(void);
extern void vga_tty_startup(int *, int *);
extern void vga_term_startup(int *, int *);
extern void vga_xputs(const char *, int, int);
extern void vga_xputc(char, int);
extern void vga_xputg(const glyph_info *, const glyph_info *);
@@ -288,6 +293,8 @@ extern void vesa_clear_screen(int);
extern void vesa_cl_end(int, int);
extern void vesa_cl_eos(int);
extern int vesa_detect(void);
extern void vesa_hide_cursor(void);
extern void vesa_show_cursor(void);
#ifdef SIMULATE_CURSOR
extern void vesa_DrawCursor(void);
#endif
@@ -302,7 +309,7 @@ extern void vesa_HideCursor(void);
#endif
extern void vesa_Init(void);
extern void vesa_tty_end_screen(void);
extern void vesa_tty_startup(int *, int *);
extern void vesa_term_startup(int *, int *);
extern void vesa_xputs(const char *, int, int);
extern void vesa_xputc(char, int);
extern void vesa_xputg(const glyph_info *, const glyph_info *);