![](/img/trans.png)
[英]How can I change the font size of all the screens in a windows forms application
[英]Change font size in a Windows Forms application
在這下面:
我的Windows窗體應用程序具有更改語言的功能,但我的問題是,當我的英文字體應用程序看起來比印地語字體更精細。
以下是我的應用程序的印地語和英語語言的屏幕截圖。
不,您無法更改MessageBox中的字體大小。 MessageBox字體大小由用戶的操作系統定義。
您可以這樣做的唯一方法是創建自己的自定義消息框:
要更改Windows窗體表單字體,只需使用窗體的字體屬性 :
public partial class MainForm : Form
{
public MainForm()
{
InitializeComponent();
this.Font = new System.Drawing.Font(
"Microsoft Sans Serif",
24F,
System.Drawing.FontStyle.Regular,
System.Drawing.GraphicsUnit.Point,
((byte)(0)));
}
}
將“24F”替換為所需的字體大小。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.