实现效果:
知识运用:
重写窗体的OnPint方法 对窗体进行重绘 最后设置透明色
实习代码:
private void Form1_Load(object sender, EventArgs e) { bit = new Bitmap(Properties.Resources.poetry); bit.MakeTransparent(Color.Wheat); } protected override void OnPaint(PaintEventArgs e) { e.Graphics.DrawImage(bit,new Point(0,0)); }