diff --git a/doc/window.txt b/doc/window.txt index 0bad7062c..45593eb88 100644 --- a/doc/window.txt +++ b/doc/window.txt @@ -649,14 +649,6 @@ can_suspend() -- Tell the core if the window system will allow the game to be suspended now. If unconditionally yes or no, use genl_can_suspend_yes() or genl_can_suspend_no(). -start_screen() -- Only used on Unix tty ports, but must be declared for - completeness. Sets up the tty to work in full-screen - graphics mode. Look at win/tty/termcap.c for an - example. If your window-port does not need this function - just declare an empty function. -end_screen() -- Only used on Unix tty ports, but must be declared for - completeness. The complement of start_screen(). - outrip(winid, int, time_t) -- The tombstone code. If you want the traditional code use genl_outrip for the value and check the #if in rip.c. diff --git a/include/winX.h b/include/winX.h index b43e442ac..3da329d7d 100644 --- a/include/winX.h +++ b/include/winX.h @@ -489,10 +489,6 @@ 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) */ -extern void X11_start_screen(void); -extern void X11_end_screen(void); - #ifdef GRAPHIC_TOMBSTONE extern void X11_outrip(winid, int, time_t); #else diff --git a/include/wincurs.h b/include/wincurs.h index 98ac5ae9e..4c5b7f19c 100644 --- a/include/wincurs.h +++ b/include/wincurs.h @@ -108,8 +108,6 @@ extern void curses_getlin(const char *question, char *input); extern int curses_get_ext_cmd(void); extern void curses_number_pad(int state); extern void curses_delay_output(void); -extern void curses_start_screen(void); -extern void curses_end_screen(void); extern void curses_outrip(winid wid, int how, time_t when); extern void genl_outrip(winid tmpwin, int how, time_t when); extern void curses_preference_update(const char *pref); diff --git a/include/winprocs.h b/include/winprocs.h index 8fc078e6c..5e0bc675f 100644 --- a/include/winprocs.h +++ b/include/winprocs.h @@ -80,10 +80,6 @@ struct window_procs { char *(*win_get_color_string)(void); #endif - /* other defs that really should go away (they're tty specific) */ - void (*win_start_screen)(void); - void (*win_end_screen)(void); - void (*win_outrip)(winid, int, time_t); void (*win_preference_update)(const char *); char *(*win_getmsghistory)(boolean); @@ -177,10 +173,6 @@ extern */ /* #define yn_function (*windowprocs.win_yn_function) */ -/* other defs that really should go away (they're tty specific) */ -#define start_screen (*windowprocs.win_start_screen) -#define end_screen (*windowprocs.win_end_screen) - #define outrip (*windowprocs.win_outrip) #define preference_update (*windowprocs.win_preference_update) #define getmsghistory (*windowprocs.win_getmsghistory) @@ -404,10 +396,6 @@ struct chain_procs { char *(*win_get_color_string)(CARGS); #endif - /* other defs that really should go away (they're tty specific) */ - void (*win_start_screen)(CARGS); - void (*win_end_screen)(CARGS); - void (*win_outrip)(CARGS, winid, int, time_t); void (*win_preference_update)(CARGS, const char *); char *(*win_getmsghistory)(CARGS, boolean); @@ -481,8 +469,6 @@ extern short safe_set_font_name(winid, char *); #endif extern char *safe_get_color_string(void); #endif -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); diff --git a/include/wintty.h b/include/wintty.h index 97d439a89..c98db6958 100644 --- a/include/wintty.h +++ b/include/wintty.h @@ -184,13 +184,16 @@ extern void term_end_attr(int attr); extern void term_end_color(void); extern void term_end_extracolor(void); extern void term_end_raw_bold(void); +extern void term_end_screen(void); extern void term_start_attr(int attr); extern void term_start_bgcolor(int color); extern void term_start_color(int color); extern void term_start_extracolor(uint32, uint16); extern void term_start_raw_bold(void); +extern void term_start_screen(void); extern void term_startup(int *, int *); extern void term_shutdown(void); + extern int xputc(int); extern void xputs(const char *); #if 0 @@ -287,10 +290,6 @@ extern void tty_status_init(void); extern void tty_status_update(int, genericptr_t, int, int, int, unsigned long *); -/* other defs that really should go away (they're tty specific) */ -extern void tty_start_screen(void); -extern void tty_end_screen(void); - extern void genl_outrip(winid, int, time_t); extern char *tty_getmsghistory(boolean); diff --git a/outdated/include/trampoli.h b/outdated/include/trampoli.h index 344dacc93..f45d3bb98 100644 --- a/outdated/include/trampoli.h +++ b/outdated/include/trampoli.h @@ -241,8 +241,8 @@ #define tty_nhbell() tty_nhbell_() #define tty_number_pad(x) tty_number_pad_(x) #define tty_delay_output() tty_delay_output_() -#define tty_start_screen() tty_start_screen_() -#define tty_end_screen() tty_end_screen_() +#define term_start_screen() term_start_screen_() +#define term_end_screen() term_end_screen_() /* ### topl.c ### */ #define tty_doprev_message() tty_doprev_message_() diff --git a/outdated/include/wingem.h b/outdated/include/wingem.h index 86b3f6ba3..c7a935ef2 100644 --- a/outdated/include/wingem.h +++ b/outdated/include/wingem.h @@ -101,10 +101,6 @@ 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) */ -extern void Gem_start_screen(void); -extern void Gem_end_screen(void); - extern void genl_outrip(winid, int, time_t); diff --git a/outdated/sys/mac/macwin.c b/outdated/sys/mac/macwin.c index 1da056a89..517b7f5a6 100644 --- a/outdated/sys/mac/macwin.c +++ b/outdated/sys/mac/macwin.c @@ -3275,9 +3275,6 @@ struct window_procs mac_procs = { tty_change_color, tty_change_background, set_tty_font_name, tty_get_color_string, #endif - /* other defs that really should go away (they're tty specific) */ - 0, // mac_start_screen, - 0, // mac_end_screen, genl_outrip, genl_preference_update, genl_can_suspend_no, }; diff --git a/outdated/sys/mac/mttymain.c b/outdated/sys/mac/mttymain.c index 1d1460df8..0020dccd1 100644 --- a/outdated/sys/mac/mttymain.c +++ b/outdated/sys/mac/mttymain.c @@ -581,13 +581,13 @@ tty_number_pad(int arg) } void -tty_start_screen(void) +term_start_screen(void) { iflags.cbreak = 1; } void -tty_end_screen(void) +term_end_screen(void) { } diff --git a/outdated/sys/msdos/SCHEMA35.MSC b/outdated/sys/msdos/SCHEMA35.MSC index 5d9392e69..400dc2f1a 100644 --- a/outdated/sys/msdos/SCHEMA35.MSC +++ b/outdated/sys/msdos/SCHEMA35.MSC @@ -254,10 +254,10 @@ functions:230 _thrwmu _tileview _timed_occupation _timer_is_local _timer_sanity_ functions:231 _topl_putsym _topologize _topten _topten_print _topten_print_bold _toss_up _toss_wsegs _touch_artifact functions:232 _touchfood _trap_detect _trickery _try_disarm _try_lift _trycall _tt_oname _tty_add_menu functions:233 _tty_askname _tty_clear_nhwindow _tty_cliparound -functions:234 _tty_display_file _tty_display_nhwindow _tty_doprev_message _tty_end_menu _tty_end_screen _tty_exit_nhwindows _tty_get_ext_cmd _tty_get_nh_event +functions:234 _tty_display_file _tty_display_nhwindow _tty_doprev_message _tty_end_menu _term_end_screen _tty_exit_nhwindows _tty_get_ext_cmd _tty_get_nh_event functions:235 _tty_getlin _tty_init_nhwindows _tty_mark_synch _tty_message_menu _tty_nh_poskey _tty_nhbell _tty_nhgetch _tty_number_pad functions:236 _tty_player_selection _tty_raw_print _tty_raw_print_bold _tty_resume_nhwindows _tty_select_menu -functions:237 _tty_start_menu _tty_start_screen _tty_startup _tty_suspend_nhwindows _tty_update_inventory _tty_yn_function +functions:237 _tty_start_menu _term_start_screen _tty_startup _tty_suspend_nhwindows _tty_update_inventory _tty_yn_function functions:238 _txt_backsp _txt_cl_end _txt_cl_eos _txt_clear_screen _txt_get_scr_size _txt_monoadapt_check functions:239 _txt_nhbell _txt_startup _u_entered_shop _u_gname _u_init functions:240 _u_left_shop _u_on_dnstairs _u_on_newpos _u_on_sstairs _u_on_upstairs _u_slip_free _u_slow_down _u_teleport_mon @@ -272,7 +272,7 @@ functions:248 _use_unicorn_horn _use_whip _use_whistle _useup _useupall _useupf functions:249 _uwepgone _vault_occupied _vault_tele _verbalize _vga_backsp _vga_cl_end _vga_cl_eos _vga_clear_screen functions:250 _vga_cliparound _vga_detect _vga_DisplayCell _vga_DisplayCell_O _vga_DrawCursor _vga_Finish _vga_FontPtrs _vga_get_scr_size functions:251 _vga_gotoloc _vga_HideCursor _vga_Init _vga_overview _vga_redrawmap _vga_refresh _vga_SetPalette _vga_SwitchMode -functions:252 _vga_traditional _vga_tty_end_screen _vga_tty_startup _vga_update_positionbar _vga_userpan _vga_WriteChar _vga_WriteStr _vga_xputc +functions:252 _vga_traditional _vga_term_end_screen _vga_term_startup _vga_update_positionbar _vga_userpan _vga_WriteChar _vga_WriteStr _vga_xputc functions:254 _vision_reset _dodiscovered _dodoor _dodown _dodrink _dodrop _doeat _doengrave functions:255 _wallification _wallify_map _wallify_vault _wantdoor _watch_on_duty _water_damage _water_friction functions:256 _water_prayer _weapon_dam_bonus _weapon_hit_bonus _weapon_type _wearing_armor _weffects _weight diff --git a/outdated/sys/msdos/schema3.MSC b/outdated/sys/msdos/schema3.MSC index ab9353f67..1e8670872 100644 --- a/outdated/sys/msdos/schema3.MSC +++ b/outdated/sys/msdos/schema3.MSC @@ -254,10 +254,10 @@ functions:230 _thrwmu _tileview _timed_occupation _timer_is_local _timer_sanity_ functions:231 _topl_putsym _topologize _topten _topten_print _topten_print_bold _toss_up _toss_wsegs _touch_artifact functions:232 _touchfood _trap_detect _trickery _try_disarm _try_lift _trycall _tt_oname _tty_add_menu functions:233 _tty_askname _tty_clear_nhwindow _tty_cliparound -functions:234 _tty_display_file _tty_display_nhwindow _tty_doprev_message _tty_end_menu _tty_end_screen _tty_exit_nhwindows _tty_get_ext_cmd _tty_get_nh_event +functions:234 _tty_display_file _tty_display_nhwindow _tty_doprev_message _tty_end_menu _term_end_screen _tty_exit_nhwindows _tty_get_ext_cmd _tty_get_nh_event functions:235 _tty_getlin _tty_init_nhwindows _tty_mark_synch _tty_message_menu _tty_nh_poskey _tty_nhbell _tty_nhgetch _tty_number_pad functions:236 _tty_player_selection _tty_raw_print _tty_raw_print_bold _tty_resume_nhwindows _tty_select_menu -functions:237 _tty_start_menu _tty_start_screen _tty_startup _tty_suspend_nhwindows _tty_update_inventory _tty_yn_function +functions:237 _tty_start_menu _term_start_screen _term_startup _tty_suspend_nhwindows _tty_update_inventory _tty_yn_function functions:238 _txt_backsp _txt_cl_end _txt_cl_eos _txt_clear_screen _txt_get_scr_size _txt_monoadapt_check functions:239 _txt_nhbell _txt_startup _u_entered_shop _u_gname _u_init functions:240 _u_left_shop _u_on_dnstairs _u_on_newpos _u_on_sstairs _u_on_upstairs _u_slip_free _u_slow_down _u_teleport_mon @@ -272,7 +272,7 @@ functions:248 _use_unicorn_horn _use_whip _use_whistle _useup _useupall _useupf functions:249 _uwepgone _vault_occupied _vault_tele _verbalize _vga_backsp _vga_cl_end _vga_cl_eos _vga_clear_screen functions:250 _vga_cliparound _vga_detect _vga_DisplayCell _vga_DisplayCell_O _vga_DrawCursor _vga_Finish _vga_FontPtrs _vga_get_scr_size functions:251 _vga_gotoloc _vga_HideCursor _vga_Init _vga_overview _vga_redrawmap _vga_refresh _vga_SetPalette _vga_SwitchMode -functions:252 _vga_traditional _vga_tty_end_screen _vga_tty_startup _vga_update_positionbar _vga_userpan _vga_WriteChar _vga_WriteStr _vga_xputc +functions:252 _vga_traditional _vga_term_end_screen _vga_term_startup _vga_update_positionbar _vga_userpan _vga_WriteChar _vga_WriteStr _vga_xputc functions:254 _vision_reset _dodiscovered _dodoor _dodown _dodrink _dodrop _doeat _doengrave functions:255 _wallification _wallify_map _wallify_vault _wantdoor _watch_on_duty _water_damage _water_friction functions:256 _water_prayer _weapon_dam_bonus _weapon_hit_bonus _weapon_type _wearing_armor _weffects _weight diff --git a/outdated/sys/wince/mswproc.c b/outdated/sys/wince/mswproc.c index e84dab8e1..8011991bc 100644 --- a/outdated/sys/wince/mswproc.c +++ b/outdated/sys/wince/mswproc.c @@ -71,8 +71,7 @@ struct window_procs mswin_procs = { #ifdef CHANGE_COLOR /* only a Mac option currently */ mswin, mswin_change_background, #endif - /* other defs that really should go away (they're tty specific) */ - mswin_start_screen, mswin_end_screen, mswin_outrip, + mswin_outrip, mswin_preference_update, genl_getmsghistory, genl_putmsghistory, genl_status_init, genl_status_finish, genl_status_enablefield, genl_status_update, @@ -1537,31 +1536,6 @@ mswin_get_color_string() return (""); } -/* -start_screen() -- Only used on Unix tty ports, but must be declared for - completeness. Sets up the tty to work in full-screen - graphics mode. Look at win/tty/termcap.c for an - example. If your window-port does not need this function - just declare an empty function. -*/ -void -mswin_start_screen() -{ - /* Do Nothing */ - logDebug("mswin_start_screen()\n"); -} - -/* -end_screen() -- Only used on Unix tty ports, but must be declared for - completeness. The complement of start_screen(). -*/ -void -mswin_end_screen() -{ - /* Do Nothing */ - logDebug("mswin_end_screen()\n"); -} - /* outrip(winid, int, when) -- The tombstone code. If you want the traditional code use diff --git a/outdated/sys/wince/winMS.h b/outdated/sys/wince/winMS.h index 3ee5622df..0ff0dd916 100644 --- a/outdated/sys/wince/winMS.h +++ b/outdated/sys/wince/winMS.h @@ -152,8 +152,6 @@ void mswin_number_pad(int state); void mswin_delay_output(void); void mswin_change_color(void); char *mswin_get_color_string(void); -void mswin_start_screen(void); -void mswin_end_screen(void); void mswin_outrip(winid wid, int how, time_t when); void mswin_preference_update(const char *pref); diff --git a/outdated/win/Qt3/qt3_win.cpp b/outdated/win/Qt3/qt3_win.cpp index 483761cfd..26e46c4bb 100644 --- a/outdated/win/Qt3/qt3_win.cpp +++ b/outdated/win/Qt3/qt3_win.cpp @@ -5152,16 +5152,6 @@ void NetHackQtBind::qt_delay_output() delay.wait(); } -void NetHackQtBind::qt_start_screen() -{ - // Ignore. -} - -void NetHackQtBind::qt_end_screen() -{ - // Ignore. -} - void NetHackQtBind::qt_outrip(winid wid, int how, time_t when) { NetHackQtWindow* window=id_to_window[wid]; @@ -5285,9 +5275,6 @@ struct window_procs Qt_procs = { donull, donull, #endif - /* other defs that really should go away (they're tty specific) */ - NetHackQtBind::qt_start_screen, - NetHackQtBind::qt_end_screen, #ifdef GRAPHIC_TOMBSTONE NetHackQtBind::qt_outrip, #else diff --git a/outdated/win/Qt3/qt3_win.h b/outdated/win/Qt3/qt3_win.h index 522f57d69..c5548e37c 100644 --- a/outdated/win/Qt3/qt3_win.h +++ b/outdated/win/Qt3/qt3_win.h @@ -877,8 +877,6 @@ class NetHackQtBind : NetHackQtBindBase static int qt_get_ext_cmd(); static void qt_number_pad(int); static void qt_delay_output(); - static void qt_start_screen(); - static void qt_end_screen(); static void qt_outrip(winid wid, int how, time_t when); static int qt_kbhit(); diff --git a/outdated/win/gem/wingem.c b/outdated/win/gem/wingem.c index df8d1d81c..15024f853 100644 --- a/outdated/win/gem/wingem.c +++ b/outdated/win/gem/wingem.c @@ -69,8 +69,7 @@ struct window_procs Gem_procs = { Gem_get_color_string, #endif - /* other defs that really should go away (they're tty specific) */ - Gem_start_screen, Gem_end_screen, Gem_outrip, Gem_preference_update, + Gem_outrip, Gem_preference_update, genl_getmsghistory, genl_putmsghistory genl_status_init, genl_status_finish, genl_status_enablefield, genl_status_update, @@ -523,16 +522,6 @@ Gem_resume_nhwindows() { } -void -Gem_end_screen() -{ -} - -void -Gem_start_screen() -{ -} - extern void mar_exit_nhwindows(void); extern boolean run_from_desktop; diff --git a/outdated/win/gnome/gnbind.c b/outdated/win/gnome/gnbind.c index 6fb043e21..a298af5a0 100644 --- a/outdated/win/gnome/gnbind.c +++ b/outdated/win/gnome/gnbind.c @@ -44,8 +44,7 @@ struct window_procs Gnome_procs = { #ifdef CHANGE_COLOR /* only a Mac option currently */ donull, donull, #endif - /* other defs that really should go away (they're tty specific) */ - gnome_start_screen, gnome_end_screen, gnome_outrip, + gnome_outrip, genl_preference_update, genl_getmsghistory, genl_putmsghistory, genl_status_init, genl_status_finish, genl_status_enablefield, genl_status_update, @@ -1132,29 +1131,6 @@ gnome_delay_output() } } -/* -start_screen() -- Only used on Unix tty ports, but must be declared for - completeness. Sets up the tty to work in full-screen - graphics mode. Look at win/tty/termcap.c for an - example. If your window-port does not need this function - just declare an empty function. -*/ -void -gnome_start_screen() -{ - /* Do Nothing */ -} - -/* -end_screen() -- Only used on Unix tty ports, but must be declared for - completeness. The complement of start_screen(). -*/ -void -gnome_end_screen() -{ - /* Do Nothing */ -} - /* outrip(winid, int, when) -- The tombstone code. If you want the traditional code use diff --git a/outdated/win/gnome/gnbind.h b/outdated/win/gnome/gnbind.h index b0f56e035..e39a56380 100644 --- a/outdated/win/gnome/gnbind.h +++ b/outdated/win/gnome/gnbind.h @@ -80,8 +80,6 @@ void gnome_getlin(const char *question, char *input); int gnome_get_ext_cmd(void); void gnome_number_pad(int state); void gnome_delay_output(void); -void gnome_start_screen(void); -void gnome_end_screen(void); void gnome_outrip(winid wid, int how, time_t when); void gnome_delete_nhwindow_by_reference(GtkWidget *menuWin); diff --git a/src/symbols.c b/src/symbols.c index d9de7b8db..ff352d214 100644 --- a/src/symbols.c +++ b/src/symbols.c @@ -11,12 +11,12 @@ staticfn struct _savedsym *savedsym_find(const char *, int); extern const uchar def_r_oc_syms[MAXOCLASSES]; /* drawing.c */ #if defined(TERMLIB) || defined(CURSES_GRAPHICS) -void (*decgraphics_mode_callback)(void) = 0; /* set in tty_start_screen() */ +void (*decgraphics_mode_callback)(void) = 0; /* set in term_start_screen() */ #endif /* TERMLIB || CURSES */ #ifdef PC9800 -void (*ibmgraphics_mode_callback)(void) = 0; /* set in tty_start_screen() */ -void (*ascgraphics_mode_callback)(void) = 0; /* set in tty_start_screen() */ +void (*ibmgraphics_mode_callback)(void) = 0; /* set in term_start_screen() */ +void (*ascgraphics_mode_callback)(void) = 0; /* set in term_start_screen() */ #endif #ifdef CURSES_GRAPHICS void (*cursesgraphics_mode_callback)(void) = 0; @@ -25,7 +25,7 @@ void (*cursesgraphics_mode_callback)(void) = 0; void (*ibmgraphics_mode_callback)(void) = 0; #endif #ifdef ENHANCED_SYMBOLS -void (*utf8graphics_mode_callback)(void) = 0; /* set in tty_start_screen and +void (*utf8graphics_mode_callback)(void) = 0; /* set in term_start_screen and * found in unixtty,windtty,&c */ #endif diff --git a/src/windows.c b/src/windows.c index d763f7eaf..a5924b2ae 100644 --- a/src/windows.c +++ b/src/windows.c @@ -598,8 +598,6 @@ static struct window_procs hup_procs = { #endif hup_get_color_string, #endif /* CHANGE_COLOR */ - hup_void_ndecl, /* start_screen */ - hup_void_ndecl, /* end_screen */ hup_outrip, genl_preference_update, genl_getmsghistory, genl_putmsghistory, hup_void_ndecl, /* status_init */ diff --git a/sys/msdos/pcvideo.h b/sys/msdos/pcvideo.h index 7aeb453d1..1d889a8b2 100644 --- a/sys/msdos/pcvideo.h +++ b/sys/msdos/pcvideo.h @@ -277,7 +277,7 @@ extern void vga_update_positionbar(char *); extern void vga_HideCursor(void); #endif extern void vga_Init(void); -extern void vga_tty_end_screen(void); +extern void vga_term_end_screen(void); extern void vga_term_startup(int *, int *); extern void vga_xputs(const char *, int, int); extern void vga_xputc(char, int); @@ -308,7 +308,7 @@ extern void vesa_update_positionbar(char *); extern void vesa_HideCursor(void); #endif extern void vesa_Init(void); -extern void vesa_tty_end_screen(void); +extern void vesa_term_end_screen(void); extern void vesa_term_startup(int *, int *); extern void vesa_xputs(const char *, int, int); extern void vesa_xputc(char, int); diff --git a/sys/msdos/video.c b/sys/msdos/video.c index a6b5bfe59..916a3518d 100644 --- a/sys/msdos/video.c +++ b/sys/msdos/video.c @@ -471,7 +471,7 @@ tty_delay_output(void) } void -tty_end_screen(void) +term_end_screen(void) { if (!iflags.grmode) { txt_clear_screen(); @@ -480,11 +480,11 @@ tty_end_screen(void) #endif #ifdef SCREEN_VGA } else if (iflags.usevga) { - vga_tty_end_screen(); + vga_term_end_screen(); #endif #ifdef SCREEN_VESA } else if (iflags.usevesa) { - vesa_tty_end_screen(); + vesa_term_end_screen(); #endif } } @@ -546,7 +546,7 @@ term_startup(int *wid, int *hgt) } void -tty_start_screen(void) +term_start_screen(void) { #ifdef PC9800 fputs("\033[>1h", stdout); diff --git a/sys/msdos/vidvesa.c b/sys/msdos/vidvesa.c index 4cc594bcf..8a3423bc0 100644 --- a/sys/msdos/vidvesa.c +++ b/sys/msdos/vidvesa.c @@ -596,7 +596,7 @@ vesa_cl_eos(int cy) } void -vesa_tty_end_screen(void) +vesa_term_end_screen(void) { vesa_clear_screen(BACKGROUND_VESA_COLOR); vesa_SwitchMode(MODETEXT); diff --git a/sys/msdos/vidvga.c b/sys/msdos/vidvga.c index 02b9f444f..140b816a5 100644 --- a/sys/msdos/vidvga.c +++ b/sys/msdos/vidvga.c @@ -290,7 +290,7 @@ void vga_cl_eos(int cy) } void -vga_tty_end_screen(void) +vga_term_end_screen(void) { vga_clear_screen(BACKGROUND_VGA_COLOR); vga_SwitchMode(MODETEXT); diff --git a/sys/share/pctty.c b/sys/share/pctty.c index 6b718d66a..fee616980 100644 --- a/sys/share/pctty.c +++ b/sys/share/pctty.c @@ -38,7 +38,7 @@ settty(const char *s) #if defined(MSDOS) && defined(NO_TERMS) gr_finish(); #endif - end_screen(); + term_end_screen(); if (s) raw_print(s); #if !defined(TOS) @@ -50,7 +50,7 @@ settty(const char *s) void setftty(void) { - start_screen(); + term_start_screen(); } #if defined(TIMED_DELAY) && defined(_MSC_VER) @@ -77,7 +77,7 @@ VA_DECL(const char *, s) VA_INIT(s, const char *); /* error() may get called before tty is initialized */ if (iflags.window_inited) - end_screen(); + term_end_screen(); putchar('\n'); Vprintf(s, VA_ARGS); putchar('\n'); diff --git a/sys/share/unixtty.c b/sys/share/unixtty.c index 44fbadc6a..c5f849e5c 100644 --- a/sys/share/unixtty.c +++ b/sys/share/unixtty.c @@ -11,6 +11,7 @@ #define NEED_VARARGS #include "hack.h" +#include "wintty.h" /* * The distinctions here are not BSD - rest but rather USG - rest, as @@ -229,7 +230,10 @@ gettty(void) void settty(const char *s) { - end_screen(); +#ifdef TTY_GRAPHICS + if (WINDOWPORT(tty)) + term_end_screen(); +#endif if (s) raw_print(s); if (STTY(&inittyb) < 0 || STTY2(&inittyb2) < 0) @@ -306,7 +310,11 @@ setftty(void) if (change) setctty(); - start_screen(); + +#ifdef TTY_GRAPHICS + if (WINDOWPORT(tty)) + term_start_screen(); +#endif } void intron(void) /* enable kbd interrupts if enabled when game started */ @@ -480,7 +488,7 @@ RESTORE_WARNING_FORMAT_NONLITERAL #ifdef ENHANCED_SYMBOLS /* - * set in tty_start_screen() and allows + * set in term_start_screen() and allows * OS-specific changes that may be * required for support of utf8. */ diff --git a/sys/vms/vmstty.c b/sys/vms/vmstty.c index 9bd26a9a5..b6dd2013e 100644 --- a/sys/vms/vmstty.c +++ b/sys/vms/vmstty.c @@ -513,7 +513,7 @@ setftty(void) sg.sm.tt2_char = tt2_char_active; setctty(); - start_screen(); + term_start_screen(); settty_needed = TRUE; } @@ -601,7 +601,7 @@ getwindowsz(void) #ifdef ENHANCED_SYMBOLS /* - * set in tty_start_screen() and allows + * set in term_start_screen() and allows * OS-specific changes that may be * required for support of utf8. * Currently a placeholder for VMS. diff --git a/sys/windows/consoletty.c b/sys/windows/consoletty.c index c89e2c8ed..b7fb0cf50 100644 --- a/sys/windows/consoletty.c +++ b/sys/windows/consoletty.c @@ -1052,7 +1052,7 @@ void settty(const char *s) { cmov(ttyDisplay->curx, ttyDisplay->cury); - end_screen(); + term_end_screen(); if (s) raw_print(s); restore_original_console_font(); @@ -1075,7 +1075,7 @@ settty(const char *s) void setftty(void) { - start_screen(); + term_start_screen(); } void @@ -1113,7 +1113,7 @@ graph_off(void) #endif void -tty_end_screen(void) +term_end_screen(void) { term_clear_screen(); really_move_cursor(); @@ -1123,7 +1123,7 @@ tty_end_screen(void) } void -tty_start_screen(void) +term_start_screen(void) { if (iflags.num_pad) tty_number_pad(1); /* make keypad send digits */ diff --git a/sys/windows/windsys.c b/sys/windows/windsys.c index 05b073a45..24dd6ed60 100644 --- a/sys/windows/windsys.c +++ b/sys/windows/windsys.c @@ -231,8 +231,10 @@ VA_DECL(const char *, s) VA_START(s); VA_INIT(s, const char *); /* error() may get called before tty is initialized */ +#ifdef TTY_GRAPHICS if (iflags.window_inited) - end_screen(); + term_end_screen(); +#endif if (WINDOWPORT(tty)) { buf[0] = '\n'; (void) vsnprintf(&buf[1], sizeof buf - (1 + sizeof "\n"), s, VA_ARGS); diff --git a/win/Qt/qt_bind.cpp b/win/Qt/qt_bind.cpp index e6546447c..91dcf65fc 100644 --- a/win/Qt/qt_bind.cpp +++ b/win/Qt/qt_bind.cpp @@ -966,16 +966,6 @@ NetHackQtBind::qt_get_color_string(void) #endif -void NetHackQtBind::qt_start_screen() -{ - // Ignore. -} - -void NetHackQtBind::qt_end_screen() -{ - // Ignore. -} - void NetHackQtBind::qt_outrip(winid wid, int how, time_t when) { NetHackQtWindow* window=id_to_window[(int)wid]; @@ -1232,8 +1222,6 @@ struct window_procs Qt_procs = { nethack_qt_::NetHackQtBind::qt_get_color_string, #endif /* other defs that really should go away (they're tty specific) */ - nethack_qt_::NetHackQtBind::qt_start_screen, - nethack_qt_::NetHackQtBind::qt_end_screen, #ifdef GRAPHIC_TOMBSTONE nethack_qt_::NetHackQtBind::qt_outrip, #else diff --git a/win/Qt/qt_bind.h b/win/Qt/qt_bind.h index 6535e637b..d0c71759c 100644 --- a/win/Qt/qt_bind.h +++ b/win/Qt/qt_bind.h @@ -85,8 +85,6 @@ public: static int qt_get_ext_cmd(); static void qt_number_pad(int); static void qt_delay_output(); - static void qt_start_screen(); - static void qt_end_screen(); static void qt_preference_update(const char *optname); static char *qt_getmsghistory(boolean init); diff --git a/win/X11/winX.c b/win/X11/winX.c index f808541d5..d9a7cacf4 100644 --- a/win/X11/winX.c +++ b/win/X11/winX.c @@ -146,8 +146,6 @@ struct window_procs X11_procs = { #ifdef CHANGE_COLOR /* only a Mac option currently */ donull, donull, #endif - /* other defs that really should go away (they're tty specific) */ - X11_start_screen, X11_end_screen, #ifdef GRAPHIC_TOMBSTONE X11_outrip, #else @@ -1396,20 +1394,6 @@ X11_number_pad(int state) /* called from options.c */ return; } -/* called from setftty() in unixtty.c */ -void -X11_start_screen(void) -{ - return; -} - -/* called from settty() in unixtty.c */ -void -X11_end_screen(void) -{ - return; -} - #ifdef GRAPHIC_TOMBSTONE void X11_outrip(winid window, int how, time_t when) diff --git a/win/chain/wc_chainin.c b/win/chain/wc_chainin.c index 6573fe826..ab63cf3c7 100644 --- a/win/chain/wc_chainin.c +++ b/win/chain/wc_chainin.c @@ -59,9 +59,6 @@ short chainin_set_font_name(winid, char *); char *chainin_get_color_string(void); #endif - /* other defs that really should go away (they're tty specific) */ -void chainin_start_screen(void); -void chainin_end_screen(void); void chainin_outrip(winid, int, time_t); void chainin_preference_update(const char *); char *chainin_getmsghistory(boolean); @@ -489,19 +486,6 @@ trace_get_color_string(void) #endif -/* other defs that really should go away (they're tty specific) */ -void -chainin_start_screen(void) -{ - (*cibase->nprocs->win_start_screen)(cibase->ndata); -} - -void -chainin_end_screen(void) -{ - (*cibase->nprocs->win_end_screen)(cibase->ndata); -} - void chainin_outrip( winid tmpwin, @@ -629,8 +613,6 @@ struct window_procs chainin_procs = { chainin_get_color_string, #endif - chainin_start_screen, chainin_end_screen, - chainin_outrip, chainin_preference_update, chainin_getmsghistory, chainin_putmsghistory, chainin_status_init, chainin_status_finish, chainin_status_enablefield, diff --git a/win/chain/wc_chainout.c b/win/chain/wc_chainout.c index a0198173c..72459b883 100644 --- a/win/chain/wc_chainout.c +++ b/win/chain/wc_chainout.c @@ -59,9 +59,6 @@ short chainout_set_font_name(void *,winid, char *); char *chainout_get_color_string(void *); #endif - /* other defs that really should go away (they're tty specific) */ -void chainout_start_screen(void *); -void chainout_end_screen(void *); void chainout_outrip(void *,winid, int, time_t); void chainout_preference_update(void *,const char *); char *chainout_getmsghistory(void *,boolean); @@ -582,23 +579,6 @@ trace_get_color_string(void *vp) #endif -/* other defs that really should go away (they're tty specific) */ -void -chainout_start_screen(void *vp) -{ - struct chainout_data *tdp = vp; - - (*tdp->nprocs->win_start_screen)(); -} - -void -chainout_end_screen(void *vp) -{ - struct chainout_data *tdp = vp; - - (*tdp->nprocs->win_end_screen)(); -} - void chainout_outrip( void *vp, @@ -755,8 +735,6 @@ struct chain_procs chainout_procs = { chainout_get_color_string, #endif - chainout_start_screen, chainout_end_screen, - chainout_outrip, chainout_preference_update, chainout_getmsghistory, chainout_putmsghistory, chainout_status_init, chainout_status_finish, chainout_status_enablefield, diff --git a/win/chain/wc_trace.c b/win/chain/wc_trace.c index 2048a05c4..7287e82a4 100644 --- a/win/chain/wc_trace.c +++ b/win/chain/wc_trace.c @@ -91,9 +91,6 @@ short trace_set_font_name(void *,winid, char *); char *trace_get_color_string(void *); #endif - /* other defs that really should go away (they're tty specific) */ -void trace_start_screen(void *); -void trace_end_screen(void *); void trace_outrip(void *,winid, int, time_t); void trace_preference_update(void *,const char *); char *trace_getmsghistory(void *,boolean); @@ -1011,31 +1008,6 @@ trace_get_color_string(void *vp) #endif -/* other defs that really should go away (they're tty specific) */ -void -trace_start_screen(void *vp) -{ - struct trace_data *tdp = vp; - - fprintf(wc_tracelogf, "%sstart_screen()\n", INDENT); - - PRE; - (*tdp->nprocs->win_start_screen)(tdp->ndata); - POST; -} - -void -trace_end_screen(void *vp) -{ - struct trace_data *tdp = vp; - - fprintf(wc_tracelogf, "%send_screen()\n", INDENT); - - PRE; - (*tdp->nprocs->win_end_screen)(tdp->ndata); - POST; -} - void trace_outrip( void *vp, @@ -1245,8 +1217,6 @@ struct chain_procs trace_procs = { trace_get_color_string, #endif - trace_start_screen, trace_end_screen, - trace_outrip, trace_preference_update, trace_getmsghistory, trace_putmsghistory, trace_status_init, trace_status_finish, trace_status_enablefield, diff --git a/win/curses/cursmain.c b/win/curses/cursmain.c index 5dee9900b..89491434e 100644 --- a/win/curses/cursmain.c +++ b/win/curses/cursmain.c @@ -126,8 +126,6 @@ struct window_procs curses_procs = { #endif curses_get_color_string, #endif - curses_start_screen, - curses_end_screen, genl_outrip, curses_preference_update, curses_getmsghistory, @@ -1207,27 +1205,6 @@ curses_delay_output(void) #endif } -/* -start_screen() -- Only used on Unix tty ports, but must be declared for - completeness. Sets up the tty to work in full-screen - graphics mode. Look at win/tty/termcap.c for an - example. If your window-port does not need this function - just declare an empty function. -*/ -void -curses_start_screen(void) -{ -} - -/* -end_screen() -- Only used on Unix tty ports, but must be declared for - completeness. The complement of start_screen(). -*/ -void -curses_end_screen(void) -{ -} - /* outrip(winid, int) -- The tombstone code. We use genl_outrip() from rip.c diff --git a/win/share/safeproc.c b/win/share/safeproc.c index efcb76097..19e9aa9b6 100644 --- a/win/share/safeproc.c +++ b/win/share/safeproc.c @@ -123,7 +123,7 @@ struct window_procs safe_procs = { #endif safe_get_color_string, #endif - safe_start_screen, safe_end_screen, safe_outrip, + safe_outrip, safe_preference_update, safe_getmsghistory, safe_putmsghistory, safe_status_init, @@ -440,18 +440,6 @@ safe_delay_output(void) return; } -void -safe_start_screen(void) -{ - return; -} - -void -safe_end_screen(void) -{ - return; -} - void safe_outrip(winid tmpwin UNUSED, int how UNUSED, time_t when UNUSED) { diff --git a/win/shim/winshim.c b/win/shim/winshim.c index dbc3ef5d7..ed09d0b27 100644 --- a/win/shim/winshim.c +++ b/win/shim/winshim.c @@ -159,8 +159,6 @@ DECLCB(short, set_shim_font_name,(winid window_type, char *font_name),"2is", A2P DECLCB(char *,shim_get_color_string,(void),"sv") /* other defs that really should go away (they're tty specific) */ -VDECLCB(shim_start_screen, (void), "v") -VDECLCB(shim_end_screen, (void), "v") VDECLCB(shim_preference_update, (const char *pref), "vp", P2V pref) DECLCB(char *,shim_getmsghistory, (boolean init), "sb", A2P init) VDECLCB(shim_putmsghistory, (const char *msg, boolean restoring_msghist), "vsb", P2V msg, A2P restoring_msghist) @@ -247,8 +245,7 @@ struct window_procs shim_procs = { shim_get_color_string, #endif - /* other defs that really should go away (they're tty specific) */ - shim_start_screen, shim_end_screen, genl_outrip, + genl_outrip, shim_preference_update, shim_getmsghistory, shim_putmsghistory, shim_status_init, diff --git a/win/tty/termcap.c b/win/tty/termcap.c index 66ed2b6a2..3af6333f9 100644 --- a/win/tty/termcap.c +++ b/win/tty/termcap.c @@ -505,7 +505,7 @@ tty_ascgraphics_hilite_fixup(void) #endif /* PC9800 */ void -tty_start_screen(void) +term_start_screen(void) { xputs(TI); xputs(VS); @@ -537,7 +537,7 @@ tty_start_screen(void) } void -tty_end_screen(void) +term_end_screen(void) { term_clear_screen(); xputs(VE); diff --git a/win/tty/wintty.c b/win/tty/wintty.c index ea9006af7..288653e5c 100644 --- a/win/tty/wintty.c +++ b/win/tty/wintty.c @@ -148,8 +148,7 @@ struct window_procs tty_procs = { tty_get_color_string, #endif - /* other defs that really should go away (they're tty specific) */ - tty_start_screen, tty_end_screen, genl_outrip, + genl_outrip, tty_preference_update, tty_getmsghistory, tty_putmsghistory, tty_status_init, @@ -530,7 +529,7 @@ tty_init_nhwindows(int *argcp UNUSED, char **argv UNUSED) /* to port dependant tty setup */ term_startup(&wid, &hgt); - setftty(); /* calls start_screen */ + setftty(); /* calls term_start_screen */ term_curs_set(0); /* set up tty descriptor */ @@ -793,7 +792,7 @@ void tty_resume_nhwindows(void) { gettty(); - setftty(); /* calls start_screen */ + setftty(); /* calls term_start_screen */ term_curs_set(0); docrt(); } diff --git a/win/win32/mswproc.c b/win/win32/mswproc.c index 1103233c2..8f5c4cc45 100644 --- a/win/win32/mswproc.c +++ b/win/win32/mswproc.c @@ -119,8 +119,7 @@ struct window_procs mswin_procs = { #ifdef CHANGE_COLOR /* only a Mac option currently */ mswin_change_color, mswin_get_color_string, #endif - /* other defs that really should go away (they're tty specific) */ - mswin_start_screen, mswin_end_screen, mswin_outrip, + mswin_outrip, mswin_preference_update, mswin_getmsghistory, mswin_putmsghistory, mswin_status_init, mswin_status_finish, mswin_status_enablefield, mswin_status_update, @@ -1924,31 +1923,6 @@ mswin_get_color_string(void) return (char *) ""; } -/* -start_screen() -- Only used on Unix tty ports, but must be declared for - completeness. Sets up the tty to work in full-screen - graphics mode. Look at win/tty/termcap.c for an - example. If your window-port does not need this function - just declare an empty function. -*/ -void -mswin_start_screen(void) -{ - /* Do Nothing */ - logDebug("mswin_start_screen()\n"); -} - -/* -end_screen() -- Only used on Unix tty ports, but must be declared for - completeness. The complement of start_screen(). -*/ -void -mswin_end_screen(void) -{ - /* Do Nothing */ - logDebug("mswin_end_screen()\n"); -} - /* outrip(winid, int, when) -- The tombstone code. If you want the traditional code use diff --git a/win/win32/winMS.h b/win/win32/winMS.h index 682fbc3ee..1de3db042 100644 --- a/win/win32/winMS.h +++ b/win/win32/winMS.h @@ -188,8 +188,6 @@ void mswin_number_pad(int state); void mswin_delay_output(void); void mswin_change_color(int color, long rgb, int reverse); char *mswin_get_color_string(void); -void mswin_start_screen(void); -void mswin_end_screen(void); void mswin_outrip(winid wid, int how, time_t when); void mswin_preference_update(const char *pref); char *mswin_getmsghistory(boolean init);