QgsRectangle rect(0, 0, 10, 10);
QgsRectangle rect(0, 0, 10, 10); double xMin = rect.xMinimum(); double yMin = rect.yMinimum(); double xMax = rect.xMaximum(); double yMax = rect.yMaximum();
QgsRectangle rect(0, 0, 10, 10); rect.expand(5);This code creates a QgsRectangle object and then expands it by 5 units in each direction. Overall, the QgsRectangle class in C++ is a useful class for representing 2D rectangles and is used extensively in the QGIS library.