Real-image posters: a new size is a new image id, never a changed placement

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-21 00:29:16 +02:00
co-authored by Claude Sonnet 5.5
parent 2ba47cb4ee
commit cf07aaf8fb
5 changed files with 82 additions and 112 deletions
+3 -3
View File
@@ -193,8 +193,8 @@ func New(cfg *config.Config) *App {
}
// noteWindow notices when the terminal's size or cell size changed. The
// placements of real-image posters are then made again: the picture would
// otherwise rely on the terminal rescaling an existing placement correctly.
// real-image posters are then uploaded and placed again from scratch instead of
// relying on the terminal to rescale what is there.
func (a *App) noteWindow(s tcell.Screen) {
w, h := s.Size()
win := [3]int{w, h, int(a.cellAspect * 1000)}
@@ -204,7 +204,7 @@ func (a *App) noteWindow(s tcell.Screen) {
first := a.lastWindow == [3]int{}
a.lastWindow = win
if !first && a.gfx != nil {
a.gfx.invalidate()
a.gfx.deleteAll()
}
}