QGIS/python/gui/qgsnewvectorlayerdialog.sip
Matthias Kuhn bb79d13e82 Remove deprecated Qgis::WKBType and API cleanup (#3325)
* Remove deprecated Qgis::WKBType and API cleanup

Renames QgsWKBTypes to QgsWkbTypes

Replaces usage of the enums:

* Qgis::WKBType with QgsWkbTypes::Type
* Qgis::GeometryType with QgsWkbTypes::GeometryType

Their values should be forward compatible (a fact that was already
explited up to now by casting between the types)

Renames some SSLxxx to SslXxx and URIxxx to UriXxx

* Fix build warnings and simplify type handling

* Add a fixer to rewrite imports

* The forgotten rebase conflictThe forgotten rebase conflicts

* QgsDataSourcURI > QgsDataSourceUri

* QgsWKBTypes > QgsWkbTypes

* Qgis.WKBGeom > QgsWkbTypes.Geom

* Further python fixes

* Guess what... Qgis::wkbDimensions != QgsWkbTypes::wkbDimensions

* Fix tests

* Python 3 updates

* [travis] pull request caching cannot be disabled

so at least use it in r/w mode

* Fix python3 print in plugins
2016-08-04 09:10:08 +02:00

35 lines
1.3 KiB
Plaintext

class QgsNewVectorLayerDialog : QDialog
{
%TypeHeaderCode
#include <qgsnewvectorlayerdialog.h>
%End
public:
// run the dialog, create the layer.
// @return fileName on success, empty string use aborted, QString::null if creation failed
static QString runAndCreateLayer( QWidget* parent = 0, QString* enc = 0 );
QgsNewVectorLayerDialog( QWidget *parent /TransferThis/ = 0, const Qt::WindowFlags& fl = QgisGui::ModalDialogFlags );
~QgsNewVectorLayerDialog();
/** Returns the selected geometry type*/
QgsWkbTypes::Type selectedType() const;
/** Appends the chosen attribute names and types to at*/
void attributes( QList< QPair<QString, QString> >& at ) const;
/** Returns the file format for storage*/
QString selectedFileFormat() const;
/** Returns the file format for storage*/
QString selectedFileEncoding() const;
/** Returns the selected crs id*/
int selectedCrsId() const;
protected slots:
void on_mAddAttributeButton_clicked();
void on_mRemoveAttributeButton_clicked();
void on_mFileFormatComboBox_currentIndexChanged( int index );
void on_mTypeBox_currentIndexChanged( int index );
void on_buttonBox_helpRequested();
void nameChanged( const QString& );
void selectionChanged();
};