diff options
author | graemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf> | 2008-05-02 10:12:30 +0000 |
---|---|---|
committer | graemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf> | 2008-05-02 10:12:30 +0000 |
commit | b013ec399cd887c4344b29c66abe205afa28c6fe (patch) | |
tree | e4331b022b6b186351cc1bea17af34eb291b3c55 /src/gui/gui_panel.pas | |
parent | 9e9d3f550ed7170cab0630fe919edbebb3f8fc6f (diff) | |
download | fpGUI-b013ec399cd887c4344b29c66abe205afa28c6fe.tar.xz |
* Applied DrawText patch to correct text alignment parameters.
Diffstat (limited to 'src/gui/gui_panel.pas')
-rw-r--r-- | src/gui/gui_panel.pas | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/src/gui/gui_panel.pas b/src/gui/gui_panel.pas index db192e34..94b83b35 100644 --- a/src/gui/gui_panel.pas +++ b/src/gui/gui_panel.pas @@ -535,7 +535,6 @@ end; procedure TfpgGroupBox.HandlePaint; var r: TfpgRect; - lTxtFlags: TFTextFlags; w: integer; begin inherited HandlePaint; @@ -582,7 +581,6 @@ begin Canvas.SetTextColor(FTextColor); Canvas.SetFont(Font); - lTxtFlags:= [txtTop]; case FAlignment of taLeftJustify: begin @@ -613,9 +611,7 @@ begin Canvas.SetColor(clHilite2); Canvas.DrawLine(w + 5, 0, w + 5, 6); - - Include(lTxtFlags, txtLeft); - Canvas.DrawText(FMargin + 5, 0, FText, lTxtFlags); + Canvas.DrawText(FMargin + 5, 0, FText); end; taRightJustify: begin @@ -646,9 +642,7 @@ begin Canvas.SetColor(clHilite2); Canvas.DrawLine(Width - 6, 0, Width - 6, 6); - - Include(lTxtFlags, txtRight); - Canvas.DrawText(Width - FFont.TextWidth(FText) - FMargin - 5, 0, FText, lTxtFlags); + Canvas.DrawText(Width - FFont.TextWidth(FText) - FMargin - 5, 0, FText); end; taCenter: begin @@ -679,9 +673,7 @@ begin Canvas.SetColor(clHilite2); Canvas.DrawLine(w + FFont.TextWidth(FText) + FMargin * 2 - 1, 0, w + FFont.TextWidth(FText) + FMargin * 2 - 1, 6); - - Include(lTxtFlags, txtHCenter); - Canvas.DrawText(w + FMargin, 0, FText, lTxtFlags); + Canvas.DrawText(w + FMargin, 0, FText); end; end; end; |