]> Dogcows Code - chaz/openbox/blobdiff - otk/truerendercontrol.cc
make docks and desktops always on all desktops
[chaz/openbox] / otk / truerendercontrol.cc
index 8e2b10839e5a411441ce02fa3d56eb75679a8528..cc46ebd9794e64774a14289ac46ca62372b2bf0c 100644 (file)
@@ -154,7 +154,7 @@ void TrueRenderControl::drawGradientBackground(
 
   if (texture.relief() != RenderTexture::Flat) {
     if (texture.bevel() == RenderTexture::Bevel1) {
-      for (off = 0, x = 0; x < w; ++x, off++)
+      for (off = 1, x = 1; x < w - 1; ++x, off++)
         highlight(data + off,
                 data + off + (h-1) * w,
                 texture.relief()==RenderTexture::Raised);
@@ -165,7 +165,7 @@ void TrueRenderControl::drawGradientBackground(
     }
 
     if (texture.bevel() == RenderTexture::Bevel2) {
-      for (off = 1, x = 1; x < w - 1; ++x, off++)
+      for (off = 2, x = 2; x < w - 2; ++x, off++)
         highlight(data + off + w,
                 data + off + (h-2) * w,
                 texture.relief()==RenderTexture::Raised);
@@ -205,8 +205,8 @@ void TrueRenderControl::highlight(pixel32 *x, pixel32 *y, bool raised) const
   b = *up & 0xFF;
   b += b >> 1;
   if (r > 255) r = 255;
-  if (g > 255) r = 255;
-  if (b > 255) r = 255;
+  if (g > 255) g = 255;
+  if (b > 255) b = 255;
   *up = (r << 16) + (g << 8) + b;
   
   r = (*down >> 16) & 0xFF;
This page took 0.025243 seconds and 4 git commands to generate.