STATE_SIXEL_SUCCESS: reset inits->numeric #1810

pull/1825/head
nick black 3 years ago
parent 0b84b4235d
commit 2bc945e52a
No known key found for this signature in database
GPG Key ID: 5F43400C21CBFACC

@ -1092,6 +1092,7 @@ pump_control_read(query_state* inits, unsigned char c){
break;
case STATE_SIXEL_SUCCESS:
if(c == ';'){
inits->numeric = 0;
inits->state = STATE_SIXEL_WIDTH;
}else{
// FIXME error?

@ -260,7 +260,6 @@ int update_term_dimensions(int fd, int* rows, int* cols, tinfo* tcache,
}
}
if(tcache->sixel_maxy_pristine){
tcache->sixel_maxy = tcache->sixel_maxy_pristine;
int sixelrows = *rows - 1;
// if the bottom margin is at least one row, we can draw into the last
// row of our visible area. we must leave the true bottom row alone.
@ -268,6 +267,9 @@ int update_term_dimensions(int fd, int* rows, int* cols, tinfo* tcache,
++sixelrows;
}
tcache->sixel_maxy = sixelrows * tcache->cellpixy;
if(tcache->sixel_maxy > tcache->sixel_maxy_pristine){
tcache->sixel_maxy = tcache->sixel_maxy_pristine;
}
}
return 0;
}

Loading…
Cancel
Save