Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/inamiy/yiinnershadowview
Inner-shadow UIView/CALayer for iOS.
https://github.com/inamiy/yiinnershadowview
Last synced: 5 days ago
JSON representation
Inner-shadow UIView/CALayer for iOS.
- Host: GitHub
- URL: https://github.com/inamiy/yiinnershadowview
- Owner: inamiy
- Created: 2012-10-14T14:35:04.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2016-08-16T16:16:20.000Z (about 8 years ago)
- Last Synced: 2024-10-31T19:42:28.981Z (12 days ago)
- Language: Objective-C
- Homepage: http://stackoverflow.com/questions/4431292/inner-shadow-effect-on-uiview-layer
- Size: 64.5 KB
- Stars: 155
- Watchers: 5
- Forks: 14
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# YIInnerShadowView
Inner-shadow UIView/CALayer for iOS.
## How to use
```
YIInnerShadowView* innerShadowView = [[YIInnerShadowView alloc] initWithFrame:frame];
innerShadowView.shadowRadius = 5;
innerShadowView.shadowMask = YIInnerShadowMaskVertical;
[self.view addSubview:innerShadowView];
```### YIInnerShadowMask
```
typedef enum {
YIInnerShadowMaskNone = 0,
YIInnerShadowMaskTop = 1 << 1,
YIInnerShadowMaskBottom = 1 << 2,
YIInnerShadowMaskLeft = 1 << 3,
YIInnerShadowMaskRight = 1 << 4,
YIInnerShadowMaskVertical = YIInnerShadowMaskTop | YIInnerShadowMaskBottom,
YIInnerShadowMaskHorizontal = YIInnerShadowMaskLeft | YIInnerShadowMaskRight,
YIInnerShadowMaskAll = YIInnerShadowMaskVertical | YIInnerShadowMaskHorizontal
} YIInnerShadowMask;```
## Acknowledgement
Main idea is from Matt Wilding:
## License
`YIInnerShadowView` is available under the [Beerware](http://en.wikipedia.org/wiki/Beerware) license.
If we meet some day, and you think this stuff is worth it, you can buy me a beer in return.