From ee9a1c1e0ae39a273f9dadafd264b5e4a9db588c Mon Sep 17 00:00:00 2001 From: Hugo Pereira Da Costa Date: Wed, 7 Oct 2009 00:54:15 +0000 Subject: [PATCH] re-added the 1 pixel contrast on the top and sides of the titlebar, for 'no-border' and 'no-side-border' window border sizes. This requires svn external update of lib/helper. svn path=/trunk/KDE/kdebase/workspace/; revision=1032139 --- clients/oxygen/oxygenclient.cpp | 41 ++++++++++++++++++++++----------- 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/clients/oxygen/oxygenclient.cpp b/clients/oxygen/oxygenclient.cpp index 49b64bfb05..25c8c5002d 100644 --- a/clients/oxygen/oxygenclient.cpp +++ b/clients/oxygen/oxygenclient.cpp @@ -906,34 +906,49 @@ namespace Oxygen // adjust if there are shadows if( compositingActive() ) frame.adjust(-1,-1, 1, 1); - // dimensions - int x,y,w,h; - frame.getRect(&x, &y, &w, &h); - // shadow and resize handles - if( configuration().frameBorder() >= OxygenConfiguration::BorderTiny ) + if( !isMaximized() ) { - if( !isMaximized() ) + if( configuration().frameBorder() >= OxygenConfiguration::BorderTiny ) { + helper().drawFloatFrame( &painter, frame, backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ), - !compositingActive(), isActive(), + !compositingActive(), isActive() && configuration().useOxygenShadows(), KDecoration::options()->color(ColorTitleBar) ); - } else if( isShade() ) { + } else { - // adjust frame so that only the bottom part of the frame is drawn helper().drawFloatFrame( - &painter, frame.adjusted( -4, -4, 4, 0 ), backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ), - !compositingActive(), isActive(), - KDecoration::options()->color(ColorTitleBar) + &painter, frame, backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ), + false, isActive() && configuration().useOxygenShadows(), + KDecoration::options()->color(ColorTitleBar), + TileSet::Top ); - } + } else if( isShade() ) { + + // adjust frame so that only the bottom part of the frame is drawn + helper().drawFloatFrame( + &painter, frame.adjusted( -4, -4, 4, 0 ), backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ), + !compositingActive(), isActive(), + KDecoration::options()->color(ColorTitleBar) + ); + + } + + if( configuration().frameBorder() >= OxygenConfiguration::BorderTiny ) + { + + + // dimensions + int x,y,w,h; + frame.getRect(&x, &y, &w, &h); + if( isResizable() && !isShade() && !isMaximized() ) {