hi,
i'm also working now with ncurses, and i'm also a beginner. i tried to figure out your problem, and i've tested it with this little program. i hope this will solve your problem!
Code:
#include <ncurses.h>
int main() {
WINDOW* one, *two, *three;
initscr();
cbreak();
keypad(stdscr, TRUE);
start_color();
one = newwin(20, 20, 0, 0);
two = newwin(20, 20, 0, 0);
three = newwin(20, 20, 0, 0);
init_pair(2, COLOR_MAGENTA, COLOR_BLACK);
init_pair(3, COLOR_YELLOW, COLOR_BLACK);
init_pair(4, COLOR_CYAN, COLOR_BLACK);
wbkgdset(one, COLOR_PAIR(2));
wbkgdset(two, COLOR_PAIR(3));
wbkgdset(three, COLOR_PAIR(4));
box(three, 0, 0);
wrefresh(three);
sleep(1);
box(two, 0, 0);
wrefresh(two);
sleep(1);
box(one, 0, 0);
refresh();
wrefresh(one);
getch();
endwin();
return 0;
}