Skip to content

Commit 4254d4e

Browse files
committed
Add casts to double to fix compilation on ARM
1 parent 9a2327c commit 4254d4e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/core/composer/qgscomposerhtml.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ double QgsComposerHtml::maxFrameWidth() const
233233
QList<QgsComposerFrame*>::const_iterator frameIt = mFrameItems.constBegin();
234234
for ( ; frameIt != mFrameItems.constEnd(); ++frameIt )
235235
{
236-
maxWidth = qMax( maxWidth, ( *frameIt )->boundingRect().width() );
236+
maxWidth = qMax( maxWidth, ( double )(( *frameIt )->boundingRect().width() ) );
237237
}
238238

239239
return maxWidth;

src/core/layertree/qgslayertreemodellegendnode.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ QgsLayerTreeModelLegendNode::ItemMetrics QgsLayerTreeModelLegendNode::draw( cons
6262
// itemHeight here is not realy item height, it is only for symbol
6363
// vertical alignment purpose, i.e. ok take single line height
6464
// if there are more lines, thos run under the symbol
65-
double itemHeight = qMax( settings.symbolSize().height(), textHeight );
65+
double itemHeight = qMax(( double ) settings.symbolSize().height(), textHeight );
6666

6767
ItemMetrics im;
6868
im.symbolSize = drawSymbol( settings, ctx, itemHeight );
@@ -334,8 +334,8 @@ QSizeF QgsSymbolV2LegendNode::drawSymbol( const QgsLegendSettings& settings, Ite
334334
p->restore();
335335
}
336336

337-
return QSizeF( qMax( width + 2 * widthOffset, settings.symbolSize().width() ),
338-
qMax( height + 2 * heightOffset, settings.symbolSize().height() ) );
337+
return QSizeF( qMax( width + 2 * widthOffset, ( double ) settings.symbolSize().width() ),
338+
qMax( height + 2 * heightOffset, ( double ) settings.symbolSize().height() ) );
339339
}
340340

341341

src/core/qgslegendrenderer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,7 +375,7 @@ QSizeF QgsLegendRenderer::drawTitle( QPainter* painter, QPointF point, Qt::Align
375375
switch ( halignment )
376376
{
377377
case Qt::AlignHCenter:
378-
textBoxWidth = ( qMin( point.x(), legendWidth - point.x() ) - mSettings.boxSpace() ) * 2.0;
378+
textBoxWidth = ( qMin(( double ) point.x(), legendWidth - point.x() ) - mSettings.boxSpace() ) * 2.0;
379379
textBoxLeft = point.x() - textBoxWidth / 2.;
380380
break;
381381
case Qt::AlignRight:

0 commit comments

Comments
 (0)