QRegion
QRegion is a class in the Qt framework that represents a geometric region used for clipping, hit testing, and region operations. A QRegion can describe a single rectangle or a complex area composed of multiple rectangles. It can be constructed from a QRect, from a QBitmap, or by combining other regions. Internally it stores the region as a set of rectangles, but it can also utilize the operating system's native region representation to speed up operations on the target platform.
The class supports boolean operations such as union, intersection, subtraction, and symmetric difference with other regions.
In practice, QRegion is widely used for clipping in painting code. A region can be supplied to
QRegion relies on native platform representations where available to improve performance, and remains a core part