公共组件汇总

公共组件使用方法


Tabs样式-陈翱

<h1>样式展示</h1> <p><img src="https://www.showdoc.cc/server/api/common/visitfile/sign/d6cac17e780da0d97f85ee369f7cbee4?showdoc=.jpg" alt="" /></p> <h1>控件代码参数说明</h1> <pre><code> /// 分页控制器 var pageViewController: LLUIKit_PageViewController /// 头部视图 var tabsView: LLUIKit_TabPageView /// 自定义样式 var tabPageConfig : LLUIKit_TabPageConfig = LLUIKit_TabPageConfig() /// 当前显示的控制器下标 var currentIndex : NSInteger = 0 /// 需要展示的所有标题数组对象 var pageTitles : [String] = [] /// 需要展示的所有控制器数组对象 var pageControllers : [UIViewController] = [] public enum indicateStyle : Int { case fullWidth case titleWidth case customWidth } public class LLUIKit_TabPageConfig: NSObject { /// 字体大小 @objc public var titleFont = UIFont.boldSystemFont(ofSize: 16) /// 选中颜色 @objc public var currentColor = UIColor(red: 105/255, green: 182/255, blue: 245/255, alpha: 1.0) /// 默认颜色 @objc public var defaultColor = UIColor(red: 153/255, green: 153/255, blue: 153/255, alpha: 1.0) /// 视图高度 @objc public var tabHeight: CGFloat = 48.0 /// 边距大小 @objc public var inset: UIEdgeInsets = UIEdgeInsets(top: 10, left: 10, bottom: 10, right: 10) /// Tab宽度 @objc public var tabWidth: CGFloat = 0 ///选中条高度 @objc public var indicateViewHeight: CGFloat = 2.0 ///选中条宽度 选中条样式是自定义才有效 @objc public var indicateViewWidth: CGFloat = 0.0 /// 选中条样式 @objc public var indicateStyle : indicateStyle = .fullWidth /// 背景颜色 @objc public var tabBackgroundColor: UIColor = .white }</code></pre> <h1>代码引用</h1> <p>LLUIKit_TabsViewController.swift</p> <h1>代码使用样例</h1> <pre><code> LLUIKit_TabsViewController *vc = [LLUIKit_TabsViewController new]; vc.pageControllers = @[ [PageChildViewController new], [PageChildViewController new], [PageChildViewController new], [PageChildViewController new]]; vc.pageTitles = @[@"选项名称",@"选项名称",@"选项名称",@"选项名称"];</code></pre>

页面列表

ITEM_HTML