RFR: 8273355: Lanai: Flickering on tooltip appearance IntelliJ IDEA 2021.2.1

Alexey Ushakov avu at openjdk.java.net
Fri Sep 10 18:54:47 UTC 2021


On Thu, 9 Sep 2021 05:35:01 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:

> There is no caching in the LWWindowPeer.setOpaque() it just do not call the updateOpaque() if the opaque property did not change.

Yes, I meant just that - cached state.

> I think that the root cause is in the performance, because the first thing we draw is the surface data which is initialized/filled by the background color. Probably in OGL it works fine because we draw mostly immediately, and in case of metal we are waiting for DisplayLink callback?

Yes, to blit the content we just start DisplayLink. So, definitely there is some lag between window appearance and the drawing of the layer.  

> What you are want to do is to call the `CWrapper.NSWindow.setBackgroundColor` from the LWWindowPeer.setBackground().

Yes, it was the purpose of use setOpaque() method. But, more verbose way with a separate method (setBackground) is better. I've prepared a new version with such a change.

-------------

PR: https://git.openjdk.java.net/jdk/pull/5373



More information about the client-libs-dev mailing list