[Libreoffice-commits] core.git: Branch 'feature/gsoc14-draw-text-background-color' - vcl/source

matteocam matteo.campanelli at gmail.com
Tue May 27 13:06:23 PDT 2014


 vcl/source/outdev/text.cxx |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

New commits:
commit ebc7be61df384120f1d0420d3e4dc5e3ac5599f4
Author: matteocam <matteo.campanelli at gmail.com>
Date:   Tue May 27 16:05:44 2014 -0400

     SetTextFillColor immediately before DrawTransparent. DrawTextRect commented
    
    Change-Id: Id283624484dfcda91546fd4965bc0b6b92614f55

diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index effb27a..a8b5709 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -149,14 +149,14 @@ void OutputDevice::ImplDrawTextRect( long nBaseX, long nBaseY,
 
     nX += nBaseX;
     nY += nBaseY;
-    mpGraphics->DrawRect( nX, nY, nWidth, nHeight, this ); // original code
+    //mpGraphics->DrawRect( nX, nY, nWidth, nHeight, this ); // original code
 
     Rectangle aRect( Point( nX, nY ), Size( nWidth+1, nHeight+1 ) );
     Polygon   aPoly( aRect );
     PolyPolygon aPolyPoly(aPoly);
-    DrawTransparent(aPolyPoly, 50);
-    // Code above is wrong: it just messes up.
-
+    Color aColor = RGB_COLORDATA(0x66,0x66, 0xFF);
+    SetTextFillColor(aColor);
+    DrawTransparent(aPolyPoly, 70);
 
 }
 
@@ -486,6 +486,7 @@ void OutputDevice::ImplDrawText( SalLayout& rSalLayout )
      and the set it as the new filling color
     */
     if (mbTextBackground) {
+        // FIXME(matteocam)
         // set right background // (XXX: now getting fixed color)
         Color aColor = RGB_COLORDATA(0x66,0x66, 0xFF); // blue-ish
         // SetBackground does not work


More information about the Libreoffice-commits mailing list