Compare commits

...

2 Commits

@ -132,13 +132,13 @@ typedef enum {
((NCCHANNEL_INITIALIZER((fr), (fg), (fb)) << 32ull) + \
(NCCHANNEL_INITIALIZER((br), (bg), (bb))))
// These lowest-level functions manipulate a channel encodings directly. Users
// will typically manipulate ncplanes' and nccells' channels through their
// APIs, rather than calling these explicitly.
// These lowest-level functions directly manipulate a channel. Users will
// typically manipulate ncplanes' and nccells' channels through their APIs,
// rather than calling these explicitly.
// Extract the 2-bit alpha component from a 32-bit channel. It is not
// shifted down, and can be directly compared to NCALPHA_* values.
static inline unsigned
static inline uint32_t
ncchannel_alpha(uint32_t channel){
return channel & NC_BG_ALPHA_MASK;
}
@ -1197,9 +1197,8 @@ typedef enum {
NCTYPE_RELEASE,
} ncintype_e;
//Note: changing this also means adding kitty_cb_atxt functions in
//in.c otherwise extra codepoints won't be picked up.
// Note: changing this also means adding kitty_cb_atxt functions in
// in.c otherwise extra codepoints won't be picked up.
#define NCINPUT_MAX_EFF_TEXT_CODEPOINTS 4
// An input event. Cell coordinates are currently defined only for mouse

@ -987,7 +987,7 @@ build_sixel_band(qstate* qs, int bnum){
}
int cidx = find_color(qs, *rgb);
if(cidx < 0){
// FIXME free?
free(meta);
return -1;
}
int act;
@ -1012,6 +1012,7 @@ build_sixel_band(qstate* qs, int bnum){
}else{
b->vecs[c] = sixelband_extend(b->vecs[c], &meta[c], qs->lenx, x);
if(b->vecs[c] == NULL){
free(meta);
return -1;
}
meta[c].rle = 1;
@ -1024,6 +1025,7 @@ build_sixel_band(qstate* qs, int bnum){
if(meta[i].rle){ // color was wholly unused iff rle == 0 at end
b->vecs[i] = sixelband_extend(b->vecs[i], &meta[i], qs->lenx, x);
if(b->vecs[i] == NULL){
free(meta);
return -1;
}
}else{

Loading…
Cancel
Save