kupiqu / SierraBreezeEnhanced

Originally a fork of BreezeEnhanced to make it (arguably) more minimalistic and informative
GNU General Public License v3.0
214 stars 33 forks source link

Add toggle to enable Corner clicking #138

Open Rudraksh88 opened 1 month ago

Rudraksh88 commented 1 month ago

This was removed in some release because it was considered a bug. But in fact, it's the default behavior in >95% of the cases. The default Breeze theme has it, BreezeEnhanced has it, browsers (chrome, brave, firefox) have it. And countless more examples. It's a general UX thing that allows you to just click without precisely clicking on the button.

Here's what it is. The window is maximized. The buttons should be clickable even from the edges and corners. Screenshot_20240822_0443311

Can we have a toggle to add it back? I tried adding in some hacky fixes but it resulted in artifacts sometimes. Maybe the changes were made too deep. But nonetheless, it should be a simple fix.

kupiqu commented 4 weeks ago

I don't follow. I tried Breeze and it works as SBE. Perhaps I didn't understand what you mean.

Rudraksh88 commented 4 weeks ago

What I meant was that in Breeze and BreezeEnhanced, when maximized, you can still trigger a click when clicking on the top edge, right edge, or corners. In SBE, we need to click on the exact button (not in the space between the window border and the button) to register a click. In the screenshot above, I'm hovering the cursor at the top edge just above the KeepAbove button, and it is clickable even though the mouse is not inside the exact bounds of the button.

I think it's better to enable this via a toggle. It's essentially button padding, but I guess currently it uses margins instead of padding. Let me know if you have some time to work on this or tell me if this is even possible with the current implementation. I know it's in the updateButtonsGeometry function and it seems like it's using margins everywhere. I tried updating it, but the buttons were getting cut off during hovering, which resulted in visual artifacts. Maybe you can just tell me about the exact place to make the changes, and I will create a PR.