Page MenuHome

Fix T92371: Move AZONE_REGION When Overlapped
ClosedPublic

Authored by Harley Acheson (harley) on Oct 21 2021, 7:13 PM.

Details

Summary

Overlapped regions have transparent backgrounds, so when placing
AZONE_REGION we need to move them in to the content edge.


This patch just moves AZONE_REGION in a bit when the region is overlapped (user has enabled USER_REGION_OVERLAP so the region is draw with a transparent background) so that the hit area for dragging matches the visible edge of content.

The amount moved in is an arbitrary amount (0.4f * U.widget_unit) but does seem to work quite well:

If we need to change these in a more granular fashion we could differ by region->regiontype, but this seems good enough in my testing.

Diff Detail

Repository
rB Blender

Event Timeline

Harley Acheson (harley) requested review of this revision.Oct 21 2021, 7:13 PM
Harley Acheson (harley) created this revision.
Hans Goudey (HooglyBoogly) added inline comments.
source/blender/editors/screen/area.c
976

const

Also, the comment could note that 0.4 is an arbitrary number that happens to line up with numbers elsewhere.

This revision is now accepted and ready to land.Oct 21 2021, 7:23 PM