summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2015-02-23 23:47:12 +0900
committerTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2015-02-23 23:50:11 +0900
commit8c693312f211a2046e433079cddaca811cae4a78 (patch)
tree6ddf3fa2086d400a146ca116044a25f8668bfac2 /sc
parentc750e1a92bad68c3518c1836f6a258a19be8b68c (diff)
simplify drawing of splitter, add more flat look
Change-Id: Ie5040c2932715b2505635ff3cb909ccfeb4b7fa0
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/view/tabsplit.cxx44
1 files changed, 11 insertions, 33 deletions
diff --git a/sc/source/ui/view/tabsplit.cxx b/sc/source/ui/view/tabsplit.cxx
index 073aaf11141e..cebbeb04d19e 100644
--- a/sc/source/ui/view/tabsplit.cxx
+++ b/sc/source/ui/view/tabsplit.cxx
@@ -65,17 +65,10 @@ void ScTabSplitter::Paint( const Rectangle& rRect )
{
case SC_SPLIT_NONE:
{
- // Draw 3D border
SetLineColor(GetSettings().GetStyleSettings().GetShadowColor());
- DrawLine(rRect.TopRight(), rRect.BottomRight());
- DrawLine(rRect.BottomLeft(), rRect.BottomRight());
- SetLineColor(GetSettings().GetStyleSettings().GetLightColor());
- DrawLine(rRect.TopLeft(), rRect.TopRight());
- DrawLine(rRect.TopLeft(), rRect.BottomLeft());
- // Fill internal rectangle
- SetLineColor();
- SetFillColor(GetSettings().GetStyleSettings().GetFaceColor());
- DrawRect(Rectangle(rRect.Left()+1, rRect.Top()+1, rRect.Right()-1, rRect.Bottom()-1));
+ SetFillColor(GetSettings().GetStyleSettings().GetShadowColor());
+ DrawRect(Rectangle(rRect.Left(), rRect.Top(), rRect.Right(), rRect.Bottom()));
+
// Draw handle
SetLineColor(Color(COL_BLACK));
SetFillColor(Color(COL_BLACK));
@@ -87,13 +80,9 @@ void ScTabSplitter::Paint( const Rectangle& rRect )
break;
}
case SC_SPLIT_NORMAL:
- SetLineColor(GetSettings().GetStyleSettings().GetLightColor());
- DrawLine(rRect.TopLeft(), rRect.BottomLeft());
SetLineColor(GetSettings().GetStyleSettings().GetShadowColor());
- DrawLine(rRect.TopRight(), rRect.BottomRight());
- SetLineColor();
- SetFillColor(GetSettings().GetStyleSettings().GetFaceColor());
- DrawRect(Rectangle(Point(rRect.Left()+1, rRect.Top()), Point(rRect.Right()-1, rRect.Bottom())));
+ SetFillColor(GetSettings().GetStyleSettings().GetShadowColor());
+ DrawRect(Rectangle(rRect.Left(), rRect.Top(), rRect.Right(), rRect.Bottom()));
break;
case SC_SPLIT_FIX:
// Nothing to draw
@@ -106,18 +95,11 @@ void ScTabSplitter::Paint( const Rectangle& rRect )
{
case SC_SPLIT_NONE:
{
- // Draw 3D border
SetLineColor(GetSettings().GetStyleSettings().GetShadowColor());
- DrawLine(rRect.TopRight(), rRect.BottomRight());
- DrawLine(rRect.BottomLeft(), rRect.BottomRight());
- SetLineColor(GetSettings().GetStyleSettings().GetLightColor());
- DrawLine(rRect.TopLeft(), rRect.TopRight());
- DrawLine(rRect.TopLeft(), rRect.BottomLeft());
- // Fill internal rectangle
- SetLineColor();
- SetFillColor(GetSettings().GetStyleSettings().GetFaceColor());
- DrawRect(Rectangle(rRect.Left()+1, rRect.Top()+1, rRect.Right()-1, rRect.Bottom()-1));
- // Draw handle
+ SetFillColor(GetSettings().GetStyleSettings().GetShadowColor());
+ DrawRect(Rectangle(rRect.Left(), rRect.Top(), rRect.Right(), rRect.Bottom()));
+
+ // Draw handle
SetLineColor(Color(COL_BLACK));
SetFillColor(Color(COL_BLACK));
const long yc = rRect.Top()+rRect.Bottom();
@@ -128,13 +110,9 @@ void ScTabSplitter::Paint( const Rectangle& rRect )
break;
}
case SC_SPLIT_NORMAL:
- SetLineColor(GetSettings().GetStyleSettings().GetLightColor());
- DrawLine(rRect.TopLeft(), rRect.TopRight());
SetLineColor(GetSettings().GetStyleSettings().GetShadowColor());
- DrawLine(rRect.BottomLeft(), rRect.BottomRight());
- SetLineColor();
- SetFillColor(GetSettings().GetStyleSettings().GetFaceColor());
- DrawRect(Rectangle(Point(rRect.Left(), rRect.Top()+1), Point(rRect.Right(), rRect.Bottom()-1)));
+ SetFillColor(GetSettings().GetStyleSettings().GetShadowColor());
+ DrawRect(Rectangle(rRect.Left(), rRect.Top(), rRect.Right(), rRect.Bottom()));
break;
case SC_SPLIT_FIX:
// Nothing to draw