Skip to content

Commit b8f8349

Browse files
author
alexbruy
committedApr 5, 2011
synchronize eVis with latest changes in delimited text provider (fix #3701)
git-svn-id: http://svn.osgeo.org/qgis/trunk@15676 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 45d5d87 commit b8f8349

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed
 

‎src/plugins/evis/databaseconnection/evisdatabaseconnectiongui.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
#include <QtXml/QDomDocument>
4040
#include <QtXml/QDomElement>
4141
#include <QtXml/QDomNode>
42+
#include <QUrl>
4243

4344
/**
4445
* Constructor
@@ -108,12 +109,12 @@ void eVisDatabaseConnectionGui::drawNewVectorLayer( QString layerName, QString x
108109
//fileName is only available if the file is open
109110
//the last file in the list is always the newest
110111
mTempOutputFileList->last( )->open( );
111-
QString uri = QString( "%1?delimiter=%2&xField=%3&yField=%4" )
112-
.arg( mTempOutputFileList->last( )->fileName( ) )
113-
.arg( "\t" )
114-
.arg( xCoordinate )
115-
.arg( yCoordinate );
116-
emit drawVectorLayer( uri, layerName, "delimitedtext" );
112+
QUrl url = QUrl::fromLocalFile( mTempOutputFileList->last()->fileName() );
113+
url.addQueryItem( "delimiter", "\t" );
114+
url.addQueryItem( "delimiterType", "regexp" );
115+
url.addQueryItem( "xField", xCoordinate );
116+
url.addQueryItem( "yField", yCoordinate );
117+
emit drawVectorLayer( QString::fromAscii( url.toEncoded() ), layerName, "delimitedtext" );
117118
mTempOutputFileList->last( )->close( );
118119
}
119120
}

0 commit comments

Comments
 (0)
Please sign in to comment.