在图片控制上显示文字

 

public void DrawStringToPictureBox(Image Img, string str)
        {
            Graphics g = null;
            g = Graphics.FromImage(Img);
            Font Var_Font = new Font("宋体", 11);
            Brush Var_Brush = new SolidBrush(Color.Red);
            Point location = new Point(20, 5);
            g.DrawString(str, Var_Font, Var_Brush, location);
        }

 

posted on 2013-11-15 17:09  筑梦1582  阅读(123)  评论(0编辑  收藏  举报