Skip to content

add line 给View | Cell添加上下左右的线

Notifications You must be signed in to change notification settings

raybon-lee/LDExtendLine

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

项目中经常需要给View, Cell加线,所以基于View封了个扩展

1.支持添加上下左右四个边的线, 功能虽简单,但是很实用!

2.基于VFL 写的自动布局,跟随View的Frame变化而变化!

效果演示

Demo说明

每次白色View高度+20,线的位置都会自动变化!

两张项目中使用的截图!

功能说明:

- (UIView *)addTopLine;                     //leftSpace = rightSapce = 0
- (UIView *)addTopLine:(CGFloat)leftSpace;  //rightSapce = 0
- (UIView *)addTopLine:(CGFloat)leftSpace rightSpace:(CGFloat)rightSpace;

- (UIView *)addLeftLine;                    //topSpace = bottomSpace = 0
- (UIView *)addLeftLine:(CGFloat)topSpace bottomSpace:(CGFloat)bottomSpace;

- (UIView *)addBottomLine;                    //leftSpace = rightSapce = 0
- (UIView *)addBottomLine:(CGFloat)leftSpace; //rightSapce = 0
- (UIView *)addBottomLine:(CGFloat)leftSpace rightSpace:(CGFloat)rightSpace;

- (UIView *)addRightLine;                   //topSpace = bottomSpace = 0
- (UIView *)addRightLine:(CGFloat)topSpace bottomSpace:(CGFloat)bottomSpace;

About

add line 给View | Cell添加上下左右的线

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Objective-C 100.0%