Skip to content
Permalink
Browse files

Merge branch 'master' of https://github.com/QGIS/qgis

  • Loading branch information
tomkralidis committed Mar 19, 2015
2 parents e57136c + f17755c commit 9ce3b3c4cdd8da34b6e03b905988eaf0f244ee00
@@ -7,7 +7,7 @@ class QgsDataItemProviderRegistry
public:
//! Returns the instance pointer, creating the object on the first call
static QgsDataItemProviderRegistry * instance();

~QgsDataItemProviderRegistry();

//! Get list of available providers
@@ -341,7 +341,7 @@ class QgsGeometry

/** Returns a simplified version of this geometry using a specified tolerance value */
QgsGeometry* simplify( double tolerance ) /Factory/;

/**Smooths a geometry by rounding off corners using the Chaikin algorithm. This operation
* roughly doubles the number of vertices in a geometry.
* @param iterations number of smoothing iterations to run. More iterations results
@@ -506,7 +506,7 @@ class QgsGeometry
* @note added in QGIS 2.9
*/
static bool compare( const QgsPolygon& p1, const QgsPolygon& p2, double epsilon = 4 * DBL_EPSILON );

/** Compares two multipolygons for equality within a specified tolerance.
* @param p1 first multipolygon
* @param p2 second multipolygon
@@ -21,7 +21,7 @@ class QgsMapLayerComboBox : QComboBox

//! currently used filter on list layers
QgsMapLayerProxyModel::Filters filters() const;

//! except a list of layers not to be listed
void setExceptedLayerList( QList<QgsMapLayer*> layerList );

@@ -42,7 +42,7 @@ class QgsMapLayerProxyModel : QSortFilterProxyModel
*/
QgsMapLayerProxyModel* setFilters( Filters filters );
const Filters& filters() const;

//! offer the possibility to except some layers to be listed
void setExceptedLayerList( QList<QgsMapLayer*> exceptList );
QList<QgsMapLayer*> exceptedLayerList();
@@ -56,7 +56,7 @@ def defineCharacteristics(self):

def processAlgorithm(self, progress):
fieldName = str(self.getParameterValue(self.FIELD_NAME))

arguments = []
if len(fieldName) > 0:
arguments.append('-tileindex')
@@ -38,7 +38,7 @@ QgsMapLayerProxyModel *QgsMapLayerProxyModel::setFilters( Filters filters )
return this;
}

