diff options
-rw-r--r-- | src/gui/fpg_combobox.pas | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/gui/fpg_combobox.pas b/src/gui/fpg_combobox.pas index ba23a0cf..eb119f01 100644 --- a/src/gui/fpg_combobox.pas +++ b/src/gui/fpg_combobox.pas @@ -713,19 +713,16 @@ begin Canvas.SetColor(clSelection); Canvas.SetTextColor(clSelectionText); InflateRect(r, -1, -1); + Canvas.FillRectangle(r); end else begin - if Enabled then - Canvas.SetColor(FBackgroundColor) - else - Canvas.SetColor(clWindowBackground); Canvas.SetTextColor(FTextColor); - r.Left := r.Left + Margin; - r.Width := r.Width - (Margin*2); end; - Canvas.FillRectangle(r); + { adjust rectangle size smaller for text } + r.Left := r.Left + Margin; + r.Width := r.Width - (Margin*2); DoDrawText(r); end; |