Skip to content

Commit dc25d45

Browse files
author
jef
committed
automatic indentation update (r14435-r15226)
git-svn-id: http://svn.osgeo.org/qgis/trunk@15227 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 4dc202e commit dc25d45

25 files changed

+150
-150
lines changed

src/app/composer/qgscomposer.cpp

+9-9
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ QgsComposer::QgsComposer( QgisApp *qgis, const QString& title ): QMainWindow(),
8080

8181
QSettings settings;
8282
int size = settings.value( "/IconSize", 24 ).toInt();
83-
setIconSize(QSize(size,size));
83+
setIconSize( QSize( size, size ) );
8484

8585
QToolButton* orderingToolButton = new QToolButton( this );
8686
orderingToolButton->setPopupMode( QToolButton::InstantPopup );
@@ -302,15 +302,15 @@ void QgsComposer::setupTheme()
302302

303303
void QgsComposer::setIconSizes( int size )
304304
{
305-
//Set the icon size of for all the toolbars created in the future.
306-
setIconSize(QSize(size,size));
305+
//Set the icon size of for all the toolbars created in the future.
306+
setIconSize( QSize( size, size ) );
307307

308-
//Change all current icon sizes.
309-
QList<QToolBar *> toolbars = findChildren<QToolBar *>();
310-
foreach(QToolBar * toolbar, toolbars)
311-
{
312-
toolbar->setIconSize(QSize(size,size));
313-
}
308+
//Change all current icon sizes.
309+
QList<QToolBar *> toolbars = findChildren<QToolBar *>();
310+
foreach( QToolBar * toolbar, toolbars )
311+
{
312+
toolbar->setIconSize( QSize( size, size ) );
313+
}
314314
}
315315

316316
void QgsComposer::connectSlots()

src/app/composer/qgscomposerlegendlayersdialog.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ QgsComposerLegendLayersDialog::QgsComposerLegendLayersDialog( QList<QgsMapLayer*
2121
setupUi( this );
2222

2323
QList<QgsMapLayer*>::iterator layerIt = layers.begin();
24-
for (; layerIt != layers.end(); ++layerIt )
24+
for ( ; layerIt != layers.end(); ++layerIt )
2525
{
2626
QListWidgetItem* item = new QListWidgetItem(( *layerIt )->name(), listMapLayers );
2727
mItemLayerMap.insert( item, *layerIt );
28-
}
28+
}
2929
}
3030

3131
QgsComposerLegendLayersDialog::QgsComposerLegendLayersDialog(): QDialog( 0 )

src/app/gps/qgsgpsmarker.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525

2626
QgsGpsMarker::QgsGpsMarker( QgsMapCanvas* mapCanvas )
27-
: QgsMapCanvasItem( mapCanvas )
27+
: QgsMapCanvasItem( mapCanvas )
2828
{
2929
mSize = 16;
3030
mWgs84CRS.createFromEpsg( 4326 );
@@ -38,14 +38,14 @@ void QgsGpsMarker::setSize( int theSize )
3838
void QgsGpsMarker::setCenter( const QgsPoint& point )
3939
{
4040
//transform to map crs
41-
if( mMapCanvas && mMapCanvas->mapRenderer() )
41+
if ( mMapCanvas && mMapCanvas->mapRenderer() )
4242
{
4343
QgsCoordinateTransform t( mWgs84CRS, mMapCanvas->mapRenderer()->destinationSrs() );
4444
try
4545
{
4646
mCenter = t.transform( point );
4747
}
48-
catch( QgsCsException e ) //silently ignore transformation exceptions
48+
catch ( QgsCsException e ) //silently ignore transformation exceptions
4949
{
5050
return;
5151
}
@@ -62,7 +62,7 @@ void QgsGpsMarker::setCenter( const QgsPoint& point )
6262
void QgsGpsMarker::paint( QPainter* p )
6363
{
6464
QSvgRenderer mySVG;
65-
if( !mySVG.load( QString( ":/images/north_arrows/gpsarrow2.svg" ) ) )
65+
if ( !mySVG.load( QString( ":/images/north_arrows/gpsarrow2.svg" ) ) )
6666
{
6767
qDebug( "GPS marker not found!" );
6868
return;

src/app/gps/qwtpolar/qwt_polar_itemdict.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class QwtPolarItemDict::PrivateData
2828
// for lists in Qt4. The implementation below
2929
// is slow, but there shouldn't be many plot items.
3030

31-
// TODO add binary search
31+
// TODO add binary search
3232

3333
#if QT_VERSION < 0x040000
3434
QValueListIterator<QwtPolarItem *> it;

src/app/legend/qgslegendgroup.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
#include <QIcon>
2626

2727
QgsLegendGroup::QgsLegendGroup( QTreeWidgetItem * theItem, QString theName )
28-
: QgsLegendItem( theItem, theName )
28+
: QgsLegendItem( theItem, theName )
2929
{
3030
mType = LEGEND_GROUP;
3131
setFlags( Qt::ItemIsEditable | Qt::ItemIsUserCheckable | Qt::ItemIsEnabled | Qt::ItemIsSelectable );
@@ -34,7 +34,7 @@ QgsLegendGroup::QgsLegendGroup( QTreeWidgetItem * theItem, QString theName )
3434
setIcon( 0, myIcon );
3535
}
3636
QgsLegendGroup::QgsLegendGroup( QTreeWidget* theListView, QString theString )
37-
: QgsLegendItem( theListView, theString )
37+
: QgsLegendItem( theListView, theString )
3838
{
3939
mType = LEGEND_GROUP;
4040
setFlags( Qt::ItemIsEditable | Qt::ItemIsUserCheckable | Qt::ItemIsEnabled | Qt::ItemIsSelectable );

src/app/qgisapp.cpp

+20-20
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, QWidget * parent,
550550
}
551551
else
552552
{
553-
QgsDebugMsg( "Tips are disabled");
553+
QgsDebugMsg( "Tips are disabled" );
554554
}
555555

556556
//finally show all the application settings as initialised above
@@ -1893,7 +1893,7 @@ void QgisApp::createToolBars()
18931893
mHelpToolBar->addAction( mActionHelpContents );
18941894
mHelpToolBar->addAction( QWhatsThis::createAction() );
18951895
mToolbarMenu->addAction( mHelpToolBar->toggleViewAction() );
1896-
1896+
18971897
//
18981898
// Raster Toolbar
18991899
mRasterToolBar = addToolBar( tr( "Raster" ) );
@@ -2050,18 +2050,18 @@ void QgisApp::setIconSizes( int size )
20502050
//Set the icon size of for all the toolbars created in the future.
20512051
setIconSize( QSize( size, size ) );
20522052

2053-
//Change all current icon sizes.
2054-
QList<QToolBar *> toolbars = findChildren<QToolBar *>();
2055-
foreach( QToolBar * toolbar, toolbars )
2056-
{
2057-
toolbar->setIconSize( QSize( size, size ) );
2058-
}
2059-
2060-
QSet<QgsComposer*>::iterator composerIt = mPrintComposers.begin();
2061-
for ( ; composerIt != mPrintComposers.end(); ++composerIt )
2062-
{
2063-
( *composerIt )->setIconSizes(size);
2064-
}
2053+
//Change all current icon sizes.
2054+
QList<QToolBar *> toolbars = findChildren<QToolBar *>();
2055+
foreach( QToolBar * toolbar, toolbars )
2056+
{
2057+
toolbar->setIconSize( QSize( size, size ) );
2058+
}
2059+
2060+
QSet<QgsComposer*>::iterator composerIt = mPrintComposers.begin();
2061+
for ( ; composerIt != mPrintComposers.end(); ++composerIt )
2062+
{
2063+
( *composerIt )->setIconSizes( size );
2064+
}
20652065
}
20662066

20672067
void QgisApp::setTheme( QString theThemeName )
@@ -5525,22 +5525,22 @@ void QgisApp::localHistogramStretch()
55255525
}
55265526
if ( rlayer->drawingStyle() == QgsRasterLayer::SingleBandGray ||
55275527
rlayer->drawingStyle() == QgsRasterLayer::MultiBandSingleBandGray
5528-
)
5528+
)
55295529
{
55305530
rlayer->setContrastEnhancementAlgorithm( "StretchToMinimumMaximum" );
55315531
rlayer->setMinimumMaximumUsingLastExtent();
5532-
rlayer->setCacheImage(NULL);
5532+
rlayer->setCacheImage( NULL );
55335533
//refreshLayerSymbology( rlayer->getLayerID() );
55345534
mMapCanvas->refresh();
55355535
return;
55365536
}
55375537
else
55385538
{
55395539
QMessageBox::information( this,
5540-
tr( "No Valid Raster Layer Selected" ),
5541-
tr( "To perform a local histogram stretch, you need to have a grayscale "
5542-
"(multiband single layer, or singleband grayscale) raster layer "
5543-
"selected." ) );
5540+
tr( "No Valid Raster Layer Selected" ),
5541+
tr( "To perform a local histogram stretch, you need to have a grayscale "
5542+
"(multiband single layer, or singleband grayscale) raster layer "
5543+
"selected." ) );
55445544
return;
55455545
}
55465546
}

src/app/qgsdisplayangle.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ QgsDisplayAngle::QgsDisplayAngle( QWidget * parent, Qt::WindowFlags f ): QDialog
2727
else
2828
mcbProjectionEnabled->setCheckState( Qt::Unchecked );
2929

30-
connect( mcbProjectionEnabled, SIGNAL( stateChanged(int) ),
31-
this, SLOT( changeState() ) );
32-
connect( mcbProjectionEnabled, SIGNAL( stateChanged(int) ),
33-
this, SIGNAL( changeProjectionEnabledState() ) );
30+
connect( mcbProjectionEnabled, SIGNAL( stateChanged( int ) ),
31+
this, SLOT( changeState() ) );
32+
connect( mcbProjectionEnabled, SIGNAL( stateChanged( int ) ),
33+
this, SIGNAL( changeProjectionEnabledState() ) );
3434
}
3535

3636
QgsDisplayAngle::~QgsDisplayAngle()
@@ -65,7 +65,7 @@ void QgsDisplayAngle::changeState()
6565
{
6666
QSettings settings;
6767
if ( mcbProjectionEnabled->isChecked() )
68-
settings.setValue( "/qgis/measure/projectionEnabled", 2);
68+
settings.setValue( "/qgis/measure/projectionEnabled", 2 );
6969
else
70-
settings.setValue( "/qgis/measure/projectionEnabled", 0);
70+
settings.setValue( "/qgis/measure/projectionEnabled", 0 );
7171
}

src/app/qgsdisplayangle.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class QgsDisplayAngle: public QDialog, private Ui::QgsDisplayAngleBase
3434

3535
signals:
3636
void changeProjectionEnabledState();
37-
37+
3838
private slots:
3939
void changeState();
4040

