drop tinfo argument from pixel_init()

pull/2206/head
nick black 3 years ago committed by nick black
parent 556039eb73
commit 6985d9a715

@ -1042,16 +1042,14 @@ int sixel_draw(const tinfo* ti, const ncpile* p, sprixel* s, fbuf* f,
return s->glyph.used;
}
int sixel_init(const tinfo* ti, int fd){
(void)ti;
int sixel_init(int fd){
// \e[?8452: DECSDM private "sixel scrolling" mode keeps the sixel from
// scrolling, but puts it at the current cursor location (as opposed to
// the upper left corner of the screen).
return tty_emit("\e[?80;8452h", fd);
}
int sixel_init_inverted(const tinfo* ti, int fd){
(void)ti;
int sixel_init_inverted(int fd){
// except MLterm (and a few others, possibly including the physical VT340),
// which inverts the usual sense of DECSDM.
return tty_emit("\e[?80l\e[?8452h", fd);

@ -220,7 +220,7 @@ int sprite_init(const tinfo* t, int fd){
if(t->pixel_init == NULL){
return 0;
}
return t->pixel_init(t, fd);
return t->pixel_init(fd);
}
uint8_t* sprixel_auxiliary_vector(const sprixel* s){

@ -183,8 +183,8 @@ int kitty_scrub(const struct ncpile* p, sprixel* s);
int fbcon_scrub(const struct ncpile* p, sprixel* s);
int kitty_remove(int id, fbuf* f);
int kitty_clear_all(fbuf* f);
int sixel_init(const tinfo* t, int fd);
int sixel_init_inverted(const tinfo* t, int fd);
int sixel_init(int fd);
int sixel_init_inverted(int fd);
int kitty_shutdown(fbuf* f);
int sixel_shutdown(fbuf* f);
uint8_t* sixel_trans_auxvec(const struct tinfo* ti);

@ -127,7 +127,7 @@ typedef struct tinfo {
// it leaves the sprixel in INVALIDATED so that it's drawn in phase 2.
void (*pixel_refresh)(const struct ncpile* p, struct sprixel* s);
int (*pixel_remove)(int id, fbuf* f); // kitty only, issue actual delete command
int (*pixel_init)(const struct tinfo*, int fd); // called when support is detected
int (*pixel_init)(int fd); // called when support is detected
int (*pixel_draw)(const struct tinfo*, const struct ncpile* p,
struct sprixel* s, fbuf* f, int y, int x);
int (*pixel_draw_late)(const struct tinfo*, struct sprixel* s, int yoff, int xoff);

Loading…
Cancel
Save