Drop shadow in Winforms Controls?

You have to overwrite the CreateParamsproperty like this: private const int CS_DROPSHADOW = 0x00020000; protected override CreateParams CreateParams { get { // add the drop shadow flag for automatically drawing // a drop shadow around the form CreateParams cp = base.CreateParams; cp.ClassStyle |= CS_DROPSHADOW; return cp; } }

-webkit-filter: drop-shadow for other browsers

Ok I have figured this out – the equivalent for opera and firefox is: filter: url(drop-shadow.svg#drop-shadow); where drop-shadow.svg looks like this: <svg height=”0″ xmlns=”http://www.w3.org/2000/svg”> <filter id=”drop-shadow”> <feGaussianBlur in=”SourceAlpha” stdDeviation=”2.2″/> <feOffset dx=”1″ dy=”4″ result=”offsetblur”/> <feFlood flood-color=”rgba(0,0,0,0.3)”/> <feComposite in2=”offsetblur” operator=”in”/> <feMerge> <feMergeNode/> <feMergeNode in=”SourceGraphic”/> </feMerge> </filter> </svg> IE being so crap doesn’t support the svg values feOffset, … Read more