Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix label font size unit from 2.x projects incorrectly restored (fix #…
  • Loading branch information
nyalldawson committed Feb 5, 2017
1 parent c5546b0 commit 6ca2cc1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/qgstextrenderer.cpp
Expand Up @@ -1382,8 +1382,8 @@ void QgsTextFormat::readFromLayer( QgsVectorLayer* layer )

if ( layer->customProperty( QStringLiteral( "labeling/fontSizeUnit" ) ).toString().isEmpty() )
{
d->fontSizeUnits = layer->customProperty( QStringLiteral( "labeling/fontSizeInMapUnits" ), 0 ).toUInt() == 0 ?
QgsUnitTypes::RenderPoints : QgsUnitTypes::RenderMapUnits;
d->fontSizeUnits = layer->customProperty( QStringLiteral( "labeling/fontSizeInMapUnits" ), QVariant( false ) ).toBool() ?
QgsUnitTypes::RenderMapUnits : QgsUnitTypes::RenderPoints;
}
else
{
Expand Down

0 comments on commit 6ca2cc1

Please sign in to comment.