pull/2122/head
nick black 3 years ago
commit 8b1521abb9

@ -1597,6 +1597,8 @@ int ncinputlayer_init(tinfo* tcache, FILE* infp, queried_terminals_e* detected,
nilayer->user_wants_data = false;
nilayer->inner_wants_data = false;
pthread_cond_init(&nilayer->creport_cond, NULL);
// widnows terminal doesn't seem to reply to any queries =/
#ifndef __MINGW64__
int csifd = nilayer->ttyfd >= 0 ? nilayer->ttyfd : nilayer->infd;
if(isatty(csifd)){
query_state inits = {
@ -1635,6 +1637,7 @@ int ncinputlayer_init(tinfo* tcache, FILE* infp, queried_terminals_e* detected,
*kittygraphs = true;
}
}
#endif
return 0;
}

@ -279,6 +279,13 @@ int update_term_dimensions(int* rows, int* cols, tinfo* tcache, int margin_b){
tcache->pixel_draw = NULL; // disable support
}
}
#else
if(rows){
*rows = tcache->default_rows;
}
if(cols){
*cols = tcache->default_cols;
}
#endif
if(tcache->sixel_maxy_pristine){
int sixelrows = *rows - 1;
@ -1154,7 +1161,7 @@ notcurses* notcurses_core_init(const notcurses_options* opts, FILE* outfp){
}
ret->stdplane = NULL;
if((ret->stdplane = create_initial_ncplane(ret, dimy, dimx)) == NULL){
logerror("Couldn't create the initial plane (bad margins?)\n");
logpanic("Couldn't create the initial plane (bad margins?)\n");
goto err;
}
reset_term_attributes(&ret->tcache, &ret->rstate.f);

Loading…
Cancel
Save