Skip to content

Commit

Permalink
Fixed resizing of font marker when units are map units.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk@13409 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder committed Apr 29, 2010
1 parent a1d5dcd commit 31f4b74
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/core/symbology-ng/qgsmarkersymbollayerv2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,9 @@ QString QgsFontMarkerSymbolLayerV2::layerType() const

void QgsFontMarkerSymbolLayerV2::startRender( QgsSymbolV2RenderContext& context )
{
mFont = QFont( mFontFamily, MM2POINT( mSize ) / context.renderContext().rasterScaleFactor() );
double pixelSize = context.outputPixelSize( mSize );
mFont = QFont( mFontFamily );
mFont.setPixelSize( pixelSize / context.renderContext().rasterScaleFactor() );
QFontMetrics fm( mFont );
mChrOffset = QPointF( fm.width( mChr ) / 2, -fm.ascent() / 2 );

Expand Down

0 comments on commit 31f4b74

Please sign in to comment.