├── 自定义.gif ├── LXKeyBoardTextView.xcodeproj ├── xcuserdata │ └── chenergou.xcuserdatad │ │ ├── xcdebugger │ │ └── Breakpoints_v2.xcbkptlist │ │ └── xcschemes │ │ └── xcschememanagement.plist ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── chenergou.xcuserdatad │ │ └── UserInterfaceState.xcuserstate └── project.pbxproj ├── LXKeyBoardTextView ├── LXKeyboadController.h ├── ViewController.h ├── LXKeyBoardXibController.h ├── AppDelegate.h ├── main.m ├── LXKeyboard │ ├── LXTextView.h │ ├── LXKeyBoard.h │ ├── LXTextView.m │ └── LXKeyBoard.m ├── Category │ ├── NSObject+LXSwizzling.h │ ├── UIColor+Expanded.h │ ├── UILabel+LXLabel.h │ ├── UILabel+LXVerticalStyle.h │ ├── UIView+LX_Frame.h │ ├── LxButton.h │ ├── UILabel+LXLabel.m │ ├── NSObject+LXSwizzling.m │ ├── UILabel+LXVerticalStyle.m │ ├── UIColor+Expanded.m │ ├── LxButton.m │ └── UIView+LX_Frame.m ├── LX.pch ├── LXKeyBoardXibController.m ├── Info.plist ├── Assets.xcassets │ └── AppIcon.appiconset │ │ └── Contents.json ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard ├── AppDelegate.m ├── ViewController.m ├── LXKeyBoardXibController.xib └── LXKeyboadController.m ├── LXKeyBoardTextViewTests ├── Info.plist └── LXKeyBoardTextViewTests.m ├── LXKeyBoardTextViewUITests ├── Info.plist └── LXKeyBoardTextViewUITests.m └── README.md /自定义.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LXManMan/LXKeyBoardTextView/HEAD/自定义.gif -------------------------------------------------------------------------------- /LXKeyBoardTextView.xcodeproj/xcuserdata/chenergou.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | -------------------------------------------------------------------------------- /LXKeyBoardTextView.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /LXKeyBoardTextView.xcodeproj/project.xcworkspace/xcuserdata/chenergou.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LXManMan/LXKeyBoardTextView/HEAD/LXKeyBoardTextView.xcodeproj/project.xcworkspace/xcuserdata/chenergou.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboadController.h: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyboadController.h 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LXKeyboadController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/ViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.h 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ViewController : UIViewController 12 | 13 | 14 | @end 15 | 16 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyBoardXibController.h: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoardXibController.h 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2018/1/17. 6 | // Copyright © 2018年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LXKeyBoardXibController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface AppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | 15 | 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "AppDelegate.h" 11 | 12 | int main(int argc, char * argv[]) { 13 | @autoreleasepool { 14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboard/LXTextView.h: -------------------------------------------------------------------------------- 1 | // 2 | // LXTextView.h 3 | // UITextViewPlaceholderView 4 | // 5 | // Created by idMac2 on 16/1/21. 6 | // Copyright © 2016年 idMac2. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LXTextView : UITextView 12 | /** 占位文字 */ 13 | @property (nonatomic, copy) NSString *placeholder; 14 | /** 占位文字的颜色 */ 15 | @property (nonatomic, strong) UIColor *placeholderColor; 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/NSObject+LXSwizzling.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+LXSwizzling.h 3 | // RunttimeLearn 4 | // 5 | // Created by zhongzhi on 2017/7/27. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | @interface NSObject (LXSwizzling) 12 | + (void)methodSwizzlingWithOriginalSelector:(SEL)originalSelector 13 | bySwizzledSelector:(SEL)swizzledSelector; 14 | @end 15 | -------------------------------------------------------------------------------- /LXKeyBoardTextView.xcodeproj/xcuserdata/chenergou.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | LXKeyBoardTextView.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UIColor+Expanded.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIColor+HexStringToColor.h 3 | // SmartGate 4 | // 5 | // Created by fred on 14-8-19. 6 | // Copyright (c) 2014年 fred. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface UIColor (Expanded) 12 | 13 | +(UIColor *) hexStringToColor: (NSString *) stringToConvert; 14 | +(UIColor *) hexStringToColor: (NSString *) stringToConvert andAlpha:(CGFloat)alpha; 15 | 16 | +(UIColor *)defaultBackGroundColor; 17 | +(UIColor *)commonBackGroundColor; 18 | +(UIColor *)defaultTitleWordColor; 19 | +(UIColor *)defaultContentWordColor; 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UILabel+LXLabel.h: -------------------------------------------------------------------------------- 1 | // 2 | // UILabel+LXLabel.h 3 | // testTryCatch 4 | // 5 | // Created by chuanglong02 on 16/7/15. 6 | // Copyright © 2016年 chuanglong02. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface UILabel (LXLabel) 12 | +(UILabel *)LXLabelWithText:(NSString *)text textColor:(UIColor *)textColor backgroundColor:(UIColor *)backgroundColor frame:(CGRect)frame font:(UIFont *)font textAlignment:(NSTextAlignment)textAlignment; 13 | +(UILabel *)LXLabelWithTextNoFrame:(NSString *)text textColor:(UIColor *)textColor backgroundColor:(UIColor *)backgroundColor font:(UIFont *)font textAlignment:(NSTextAlignment)textAlignment; 14 | @end 15 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboard/LXKeyBoard.h: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoard.h 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | typedef void (^SendBlock) (NSString *text); 12 | @interface LXKeyBoard : UIView 13 | /** 14 | 15 | 需要配置的属性(也可不传) 16 | 17 | */ 18 | @property(nonatomic,assign)BOOL isDisappear;//是否即将消失。 19 | @property(nonatomic,assign)int maxLine;//设置最大行数 20 | @property(nonatomic,assign)CGFloat topOrBottomEdge;//上下间距 21 | @property(nonatomic,strong)UIFont *font;//设置字体大小(决定输入框的初始高度) 22 | 23 | 24 | //设置好属性之后开始布局 25 | -(void)beginUpdateUI; 26 | 27 | 28 | //回调 29 | @property(nonatomic,copy)SendBlock sendBlock; 30 | @end 31 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UILabel+LXVerticalStyle.h: -------------------------------------------------------------------------------- 1 | // 2 | // UILabel+LXVerticalStyle.h 3 | // UIlable字体居上 4 | // 5 | // Created by chenergou on 2017/11/18. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | typedef enum 11 | { 12 | 13 | LXVerticalAlignmentMiddle = 0, // default 14 | LXVerticalAlignmentTop, 15 | LXVerticalAlignmentBottom, 16 | } LXVerticalAlignment; 17 | @interface UILabel (LXVerticalStyle) 18 | @property(nonatomic,assign)LXVerticalAlignment verticalStyle; 19 | /** 20 | * 设置button的titleLabel和imageView的布局样式,及间距 21 | * 22 | * @param style titleLabel和imageView的布局样式 23 | * @param space titleLabel和imageView的间距 24 | */ 25 | //- (void)layoutLabelWithStyle:(LXVerticalAlignment)style; 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /LXKeyBoardTextViewTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /LXKeyBoardTextViewUITests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UIView+LX_Frame.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+LX_Frame.h 3 | // AliPayHome 4 | // 5 | // Created by chenergou on 2017/10/31. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface UIView (LX_Frame) 12 | @property (assign, nonatomic) CGFloat lx_x; 13 | @property (assign, nonatomic) CGFloat lx_y; 14 | @property (assign, nonatomic) CGFloat lx_width; 15 | @property (assign, nonatomic) CGFloat lx_height; 16 | 17 | @property (assign, nonatomic) CGFloat lx_left; 18 | @property (assign, nonatomic) CGFloat lx_top; 19 | @property (assign, nonatomic) CGFloat lx_right; 20 | @property (assign, nonatomic) CGFloat lx_bottom; 21 | 22 | @property (assign, nonatomic) CGSize lx_size; 23 | @property (assign, nonatomic) CGFloat lx_centerX; 24 | @property (assign, nonatomic) CGFloat lx_centerY; 25 | 26 | @end 27 | -------------------------------------------------------------------------------- /LXKeyBoardTextViewTests/LXKeyBoardTextViewTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoardTextViewTests.m 3 | // LXKeyBoardTextViewTests 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LXKeyBoardTextViewTests : XCTestCase 12 | 13 | @end 14 | 15 | @implementation LXKeyBoardTextViewTests 16 | 17 | - (void)setUp { 18 | [super setUp]; 19 | // Put setup code here. This method is called before the invocation of each test method in the class. 20 | } 21 | 22 | - (void)tearDown { 23 | // Put teardown code here. This method is called after the invocation of each test method in the class. 24 | [super tearDown]; 25 | } 26 | 27 | - (void)testExample { 28 | // This is an example of a functional test case. 29 | // Use XCTAssert and related functions to verify your tests produce the correct results. 30 | } 31 | 32 | - (void)testPerformanceExample { 33 | // This is an example of a performance test case. 34 | [self measureBlock:^{ 35 | // Put the code you want to measure the time of here. 36 | }]; 37 | } 38 | 39 | @end 40 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/LxButton.h: -------------------------------------------------------------------------------- 1 | // 2 | // LxButton.h 3 | // ButtonBlock 4 | // 5 | // Created by chuanglong02 on 16/8/4. 6 | // Copyright © 2016年 chuanglong02. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #define Font(f) [UIFont systemFontOfSize:(f)] 12 | #define LXWS(weakSelf) __weak __typeof(&*self)weakSelf = self 13 | typedef void (^ButtonBlock)(UIButton *button); 14 | 15 | @interface LxButton : UIButton 16 | @property(nonatomic,copy)ButtonBlock block; 17 | @property(nonatomic,assign)NSInteger buttonID; 18 | 19 | @property(nonatomic,assign)CGSize enlargeSize; 20 | 21 | -(void)addClickBlock:(ButtonBlock)block; 22 | 23 | +(LxButton *)LXButtonWithTitle:(NSString *)title titleFont:(UIFont *)titleLabelFont Image:(UIImage *)image backgroundImage:(UIImage *)backgroundImage backgroundColor:(UIColor *)backgroundColor titleColor:(UIColor *)titleLabelColor frame:(CGRect)frame; 24 | 25 | +(LxButton *)LXButtonNoFrameWithTitle:(NSString *)title titleFont:(UIFont *)titleLabelFont Image:(UIImage *)image backgroundImage:(UIImage *)backgroundImage backgroundColor:(UIColor *)backgroundColor titleColor:(UIColor *)titleLabelColor; 26 | @end 27 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LX.pch: -------------------------------------------------------------------------------- 1 | // 2 | // LX.pch 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #ifndef LX_pch 10 | #define LX_pch 11 | 12 | // Include any system framework and library headers here that should be included in all compilation units. 13 | // You will also need to set the Prefix Header build setting of one or more of your targets to reference this file. 14 | 15 | 16 | #define Device_Width [[UIScreen mainScreen] bounds].size.width//获取屏幕宽高 17 | #define Device_Height [[UIScreen mainScreen] bounds].size.height 18 | 19 | #define NAVH (MAX(Device_Width, Device_Height) == 812 ? 88 : 64) 20 | #define TABBARH (MAX(Device_Width, Device_Height) == 812 ? 83 : 49) 21 | 22 | #define LXColor(r, g, b) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:1.0] 23 | #define LXRandomColor LXColor(arc4random_uniform(256), arc4random_uniform(256), arc4random_uniform(256)) 24 | 25 | #import "UILabel+LXLabel.h" 26 | #import "UIColor+Expanded.h" 27 | 28 | #import "LxButton.h" 29 | #import "UILabel+LXVerticalStyle.h" 30 | #import "UIView+LX_Frame.h" 31 | #endif /* LX_pch */ 32 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UILabel+LXLabel.m: -------------------------------------------------------------------------------- 1 | // 2 | // UILabel+LXLabel.m 3 | // testTryCatch 4 | // 5 | // Created by chuanglong02 on 16/7/15. 6 | // Copyright © 2016年 chuanglong02. All rights reserved. 7 | // 8 | 9 | #import "UILabel+LXLabel.h" 10 | 11 | @implementation UILabel (LXLabel) 12 | +(UILabel *)LXLabelWithText:(NSString *)text textColor:(UIColor *)textColor backgroundColor:(UIColor *)backgroundColor frame:(CGRect)frame font:(UIFont *)font textAlignment:(NSTextAlignment)textAlignment 13 | { 14 | UILabel *label =[[UILabel alloc]init]; 15 | label.textAlignment = textAlignment; 16 | label.text = text; 17 | label.backgroundColor = backgroundColor; 18 | label.frame= frame; 19 | label.font = font; 20 | label.textColor = textColor; 21 | return label; 22 | } 23 | +(UILabel *)LXLabelWithTextNoFrame:(NSString *)text textColor:(UIColor *)textColor backgroundColor:(UIColor *)backgroundColor font:(UIFont *)font textAlignment:(NSTextAlignment)textAlignment{ 24 | UILabel *label =[[UILabel alloc]init]; 25 | label.textAlignment = textAlignment; 26 | label.text = text; 27 | label.backgroundColor = backgroundColor; 28 | label.font = font; 29 | label.textColor = textColor; 30 | return label; 31 | } 32 | @end 33 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/NSObject+LXSwizzling.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+LXSwizzling.m 3 | // RunttimeLearn 4 | // 5 | // Created by zhongzhi on 2017/7/27. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "NSObject+LXSwizzling.h" 10 | 11 | @implementation NSObject (LXSwizzling) 12 | + (void)methodSwizzlingWithOriginalSelector:(SEL)originalSelector bySwizzledSelector:(SEL)swizzledSelector{ 13 | 14 | Class class = [self class]; 15 | //原有方法 16 | Method originalMethod = class_getInstanceMethod(class, originalSelector); 17 | //替换原有方法的新方法 18 | Method swizzledMethod = class_getInstanceMethod(class, swizzledSelector); 19 | //先尝试給源SEL添加IMP,这里是为了避免源SEL没有实现IMP的情况 20 | BOOL didAddMethod = class_addMethod(class,originalSelector, 21 | method_getImplementation(swizzledMethod), method_getTypeEncoding(swizzledMethod)); 22 | 23 | if (didAddMethod) { 24 | //添加成功:说明源SEL没有实现IMP,将源SEL的IMP替换到交换SEL的IMP 25 | class_replaceMethod(class,swizzledSelector, 26 | method_getImplementation(originalMethod), method_getTypeEncoding(originalMethod)); 27 | } else { 28 | //添加失败:说明源SEL已经有IMP,直接将两个SEL的IMP交换即可 29 | method_exchangeImplementations(originalMethod, swizzledMethod); } } 30 | 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /LXKeyBoardTextViewUITests/LXKeyBoardTextViewUITests.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoardTextViewUITests.m 3 | // LXKeyBoardTextViewUITests 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LXKeyBoardTextViewUITests : XCTestCase 12 | 13 | @end 14 | 15 | @implementation LXKeyBoardTextViewUITests 16 | 17 | - (void)setUp { 18 | [super setUp]; 19 | 20 | // Put setup code here. This method is called before the invocation of each test method in the class. 21 | 22 | // In UI tests it is usually best to stop immediately when a failure occurs. 23 | self.continueAfterFailure = NO; 24 | // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. 25 | [[[XCUIApplication alloc] init] launch]; 26 | 27 | // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. 28 | } 29 | 30 | - (void)tearDown { 31 | // Put teardown code here. This method is called after the invocation of each test method in the class. 32 | [super tearDown]; 33 | } 34 | 35 | - (void)testExample { 36 | // Use recording to get started writing UI tests. 37 | // Use XCTAssert and related functions to verify your tests produce the correct results. 38 | } 39 | 40 | @end 41 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyBoardXibController.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoardXibController.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2018/1/17. 6 | // Copyright © 2018年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "LXKeyBoardXibController.h" 10 | #import "LXKeyBoard.h" 11 | @interface LXKeyBoardXibController () 12 | @property (weak, nonatomic) IBOutlet LXKeyBoard *keyBoard; 13 | 14 | @end 15 | 16 | @implementation LXKeyBoardXibController 17 | -(void)viewWillAppear:(BOOL)animated{ 18 | [super viewWillAppear:animated]; 19 | self.keyBoard.isDisappear = NO; 20 | } 21 | -(void)viewWillDisappear:(BOOL)animated{ 22 | [super viewWillDisappear:animated]; 23 | self.keyBoard.isDisappear = YES; 24 | } 25 | - (void)viewDidLoad { 26 | [super viewDidLoad]; 27 | // Do any additional setup after loading the view from its nib. 28 | 29 | [self.keyBoard beginUpdateUI]; 30 | } 31 | 32 | - (void)didReceiveMemoryWarning { 33 | [super didReceiveMemoryWarning]; 34 | // Dispose of any resources that can be recreated. 35 | } 36 | 37 | /* 38 | #pragma mark - Navigation 39 | 40 | // In a storyboard-based application, you will often want to do a little preparation before navigation 41 | - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { 42 | // Get the new view controller using [segue destinationViewController]. 43 | // Pass the selected object to the new view controller. 44 | } 45 | */ 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UILaunchStoryboardName 24 | LaunchScreen 25 | UIMainStoryboardFile 26 | Main 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # LXKeyBoardTextView 2 | 仿微信多行限制多行输入,一体键盘 3 | ![image](https://github.com/liuxinixn/LXKeyBoardTextView/blob/master/%E8%87%AA%E5%AE%9A%E4%B9%89.gif) 4 | 5 | 支持代码以及XIB. 6 | 介绍: 7 | ``` 8 | typedef void (^SendBlock) (NSString *text); 9 | @interface LXKeyBoard : UIView 10 | /** 11 | 12 | 需要配置的属性(也可不传) 13 | 14 | */ 15 | @property(nonatomic,assign)BOOL isDisappear;//是否即将消失。 16 | @property(nonatomic,assign)int maxLine;//设置最大行数 17 | @property(nonatomic,assign)CGFloat topOrBottomEdge;//上下间距 18 | @property(nonatomic,strong)UIFont *font;//设置字体大小(决定输入框的初始高度) 19 | 20 | 21 | //设置好属性之后开始布局 22 | -(void)beginUpdateUI; 23 | 24 | 25 | //回调 26 | @property(nonatomic,copy)SendBlock sendBlock; 27 | @end 28 | 29 | ``` 30 | 使用方法: 31 | ``` 32 | -(LXKeyBoard *)keyboard{ 33 | if (!_keyboard) { 34 | _keyboard =[[LXKeyBoard alloc]initWithFrame:CGRectZero]; 35 | _keyboard.backgroundColor =[UIColor whiteColor]; 36 | _keyboard.maxLine = 3; 37 | _keyboard.font = Font(18); 38 | _keyboard.topOrBottomEdge = 10; 39 | [_keyboard beginUpdateUI]; 40 | LXWS(weakSelf); 41 | 42 | _keyboard.sendBlock = ^(NSString *text) { 43 | NSLog(@"%@",text); 44 | weakSelf.resultLabel.text = text; 45 | [weakSelf.resultLabel sizeThatFits:CGSizeMake(Device_Width - 40, MAXFLOAT)]; 46 | }; 47 | } 48 | return _keyboard; 49 | } 50 | -(void)viewWillAppear:(BOOL)animated{ 51 | [super viewWillAppear:animated]; 52 | self.keyboard.isDisappear = NO; 53 | } 54 | -(void)viewWillDisappear:(BOOL)animated{ 55 | [super viewWillDisappear:animated]; 56 | self.keyboard.isDisappear = YES; 57 | } 58 | ``` 59 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "20x20", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "20x20", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "29x29", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "29x29", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "40x40", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "40x40", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "size" : "60x60", 36 | "scale" : "2x" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "size" : "60x60", 41 | "scale" : "3x" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "size" : "20x20", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "size" : "20x20", 51 | "scale" : "2x" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "size" : "29x29", 56 | "scale" : "1x" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "size" : "29x29", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "size" : "40x40", 66 | "scale" : "1x" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "size" : "40x40", 71 | "scale" : "2x" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "size" : "76x76", 76 | "scale" : "1x" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "size" : "76x76", 81 | "scale" : "2x" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "size" : "83.5x83.5", 86 | "scale" : "2x" 87 | } 88 | ], 89 | "info" : { 90 | "version" : 1, 91 | "author" : "xcode" 92 | } 93 | } -------------------------------------------------------------------------------- /LXKeyBoardTextView/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UILabel+LXVerticalStyle.m: -------------------------------------------------------------------------------- 1 | // 2 | // UILabel+LXVerticalStyle.m 3 | // UIlable字体居上 4 | // 5 | // Created by chenergou on 2017/11/18. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "UILabel+LXVerticalStyle.h" 10 | #import "NSObject+LXSwizzling.h" 11 | static NSString *style = @"verticalStyle"; 12 | @implementation UILabel (LXVerticalStyle) 13 | +(void)load{ 14 | static dispatch_once_t onceToken; 15 | dispatch_once(&onceToken, ^{ 16 | 17 | Class class = objc_getClass("UILabel"); 18 | [class methodSwizzlingWithOriginalSelector:@selector(textRectForBounds:limitedToNumberOfLines:) bySwizzledSelector:@selector(LXTextRectForBounds:limitedToNumberOfLines:) ]; 19 | 20 | [class methodSwizzlingWithOriginalSelector:@selector(drawTextInRect:) bySwizzledSelector:@selector(LXDrawTextInRect:) ]; 21 | 22 | }); 23 | } 24 | -(void)setVerticalStyle:(LXVerticalAlignment)verticalStyle{ 25 | 26 | objc_setAssociatedObject(self, &style, @(verticalStyle), OBJC_ASSOCIATION_ASSIGN); 27 | [self setNeedsDisplay]; 28 | } 29 | -(LXVerticalAlignment)verticalStyle{ 30 | id value = objc_getAssociatedObject(self, &style); 31 | return [value intValue]; 32 | } 33 | 34 | -(CGRect)LXTextRectForBounds:(CGRect)bounds limitedToNumberOfLines:(NSInteger)numberOfLines{ 35 | CGRect textRect = [self LXTextRectForBounds:bounds limitedToNumberOfLines:numberOfLines]; 36 | switch (self.verticalStyle) { 37 | case LXVerticalAlignmentTop: 38 | textRect.origin.y = bounds.origin.y; 39 | break; 40 | case LXVerticalAlignmentBottom: 41 | textRect.origin.y = bounds.origin.y + bounds.size.height - textRect.size.height; 42 | break; 43 | case LXVerticalAlignmentMiddle: 44 | // Fall through. 45 | default: 46 | textRect.origin.y = bounds.origin.y + (bounds.size.height - textRect.size.height) / 2.0; 47 | } 48 | return textRect; 49 | } 50 | 51 | -(void)LXDrawTextInRect:(CGRect)requestedRect { 52 | CGRect actualRect = [self textRectForBounds:requestedRect limitedToNumberOfLines:self.numberOfLines]; 53 | [self LXDrawTextInRect:actualRect]; 54 | } 55 | 56 | 57 | @end 58 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | 11 | @interface AppDelegate () 12 | 13 | @end 14 | 15 | @implementation AppDelegate 16 | 17 | 18 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 19 | // Override point for customization after application launch. 20 | return YES; 21 | } 22 | 23 | 24 | - (void)applicationWillResignActive:(UIApplication *)application { 25 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 26 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 27 | } 28 | 29 | 30 | - (void)applicationDidEnterBackground:(UIApplication *)application { 31 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 32 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 33 | } 34 | 35 | 36 | - (void)applicationWillEnterForeground:(UIApplication *)application { 37 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 38 | } 39 | 40 | 41 | - (void)applicationDidBecomeActive:(UIApplication *)application { 42 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 43 | } 44 | 45 | 46 | - (void)applicationWillTerminate:(UIApplication *)application { 47 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 48 | } 49 | 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UIColor+Expanded.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIColor+HexStringToColor.m 3 | // SmartGate 4 | // 5 | // Created by fred on 14-8-19. 6 | // Copyright (c) 2014年 fred. All rights reserved. 7 | // 8 | 9 | #import "UIColor+Expanded.h" 10 | 11 | @implementation UIColor (Expanded) 12 | 13 | +(UIColor *) hexStringToColor: (NSString *) stringToConvert 14 | { 15 | return [UIColor hexStringToColor:stringToConvert andAlpha:1.0]; 16 | } 17 | 18 | +(UIColor *) hexStringToColor: (NSString *) stringToConvert andAlpha:(CGFloat)alpha 19 | { 20 | NSString *cString = [[stringToConvert stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] uppercaseString]; 21 | 22 | // String should be 6 or 8 characters 23 | if ([cString length] < 6) return [UIColor clearColor]; 24 | // strip 0X if it appears 25 | if ([cString hasPrefix:@"0X"]) cString = [cString substringFromIndex:2]; 26 | if ([cString hasPrefix:@"#"]) cString = [cString substringFromIndex:1]; 27 | if ([cString length] != 6) return [UIColor clearColor]; 28 | 29 | // Separate into r, g, b substrings 30 | 31 | NSRange range; 32 | range.location = 0; 33 | range.length = 2; 34 | NSString *rString = [cString substringWithRange:range]; 35 | range.location = 2; 36 | NSString *gString = [cString substringWithRange:range]; 37 | range.location = 4; 38 | NSString *bString = [cString substringWithRange:range]; 39 | // Scan values 40 | unsigned int r, g, b; 41 | 42 | if (alpha >1.0 || alpha < 0) { 43 | alpha = 1.0; 44 | } 45 | 46 | [[NSScanner scannerWithString:rString] scanHexInt:&r]; 47 | [[NSScanner scannerWithString:gString] scanHexInt:&g]; 48 | [[NSScanner scannerWithString:bString] scanHexInt:&b]; 49 | 50 | return [UIColor colorWithRed:((float) r / 255.0f) 51 | green:((float) g / 255.0f) 52 | blue:((float) b / 255.0f) 53 | alpha:alpha]; 54 | } 55 | 56 | +(UIColor *)commonBackGroundColor 57 | { 58 | return [self hexStringToColor:@"F2F2F2"]; 59 | } 60 | 61 | +(UIColor *)defaultBackGroundColor 62 | { 63 | return [self hexStringToColor:@"2B569A"]; 64 | } 65 | 66 | +(UIColor *)defaultTitleWordColor 67 | { 68 | return [self hexStringToColor:@"666666"]; 69 | } 70 | 71 | +(UIColor *)defaultContentWordColor 72 | { 73 | return [self hexStringToColor:@"2B569A"]; 74 | } 75 | 76 | @end 77 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/LxButton.m: -------------------------------------------------------------------------------- 1 | // 2 | // LxButton.m 3 | // ButtonBlock 4 | // 5 | // Created by chuanglong02 on 16/8/4. 6 | // Copyright © 2016年 chuanglong02. All rights reserved. 7 | // 8 | 9 | #import "LxButton.h" 10 | 11 | @implementation LxButton 12 | +(LxButton *)LXButtonWithTitle:(NSString *)title titleFont:(UIFont *)titleLabelFont Image:(UIImage *)image backgroundImage:(UIImage *)backgroundImage backgroundColor:(UIColor *)backgroundColor titleColor:(UIColor *)titleLabelColor frame:(CGRect)frame 13 | { 14 | LxButton *button = [LxButton buttonWithType:UIButtonTypeCustom]; 15 | [button setImage:image forState:UIControlStateNormal]; 16 | [button setBackgroundImage:backgroundImage forState:UIControlStateNormal]; 17 | [button setTitle:title forState:UIControlStateNormal]; 18 | [button setTitleColor:titleLabelColor forState:UIControlStateNormal]; 19 | button.backgroundColor = backgroundColor; 20 | button.frame = frame; 21 | button.titleLabel.font = titleLabelFont; 22 | return button; 23 | } 24 | +(LxButton *)LXButtonNoFrameWithTitle:(NSString *)title titleFont:(UIFont *)titleLabelFont Image:(UIImage *)image backgroundImage:(UIImage *)backgroundImage backgroundColor:(UIColor *)backgroundColor titleColor:(UIColor *)titleLabelColor 25 | { 26 | LxButton *button = [LxButton buttonWithType:UIButtonTypeCustom]; 27 | [button setImage:image forState:UIControlStateNormal]; 28 | [button setBackgroundImage:backgroundImage forState:UIControlStateNormal]; 29 | [button setTitle:title forState:UIControlStateNormal]; 30 | [button setTitleColor:titleLabelColor forState:UIControlStateNormal]; 31 | button.backgroundColor = backgroundColor; 32 | button.titleLabel.font = titleLabelFont; 33 | return button; 34 | } 35 | 36 | -(void)addClickBlock:(ButtonBlock)block 37 | { 38 | _block = block; 39 | [self addTarget:self action:@selector(buttonAction:) forControlEvents:UIControlEventTouchUpInside]; 40 | } 41 | -(void)buttonAction:(UIButton *)button 42 | { 43 | _block(button); 44 | } 45 | -(void)setButtonID:(NSInteger)buttonID 46 | { 47 | _buttonID = buttonID; 48 | self.tag = buttonID; 49 | } 50 | 51 | -(void)setEnlargeSize:(CGSize)enlargeSize{ 52 | _enlargeSize = enlargeSize; 53 | } 54 | -(BOOL)pointInside:(CGPoint)point withEvent:(UIEvent*)event 55 | { 56 | CGRect bounds = self.bounds; 57 | //扩大原热区直径至26,可以暴露个接口,用来设置需要扩大的半径。 58 | 59 | CGFloat widthDelta = MAX(self.enlargeSize.width , 0); 60 | CGFloat heightDelta = MAX(self.enlargeSize.height, 0); 61 | bounds = CGRectInset(bounds, -0.5 * widthDelta, -0.5 * heightDelta); 62 | return CGRectContainsPoint(bounds, point); 63 | } 64 | 65 | @end 66 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/ViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "ViewController.h" 10 | #import "LXKeyboadController.h" 11 | #import "LXKeyBoardXibController.h" 12 | @interface ViewController () 13 | @property(nonatomic,strong)UITableView *tabelview; 14 | @end 15 | 16 | @implementation ViewController 17 | 18 | - (void)viewDidLoad { 19 | [super viewDidLoad]; 20 | // Do any additional setup after loading the view, typically from a nib. 21 | self.title = @"自定义限制多行输入框"; 22 | 23 | [self setUp]; 24 | } 25 | 26 | 27 | -(void)setUp{ 28 | [self.view addSubview:self.tableview]; 29 | 30 | } 31 | -(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ 32 | return 2; 33 | } 34 | -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{ 35 | UITableViewCell *cell =[tableView dequeueReusableCellWithIdentifier:@"cell" forIndexPath:indexPath]; 36 | if (!cell) { 37 | cell =[[UITableViewCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"cell"]; 38 | } 39 | 40 | 41 | if (indexPath.row == 0) { 42 | cell.textLabel.text = @"代码初始化键盘"; 43 | }else{ 44 | cell.textLabel.text = @"xib初始化键盘"; 45 | 46 | } 47 | return cell; 48 | } 49 | -(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{ 50 | [tableView deselectRowAtIndexPath:indexPath animated:YES]; 51 | 52 | 53 | if (indexPath.row == 0) { 54 | LXKeyboadController *changeVc =[[LXKeyboadController alloc]init]; 55 | [self.navigationController pushViewController:changeVc animated:YES]; 56 | }else{ 57 | LXKeyBoardXibController *changeVc =[[LXKeyBoardXibController alloc]init]; 58 | [self.navigationController pushViewController:changeVc animated:YES]; 59 | 60 | } 61 | 62 | } 63 | -(UITableView *)tableview{ 64 | 65 | if (!_tabelview) { 66 | _tabelview =[[UITableView alloc]initWithFrame:self.view.bounds style:UITableViewStylePlain]; 67 | _tabelview.delegate = self; 68 | _tabelview.dataSource = self; 69 | 70 | _tabelview.showsVerticalScrollIndicator = NO; 71 | _tabelview.showsHorizontalScrollIndicator = NO; 72 | _tabelview.tableFooterView = [UIView new]; 73 | 74 | [_tabelview registerClass:[UITableViewCell class] forCellReuseIdentifier:@"cell"]; 75 | 76 | } 77 | return _tabelview; 78 | } 79 | 80 | 81 | @end 82 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyBoardXibController.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboadController.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyboadController.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "LXKeyboadController.h" 10 | #import "LXKeyBoard.h" 11 | 12 | @interface LXKeyboadController () 13 | 14 | @property(nonatomic,strong)LXKeyBoard *keyboard; 15 | @property(nonatomic,strong)UILabel *resultLabel; 16 | 17 | @end 18 | 19 | @implementation LXKeyboadController 20 | 21 | - (void)viewDidLoad { 22 | [super viewDidLoad]; 23 | // Do any additional setup after loading the view. 24 | self.view.backgroundColor =[UIColor whiteColor]; 25 | self.title = @"控制多行输入键盘"; 26 | 27 | [self setup]; 28 | 29 | if (@available(iOS 11.0, *)) { 30 | 31 | } else { 32 | #pragma clang diagnostic push 33 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 34 | // 这部分使用到的过期api 35 | self.automaticallyAdjustsScrollViewInsets = NO; 36 | #pragma clang diagnostic pop 37 | } 38 | 39 | 40 | } 41 | -(void)viewWillAppear:(BOOL)animated{ 42 | [super viewWillAppear:animated]; 43 | self.keyboard.isDisappear = NO; 44 | } 45 | -(void)viewWillDisappear:(BOOL)animated{ 46 | [super viewWillDisappear:animated]; 47 | self.keyboard.isDisappear = YES; 48 | } 49 | -(void)setup{ 50 | [self.view addSubview:self.keyboard]; 51 | [self.view addSubview:self.resultLabel]; 52 | } 53 | -(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{ 54 | [self.view endEditing:YES]; 55 | } 56 | -(LXKeyBoard *)keyboard{ 57 | if (!_keyboard) { 58 | _keyboard =[[LXKeyBoard alloc]initWithFrame:CGRectZero]; 59 | _keyboard.backgroundColor =[UIColor whiteColor]; 60 | _keyboard.maxLine = 3; 61 | _keyboard.font = Font(18); 62 | _keyboard.topOrBottomEdge = 10; 63 | [_keyboard beginUpdateUI]; 64 | LXWS(weakSelf); 65 | 66 | _keyboard.sendBlock = ^(NSString *text) { 67 | NSLog(@"%@",text); 68 | weakSelf.resultLabel.text = text; 69 | [weakSelf.resultLabel sizeThatFits:CGSizeMake(Device_Width - 40, MAXFLOAT)]; 70 | }; 71 | } 72 | return _keyboard; 73 | } 74 | -(UILabel *)resultLabel{ 75 | if (!_resultLabel) { 76 | _resultLabel =[UILabel LXLabelWithText:@"" textColor:[UIColor hexStringToColor:@"3c3c3c"] backgroundColor:[UIColor lightGrayColor] frame:CGRectMake(20, 64, Device_Width - 40, 200) font:Font(15) textAlignment:NSTextAlignmentLeft]; 77 | _resultLabel.numberOfLines = 0; 78 | _resultLabel.verticalStyle = LXVerticalAlignmentTop; 79 | } 80 | return _resultLabel; 81 | } 82 | @end 83 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboard/LXTextView.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXTextView.m 3 | // UITextViewPlaceholderView 4 | // 5 | // Created by idMac2 on 16/1/21. 6 | // Copyright © 2016年 idMac2. All rights reserved. 7 | // 8 | 9 | #import "LXTextView.h" 10 | //通知中心 11 | #define LXNotificationCenter [NSNotificationCenter defaultCenter] 12 | @implementation LXTextView 13 | -(void)awakeFromNib{ 14 | [super awakeFromNib]; 15 | // 通知 16 | // 当UITextView的文字发生改变时,UITextView自己会发出一个UITextViewTextDidChangeNotification通知 17 | [LXNotificationCenter addObserver:self selector:@selector(textDidChange) name:UITextViewTextDidChangeNotification object:self]; 18 | } 19 | - (id)initWithFrame:(CGRect)frame 20 | { 21 | self = [super initWithFrame:frame]; 22 | if (self) { 23 | // 不要设置自己的delegate为自己 24 | // self.delegate = self; 25 | 26 | if (@available(iOS 11.0, *)) { 27 | self.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever; 28 | } 29 | // 通知 30 | // 当UITextView的文字发生改变时,UITextView自己会发出一个UITextViewTextDidChangeNotification通知 31 | [LXNotificationCenter addObserver:self selector:@selector(textDidChange) name:UITextViewTextDidChangeNotification object:self]; 32 | 33 | } 34 | return self; 35 | } 36 | 37 | 38 | - (void)dealloc 39 | { 40 | [LXNotificationCenter removeObserver:self]; 41 | } 42 | 43 | /** 44 | * 监听文字改变 45 | */ 46 | - (void)textDidChange 47 | { 48 | // 重绘(重新调用) 49 | [self setNeedsDisplay]; 50 | } 51 | 52 | - (void)setPlaceholder:(NSString *)placeholder 53 | { 54 | _placeholder = [placeholder copy]; 55 | 56 | [self setNeedsDisplay]; 57 | } 58 | 59 | - (void)setPlaceholderColor:(UIColor *)placeholderColor 60 | { 61 | _placeholderColor = placeholderColor; 62 | 63 | [self setNeedsDisplay]; 64 | } 65 | 66 | - (void)setText:(NSString *)text 67 | { 68 | [super setText:text]; 69 | 70 | // setNeedsDisplay会在下一个消息循环时刻,调用drawRect: 71 | [self setNeedsDisplay]; 72 | } 73 | 74 | - (void)setFont:(UIFont *)font 75 | { 76 | [super setFont:font]; 77 | 78 | [self setNeedsDisplay]; 79 | } 80 | 81 | - (void)drawRect:(CGRect)rect 82 | { 83 | // [HWRandomColor set]; 84 | // UIRectFill(CGRectMake(20, 20, 30, 30)); 85 | // 如果有输入文字,就直接返回,不画占位文字 86 | 87 | 88 | if (self.hasText) return; 89 | 90 | // 文字属性 91 | NSMutableDictionary *attrs = [NSMutableDictionary dictionary]; 92 | attrs[NSFontAttributeName] = self.font; 93 | attrs[NSForegroundColorAttributeName] = self.placeholderColor?self.placeholderColor:[UIColor grayColor]; 94 | // 画文字 95 | // [self.placeholder drawAtPoint:CGPointMake(5, 8) withAttributes:attrs]; 96 | CGFloat x = 0; 97 | CGFloat w = rect.size.width - 2 * x; 98 | CGFloat y = 0; 99 | CGFloat h = rect.size.height - 2 * y; 100 | CGRect placeholderRect = CGRectMake(x, y, w, h); 101 | [self.placeholder drawInRect:placeholderRect withAttributes:attrs]; 102 | 103 | 104 | 105 | 106 | } 107 | 108 | @end 109 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Category/UIView+LX_Frame.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+LX_Frame.m 3 | // AliPayHome 4 | // 5 | // Created by chenergou on 2017/10/31. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "UIView+LX_Frame.h" 10 | 11 | @implementation UIView (LX_Frame) 12 | -(void)setLx_x:(CGFloat)lx_x{ 13 | CGFloat y = self.frame.origin.y; 14 | CGFloat width = self.frame.size.width; 15 | CGFloat height = self.frame.size.height; 16 | self.frame = CGRectMake(lx_x, y, width, height); 17 | } 18 | -(CGFloat)lx_x{ 19 | return self.frame.origin.x; 20 | } 21 | -(void)setLx_y:(CGFloat)lx_y{ 22 | CGFloat x = self.frame.origin.x; 23 | CGFloat width = self.frame.size.width; 24 | CGFloat height = self.frame.size.height; 25 | self.frame = CGRectMake(x, lx_y, width, height); 26 | } 27 | -(CGFloat)lx_y{ 28 | return self.frame.origin.y; 29 | } 30 | -(void)setLx_width:(CGFloat)lx_width{ 31 | CGRect frame = self.frame; 32 | frame.size.width = lx_width; 33 | self.frame = frame; 34 | } 35 | -(CGFloat)lx_width{ 36 | return self.frame.size.width; 37 | } 38 | 39 | -(void)setLx_height:(CGFloat)lx_height{ 40 | CGRect frame = self.frame; 41 | frame.size.height = lx_height; 42 | self.frame = frame; 43 | } 44 | 45 | -(CGFloat)lx_height{ 46 | return self.frame.size.height; 47 | } 48 | 49 | 50 | -(void)setLx_left:(CGFloat)lx_left{ 51 | CGFloat y = self.frame.origin.y; 52 | CGFloat width = self.frame.size.width; 53 | CGFloat height = self.frame.size.height; 54 | self.frame = CGRectMake(lx_left, y, width, height); 55 | } 56 | -(CGFloat)lx_left{ 57 | return self.frame.origin.x; 58 | } 59 | 60 | 61 | -(void)setLx_top:(CGFloat)lx_top{ 62 | CGFloat x = self.frame.origin.x; 63 | CGFloat width = self.frame.size.width; 64 | CGFloat height = self.frame.size.height; 65 | self.frame = CGRectMake(x, lx_top, width, height); 66 | } 67 | -(CGFloat)lx_top{ 68 | return self.frame.origin.y; 69 | } 70 | -(void)setLx_right:(CGFloat)lx_right{ 71 | CGRect frame = self.frame; 72 | frame.origin.x = lx_right - frame.size.width; 73 | self.frame = frame; 74 | } 75 | -(CGFloat)lx_right{ 76 | return self.frame.origin.x + self.frame.size.width; 77 | } 78 | -(void)setLx_bottom:(CGFloat)lx_bottom{ 79 | CGRect frame = self.frame; 80 | frame.origin.y = lx_bottom - frame.size.height; 81 | self.frame = frame; 82 | } 83 | -(CGFloat)lx_bottom{ 84 | return self.frame.origin.y + self.frame.size.height; 85 | } 86 | 87 | -(CGSize)lx_size { 88 | return self.frame.size; 89 | } 90 | 91 | - (void)setLx_size:(CGSize)lx_size { 92 | CGRect frame = self.frame; 93 | frame.size = lx_size; 94 | self.frame = frame; 95 | } 96 | -(CGFloat)lx_centerX{ 97 | return self.center.x; 98 | } 99 | -(void)setLx_centerX:(CGFloat)lx_centerX{ 100 | 101 | self.center = CGPointMake(lx_centerX, self.center.y); 102 | 103 | } 104 | -(CGFloat)lx_centerY{ 105 | return self.center.y; 106 | 107 | } 108 | -(void)setLx_centerY:(CGFloat)lx_centerY{ 109 | self.center = CGPointMake(self.center.x, lx_centerY); 110 | } 111 | @end 112 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /LXKeyBoardTextView/LXKeyboard/LXKeyBoard.m: -------------------------------------------------------------------------------- 1 | // 2 | // LXKeyBoard.m 3 | // LXKeyBoardTextView 4 | // 5 | // Created by chenergou on 2017/12/21. 6 | // Copyright © 2017年 漫漫. All rights reserved. 7 | // 8 | 9 | #import "LXKeyBoard.h" 10 | #import "LXTextView.h" 11 | @interface LXKeyBoard() 12 | @property(nonatomic,strong)LXTextView *textView; 13 | @property(nonatomic,strong)LxButton *sendBtn; 14 | @property(nonatomic,strong)UIView *line; 15 | @property(nonatomic,assign)CGFloat btnH; 16 | @end 17 | @implementation LXKeyBoard 18 | { 19 | CGFloat keyboardY; 20 | 21 | } 22 | 23 | -(void)awakeFromNib{ 24 | [super awakeFromNib]; 25 | 26 | [[NSNotificationCenter defaultCenter]removeObserver:self]; 27 | self.layer.borderWidth = 1; 28 | self.layer.borderColor =[UIColor hexStringToColor:@"A5A5A5"].CGColor; 29 | 30 | 31 | [[NSNotificationCenter defaultCenter]addObserver:self selector:@selector(keyboardWillChangeFrame:) name:UIKeyboardWillChangeFrameNotification object:nil]; 32 | [[NSNotificationCenter defaultCenter]addObserver:self selector:@selector(keyboardDidChangeFrame:) name:UIKeyboardDidChangeFrameNotification object:nil];; 33 | 34 | //设置默认属性 35 | self.topOrBottomEdge = 8; 36 | self.font = Font(18); 37 | self.maxLine = 3; 38 | } 39 | -(instancetype)initWithFrame:(CGRect)frame{ 40 | self = [super initWithFrame:frame]; 41 | 42 | 43 | if (self) { 44 | self.layer.borderWidth = 1; 45 | self.layer.borderColor =[UIColor hexStringToColor:@"A5A5A5"].CGColor; 46 | 47 | 48 | [[NSNotificationCenter defaultCenter]addObserver:self selector:@selector(keyboardWillChangeFrame:) name:UIKeyboardWillChangeFrameNotification object:nil]; 49 | [[NSNotificationCenter defaultCenter]addObserver:self selector:@selector(keyboardDidChangeFrame:) name:UIKeyboardDidChangeFrameNotification object:nil]; 50 | //设置默认属性 51 | self.topOrBottomEdge = 8; 52 | self.font = Font(18); 53 | self.maxLine = 3; 54 | 55 | } 56 | return self; 57 | } 58 | -(void)dealloc{ 59 | [[NSNotificationCenter defaultCenter]removeObserver:self]; 60 | NSLog(@"%@",self.class); 61 | } 62 | 63 | 64 | -(void)beginUpdateUI{ 65 | 66 | //初始化高度 textView的lineHeight + 2 * 上下间距 67 | CGFloat orignTextH = ceil (self.font.lineHeight) + 2 * self.topOrBottomEdge; 68 | 69 | 70 | self.frame = CGRectMake(0, Device_Height - orignTextH, Device_Width, orignTextH); 71 | 72 | 73 | self.btnH = self.lx_height; 74 | 75 | 76 | [self setup]; 77 | 78 | 79 | } 80 | -(void)setup{ 81 | [self addSubview:self.textView]; 82 | [self addSubview:self.sendBtn]; 83 | [self.sendBtn addSubview:self.line]; 84 | 85 | LXWS(weakSelf); 86 | [self.sendBtn addClickBlock:^(UIButton *button) { 87 | 88 | if (weakSelf.sendBlock) { 89 | weakSelf.sendBlock(weakSelf.textView.text); 90 | } 91 | }]; 92 | } 93 | -(void)textViewDidChange:(UITextView *)textView{ 94 | 95 | CGFloat contentSizeH = self.textView.contentSize.height; 96 | CGFloat lineH = self.textView.font.lineHeight; 97 | 98 | CGFloat maxHeight = ceil(lineH * self.maxLine + textView.textContainerInset.top + textView.textContainerInset.bottom); 99 | if (contentSizeH <= maxHeight) { 100 | self.textView.lx_height = contentSizeH; 101 | }else{ 102 | self.textView.lx_height = maxHeight; 103 | } 104 | 105 | [textView scrollRangeToVisible:NSMakeRange(textView.selectedRange.location, 1)]; 106 | 107 | 108 | CGFloat totalH = ceil(self.textView.lx_height) + 2 * self.topOrBottomEdge; 109 | self.frame = CGRectMake(0, keyboardY - totalH, self.lx_width, totalH); 110 | 111 | 112 | self.sendBtn.lx_height = totalH; 113 | self.line.lx_height = totalH - 10; 114 | 115 | } 116 | -(void)keyboardWillChangeFrame:(NSNotification *)notification{ 117 | 118 | NSDictionary *userInfo = notification.userInfo; 119 | // 动画的持续时间 120 | double duration = [userInfo[UIKeyboardAnimationDurationUserInfoKey] doubleValue]; 121 | 122 | // 键盘的frame 123 | CGRect keyboardF = [userInfo[UIKeyboardFrameEndUserInfoKey] CGRectValue]; 124 | // NSLog(@"%@",NSStringFromCGRect(keyboardF)); 125 | keyboardY = keyboardF.origin.y; 126 | 127 | if (!_isDisappear) { 128 | 129 | [self dealKeyBoardWithKeyboardF:keyboardY duration:duration]; 130 | 131 | } 132 | 133 | 134 | } 135 | 136 | -(void)keyboardDidChangeFrame:(NSNotification *)notification{ 137 | 138 | NSDictionary *userInfo = notification.userInfo; 139 | // 动画的持续时间 140 | double duration = [userInfo[UIKeyboardAnimationDurationUserInfoKey] doubleValue]; 141 | // 键盘的frame 142 | CGRect keyboardF = [userInfo[UIKeyboardFrameEndUserInfoKey] CGRectValue]; 143 | // NSLog(@"%@",NSStringFromCGRect(keyboardF)); 144 | 145 | keyboardY = keyboardF.origin.y; 146 | // // 工具条的Y值 == 键盘的Y值 - 工具条的高度 147 | if (_isDisappear) { 148 | [self dealKeyBoardWithKeyboardF:keyboardY duration:duration]; 149 | } 150 | 151 | } 152 | #pragma mark---处理高度--- 153 | -(void)dealKeyBoardWithKeyboardF:(CGFloat)keyboardY duration:(CGFloat)duration { 154 | 155 | if (!_isDisappear) { 156 | [UIView animateWithDuration:duration animations:^{ 157 | // 工具条的Y值 == 键盘的Y值 - 工具条的高度 158 | 159 | if (keyboardY > Device_Height) { 160 | self.lx_y = Device_Height- self.lx_height; 161 | }else 162 | { 163 | self.lx_y = keyboardY - self.lx_height; 164 | } 165 | }]; 166 | }else{ 167 | if (keyboardY > Device_Height) { 168 | self.lx_y = Device_Height- self.lx_height; 169 | }else 170 | { 171 | self.lx_y = keyboardY - self.lx_height; 172 | } 173 | } 174 | 175 | 176 | } 177 | #pragma mark---setter--- 178 | -(void)setTopOrBottomEdge:(CGFloat)topOrBottomEdge{ 179 | _topOrBottomEdge = topOrBottomEdge; 180 | 181 | if (!_topOrBottomEdge) { 182 | topOrBottomEdge = 10; 183 | } 184 | } 185 | -(void)setMaxLine:(int)maxLine{ 186 | _maxLine = maxLine; 187 | 188 | if (!_maxLine || _maxLine <=0) { 189 | _maxLine = 3; 190 | } 191 | 192 | } 193 | -(void)setFont:(UIFont *)font{ 194 | _font = font; 195 | if (!font) { 196 | _font = Font(16); 197 | } 198 | 199 | 200 | } 201 | -(void)setIsDisappear:(BOOL)isDisappear{ 202 | _isDisappear = isDisappear; 203 | } 204 | 205 | 206 | #pragma mark---getter--- 207 | -(LXTextView *)textView{ 208 | if (!_textView) { 209 | _textView =[[LXTextView alloc]initWithFrame:CGRectMake(0, self.topOrBottomEdge, self.lx_width - 60, ceil(self.font.lineHeight))]; 210 | _textView.font = self.font; 211 | _textView.delegate = self; 212 | _textView.layoutManager.allowsNonContiguousLayout = NO; 213 | _textView.enablesReturnKeyAutomatically = YES; 214 | _textView.scrollsToTop = NO; 215 | _textView.textContainerInset = UIEdgeInsetsZero; //关闭textview的默认间距属性 216 | _textView.textContainer.lineFragmentPadding = 0; 217 | _textView.placeholder = @"发表评论:"; 218 | } 219 | return _textView; 220 | } 221 | -(LxButton *)sendBtn{ 222 | if (!_sendBtn) { 223 | _sendBtn =[LxButton LXButtonWithTitle:@"发送" titleFont:Font(14) Image:nil backgroundImage:nil backgroundColor:[UIColor whiteColor] titleColor:[UIColor hexStringToColor:@"3c3c3c"] frame:CGRectMake(self.lx_width - 60, 0, 60, self.btnH)]; 224 | } 225 | return _sendBtn; 226 | } 227 | -(UIView *)line{ 228 | if (!_line) { 229 | _line =[[UIView alloc]initWithFrame:CGRectMake(0, 5, 1, self.btnH - 10)]; 230 | _line.backgroundColor =[UIColor hexStringToColor:@"c2c2c2"]; 231 | } 232 | return _line; 233 | } 234 | @end 235 | -------------------------------------------------------------------------------- /LXKeyBoardTextView.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 48; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | F31B6EB31FECBA5B0073C5EE /* UILabel+LXVerticalStyle.m in Sources */ = {isa = PBXBuildFile; fileRef = F31B6EB21FECBA5B0073C5EE /* UILabel+LXVerticalStyle.m */; }; 11 | F31B6EB61FECBA8F0073C5EE /* NSObject+LXSwizzling.m in Sources */ = {isa = PBXBuildFile; fileRef = F31B6EB41FECBA8F0073C5EE /* NSObject+LXSwizzling.m */; }; 12 | F3A118881FEB4B4F00B91E40 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118871FEB4B4F00B91E40 /* AppDelegate.m */; }; 13 | F3A1188B1FEB4B4F00B91E40 /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A1188A1FEB4B4F00B91E40 /* ViewController.m */; }; 14 | F3A1188E1FEB4B4F00B91E40 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F3A1188C1FEB4B4F00B91E40 /* Main.storyboard */; }; 15 | F3A118901FEB4B4F00B91E40 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = F3A1188F1FEB4B4F00B91E40 /* Assets.xcassets */; }; 16 | F3A118931FEB4B4F00B91E40 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F3A118911FEB4B4F00B91E40 /* LaunchScreen.storyboard */; }; 17 | F3A118961FEB4B4F00B91E40 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118951FEB4B4F00B91E40 /* main.m */; }; 18 | F3A118A01FEB4B5000B91E40 /* LXKeyBoardTextViewTests.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A1189F1FEB4B5000B91E40 /* LXKeyBoardTextViewTests.m */; }; 19 | F3A118AB1FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118AA1FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.m */; }; 20 | F3A118C11FEB4B8700B91E40 /* LxButton.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118BA1FEB4B8700B91E40 /* LxButton.m */; }; 21 | F3A118C21FEB4B8700B91E40 /* UIColor+Expanded.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118BC1FEB4B8700B91E40 /* UIColor+Expanded.m */; }; 22 | F3A118C31FEB4B8700B91E40 /* UILabel+LXLabel.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118BE1FEB4B8700B91E40 /* UILabel+LXLabel.m */; }; 23 | F3A118C41FEB4B8700B91E40 /* UIView+LX_Frame.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118C01FEB4B8700B91E40 /* UIView+LX_Frame.m */; }; 24 | F3A118C81FEB4C6E00B91E40 /* LXKeyboadController.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118C71FEB4C6E00B91E40 /* LXKeyboadController.m */; }; 25 | F3A118CF1FEB4E8B00B91E40 /* LXKeyBoard.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118CE1FEB4E8B00B91E40 /* LXKeyBoard.m */; }; 26 | F3A118D21FEB4F7B00B91E40 /* LXTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = F3A118D11FEB4F7B00B91E40 /* LXTextView.m */; }; 27 | F3E9B149200EF04600120BD2 /* LXKeyBoardXibController.m in Sources */ = {isa = PBXBuildFile; fileRef = F3E9B147200EF04600120BD2 /* LXKeyBoardXibController.m */; }; 28 | F3E9B14A200EF04600120BD2 /* LXKeyBoardXibController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F3E9B148200EF04600120BD2 /* LXKeyBoardXibController.xib */; }; 29 | /* End PBXBuildFile section */ 30 | 31 | /* Begin PBXContainerItemProxy section */ 32 | F3A1189C1FEB4B4F00B91E40 /* PBXContainerItemProxy */ = { 33 | isa = PBXContainerItemProxy; 34 | containerPortal = F3A1187B1FEB4B4F00B91E40 /* Project object */; 35 | proxyType = 1; 36 | remoteGlobalIDString = F3A118821FEB4B4F00B91E40; 37 | remoteInfo = LXKeyBoardTextView; 38 | }; 39 | F3A118A71FEB4B5000B91E40 /* PBXContainerItemProxy */ = { 40 | isa = PBXContainerItemProxy; 41 | containerPortal = F3A1187B1FEB4B4F00B91E40 /* Project object */; 42 | proxyType = 1; 43 | remoteGlobalIDString = F3A118821FEB4B4F00B91E40; 44 | remoteInfo = LXKeyBoardTextView; 45 | }; 46 | /* End PBXContainerItemProxy section */ 47 | 48 | /* Begin PBXFileReference section */ 49 | F31B6EB11FECBA5B0073C5EE /* UILabel+LXVerticalStyle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UILabel+LXVerticalStyle.h"; sourceTree = ""; }; 50 | F31B6EB21FECBA5B0073C5EE /* UILabel+LXVerticalStyle.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UILabel+LXVerticalStyle.m"; sourceTree = ""; }; 51 | F31B6EB41FECBA8F0073C5EE /* NSObject+LXSwizzling.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+LXSwizzling.m"; sourceTree = ""; }; 52 | F31B6EB51FECBA8F0073C5EE /* NSObject+LXSwizzling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+LXSwizzling.h"; sourceTree = ""; }; 53 | F3A118831FEB4B4F00B91E40 /* LXKeyBoardTextView.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = LXKeyBoardTextView.app; sourceTree = BUILT_PRODUCTS_DIR; }; 54 | F3A118861FEB4B4F00B91E40 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 55 | F3A118871FEB4B4F00B91E40 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 56 | F3A118891FEB4B4F00B91E40 /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; 57 | F3A1188A1FEB4B4F00B91E40 /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; 58 | F3A1188D1FEB4B4F00B91E40 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 59 | F3A1188F1FEB4B4F00B91E40 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 60 | F3A118921FEB4B4F00B91E40 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 61 | F3A118941FEB4B4F00B91E40 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 62 | F3A118951FEB4B4F00B91E40 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 63 | F3A1189B1FEB4B4F00B91E40 /* LXKeyBoardTextViewTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = LXKeyBoardTextViewTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 64 | F3A1189F1FEB4B5000B91E40 /* LXKeyBoardTextViewTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LXKeyBoardTextViewTests.m; sourceTree = ""; }; 65 | F3A118A11FEB4B5000B91E40 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 66 | F3A118A61FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = LXKeyBoardTextViewUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 67 | F3A118AA1FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LXKeyBoardTextViewUITests.m; sourceTree = ""; }; 68 | F3A118AC1FEB4B5000B91E40 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 69 | F3A118B91FEB4B8700B91E40 /* LxButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LxButton.h; sourceTree = ""; }; 70 | F3A118BA1FEB4B8700B91E40 /* LxButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LxButton.m; sourceTree = ""; }; 71 | F3A118BB1FEB4B8700B91E40 /* UIColor+Expanded.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIColor+Expanded.h"; sourceTree = ""; }; 72 | F3A118BC1FEB4B8700B91E40 /* UIColor+Expanded.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIColor+Expanded.m"; sourceTree = ""; }; 73 | F3A118BD1FEB4B8700B91E40 /* UILabel+LXLabel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UILabel+LXLabel.h"; sourceTree = ""; }; 74 | F3A118BE1FEB4B8700B91E40 /* UILabel+LXLabel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UILabel+LXLabel.m"; sourceTree = ""; }; 75 | F3A118BF1FEB4B8700B91E40 /* UIView+LX_Frame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+LX_Frame.h"; sourceTree = ""; }; 76 | F3A118C01FEB4B8700B91E40 /* UIView+LX_Frame.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIView+LX_Frame.m"; sourceTree = ""; }; 77 | F3A118C51FEB4B9800B91E40 /* LX.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LX.pch; sourceTree = ""; }; 78 | F3A118C61FEB4C6E00B91E40 /* LXKeyboadController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LXKeyboadController.h; sourceTree = ""; }; 79 | F3A118C71FEB4C6E00B91E40 /* LXKeyboadController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LXKeyboadController.m; sourceTree = ""; }; 80 | F3A118CD1FEB4E8B00B91E40 /* LXKeyBoard.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LXKeyBoard.h; sourceTree = ""; }; 81 | F3A118CE1FEB4E8B00B91E40 /* LXKeyBoard.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LXKeyBoard.m; sourceTree = ""; }; 82 | F3A118D01FEB4F7B00B91E40 /* LXTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LXTextView.h; sourceTree = ""; }; 83 | F3A118D11FEB4F7B00B91E40 /* LXTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LXTextView.m; sourceTree = ""; }; 84 | F3E9B146200EF04600120BD2 /* LXKeyBoardXibController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LXKeyBoardXibController.h; sourceTree = ""; }; 85 | F3E9B147200EF04600120BD2 /* LXKeyBoardXibController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LXKeyBoardXibController.m; sourceTree = ""; }; 86 | F3E9B148200EF04600120BD2 /* LXKeyBoardXibController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = LXKeyBoardXibController.xib; sourceTree = ""; }; 87 | /* End PBXFileReference section */ 88 | 89 | /* Begin PBXFrameworksBuildPhase section */ 90 | F3A118801FEB4B4F00B91E40 /* Frameworks */ = { 91 | isa = PBXFrameworksBuildPhase; 92 | buildActionMask = 2147483647; 93 | files = ( 94 | ); 95 | runOnlyForDeploymentPostprocessing = 0; 96 | }; 97 | F3A118981FEB4B4F00B91E40 /* Frameworks */ = { 98 | isa = PBXFrameworksBuildPhase; 99 | buildActionMask = 2147483647; 100 | files = ( 101 | ); 102 | runOnlyForDeploymentPostprocessing = 0; 103 | }; 104 | F3A118A31FEB4B5000B91E40 /* Frameworks */ = { 105 | isa = PBXFrameworksBuildPhase; 106 | buildActionMask = 2147483647; 107 | files = ( 108 | ); 109 | runOnlyForDeploymentPostprocessing = 0; 110 | }; 111 | /* End PBXFrameworksBuildPhase section */ 112 | 113 | /* Begin PBXGroup section */ 114 | F3A1187A1FEB4B4F00B91E40 = { 115 | isa = PBXGroup; 116 | children = ( 117 | F3A118851FEB4B4F00B91E40 /* LXKeyBoardTextView */, 118 | F3A1189E1FEB4B5000B91E40 /* LXKeyBoardTextViewTests */, 119 | F3A118A91FEB4B5000B91E40 /* LXKeyBoardTextViewUITests */, 120 | F3A118841FEB4B4F00B91E40 /* Products */, 121 | ); 122 | sourceTree = ""; 123 | }; 124 | F3A118841FEB4B4F00B91E40 /* Products */ = { 125 | isa = PBXGroup; 126 | children = ( 127 | F3A118831FEB4B4F00B91E40 /* LXKeyBoardTextView.app */, 128 | F3A1189B1FEB4B4F00B91E40 /* LXKeyBoardTextViewTests.xctest */, 129 | F3A118A61FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.xctest */, 130 | ); 131 | name = Products; 132 | sourceTree = ""; 133 | }; 134 | F3A118851FEB4B4F00B91E40 /* LXKeyBoardTextView */ = { 135 | isa = PBXGroup; 136 | children = ( 137 | F3A118861FEB4B4F00B91E40 /* AppDelegate.h */, 138 | F3A118871FEB4B4F00B91E40 /* AppDelegate.m */, 139 | F3A118891FEB4B4F00B91E40 /* ViewController.h */, 140 | F3A1188A1FEB4B4F00B91E40 /* ViewController.m */, 141 | F3A118C61FEB4C6E00B91E40 /* LXKeyboadController.h */, 142 | F3A118C71FEB4C6E00B91E40 /* LXKeyboadController.m */, 143 | F3E9B146200EF04600120BD2 /* LXKeyBoardXibController.h */, 144 | F3E9B147200EF04600120BD2 /* LXKeyBoardXibController.m */, 145 | F3E9B148200EF04600120BD2 /* LXKeyBoardXibController.xib */, 146 | F3A118C91FEB4E5400B91E40 /* LXKeyboard */, 147 | F3A118B81FEB4B8700B91E40 /* Category */, 148 | F3A1188C1FEB4B4F00B91E40 /* Main.storyboard */, 149 | F3A1188F1FEB4B4F00B91E40 /* Assets.xcassets */, 150 | F3A118911FEB4B4F00B91E40 /* LaunchScreen.storyboard */, 151 | F3A118941FEB4B4F00B91E40 /* Info.plist */, 152 | F3A118951FEB4B4F00B91E40 /* main.m */, 153 | F3A118C51FEB4B9800B91E40 /* LX.pch */, 154 | ); 155 | path = LXKeyBoardTextView; 156 | sourceTree = ""; 157 | }; 158 | F3A1189E1FEB4B5000B91E40 /* LXKeyBoardTextViewTests */ = { 159 | isa = PBXGroup; 160 | children = ( 161 | F3A1189F1FEB4B5000B91E40 /* LXKeyBoardTextViewTests.m */, 162 | F3A118A11FEB4B5000B91E40 /* Info.plist */, 163 | ); 164 | path = LXKeyBoardTextViewTests; 165 | sourceTree = ""; 166 | }; 167 | F3A118A91FEB4B5000B91E40 /* LXKeyBoardTextViewUITests */ = { 168 | isa = PBXGroup; 169 | children = ( 170 | F3A118AA1FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.m */, 171 | F3A118AC1FEB4B5000B91E40 /* Info.plist */, 172 | ); 173 | path = LXKeyBoardTextViewUITests; 174 | sourceTree = ""; 175 | }; 176 | F3A118B81FEB4B8700B91E40 /* Category */ = { 177 | isa = PBXGroup; 178 | children = ( 179 | F31B6EB51FECBA8F0073C5EE /* NSObject+LXSwizzling.h */, 180 | F31B6EB41FECBA8F0073C5EE /* NSObject+LXSwizzling.m */, 181 | F31B6EB11FECBA5B0073C5EE /* UILabel+LXVerticalStyle.h */, 182 | F31B6EB21FECBA5B0073C5EE /* UILabel+LXVerticalStyle.m */, 183 | F3A118B91FEB4B8700B91E40 /* LxButton.h */, 184 | F3A118BA1FEB4B8700B91E40 /* LxButton.m */, 185 | F3A118BB1FEB4B8700B91E40 /* UIColor+Expanded.h */, 186 | F3A118BC1FEB4B8700B91E40 /* UIColor+Expanded.m */, 187 | F3A118BD1FEB4B8700B91E40 /* UILabel+LXLabel.h */, 188 | F3A118BE1FEB4B8700B91E40 /* UILabel+LXLabel.m */, 189 | F3A118BF1FEB4B8700B91E40 /* UIView+LX_Frame.h */, 190 | F3A118C01FEB4B8700B91E40 /* UIView+LX_Frame.m */, 191 | ); 192 | path = Category; 193 | sourceTree = ""; 194 | }; 195 | F3A118C91FEB4E5400B91E40 /* LXKeyboard */ = { 196 | isa = PBXGroup; 197 | children = ( 198 | F3A118CD1FEB4E8B00B91E40 /* LXKeyBoard.h */, 199 | F3A118CE1FEB4E8B00B91E40 /* LXKeyBoard.m */, 200 | F3A118D01FEB4F7B00B91E40 /* LXTextView.h */, 201 | F3A118D11FEB4F7B00B91E40 /* LXTextView.m */, 202 | ); 203 | path = LXKeyboard; 204 | sourceTree = ""; 205 | }; 206 | /* End PBXGroup section */ 207 | 208 | /* Begin PBXNativeTarget section */ 209 | F3A118821FEB4B4F00B91E40 /* LXKeyBoardTextView */ = { 210 | isa = PBXNativeTarget; 211 | buildConfigurationList = F3A118AF1FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextView" */; 212 | buildPhases = ( 213 | F3A1187F1FEB4B4F00B91E40 /* Sources */, 214 | F3A118801FEB4B4F00B91E40 /* Frameworks */, 215 | F3A118811FEB4B4F00B91E40 /* Resources */, 216 | ); 217 | buildRules = ( 218 | ); 219 | dependencies = ( 220 | ); 221 | name = LXKeyBoardTextView; 222 | productName = LXKeyBoardTextView; 223 | productReference = F3A118831FEB4B4F00B91E40 /* LXKeyBoardTextView.app */; 224 | productType = "com.apple.product-type.application"; 225 | }; 226 | F3A1189A1FEB4B4F00B91E40 /* LXKeyBoardTextViewTests */ = { 227 | isa = PBXNativeTarget; 228 | buildConfigurationList = F3A118B21FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextViewTests" */; 229 | buildPhases = ( 230 | F3A118971FEB4B4F00B91E40 /* Sources */, 231 | F3A118981FEB4B4F00B91E40 /* Frameworks */, 232 | F3A118991FEB4B4F00B91E40 /* Resources */, 233 | ); 234 | buildRules = ( 235 | ); 236 | dependencies = ( 237 | F3A1189D1FEB4B4F00B91E40 /* PBXTargetDependency */, 238 | ); 239 | name = LXKeyBoardTextViewTests; 240 | productName = LXKeyBoardTextViewTests; 241 | productReference = F3A1189B1FEB4B4F00B91E40 /* LXKeyBoardTextViewTests.xctest */; 242 | productType = "com.apple.product-type.bundle.unit-test"; 243 | }; 244 | F3A118A51FEB4B5000B91E40 /* LXKeyBoardTextViewUITests */ = { 245 | isa = PBXNativeTarget; 246 | buildConfigurationList = F3A118B51FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextViewUITests" */; 247 | buildPhases = ( 248 | F3A118A21FEB4B5000B91E40 /* Sources */, 249 | F3A118A31FEB4B5000B91E40 /* Frameworks */, 250 | F3A118A41FEB4B5000B91E40 /* Resources */, 251 | ); 252 | buildRules = ( 253 | ); 254 | dependencies = ( 255 | F3A118A81FEB4B5000B91E40 /* PBXTargetDependency */, 256 | ); 257 | name = LXKeyBoardTextViewUITests; 258 | productName = LXKeyBoardTextViewUITests; 259 | productReference = F3A118A61FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.xctest */; 260 | productType = "com.apple.product-type.bundle.ui-testing"; 261 | }; 262 | /* End PBXNativeTarget section */ 263 | 264 | /* Begin PBXProject section */ 265 | F3A1187B1FEB4B4F00B91E40 /* Project object */ = { 266 | isa = PBXProject; 267 | attributes = { 268 | LastUpgradeCheck = 0910; 269 | ORGANIZATIONNAME = "漫漫"; 270 | TargetAttributes = { 271 | F3A118821FEB4B4F00B91E40 = { 272 | CreatedOnToolsVersion = 9.1; 273 | ProvisioningStyle = Automatic; 274 | }; 275 | F3A1189A1FEB4B4F00B91E40 = { 276 | CreatedOnToolsVersion = 9.1; 277 | ProvisioningStyle = Automatic; 278 | TestTargetID = F3A118821FEB4B4F00B91E40; 279 | }; 280 | F3A118A51FEB4B5000B91E40 = { 281 | CreatedOnToolsVersion = 9.1; 282 | ProvisioningStyle = Automatic; 283 | TestTargetID = F3A118821FEB4B4F00B91E40; 284 | }; 285 | }; 286 | }; 287 | buildConfigurationList = F3A1187E1FEB4B4F00B91E40 /* Build configuration list for PBXProject "LXKeyBoardTextView" */; 288 | compatibilityVersion = "Xcode 8.0"; 289 | developmentRegion = en; 290 | hasScannedForEncodings = 0; 291 | knownRegions = ( 292 | en, 293 | Base, 294 | ); 295 | mainGroup = F3A1187A1FEB4B4F00B91E40; 296 | productRefGroup = F3A118841FEB4B4F00B91E40 /* Products */; 297 | projectDirPath = ""; 298 | projectRoot = ""; 299 | targets = ( 300 | F3A118821FEB4B4F00B91E40 /* LXKeyBoardTextView */, 301 | F3A1189A1FEB4B4F00B91E40 /* LXKeyBoardTextViewTests */, 302 | F3A118A51FEB4B5000B91E40 /* LXKeyBoardTextViewUITests */, 303 | ); 304 | }; 305 | /* End PBXProject section */ 306 | 307 | /* Begin PBXResourcesBuildPhase section */ 308 | F3A118811FEB4B4F00B91E40 /* Resources */ = { 309 | isa = PBXResourcesBuildPhase; 310 | buildActionMask = 2147483647; 311 | files = ( 312 | F3E9B14A200EF04600120BD2 /* LXKeyBoardXibController.xib in Resources */, 313 | F3A118931FEB4B4F00B91E40 /* LaunchScreen.storyboard in Resources */, 314 | F3A118901FEB4B4F00B91E40 /* Assets.xcassets in Resources */, 315 | F3A1188E1FEB4B4F00B91E40 /* Main.storyboard in Resources */, 316 | ); 317 | runOnlyForDeploymentPostprocessing = 0; 318 | }; 319 | F3A118991FEB4B4F00B91E40 /* Resources */ = { 320 | isa = PBXResourcesBuildPhase; 321 | buildActionMask = 2147483647; 322 | files = ( 323 | ); 324 | runOnlyForDeploymentPostprocessing = 0; 325 | }; 326 | F3A118A41FEB4B5000B91E40 /* Resources */ = { 327 | isa = PBXResourcesBuildPhase; 328 | buildActionMask = 2147483647; 329 | files = ( 330 | ); 331 | runOnlyForDeploymentPostprocessing = 0; 332 | }; 333 | /* End PBXResourcesBuildPhase section */ 334 | 335 | /* Begin PBXSourcesBuildPhase section */ 336 | F3A1187F1FEB4B4F00B91E40 /* Sources */ = { 337 | isa = PBXSourcesBuildPhase; 338 | buildActionMask = 2147483647; 339 | files = ( 340 | F3A1188B1FEB4B4F00B91E40 /* ViewController.m in Sources */, 341 | F31B6EB61FECBA8F0073C5EE /* NSObject+LXSwizzling.m in Sources */, 342 | F3A118CF1FEB4E8B00B91E40 /* LXKeyBoard.m in Sources */, 343 | F3A118C31FEB4B8700B91E40 /* UILabel+LXLabel.m in Sources */, 344 | F31B6EB31FECBA5B0073C5EE /* UILabel+LXVerticalStyle.m in Sources */, 345 | F3E9B149200EF04600120BD2 /* LXKeyBoardXibController.m in Sources */, 346 | F3A118D21FEB4F7B00B91E40 /* LXTextView.m in Sources */, 347 | F3A118C41FEB4B8700B91E40 /* UIView+LX_Frame.m in Sources */, 348 | F3A118C11FEB4B8700B91E40 /* LxButton.m in Sources */, 349 | F3A118961FEB4B4F00B91E40 /* main.m in Sources */, 350 | F3A118881FEB4B4F00B91E40 /* AppDelegate.m in Sources */, 351 | F3A118C21FEB4B8700B91E40 /* UIColor+Expanded.m in Sources */, 352 | F3A118C81FEB4C6E00B91E40 /* LXKeyboadController.m in Sources */, 353 | ); 354 | runOnlyForDeploymentPostprocessing = 0; 355 | }; 356 | F3A118971FEB4B4F00B91E40 /* Sources */ = { 357 | isa = PBXSourcesBuildPhase; 358 | buildActionMask = 2147483647; 359 | files = ( 360 | F3A118A01FEB4B5000B91E40 /* LXKeyBoardTextViewTests.m in Sources */, 361 | ); 362 | runOnlyForDeploymentPostprocessing = 0; 363 | }; 364 | F3A118A21FEB4B5000B91E40 /* Sources */ = { 365 | isa = PBXSourcesBuildPhase; 366 | buildActionMask = 2147483647; 367 | files = ( 368 | F3A118AB1FEB4B5000B91E40 /* LXKeyBoardTextViewUITests.m in Sources */, 369 | ); 370 | runOnlyForDeploymentPostprocessing = 0; 371 | }; 372 | /* End PBXSourcesBuildPhase section */ 373 | 374 | /* Begin PBXTargetDependency section */ 375 | F3A1189D1FEB4B4F00B91E40 /* PBXTargetDependency */ = { 376 | isa = PBXTargetDependency; 377 | target = F3A118821FEB4B4F00B91E40 /* LXKeyBoardTextView */; 378 | targetProxy = F3A1189C1FEB4B4F00B91E40 /* PBXContainerItemProxy */; 379 | }; 380 | F3A118A81FEB4B5000B91E40 /* PBXTargetDependency */ = { 381 | isa = PBXTargetDependency; 382 | target = F3A118821FEB4B4F00B91E40 /* LXKeyBoardTextView */; 383 | targetProxy = F3A118A71FEB4B5000B91E40 /* PBXContainerItemProxy */; 384 | }; 385 | /* End PBXTargetDependency section */ 386 | 387 | /* Begin PBXVariantGroup section */ 388 | F3A1188C1FEB4B4F00B91E40 /* Main.storyboard */ = { 389 | isa = PBXVariantGroup; 390 | children = ( 391 | F3A1188D1FEB4B4F00B91E40 /* Base */, 392 | ); 393 | name = Main.storyboard; 394 | sourceTree = ""; 395 | }; 396 | F3A118911FEB4B4F00B91E40 /* LaunchScreen.storyboard */ = { 397 | isa = PBXVariantGroup; 398 | children = ( 399 | F3A118921FEB4B4F00B91E40 /* Base */, 400 | ); 401 | name = LaunchScreen.storyboard; 402 | sourceTree = ""; 403 | }; 404 | /* End PBXVariantGroup section */ 405 | 406 | /* Begin XCBuildConfiguration section */ 407 | F3A118AD1FEB4B5000B91E40 /* Debug */ = { 408 | isa = XCBuildConfiguration; 409 | buildSettings = { 410 | ALWAYS_SEARCH_USER_PATHS = NO; 411 | CLANG_ANALYZER_NONNULL = YES; 412 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 413 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 414 | CLANG_CXX_LIBRARY = "libc++"; 415 | CLANG_ENABLE_MODULES = YES; 416 | CLANG_ENABLE_OBJC_ARC = YES; 417 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 418 | CLANG_WARN_BOOL_CONVERSION = YES; 419 | CLANG_WARN_COMMA = YES; 420 | CLANG_WARN_CONSTANT_CONVERSION = YES; 421 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 422 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 423 | CLANG_WARN_EMPTY_BODY = YES; 424 | CLANG_WARN_ENUM_CONVERSION = YES; 425 | CLANG_WARN_INFINITE_RECURSION = YES; 426 | CLANG_WARN_INT_CONVERSION = YES; 427 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 428 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 429 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 430 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 431 | CLANG_WARN_STRICT_PROTOTYPES = YES; 432 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 433 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 434 | CLANG_WARN_UNREACHABLE_CODE = YES; 435 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 436 | CODE_SIGN_IDENTITY = "iPhone Developer"; 437 | COPY_PHASE_STRIP = NO; 438 | DEBUG_INFORMATION_FORMAT = dwarf; 439 | ENABLE_STRICT_OBJC_MSGSEND = YES; 440 | ENABLE_TESTABILITY = YES; 441 | GCC_C_LANGUAGE_STANDARD = gnu11; 442 | GCC_DYNAMIC_NO_PIC = NO; 443 | GCC_NO_COMMON_BLOCKS = YES; 444 | GCC_OPTIMIZATION_LEVEL = 0; 445 | GCC_PREPROCESSOR_DEFINITIONS = ( 446 | "DEBUG=1", 447 | "$(inherited)", 448 | ); 449 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 450 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 451 | GCC_WARN_UNDECLARED_SELECTOR = YES; 452 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 453 | GCC_WARN_UNUSED_FUNCTION = YES; 454 | GCC_WARN_UNUSED_VARIABLE = YES; 455 | IPHONEOS_DEPLOYMENT_TARGET = 11.1; 456 | MTL_ENABLE_DEBUG_INFO = YES; 457 | ONLY_ACTIVE_ARCH = YES; 458 | SDKROOT = iphoneos; 459 | }; 460 | name = Debug; 461 | }; 462 | F3A118AE1FEB4B5000B91E40 /* Release */ = { 463 | isa = XCBuildConfiguration; 464 | buildSettings = { 465 | ALWAYS_SEARCH_USER_PATHS = NO; 466 | CLANG_ANALYZER_NONNULL = YES; 467 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 468 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 469 | CLANG_CXX_LIBRARY = "libc++"; 470 | CLANG_ENABLE_MODULES = YES; 471 | CLANG_ENABLE_OBJC_ARC = YES; 472 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 473 | CLANG_WARN_BOOL_CONVERSION = YES; 474 | CLANG_WARN_COMMA = YES; 475 | CLANG_WARN_CONSTANT_CONVERSION = YES; 476 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 477 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 478 | CLANG_WARN_EMPTY_BODY = YES; 479 | CLANG_WARN_ENUM_CONVERSION = YES; 480 | CLANG_WARN_INFINITE_RECURSION = YES; 481 | CLANG_WARN_INT_CONVERSION = YES; 482 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 483 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 484 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 485 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 486 | CLANG_WARN_STRICT_PROTOTYPES = YES; 487 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 488 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 489 | CLANG_WARN_UNREACHABLE_CODE = YES; 490 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 491 | CODE_SIGN_IDENTITY = "iPhone Developer"; 492 | COPY_PHASE_STRIP = NO; 493 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 494 | ENABLE_NS_ASSERTIONS = NO; 495 | ENABLE_STRICT_OBJC_MSGSEND = YES; 496 | GCC_C_LANGUAGE_STANDARD = gnu11; 497 | GCC_NO_COMMON_BLOCKS = YES; 498 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 499 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 500 | GCC_WARN_UNDECLARED_SELECTOR = YES; 501 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 502 | GCC_WARN_UNUSED_FUNCTION = YES; 503 | GCC_WARN_UNUSED_VARIABLE = YES; 504 | IPHONEOS_DEPLOYMENT_TARGET = 11.1; 505 | MTL_ENABLE_DEBUG_INFO = NO; 506 | SDKROOT = iphoneos; 507 | VALIDATE_PRODUCT = YES; 508 | }; 509 | name = Release; 510 | }; 511 | F3A118B01FEB4B5000B91E40 /* Debug */ = { 512 | isa = XCBuildConfiguration; 513 | buildSettings = { 514 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 515 | CODE_SIGN_STYLE = Automatic; 516 | DEVELOPMENT_TEAM = BL3GGVA2PM; 517 | GCC_PREFIX_HEADER = "$(SRCROOT)/LXKeyBoardTextView/LX.pch"; 518 | INFOPLIST_FILE = LXKeyBoardTextView/Info.plist; 519 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 520 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 521 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextView"; 522 | PRODUCT_NAME = "$(TARGET_NAME)"; 523 | TARGETED_DEVICE_FAMILY = 1; 524 | }; 525 | name = Debug; 526 | }; 527 | F3A118B11FEB4B5000B91E40 /* Release */ = { 528 | isa = XCBuildConfiguration; 529 | buildSettings = { 530 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 531 | CODE_SIGN_STYLE = Automatic; 532 | DEVELOPMENT_TEAM = BL3GGVA2PM; 533 | GCC_PREFIX_HEADER = "$(SRCROOT)/LXKeyBoardTextView/LX.pch"; 534 | INFOPLIST_FILE = LXKeyBoardTextView/Info.plist; 535 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 536 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 537 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextView"; 538 | PRODUCT_NAME = "$(TARGET_NAME)"; 539 | TARGETED_DEVICE_FAMILY = 1; 540 | }; 541 | name = Release; 542 | }; 543 | F3A118B31FEB4B5000B91E40 /* Debug */ = { 544 | isa = XCBuildConfiguration; 545 | buildSettings = { 546 | BUNDLE_LOADER = "$(TEST_HOST)"; 547 | CODE_SIGN_STYLE = Automatic; 548 | INFOPLIST_FILE = LXKeyBoardTextViewTests/Info.plist; 549 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 550 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextViewTests"; 551 | PRODUCT_NAME = "$(TARGET_NAME)"; 552 | TARGETED_DEVICE_FAMILY = "1,2"; 553 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/LXKeyBoardTextView.app/LXKeyBoardTextView"; 554 | }; 555 | name = Debug; 556 | }; 557 | F3A118B41FEB4B5000B91E40 /* Release */ = { 558 | isa = XCBuildConfiguration; 559 | buildSettings = { 560 | BUNDLE_LOADER = "$(TEST_HOST)"; 561 | CODE_SIGN_STYLE = Automatic; 562 | INFOPLIST_FILE = LXKeyBoardTextViewTests/Info.plist; 563 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 564 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextViewTests"; 565 | PRODUCT_NAME = "$(TARGET_NAME)"; 566 | TARGETED_DEVICE_FAMILY = "1,2"; 567 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/LXKeyBoardTextView.app/LXKeyBoardTextView"; 568 | }; 569 | name = Release; 570 | }; 571 | F3A118B61FEB4B5000B91E40 /* Debug */ = { 572 | isa = XCBuildConfiguration; 573 | buildSettings = { 574 | CODE_SIGN_STYLE = Automatic; 575 | INFOPLIST_FILE = LXKeyBoardTextViewUITests/Info.plist; 576 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 577 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextViewUITests"; 578 | PRODUCT_NAME = "$(TARGET_NAME)"; 579 | TARGETED_DEVICE_FAMILY = "1,2"; 580 | TEST_TARGET_NAME = LXKeyBoardTextView; 581 | }; 582 | name = Debug; 583 | }; 584 | F3A118B71FEB4B5000B91E40 /* Release */ = { 585 | isa = XCBuildConfiguration; 586 | buildSettings = { 587 | CODE_SIGN_STYLE = Automatic; 588 | INFOPLIST_FILE = LXKeyBoardTextViewUITests/Info.plist; 589 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 590 | PRODUCT_BUNDLE_IDENTIFIER = "--.LXKeyBoardTextViewUITests"; 591 | PRODUCT_NAME = "$(TARGET_NAME)"; 592 | TARGETED_DEVICE_FAMILY = "1,2"; 593 | TEST_TARGET_NAME = LXKeyBoardTextView; 594 | }; 595 | name = Release; 596 | }; 597 | /* End XCBuildConfiguration section */ 598 | 599 | /* Begin XCConfigurationList section */ 600 | F3A1187E1FEB4B4F00B91E40 /* Build configuration list for PBXProject "LXKeyBoardTextView" */ = { 601 | isa = XCConfigurationList; 602 | buildConfigurations = ( 603 | F3A118AD1FEB4B5000B91E40 /* Debug */, 604 | F3A118AE1FEB4B5000B91E40 /* Release */, 605 | ); 606 | defaultConfigurationIsVisible = 0; 607 | defaultConfigurationName = Release; 608 | }; 609 | F3A118AF1FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextView" */ = { 610 | isa = XCConfigurationList; 611 | buildConfigurations = ( 612 | F3A118B01FEB4B5000B91E40 /* Debug */, 613 | F3A118B11FEB4B5000B91E40 /* Release */, 614 | ); 615 | defaultConfigurationIsVisible = 0; 616 | defaultConfigurationName = Release; 617 | }; 618 | F3A118B21FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextViewTests" */ = { 619 | isa = XCConfigurationList; 620 | buildConfigurations = ( 621 | F3A118B31FEB4B5000B91E40 /* Debug */, 622 | F3A118B41FEB4B5000B91E40 /* Release */, 623 | ); 624 | defaultConfigurationIsVisible = 0; 625 | defaultConfigurationName = Release; 626 | }; 627 | F3A118B51FEB4B5000B91E40 /* Build configuration list for PBXNativeTarget "LXKeyBoardTextViewUITests" */ = { 628 | isa = XCConfigurationList; 629 | buildConfigurations = ( 630 | F3A118B61FEB4B5000B91E40 /* Debug */, 631 | F3A118B71FEB4B5000B91E40 /* Release */, 632 | ); 633 | defaultConfigurationIsVisible = 0; 634 | defaultConfigurationName = Release; 635 | }; 636 | /* End XCConfigurationList section */ 637 | }; 638 | rootObject = F3A1187B1FEB4B4F00B91E40 /* Project object */; 639 | } 640 | --------------------------------------------------------------------------------