C# 文字动态转成图片

string str="hello"; Graphics g = Graphics.FromImage(new Bitmap(1, 1)); Font font=new Font("宋体", 9); SizeF sizeF = g.MeasureString(str, font); //测量出字体的高度和宽度 Brush brush; //笔刷,颜色 brush = Brushes.Lime; P
相关文章
相关标签/搜索