dropshadow

how can I add attached drop shadows to uinavigationbar and uitoolbar

风格不统一 提交于 2019-12-02 21:29:49
I'm working on an app that uses a custom image for UINavigationBar and UIToolbar, which is fine, but they also need a drop shadow below the nav bar and above the toolbar, which would always rest above all other view controllers. I cannot simply make background images which include the shadows as this would not work well with my tableviews. I also need the shadows animate away when I set nav bar and tool bar to hidden (animated). I've looked through Stack Overflow and other sources on the net, and have worked through the proposed solutions but I cannot successfully subclass UINavigationBar,

I am trying to add a drop shadow to a UImageView

浪尽此生 提交于 2019-12-01 22:43:01
I am trying to add a drop shadow to a UIImage view. I get a shadow but it is clipped to the edges of the image view and I am not sure why since I correctly set the uiimageview.clipsToBounds to NO. Below is the code: -(void)addShadow { UIGraphicsBeginImageContext(self.frame.size); CGContextRef myContext = UIGraphicsGetCurrentContext(); float myColorValues[] = {0, 0, 0, darkness};// 3 CGColorRef myColor;// 4 CGColorSpaceRef myColorSpace; CGContextSaveGState(myContext);// 6 myColorSpace = CGColorSpaceCreateDeviceRGB ();// 9 myColor = CGColorCreate (myColorSpace, myColorValues);// 10

I am trying to add a drop shadow to a UImageView

最后都变了- 提交于 2019-12-01 21:51:27
问题 I am trying to add a drop shadow to a UIImage view. I get a shadow but it is clipped to the edges of the image view and I am not sure why since I correctly set the uiimageview.clipsToBounds to NO. Below is the code: -(void)addShadow { UIGraphicsBeginImageContext(self.frame.size); CGContextRef myContext = UIGraphicsGetCurrentContext(); float myColorValues[] = {0, 0, 0, darkness};// 3 CGColorRef myColor;// 4 CGColorSpaceRef myColorSpace; CGContextSaveGState(myContext);// 6 myColorSpace =

Win32: How to draw outside my window?

风流意气都作罢 提交于 2019-11-30 22:55:55
Looking at a Windows tooltips class hint window, i see that it draws its drop-shadow outside the hint window's actual rectangle. Using SpyXX - i can get the tooltip's window rect, and class styles: Rectangle: (440, 229)-(544, 249), 104x20 Restored Rect: (440, 229)-(544, 249), 104x20 Client Rect: (0, 0)-(104, 20), 104x20 You'll notice that the drop shadow you see is physically outside the window that's being drawn. How can i draw a shadow outside around my window, while being outside my window? Note : The shadow is not drawn using the standard CS_DROPSHADOW class style. i've confirmed this

HTML/CSS: How does Google create this drop shadow over their maps?

人走茶凉 提交于 2019-11-30 17:44:47
问题 Question : How does Google create the dropshadow next to the vertical scrollbar over the Google Map? This is a screenshot depicting exactly what I'm talking about. This seems to be regardless of browser (IE, Firefox, Chrome) and platform (Windows, Mac, Linux). 回答1: It's actually a series of five razor-thin DIVs, each with decreasing opacity, stacked next to each other. You can see this for yourself by using Firebug and clicking on the shadow area. 回答2: IE 8: Use F12, select the arrow control,

Internet Explorer - CSS Shadow All Around

无人久伴 提交于 2019-11-30 14:50:22
问题 I have been ripping my hair out over this issue, I want a simple shadow that does around the whole element, besides for the top. I got it to work in Firefox and Chrome with no problem. But IE has this weird "direction" setting where as the other as 4 numbers to define the shadow. Can someone help me define the right CSS so that it will have a shadow around the whole element besides the top. /* For Firefox and Chrome */ -moz-box-shadow: 0px 0px 7px #000; -webkit-box-shadow: 0px 0px 7px #000;

Internet Explorer - CSS Shadow All Around

蹲街弑〆低调 提交于 2019-11-30 12:18:30
I have been ripping my hair out over this issue, I want a simple shadow that does around the whole element, besides for the top. I got it to work in Firefox and Chrome with no problem. But IE has this weird "direction" setting where as the other as 4 numbers to define the shadow. Can someone help me define the right CSS so that it will have a shadow around the whole element besides the top. /* For Firefox and Chrome */ -moz-box-shadow: 0px 0px 7px #000; -webkit-box-shadow: 0px 0px 7px #000; box-shadow: 0px 0px 7px #000; /* for IE */ -ms-filter: "progid:DXImageTransform.Microsoft.Shadow

WPF DropShadowEffect Causing Blurriness

纵饮孤独 提交于 2019-11-30 12:14:24
I've observed that applying a DropShadowEffect to a UIElement sporadically causes the UIElement's content to blur a bit. It's a pretty nasty effect: it can cause a photograph to look out of focus or worse- make an entire 'popup' region completely illegible. I haven't seen anyone else complaining about this, so my inclination is to think that there is something that I am doing wrong. Sample use (blurs content at random): <Border> <Border.Effect> <DropShadowEffect /> </Border.Effect> <!-- (Content) --> </Border> But removing the DropShadowEffect clears it up: <Border> <!--<Border.Effect>

Remove action bar shadow programmatically

一曲冷凌霜 提交于 2019-11-30 11:13:15
How can i remove the drop shadow of action bar from java code ?. If i remove from the style it is working fine. <style name="MyTheme" parent="Theme.Sherlock"> .... <item name="windowContentOverlay">@null</item> <item name="android:windowContentOverlay">@null</item> .... </style> But i need to remove and add it dynamically from java code. erakitin There is no way to set value for windowContentOverlay attribute programmatically. But you can define two different themes, one for Activities with a visible ActionBar shadow and one for others: <!-- Your main theme with ActionBar shadow. --> <style

Algorithm for fast Drop shadow in GDI+

旧巷老猫 提交于 2019-11-30 06:23:32
问题 What is an efficient way to add a drop-shadow to an image in GDI? Right now i start with my image: i use ImageAttributes and a ColorMatrix to draw the image's alpha mask to a new image: colorMatrix = ( ( 0, 0, 0, 0, 0), ( 0, 0, 0, 0, 0), ( 0, 0, 0, 0, 0), (-1, -1, -1, 1, 0), ( 1, 1, 1, 0, 1) ); i then apply a Gaussian Blur convolution kernel, and offset it slightly: And then i draw my original image back over top: Problem is that it's just too slow, it takes about 170ms to generate the image