Skip to content

Commit

Permalink
Provide a little more detail when vector tile expression can't be
Browse files Browse the repository at this point in the history
converted

Refs #58364
  • Loading branch information
nyalldawson committed Aug 16, 2024
1 parent 0c6ca39 commit 4e4329c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/core/vectortile/qgsmapboxglstyleconverter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2970,7 +2970,9 @@ QString QgsMapBoxGlStyleConverter::parseExpression( const QVariantList &expressi
QString op = expression.value( 0 ).toString();
if ( op == QLatin1String( "%" ) && expression.size() >= 3 )
{
return QStringLiteral( "%1 %2 %3" ).arg( parseValue( expression.value( 1 ), context ) ).arg( op ).arg( parseValue( expression.value( 2 ), context ) );
return QStringLiteral( "%1 %2 %3" ).arg( parseValue( expression.value( 1 ), context ),
op,
parseValue( expression.value( 2 ), context ) );
}
else if ( op == QLatin1String( "to-number" ) )
{
Expand Down Expand Up @@ -3143,7 +3145,7 @@ QString QgsMapBoxGlStyleConverter::parseExpression( const QVariantList &expressi
}
else
{
context.pushWarning( QObject::tr( "%1: Skipping unsupported expression" ).arg( context.layerId() ) );
context.pushWarning( QObject::tr( "%1: Skipping unsupported expression \"%2\"" ).arg( context.layerId(), op ) );
return QString();
}
}
Expand Down

0 comments on commit 4e4329c

Please sign in to comment.