Declared in UIView+TKCategory.h
UIView+TKCategory.m

Overview

Additional functionality for UIView.

Properties

cornerRadius

The corner radius of the view.

@property (nonatomic, assign) CGFloat cornerRadius

Declared In

UIView+TKCategory.h

visible

The opposite of hidden.

@property (nonatomic, assign) BOOL visible

Declared In

UIView+TKCategory.h

Instance Methods

addSubviewToBack:

Adds a view to the beginning of the receiver’s list of subviews.

- (void)addSubviewToBack:(UIView *)view

Parameters

view

The view to be added. This view is retained by the receiver. After being added, this view appears below of any other subviews.

Declared In

UIView+TKCategory.h

setBorderWithColor:width:

Set the border for the view.

- (void)setBorderWithColor:(UIColor *)color width:(CGFloat)width

Parameters

color

The color of the border.

width

The width of the border.

Declared In

UIView+TKCategory.h

setShadowWithOffset:opacity:color:radius:

Set the shadow for the view.

- (void)setShadowWithOffset:(CGSize)offset opacity:(CGFloat)opacity color:(UIColor *)color radius:(CGFloat)radius

Parameters

offset

The offset of the shadow.

opacity

The opacity of the shadow.

color

The color of the shadow.

radius

The radius of the shadow.

Declared In

UIView+TKCategory.h

setShadowWithOffset:opacity:radius:

Set the shadow for the view.

- (void)setShadowWithOffset:(CGSize)offset opacity:(CGFloat)opacity radius:(CGFloat)radius

Parameters

offset

The offset of the shadow.

opacity

The opacity of the shadow.

radius

The radius of the shadow.

Declared In

UIView+TKCategory.h

setShadowWithPath:offset:opacity:color:radius:

Set the shadow for the view.

- (void)setShadowWithPath:(UIBezierPath *)bezierPath offset:(CGSize)offset opacity:(CGFloat)opacity color:(UIColor *)color radius:(CGFloat)radius

Parameters

bezierPath

The shape of the shadow.

offset

The shadow ofsset.

opacity

The opacity of the shadow.

color

The color of the shadow.

radius

The radius of the shadow.

Declared In

UIView+TKCategory.h

snapshotImageAfterScreenUpdates:

Takes a snapshot of the view.

- (UIImage *)snapshotImageAfterScreenUpdates:(BOOL)updates

Parameters

updates

The radius of the shadow.

Return Value

The snapshot image.

Declared In

UIView+TKCategory.h