From ee62f95569841f016025198dabf379eaa816c1dc Mon Sep 17 00:00:00 2001 From: Quentin Carbonneaux Date: Wed, 28 Feb 2018 15:05:41 -0500 Subject: fix long-standing UI bug This has been annoying me on and off for YEARS! (Literally.) In some (quite rare) settings, there was an annoying UI bug where it would look like some updates were not propagated to the UI when they had to. After spending a couple of days investigating this, it turns out that it is not a bug in the editor, but in xserver (maybe). Experiments and frustration revealed that the bug seems to be in some backing store-related logic. So, here, I remove our request to get a backing store. This backing store option was here to help performance, but X implementations really should be smart enough to use one even when clients don't ask for it. Even if X servers are dumb, removing the option should not cause a noticeable performance degradation. --- x11.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/x11.c b/x11.c index 4c5291d..39961ee 100644 --- a/x11.c +++ b/x11.c @@ -58,9 +58,8 @@ init() /* create the main window */ win = XCreateSimpleWindow(d, root, 0, 0, Width, Height, 0, 0, WhitePixel(d, screen)); - swa.backing_store = WhenMapped; swa.bit_gravity = NorthWestGravity; - XChangeWindowAttributes(d, win, CWBackingStore|CWBitGravity, &swa); + XChangeWindowAttributes(d, win, CWBitGravity, &swa); XStoreName(d, win, "ED"); XSelectInput(d, win, StructureNotifyMask|ButtonPressMask|ButtonReleaseMask|Button1MotionMask|KeyPressMask|ExposureMask|FocusChangeMask); -- cgit v1.2.3