From f7c619457bd0189fb703f4f06dd064f0b58a5b8e Mon Sep 17 00:00:00 2001 From: Mortdecai Date: Tue, 7 Apr 2026 22:29:20 -0400 Subject: [PATCH] fix(composite): don't draw partially off-screen images (prevents sticky images on scroll) --- app/compositeview.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/compositeview.go b/app/compositeview.go index e3940e5..a8f7c03 100644 --- a/app/compositeview.go +++ b/app/compositeview.go @@ -273,11 +273,11 @@ func (cc *compositeContent) drawImage(ctx *ui.Context, idx, row, width, height i graphic.Resize(width, height) } - startRow := row - if startRow < 0 { - startRow = 0 + // Only draw when fully on-screen — partial placement causes sticky images + if row < 0 || row+height > ctx.Height() { + return } - win := ctx.Window().New(0, startRow, width, height) + win := ctx.Window().New(0, row, width, height) graphic.Draw(win) }