diff options
author | Ahmad H. Al Harthi <aalharthi@kacst.edu.sa> | 2014-02-11 11:19:16 +0300 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-03-05 09:00:34 -0600 |
commit | 60b257f47750a3315edd3024ff7931a0c40ae33a (patch) | |
tree | 2da84344396619b8ce20455684c9ed5637620a45 | |
parent | f57fa998035cb5f859b89451a563137fdaf1b465 (diff) |
fdo#59329 fix docked panels borders
Change-Id: Ia918d644fb57d6fbaeef90c8c1a6806a8d7e589c
Reviewed-on: https://gerrit.libreoffice.org/8412
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | vcl/source/window/splitwin.cxx | 49 |
1 files changed, 12 insertions, 37 deletions
diff --git a/vcl/source/window/splitwin.cxx b/vcl/source/window/splitwin.cxx index c411b51f134a..628d5986b779 100644 --- a/vcl/source/window/splitwin.cxx +++ b/vcl/source/window/splitwin.cxx @@ -137,9 +137,9 @@ static void ImplCalcBorder( WindowAlign eAlign, sal_Bool bNoAlign, rBottom = 0; break; case WINDOWALIGN_LEFT: - rLeft = 2; + rLeft = 0; rTop = 2; - rRight = 0; + rRight = 2; rBottom = 2; break; case WINDOWALIGN_BOTTOM: @@ -179,48 +179,23 @@ void SplitWindow::ImplDrawBorder( SplitWindow* pWin ) { case WINDOWALIGN_BOTTOM: pWin->SetLineColor( rStyleSettings.GetShadowColor() ); - pWin->DrawLine( Point( 0, nDY-2 ), Point( nDX-1, nDY-2 ) ); - pWin->DrawLine( Point( 0, 0 ), Point( 0, nDY-1 ) ); - pWin->DrawLine( Point( nDX-2, 0 ), Point( nDX-2, nDY-3 ) ); - - pWin->SetLineColor( rStyleSettings.GetLightColor() ); - pWin->DrawLine( Point( 0, nDY-1 ), Point( nDX-1, nDY-1 ) ); - pWin->DrawLine( Point( 1, 1 ), Point( 1, nDY-3 ) ); - pWin->DrawLine( Point( nDX-1, 0 ), Point( nDX-1, nDY-1 ) ); + pWin->DrawLine( Point( 0, 6 ), Point( nDX-1, 6 ) ); + pWin->DrawLine( Point( 0, 0 ), Point( nDX-1, 0 ) ); break; case WINDOWALIGN_TOP: pWin->SetLineColor( rStyleSettings.GetShadowColor() ); - pWin->DrawLine( Point( 0, 0 ), Point( nDX-1, 0 ) ); - pWin->DrawLine( Point( 0, 0 ), Point( 0, nDY-1 ) ); - pWin->DrawLine( Point( nDX-2, 0 ), Point( nDX-2, nDY-1 ) ); - - pWin->SetLineColor( rStyleSettings.GetLightColor() ); - pWin->DrawLine( Point( 1, 1 ), Point( nDX-3, 1 ) ); - pWin->DrawLine( Point( 1, 1 ), Point( 1, nDY-1 ) ); - pWin->DrawLine( Point( nDX-1, 1 ), Point( nDX-1, nDY-1 ) ); + pWin->DrawLine( Point( 0, nDY-1 ), Point( nDX-1, nDY-1 ) ); + pWin->DrawLine( Point( 0, nDY-7 ), Point( nDX-1, nDY-7 ) ); break; case WINDOWALIGN_LEFT: pWin->SetLineColor( rStyleSettings.GetShadowColor() ); - pWin->DrawLine( Point( 0, 0 ), Point( nDX-1, 0 ) ); - pWin->DrawLine( Point( 0, 0 ), Point( 0, nDY-1 ) ); - pWin->DrawLine( Point( 0, nDY-2 ), Point( nDX-1, nDY-2 ) ); - - pWin->SetLineColor( rStyleSettings.GetLightColor() ); - pWin->DrawLine( Point( 1, 1 ), Point( nDX-1, 1 ) ); - pWin->DrawLine( Point( 1, 1 ), Point( 1, nDY-3 ) ); - pWin->DrawLine( Point( 1, nDY-1 ), Point( nDX-1, nDY-1 ) ); + pWin->DrawLine( Point( nDX-2, 0 ), Point( nDX-2, nDY-1 ) ); + pWin->DrawLine( Point( nDX-8, 0 ), Point( nDX-8, nDY-1 ) ); break; default: pWin->SetLineColor( rStyleSettings.GetShadowColor() ); - pWin->DrawLine( Point( 0, 0 ), Point( nDX-2, 0 ) ); - pWin->DrawLine( Point( nDX-2, 0 ), Point( nDX-2, nDY-3 ) ); - pWin->DrawLine( Point( 0, nDY-2 ), Point( nDX-2, nDY-2 ) ); - - pWin->SetLineColor( rStyleSettings.GetLightColor() ); - pWin->DrawLine( Point( 0, 1 ), Point( nDX-3, 1 ) ); - pWin->DrawLine( Point( nDX-1, 0 ), Point( nDX-1, nDY-1 ) ); - pWin->DrawLine( Point( 0, nDY-1 ), Point( nDX-1, nDY-1 ) ); - break; + pWin->DrawLine( Point( 0, 0 ), Point( 0, nDY-1 ) ); + pWin->DrawLine( Point( 6, 0 ), Point( 6, nDY-1 ) ); } } } @@ -1650,7 +1625,7 @@ void SplitWindow::ImplSplitMousePos( Point& rMousePos ) void SplitWindow::ImplGetButtonRect( Rectangle& rRect, long nEx, sal_Bool bTest ) const { - long nSplitSize = mpMainSet->mnSplitSize-2; + long nSplitSize = mpMainSet->mnSplitSize-1; if ( mbAutoHide || mbFadeOut || mbFadeIn ) nSplitSize += SPLITWIN_SPLITSIZEEX; @@ -2000,7 +1975,7 @@ void SplitWindow::ImplDrawGrip( const Rectangle& rRect, sal_Bool bHorz, sal_Bool int height = (int) (0.5 * rRect.getHeight() + 0.5); int i = rRect.Top() + (rRect.getHeight() - height) / 2; height += i; - const int x = rRect.Left() + 1; + const int x = rRect.Left() + 2; ImplDrawFadeArrow( Point( x, i-8), bHorz, bLeft ); while( i <= height ) { |