Change Font.Style at runtime  

Send By: Q3 Team
Web : http://www.q3.nu
Email: dlib@q3.nu
Date: 18/12/99

Tip accessed 632 times

 


Add or remove Bold, Underline, etc:



 procedure TForm1.Button1Click(Sender: TObject);
 begin
   with Label1 do begin
    Font.Style := Font.Style
                  {+ o - Aņadir-quitar/Add-Remove}
                  + [fsStrikeOut]
                  + [fsItalic]
                  + [fsUnderline]
                  + [fsBold];
    end;
 end;



To add, use +, to remove use -