Class: QgsNewMemoryLayerDialog¶
Class Hierarchy¶
Base classes¶
Methods
Returns the selected CRS for the new layer. |
|
Returns attributes for the new layer. |
|
Returns the layer name |
|
Returns the selected geometry type |
|
Sets the crs value for the new layer in the dialog. |
Static Methods
Runs the dialog and creates a new memory layer |
- class qgis.gui.QgsNewMemoryLayerDialog(parent: QWidget | None = None, fl: Qt.WindowFlags | Qt.WindowType = QgsGuiUtils.ModalDialogFlags)[source]¶
Bases:
QDialog
- crs(self) QgsCoordinateReferenceSystem [source]¶
Returns the selected CRS for the new layer.
See also
- Return type:
- fields(self) QgsFields [source]¶
Returns attributes for the new layer.
Added in version 3.14.
- Return type:
- static runAndCreateLayer(parent: QWidget | None = None, defaultCrs: QgsCoordinateReferenceSystem = QgsCoordinateReferenceSystem()) QgsVectorLayer | None [source]¶
Runs the dialog and creates a new memory layer
- Parameters:
parent (Optional[QWidget] = None) – parent widget
defaultCrs (
QgsCoordinateReferenceSystem
= QgsCoordinateReferenceSystem()) – default layer CRS to show in dialog
- Return type:
Optional[QgsVectorLayer]
- Returns:
new memory layer
- selectedType(self) Qgis.WkbType [source]¶
Returns the selected geometry type
- Return type:
- setCrs(self, crs: QgsCoordinateReferenceSystem)[source]¶
Sets the
crs
value for the new layer in the dialog.See also
- Parameters: