Snap Area handles flicker on initial render on Ventura when there are a large number of them (~53)

Describe the bug
I use a huge number of snap areas on a Dell U4919DW double-wide monitor (about 53 of them :slight_smile: , created by a custom script). When I start to drag a window I get a bunch of flickering (of the snap handles) which can last 3-5 seconds. While that repeated rendering is happening the system is otherwise unresponsive. My gut tells me that all the handles are being rendered over and over again, perhaps 53 times (once for each handle).

This issue showed up when I updated to Ventura about a month ago, and has been present in all BTT updates from then to now.

For the most part it "calms down" after the first time it happens and I won't see the flickering behavior again as long as I continue to work in the same Desktop Space. If I switch Spaces (not always, but sometimes) then the flicker happens again the first time I move a window in the new Space.

Note: Because I used a custom script to generate the snap areas it seems possible that there is something unique or weird about their data. I have attached an export of my BTT configuration just in case that's useful.

Affected input device (e.g. MacBook Trackpad, Magic Mouse/Trackpad, Touch Bar, etc.):
Mouse drag of windows

Screenshots
This is a rendering of my snap areas (from my snap area creation tool)

This is a screenshot of the actual snap areas:

Device information:

  • Type of Mac: MacBook Pro 16" 2019
  • macOS version: Ventura (13.2.1)
  • BetterTouchTool version: 4.070 (2285)

Additional information (e.g. StackTraces, related issues, screenshots, workarounds, etc.):
btt_export_EPM_2023-04-09.bttpreset (195.6 KB)

Any comment on this one? I don't know if it seems like a low priority because perhaps it only becomes significant when someone has a lot of snap areas, and perhaps I am unique in having so many, but for me this is a thorn in my side that pokes me ~50 time a day. :slight_smile:

I have this same problem but with a much lower number of custom touch points. It causes lag on my system any time I try to move or re-size the window. I wouldn't call this low priority because it's caused me to start looking for an alternate solution for window snapping. This issue has continued across multiple versions of MacOS and extends to both BetterTouchTool and BetterSnapTool.

Is this option checked for you?

If so BTT keeps all the snap areas cached, in that case there shouldn't be any lag - however with the original request I'm not sure. I'll need to do a bit more testing with such an amount of areas :slight_smile:

//edit: I have now tested with > 30 areas on one ultra wide screen, but there is absolutely no lag or flickering. So I don't think it's the amount of areas that causes this. (However I'm on a M1 Max machine)

I have an U4919DW, I'll test your preset with it soon.

Is this option checked for you?

That option is checked (and I didn't touch it today, so it must have been checked before I started seeing this issue).

I have an U4919DW, I'll test your preset with it soon.

Wow, that is a super helpful coincidence! Hopefully you are able to reproduce it on that. As I said, it comes and goes so some times I see it on every drag and some times (like this morning) it takes me a while to reproduce and I have to keep switching spaces and dragging things before I see it start. I haven't been able to determine a minimum sequence of behaviors to reproduce.

I'm on a M1 Max machine

I'm on an Intel machine but I also have an M2 Air so I'll try hooking up to this display just to see if I can reproduce on that machine as well.

Thanks for looking into this! I love BTT and I LOVE snap areas :slight_smile: