Showing with 16 additions and 23 deletions.
  1. +1 −1 scripts/astyle-all.sh
  2. +1 −9 src/app/CMakeLists.txt
  3. +9 −9 src/core/composer/qgscomposerlegend.cpp
  4. +1 −1 src/core/composer/qgscomposerlegend.h
  5. +4 −3 src/core/qgscoordinatetransform.cpp
2 changes: 1 addition & 1 deletion scripts/astyle-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export elcr="$(tput el)$(tput cr)"

find python src tests -type f -print | while read f; do
case "$f" in
src/app/gps/qwtpolar-*|src/app/qtmain_android.cpp|src/core/spatialite/*|src/core/spatialindex/src/*|src/core/gps/qextserialport/*|src/plugins/grass/qtermwidget/*|src/astyle/*|python/pyspatialite/*|src/providers/sqlanywhere/sqlanyconnection/*|src/providers/spatialite/qspatialite/*|src/plugins/dxf2shp_converter/dxflib/src/*|src/plugins/globe/osgEarthQt/*|src/plugins/globe/osgEarthUtil/*)
src/app/gps/qwtpolar-*|src/core/spatialite/*|src/core/spatialindex/src/*|src/core/gps/qextserialport/*|src/plugins/grass/qtermwidget/*|src/astyle/*|python/pyspatialite/*|src/providers/sqlanywhere/sqlanyconnection/*|src/providers/spatialite/qspatialite/*|src/plugins/dxf2shp_converter/dxflib/src/*|src/plugins/globe/osgEarthQt/*|src/plugins/globe/osgEarthUtil/*)
echo $f skipped
continue
;;
Expand Down
10 changes: 1 addition & 9 deletions src/app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ SET(QGIS_APP_SRCS
qgsmaptoolsplitfeatures.cpp
qgsmaptoolsvgannotation.cpp
qgsmaptooltextannotation.cpp
qgsmaptoolvertexedit.cpp
qgsmaptoolvertexedit.cpp

nodetool/qgsmaptoolnodetool.cpp
nodetool/qgsselectedfeature.cpp
Expand Down Expand Up @@ -160,14 +160,6 @@ SET(QGIS_APP_SRCS
openstreetmap/qgsosmexportdialog.cpp
)

IF (ANDROID)
SET(QGIS_APP_SRCS
${QGIS_APP_SRCS}
qtmain_android.cpp
)
ENDIF (ANDROID)


SET (QGIS_APP_MOC_HDRS
qgisapp.h
qgisappinterface.h
Expand Down
18 changes: 9 additions & 9 deletions src/core/composer/qgscomposerlegend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ QSizeF QgsComposerLegend::paintAndDetermineSize( QPainter* painter )

setColumns( atomList );

double maxColumnWidth = 0;
qreal maxColumnWidth = 0;
if ( mEqualColumnWidth )
{
foreach ( Atom atom, atomList )
Expand All @@ -112,7 +112,7 @@ QSizeF QgsComposerLegend::paintAndDetermineSize( QPainter* painter )
QPointF point( mBoxSpace, columnTop );
bool firstInColumn = true;
double columnMaxHeight = 0;
double columnWidth = 0;
qreal columnWidth = 0;
int column = 0;
foreach ( Atom atom, atomList )
{
Expand Down Expand Up @@ -212,8 +212,8 @@ QSizeF QgsComposerLegend::drawTitle( QPainter* painter, QPointF point, Qt::Align
for ( QStringList::Iterator titlePart = lines.begin(); titlePart != lines.end(); ++titlePart )
{
// it does not draw the last world if rectangle width is exactly text width
double width = textWidthMillimeters( mTitleFont, *titlePart ) + 1;
double height = fontAscentMillimeters( mTitleFont ) + fontDescentMillimeters( mTitleFont );
qreal width = textWidthMillimeters( mTitleFont, *titlePart ) + 1;
qreal height = fontAscentMillimeters( mTitleFont ) + fontDescentMillimeters( mTitleFont );

double left = halignment == Qt::AlignLeft ? point.x() : point.x() - width / 2;

Expand Down Expand Up @@ -249,7 +249,7 @@ QSizeF QgsComposerLegend::drawGroupItemTitle( QgsComposerGroupItem* groupItem, Q
{
y += fontAscentMillimeters( mGroupFont );
if ( painter ) drawText( painter, point.x(), y, *groupPart, mGroupFont );
double width = textWidthMillimeters( mGroupFont, *groupPart );
qreal width = textWidthMillimeters( mGroupFont, *groupPart );
size.rwidth() = qMax( width, size.width() );
if ( groupPart != lines.end() )
{
Expand Down Expand Up @@ -277,7 +277,7 @@ QSizeF QgsComposerLegend::drawLayerItemTitle( QgsComposerLayerItem* layerItem, Q
{
y += fontAscentMillimeters( mLayerFont );
if ( painter ) drawText( painter, point.x(), y, *layerItemPart , mLayerFont );
double width = textWidthMillimeters( mLayerFont, *layerItemPart );
qreal width = textWidthMillimeters( mLayerFont, *layerItemPart );
size.rwidth() = qMax( width, size.width() );
if ( layerItemPart != lines.end() )
{
Expand Down Expand Up @@ -401,7 +401,7 @@ QgsComposerLegend::Nucleon QgsComposerLegend::drawSymbolItem( QgsComposerLegendI
for ( QStringList::Iterator itemPart = lines.begin(); itemPart != lines.end(); ++itemPart )
{
if ( painter ) drawText( painter, labelX, labelY, *itemPart , mItemFont );
labelSize.rwidth() = qMax( textWidthMillimeters( mItemFont, *itemPart ), labelSize.width() );
labelSize.rwidth() = qMax( textWidthMillimeters( mItemFont, *itemPart ), double(labelSize.width()) );
if ( itemPart != lines.end() )
{
labelY += mlineSpacing + textHeight;
Expand Down Expand Up @@ -1012,7 +1012,7 @@ void QgsComposerLegend::setColumns( QList<Atom>& atomList )
// Divide atoms to columns
double totalHeight = 0;
bool first = true;
double maxAtomHeight = 0;
qreal maxAtomHeight = 0;
foreach ( Atom atom, atomList )
{
if ( !first )
Expand Down Expand Up @@ -1073,7 +1073,7 @@ void QgsComposerLegend::setColumns( QList<Atom>& atomList )
}

// Alling labels of symbols for each layr/column to the same labelXOffset
QMap<QString, double> maxSymbolWidth;
QMap<QString, qreal> maxSymbolWidth;
for ( int i = 0; i < atomList.size(); i++ )
{
for ( int j = 0; j < atomList[i].nucleons.size(); j++ )
Expand Down
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposerlegend.h
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ class CORE_EXPORT QgsComposerLegend : public QgsComposerItem
QColor mFontColor;

/**Space between item box and contents*/
double mBoxSpace;
qreal mBoxSpace;
/**Space between columns*/
double mColumnSpace;
/**Vertical space between group entries*/
Expand Down
7 changes: 4 additions & 3 deletions src/core/qgscoordinatetransform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -323,9 +323,10 @@ void QgsCoordinateTransform::transformPolygon( QPolygonF& poly, TransformDirecti
{
//create x, y arrays
int nVertices = poly.size();
QVector<qreal> x( nVertices );
QVector<qreal> y( nVertices );
QVector<qreal> z( nVertices );

QVector<double> x( nVertices );
QVector<double> y( nVertices );
QVector<double> z( nVertices );

for ( int i = 0; i < nVertices; ++i )
{
Expand Down