delphi TFontDialog

delphi TFontDialog
 
设置前先获得Memo的字体属性并设置给FontDialog 然后再设置MEMO的字体属性
 
//设置Memo的字体属性
procedure TForm1.mni_FontClick(Sender: TObject);
begin
   with TFontDialog.Create( nil) do
   begin
    Font :=Memo1.Font;
    Options := [fdApplyButton];
     if Execute() then
       Memo1.Font :=Font;
   end;
end;




你可能感兴趣的:(Delphi)