diff options
author | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2013-06-11 11:41:09 +0200 |
---|---|---|
committer | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2013-06-11 11:41:23 +0200 |
commit | 721f82c9bff871cd11c6a7c41ae080375463a690 (patch) | |
tree | 47db36c9c25ab59dc611bc1f15db3d5581e7ca1b /cppcanvas | |
parent | eb0a738d1b3f1a9df41d55a1defd349264486920 (diff) |
Use a local variable for the points
Change-Id: Ibd274ecd7eaeadaaef9f2a17a0d721355a561431
Diffstat (limited to 'cppcanvas')
-rw-r--r-- | cppcanvas/source/mtfrenderer/emfplus.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cppcanvas/source/mtfrenderer/emfplus.cxx b/cppcanvas/source/mtfrenderer/emfplus.cxx index 7817a79a3df2..47fa72621df5 100644 --- a/cppcanvas/source/mtfrenderer/emfplus.cxx +++ b/cppcanvas/source/mtfrenderer/emfplus.cxx @@ -1618,11 +1618,13 @@ namespace cppcanvas double cellSize = setFont (flags & 0xff, rFactoryParms, rState); rState.textColor = COLOR( brushId ); + ::basegfx::B2DPoint point( Map( lx + 0.15*cellSize, ly + cellSize ) ); + ActionSharedPtr pTextAction( TextActionFactory::createTextAction( // position is just rough guess for now // we should calculate it exactly from layoutRect or font - ::vcl::unotools::pointFromB2DPoint ( Map( lx + 0.15*cellSize, ly + cellSize ) ), + ::vcl::unotools::pointFromB2DPoint ( point ), ::Size(), ::Color(), ::Size(), @@ -1863,9 +1865,11 @@ namespace cppcanvas if( flags & 0x8000 ) rState.textColor = COLOR( brushIndexOrColor ); + ::basegfx::B2DPoint point( Map( charsPosX[0], charsPosY[0] ) ); + ActionSharedPtr pTextAction( TextActionFactory::createTextAction( - ::vcl::unotools::pointFromB2DPoint ( Map( charsPosX[0], charsPosY[0] ) ), + ::vcl::unotools::pointFromB2DPoint ( point ), ::Size(), ::Color(), ::Size(), |