X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Ftest_inwstr.c;h=81ebda776a3820f295355b496df9dfce215eda4e;hp=fe2b645c958119a835d52d45d5afd5e75dbc911c;hb=3e91848cbe3dad23fdb60962fa9b678592591c34;hpb=772f879d17117c5b766022f28099e341ebea825b diff --git a/test/test_inwstr.c b/test/test_inwstr.c index fe2b645c..81ebda77 100644 --- a/test/test_inwstr.c +++ b/test/test_inwstr.c @@ -1,5 +1,6 @@ /**************************************************************************** - * Copyright (c) 2007 Free Software Foundation, Inc. * + * Copyright 2020 Thomas E. Dickey * + * Copyright 2007-2010,2017 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -26,7 +27,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: test_inwstr.c,v 1.3 2007/07/21 22:47:42 tom Exp $ + * $Id: test_inwstr.c,v 1.6 2020/02/02 23:34:34 tom Exp $ * * Author: Thomas E Dickey * @@ -58,7 +59,7 @@ Quit(int ch) static void show_1st(WINDOW *win, int line, wchar_t *buffer) { - mvwaddwstr(win, line, 5, buffer); + (void) mvwaddwstr(win, line, 5, buffer); } static void @@ -70,7 +71,7 @@ showmore(WINDOW *win, int line, wchar_t *buffer) } static int -test_inchs(int level, char **argv, WINDOW *chrwin, WINDOW *strwin) +recursive_test(int level, char **argv, WINDOW *chrwin, WINDOW *strwin) { WINDOW *txtbox = 0; WINDOW *txtwin = 0; @@ -151,7 +152,7 @@ test_inchs(int level, char **argv, WINDOW *chrwin, WINDOW *strwin) beep(); break; case 'w': - test_inchs(level + 1, argv, chrwin, strwin); + recursive_test(level + 1, argv, chrwin, strwin); if (txtbox != 0) { touchwin(txtbox); wnoutrefresh(txtbox); @@ -175,7 +176,7 @@ test_inchs(int level, char **argv, WINDOW *chrwin, WINDOW *strwin) break; } - mvwprintw(chrwin, 0, 0, "line:"); + MvWPrintw(chrwin, 0, 0, "line:"); wclrtoeol(chrwin); if (txtwin != stdscr) { @@ -199,7 +200,7 @@ test_inchs(int level, char **argv, WINDOW *chrwin, WINDOW *strwin) } wnoutrefresh(chrwin); - mvwprintw(strwin, 0, 0, "%4d:", limit); + MvWPrintw(strwin, 0, 0, "%4d:", limit); wclrtobot(strwin); if (txtwin != stdscr) { @@ -254,7 +255,7 @@ main(int argc, char *argv[]) chrwin = derwin(chrbox, 2, COLS - 2, 1, 1); strwin = derwin(chrbox, 2, COLS - 2, 3, 1); - test_inchs(1, argv, chrwin, strwin); + recursive_test(1, argv, chrwin, strwin); endwin(); ExitProgram(EXIT_SUCCESS);