~eliasnaur/gio-patches

app/internal/window: specify None as the X11 window background v1 PROPOSED

Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~eliasnaur/gio-patches/patches/8993/mbox | git am -3
Learn more about email & git

[PATCH] app/internal/window: specify None as the X11 window background Export this patch

Avoids flickering on my Fedora 31 Gnome setup.

Signed-off-by: Elias Naur <mail@eliasnaur.com>
---
 app/internal/window/os_x11.go | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/app/internal/window/os_x11.go b/app/internal/window/os_x11.go
index d8d6ceb..1e37229 100644
--- a/app/internal/window/os_x11.go
+++ b/app/internal/window/os_x11.go
@@ -530,10 +530,11 @@ func newX11Window(gioWin Callbacks, opts *Options) error {
 		xic C.XIC
 	)
 	swa.event_mask = C.ExposureMask | C.PointerMotionMask | C.KeyPressMask
+	swa.background_pixmap = C.None
 	win := C.XCreateWindow(dpy, root,
 		0, 0, C.uint(cfg.Px(opts.Width)), C.uint(cfg.Px(opts.Height)), 0,
 		C.CopyFromParent, C.InputOutput,
-		nil, C.CWEventMask|C.CWBackPixel,
+		nil, C.CWEventMask|C.CWBackPixmap,
 		&swa)
 	C.gio_x11_init_ime(dpy, win, &xim, &xic)
 	C.XSelectInput(dpy, win, 0|
-- 
2.23.0
View this thread in the archives