c#中,Bitmap b = new Bitmap("1.bmp"); Graphics g = Graphics.FromImage(b);
答案:2 悬赏:40 手机版
解决时间 2021-04-02 00:57
- 提问者网友:川水往事
- 2021-04-01 17:01
c#中,Bitmap b = new Bitmap("1.bmp"); Graphics g = Graphics.FromImage(b);
最佳答案
- 五星知识达人网友:独钓一江月
- 2021-04-01 18:32
可以用Graphics画到窗体上或者赋值到窗体上:
CreateGraphics().DrawImage(b,new Point(0,0));
或者:
BackgroundImage = b;
CreateGraphics().DrawImage(b,new Point(0,0));
或者:
BackgroundImage = b;
全部回答
- 1楼网友:何以畏孤独
- 2021-04-01 19:38
Bitmap b = Bitmap.FromFile(@"1.bmp") as Bitmap;
Graphics g = this.CreateGraphics();
g.drawImage(b);追问我是在一个类里面创建了一个绘图函数,想在主窗体中调用这个类的函数,然后显示在子窗体中。
Graphics g = this.CreateGraphics();
g.drawImage(b);追问我是在一个类里面创建了一个绘图函数,想在主窗体中调用这个类的函数,然后显示在子窗体中。
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
推荐资讯