SPECIAL OFFER        Order and save right now!
20% off with the 729824315 dicscount code for Ultimate Pack and any another product for Delphi from Greatis Programming!

⤷ Set color of text and backgroud

One of the ways to set text color and background color is using SetTextColor and SetBkColor function.

procedure TForm1.Button1Click(Sender: TObject);
  SetTextColor(Form1.Canvas.Handle, clRed);
  SetBkColor(Form1.Canvas.Handle, clGray);
  SetBkMode(Form1.Canvas.Handle, OPAQUE);
  Form1.Canvas.TextOut(10, 10, 'Test Test Test Test Test Test');
More for developers
Databases for Amazon Associates
Amazon Categories
Amazon Nodes