首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > C++ Builder >

高手

2012-02-20 
求助: 求助高手Label1- Font- StyleTFontStyles() fsBold fsItalic  粗斜体Label1- Font- Styl

求助: 求助高手
Label1-> Font-> Style   =   TFontStyles() < <   fsBold   < <   fsItalic;     粗斜体
Label1-> Font-> Style   =   TFontStyles() < <   fsItalic;   &#12539;&#12539;斜体
Label1-> Font-> Style   =   TFontStyles() < <   fsBold   ;  粗体
那正常体怎么写的    
  这样写     Label1-> Font-> Style   =   TFontStyles()         ?     貌似不行啊    


[解决办法]
帮助里找到的
This example sets a Label 's Font Style to fsBold and fsUnderline.

void __fastcall TForm1::Button1Click(TObject *Sender)
{
Label1-> Font-> Style = TFontStyles() < < fsBold < < fsUnderline;
}
procedure Form1.Button1Click(Sender: TObject);
begin
Label1.Font.Style := [fsBold,fsUnderline];
end;

This example demonstrates how to clear any Styles that were previously set.

void __fastcall TForm1::Button2Click(TObject *Sender)
{
Label1-> Font-> Style = TFontStyles();
}

热点排行