ExportMap/Sources/MoonExp.py
@@ -144,8 +144,8 @@ size = map.sizeWithUnits() print('size: ' + str(size.width()) + " * " + str(size.height()) + " mm") if size.width() > 280 or size.height() > 174: map.attemptResize(QgsLayoutSize(280, 174, QgsUnitTypes.LayoutMillimeters)) if size.width() > 233 or size.height() > 174: map.attemptResize(QgsLayoutSize(233, 174, QgsUnitTypes.LayoutMillimeters)) print('size: ' + str(map.sizeWithUnits().width()) + " * " + str(map.sizeWithUnits().height()) + " mm") # 设置图层