src/app/qgslabelpropertydialog.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class QgsMapRenderer;
2828
/**A dialog to enter data defined label attributes*/
2929
class QgsLabelPropertyDialog: public QDialog, private Ui::QgsLabelPropertyDialogBase
3030
{
31-
Q_OBJECT
31+
Q_OBJECT
3232
public:
3333
QgsLabelPropertyDialog( const QString& layerId, int featureId, QgsMapRenderer* renderer, QWidget * parent = 0, Qt::WindowFlags f = 0 );
3434
~QgsLabelPropertyDialog();
@@ -48,7 +48,7 @@ class QgsLabelPropertyDialog: public QDialog, private Ui::QgsLabelPropertyDialog
4848
void on_mBufferColorButton_clicked();
4949
void on_mHaliComboBox_currentIndexChanged( const QString& text );
5050
void on_mValiComboBox_currentIndexChanged( const QString& text );
51-
void on_mLabelTextLineEdit_textChanged ( const QString& text );
51+
void on_mLabelTextLineEdit_textChanged( const QString& text );
5252

5353
private:
5454
/**Sets activation / values to the gui elements depending on the label settings and feature values*/

src/app/qgsmaptoolselect.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,15 @@
2929

3030

3131
QgsMapToolSelect::QgsMapToolSelect( QgsMapCanvas* canvas )
32-
: QgsMapTool( canvas )
32+
: QgsMapTool( canvas )
3333
{
3434
mCursor = Qt::ArrowCursor;
3535
}
3636

3737
void QgsMapToolSelect::canvasReleaseEvent( QMouseEvent * e )
3838
{
3939
QgsVectorLayer* vlayer = QgsMapToolSelectUtils::getCurrentVectorLayer( mCanvas );
40-
if( vlayer == NULL )
40+
if ( vlayer == NULL )
4141
{
4242
return;
4343
}

src/core/qgscoordinatereferencesystem.cpp

+18-18
Original file line numberDiff line numberDiff line change
@@ -99,30 +99,30 @@ bool QgsCoordinateReferenceSystem::createFromId( const long theId, CrsType theTy
9999
bool QgsCoordinateReferenceSystem::createFromString( const QString theDefinition )
100100
{
101101
bool result = false;
102-
QRegExp reCrsId("^(epsg|postgis|internal)\\:(\\d+)$",Qt::CaseInsensitive);
103-
if( reCrsId.indexIn(theDefinition) == 0)
102+
QRegExp reCrsId( "^(epsg|postgis|internal)\\:(\\d+)$", Qt::CaseInsensitive );
103+
if ( reCrsId.indexIn( theDefinition ) == 0 )
104104
{
105-
QString authName = reCrsId.cap(1).toLower();
106-
CrsType type = InternalCrsId;
107-
if( authName == "epsg" ) type = EpsgCrsId;
108-
if( authName == "postgis" ) type = PostgisCrsId;
109-
long id = reCrsId.cap(2).toLong();
110-
result = createFromId(id,type);
105+
QString authName = reCrsId.cap( 1 ).toLower();
106+
CrsType type = InternalCrsId;
107+
if ( authName == "epsg" ) type = EpsgCrsId;
108+
if ( authName == "postgis" ) type = PostgisCrsId;
109+
long id = reCrsId.cap( 2 ).toLong();
110+
result = createFromId( id, type );
111111
}
112112
else
113113
{
114-
QRegExp reCrsStr("^(?:(wkt|proj4)\\:)?(.+)$",Qt::CaseInsensitive);
115-
if( reCrsStr.indexIn(theDefinition) == 0 )
114+
QRegExp reCrsStr( "^(?:(wkt|proj4)\\:)?(.+)$", Qt::CaseInsensitive );
115+
if ( reCrsStr.indexIn( theDefinition ) == 0 )
116+
{
117+
if ( reCrsStr.cap( 1 ).toLower() == "proj4" )
116118
{
117-
if( reCrsStr.cap(1).toLower() == "proj4" )
118-
{
119-
result = createFromProj4(reCrsStr.cap(2));
120-
}
121-
else
122-
{
123-
result = createFromWkt(reCrsStr.cap(2));
124-
}
119+
result = createFromProj4( reCrsStr.cap( 2 ) );
125120
}
121+
else
122+
{
123+
result = createFromWkt( reCrsStr.cap( 2 ) );
124+
}
125+
}
126126
}
127127
return result;
128128
}

src/core/qgscoordinatereferencesystem.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
5757
~QgsCoordinateReferenceSystem();
5858

5959
/*!
60-
* Constructs a CRS object from a string definition as defined in the createFromString
60+
* Constructs a CRS object from a string definition as defined in the createFromString
6161
* member function (by default a WKT definition).
6262
* @param theDefinition A String containing a coordinate reference system definition.
6363
*/
@@ -162,7 +162,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
162162
* @return bool TRUE if sucess else false
163163
*/
164164
bool createFromProj4( const QString theProjString );
165-
165+
166166
/*! Set up this srs from a string definition, by default a WKT definition. Otherwise
167167
* the string defines a authority, followed by a colon, followed by the definition.
168168
* The authority can be one of "epsg", "postgis", "internal" for integer definitions,

src/core/qgsmaprenderer.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -235,13 +235,13 @@ void QgsMapRenderer::render( QPainter* painter )
235235
}
236236

237237
// wait
238-
if( mDrawing )
238+
if ( mDrawing )
239239
{
240240
QgsDebugMsg( "already rendering" );
241241
QCoreApplication::processEvents();
242242
}
243243

244-
if( mDrawing )
244+
if ( mDrawing )
245245
{
246246
QgsDebugMsg( "still rendering - skipping" );
247247
return;
@@ -381,7 +381,7 @@ void QgsMapRenderer::render( QPainter* painter )
381381
split = splitLayersExtent( ml, r1, r2 );
382382
ct = new QgsCoordinateTransform( ml->srs(), *mDestCRS );
383383
mRenderContext.setExtent( r1 );
384-
if( !r1.isFinite() || !r2.isFinite() ) //there was a problem transforming the extent. Skip the layer
384+
if ( !r1.isFinite() || !r2.isFinite() ) //there was a problem transforming the extent. Skip the layer
385385
{
386386
continue;
387387
}

src/core/qgspallabeling.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,7 @@ void QgsPalLayerSettings::registerFeature( QgsFeature& f, const QgsRenderContext
578578

579579
if ( distance != 0 )
580580
{
581-
if( distInMapUnits ) //convert distance from mm/map units to pixels
581+
if ( distInMapUnits ) //convert distance from mm/map units to pixels
582582
{
583583
distance /= context.mapToPixel().mapUnitsPerPixel();
584584
}

src/core/spatialindex/include/Tools.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ namespace Tools
316316

317317
// since all base classes are interfaces (there is no state involved) all
318318
// inheritance can be virtual for efficiency.
319-
interface IShape : public virtual ISerializable
319+
interface IShape : public virtual ISerializable
320320
{
321321
public:
322322
virtual bool intersectsShape( const IShape& in ) const = 0;
@@ -332,7 +332,7 @@ namespace Tools
332332

333333
// since all base classes are interfaces (there is no state involved) all
334334
// inheritance can be virtual for efficiency.
335-
interface ITimeShape : public virtual IShape, public virtual IInterval
335+
interface ITimeShape : public virtual IShape, public virtual IInterval
336336
{
337337
public:
338338
virtual bool intersectsShapeInTime( const ITimeShape& in ) const = 0;
@@ -350,7 +350,7 @@ namespace Tools
350350

351351
// since all base classes are interfaces (there is no state involved) all
352352
// inheritance can be virtual for efficiency.
353-
interface IEvolvingShape : public virtual IShape
353+
interface IEvolvingShape : public virtual IShape
354354
{
355355
public:
356356
virtual void getVMBR( Region& out ) const = 0;

0 commit comments

Comments
 (0)