demo: call boxdemo

pull/30/head
nick black 5 years ago committed by Nick Black
parent 48555507e6
commit ba08a6142e

@ -95,6 +95,9 @@ int main(int argc, char** argv){
goto err;
}
sleep(1);
if(box_demo(nc)){
goto err;
}
if(widecolor_demo(nc, ncp)){
goto err;
}

@ -10,6 +10,7 @@ extern "C" {
#define FADE_MILLISECONDS 500
int widecolor_demo(struct notcurses* nc, struct ncplane* n);
int box_demo(struct notcurses* nc);
#ifdef __cplusplus
}

@ -797,7 +797,6 @@ int ncplane_vline(ncplane* n, const cell* c, int len){
int ret, ypos, xpos;
ncplane_cursor_yx(n, &ypos, &xpos);
for(ret = 0 ; ret < len ; ++ret){
fprintf(stderr, "MOCNG: %d %d\n", ypos + ret, xpos);
if(ncplane_cursor_move_yx(n, ypos + ret, xpos)){
return -1;
}
@ -805,7 +804,6 @@ fprintf(stderr, "MOCNG: %d %d\n", ypos + ret, xpos);
break;
}
}
fprintf(stderr, "RETURN %d of %d\n", ret, len);
return ret;
}

@ -169,8 +169,8 @@ TEST_F(NcplaneTest, ConcentricBoxen) {
cell_load(n_, &ur, "");
cell_load(n_, &ll, "");
cell_load(n_, &lr, "");
cell_load(n_, &hl, "");
cell_load(n_, &vl, "");
cell_load(n_, &vl, "");
cell_load(n_, &hl, "");
EXPECT_EQ(0, ncplane_box(n_, &ul, &ur, &ll, &lr, &hl, &vl, y, x));
cell_release(n_, &vl);
cell_release(n_, &hl);

Loading…
Cancel
Save