┌───────────────────────────┐
│ Form1 │
│┌─────────────────┐ │
││┌────┐ Control1 │ │
│││Graphic1├─┐ │ │
││└────┘Graphics之间半透明容易│ │
││┌────┐ │ │ │
│││Graphic2├─┘ │ │
││└────┘ ├┐ │
│└─────────────────┘│ │
│┌─────────────────┐├控件之间半透明│
││ Control2 ├┘咋就这么难呢?│
│└─────────────────┘ ├┐
└───────────────────────────┘│
├ Form之间半透明容易
┌───────────────────────────┐│
│ Form2 ├┘
└───────────────────────────┘
│ Form1 │
│┌─────────────────┐ │
││┌────┐ Control1 │ │
│││Graphic1├─┐ │ │
││└────┘Graphics之间半透明容易│ │
││┌────┐ │ │ │
│││Graphic2├─┘ │ │
││└────┘ ├┐ │
│└─────────────────┘│ │
│┌─────────────────┐├控件之间半透明│
││ Control2 ├┘咋就这么难呢?│
│└─────────────────┘ ├┐
└───────────────────────────┘│
├ Form之间半透明容易
┌───────────────────────────┐│
│ Form2 ├┘
└───────────────────────────┘
那全透明呢?就是自己实现一个UserControl,有大小,可点击,但同时能看到下面的所有控件。
图片有透明,控件就没透明?其实就是下面的效果
http://hi.baidu.com/tanchengitman/blog/item/c76eb823de489947ac34de36.html
Opacity 100% 就不透明 然后自己改就好了
┌───────────────────────────┐
│ Form_1 │
│┌─────────────────┐ │
││┌────┐ Control1 │ │
│││Graphic1├─┐ │ │
││└────┘Graphics之间半透明容易│ │
││┌────┐ │ │ │
│││Graphic2├─┘ │ │
││└────┘ ├┐ │
│└─────────────────┘│ │
│┌─────────────────┐├控件之间半透明│
││ Control2 ├┘咋就这么难呢?│
│└─────────────────┘ ├┐
└───────────────────────────┘│
├ Form之间半透明容易
┌───────────────────────────┐│
│ Form_2 ├┘
└───────────────────────────┘
覆盖OnPaint()函数,获取e.Graphics,然后用透明Pen或Brush重绘都试过,是可以透明,但是在控件内部透明,就是说控件本身还是有一个底色的,e.Graphics.Clear(Color.Transparent)清不掉,控件Constructor内setStyle也调用过,UserPaint,双缓冲,Opaque,SupportsTransparentColor都打开了,还是不行,晕死了