li han
unread,Jun 17, 2024, 10:45:30 AMJun 17Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to fltk.general
Similar to this
```c++
Gdiplus::Graphics graphics(dcCompatible);
HRGN hgn1 = CreateRectRgn(m_rectTracker.m_rect.left,m_rectTracker.m_rect.top,
m_rectTracker.m_rect.right,m_rectTracker.m_rect.bottom);
Region region1(hgn1);
HRGN hgn2 = CreateRectRgn(rect.left,rect.top,
rect.right,rect.bottom);
Region region2(hgn2);
region2.Exclude(®ion1);
SolidBrush solidBrush(Color(100, 128, 128, 128));
graphics.FillRegion(&solidBrush,®ion2);
DeleteObject(hgn1);
DeleteObject(hgn2);
```