diff options
-rw-r--r-- | src/local/term.nim | 4 | ||||
-rw-r--r-- | todo | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/local/term.nim b/src/local/term.nim index 3b2b8050..f2faaa13 100644 --- a/src/local/term.nim +++ b/src/local/term.nim @@ -65,6 +65,7 @@ type disph: int damaged: bool marked*: bool + dead: bool kittyId: int bmp: Bitmap # 0 if kitty @@ -645,7 +646,7 @@ proc outputGrid*(term: Terminal) = func findImage(term: Terminal; pid, imageId: int; bmp: Bitmap; rx, ry, erry, offx, dispw: int): CanvasImage = for it in term.canvasImages: - if it.pid == pid and it.imageId == imageId and + if not it.dead and it.pid == pid and it.imageId == imageId and it.bmp.width == bmp.width and it.bmp.height == bmp.height and it.rx == rx and it.ry == ry and (term.imageMode != imSixel or it.erry == erry and it.dispw == dispw and @@ -709,6 +710,7 @@ proc loadImage*(term: Terminal; bmp: Bitmap; data: Blob; pid, imageId, term.clearImage(image, maxh) if not term.positionImage(image, x, y, maxw, maxh): # no longer on screen + image.dead = true return nil elif term.imageMode == imSixel: # check if any line of our image is damaged diff --git a/todo b/todo index 49fae2e3..538b58de 100644 --- a/todo +++ b/todo @@ -71,8 +71,8 @@ layout engine: - iframe - writing-mode, grid, ruby, ... (i.e. cool new stuff) images: -- more efficient sixel display (store encoded images) -- proper sixel color register allocation, dithering +- sixel dithering +- z order, proper image blending - incremental decoding, interlaced images, animation man: - add a DOM -> man page converter so that we do not depend on pandoc |