I upgraded from Ubuntu 22.04 to Ubuntu 24.04 (it was clean install on new SSD drive). I'm using JWM window manager. When I run any app made in lazarus (including lazarus itself) there is weird flickering of the window. Sometimes the app doesn't start until I alt+tab twice. I thought it was disto's lazarus issue so I uninstalled it and installed Lazarus 3.8 (rev Unknown) FPC 3.2.2 x86_64-linux-gtk2 from sourceforge. The issue ramains, I tried older JWM (from 22.04 where it worked) but that didn't help. I tried openbox wm it's doing it there as well. I tried few other WM and in some it is worse, for example in miwm the window just slowly flows up in a flickering manner. It's relatively ok for empty window but as I add components (main menu, memo alClient) it gets progressively worse. If I change window left/top/width/height in FormCreate the flickering is worse, sometimes it never stops (until double Alt+Tab). The lazarus itself is doing it too. I tried sleep(100) and application.processMessages in random places but it didn't help.
This is what it looks like in JWM:
https://www.youtube.com/watch?v=qo7U9hzwyeoThis is what it looks like in MIWM:
https://www.youtube.com/watch?v=gBWfno9rE9MIt seems like some kind of discrepancy between WM's desired window size and Lazarus desired window size and they fighting each other.