From 5f49f7a367e8438ba5bbfffab94ae585bd047226 Mon Sep 17 00:00:00 2001 From: "Colin J. Brigato" Date: Mon, 30 Sep 2024 18:15:59 +0200 Subject: [PATCH] precompute canvas at undo level to avoid blinking --- examples/paint/toolbar.go | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/paint/toolbar.go b/examples/paint/toolbar.go index f660d806..c92fda59 100644 --- a/examples/paint/toolbar.go +++ b/examples/paint/toolbar.go @@ -149,6 +149,7 @@ func ButtonColorMaker() *g.RowWidget { canvas, _ = NewCanvas(canvasDetectedHeight) canvas.UndoIndexes = uind canvas.DrawCommands = dc + canvas.Compute() } } imgui.SameLine()