Recent

Author Topic: change TBevel color  (Read 401 times)

fcu

  • Full Member
  • ***
  • Posts: 119
change TBevel color
« on: June 06, 2025, 01:07:42 pm »
Hi
seems Bevel1.color := clred; dose not work
how can i change TBevel color

thanks

jamie

  • Hero Member
  • *****
  • Posts: 7405
Re: change TBevel color
« Reply #1 on: June 07, 2025, 01:27:53 am »
I never found much use for that control.

You can however use the OnPaint handler to customize the appearance as you wish.

Code: Pascal  [Select][+][-]
  1. procedure TForm1.Bevel1Paint(Sender: TObject);
  2. begin
  3.  With Bevel1 do
  4.   Begin
  5.     canvas.Brush.color := Color;
  6.     Canvas.FillRect(ClientRect);
  7.   end;
  8. end;
  9.                              
  10.  

Something like that.

The only true wisdom is knowing you know nothing

 

TinyPortal © 2005-2018