summaryrefslogtreecommitdiff
path: root/src/gui/fpg_panel.pas
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2010-07-02 13:05:38 +0200
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2010-07-02 13:05:38 +0200
commite66f029d80f3f442275c5a124063a2621f231ae5 (patch)
tree6122cc351fd83498d363797dedb90a6a34d20377 /src/gui/fpg_panel.pas
parent6c42452705d72c48958791edcd1961d44261d52d (diff)
downloadfpGUI-e66f029d80f3f442275c5a124063a2621f231ae5.tar.xz
fpg_panel: BorderStyle only really applies to bsBox style
The code now reflects that. All other bsXXX style use a single pixel solid line.
Diffstat (limited to 'src/gui/fpg_panel.pas')
-rw-r--r--src/gui/fpg_panel.pas16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/gui/fpg_panel.pas b/src/gui/fpg_panel.pas
index 68129136..bf8b7798 100644
--- a/src/gui/fpg_panel.pas
+++ b/src/gui/fpg_panel.pas
@@ -329,6 +329,11 @@ end;
procedure TfpgBevel.DrawBox;
begin
if FPanelBorder = bsSingle then
+ Canvas.SetLineStyle(1, lsSolid)
+ else
+ Canvas.SetLineStyle(2, lsSolid);
+
+ if FPanelBorder = bsSingle then
Canvas.DrawLine(0, 0, Width - 1, 0)
else
Canvas.DrawLine(0, 1, Width - 1, 1);
@@ -349,6 +354,8 @@ end;
procedure TfpgBevel.DrawFrame;
begin
+ Canvas.SetLineStyle(1, lsSolid);
+
Canvas.DrawLine(0, 0, Width - 1, 0);
Canvas.DrawLine(0, 1, 0, Height - 1);
Canvas.DrawLine(Width - 2, 1, Width - 2, Height - 1);
@@ -367,6 +374,7 @@ end;
procedure TfpgBevel.DrawTopLine;
begin
+ Canvas.SetLineStyle(1, lsSolid);
Canvas.DrawLine(0, 0, Width, 0);
if Style = bsRaised then
@@ -379,6 +387,7 @@ end;
procedure TfpgBevel.DrawBottomLine;
begin
+ Canvas.SetLineStyle(1, lsSolid);
Canvas.DrawLine(0, Height - 2, Width, Height - 2);
if Style = bsRaised then
@@ -391,6 +400,7 @@ end;
procedure TfpgBevel.DrawLeftLine;
begin
+ Canvas.SetLineStyle(1, lsSolid);
Canvas.DrawLine(0, 1, 0, Height - 1);
if Style = bsRaised then
@@ -403,6 +413,7 @@ end;
procedure TfpgBevel.DrawRightLine;
begin
+ Canvas.SetLineStyle(1, lsSolid);
Canvas.DrawLine(Width - 2, 0, Width - 2, Height - 1);
if Style = bsRaised then
@@ -447,11 +458,6 @@ procedure TfpgBevel.HandlePaint;
begin
inherited HandlePaint;
- if FPanelBorder = bsSingle then
- Canvas.SetLineStyle(1, lsSolid)
- else
- Canvas.SetLineStyle(2, lsSolid);
-
if Style = bsRaised then
Canvas.SetColor(clHilite2)
else