diff options
author | Herbert Duerr [hdu] <duerr@sun.com> | 2010-08-04 16:05:53 +0200 |
---|---|---|
committer | Herbert Duerr [hdu] <duerr@sun.com> | 2010-08-04 16:05:53 +0200 |
commit | 92d15d82cfa7c7cc9ac3e8f7f90d89e2669ad30e (patch) | |
tree | a7fd942bc91f167d12a18657ae9a73ef328ce413 /vcl/source | |
parent | 3abef1d286a55f0d99c6f0af9d0ab9bb2a77eaee (diff) |
#i106817# fix rotated textline drawing also in mirrored mode
Diffstat (limited to 'vcl/source')
-rw-r--r-- | vcl/source/gdi/outdev3.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/vcl/source/gdi/outdev3.cxx b/vcl/source/gdi/outdev3.cxx index aacbf7ed416c..c45f1a5bb287 100644 --- a/vcl/source/gdi/outdev3.cxx +++ b/vcl/source/gdi/outdev3.cxx @@ -4090,10 +4090,14 @@ void OutputDevice::ImplDrawTextLine( long nX, long nY, BOOL bUnderlineDone = FALSE; BOOL bOverlineDone = FALSE; - // TODO: fix rotated text if ( IsRTLEnabled() ) + { // --- RTL --- mirror at basex - nX = nDistX - nWidth - (nX - nDistX - 1); + long nRotDX = nDistX; + if( mpFontEntry->mnOrientation ) + nRotDX = FRound( nRotDX * cos( mpFontEntry->mnOrientation*F_PI1800 ) ); + nX += 1 + nWidth - nRotDX; + } if ( !IsTextLineColor() ) aUnderlineColor = GetTextColor(); |