diff --git a/doc/man/man1/notcurses-demo.1 b/doc/man/man1/notcurses-demo.1 index c68096212..802454073 100644 --- a/doc/man/man1/notcurses-demo.1 +++ b/doc/man/man1/notcurses-demo.1 @@ -20,7 +20,7 @@ on your terminal after the program exits. Print a usage message, and exit with success. .TP .IR demospec -Select which demos to run, and what order to run them in. The default is "isumbgwvpo". See below for a list of demos. +Select which demos to run, and what order to run them in. The default is "imbgsuwvpo". See below for a list of demos. .SH DESCRIPTION .B notcurses-demo contains a set of text-based demonstrations of capabilities from the notcurses library. The demonstrations include: diff --git a/src/demo/demo.c b/src/demo/demo.c index 80808ef2f..207401054 100644 --- a/src/demo/demo.c +++ b/src/demo/demo.c @@ -9,6 +9,8 @@ #include #include "demo.h" +static const char DEFAULT_DEMO[] = "imbgsuwvpo"; + int timespec_subtract(struct timespec *result, const struct timespec *time0, struct timespec *time1){ if(time0->tv_nsec < time1->tv_nsec){ @@ -324,7 +326,7 @@ int main(int argc, char** argv){ if(argv[optind] != NULL){ usage(*argv, EXIT_FAILURE); } - demos = "isumbgwvpo"; + demos = DEFAULT_DEMO; } if((nc = notcurses_init(&nopts)) == NULL){ return EXIT_FAILURE; diff --git a/src/demo/unicodeblocks.c b/src/demo/unicodeblocks.c index b0a94bd19..5cb38edd0 100644 --- a/src/demo/unicodeblocks.c +++ b/src/demo/unicodeblocks.c @@ -172,6 +172,7 @@ int unicodeblocks_demo(struct notcurses* nc){ cell_release(n, &c); } ncplane_set_fg_rgb(n, 0x40, 0xc0, 0x40); + ncplane_set_bg_rgb(n, 0, 0, 0); if(ncplane_cursor_move_yx(n, 6 + BLOCKSIZE / CHUNKSIZE, 0)){ return -1; } diff --git a/src/demo/widecolor.c b/src/demo/widecolor.c index c5a30ac11..aacc72d4a 100644 --- a/src/demo/widecolor.c +++ b/src/demo/widecolor.c @@ -578,6 +578,7 @@ int widecolor_demo(struct notcurses* nc){ struct ncplane* n = notcurses_stdplane(nc); size_t i; const size_t screens = sizeof(steps) / sizeof(*steps); + ncplane_erase(n); for(i = 0 ; i < screens ; ++i){ ncspecial_key special; cell c; @@ -587,7 +588,6 @@ int widecolor_demo(struct notcurses* nc){ const int rollover = 256 / ((step & 0xff) | ((step & 0xff00) >> 8u) | ((step & 0xff0000) >> 16u)); int rollcount = 0; // number of times we've added this step - //ncplane_erase(n); int dimy, dimx; notcurses_resize(nc, &dimy, &dimx); cell_init(&c);