diff options
author | Ivan Timofeev <timofeev.i.s@gmail.com> | 2012-08-05 19:12:39 +0400 |
---|---|---|
committer | Ivan Timofeev <timofeev.i.s@gmail.com> | 2012-08-05 20:30:59 +0400 |
commit | d1501aa5e8f40b6016753f9fb34181a4f914a1d5 (patch) | |
tree | 4ee406e2a8bd9cb05104df92bbfcb0b257f14e1b /starmath/source | |
parent | 20d4cd5e08c1400fcc5ae5eb45861f429b914969 (diff) |
SmCmdBoxWindow: reduce padding from 8 to 4
Change-Id: If87bc63b4bd3fd27eef665261667478d9284ff0b
Diffstat (limited to 'starmath/source')
-rw-r--r-- | starmath/source/view.cxx | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/starmath/source/view.cxx b/starmath/source/view.cxx index a7af46453a79..ad6c23213900 100644 --- a/starmath/source/view.cxx +++ b/starmath/source/view.cxx @@ -74,6 +74,9 @@ #define MINZOOM 25 #define MAXZOOM 800 +// space around the edit window, in pixels +#define CMD_BOX_PADDING 4 + #define SmViewShell #include "smslots.hxx" @@ -721,9 +724,12 @@ SmViewShell * SmCmdBoxWindow::GetView() void SmCmdBoxWindow::Resize() { Rectangle aRect = Rectangle(Point(0, 0), GetOutputSizePixel()); + aRect.Left() += CMD_BOX_PADDING; + aRect.Top() += CMD_BOX_PADDING; + aRect.Right() -= CMD_BOX_PADDING; + aRect.Bottom() -= CMD_BOX_PADDING; + DecorationView aView(this); - aRect.Left() += 8; aRect.Top() += 8; - aRect.Right()-= 8; aRect.Bottom()-= 8; aRect = aView.DrawFrame( aRect, FRAME_DRAW_DOUBLEIN | FRAME_DRAW_NODRAW ); aEdit.SetPosSizePixel(aRect.TopLeft(), aRect.GetSize()); @@ -735,10 +741,13 @@ void SmCmdBoxWindow::Resize() void SmCmdBoxWindow::Paint(const Rectangle& /*rRect*/) { Rectangle aRect = Rectangle(Point(0, 0), GetOutputSizePixel()); + aRect.Left() += CMD_BOX_PADDING; + aRect.Top() += CMD_BOX_PADDING; + aRect.Right() -= CMD_BOX_PADDING; + aRect.Bottom() -= CMD_BOX_PADDING; + DecorationView aView(this); - aRect.Left() += 8; aRect.Top() += 8; - aRect.Right()-= 8; aRect.Bottom()-= 8; - aRect = aView.DrawFrame( aRect, FRAME_DRAW_DOUBLEIN ); + aView.DrawFrame( aRect, FRAME_DRAW_DOUBLEIN ); } |