void QgsMapLayerProxyModel::setExceptedLayerList(QList<QgsMapLayer*> exceptList)
void QgsMapLayerProxyModel::setExceptedLayerList( QList<QgsMapLayer*> exceptList )
{
mExceptList = exceptList;
invalidateFilter();
@@ -32,7 +32,7 @@ QgsScaleWidget::QgsScaleWidget( QWidget *parent )
layout->addWidget( mScaleComboBox );

mCurrentScaleButton = new QToolButton( this );
mCurrentScaleButton->setToolTip( tr("Set to current canvas scale") );
mCurrentScaleButton->setToolTip( tr( "Set to current canvas scale" ) );
mCurrentScaleButton->setIcon( QgsApplication::getThemeIcon( "/mActionMapIdentification.svg" ) );
layout->addWidget( mCurrentScaleButton );
mCurrentScaleButton->hide();
@@ -322,7 +322,7 @@ bool QgsPostgresFeatureIterator::declareCursor( const QString& whereClause )
if ( mSource->mForce2d )
{
geom = QString( "%1(%2)" )
// Force_2D before 2.0
// Force_2D before 2.0
.arg( mConn->majorVersion() < 2 ? "force_2d"
// ST_Force2D since 2.1.0
: mConn->majorVersion() > 2 || mConn->minorVersion() > 0 ? "st_force2d"
@@ -1417,11 +1417,11 @@ int QgsWMSServer::getFeatureInfo( QDomDocument& result, QString version )
}
else
{
infoPoint = new QgsPoint();
if( !infoPointToMapCoordinates( i, j, infoPoint, mMapRenderer ) )
{
return 5;
}
infoPoint = new QgsPoint();
if ( !infoPointToMapCoordinates( i, j, infoPoint, mMapRenderer ) )
{
return 5;
}
}

//get the layer registered in QgsMapLayerRegistry and apply possible filters
@@ -1552,9 +1552,9 @@ int QgsWMSServer::getFeatureInfo( QDomDocument& result, QString version )
QgsRasterLayer* rasterLayer = dynamic_cast<QgsRasterLayer*>( currentLayer );
if ( rasterLayer )
{
if( !infoPoint )
if ( !infoPoint )
{
continue;
continue;
}
QgsPoint layerInfoPoint = mMapRenderer->mapToLayerCoordinates( currentLayer, *infoPoint );
if ( featureInfoFromRasterLayer( rasterLayer, &layerInfoPoint, result, layerElement, version, infoFormat ) != 0 )
@@ -101,12 +101,12 @@ void TestQgsMapRotation::initTestCase()
mapLayers << mLinesLayer;

// Register all layers with the registry
QgsMapLayerRegistry::instance()->addMapLayers(mapLayers);
QgsMapLayerRegistry::instance()->addMapLayers( mapLayers );

// This is needed to correctly set rotation center,
// the actual size doesn't matter as QgsRenderChecker will
// re-set it to the size of the expected image
mMapSettings.setOutputSize( QSize(256,256) );
mMapSettings.setOutputSize( QSize( 256, 256 ) );

mReport += "<h1>Map Rotation Tests</h1>\n";
}
@@ -150,7 +150,7 @@ void TestQgsMapRotation::pointsLayer()
bool success = false;
mPointsLayer->loadNamedStyle( qml, success );
QVERIFY( success );
mMapSettings.setExtent( QgsRectangle(-105.5,37,-97.5,45) );
mMapSettings.setExtent( QgsRectangle( -105.5, 37, -97.5, 45 ) );
mMapSettings.setRotation( -60 );
QVERIFY( render( "svgpoints-60" ) );

@@ -159,7 +159,7 @@ void TestQgsMapRotation::pointsLayer()
success = false;
mPointsLayer->loadNamedStyle( qml, success );
QVERIFY( success );
mMapSettings.setExtent( QgsRectangle(-116,33,-107,42) );
mMapSettings.setExtent( QgsRectangle( -116, 33, -107, 42 ) );
mMapSettings.setRotation( 90 );
QVERIFY( render( "svgpoints-datadefined+90" ) );

@@ -170,7 +170,7 @@ void TestQgsMapRotation::pointsLayer()
success = false;
mPointsLayer->loadNamedStyle( qml, success );
QVERIFY( success );
mMapSettings.setExtent( QgsRectangle(-116,33,-107,42) );
mMapSettings.setExtent( QgsRectangle( -116, 33, -107, 42 ) );
mMapSettings.setRotation( 90 );
QVERIFY( render( "simplepoints-datadefined+90" ) );

@@ -179,7 +179,7 @@ void TestQgsMapRotation::pointsLayer()
success = false;
mPointsLayer->loadNamedStyle( qml, success );
QVERIFY( success );
mMapSettings.setExtent( QgsRectangle(-108,26,-100,34) );
mMapSettings.setExtent( QgsRectangle( -108, 26, -100, 34 ) );
mMapSettings.setRotation( 30 );
QVERIFY( render( "simplepoints+30" ) );

@@ -207,7 +207,7 @@ bool TestQgsMapRotation::render( QString theTestType )
{
mReport += "<h2>" + theTestType + "</h2>\n";
QgsRenderChecker checker;
checker.setControlPathPrefix("maprotation");
checker.setControlPathPrefix( "maprotation" );
checker.setControlName( "expected_" + theTestType );
checker.setMapSettings( mMapSettings );
bool result = checker.runTest( theTestType );

0 comments on commit 9ce3b3c

Please sign in to comment.
You can’t perform that action at this time.