Skip to content

Commit a2df00c

Browse files
committed
testcurs : clarified some messages, added a test of PDC_set_title()
1 parent a3762aa commit a2df00c

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

demos/testcurs.c

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,9 @@ int main(int argc, char *argv[])
219219

220220
if (initTest(&win, argc, argv))
221221
return 1;
222-
222+
#ifdef __PDCURSESMOD__
223+
PDC_set_title( "testcurs -- PDCurses* demo/test program");
224+
#endif
223225
for( i = 1; i < argc; i++)
224226
if( argv[i][0] == '-')
225227
switch( argv[i][1])
@@ -1654,16 +1656,16 @@ static void show_color_cube( int tmarg)
16541656

16551657
mvaddstr(tmarg + 2, lmarg, "6x6x6 Color Cube (16-231):");
16561658

1657-
mvaddstr(tmarg + 4, lmarg, "Blk Red");
1658-
mvaddstr(tmarg + 11, lmarg, "Blue Mgta");
1659+
mvaddstr(tmarg + 4, lmarg, "Black Red");
1660+
mvaddstr(tmarg + 11, lmarg, "Blue Magenta");
16591661
if( COLS >= 77)
16601662
{
1661-
mvaddstr(tmarg + 4, lmarg + 65, "Grn Yel");
1663+
mvaddstr(tmarg + 4, lmarg + 65, "Green Yellow");
16621664
mvaddstr(tmarg + 11, lmarg + 65, "Cyan White");
16631665
}
16641666
else
16651667
{
1666-
mvaddstr(tmarg + 11, COLS - 12, "Grn Yel");
1668+
mvaddstr(tmarg + 11, COLS - 12, "Green Yellow");
16671669
mvaddstr(tmarg + 18, COLS - 12, "Cyan White");
16681670
}
16691671

@@ -1818,7 +1820,7 @@ void gradient(int tmarg)
18181820

18191821
attrset(A_NORMAL);
18201822
if( cnum >= COLORS || pnum >= COLOR_PAIRS)
1821-
mvaddstr(tmarg + 18, 3, "RAN OUT OF COLORS");
1823+
mvprintw(tmarg + 18, 3, "RAN OUT OF COLORS at %d colors", (int)cnum);
18221824
mvaddstr(tmarg + 19, 3, "Press any key to continue");
18231825
curTest();
18241826
}

0 commit comments

Comments
 (0)